lkml.org 
[lkml]   [2012]   [Jul]   [31]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    /
    Date
    Subjectdrivers/misc/apds990x.c: might_sleep operation in interrupt handler
    From
    Interrupt handler apds990x_irq in APDS990x sensor driver
    invokes mutex_lock that is might sleep operation.

    Found by Linux Driver Verification project (linuxtesting.org)
    within my participation in the GSoC 2012 program.


    static irqreturn_t apds990x_irq(int irq, void *data)
    {
    struct apds990x_chip *chip = data;
    u8 status;

    apds990x_read_byte(chip, APDS990X_STATUS, &status);
    apds990x_ack_int(chip, status);

    mutex_lock(&chip->mutex);
    ...
    }

    static int __devinit apds990x_probe(struct i2c_client *client,
    const struct i2c_device_id *id)
    {
    ...
    err = request_threaded_irq(client->irq, NULL,
    apds990x_irq,
    IRQF_TRIGGER_FALLING | IRQF_TRIGGER_LOW |
    IRQF_ONESHOT,
    "apds990x", chip);
    ...
    }


    \
     
     \ /
      Last update: 2012-07-31 20:21    [W:0.035 / U:31.540 seconds]
    ©2003-2016 Jasper Spaans. hosted at Digital OceanAdvertise on this site