linux-next: build failure after merge of the nvdimm tree

From: Stephen Rothwell
Date: Mon Aug 30 2021 - 03:09:52 EST


Hi all,

After merging the nvdimm tree, today's linux-next build (x86_64
allmodconfig) failed like this:

fs/erofs/super.c: In function 'erofs_fc_fill_super':
fs/erofs/super.c:549:7: error: implicit declaration of function 'bdev_dax_supported'; did you mean 'dax_supported'? [-Werror=implicit-function-declaration]
549 | !bdev_dax_supported(sb->s_bdev, EROFS_BLKSIZ)) {
| ^~~~~~~~~~~~~~~~~~
| dax_supported

Caused by commit

bdd3c50d83bf ("dax: remove bdev_dax_supported")

Interacting with commit

06252e9ce05b ("erofs: dax support for non-tailpacking regular file")

from the erofs tree.

I have applied the following merge fix patch:

From: Stephen Rothwell <sfr@xxxxxxxxxxxxxxxx>
Date: Mon, 30 Aug 2021 17:04:59 +1000
Subject: [PATCH] fixup for "dax: remove bdev_dax_supported"

Signed-off-by: Stephen Rothwell <sfr@xxxxxxxxxxxxxxxx>
---
fs/erofs/super.c | 6 ++++--
1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/fs/erofs/super.c b/fs/erofs/super.c
index a8d49e8fc83a..2dc0b9f1d421 100644
--- a/fs/erofs/super.c
+++ b/fs/erofs/super.c
@@ -526,6 +526,7 @@ static int erofs_fc_fill_super(struct super_block *sb, struct fs_context *fc)
struct inode *inode;
struct erofs_sb_info *sbi;
struct erofs_fs_context *ctx = fc->fs_private;
+ struct dax_device *dax_dev = fs_dax_get_by_bdev(sb->s_bdev);
int err;

sb->s_magic = EROFS_SUPER_MAGIC;
@@ -540,13 +541,14 @@ static int erofs_fc_fill_super(struct super_block *sb, struct fs_context *fc)
return -ENOMEM;

sb->s_fs_info = sbi;
- sbi->dax_dev = fs_dax_get_by_bdev(sb->s_bdev);
+ sbi->dax_dev = dax_dev;
err = erofs_read_superblock(sb);
if (err)
return err;

if (test_opt(ctx, DAX_ALWAYS) &&
- !bdev_dax_supported(sb->s_bdev, EROFS_BLKSIZ)) {
+ !dax_supported(dax_dev, sb->s_bdev, EROFS_BLKSIZ, 0,
+ bdev_nr_sectors(sb->s_bdev))) {
errorfc(fc, "DAX unsupported by block device. Turning off DAX.");
clear_opt(ctx, DAX_ALWAYS);
}
--
2.32.0

--
Cheers,
Stephen Rothwell

Attachment: pgpHZM2OjzZdX.pgp
Description: OpenPGP digital signature