data = kmalloc(indio_dev->scan_bytes, GFP_KERNEL);
if (data == NULL) {
dev_err(&st->us->dev, "memory alloc failed in ring bh");
- return -ENOMEM;
+ goto done;
}
if (!bitmap_empty(indio_dev->active_scan_mask, indio_dev->masklength)
ring->access->store_to(ring, (u8 *)data, pf->timestamp);
- iio_trigger_notify_done(indio_dev->trig);
kfree(data);
+done:
+ iio_trigger_notify_done(indio_dev->trig);
return IRQ_HANDLED;
}
data = kmalloc(indio_dev->scan_bytes, GFP_KERNEL);
if (data == NULL) {
dev_err(&st->us->dev, "memory alloc failed in ring bh");
- return -ENOMEM;
+ goto done;
}
if (!bitmap_empty(indio_dev->active_scan_mask, indio_dev->masklength) &&
(u8 *)data,
pf->timestamp);
- iio_trigger_notify_done(indio_dev->trig);
kfree(data);
+done:
+ iio_trigger_notify_done(indio_dev->trig);
return IRQ_HANDLED;
}
data = kmalloc(indio_dev->scan_bytes, GFP_KERNEL);
if (data == NULL) {
dev_err(&st->us->dev, "memory alloc failed in ring bh");
- return -ENOMEM;
+ goto done;
}
if (!bitmap_empty(indio_dev->active_scan_mask, indio_dev->masklength) &&
ring->access->store_to(ring, (u8 *)data, pf->timestamp);
- iio_trigger_notify_done(indio_dev->trig);
kfree(data);
+done:
+ iio_trigger_notify_done(indio_dev->trig);
return IRQ_HANDLED;
}
data = kmalloc(indio_dev->scan_bytes, GFP_KERNEL);
if (data == NULL) {
dev_err(&st->us->dev, "memory alloc failed in ring bh");
- return -ENOMEM;
+ goto done;
}
if (!bitmap_empty(indio_dev->active_scan_mask, indio_dev->masklength) &&
ring->access->store_to(ring, (u8 *)data, pf->timestamp);
- iio_trigger_notify_done(indio_dev->trig);
kfree(data);
+done:
+ iio_trigger_notify_done(indio_dev->trig);
return IRQ_HANDLED;
}
data = kmalloc(indio_dev->scan_bytes, GFP_KERNEL);
if (data == NULL) {
dev_err(&st->us->dev, "memory alloc failed in ring bh");
- return -ENOMEM;
+ goto done;
}
if (!bitmap_empty(indio_dev->active_scan_mask, indio_dev->masklength) &&
ring->access->store_to(ring, (u8 *)data, pf->timestamp);
- iio_trigger_notify_done(indio_dev->trig);
kfree(data);
+done:
+ iio_trigger_notify_done(indio_dev->trig);
return IRQ_HANDLED;
}