public inbox for linux-next@vger.kernel.org 
 help / color / mirror / Atom feed
From: Stephen Rothwell <sfr@canb•auug.org.au>
To: David Sterba <dsterba@suse•cz>,
	Andrew Morton <akpm@linux-foundation•org>
Cc: Christoph Hellwig <hch@lst•de>, David Sterba <dsterba@suse•com>,
	Linux Kernel Mailing List <linux-kernel@vger•kernel.org>,
	Linux Next Mailing List <linux-next@vger•kernel.org>,
	Qi Zheng <zhengqi.arch@bytedance•com>
Subject: Re: linux-next: manual merge of the btrfs tree with the mm tree
Date: Fri, 15 Sep 2023 09:47:31 +1000	[thread overview]
Message-ID: <20230915094731.076a3e98@canb.auug.org.au> (raw)
In-Reply-To: <20230915091421.58207f2c@canb.auug.org.au>

[-- Attachment #1: Type: text/plain, Size: 1934 bytes --]

Hi all,

[Forgot the diff ...]

On Fri, 15 Sep 2023 09:14:21 +1000 Stephen Rothwell <sfr@canb•auug.org.au> wrote:
> 
> Today's linux-next merge of the btrfs tree got a conflict in:
> 
>   fs/btrfs/super.c
> 
> between commit:
> 
>   c0824542e4d1 ("fs: super: dynamically allocate the s_shrink")
> 
> from the mm tree and commit:
> 
>   2ebed4689ba2 ("btrfs: open block devices after superblock creation")
> 
> from the btrfs tree.
> 
> I fixed it up (see below) and can carry the fix as necessary. This
> is now fixed as far as linux-next is concerned, but any non trivial
> conflicts should be mentioned to your upstream maintainer when your tree
> is submitted for merging.  You may also want to consider cooperating
> with the maintainer of the conflicting tree to minimise any particularly
> complex conflicts.

-- 
Cheers,
Stephen Rothwell

diff --cc fs/btrfs/super.c
index 3b165d9967bb,3eff75e06a57..000000000000
--- a/fs/btrfs/super.c
+++ b/fs/btrfs/super.c
@@@ -1518,8 -1459,23 +1459,23 @@@ static struct dentry *btrfs_mount_root(
  		if ((flags ^ s->s_flags) & SB_RDONLY)
  			error = -EBUSY;
  	} else {
- 		snprintf(s->s_id, sizeof(s->s_id), "%pg", bdev);
+ 		struct btrfs_fs_devices *fs_devices = fs_info->fs_devices;
+ 
+ 		mutex_lock(&uuid_mutex);
+ 		error = btrfs_open_devices(fs_devices, sb_open_mode(flags),
+ 					   fs_type);
+ 		mutex_unlock(&uuid_mutex);
+ 		if (error)
+ 			goto error_deactivate;
+ 
+ 		if (!(flags & SB_RDONLY) && fs_devices->rw_devices == 0) {
+ 			error = -EACCES;
+ 			goto error_deactivate;
+ 		}
+ 
+ 		snprintf(s->s_id, sizeof(s->s_id), "%pg",
+ 			 fs_devices->latest_dev->bdev);
 -		shrinker_debugfs_rename(&s->s_shrink, "sb-%s:%s", fs_type->name,
 +		shrinker_debugfs_rename(s->s_shrink, "sb-%s:%s", fs_type->name,
  					s->s_id);
  		btrfs_sb(s)->bdev_holder = fs_type;
  		error = btrfs_fill_super(s, fs_devices, data);

[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 488 bytes --]

  reply	other threads:[~2023-09-14 23:47 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-09-14 23:14 linux-next: manual merge of the btrfs tree with the mm tree Stephen Rothwell
2023-09-14 23:47 ` Stephen Rothwell [this message]
2023-09-15  2:17   ` Qi Zheng
  -- strict thread matches above, loose matches on Subject: below --
2023-09-26  0:17 Stephen Rothwell
2023-06-04 23:08 Stephen Rothwell
2023-06-27  0:45 ` Stephen Rothwell

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20230915094731.076a3e98@canb.auug.org.au \
    --to=sfr@canb$(echo .)auug.org.au \
    --cc=akpm@linux-foundation$(echo .)org \
    --cc=dsterba@suse$(echo .)com \
    --cc=dsterba@suse$(echo .)cz \
    --cc=hch@lst$(echo .)de \
    --cc=linux-kernel@vger$(echo .)kernel.org \
    --cc=linux-next@vger$(echo .)kernel.org \
    --cc=zhengqi.arch@bytedance$(echo .)com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox