diff mbox series

swim: fix a missing FMODE_ -> BLK_OPEN_ conversion in floppy_open

Message ID 20230620043051.707196-1-hch@lst.de (mailing list archive)
State New, archived
Headers show
Series swim: fix a missing FMODE_ -> BLK_OPEN_ conversion in floppy_open | expand

Commit Message

Christoph Hellwig June 20, 2023, 4:30 a.m. UTC
Fix a missing conversion to the new BLK_OPEN constant in swim.

Fixes: 05bdb9965305 ("block: replace fmode_t with a block-specific type for block open flags")
Reported-by: kernel test robot <lkp@intel.com>
Signed-off-by: Christoph Hellwig <hch@lst.de>
---
 drivers/block/swim.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Jens Axboe June 20, 2023, 1:18 p.m. UTC | #1
On Tue, 20 Jun 2023 06:30:51 +0200, Christoph Hellwig wrote:
> Fix a missing conversion to the new BLK_OPEN constant in swim.
> 
> 

Applied, thanks!

[1/1] swim: fix a missing FMODE_ -> BLK_OPEN_ conversion in floppy_open
      commit: 9a7933f3aca9d3b77235953996126f0e87c1d496

Best regards,
diff mbox series

Patch

diff --git a/drivers/block/swim.c b/drivers/block/swim.c
index 651009b3a601eb..f85b6af414b431 100644
--- a/drivers/block/swim.c
+++ b/drivers/block/swim.c
@@ -640,7 +640,7 @@  static int floppy_open(struct gendisk *disk, blk_mode_t mode)
 	if (mode & (BLK_OPEN_READ | BLK_OPEN_WRITE)) {
 		if (disk_check_media_change(disk) && fs->disk_in)
 			fs->ejected = 0;
-		if ((mode & FMODE_WRITE) && fs->write_protected) {
+		if ((mode & BLK_OPEN_WRITE) && fs->write_protected) {
 			err = -EROFS;
 			goto out;
 		}