1. 17 Mar, 2023 31 commits
  2. 10 Mar, 2023 4 commits
  3. 07 Mar, 2023 1 commit
  4. 06 Mar, 2023 1 commit
    • Greg Kroah-Hartman's avatar
      driver core: remove CONFIG_SYSFS_DEPRECATED and CONFIG_SYSFS_DEPRECATED_V2 · 721da5ce
      Greg Kroah-Hartman authored
      CONFIG_SYSFS_DEPRECATED was added in commit 88a22c98
      ("CONFIG_SYSFS_DEPRECATED") in 2006 to allow systems with older versions
      of some tools (i.e. Fedora 3's version of udev) to boot properly.  Four
      years later, in 2010, the option was attempted to be removed as most of
      userspace should have been fixed up properly by then, but some kernel
      developers clung to those old systems and refused to update, so we added
      CONFIG_SYSFS_DEPRECATED_V2 in commit e52eec13 ("SYSFS: Allow boot
      time switching between deprecated and modern sysfs layout") to allow
      them to continue to boot properly, and we allowed a boot time parameter
      to be used to switch back to the old format if needed.
      
      Over time, the logic that was covered under these config options was
      slowly removed from individual driver subsystems successfully, removed,
      and the only thing that is now left in the kernel are some changes in
      the block layer's representation in sysfs where real directories are
      used instead of symlinks like normal.
      
      Because the original changes were done to userspace tools in 2006, and
      all distros that use those tools are long end-of-life, and older
      non-udev-based systems do not care about the block layer's sysfs
      representation, it is time to finally remove this old logic and the
      config entries from the kernel.
      
      Cc: Jonathan Corbet <corbet@lwn.net>
      Cc: "Rafael J. Wysocki" <rafael@kernel.org>
      Cc: linux-block@vger.kernel.org
      Cc: linux-doc@vger.kernel.org
      Acked-by: default avatarJens Axboe <axboe@kernel.dk>
      Link: https://lore.kernel.org/r/20230223073326.2073220-1-gregkh@linuxfoundation.orgSigned-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      721da5ce
  5. 05 Mar, 2023 3 commits
    • Linus Torvalds's avatar
      Linux 6.3-rc1 · fe15c26e
      Linus Torvalds authored
      fe15c26e
    • Linus Torvalds's avatar
      cpumask: re-introduce constant-sized cpumask optimizations · 596ff4a0
      Linus Torvalds authored
      Commit aa47a7c2 ("lib/cpumask: deprecate nr_cpumask_bits") resulted
      in the cpumask operations potentially becoming hugely less efficient,
      because suddenly the cpumask was always considered to be variable-sized.
      
      The optimization was then later added back in a limited form by commit
      6f9c07be ("lib/cpumask: add FORCE_NR_CPUS config option"), but that
      FORCE_NR_CPUS option is not useful in a generic kernel and more of a
      special case for embedded situations with fixed hardware.
      
      Instead, just re-introduce the optimization, with some changes.
      
      Instead of depending on CPUMASK_OFFSTACK being false, and then always
      using the full constant cpumask width, this introduces three different
      cpumask "sizes":
      
       - the exact size (nr_cpumask_bits) remains identical to nr_cpu_ids.
      
         This is used for situations where we should use the exact size.
      
       - the "small" size (small_cpumask_bits) is the NR_CPUS constant if it
         fits in a single word and the bitmap operations thus end up able
         to trigger the "small_const_nbits()" optimizations.
      
         This is used for the operations that have optimized single-word
         cases that get inlined, notably the bit find and scanning functions.
      
       - the "large" size (large_cpumask_bits) is the NR_CPUS constant if it
         is an sufficiently small constant that makes simple "copy" and
         "clear" operations more efficient.
      
         This is arbitrarily set at four words or less.
      
      As a an example of this situation, without this fixed size optimization,
      cpumask_clear() will generate code like
      
              movl    nr_cpu_ids(%rip), %edx
              addq    $63, %rdx
              shrq    $3, %rdx
              andl    $-8, %edx
              callq   memset@PLT
      
      on x86-64, because it would calculate the "exact" number of longwords
      that need to be cleared.
      
      In contrast, with this patch, using a MAX_CPU of 64 (which is quite a
      reasonable value to use), the above becomes a single
      
      	movq $0,cpumask
      
      instruction instead, because instead of caring to figure out exactly how
      many CPU's the system has, it just knows that the cpumask will be a
      single word and can just clear it all.
      
      Note that this does end up tightening the rules a bit from the original
      version in another way: operations that set bits in the cpumask are now
      limited to the actual nr_cpu_ids limit, whereas we used to do the
      nr_cpumask_bits thing almost everywhere in the cpumask code.
      
      But if you just clear bits, or scan for bits, we can use the simpler
      compile-time constants.
      
      In the process, remove 'cpumask_complement()' and 'for_each_cpu_not()'
      which were not useful, and which fundamentally have to be limited to
      'nr_cpu_ids'.  Better remove them now than have somebody introduce use
      of them later.
      
      Of course, on x86-64 with MAXSMP there is no sane small compile-time
      constant for the cpumask sizes, and we end up using the actual CPU bits,
      and will generate the above kind of horrors regardless.  Please don't
      use MAXSMP unless you really expect to have machines with thousands of
      cores.
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      596ff4a0
    • Linus Torvalds's avatar
      Merge tag 'v6.3-p2' of git://git.kernel.org/pub/scm/linux/kernel/git/herbert/crypto-2.6 · f915322f
      Linus Torvalds authored
      Pull crypto fix from Herbert Xu:
       "Fix a regression in the caam driver"
      
      * tag 'v6.3-p2' of git://git.kernel.org/pub/scm/linux/kernel/git/herbert/crypto-2.6:
        crypto: caam - Fix edesc/iv ordering mixup
      f915322f