loop: make do_req_filebacked more robust
authorChristoph Hellwig <hch@lst.de>
Thu, 4 Aug 2016 14:10:01 +0000 (16:10 +0200)
committerJens Axboe <axboe@fb.com>
Thu, 4 Aug 2016 20:19:16 +0000 (14:19 -0600)
commitc1c87c2ba9ec06d8ba9e8a26c18c67a2ba9cd9c1
tree6ff6442724b953a5da022be0752eb0c346665e7e
parentf0225cacfe7e69ff3234a125aeb0f3d65077835c
loop: make do_req_filebacked more robust

Use a switch statement to iterate over the possible operations and
error out if it's an incorrect one.

Signed-off-by: Jens Axboe <axboe@fb.com>
drivers/block/loop.c