Skip to content

Commit c44a4ed

Browse files
bvanasscheaxboe
authored andcommitted
block: Fix the type of 'sts' in bsg_queue_rq()
This patch fixes the following sparse warnings: block/bsg-lib.c:269:19: warning: incorrect type in initializer (different base types) block/bsg-lib.c:269:19: expected int sts block/bsg-lib.c:269:19: got restricted blk_status_t [usertype] block/bsg-lib.c:286:16: warning: incorrect type in return expression (different base types) block/bsg-lib.c:286:16: expected restricted blk_status_t block/bsg-lib.c:286:16: got int [assigned] sts Cc: Martin Wilck <[email protected]> Fixes: d46fe2c ("block: drop device references in bsg_queue_rq()") Signed-off-by: Bart Van Assche <[email protected]> Signed-off-by: Jens Axboe <[email protected]>
1 parent c58c1f8 commit c44a4ed

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

block/bsg-lib.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -266,7 +266,7 @@ static blk_status_t bsg_queue_rq(struct blk_mq_hw_ctx *hctx,
266266
struct request *req = bd->rq;
267267
struct bsg_set *bset =
268268
container_of(q->tag_set, struct bsg_set, tag_set);
269-
int sts = BLK_STS_IOERR;
269+
blk_status_t sts = BLK_STS_IOERR;
270270
int ret;
271271

272272
blk_mq_start_request(req);

0 commit comments

Comments
 (0)