Skip to content

Commit 752a592

Browse files
Yang Ruibinaxboe
authored andcommitted
pktcdvd: remove unnecessary debugfs_create_dir() error check
Remove the debugfs_create_dir() error check. It's safe to pass in error pointers to the debugfs API, hence the user isn't supposed to include error checking of the return values. Signed-off-by: Yang Ruibin <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Jens Axboe <[email protected]>
1 parent 9bce800 commit 752a592

File tree

1 file changed

+0
-2
lines changed

1 file changed

+0
-2
lines changed

drivers/block/pktcdvd.c

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -498,8 +498,6 @@ static void pkt_debugfs_dev_new(struct pktcdvd_device *pd)
498498
if (!pkt_debugfs_root)
499499
return;
500500
pd->dfs_d_root = debugfs_create_dir(pd->disk->disk_name, pkt_debugfs_root);
501-
if (!pd->dfs_d_root)
502-
return;
503501

504502
pd->dfs_f_info = debugfs_create_file("info", 0444, pd->dfs_d_root,
505503
pd, &pkt_seq_fops);

0 commit comments

Comments
 (0)