diff options
| author | Jakub Kicinski <[email protected]> | 2025-01-16 18:30:22 +0000 |
|---|---|---|
| committer | Jakub Kicinski <[email protected]> | 2025-01-16 18:34:59 +0000 |
| commit | 2ee738e90e80850582cbe10f34c6447965c1d87b (patch) | |
| tree | 75a5d764d283bfac0648710f1e8c51680ef992fa /fs/smb/client/namespace.c | |
| parent | Merge branch 'net-stmmac-rx-performance-improvement' (diff) | |
| parent | Merge tag 'net-6.13-rc8' of git://git.kernel.org/pub/scm/linux/kernel/git/net... (diff) | |
| download | kernel-2ee738e90e80850582cbe10f34c6447965c1d87b.tar.gz kernel-2ee738e90e80850582cbe10f34c6447965c1d87b.zip | |
Merge git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net
Cross-merge networking fixes after downstream PR (net-6.13-rc8).
Conflicts:
drivers/net/ethernet/realtek/r8169_main.c
1f691a1fc4be ("r8169: remove redundant hwmon support")
152d00a91396 ("r8169: simplify setting hwmon attribute visibility")
https://lore.kernel.org/[email protected]
Adjacent changes:
drivers/net/ethernet/broadcom/bnxt/bnxt.c
152f4da05aee ("bnxt_en: add support for rx-copybreak ethtool command")
f0aa6a37a3db ("eth: bnxt: always recalculate features after XDP clearing, fix null-deref")
drivers/net/ethernet/intel/ice/ice_type.h
50327223a8bb ("ice: add lock to protect low latency interface")
dc26548d729e ("ice: Fix quad registers read on E825")
Signed-off-by: Jakub Kicinski <[email protected]>
Diffstat (limited to 'fs/smb/client/namespace.c')
| -rw-r--r-- | fs/smb/client/namespace.c | 19 |
1 files changed, 18 insertions, 1 deletions
diff --git a/fs/smb/client/namespace.c b/fs/smb/client/namespace.c index 0f788031b740..e3f9213131c4 100644 --- a/fs/smb/client/namespace.c +++ b/fs/smb/client/namespace.c @@ -196,11 +196,28 @@ static struct vfsmount *cifs_do_automount(struct path *path) struct smb3_fs_context tmp; char *full_path; struct vfsmount *mnt; + struct cifs_sb_info *mntpt_sb; + struct cifs_ses *ses; if (IS_ROOT(mntpt)) return ERR_PTR(-ESTALE); - cur_ctx = CIFS_SB(mntpt->d_sb)->ctx; + mntpt_sb = CIFS_SB(mntpt->d_sb); + ses = cifs_sb_master_tcon(mntpt_sb)->ses; + cur_ctx = mntpt_sb->ctx; + + /* + * At this point, the root session should be in the mntpt sb. We should + * bring the sb context passwords in sync with the root session's + * passwords. This would help prevent unnecessary retries and password + * swaps for automounts. + */ + mutex_lock(&ses->session_mutex); + rc = smb3_sync_session_ctx_passwords(mntpt_sb, ses); + mutex_unlock(&ses->session_mutex); + + if (rc) + return ERR_PTR(rc); fc = fs_context_for_submount(path->mnt->mnt_sb->s_type, mntpt); if (IS_ERR(fc)) |
