ACK/cmnt: [Pull Request v2] [hirsute:linux-azure] Update CIFS to v5.15-rc3

Kleber Souza kleber.souza at canonical.com
Tue Nov 2 14:24:28 UTC 2021


On 02.11.21 12:47, Tim Gardner wrote:
> 
> BugLink: https://bugs.launchpad.net/bugs/1947027
> 
> SRU Justification
> 
> [Impact]
> 
> Microsoft has requested an update to the CIFS file system to v5.15-rc3.
> This patch set was developed by first reverting all stable patches to
> fs/cifs,
> then cherry-picking relevant patches from upstream fs/cifs while making
> sure that
> all reverted stable patches were recoved from clean upstream
> cherry-picks. Some
> of the original stable patches are backports with slight context adjustments
> that wouldn't allow a clean upstream cherry-pick series.
> 
> [Test Case]
> 
> Steven French of Microsoft tested and verified.
> 
> [Where things might go wrong]
> 
> CIFS connections could fail.
> 
> [Other Info]
> 
> SF: #00316229
> 
> ----------------------------------------------------------------
> The following changes since commit 6823f3d7556a0d375be0b9ccf5a46632276a2d6b:
> 
>     UBUNTU: Ubuntu-azure-5.11.0-1021.22 (2021-10-22 09:33:36 -0700)
> 
> are available in the Git repository at:
> 
>   
> git+ssh://timg-tpi@git.launchpad.net/~timg-tpi/ubuntu/+source/linux/+git/hirsute

The branch for fetching should be 'hirsute-cifs-5.11-backport-sf00316229'.



Acked-by: Kleber Sacilotto de Souza <kleber.souza at canonical.com>

Thanks


