dm: avoid void function return statements
authorHeinz Mauelshagen <heinzm@redhat.com>
Tue, 7 Feb 2023 21:27:11 +0000 (22:27 +0100)
committerMike Snitzer <snitzer@kernel.org>
Tue, 14 Feb 2023 19:23:07 +0000 (14:23 -0500)
Signed-off-by: Heinz Mauelshagen <heinzm@redhat.com>
Signed-off-by: Mike Snitzer <snitzer@kernel.org>
drivers/md/dm-io-rewind.c
drivers/md/dm-log-userspace-base.c
drivers/md/dm-zoned-target.c

index e59b749eec82970a5b50c936ba184832c3676745..6155b0117c9d6b6c687a1885aa8594b9b9dc264b 100644 (file)
@@ -68,7 +68,6 @@ static void dm_bio_integrity_rewind(struct bio *bio, unsigned int bytes_done)
 static inline void dm_bio_integrity_rewind(struct bio *bio,
                                           unsigned int bytes_done)
 {
-       return;
 }
 
 #endif
@@ -104,7 +103,6 @@ static void dm_bio_crypt_rewind(struct bio *bio, unsigned int bytes)
 
 static inline void dm_bio_crypt_rewind(struct bio *bio, unsigned int bytes)
 {
-       return;
 }
 
 #endif
index bc418173c5f78cb07de894e01adca30e0db0c103..5aace6ee6d4790fbccd8f8875c7dc69ec5159f85 100644 (file)
@@ -346,8 +346,6 @@ static void userspace_dtr(struct dm_dirty_log *log)
 
        kfree(lc->usr_argv_str);
        kfree(lc);
-
-       return;
 }
 
 static int userspace_presuspend(struct dm_dirty_log *log)
@@ -661,8 +659,6 @@ static void userspace_mark_region(struct dm_dirty_log *log, region_t region)
        fe->region = region;
        list_add(&fe->list, &lc->mark_list);
        spin_unlock_irqrestore(&lc->flush_lock, flags);
-
-       return;
 }
 
 /*
@@ -698,8 +694,6 @@ static void userspace_clear_region(struct dm_dirty_log *log, region_t region)
        fe->region = region;
        list_add(&fe->list, &lc->clear_list);
        spin_unlock_irqrestore(&lc->flush_lock, flags);
-
-       return;
 }
 
 /*
@@ -756,7 +750,6 @@ static void userspace_set_region_sync(struct dm_dirty_log *log,
         * It would be nice to be able to report failures.
         * However, it is easy enough to detect and resolve.
         */
-       return;
 }
 
 /*
@@ -927,7 +920,6 @@ static void __exit userspace_dirty_log_exit(void)
        kmem_cache_destroy(_flush_entry_cache);
 
        DMINFO("version " DM_LOG_USERSPACE_VSN " unloaded");
-       return;
 }
 
 module_init(userspace_dirty_log_init);
index 95b132b52f332376a8d4504c5be500c60917ffe2..ad4764dcd013704fabcefb3f3ad14c3f3d7c7f40 100644 (file)
@@ -1119,7 +1119,6 @@ static void dmz_status(struct dm_target *ti, status_type_t type,
                *result = '\0';
                break;
        }
-       return;
 }
 
 static int dmz_message(struct dm_target *ti, unsigned int argc, char **argv,