• Joel Stanley's avatar
    mmc: core: Fix blk_status_t handling · 1ccaa1bd
    Joel Stanley authored
    Sparse spits out this following warning:
    
    drivers/mmc/core/queue.c:311:21: warning: incorrect type in assignment (different base types)
    drivers/mmc/core/queue.c:311:21:    expected int ret
    drivers/mmc/core/queue.c:311:21:    got restricted blk_status_t [usertype]
    drivers/mmc/core/queue.c:314:21: warning: incorrect type in assignment (different base types)
    drivers/mmc/core/queue.c:314:21:    expected int ret
    drivers/mmc/core/queue.c:314:21:    got restricted blk_status_t [usertype]
    drivers/mmc/core/queue.c:336:16: warning: incorrect type in return expression (different base types)
    drivers/mmc/core/queue.c:336:16:    expected restricted blk_status_t
    drivers/mmc/core/queue.c:336:16:    got int [assigned] ret
    
    ret is only used for blk_status_t types, so make it that type.
    Signed-off-by: default avatarJoel Stanley <joel@jms.id.au>
    Reviewed-by: default avatarChristoph Hellwig <hch@lst.de>
    Link: https://lore.kernel.org/r/20211215011336.194089-1-joel@jms.id.auSigned-off-by: default avatarUlf Hansson <ulf.hansson@linaro.org>
    1ccaa1bd
queue.c 12.9 KB