]> git.kernelconcepts.de Git - karo-tx-linux.git/blobdiff - drivers/block/swim.c
block: introduce new block status code type
[karo-tx-linux.git] / drivers / block / swim.c
index 3064be6cf3755a4017cbd2a30cda023977250cbf..1633aaf240600859302b7cf4902e48aaf0c9e78c 100644 (file)
@@ -493,7 +493,7 @@ static inline int swim_read_sector(struct floppy_state *fs,
        return ret;
 }
 
-static int floppy_read_sectors(struct floppy_state *fs,
+static blk_status_t floppy_read_sectors(struct floppy_state *fs,
                               int req_sector, int sectors_nb,
                               unsigned char *buffer)
 {
@@ -516,7 +516,7 @@ static int floppy_read_sectors(struct floppy_state *fs,
                        ret = swim_read_sector(fs, side, track, sector,
                                                buffer);
                        if (try-- == 0)
-                               return -EIO;
+                               return BLK_STS_IOERR;
                } while (ret != 512);
 
                buffer += ret;
@@ -553,7 +553,7 @@ static void do_fd_request(struct request_queue *q)
 
        req = swim_next_request(swd);
        while (req) {
-               int err = -EIO;
+               blk_status_t err = BLK_STS_IOERR;
 
                fs = req->rq_disk->private_data;
                if (blk_rq_pos(req) >= fs->total_secs)