1. 11 Jun, 2021 2 commits
    • Tushar Sugandhi's avatar
      IMA: support for duplicate measurement records · 52c20839
      Tushar Sugandhi authored
      IMA measures contents of a given file/buffer/critical-data record,
      and properly re-measures it on change.  However, IMA does not measure
      the duplicate value for a given record, since TPM extend is a very
      expensive operation.  For example, if the record changes from value
      'v#1' to 'v#2', and then back to 'v#1', IMA will not measure and log
      the last change to 'v#1', since the hash of 'v#1' for that record is
      already present in the IMA htable.  This limits the ability of an
      external attestation service to accurately determine the current state
      of the system.  The service would incorrectly conclude that the latest
      value of the given record on the system is 'v#2', and act accordingly.
      
      Define and use a new Kconfig option IMA_DISABLE_HTABLE to permit
      duplicate records in the IMA measurement list.
      
      In addition to the duplicate measurement records described above,
      other duplicate file measurement records may be included in the log,
      when CONFIG_IMA_DISABLE_HTABLE is enabled.  For example,
          - i_version is not enabled,
          - i_generation changed,
          - same file present on different filesystems,
          - an inode is evicted from dcache
      Signed-off-by: default avatarTushar Sugandhi <tusharsu@linux.microsoft.com>
      Reviewed-by: default avatarPetr Vorel <pvorel@suse.cz>
      [zohar@linux.ibm.com: updated list of duplicate measurement records]
      Signed-off-by: default avatarMimi Zohar <zohar@linux.ibm.com>
      52c20839
    • Lakshmi Ramasubramanian's avatar
      ima: Fix warning: no previous prototype for function 'ima_add_kexec_buffer' · c6791349
      Lakshmi Ramasubramanian authored
      The function prototype for ima_add_kexec_buffer() is present
      in 'linux/ima.h'.  But this header file is not included in
      ima_kexec.c where the function is implemented.  This results
      in the following compiler warning when "-Wmissing-prototypes" flag
      is turned on:
      
        security/integrity/ima/ima_kexec.c:81:6: warning: no previous prototype
        for function 'ima_add_kexec_buffer' [-Wmissing-prototypes]
      
      Include the header file 'linux/ima.h' in ima_kexec.c to fix
      the compiler warning.
      
      Fixes: dce92f6b (arm64: Enable passing IMA log to next kernel on kexec)
      Reported-by: default avatarkernel test robot <lkp@intel.com>
      Signed-off-by: default avatarLakshmi Ramasubramanian <nramas@linux.microsoft.com>
      Acked-by: default avatarRob Herring <robh@kernel.org>
      Signed-off-by: default avatarMimi Zohar <zohar@linux.ibm.com>
      c6791349
  2. 10 Jun, 2021 1 commit
  3. 09 Jun, 2021 1 commit
  4. 08 Jun, 2021 5 commits
  5. 03 Jun, 2021 3 commits
    • Mimi Zohar's avatar
      Merge branch 'verify-evm-portable-sig-v2' into next-integrity · dc0983f2
      Mimi Zohar authored
      From the cover letter:
      
      The recent patch set 'evm: Improve usability of portable signatures' added
      the possibility to include EVM portable signatures in the IMA measurement
      list.
      
      However, the information necessary to verify the signature were not
      included in the IMA measurement list. This patch set introduces new
      template fields to accomplish this goal:
      
      - 'iuid': the inode UID;
      - 'igid': the inode GID;
      - 'imode': the inode mode;
      - 'xattrnames': a list of xattr names (separated by |), only if the xattr is
        present;
      - 'xattrlengths': a list of xattr lengths (u32), only if the xattr is present;
      - 'xattrvalues': a list of xattr values;
      
      Patch 1 adds an helper function to show integers in the measurement list.
      Patches 2, 3 and 5 introduce new template fields. Patch 4 make it possible
      to verify EVM portable signatures which protect xattrs belonging to LSMs
      not enabled in the target platform. Patch 6 introduces the new IMA template
      evm-sig. Patch 7 fixes a small issue in evm_write_xattrs() when audit is
      not enabled.
      
      Link: https://lore.kernel.org/linux-integrity/20210528073812.407936-1-roberto.sassu@huawei.com/
      dc0983f2
    • Roberto Sassu's avatar
      evm: Don't return an error in evm_write_xattrs() if audit is not enabled · d721c15f
      Roberto Sassu authored
      This patch avoids that evm_write_xattrs() returns an error when audit is
      not enabled. The ab variable can be NULL and still be passed to the other
      audit_log_() functions, as those functions do not include any instruction.
      Signed-off-by: default avatarRoberto Sassu <roberto.sassu@huawei.com>
      Signed-off-by: default avatarMimi Zohar <zohar@linux.ibm.com>
      d721c15f
    • Roberto Sassu's avatar
      ima: Define new template evm-sig · 88016de3
      Roberto Sassu authored
      With the recent introduction of the evmsig template field, remote verifiers
      can obtain the EVM portable signature instead of the IMA signature, to
      verify file metadata.
      
      After introducing the new fields to include file metadata in the
      measurement list, this patch finally defines the evm-sig template, whose
      format is:
      
      d-ng|n-ng|evmsig|xattrnames|xattrlengths|xattrvalues|iuid|igid|imode
      
      xattrnames, xattrlengths and xattrvalues are populated only from defined
      EVM protected xattrs, i.e. the ones that EVM considers to verify the
      portable signature. xattrnames and xattrlengths are populated only if the
      xattr is present.
      
      xattrnames and xattrlengths are not necessary for verifying the EVM
      portable signature, but they are included for completeness of information,
      if a remote verifier wants to infer more from file metadata.
      Signed-off-by: default avatarRoberto Sassu <roberto.sassu@huawei.com>
      Signed-off-by: default avatarMimi Zohar <zohar@linux.ibm.com>
      88016de3
  6. 02 Jun, 2021 1 commit
  7. 01 Jun, 2021 10 commits
    • Roberto Sassu's avatar
      evm: Verify portable signatures against all protected xattrs · 8c7a703e
      Roberto Sassu authored
      Currently, the evm_config_default_xattrnames array contains xattr names
      only related to LSMs which are enabled in the kernel configuration.
      However, EVM portable signatures do not depend on local information and a
      vendor might include in the signature calculation xattrs that are not
      enabled in the target platform.
      
      Just including all xattrs names in evm_config_default_xattrnames is not a
      safe approach, because a target system might have already calculated
      signatures or HMACs based only on the enabled xattrs. After applying this
      patch, EVM would verify those signatures and HMACs with all xattrs instead.
      The non-enabled ones, which could possibly exist, would cause a
      verification error.
      
      Thus, this patch adds a new field named enabled to the xattr_list
      structure, which is set to true if the LSM associated to a given xattr name
      is enabled in the kernel configuration. The non-enabled xattrs are taken
      into account only in evm_calc_hmac_or_hash(), if the passed security.evm
      type is EVM_XATTR_PORTABLE_DIGSIG.
      
      The new function evm_protected_xattr_if_enabled() has been defined so that
      IMA can include all protected xattrs and not only the enabled ones in the
      measurement list, if the new template fields xattrnames, xattrlengths or
      xattrvalues have been included in the template format.
      Signed-off-by: default avatarRoberto Sassu <roberto.sassu@huawei.com>
      Signed-off-by: default avatarMimi Zohar <zohar@linux.ibm.com>
      8c7a703e
    • Roberto Sassu's avatar
      ima: Define new template field imode · f8216f6b
      Roberto Sassu authored
      This patch defines the new template field imode, which includes the
      inode mode. It can be used by a remote verifier to verify the EVM portable
      signature, if it was included with the template fields sig or evmsig.
      Signed-off-by: default avatarRoberto Sassu <roberto.sassu@huawei.com>
      Signed-off-by: default avatarMimi Zohar <zohar@linux.ibm.com>
      f8216f6b
    • Roberto Sassu's avatar
      ima: Define new template fields iuid and igid · 7dcfeacc
      Roberto Sassu authored
      This patch defines the new template fields iuid and igid, which include
      respectively the inode UID and GID. For idmapped mounts, still the original
      UID and GID are provided.
      
      These fields can be used to verify the EVM portable signature, if it was
      included with the template fields sig or evmsig.
      Signed-off-by: default avatarRoberto Sassu <roberto.sassu@huawei.com>
      Acked-by: default avatarChristian Brauner <christian.brauner@ubuntu.com>
      Signed-off-by: default avatarMimi Zohar <zohar@linux.ibm.com>
      7dcfeacc
    • Roberto Sassu's avatar
      ima: Add ima_show_template_uint() template library function · cde1391a
      Roberto Sassu authored
      This patch introduces the new function ima_show_template_uint(). This can
      be used for showing integers of different sizes in ASCII format. The
      function ima_show_template_data_ascii() automatically determines how to
      print a stored integer by checking the integer size.
      
      If integers have been written in canonical format,
      ima_show_template_data_ascii() calls the appropriate leXX_to_cpu() function
      to correctly display the value.
      Signed-off-by: default avatarRoberto Sassu <roberto.sassu@huawei.com>
      Signed-off-by: default avatarMimi Zohar <zohar@linux.ibm.com>
      cde1391a
    • Mimi Zohar's avatar
      Merge branch 'misc-evm-v7' into next-integrity · 5a25d8ce
      Mimi Zohar authored
      From cover letter:
      
      EVM portable signatures are particularly suitable for the protection of
      metadata of immutable files where metadata is signed by a software vendor.
      They can be used for example in conjunction with an IMA policy that
      appraises only executed and memory mapped files.
      
      However, until now portable signatures can be properly installed only if
      the EVM_ALLOW_METADATA_WRITES initialization flag is also set, which
      disables metadata verification until an HMAC key is loaded. This will cause
      metadata writes to be allowed even in the situations where they shouldn't
      (metadata protected by a portable signature is immutable).
      
      The main reason why setting the flag is necessary is that the operations
      necessary to install portable signatures and protected metadata would be
      otherwise denied, despite being legitimate, due to the fact that the
      decision logic has to avoid an unsafe recalculation of the HMAC that would
      make the unsuccessfully verified metadata valid. However, the decision
      logic is too coarse, and does not fully take into account all the possible
      situations where metadata operations could be allowed.
      
      For example, if the HMAC key is not loaded and it cannot be loaded in the
      future due the EVM_SETUP_COMPLETE flag being set, it wouldn't be a problem
      to allow metadata operations, as they wouldn't result in an HMAC being
      recalculated.
      
      This patch set extends the decision logic and adds the necessary exceptions
      to use portable signatures without turning off metadata verification and
      deprecates the EVM_ALLOW_METADATA_WRITES flag.
      
      Link: https://lore.kernel.org/linux-integrity/20210514152753.982958-1-roberto.sassu@huawei.com/
      5a25d8ce
    • Roberto Sassu's avatar
      ima: Don't remove security.ima if file must not be appraised · ed1b472f
      Roberto Sassu authored
      Files might come from a remote source and might have xattrs, including
      security.ima. It should not be IMA task to decide whether security.ima
      should be kept or not. This patch removes the removexattr() system
      call in ima_inode_post_setattr().
      Signed-off-by: default avatarRoberto Sassu <roberto.sassu@huawei.com>
      Signed-off-by: default avatarMimi Zohar <zohar@linux.ibm.com>
      ed1b472f
    • Roberto Sassu's avatar
      ima: Introduce template field evmsig and write to field sig as fallback · 026d7fc9
      Roberto Sassu authored
      With the patch to accept EVM portable signatures when the
      appraise_type=imasig requirement is specified in the policy, appraisal can
      be successfully done even if the file does not have an IMA signature.
      
      However, remote attestation would not see that a different signature type
      was used, as only IMA signatures can be included in the measurement list.
      This patch solves the issue by introducing the new template field 'evmsig'
      to show EVM portable signatures and by including its value in the existing
      field 'sig' if the IMA signature is not found.
      Suggested-by: default avatarMimi Zohar <zohar@linux.ibm.com>
      Signed-off-by: default avatarRoberto Sassu <roberto.sassu@huawei.com>
      Signed-off-by: default avatarMimi Zohar <zohar@linux.ibm.com>
      026d7fc9
    • Roberto Sassu's avatar
      ima: Allow imasig requirement to be satisfied by EVM portable signatures · 7aa5783d
      Roberto Sassu authored
      System administrators can require that all accessed files have a signature
      by specifying appraise_type=imasig in a policy rule.
      
      Currently, IMA signatures satisfy this requirement. Appended signatures may
      also satisfy this requirement, but are not applicable as IMA signatures.
      IMA/appended signatures ensure data source authentication for file content
      and prevent any change. EVM signatures instead ensure data source
      authentication for file metadata. Given that the digest or signature of the
      file content must be included in the metadata, EVM signatures provide the
      same file data guarantees of IMA signatures, as well as providing file
      metadata guarantees.
      
      This patch lets systems protected with EVM signatures pass appraisal
      verification if the appraise_type=imasig requirement is specified in the
      policy. This facilitates deployment in the scenarios where only EVM
      signatures are available.
      
      The patch makes the following changes:
      
      file xattr types:
      security.ima: IMA_XATTR_DIGEST/IMA_XATTR_DIGEST_NG
      security.evm: EVM_XATTR_PORTABLE_DIGSIG
      
      execve(), mmap(), open() behavior (with appraise_type=imasig):
      before: denied (file without IMA signature, imasig requirement not met)
      after: allowed (file with EVM portable signature, imasig requirement met)
      
      open(O_WRONLY) behavior (without appraise_type=imasig):
      before: allowed (file without IMA signature, not immutable)
      after: denied (file with EVM portable signature, immutable)
      
      In addition, similarly to IMA signatures, this patch temporarily allows
      new files without or with incomplete metadata to be opened so that content
      can be written.
      Signed-off-by: default avatarRoberto Sassu <roberto.sassu@huawei.com>
      Signed-off-by: default avatarMimi Zohar <zohar@linux.ibm.com>
      7aa5783d
    • Roberto Sassu's avatar
      evm: Deprecate EVM_ALLOW_METADATA_WRITES · 1434c6a1
      Roberto Sassu authored
      This patch deprecates the usage of EVM_ALLOW_METADATA_WRITES, as it is no
      longer necessary. All the issues that prevent the usage of EVM portable
      signatures just with a public key loaded have been solved.
      
      This flag will remain available for a short time to ensure that users are
      able to use EVM without it.
      Signed-off-by: default avatarRoberto Sassu <roberto.sassu@huawei.com>
      Signed-off-by: default avatarMimi Zohar <zohar@linux.ibm.com>
      1434c6a1
    • Roberto Sassu's avatar
      evm: Allow setxattr() and setattr() for unmodified metadata · 1886ab01
      Roberto Sassu authored
      With the patch to allow xattr/attr operations if a portable signature
      verification fails, cp and tar can copy all xattrs/attrs so that at the
      end of the process verification succeeds.
      
      However, it might happen that the xattrs/attrs are already set to the
      correct value (taken at signing time) and signature verification succeeds
      before the copy has completed. For example, an archive might contains files
      owned by root and the archive is extracted by root.
      
      Then, since portable signatures are immutable, all subsequent operations
      fail (e.g. fchown()), even if the operation is legitimate (does not alter
      the current value).
      
      This patch avoids this problem by reporting successful operation to user
      space when that operation does not alter the current value of xattrs/attrs.
      
      With this patch, the one that introduces evm_hmac_disabled() and the one
      that allows a metadata operation on the INTEGRITY_FAIL_IMMUTABLE error, EVM
      portable signatures can be used without disabling metadata verification
      (by setting EVM_ALLOW_METADATA_WRITES). Due to keeping metadata
      verification enabled, altering immutable metadata protected with a portable
      signature that was successfully verified will be denied (existing
      behavior).
      
      Reported-by: kernel test robot <lkp@intel.com> [implicit declaration of function]
      Signed-off-by: default avatarRoberto Sassu <roberto.sassu@huawei.com>
      Reviewed-by: default avatarChristian Brauner <christian.brauner@ubuntu.com>
      Cc: Andreas Gruenbacher <agruenba@redhat.com>
      Signed-off-by: default avatarMimi Zohar <zohar@linux.ibm.com>
      1886ab01
  8. 21 May, 2021 7 commits
    • Roberto Sassu's avatar
      evm: Pass user namespace to set/remove xattr hooks · 7e135dc7
      Roberto Sassu authored
      In preparation for 'evm: Allow setxattr() and setattr() for unmodified
      metadata', this patch passes mnt_userns to the inode set/remove xattr hooks
      so that the GID of the inode on an idmapped mount is correctly determined
      by posix_acl_update_mode().
      Signed-off-by: default avatarRoberto Sassu <roberto.sassu@huawei.com>
      Reviewed-by: default avatarChristian Brauner <christian.brauner@ubuntu.com>
      Cc: Andreas Gruenbacher <agruenba@redhat.com>
      Signed-off-by: default avatarMimi Zohar <zohar@linux.ibm.com>
      7e135dc7
    • Roberto Sassu's avatar
      evm: Allow xattr/attr operations for portable signatures · cdef685b
      Roberto Sassu authored
      If files with portable signatures are copied from one location to another
      or are extracted from an archive, verification can temporarily fail until
      all xattrs/attrs are set in the destination. Only portable signatures may
      be moved or copied from one file to another, as they don't depend on
      system-specific information such as the inode generation. Instead portable
      signatures must include security.ima.
      
      Unlike other security.evm types, EVM portable signatures are also
      immutable. Thus, it wouldn't be a problem to allow xattr/attr operations
      when verification fails, as portable signatures will never be replaced with
      the HMAC on possibly corrupted xattrs/attrs.
      
      This patch first introduces a new integrity status called
      INTEGRITY_FAIL_IMMUTABLE, that allows callers of
      evm_verify_current_integrity() to detect that a portable signature didn't
      pass verification and then adds an exception in evm_protect_xattr() and
      evm_inode_setattr() for this status and returns 0 instead of -EPERM.
      Signed-off-by: default avatarRoberto Sassu <roberto.sassu@huawei.com>
      Signed-off-by: default avatarMimi Zohar <zohar@linux.ibm.com>
      cdef685b
    • Roberto Sassu's avatar
      evm: Introduce evm_hmac_disabled() to safely ignore verification errors · 4a804b8a
      Roberto Sassu authored
      When a file is being created, LSMs can set the initial label with the
      inode_init_security hook. If no HMAC key is loaded, the new file will have
      LSM xattrs but not the HMAC. It is also possible that the file remains
      without protected xattrs after creation if no active LSM provided it, or
      because the filesystem does not support them.
      
      Unfortunately, EVM will deny any further metadata operation on new files,
      as evm_protect_xattr() will return the INTEGRITY_NOLABEL error if protected
      xattrs exist without security.evm, INTEGRITY_NOXATTRS if no protected
      xattrs exist or INTEGRITY_UNKNOWN if xattrs are not supported. This would
      limit the usability of EVM when only a public key is loaded, as commands
      such as cp or tar with the option to preserve xattrs won't work.
      
      This patch introduces the evm_hmac_disabled() function to determine whether
      or not it is safe to ignore verification errors, based on the ability of
      EVM to calculate HMACs. If the HMAC key is not loaded, and it cannot be
      loaded in the future due to the EVM_SETUP_COMPLETE initialization flag,
      allowing an operation despite the attrs/xattrs being found invalid will not
      make them valid.
      
      Since the post hooks can be executed even when the HMAC key is not loaded,
      this patch also ensures that the EVM_INIT_HMAC initialization flag is set
      before the post hooks call evm_update_evmxattr().
      Signed-off-by: default avatarRoberto Sassu <roberto.sassu@huawei.com>
      Suggested-by: Mimi Zohar <zohar@linux.ibm.com> (for ensuring EVM_INIT_HMAC is set)
      Signed-off-by: default avatarMimi Zohar <zohar@linux.ibm.com>
      4a804b8a
    • Roberto Sassu's avatar
      evm: Introduce evm_revalidate_status() · e3ccfe1a
      Roberto Sassu authored
      When EVM_ALLOW_METADATA_WRITES is set, EVM allows any operation on
      metadata. Its main purpose is to allow users to freely set metadata when it
      is protected by a portable signature, until an HMAC key is loaded.
      
      However, callers of evm_verifyxattr() are not notified about metadata
      changes and continue to rely on the last status returned by the function.
      For example IMA, since it caches the appraisal result, will not call again
      evm_verifyxattr() until the appraisal flags are cleared, and will grant
      access to the file even if there was a metadata operation that made the
      portable signature invalid.
      
      This patch introduces evm_revalidate_status(), which callers of
      evm_verifyxattr() can use in their xattr hooks to determine whether
      re-validation is necessary and to do the proper actions. IMA calls it in
      its xattr hooks to reset the appraisal flags, so that the EVM status is
      re-evaluated after a metadata operation.
      
      Lastly, this patch also adds a call to evm_reset_status() in
      evm_inode_post_setattr() to invalidate the cached EVM status after a
      setattr operation.
      Signed-off-by: default avatarRoberto Sassu <roberto.sassu@huawei.com>
      Signed-off-by: default avatarMimi Zohar <zohar@linux.ibm.com>
      e3ccfe1a
    • Roberto Sassu's avatar
      evm: Refuse EVM_ALLOW_METADATA_WRITES only if an HMAC key is loaded · 9acc89d3
      Roberto Sassu authored
      EVM_ALLOW_METADATA_WRITES is an EVM initialization flag that can be set to
      temporarily disable metadata verification until all xattrs/attrs necessary
      to verify an EVM portable signature are copied to the file. This flag is
      cleared when EVM is initialized with an HMAC key, to avoid that the HMAC is
      calculated on unverified xattrs/attrs.
      
      Currently EVM unnecessarily denies setting this flag if EVM is initialized
      with a public key, which is not a concern as it cannot be used to trust
      xattrs/attrs updates. This patch removes this limitation.
      
      Fixes: ae1ba167 ("EVM: Allow userland to permit modification of EVM-protected metadata")
      Signed-off-by: default avatarRoberto Sassu <roberto.sassu@huawei.com>
      Cc: stable@vger.kernel.org # 4.16.x
      Signed-off-by: default avatarMimi Zohar <zohar@linux.ibm.com>
      9acc89d3
    • Roberto Sassu's avatar
      evm: Load EVM key in ima_load_x509() to avoid appraisal · aa2ead71
      Roberto Sassu authored
      The public builtin keys do not need to be appraised by IMA as the
      restriction on the IMA/EVM trusted keyrings ensures that a key can be
      loaded only if it is signed with a key on the builtin or secondary
      keyrings.
      
      However, when evm_load_x509() is called, appraisal is already enabled and
      a valid IMA signature must be added to the EVM key to pass verification.
      
      Since the restriction is applied on both IMA and EVM trusted keyrings, it
      is safe to disable appraisal also when the EVM key is loaded. This patch
      calls evm_load_x509() inside ima_load_x509() if CONFIG_IMA_LOAD_X509 is
      enabled, which crosses the normal IMA and EVM boundary.
      Signed-off-by: default avatarRoberto Sassu <roberto.sassu@huawei.com>
      Signed-off-by: default avatarMimi Zohar <zohar@linux.ibm.com>
      aa2ead71
    • Roberto Sassu's avatar
      evm: Execute evm_inode_init_security() only when an HMAC key is loaded · 9eea2904
      Roberto Sassu authored
      evm_inode_init_security() requires an HMAC key to calculate the HMAC on
      initial xattrs provided by LSMs. However, it checks generically whether a
      key has been loaded, including also public keys, which is not correct as
      public keys are not suitable to calculate the HMAC.
      
      Originally, support for signature verification was introduced to verify a
      possibly immutable initial ram disk, when no new files are created, and to
      switch to HMAC for the root filesystem. By that time, an HMAC key should
      have been loaded and usable to calculate HMACs for new files.
      
      More recently support for requiring an HMAC key was removed from the
      kernel, so that signature verification can be used alone. Since this is a
      legitimate use case, evm_inode_init_security() should not return an error
      when no HMAC key has been loaded.
      
      This patch fixes this problem by replacing the evm_key_loaded() check with
      a check of the EVM_INIT_HMAC flag in evm_initialized.
      
      Fixes: 26ddabfe ("evm: enable EVM when X509 certificate is loaded")
      Signed-off-by: default avatarRoberto Sassu <roberto.sassu@huawei.com>
      Cc: stable@vger.kernel.org # 4.5.x
      Signed-off-by: default avatarMimi Zohar <zohar@linux.ibm.com>
      9eea2904
  9. 20 May, 2021 1 commit
    • Mimi Zohar's avatar
      evm: fix writing <securityfs>/evm overflow · 49219d9b
      Mimi Zohar authored
      EVM_SETUP_COMPLETE is defined as 0x80000000, which is larger than INT_MAX.
      The "-fno-strict-overflow" compiler option properly prevents signaling
      EVM that the EVM policy setup is complete.  Define and read an unsigned
      int.
      
      Fixes: f00d7975 ("EVM: Allow userspace to signal an RSA key has been loaded")
      Signed-off-by: default avatarMimi Zohar <zohar@linux.ibm.com>
      49219d9b
  10. 16 May, 2021 7 commits
    • Linus Torvalds's avatar
      Linux 5.13-rc2 · d07f6ca9
      Linus Torvalds authored
      d07f6ca9
    • Linus Torvalds's avatar
      Merge tag 'driver-core-5.13-rc2' of... · 28183dbf
      Linus Torvalds authored
      Merge tag 'driver-core-5.13-rc2' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/driver-core
      
      Pull driver core fixes from Greg KH:
       "Here are two driver fixes for driver core changes that happened in
        5.13-rc1.
      
        The clk driver fix resolves a many-reported issue with booting some
        devices, and the USB typec fix resolves the reported problem of USB
        systems on some embedded boards.
      
        Both of these have been in linux-next this week with no reported
        issues"
      
      * tag 'driver-core-5.13-rc2' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/driver-core:
        clk: Skip clk provider registration when np is NULL
        usb: typec: tcpm: Don't block probing of consumers of "connector" nodes
      28183dbf
    • Linus Torvalds's avatar
      Merge tag 'staging-5.13-rc2' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/staging · 6942d81a
      Linus Torvalds authored
      Pull staging and IIO driver fixes from Greg KH:
       "Here are some small IIO driver fixes and one Staging driver fix for
        5.13-rc2.
      
        Nothing major, just some resolutions for reported problems:
      
         - gcc-11 bogus warning fix for rtl8723bs
      
         - iio driver tiny fixes
      
        All of these have been in linux-next for many days with no reported
        issues"
      
      * tag 'staging-5.13-rc2' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/staging:
        iio: tsl2583: Fix division by a zero lux_val
        iio: core: return ENODEV if ioctl is unknown
        iio: core: fix ioctl handlers removal
        iio: gyro: mpu3050: Fix reported temperature value
        iio: hid-sensors: select IIO_TRIGGERED_BUFFER under HID_SENSOR_IIO_TRIGGER
        iio: proximity: pulsedlight: Fix rumtime PM imbalance on error
        iio: light: gp2ap002: Fix rumtime PM imbalance on error
        staging: rtl8723bs: avoid bogus gcc warning
      6942d81a
    • Linus Torvalds's avatar
      Merge tag 'usb-5.13-rc2' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb · 4a668429
      Linus Torvalds authored
      Pull USB fixes from Greg KH:
       "Here are some small USB fixes for 5.13-rc2. They consist of a number
        of resolutions for reported issues:
      
         - typec fixes for found problems
      
         - xhci fixes and quirk additions
      
         - dwc3 driver fixes
      
         - minor fixes found by Coverity
      
         - cdc-wdm fixes for reported problems
      
        All of these have been in linux-next for a few days with no reported
        issues"
      
      * tag 'usb-5.13-rc2' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb: (28 commits)
        usb: core: hub: fix race condition about TRSMRCY of resume
        usb: typec: tcpm: Fix SINK_DISCOVERY current limit for Rp-default
        xhci: Add reset resume quirk for AMD xhci controller.
        usb: xhci: Increase timeout for HC halt
        xhci: Do not use GFP_KERNEL in (potentially) atomic context
        xhci: Fix giving back cancelled URBs even if halted endpoint can't reset
        xhci-pci: Allow host runtime PM as default for Intel Alder Lake xHCI
        usb: musb: Fix an error message
        usb: typec: tcpm: Fix wrong handling for Not_Supported in VDM AMS
        usb: typec: tcpm: Send DISCOVER_IDENTITY from dedicated work
        usb: typec: ucsi: Retrieve all the PDOs instead of just the first 4
        usb: fotg210-hcd: Fix an error message
        docs: usb: function: Modify path name
        usb: dwc3: omap: improve extcon initialization
        usb: typec: ucsi: Put fwnode in any case during ->probe()
        usb: typec: tcpm: Fix wrong handling in GET_SINK_CAP
        usb: dwc2: Remove obsolete MODULE_ constants from platform.c
        usb: dwc3: imx8mp: fix error return code in dwc3_imx8mp_probe()
        usb: dwc3: imx8mp: detect dwc3 core node via compatible string
        usb: dwc3: gadget: Return success always for kick transfer in ep queue
        ...
      4a668429
    • Linus Torvalds's avatar
      Merge tag 'timers-urgent-2021-05-16' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip · 8ce36481
      Linus Torvalds authored
      Pull timer fixes from Thomas Gleixner:
       "Two fixes for timers:
      
         - Use the ALARM feature check in the alarmtimer core code insted of
           the old method of checking for the set_alarm() callback.
      
           Drivers can have that callback set but the feature bit cleared. If
           such a RTC device is selected then alarms wont work.
      
         - Use a proper define to let the preprocessor check whether Hyper-V
           VDSO clocksource should be active.
      
           The code used a constant in an enum with #ifdef, which evaluates to
           always false and disabled the clocksource for VDSO"
      
      * tag 'timers-urgent-2021-05-16' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip:
        clocksource/drivers/hyper-v: Re-enable VDSO_CLOCKMODE_HVCLOCK on X86
        alarmtimer: Check RTC features instead of ops
      8ce36481
    • Linus Torvalds's avatar
      Merge tag 'for-linus-5.13b-rc2-tag' of git://git.kernel.org/pub/scm/linux/kernel/git/xen/tip · f44e58bb
      Linus Torvalds authored
      Pull xen fixes from Juergen Gross:
      
       - two patches for error path fixes
      
       - a small series for fixing a regression with swiotlb with Xen on Arm
      
      * tag 'for-linus-5.13b-rc2-tag' of git://git.kernel.org/pub/scm/linux/kernel/git/xen/tip:
        xen/swiotlb: check if the swiotlb has already been initialized
        arm64: do not set SWIOTLB_NO_FORCE when swiotlb is required
        xen/arm: move xen_swiotlb_detect to arm/swiotlb-xen.h
        xen/unpopulated-alloc: fix error return code in fill_list()
        xen/gntdev: fix gntdev_mmap() error exit path
      f44e58bb
    • Linus Torvalds's avatar
      Merge tag 'x86_urgent_for_v5.13_rc2' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip · ccb013c2
      Linus Torvalds authored
      Pull x86 fixes from Borislav Petkov:
       "The three SEV commits are not really urgent material. But we figured
        since getting them in now will avoid a huge amount of conflicts
        between future SEV changes touching tip, the kvm and probably other
        trees, sending them to you now would be best.
      
        The idea is that the tip, kvm etc branches for 5.14 will all base
        ontop of -rc2 and thus everything will be peachy. What is more, those
        changes are purely mechanical and defines movement so they should be
        fine to go now (famous last words).
      
        Summary:
      
         - Enable -Wundef for the compressed kernel build stage
      
         - Reorganize SEV code to streamline and simplify future development"
      
      * tag 'x86_urgent_for_v5.13_rc2' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip:
        x86/boot/compressed: Enable -Wundef
        x86/msr: Rename MSR_K8_SYSCFG to MSR_AMD64_SYSCFG
        x86/sev: Move GHCB MSR protocol and NAE definitions in a common header
        x86/sev-es: Rename sev-es.{ch} to sev.{ch}
      ccb013c2
  11. 15 May, 2021 2 commits
    • Linus Torvalds's avatar
      Merge tag 'powerpc-5.13-3' of git://git.kernel.org/pub/scm/linux/kernel/git/powerpc/linux · 63d1cb53
      Linus Torvalds authored
      Pull powerpc fixes from Michael Ellerman:
      
       - Fix a regression in the conversion of the 64-bit BookE interrupt
         entry to C.
      
       - Fix KVM hosts running with the hash MMU since the recent KVM gfn
         changes.
      
       - Fix a deadlock in our paravirt spinlocks when hcall tracing is
         enabled.
      
       - Several fixes for oopses in our runtime code patching for security
         mitigations.
      
       - A couple of minor fixes for the recent conversion of 32-bit interrupt
         entry/exit to C.
      
       - Fix __get_user() causing spurious crashes in sigreturn due to a bad
         inline asm constraint, spotted with GCC 11.
      
       - A fix for the way we track IRQ masking state vs NMI interrupts when
         using the new scv system call entry path.
      
       - A couple more minor fixes.
      
      Thanks to Cédric Le Goater, Christian Zigotzky, Christophe Leroy,
      Naveen N. Rao, Nicholas Piggin Paul Menzel, and Sean Christopherson.
      
      * tag 'powerpc-5.13-3' of git://git.kernel.org/pub/scm/linux/kernel/git/powerpc/linux:
        powerpc/64e/interrupt: Fix nvgprs being clobbered
        powerpc/64s: Make NMI record implicitly soft-masked code as irqs disabled
        powerpc/64s: Fix stf mitigation patching w/strict RWX & hash
        powerpc/64s: Fix entry flush patching w/strict RWX & hash
        powerpc/64s: Fix crashes when toggling entry flush barrier
        powerpc/64s: Fix crashes when toggling stf barrier
        KVM: PPC: Book3S HV: Fix kvm_unmap_gfn_range_hv() for Hash MMU
        powerpc/legacy_serial: Fix UBSAN: array-index-out-of-bounds
        powerpc/signal: Fix possible build failure with unsafe_copy_fpr_{to/from}_user
        powerpc/uaccess: Fix __get_user() with CONFIG_CC_HAS_ASM_GOTO_OUTPUT
        powerpc/pseries: warn if recursing into the hcall tracing code
        powerpc/pseries: use notrace hcall variant for H_CEDE idle
        powerpc/pseries: Don't trace hcall tracing wrapper
        powerpc/pseries: Fix hcall tracing recursion in pv queued spinlocks
        powerpc/syscall: Calling kuap_save_and_lock() is wrong
        powerpc/interrupts: Fix kuep_unlock() call
      63d1cb53
    • Linus Torvalds's avatar
      Merge tag 'sched-urgent-2021-05-15' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip · c12a29ed
      Linus Torvalds authored
      Pull scheduler fixes from Ingo Molnar:
       "Fix an idle CPU selection bug, and an AMD Ryzen maximum frequency
        enumeration bug"
      
      * tag 'sched-urgent-2021-05-15' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip:
        x86, sched: Fix the AMD CPPC maximum performance value on certain AMD Ryzen generations
        sched/fair: Fix clearing of has_idle_cores flag in select_idle_cpu()
      c12a29ed