Skip to content

Commit d4d5894

Browse files
committed
Merge tag 'block-6.4-2023-05-13' of git://git.kernel.dk/linux
Pull block fixes from Jens Axboe: "Just a few minor fixes for drivers, and a deletion of a file that is woefully out-of-date these days" * tag 'block-6.4-2023-05-13' of git://git.kernel.dk/linux: Documentation/block: drop the request.rst file ublk: fix command op code check block/rnbd: replace REQ_OP_FLUSH with REQ_OP_WRITE nbd: Fix debugfs_create_dir error checking
2 parents 9a48d60 + 56cdea9 commit d4d5894

File tree

5 files changed

+4
-104
lines changed

5 files changed

+4
-104
lines changed

Documentation/block/index.rst

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,6 @@ Block
1818
kyber-iosched
1919
null_blk
2020
pr
21-
request
2221
stat
2322
switching-sched
2423
writeback_cache_control

Documentation/block/request.rst

Lines changed: 0 additions & 99 deletions
This file was deleted.

drivers/block/nbd.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1666,7 +1666,7 @@ static int nbd_dev_dbg_init(struct nbd_device *nbd)
16661666
return -EIO;
16671667

16681668
dir = debugfs_create_dir(nbd_name(nbd), nbd_dbg_dir);
1669-
if (!dir) {
1669+
if (IS_ERR(dir)) {
16701670
dev_err(nbd_to_dev(nbd), "Failed to create debugfs dir for '%s'\n",
16711671
nbd_name(nbd));
16721672
return -EIO;
@@ -1692,7 +1692,7 @@ static int nbd_dbg_init(void)
16921692
struct dentry *dbg_dir;
16931693

16941694
dbg_dir = debugfs_create_dir("nbd", NULL);
1695-
if (!dbg_dir)
1695+
if (IS_ERR(dbg_dir))
16961696
return -EIO;
16971697

16981698
nbd_dbg_dir = dbg_dir;

drivers/block/rnbd/rnbd-proto.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -241,7 +241,7 @@ static inline blk_opf_t rnbd_to_bio_flags(u32 rnbd_opf)
241241
bio_opf = REQ_OP_WRITE;
242242
break;
243243
case RNBD_OP_FLUSH:
244-
bio_opf = REQ_OP_FLUSH | REQ_PREFLUSH;
244+
bio_opf = REQ_OP_WRITE | REQ_PREFLUSH;
245245
break;
246246
case RNBD_OP_DISCARD:
247247
bio_opf = REQ_OP_DISCARD;

drivers/block/ublk_drv.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1281,7 +1281,7 @@ static inline int ublk_check_cmd_op(u32 cmd_op)
12811281
{
12821282
u32 ioc_type = _IOC_TYPE(cmd_op);
12831283

1284-
if (IS_ENABLED(CONFIG_BLKDEV_UBLK_LEGACY_OPCODES) && ioc_type != 'u')
1284+
if (!IS_ENABLED(CONFIG_BLKDEV_UBLK_LEGACY_OPCODES) && ioc_type != 'u')
12851285
return -EOPNOTSUPP;
12861286

12871287
if (ioc_type != 'u' && ioc_type != 0)

0 commit comments

Comments
 (0)