]> git.baikalelectronics.ru Git - kernel.git/commit
lp8727_charger: Clean up the interrupt handler
authorKim, Milo <Milo.Kim@ti.com>
Fri, 31 Aug 2012 09:23:57 +0000 (09:23 +0000)
committerAnton Vorontsov <anton.vorontsov@linaro.org>
Fri, 21 Sep 2012 01:00:08 +0000 (18:00 -0700)
commit244c384eecc7e0df23facb25eb67d6d1b08d7277
tree0213d1f047f26b721226cab4daa90b51a4794011
parent2598243eb683ca0fd0d0c4c201b4e6e2e477da44
lp8727_charger: Clean up the interrupt handler

For better understanding, function name is changed. (lp8727_intr_config()
is replaced with lp8727_setup_irq().)

The private IRQ number is set when the IRQ is allocated successfully. This
data is used for releasing the IRQ on unloading the driver. Even the IRQ
number is not defined, the driver should be operated. In this case, just
return as 0.

In additional function lp8727_release_irq(), the workqueue is canceled and
the allocated IRQ is released.

Signed-off-by: Milo(Woogyom) Kim <milo.kim@ti.com>
Signed-off-by: Anton Vorontsov <anton.vorontsov@linaro.org>
drivers/power/lp8727_charger.c