1. 25 8月, 2021 1 次提交
    • N
      s390/pci: improve DMA translation init and exit · 1f3f7681
      Niklas Schnelle 提交于
      Currently zpci_dma_init_device()/zpci_dma_exit_device() is called as
      part of zpci_enable_device()/zpci_disable_device() and errors for
      zpci_dma_exit_device() are always ignored even if we could abort.
      
      Improve upon this by moving zpci_dma_exit_device() out of
      zpci_disable_device() and check for errors whenever we have a way to
      abort the current operation. Note that for example in
      zpci_event_hard_deconfigured() the device is expected to be gone so we
      really can't abort and proceed even in case of error.
      
      Similarly move the cc == 3 special case out of zpci_unregister_ioat()
      and into the callers allowing to abort when finding an already disabled
      devices precludes proceeding with the operation.
      
      While we are at it log IOAT register/unregister errors in the s390
      debugfs log,
      Reviewed-by: NMatthew Rosato <mjrosato@linux.ibm.com>
      Signed-off-by: NNiklas Schnelle <schnelle@linux.ibm.com>
      Signed-off-by: NHeiko Carstens <hca@linux.ibm.com>
      1f3f7681
  2. 18 8月, 2021 2 次提交
  3. 09 8月, 2021 2 次提交
  4. 02 8月, 2021 1 次提交
    • F
      iommu: Check if group is NULL before remove device · 5aa95d88
      Frank Wunderlich 提交于
      If probe_device is failing, iommu_group is not initialized because
      iommu_group_add_device is not reached, so freeing it will result
      in NULL pointer access.
      
      iommu_bus_init
        ->bus_iommu_probe
            ->probe_iommu_group in for each:/* return -22 in fail case */
                ->iommu_probe_device
                    ->__iommu_probe_device       /* return -22 here.*/
                        -> ops->probe_device          /* return -22 here.*/
                        -> iommu_group_get_for_dev
                              -> ops->device_group
                              -> iommu_group_add_device //good case
        ->remove_iommu_group  //in fail case, it will remove group
           ->iommu_release_device
               ->iommu_group_remove_device // here we don't have group
      
      In my case ops->probe_device (mtk_iommu_probe_device from
      mtk_iommu_v1.c) is due to failing fwspec->ops mismatch.
      
      Fixes: d72e31c9 ("iommu: IOMMU Groups")
      Signed-off-by: NFrank Wunderlich <frank-w@public-files.de>
      Link: https://lore.kernel.org/r/20210731074737.4573-1-linux@fw-web.deSigned-off-by: NJoerg Roedel <jroedel@suse.de>
      5aa95d88
  5. 26 7月, 2021 1 次提交
  6. 20 7月, 2021 1 次提交
  7. 14 7月, 2021 6 次提交
  8. 25 6月, 2021 3 次提交
  9. 23 6月, 2021 3 次提交
  10. 18 6月, 2021 1 次提交
  11. 16 6月, 2021 2 次提交
  12. 11 6月, 2021 5 次提交
  13. 10 6月, 2021 12 次提交