> 
> 
> for you to fetch changes up to a2055c1a80b28f428684c2dfbe32cf9197182fd7:
> 
>     cifs: fix incorrect check for null pointer in header_assemble
> (2021-10-29 06:00:35 -0600)
> 
> ----------------------------------------------------------------
> Al Viro (9):
>         cifs_debug: use %pd instead of messing with ->d_name
>         do_cifs_create(): don't set ->i_mode of something we had not created
>         cifs: have ->mkdir() handle race with another client sanely
>         cifs: don't cargo-cult strndup()
>         cifs: constify get_normalized_path() properly
>         cifs: constify path argument of ->make_node()
>         cifs: constify pathname arguments in a bunch of helpers
>         cifs: make build_path_from_dentry() return const char *
>         cifs: switch build_path_from_dentry() to using dentry_path_raw()
> 
> Aurelien Aptel (13):
>         cifs: fix credit accounting for extra channel
>         cifs: ask for more credit on async read/write code paths
>         cifs: warn and fail if trying to use rootfs without the config option
>         cifs: simplify SWN code with dummy funcs instead of ifdefs
>         cifs: remove old dead code
>         cifs: make fs_context error logging wrapper
>         cifs: add fs_context param to parsing helpers
>         cifs: log mount errors using cifs_errorf()
>         cifs: export supported mount options via new mount_params /proc file
>         smb2: fix use-after-free in smb2_ioctl_query_info()
>         cifs: set server->cipher_type to AES-128-CCM for SMB3.0
>         cifs: change format of CIFS_FULL_KEY_DUMP ioctl
>         cifs: fix ipv6 formating in cifs_ses_add_channel
> 
> Baokun Li (3):
>         cifs: fix doc warnings in cifs_dfs_ref.c
>         cifs: convert list_for_each to entry variant in smb2misc.c
>         cifs: convert list_for_each to entry variant in cifs_debug.c
> 
> Colin Ian King (1):
>         cifs: remove redundant initialization of variable rc
> 
> Dan Carpenter (2):
>         cifs: fix NULL dereference in smb2_check_message()
>         cifs: fix a sign extension bug
> 
> David Disseldorp (1):
>         cifs: fix leak in cifs_smb3_do_mount() ctx
> 
> David Howells (2):
>         cifs: use discard iterator to discard unneeded network data more
> efficiently
>         cifs: Deal with some warnings from W=1
> 
> Ding Hui (1):
>         cifs: fix wrong release in sess_alloc_buffer() failed path
> 
> Enzo Matsumiya (1):
>         cifs: properly invalidate cached root handle when closing it
> 
> Eugene Korenevsky (1):
>         cifs: fix out-of-bound memory access when calling smb3_notify()
> at mount point
> 
> Gustavo A. R. Silva (1):
>         cifs: cifspdu.h: Replace one-element array with flexible-array member
> 
> Hyunchul Lee (1):
>         cifs: fix the out of range assignment to bit fields in
> parse_server_interfaces
> 
> Jiapeng Chong (2):
>         cifs: Remove useless variable
>         cifs: Fix inconsistent indenting
> 
> Kees Cook (1):
>         cifs: Avoid field over-reading memcpy()
> 
> Khaled ROMDHANI (1):
>         fs/cifs: Fix resource leak
> 
> Len Baker (1):
>         CIFS: Fix a potencially linear read overflow
> 
> Liu xuzhi (1):
>         fs/cifs/: fix misspellings using codespell tool
> 
> Maciek Borzecki (1):
>         cifs: escape spaces in share names
> 
> Muhammad Usama Anjum (1):
>         cifs: remove unnecessary copies of tcon->crfid.fid
> 
> Paul Aurich (1):
>         cifs: Return correct error code from smb2_get_enc_key
> 
> Paulo Alcantara (23):
>         cifs: fix nodfs mount option
>         cifs: fix DFS failover
>         cifs: check all path components in resolved dfs target
>         cifs: introduce helper for finding referral server to improve DFS
> target resolution
>         cifs: print MIDs in decimal notation
>         cifs: change noisy error message to FYI
>         cifs: return proper error code in statfs(2)
>         cifs: do not send close in compound create+close requests
>         cifs: fix regression when mounting shares with prefix paths
>         cifs: do not send tree disconnect to ipc shares
>         cifs: get rid of @noreq param in __dfs_cache_find()
>         cifs: keep referral server sessions alive
>         cifs: handle different charsets in dfs cache
>         cifs: fix path comparison and hash calc
>         cifs: set a minimum of 2 minutes for refreshing dfs cache
>         cifs: do not share tcp servers with dfs mounts
>         cifs: avoid starvation when refreshing dfs cache
>         cifs: fix check of dfs interlinks
>         cifs: prevent NULL deref in cifs_compose_mount_options()
>         cifs: handle reconnect of tcon when there is no cached dfs referral
>         cifs: do not share tcp sessions of dfs connections
>         cifs: support share failover when remounting
>         cifs: fix signed integer overflow when fl_end is OFFSET_MAX
> 
> Rikard Falkeborn (1):
>         cifs: Constify static struct genl_ops
> 
> Rohith Surabattula (11):
>         TCON Reconnect during STATUS_NETWORK_NAME_DELETED
>         cifs: Deferred close for files
>         Cifs: Fix kernel oops caused by deferred close for files.
>         Fix kernel oops when CONFIG_DEBUG_ATOMIC_SLEEP is enabled.
>         Defer close only when lease is enabled.
>         Fix KASAN identified use-after-free issue.
>         cifs: Handle race conditions during rename
>         cifs: Call close synchronously during unlink/rename/lease break.
>         cifs: Deferred close performance improvements
>         cifs: Fix soft lockup during fsstress
>         cifs: Not to defer close on file when lock is set
> 
> Ronnie Sahlberg (23):
>         cifs: fix handling of escaped ',' in the password mount argument
>         cifs: revalidate mapping when we open files for SMB1 POSIX
>         cifs: move the check for nohandlecache into open_shroot
>         cifs: pass a path to open_shroot and check if it is the root or not
>         cifs: rename the *_shroot* functions to *_cached_dir*
>         cifs: store a pointer to the root dentry in cifs_sb_info once we
> have completed mounting the share
>         cifs: Grab a reference for the dentry of the cached directory
> during the lifetime of the cache
>         cifs: add a function to get a cached dir based on its dentry
>         cifs: add a timestamp to track when the lease of the cached dir
> was taken
>         cifs: pass the dentry instead of the inode down to the
> revalidation check functions
>         cifs: check the timestamp for the cached dirent when deciding on
> revalidate
>         cifs: add support for FALLOC_FL_COLLAPSE_RANGE
>         cifs: add FALLOC_FL_INSERT_RANGE support
>         cifs: fix memory leak in smb2_copychunk_range
>         cifs: improve fallocate emulation
>         cifs: avoid extra calls in posix_info_parse
>         cifs: use helpers when parsing uid/gid mount options and validate
> them
>         cifs: Do not use the original cruid when following DFS links for
> multiuser mounts
>         cifs: only write 64kb at a time when fallocating a small region
> of a file
>         cifs: fix fallocate when trying to allocate a hole.
>         cifs: add missing parsing of backupuid
>         cifs: use the correct max-length for dentry_path_raw()
>         cifs: Do not leak EDEADLK to dgetents64 for
> STATUS_USER_SESSION_DELETED
> 
> Shyam Prasad N (20):
>         cifs: New optype for session operations.
>         cifs: Fix in error types returned for out-of-credit situations.
>         cifs: Identify a connection by a conn_id.
>         cifs: Reformat DebugData and index connections by conn_id.
>         cifs: Fix cifsacl ACE mask for group and others.
>         cifs: Retain old ACEs when converting between mode bits and ACL.
>         cifs: Change SIDs in ACEs while transferring file ownership.
>         cifs: If a corrupted DACL is returned by the server, bail out.
>         cifs: update new ACE pointer after populate_new_aces.
>         cifs: Adjust key sizes and key generation routines for AES256
> encryption
>         cifs: Fix chmod with modefromsid when an older ACE already exists.
>         cifs: On cifs_reconnect, resolve the hostname again.
>         cifs: detect dead connections only when echoes are enabled.
>         cifs: use echo_interval even when connection not ready.
>         cifs: fix string declarations and assignments in tracepoints
>         cifs: missed ref-counting smb session in find
>         cifs: use the expiry output of dns_query to schedule next resolution
>         cifs: added WARN_ON for all the count decrements
>         cifs: create sd context must be a multiple of 8
>         cifs: enable fscache usage even for files opened as rw
> 
> Steve French (68):
>         smb3: negotiate current dialect (SMB3.1.1) when version 3 or
> greater requested
>         cifs: fix trivial typo
>         cifs: change confusing field serverName (to ip_addr)
>         cifs: clarify hostname vs ip address in /proc/fs/cifs/DebugData
>         cifs: cleanup a few le16 vs. le32 uses in cifsacl.c
>         cifs: minor simplification to smb2_is_network_name_deleted
>         cifs: Add new mount parameter "acdirmax" to allow caching
> directory metadata
>         cifs: convert revalidate of directories to using directory
> metadata cache timeout
>         cifs: Add new parameter "acregmax" for distinct file and
> directory metadata timeout
>         cifs: update internal version number
>         cifs: fix allocation size on newly created files
>         smb3: fix cached file size problems in duplicate extents (reflink)
>         cifs: correct comments explaining internal semaphore usage in the
> module
>         smb3: update protocol header definitions based to include new flags
>         SMB3: update structures for new compression protocol definitions
>         cifs: allocate buffer in the caller of build_path_from_dentry()
>         smb3: limit noisy error
>         smb3: add rasize mount parameter to improve readahead performance
>         cifs: update internal version number
>         smb3.1.1: enable negotiating stronger encryption by default
>         cifs: add shutdown support
>         smb3.1.1: allow dumping GCM256 keys to improve debugging of
> encrypted shares
>         smb3.1.1: allow dumping keys for multiuser mounts
>         smb3: when mounting with multichannel include it in requested
> capabilities
>         smb3: do not attempt multichannel to server which does not support it
>         smb3: if max_channels set to more than one channel request
> multichannel
>         SMB3: incorrect file id in requests compounded with open
>         cifs: remove duplicated prototype
>         cifs: enable extended stats by default
>         cifs: use SPDX-Licence-Identifier
>         cifs: fix unneeded null check
>         smb3: fix uninitialized value for port in witness protocol move
>         cifs: fix SMB1 error path in cifs_get_file_info_unix
>         smb311: remove dead code for non compounded posix query info
>         smbdirect: missing rc checks while waiting for rdma events
>         SMB3: Add new info level for query directory
>         cifs: remove two cases where rc is set unnecessarily in sid_to_id
>         cifs: missing null check for newinode pointer
>         smb3: fix possible access to uninitialized pointer to DACL
>         cifs: missing null pointer check in cifs_mount
>         cifs: fix missing spinlock around update to ses->status
>         smb3: prevent races updating CurrentMid
>         cifs: make locking consistent around the server session status
>         cifs: clarify SMB1 code for UnixCreateHardLink
>         CIFS: Clarify SMB1 code for UnixCreateSymLink
>         CIFS: Clarify SMB1 code for UnixSetPathInfo
>         smb3: fix typo in header file
>         CIFS: Clarify SMB1 code for SetFileSize
>         CIFS: Clarify SMB1 code for delete
>         CIFS: Clarify SMB1 code for rename open file
>         CIFS: Clarify SMB1 code for POSIX Lock
>         SMB3.1.1: Add support for negotiating signing algorithm
>         cifs: update internal version number
>         cifs: fix missing null session check in mount
>         SMB3.1.1: fix mount failure to some servers when compression enabled
>         CIFS: Clarify SMB1 code for POSIX Create
>         CIFS: Clarify SMB1 code for POSIX delete file
>         SMB3: fix readpage for large swap cache
>         smb3: rc uninitialized in one fallocate path
>         cifs: avoid signed integer overflow in calculating blocks
>         smb3: fix posix extensions mount option
>         cifs: update FSCTL definitions
>         cifs: remove pathname for file from SPDX header
>         cifs: fix incorrect kernel doc comments
>         cifs: Clear modified attribute bit from inode flags
>         smb3: correct smb3 ACL security descriptor
>         smb3: correct server pointer dereferencing check to be more
> consistent
>         cifs: fix incorrect check for null pointer in header_assemble
> 
> Thiago Rafael Becker (1):
>         cifs: retry lookup and readdir when EAGAIN is returned.
> 
> Tim Gardner (50):
>         Revert "CIFS: Fix a potencially linear read overflow"
>         Revert "smb3: fix posix extensions mount option"
>         Revert "cifs: create sd context must be a multiple of 8"
>         Revert "smb3: rc uninitialized in one fallocate path"
>         Revert "cifs: add missing parsing of backupuid"
>         Revert "cifs: use helpers when parsing uid/gid mount options and
> validate them"
>         Revert "SMB3: fix readpage for large swap cache"
>         Revert "cifs: fix the out of range assignment to bit fields in
> parse_server_interfaces"
>         Revert "cifs: fix fallocate when trying to allocate a hole."
>         Revert "cifs: only write 64kb at a time when fallocating a small
> region of a file"
>         Revert "cifs: prevent NULL deref in cifs_compose_mount_options()"
>         Revert "cifs: Do not use the original cruid when following DFS
> links for multiuser mounts"
>         Revert "cifs: use the expiry output of dns_query to schedule next
> resolution"
>         Revert "cifs: handle reconnect of tcon when there is no cached
> dfs referral"
>         Revert "smb3: fix uninitialized value for port in witness
> protocol move"
>         Revert "cifs: fix check of dfs interlinks"
>         Revert "cifs: fix missing spinlock around update to ses->status"
>         Revert "cifs: improve fallocate emulation"
>         Revert "SMB3: incorrect file id in requests compounded with open"
>         Revert "cifs: set server->cipher_type to AES-128-CCM for SMB3.0"
>         Revert "cifs: fix memory leak in smb2_copychunk_range"
>         Revert "smb3: do not attempt multichannel to server which does
> not support it"
>         Revert "smb3: if max_channels set to more than one channel
> request multichannel"
>         Revert "smb3: when mounting with multichannel include it in
> requested capabilities"
>         Revert "smb2: fix use-after-free in smb2_ioctl_query_info()"
>         Revert "cifs: fix regression when mounting shares with prefix paths"
>         Revert "cifs: detect dead connections only when echoes are enabled."
>         Revert "cifs: fix leak in cifs_smb3_do_mount() ctx"
>         Revert "cifs: fix out-of-bound memory access when calling
> smb3_notify() at mount point"
>         Revert "cifs: Return correct error code from smb2_get_enc_key"
>         Revert "cifs: On cifs_reconnect, resolve the hostname again."
>         Revert "cifs: escape spaces in share names"
>         Revert "cifs: Silently ignore unknown oplock break handle"
>         Revert "cifs: revalidate mapping when we open files for SMB1 POSIX"
>         Revert "cifs: Adjust key sizes and key generation routines for
> AES256 encryption"
>         Revert "smb3: fix cached file size problems in duplicate extents
> (reflink)"
>         Revert "cifs: change noisy error message to FYI"
>         Revert "cifs: ask for more credit on async read/write code paths"
>         Revert "cifs: Fix preauth hash corruption"
>         Revert "cifs: fix allocation size on newly created files"
>         Revert "cifs: warn and fail if trying to use rootfs without the
> config option"
>         Revert "cifs: do not send close in compound create+close requests"
>         Revert "cifs: return proper error code in statfs(2)"
>         Revert "cifs: fix credit accounting for extra channel"
>         Revert "cifs: fix handling of escaped ',' in the password mount
> argument"
>         Revert "cifs: fix nodfs mount option"
>         Revert "cifs: introduce helper for finding referral server to
> improve DFS target resolution"
>         Revert "cifs: check all path components in resolved dfs target"
>         Revert "cifs: fix DFS failover"
>         Revert "cifs: Fix inconsistent IS_ERR and PTR_ERR"
> 
> Vincent Whitchurch (2):
>         cifs: Fix preauth hash corruption
>         cifs: Silently ignore unknown oplock break handle
> 
> Wan Jiabing (2):
>         fs: cifs: Remove unnecessary struct declaration
>         fs: cifs: Remove repeated struct declaration
> 
> YueHaibing (2):
>         cifs: Fix inconsistent IS_ERR and PTR_ERR
>         cifs: Remove unused inline function is_sysvol_or_netlogon()
> 
> jack1.li_cp (1):
>         cifs: Fix spelling of 'security'
> 
> wenhuizhang (1):
>         cifs: remove deadstore in cifs_close_all_deferred_files()
> 
>    fs/cifs/Kconfig         |    4 +-
>    fs/cifs/cache.c         |   16 +-
>    fs/cifs/cifs_debug.c    |  206 +++++---
>    fs/cifs/cifs_debug.h    |    2 +-
>    fs/cifs/cifs_dfs_ref.c  |   16 +-
>    fs/cifs/cifs_fs_sb.h    |   24 +-
>    fs/cifs/cifs_ioctl.h    |   60 ++-
>    fs/cifs/cifs_spnego.c   |   16 +-
>    fs/cifs/cifs_spnego.h   |   16 +-
>    fs/cifs/cifs_swn.c      |    2 +-
>    fs/cifs/cifs_swn.h      |   27 ++
>    fs/cifs/cifs_unicode.c  |    1 -
>    fs/cifs/cifsacl.c       |  398 ++++++++++++----
>    fs/cifs/cifsacl.h       |   20 +-
>    fs/cifs/cifsencrypt.c   |   21 +-
>    fs/cifs/cifsfs.c        |   93 ++--
>    fs/cifs/cifsfs.h        |   17 +-
>    fs/cifs/cifsglob.h      |  104 ++--
>    fs/cifs/cifspdu.h       |   21 +-
>    fs/cifs/cifsproto.h     |   63 +--
>    fs/cifs/cifssmb.c       |  113 ++---
>    fs/cifs/connect.c       |  314 +++++++------
>    fs/cifs/dfs_cache.c     | 1200
> ++++++++++++++++++++++++-----------------------
>    fs/cifs/dfs_cache.h     |   48 +-
>    fs/cifs/dir.c           |  207 ++++----
>    fs/cifs/dns_resolve.c   |   15 +-
>    fs/cifs/dns_resolve.h   |   18 +-
>    fs/cifs/export.c        |   15 +-
>    fs/cifs/file.c          |  227 ++++++---
>    fs/cifs/fs_context.c    |  177 ++++---
>    fs/cifs/fs_context.h    |   19 +-
>    fs/cifs/fscache.c       |   57 ++-
>    fs/cifs/fscache.h       |   39 +-
>    fs/cifs/inode.c         |  243 ++++++----
>    fs/cifs/ioctl.c         |  209 ++++++++-
>    fs/cifs/link.c          |   72 +--
>    fs/cifs/misc.c          |  193 +++++++-
>    fs/cifs/netlink.c       |    2 +-
>    fs/cifs/netmisc.c       |    1 -
>    fs/cifs/ntlmssp.h       |   15 +-
>    fs/cifs/readdir.c       |   55 ++-
>    fs/cifs/rfc1002pdu.h    |   15 +-
>    fs/cifs/sess.c          |   21 +-
>    fs/cifs/smb1ops.c       |    6 +-
>    fs/cifs/smb2file.c      |   17 +-
>    fs/cifs/smb2glob.h      |   12 +-
>    fs/cifs/smb2inode.c     |   25 +-
>    fs/cifs/smb2maperror.c  |   14 +-
>    fs/cifs/smb2misc.c      |   56 +--
>    fs/cifs/smb2ops.c       |  309 ++++++++++--
>    fs/cifs/smb2pdu.c       |  163 +++++--
>    fs/cifs/smb2pdu.h       |  111 ++++-
>    fs/cifs/smb2proto.h     |   33 +-
>    fs/cifs/smb2status.h    |   15 +-
>    fs/cifs/smb2transport.c |   27 +-
>    fs/cifs/smbdirect.c     |   14 +-
>    fs/cifs/smberr.h        |   15 +-
>    fs/cifs/smbfsctl.h      |   28 +-
>    fs/cifs/trace.h         |   65 ++-
>    fs/cifs/transport.c     |   80 ++--
>    fs/cifs/unc.c           |    4 +-
>    fs/cifs/winucase.c      |    1 -
>    fs/cifs/xattr.c         |   59 ++-
>    63 files changed, 3231 insertions(+), 2225 deletions(-)
> 




More information about the kernel-team mailing list