1. 08 Oct, 2021 2 commits
    • Arnd Bergmann's avatar
      crypto: ccree - avoid out-of-range warnings from clang · cfd6fb45
      Arnd Bergmann authored
      clang points out inconsistencies in the FIELD_PREP() invocation in
      this driver that result from the 'mask' being a 32-bit value:
      
      drivers/crypto/ccree/cc_driver.c:117:18: error: result of comparison of constant 18446744073709551615 with expression of type 'u32' (aka 'unsigned int') is always false [-Werror,-Wtautological-constant-out-of-range-compare]
              cache_params |= FIELD_PREP(mask, val);
                              ^~~~~~~~~~~~~~~~~~~~~
      include/linux/bitfield.h:94:3: note: expanded from macro 'FIELD_PREP'
                      __BF_FIELD_CHECK(_mask, 0ULL, _val, "FIELD_PREP: ");    \
                      ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
      include/linux/bitfield.h:52:28: note: expanded from macro '__BF_FIELD_CHECK'
                      BUILD_BUG_ON_MSG((_mask) > (typeof(_reg))~0ull,         \
                      ~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
      
      This does not happen in other places that just pass a constant here.
      
      Work around the warnings by widening the type of the temporary variable.
      
      Fixes: 05c2a705 ("crypto: ccree - rework cache parameters handling")
      Signed-off-by: default avatarArnd Bergmann <arnd@arndb.de>
      Acked-by: default avatarGilad ben-Yossef <gilad@benyossef.com>
      Signed-off-by: default avatarHerbert Xu <herbert@gondor.apana.org.au>
      cfd6fb45
    • Kai Ye's avatar
      crypto: hisilicon/qm - modify the uacce mode check · 183b60e0
      Kai Ye authored
      As qm should register to uacce in UACCE_DEV_SVA mode,
      this patch modifies to checks uacce mode before doing uacce
      registration.
      Signed-off-by: default avatarKai Ye <yekai13@huawei.com>
      Signed-off-by: default avatarHerbert Xu <herbert@gondor.apana.org.au>
      183b60e0
  2. 01 Oct, 2021 4 commits
  3. 24 Sep, 2021 4 commits
    • Herbert Xu's avatar
      crypto: api - Fix built-in testing dependency failures · adad556e
      Herbert Xu authored
      When complex algorithms that depend on other algorithms are built
      into the kernel, the order of registration must be done such that
      the underlying algorithms are ready before the ones on top are
      registered.  As otherwise they would fail during the self-test
      which is required during registration.
      
      In the past we have used subsystem initialisation ordering to
      guarantee this.  The number of such precedence levels are limited
      and they may cause ripple effects in other subsystems.
      
      This patch solves this problem by delaying all self-tests during
      boot-up for built-in algorithms.  They will be tested either when
      something else in the kernel requests for them, or when we have
      finished registering all built-in algorithms, whichever comes
      earlier.
      Reported-by: default avatarVladis Dronov <vdronov@redhat.com>
      Signed-off-by: default avatarHerbert Xu <herbert@gondor.apana.org.au>
      adad556e
    • Krzysztof Kozlowski's avatar
      crypto: marvell/cesa - drop unneeded MODULE_ALIAS · 7c532969
      Krzysztof Kozlowski authored
      The MODULE_DEVICE_TABLE already creates proper alias for platform
      driver.  Having another MODULE_ALIAS causes the alias to be duplicated.
      Signed-off-by: default avatarKrzysztof Kozlowski <krzysztof.kozlowski@canonical.com>
      Signed-off-by: default avatarHerbert Xu <herbert@gondor.apana.org.au>
      7c532969
    • Giovanni Cabiddu's avatar
      crypto: qat - power up 4xxx device · ca605f97
      Giovanni Cabiddu authored
      After reset or boot, QAT 4xxx devices are inactive and require to be
      explicitly activated.
      This is done by writing the DRV_ACTIVE bit in the PM_INTERRUPT register
      and polling the PM_INIT_STATE to make sure that the transaction has
      completed properly.
      
      If this is not done, the driver will fail the initialization sequence
      reporting the following message:
          [   22.081193] 4xxx 0000:f7:00.0: enabling device (0140 -> 0142)
          [   22.720285] QAT: AE0 is inactive!!
          [   22.720287] QAT: failed to get device out of reset
          [   22.720288] 4xxx 0000:f7:00.0: qat_hal_clr_reset error
          [   22.720290] 4xxx 0000:f7:00.0: Failed to init the AEs
          [   22.720290] 4xxx 0000:f7:00.0: Failed to initialise Acceleration Engine
          [   22.720789] 4xxx 0000:f7:00.0: Resetting device qat_dev0
          [   22.825099] 4xxx: probe of 0000:f7:00.0 failed with error -14
      
      The patch also temporarily disables the power management source of
      interrupt, to avoid possible spurious interrupts as the power management
      feature is not fully supported.
      
      The device init function has been added to adf_dev_init(), and not in the
      probe of 4xxx to make sure that the device is re-enabled in case of
      reset.
      
      Note that the error code reported by hw_data->init_device() in
      adf_dev_init() has been shadowed for consistency with the other calls
      in the same function.
      
      Fixes: 8c826816 ("crypto: qat - add qat_4xxx driver")
      Signed-off-by: default avatarGiovanni Cabiddu <giovanni.cabiddu@intel.com>
      Reviewed-by: default avatarWojciech Ziemba <wojciech.ziemba@intel.com>
      Signed-off-by: default avatarHerbert Xu <herbert@gondor.apana.org.au>
      ca605f97
    • Michael Walle's avatar
      crypto: caam - disable pkc for non-E SoCs · f20311cc
      Michael Walle authored
      On newer CAAM versions, not all accelerators are disabled if the SoC is
      a non-E variant. While the driver checks most of the modules for
      availability, there is one - PKHA - which sticks out. On non-E variants
      it is still reported as available, that is the number of instances is
      non-zero, but it has limited functionality. In particular it doesn't
      support encryption and decryption, but just signing and verifying. This
      is indicated by a bit in the PKHA_MISC field. Take this bit into account
      if we are checking for availability.
      
      This will the following error:
      [    8.167817] caam_jr 8020000.jr: 20000b0f: CCB: desc idx 11: : Invalid CHA selected.
      
      Tested on an NXP LS1028A (non-E) SoC.
      
      Fixes: d239b10d ("crypto: caam - add register map changes cf. Era 10")
      Signed-off-by: default avatarMichael Walle <michael@walle.cc>
      Reviewed-by: default avatarHoria Geantă <horia.geanta@nxp.com>
      Signed-off-by: default avatarHerbert Xu <herbert@gondor.apana.org.au>
      f20311cc
  4. 17 Sep, 2021 22 commits
  5. 12 Sep, 2021 8 commits
    • Linus Torvalds's avatar
      Linux 5.15-rc1 · 6880fa6c
      Linus Torvalds authored
      6880fa6c
    • Linus Torvalds's avatar
      Merge tag 'perf-tools-for-v5.15-2021-09-11' of... · b5b65f13
      Linus Torvalds authored
      Merge tag 'perf-tools-for-v5.15-2021-09-11' of git://git.kernel.org/pub/scm/linux/kernel/git/acme/linux
      
      Pull more perf tools updates from Arnaldo Carvalho de Melo:
      
       - Add missing fields and remove some duplicate fields when printing a
         perf_event_attr.
      
       - Fix hybrid config terms list corruption.
      
       - Update kernel header copies, some resulted in new kernel features
         being automagically added to 'perf trace' syscall/tracepoint argument
         id->string translators.
      
       - Add a file generated during the documentation build to .gitignore.
      
       - Add an option to build without libbfd, as some distros, like Debian
         consider its ABI unstable.
      
       - Add support to print a textual representation of IBS raw sample data
         in 'perf report'.
      
       - Fix bpf 'perf test' sample mismatch reporting
      
       - Fix passing arguments to stackcollapse report in a 'perf script'
         python script.
      
       - Allow build-id with trailing zeros.
      
       - Look for ImageBase in PE file to compute .text offset.
      
      * tag 'perf-tools-for-v5.15-2021-09-11' of git://git.kernel.org/pub/scm/linux/kernel/git/acme/linux: (25 commits)
        tools headers UAPI: Update tools's copy of drm.h headers
        tools headers UAPI: Sync drm/i915_drm.h with the kernel sources
        tools headers UAPI: Sync linux/fs.h with the kernel sources
        tools headers UAPI: Sync linux/in.h copy with the kernel sources
        perf tools: Add an option to build without libbfd
        perf tools: Allow build-id with trailing zeros
        perf tools: Fix hybrid config terms list corruption
        perf tools: Factor out copy_config_terms() and free_config_terms()
        perf tools: Fix perf_event_attr__fprintf() missing/dupl. fields
        perf tools: Ignore Documentation dependency file
        perf bpf: Provide a weak btf__load_from_kernel_by_id() for older libbpf versions
        tools include UAPI: Update linux/mount.h copy
        perf beauty: Cover more flags in the  move_mount syscall argument beautifier
        tools headers UAPI: Sync linux/prctl.h with the kernel sources
        tools include UAPI: Sync sound/asound.h copy with the kernel sources
        tools headers UAPI: Sync linux/kvm.h with the kernel sources
        tools headers UAPI: Sync x86's asm/kvm.h with the kernel sources
        perf report: Add support to print a textual representation of IBS raw sample data
        perf report: Add tools/arch/x86/include/asm/amd-ibs.h
        perf env: Add perf_env__cpuid, perf_env__{nr_}pmu_mappings
        ...
      b5b65f13
    • Linus Torvalds's avatar
      Merge tag 'compiler-attributes-for-linus-v5.15-rc1-v2' of git://github.com/ojeda/linux · c3e46874
      Linus Torvalds authored
      Pull compiler attributes updates from Miguel Ojeda:
      
       - Fix __has_attribute(__no_sanitize_coverage__) for GCC 4 (Marco Elver)
      
       - Add Nick as Reviewer for compiler_attributes.h (Nick Desaulniers)
      
       - Move __compiletime_{error|warning} (Nick Desaulniers)
      
      * tag 'compiler-attributes-for-linus-v5.15-rc1-v2' of git://github.com/ojeda/linux:
        compiler_attributes.h: move __compiletime_{error|warning}
        MAINTAINERS: add Nick as Reviewer for compiler_attributes.h
        Compiler Attributes: fix __has_attribute(__no_sanitize_coverage__) for GCC 4
      c3e46874
    • Linus Torvalds's avatar
      Merge tag 'auxdisplay-for-linus-v5.15-rc1' of git://github.com/ojeda/linux · d41adc4e
      Linus Torvalds authored
      Pull auxdisplay updates from Miguel Ojeda:
       "An assortment of improvements for auxdisplay:
      
         - Replace symbolic permissions with octal permissions (Jinchao Wang)
      
         - ks0108: Switch to use module_parport_driver() (Andy Shevchenko)
      
         - charlcd: Drop unneeded initializers and switch to C99 style (Andy
           Shevchenko)
      
         - hd44780: Fix oops on module unloading (Lars Poeschel)
      
         - Add I2C gpio expander example (Ralf Schlatterbeck)"
      
      * tag 'auxdisplay-for-linus-v5.15-rc1' of git://github.com/ojeda/linux:
        auxdisplay: Replace symbolic permissions with octal permissions
        auxdisplay: ks0108: Switch to use module_parport_driver()
        auxdisplay: charlcd: Drop unneeded initializers and switch to C99 style
        auxdisplay: hd44780: Fix oops on module unloading
        auxdisplay: Add I2C gpio expander example
      d41adc4e
    • Linus Torvalds's avatar
      Merge tag 'smp-urgent-2021-09-12' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip · f306b90c
      Linus Torvalds authored
      Pull CPU hotplug updates from Thomas Gleixner:
       "Updates for the SMP and CPU hotplug:
      
         - Remove DEFINE_SMP_CALL_CACHE_FUNCTION() which is a left over of the
           original hotplug code and now causing trouble with the ARM64 cache
           topology setup due to the pointless SMP function call.
      
           It's not longer required as the hotplug callbacks are guaranteed to
           be invoked on the upcoming CPU.
      
         - Remove the deprecated and now unused CPU hotplug functions
      
         - Rewrite the CPU hotplug API documentation"
      
      * tag 'smp-urgent-2021-09-12' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip:
        Documentation: core-api/cpuhotplug: Rewrite the API section
        cpu/hotplug: Remove deprecated CPU-hotplug functions.
        thermal: Replace deprecated CPU-hotplug functions.
        drivers: base: cacheinfo: Get rid of DEFINE_SMP_CALL_CACHE_FUNCTION()
      f306b90c
    • Linus Torvalds's avatar
      Merge tag 'char-misc-5.15-rc1-lkdtm' of... · d8e988b6
      Linus Torvalds authored
      Merge tag 'char-misc-5.15-rc1-lkdtm' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/char-misc
      
      Pull misc driver fix from Greg KH:
       "Here is a single patch for 5.15-rc1, for the lkdtm misc driver.
      
        It resolves a build issue that many people were hitting with your
        current tree, and Kees and others felt would be good to get merged
        before -rc1 comes out, to prevent them from having to constantly hit
        it as many development trees restart on -rc1, not older -rc releases.
      
        It has NOT been in linux-next, but has passed 0-day testing and looks
        'obviously correct' when reviewing it locally :)"
      
      * tag 'char-misc-5.15-rc1-lkdtm' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/char-misc:
        lkdtm: Use init_uts_ns.name instead of macros
      d8e988b6
    • Linus Torvalds's avatar
      Merge tag 'for-linus-5.15-1' of git://github.com/cminyard/linux-ipmi · 1791596b
      Linus Torvalds authored
      Pull IPMI updates from Corey Minyard:
       "A couple of very minor fixes for style and rate limiting.
      
        Nothing big, but probably needs to go in"
      
      * tag 'for-linus-5.15-1' of git://github.com/cminyard/linux-ipmi:
        char: ipmi: use DEVICE_ATTR helper macro
        ipmi: rate limit ipmi smi_event failure message
      1791596b
    • Linus Torvalds's avatar
      Merge tag 'sched_urgent_for_v5.15_rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip · 56c24438
      Linus Torvalds authored
      Pull scheduler fixes from Borislav Petkov:
      
       - Make sure the idle timer expires in hardirq context, on PREEMPT_RT
      
       - Make sure the run-queue balance callback is invoked only on the
         outgoing CPU
      
      * tag 'sched_urgent_for_v5.15_rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip:
        sched: Prevent balance_push() on remote runqueues
        sched/idle: Make the idle timer expire in hard interrupt context
      56c24438