]> git.baikalelectronics.ru Git - kernel.git/commit
mtd: powernv_flash: Don't return -ERESTARTSYS on interrupted token acquisition
authorCyril Bur <cyrilbur@gmail.com>
Fri, 3 Nov 2017 02:41:40 +0000 (13:41 +1100)
committerMichael Ellerman <mpe@ellerman.id.au>
Mon, 6 Nov 2017 09:20:26 +0000 (20:20 +1100)
commit4562640a7fde721fc8fa96a23d1dd75b0719a5f7
tree72dfff942caf4043a5d34dd37b4464dc088d45d0
parent32995c0ed18f7d0280e5980429e64a9c3706903d
mtd: powernv_flash: Don't return -ERESTARTSYS on interrupted token acquisition

Because the MTD core might split up a read() or write() from userspace
into several calls to the driver, we may fail to get a token but already
have done some work, best to return -EINTR back to userspace and have
them decide what to do.

Signed-off-by: Cyril Bur <cyrilbur@gmail.com>
Acked-by: Boris Brezillon <boris.brezillon@free-electrons.com>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
drivers/mtd/devices/powernv_flash.c