]> git.baikalelectronics.ru Git - kernel.git/commit
CRIS: gpio: don't call copy_to_user()/copy_from_user() while holding spinlocks
authorJesper Nilsson <jesper.nilsson@axis.com>
Mon, 2 Aug 2010 11:17:05 +0000 (13:17 +0200)
committerJesper Nilsson <jesper.nilsson@axis.com>
Wed, 4 Aug 2010 10:59:14 +0000 (12:59 +0200)
commit6c9a748c47b93490fa8206770c297d782cd5e84e
tree5c255d6b869bd98592b862a31dc79110df91557a
parent6a30703f9dbd683937b845c43595524f248c0924
CRIS: gpio: don't call copy_to_user()/copy_from_user() while holding spinlocks

copy_to_user()/copy_from_user() must not be used with spinlocks held.
Move locks inside each case so we have better control of when the locks
are held.

Also, since we use spinlocks, we don't need to hold the BKL, so remove it.

Reported-by: Kulikov Vasiliy <segooon@gmail.com>
Signed-off-by: Jesper Nilsson <jesper.nilsson@axis.com>
arch/cris/arch-v10/drivers/gpio.c