mtip32xx: Add SRSI support
authorAsai Thambi S P <asamymuthupa@micron.com>
Wed, 11 Sep 2013 19:14:42 +0000 (13:14 -0600)
committerJens Axboe <axboe@fb.com>
Mon, 30 Mar 2015 18:54:50 +0000 (12:54 -0600)
commitedfdfd3db8d69cd997c121896f56a6a57210755c
treef587c1e4a454722a0430ffc139f686ac9d2d34d8
parent6176baaae34b746713f0d8ed25310c68e4f0c9a5
mtip32xx: Add SRSI support

This patch add support for SRSI(Surprise Removal Surprise Insertion).

Approach:
---------
Surprise Removal:
-----------------
On surprise removal of the device, gendisk, request queue, device index, sysfs
entries, etc are retained as long as device is in use - mounted filesystem,
device opened by an application, etc. The service thread breaks out of the main
while loop, waits for pci remove to exit, and then waits for device to become
free. When there no holders of the device, service thread cleans up the block
and device related stuff and returns.

Surprise Insertion:
-------------------
No change, this scenario follows the normal pci probe() function flow.

Signed-off-by: Asai Thambi S P <asamymuthupa@micron.com>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
drivers/block/mtip32xx/mtip32xx.c
drivers/block/mtip32xx/mtip32xx.h