On Wed 18-11-20 09:47:47, Christoph Hellwig wrote: > Split each case into a self-contained helper. > > Signed-off-by: Christoph Hellwig <hch@xxxxxx> > --- > include/linux/genhd.h | 7 +- > init/do_mounts.c | 183 +++++++++++++++++++++--------------------- > 2 files changed, 91 insertions(+), 99 deletions(-) > > diff --git a/include/linux/genhd.h b/include/linux/genhd.h > index 22f5b9fd96f8bf..ca5e356084c353 100644 > --- a/include/linux/genhd.h > +++ b/include/linux/genhd.h > @@ -388,18 +388,13 @@ static inline void bd_unlink_disk_holder(struct block_device *bdev, > } > #endif /* CONFIG_SYSFS */ > > +dev_t blk_lookup_devt(const char *name, int partno); > #ifdef CONFIG_BLOCK > void printk_all_partitions(void); > -dev_t blk_lookup_devt(const char *name, int partno); > #else /* CONFIG_BLOCK */ > static inline void printk_all_partitions(void) > { > } > -static inline dev_t blk_lookup_devt(const char *name, int partno) > -{ > - dev_t devt = MKDEV(0, 0); > - return devt; > -} > #endif /* CONFIG_BLOCK */ This hunk looks unrelated to the change? Also why you move the declaration outside the CONFIG_BLOCK ifdef? AFAICS blk_lookup_devt() still exists only when CONFIG_BLOCK is defined? Otherwise the patch looks good to me. Honza -- Jan Kara <jack@xxxxxxxx> SUSE Labs, CR