1
0
Fork 0
alistair23-linux/drivers/block
Christoph Hellwig 2a842acab1 block: introduce new block status code type
Currently we use nornal Linux errno values in the block layer, and while
we accept any error a few have overloaded magic meanings.  This patch
instead introduces a new  blk_status_t value that holds block layer specific
status codes and explicitly explains their meaning.  Helpers to convert from
and to the previous special meanings are provided for now, but I suspect
we want to get rid of them in the long run - those drivers that have a
errno input (e.g. networking) usually get errnos that don't know about
the special block layer overloads, and similarly returning them to userspace
will usually return somethings that strictly speaking isn't correct
for file system operations, but that's left as an exercise for later.

For now the set of errors is a very limited set that closely corresponds
to the previous overloaded errno values, but there is some low hanging
fruite to improve it.

blk_status_t (ab)uses the sparse __bitwise annotations to allow for sparse
typechecking, so that we can easily catch places passing the wrong values.

Signed-off-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Jens Axboe <axboe@fb.com>
2017-06-09 09:27:32 -06:00
..
aoe block: introduce new block status code type 2017-06-09 09:27:32 -06:00
drbd Merge branch 'for-linus' of git://git.kernel.dk/linux-block 2017-05-20 16:12:30 -07:00
mtip32xx block: introduce new block status code type 2017-06-09 09:27:32 -06:00
paride block: introduce new block status code type 2017-06-09 09:27:32 -06:00
rsxx rsxx: remove the discard_zeroes_data flag 2017-04-08 11:25:38 -06:00
xen-blkback block: xen-blkback: add null check to avoid null pointer dereference 2017-05-15 17:14:28 -04:00
zram zram: reduce load operation in page_same_filled 2017-05-03 15:52:11 -07:00
DAC960.c block: introduce new block status code type 2017-06-09 09:27:32 -06:00
DAC960.h
Kconfig libnvdimm for 4.12 2017-05-05 18:49:20 -07:00
Makefile block: remove the osdblk driver 2017-04-19 09:10:51 -06:00
amiflop.c block: introduce new block status code type 2017-06-09 09:27:32 -06:00
ataflop.c block: introduce new block status code type 2017-06-09 09:27:32 -06:00
brd.c libnvdimm for 4.12 2017-05-05 18:49:20 -07:00
cciss.c block: introduce new block status code type 2017-06-09 09:27:32 -06:00
cciss.h SCSI misc on 20170220 2017-02-21 11:51:42 -08:00
cciss_cmd.h cciss: use new doorbell-bit-5 reset method 2011-05-06 08:23:55 -06:00
cciss_scsi.c cciss: Remove kmalloc cast 2017-02-22 11:54:49 -07:00
cciss_scsi.h cciss: add cciss_tape_cmds module paramter 2011-05-06 08:23:59 -06:00
cryptoloop.c Replace <asm/uaccess.h> with <linux/uaccess.h> globally 2016-12-24 11:46:01 -08:00
floppy.c block: introduce new block status code type 2017-06-09 09:27:32 -06:00
loop.c block: introduce new block status code type 2017-06-09 09:27:32 -06:00
loop.h loop: support 4k physical blocksize 2017-06-08 08:40:00 -06:00
nbd.c block: introduce new block status code type 2017-06-09 09:27:32 -06:00
null_blk.c block: introduce new block status code type 2017-06-09 09:27:32 -06:00
pktcdvd.c pktcdvd: Check queue type before attaching to a queue 2017-06-01 13:10:43 -06:00
ps3disk.c block: introduce new block status code type 2017-06-09 09:27:32 -06:00
ps3vram.c block: convert to device_add_disk() 2016-06-27 12:26:08 -07:00
rbd.c block: introduce new block status code type 2017-06-09 09:27:32 -06:00
rbd_types.h rbd: RBD_V{1,2}_DATA_FORMAT macros 2017-02-20 12:16:15 +01:00
skd_main.c block: introduce new block status code type 2017-06-09 09:27:32 -06:00
skd_s1120.h skd: fix formatting in skd_s1120.h 2013-11-08 09:10:30 -07:00
smart1,2.h fix typos 'comamnd' -> 'command' in comments 2011-02-02 11:31:21 +01:00
sunvdc.c block: introduce new block status code type 2017-06-09 09:27:32 -06:00
swim.c block: introduce new block status code type 2017-06-09 09:27:32 -06:00
swim3.c block: introduce new block status code type 2017-06-09 09:27:32 -06:00
swim_asm.S
sx8.c block: introduce new block status code type 2017-06-09 09:27:32 -06:00
umem.c Replace <asm/uaccess.h> with <linux/uaccess.h> globally 2016-12-24 11:46:01 -08:00
umem.h
virtio_blk.c block: introduce new block status code type 2017-06-09 09:27:32 -06:00
xen-blkfront.c block: introduce new block status code type 2017-06-09 09:27:32 -06:00
xsysace.c block: introduce new block status code type 2017-06-09 09:27:32 -06:00
z2ram.c block: introduce new block status code type 2017-06-09 09:27:32 -06:00