- 25 11月, 2022 2 次提交
-
-
由 Mike Leach 提交于
mainline inclusion from mainline-v5.11 commit 42b2b570 category: feature bugzilla: https://gitee.com/openeuler/kernel/issues/I636PS CVE: NA Reference: https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?id=42b2b570b34afb5fb9dc16ac77cb332194136a85 -------------------------------------------------------------------------- The current fixed metadata version format (version 0), means that adding metadata parameter items renders files from a previous version of perf unreadable. Per CPU parameters appear in a fixed order, but there is no field to indicate the number of ETM parameters per CPU. This patch updates the per CPU parameter blocks to include a NR_PARAMs value which indicates the number of parameters in the block. The header version is incremented to 1. Fixed ordering is retained, new ETM parameters are added to the end of the list. The reader code is updated to be able to read current version 0 files, For version 1, the reader will read the number of parameters in the per CPU block. This allows the reader to process older or newer files that may have different numbers of parameters than in use at the time perf was built. Signed-off-by: NMike Leach <mike.leach@linaro.org> Reviewed-by: NLeo Yan <leo.yan@linaro.org> Tested-by: NLeo Yan <leo.yan@linaro.org> Link: https://lore.kernel.org/r/20210202214040.32349-1-mike.leach@linaro.org Link: https://lore.kernel.org/r/20210224164835.3497311-2-mathieu.poirier@linaro.orgSigned-off-by: NArnaldo Carvalho de Melo <acme@redhat.com> Signed-off-by: NJunhao He <hejunhao3@huawei.com>
-
由 openeuler-ci-bot 提交于
!223 SPR: IDXD driver (on top of OLK-5.10) - DSA/IAA incremental backporting patches until upstream 6.1 Merge Pull Request from: @xiaochenshen **IDXD kernel driver:** IDXD driver is the common driver framework of Intel Data Stream Accelerator (DSA) and Intel In-memory Analytics Accelerator (IAA). This patchset covers the incremental backporting kernel patches until upstream 6.1. It fixes issues: 1. https://gitee.com/openeuler/intel-kernel/issues/I596WO 2. https://gitee.com/openeuler/intel-kernel/issues/I590PB **DSA – Intel Data Streaming Accelerator:** Intel DSA is a high-performance data copy and transformation accelerator that is integrated in Intel Sapphire Rapids (SPR) processors, targeted for optimizing streaming data movement and transformation operations common with applications for high-performance storage, networking, persistent memory, and various data processing applications. See more details in DSA spec: https://software.intel.com/content/www/us/en/develop/articles/intel-data-streaming-accelerator-architecture-specification.html **IAA - Intel In-memory Analytics Accelerator:** Intel In-memory Analytics Accelerator is the integrated accelerator that accelerates analytics primitives (scan, filter, etc.), CRC calculations, compression, decompression, and more on Intel Sapphire Rapids (SPR) processors. See more details in IAA spec: https://cdrdv2.intel.com/v1/dl/getContent/721858 **There are 173 patches in total in this patch set. It covers:** 1. IDXD driver incremental patches between 5.10 LTS and upstream 6.1 (Shared WQ, SVM, IAA, driver refactoring and bug fixes). 2. ENQCMD and PASID re-enabling patches (as dependencies of IDXD driver) 3. Other dependencies in IOMMU driver. 4. kABI fixes for OpenEuler. 5. Enable necessary kernel configs in openeuler_defconfig. **Passed tests:** 1. Unit tests: passed - accel-config test - accel-config/test dsa_user_test_runner.sh - accel-config/test iaa_user_test_runner.sh - Kernel dmatest test (SVA disabled: "modprobe idxd sva=0") - Intel internal DSA config test suite (dsa_config_bat_tests, dsa_config_func_tests) - Intel internal IAX config test suite (iax_config_bat_tests, iax_config_func_tests) 3. Build successfully. 4. Boot test: passed. **Kernel config changes against default:** ``` @@ -6381,7 +6381,11 @@ CONFIG_DMA_VIRTUAL_CHANNELS=y CONFIG_DMA_ACPI=y # CONFIG_ALTERA_MSGDMA is not set CONFIG_INTEL_IDMA64=m +CONFIG_INTEL_IDXD_BUS=m CONFIG_INTEL_IDXD=m +# CONFIG_INTEL_IDXD_COMPAT is not set +CONFIG_INTEL_IDXD_SVM=y +CONFIG_INTEL_IDXD_PERFMON=y CONFIG_INTEL_IOATDMA=m # CONFIG_PLX_DMA is not set # CONFIG_QCOM_HIDMA_MGMT is not set @@ -6632,11 +6636,12 @@ CONFIG_IOMMU_SUPPORT=y # CONFIG_IOMMU_DEBUGFS is not set CONFIG_IOMMU_DEFAULT_PASSTHROUGH=y CONFIG_IOMMU_DMA=y +CONFIG_IOMMU_SVA=y CONFIG_AMD_IOMMU=y CONFIG_AMD_IOMMU_V2=m CONFIG_DMAR_TABLE=y CONFIG_INTEL_IOMMU=y -# CONFIG_INTEL_IOMMU_SVM is not set +CONFIG_INTEL_IOMMU_SVM=y # CONFIG_INTEL_IOMMU_DEFAULT_ON is not set CONFIG_INTEL_IOMMU_FLOPPY_WA=y # CONFIG_INTEL_IOMMU_SCALABLE_MODE_DEFAULT_ON is not set ``` **Kernel command line to enable intel iommu scalable mode (in grub.cfg):** ``` intel_iommu=on,sm_on ``` Link:https://gitee.com/openeuler/kernel/pulls/223 Reviewed-by: Zheng Zengkai <zhengzengkai@huawei.com> Reviewed-by: Chen Wei <chenwei@xfusion.com> Reviewed-by: Liu Chao <liuchao173@huawei.com> Reviewed-by: Jun Tian <jun.j.tian@intel.com> Signed-off-by: Zheng Zengkai <zhengzengkai@huawei.com>
-
- 24 11月, 2022 38 次提交
-
-
由 Xiaochen Shen 提交于
category: feature bugzilla: https://gitee.com/openeuler/intel-kernel/issues/I596WO CVE: NA Intel-SIG: openeuler_defconfig: Enable configs for Intel IDXD driver. -------------------------------------------- Enable necessary kernel configs for Intel IDXD driver in openeuler_defconfig for Intel DSA/IAA features. Signed-off-by: NXiaochen Shen <xiaochen.shen@intel.com>
-
由 Xiaochen Shen 提交于
category: bugfix bugzilla: https://gitee.com/openeuler/intel-kernel/issues/I596WO CVE: NA Intel-SIG: sched: Fix kABI for task->pasid_activated. ------------------------------------------------- In commit ("sched: Define and initialize a flag to identify valid PASID in the task"), a new single bit field 'pasid_activated' is added to the middle of 'struct task_struct' that causes kABI breakage. Fix it by using KABI_FILL_HOLE() API for task->pasid_activated. Signed-off-by: NXiaochen Shen <xiaochen.shen@intel.com>
-
由 Xiaochen Shen 提交于
category: bugfix bugzilla: https://gitee.com/openeuler/intel-kernel/issues/I596WO CVE: NA Intel-SIG: dmaengine: idxd: Fix kABI for IDXD perfmon cpu hot plug state. ------------------------------------------------- In commit ("dmaengine: idxd: Add IDXD performance monitor support"), the introduction of Intel IDXD performance monitor feature adds new CPU hot plug state 'CPUHP_AP_PERF_X86_IDXD_ONLINE' in the middle of data structure 'enum cpuhp_state' that causes kABI breakage. Fix it by reusing other arch's entry for CPUHP_AP_PERF_X86_IDXD_ONLINE to avoid kABI breakage. Signed-off-by: NXiaochen Shen <xiaochen.shen@intel.com>
-
由 Thomas Gleixner 提交于
mainline inclusion from mainline-v6.2 commit 444eef7d category: feature bugzilla: https://gitee.com/openeuler/intel-kernel/issues/I596WO CVE: NA Intel-SIG: commit 444eef7d dmaengine: idxd: Remove linux/msi.h include. Incremental backporting patches for DSA/IAA on Intel Xeon platform. -------------------------------- Nothing in this file needs anything from linux/msi.h Signed-off-by: NThomas Gleixner <tglx@linutronix.de> Cc: Fenghua Yu <fenghua.yu@intel.com> Cc: Dave Jiang <dave.jiang@intel.com> Cc: Vinod Koul <vkoul@kernel.org> Cc: dmaengine@vger.kernel.org Link: https://lore.kernel.org/r/20221113202428.573536003@linutronix.deSigned-off-by: NVinod Koul <vkoul@kernel.org> Signed-off-by: NXiaochen Shen <xiaochen.shen@intel.com>
-
由 Fenghua Yu 提交于
mainline inclusion from mainline-v6.2 commit dc901d98 category: bugfix bugzilla: https://gitee.com/openeuler/intel-kernel/issues/I596WO CVE: NA Intel-SIG: commit dc901d98 dmaengine: idxd: Fix crc_val field for completion record. Incremental backporting patches for DSA/IAA on Intel Xeon platform. -------------------------------- The crc_val in the completion record should be 64 bits and not 32 bits. Fixes: 4ac823e9 ("dmaengine: idxd: fix delta_rec and crc size field for completion record") Reported-by: NNirav N Shah <nirav.n.shah@intel.com> Signed-off-by: NFenghua Yu <fenghua.yu@intel.com> Reviewed-by: NDave Jiang <dave.jiang@intel.com> Link: https://lore.kernel.org/r/20221111012715.2031481-1-fenghua.yu@intel.comSigned-off-by: NVinod Koul <vkoul@kernel.org> Signed-off-by: NXiaochen Shen <xiaochen.shen@intel.com>
-
由 Xiaochen Shen 提交于
mainline inclusion from mainline-v6.2 commit 9a8ddb35 category: bugfix bugzilla: https://gitee.com/openeuler/intel-kernel/issues/I596WO CVE: NA Intel-SIG: commit 9a8ddb35 dmaengine: idxd: Make read buffer sysfs attributes invisible for Intel IAA. Incremental backporting patches for DSA/IAA on Intel Xeon platform. -------------------------------- In current code, the following sysfs attributes are exposed to user to show or update the values: max_read_buffers (max_tokens) read_buffer_limit (token_limit) group/read_buffers_allowed (group/tokens_allowed) group/read_buffers_reserved (group/tokens_reserved) group/use_read_buffer_limit (group/use_token_limit) >From Intel IAA spec [1], Intel IAA does not support Read Buffer allocation control. So these sysfs attributes should not be supported on IAA device. Fix this issue by making these sysfs attributes invisible through is_visible() filter when the device is IAA. Add description in the ABI documentation to mention that these attributes are not visible when the device does not support Read Buffer allocation control. [1]: https://cdrdv2.intel.com/v1/dl/getContent/721858 Fixes: fde212e4 ("dmaengine: idxd: deprecate token sysfs attributes for read buffers") Fixes: c52ca478 ("dmaengine: idxd: add configuration component of driver") Signed-off-by: NXiaochen Shen <xiaochen.shen@intel.com> Reviewed-by: NDave Jiang <dave.jiang@intel.com> Link: https://lore.kernel.org/r/20221022074949.11719-1-xiaochen.shen@intel.comSigned-off-by: NVinod Koul <vkoul@kernel.org> Signed-off-by: NXiaochen Shen <xiaochen.shen@intel.com>
-
由 Xiaochen Shen 提交于
mainline inclusion from mainline-v6.2 commit 91123b37 category: bugfix bugzilla: https://gitee.com/openeuler/intel-kernel/issues/I596WO CVE: NA Intel-SIG: commit 91123b37 dmaengine: idxd: Make max batch size attributes in sysfs invisible for Intel IAA. Incremental backporting patches for DSA/IAA on Intel Xeon platform. -------------------------------- In current code, dev.max_batch_size and wq.max_batch_size attributes in sysfs are exposed to user to show or update the values. >From Intel IAA spec [1], Intel IAA does not support batch processing. So these sysfs attributes should not be supported on IAA device. Fix this issue by making the attributes of max_batch_size invisible in sysfs through is_visible() filter when the device is IAA. Add description in the ABI documentation to mention that the attributes are not visible when the device does not support batch. [1]: https://cdrdv2.intel.com/v1/dl/getContent/721858 Fixes: e7184b15 ("dmaengine: idxd: add support for configurable max wq batch size") Fixes: c52ca478 ("dmaengine: idxd: add configuration component of driver") Signed-off-by: NXiaochen Shen <xiaochen.shen@intel.com> Reviewed-by: NDave Jiang <dave.jiang@intel.com> Reviewed-by: NFenghua Yu <fenghua.yu@intel.com> Link: https://lore.kernel.org/r/20220930201528.18621-3-xiaochen.shen@intel.comSigned-off-by: NVinod Koul <vkoul@kernel.org> Signed-off-by: NXiaochen Shen <xiaochen.shen@intel.com>
-
由 Fengqian Gao 提交于
mainline inclusion from mainline-v6.1 commit 0b8c97a1 category: bugfix bugzilla: https://gitee.com/openeuler/intel-kernel/issues/I596WO CVE: NA Intel-SIG: commit 0b8c97a1 dmaengine: idxd: fix RO device state error after been disabled/reset. Incremental backporting patches for DSA/IAA on Intel Xeon platform. -------------------------------- When IDXD is not configurable, that means its WQ, engine, and group configurations cannot be changed. But it can be disabled and its state should be set as disabled regardless it's configurable or not. Fix this by setting device state IDXD_DEV_DISABLED for read-only device as well in idxd_device_clear_state(). Fixes: cf4ac3fe ("dmaengine: idxd: fix lockdep warning on device driver removal") Signed-off-by: NFengqian Gao <fengqian.gao@intel.com> Reviewed-by: NXiaochen Shen <xiaochen.shen@intel.com> Reviewed-by: NDave Jiang <dave.jiang@intel.com> Reviewed-by: NFenghua Yu <fenghua.yu@intel.com> Link: https://lore.kernel.org/r/20220930032835.2290-1-fengqian.gao@intel.comSigned-off-by: NVinod Koul <vkoul@kernel.org> Signed-off-by: NXiaochen Shen <xiaochen.shen@intel.com>
-
由 Xiaochen Shen 提交于
mainline inclusion from mainline-v6.1 commit e8dbd644 category: bugfix bugzilla: https://gitee.com/openeuler/intel-kernel/issues/I596WO CVE: NA Intel-SIG: commit e8dbd644 dmaengine: idxd: Fix max batch size for Intel IAA. Incremental backporting patches for DSA/IAA on Intel Xeon platform. -------------------------------- >From Intel IAA spec [1], Intel IAA does not support batch processing. Two batch related default values for IAA are incorrect in current code: (1) The max batch size of device is set during device initialization, that indicates batch is supported. It should be always 0 on IAA. (2) The max batch size of work queue is set to WQ_DEFAULT_MAX_BATCH (32) as the default value regardless of Intel DSA or IAA device during work queue setup and cleanup. It should be always 0 on IAA. Fix the issues by setting the max batch size of device and max batch size of work queue to 0 on IAA device, that means batch is not supported. [1]: https://cdrdv2.intel.com/v1/dl/getContent/721858 Fixes: 23084545 ("dmaengine: idxd: set max_xfer and max_batch for RO device") Fixes: 92452a72 ("dmaengine: idxd: set defaults for wq configs") Fixes: bfe1d560 ("dmaengine: idxd: Init and probe for Intel data accelerators") Signed-off-by: NXiaochen Shen <xiaochen.shen@intel.com> Reviewed-by: NDave Jiang <dave.jiang@intel.com> Reviewed-by: NFenghua Yu <fenghua.yu@intel.com> Link: https://lore.kernel.org/r/20220930201528.18621-2-xiaochen.shen@intel.comSigned-off-by: NVinod Koul <vkoul@kernel.org> Signed-off-by: NXiaochen Shen <xiaochen.shen@intel.com>
-
由 Fenghua Yu 提交于
mainline inclusion from mainline-v6.1 commit 0ec8ce07 category: bugfix bugzilla: https://gitee.com/openeuler/intel-kernel/issues/I596WO CVE: NA Intel-SIG: commit 0ec8ce07 dmaengine: idxd: Do not enable user type Work Queue without Shared Virtual Addressing. Incremental backporting patches for DSA/IAA on Intel Xeon platform. -------------------------------- When the idxd_user_drv driver is bound to a Work Queue (WQ) device without IOMMU or with IOMMU Passthrough without Shared Virtual Addressing (SVA), the application gains direct access to physical memory via the device by programming physical address to a submitted descriptor. This allows direct userspace read and write access to arbitrary physical memory. This is inconsistent with the security goals of a good kernel API. Unlike vfio_pci driver, the IDXD char device driver does not provide any ways to pin user pages and translate the address from user VA to IOVA or PA without IOMMU SVA. Therefore the application has no way to instruct the device to perform DMA function. This makes the char device not usable for normal application usage. Since user type WQ without SVA cannot be used for normal application usage and presents the security issue, bind idxd_user_drv driver and enable user type WQ only when SVA is enabled (i.e. user PASID is enabled). Fixes: 448c3de8 ("dmaengine: idxd: create user driver for wq 'device'") Cc: stable@vger.kernel.org Suggested-by: NArjan Van De Ven <arjan.van.de.ven@intel.com> Signed-off-by: NFenghua Yu <fenghua.yu@intel.com> Reviewed-by: NDave Jiang <dave.jiang@intel.com> Reviewed-by: NJerry Snitselaar <jsnitsel@redhat.com> Link: https://lore.kernel.org/r/20221014222541.3912195-1-fenghua.yu@intel.comSigned-off-by: NVinod Koul <vkoul@kernel.org> Signed-off-by: NXiaochen Shen <xiaochen.shen@intel.com>
-
由 Dave Jiang 提交于
mainline inclusion from mainline-v6.1 commit 7ca68fa3 category: feature bugzilla: https://gitee.com/openeuler/intel-kernel/issues/I596WO CVE: NA Intel-SIG: commit 7ca68fa3 dmaengine: idxd: add configuration for concurrent batch descriptor processing. Incremental backporting patches for DSA/IAA on Intel Xeon platform. -------------------------------- Add sysfs knob to allow control of the number of batch descriptors that can be concurrently processed by an engine in the group as a fraction of the Maximum Work Descriptors in Progress value specfied in ENGCAP register. This control knob is part of toggle for QoS control. Signed-off-by: NDave Jiang <dave.jiang@intel.com> Co-developed-by: NFenghua Yu <fenghua.yu@intel.com> Signed-off-by: NFenghua Yu <fenghua.yu@intel.com> Link: https://lore.kernel.org/r/20220917161222.2835172-6-fenghua.yu@intel.comSigned-off-by: NVinod Koul <vkoul@kernel.org> Signed-off-by: NXiaochen Shen <xiaochen.shen@intel.com>
-
由 Dave Jiang 提交于
mainline inclusion from mainline-v6.1 commit 1f273752 category: feature bugzilla: https://gitee.com/openeuler/intel-kernel/issues/I596WO CVE: NA Intel-SIG: commit 1f273752 dmaengine: idxd: add configuration for concurrent work descriptor processing. Incremental backporting patches for DSA/IAA on Intel Xeon platform. -------------------------------- Add sysfs knob to allow control of the number of work descriptors that can be concurrently processed by an engine in the group as a fraction of the Maximum Work Descriptors in Progress value specified in ENGCAP register. This control knob is part of toggle for QoS control. Signed-off-by: NDave Jiang <dave.jiang@intel.com> Co-developed-by: NFenghua Yu <fenghua.yu@intel.com> Signed-off-by: NFenghua Yu <fenghua.yu@intel.com> Link: https://lore.kernel.org/r/20220917161222.2835172-5-fenghua.yu@intel.comSigned-off-by: NVinod Koul <vkoul@kernel.org> Signed-off-by: NXiaochen Shen <xiaochen.shen@intel.com>
-
由 Dave Jiang 提交于
mainline inclusion from mainline-v6.1 commit b0325aef category: feature bugzilla: https://gitee.com/openeuler/intel-kernel/issues/I596WO CVE: NA Intel-SIG: commit b0325aef dmaengine: idxd: add WQ operation cap restriction support. Incremental backporting patches for DSA/IAA on Intel Xeon platform. -------------------------------- DSA 2.0 add the capability of configuring DMA ops on a per workqueue basis. This means that certain ops can be disabled by the system administrator for certain wq. By default, all ops are available. A bitmap is used to store the ops due to total op size of 256 bits and it is more convenient to use a range list to specify which bits are enabled. One of the usage to support this is for VM migration between different iteration of devices. The newer ops are disabled in order to allow guest to migrate to a host that only support older ops. Another usage is to restrict the WQ to certain operations for QoS of performance. A sysfs of ops_config attribute is added per wq. It is only usable when the ops_config bit is set under WQ_CAP register. This means that this attribute will return -EOPNOTSUPP on DSA 1.x devices. The expected input is a range list for the bits per operation the WQ supports. Signed-off-by: NDave Jiang <dave.jiang@intel.com> Co-developed-by: NFenghua Yu <fenghua.yu@intel.com> Signed-off-by: NFenghua Yu <fenghua.yu@intel.com> Link: https://lore.kernel.org/r/20220917161222.2835172-4-fenghua.yu@intel.comSigned-off-by: NVinod Koul <vkoul@kernel.org> Signed-off-by: NXiaochen Shen <xiaochen.shen@intel.com>
-
由 Dave Jiang 提交于
mainline inclusion from mainline-v6.1 commit a8563a33 category: feature bugzilla: https://gitee.com/openeuler/intel-kernel/issues/I596WO CVE: NA Intel-SIG: commit a8563a33 dmanegine: idxd: reformat opcap output to match bitmap_parse() input. Incremental backporting patches for DSA/IAA on Intel Xeon platform. -------------------------------- To make input and output consistent and prepping for the per WQ operation configuration support, change the output of opcap display to match the input that is expected by bitmap_parse() helper function. The output will be a bitmap with field width as the number of bits using the %*pb format specifier for printk() family. Signed-off-by: NDave Jiang <dave.jiang@intel.com> Co-developed-by: NFenghua Yu <fenghua.yu@intel.com> Signed-off-by: NFenghua Yu <fenghua.yu@intel.com> Link: https://lore.kernel.org/r/20220917161222.2835172-3-fenghua.yu@intel.comSigned-off-by: NVinod Koul <vkoul@kernel.org> Signed-off-by: NXiaochen Shen <xiaochen.shen@intel.com>
-
由 Dave Jiang 提交于
mainline inclusion from mainline-v6.1 commit 22bd0df8 category: feature bugzilla: https://gitee.com/openeuler/intel-kernel/issues/I596WO CVE: NA Intel-SIG: commit 22bd0df8 dmaengine: idxd: convert ats_dis to a wq flag. Incremental backporting patches for DSA/IAA on Intel Xeon platform. -------------------------------- Make wq attributes access consistent. Convert ats_dis to wq flag WQ_FLAG_ATS_DISABLE. Signed-off-by: NDave Jiang <dave.jiang@intel.com> Co-developed-by: NFenghua Yu <fenghua.yu@intel.com> Signed-off-by: NFenghua Yu <fenghua.yu@intel.com> Link: https://lore.kernel.org/r/20220917161222.2835172-2-fenghua.yu@intel.comSigned-off-by: NVinod Koul <vkoul@kernel.org> Signed-off-by: NXiaochen Shen <xiaochen.shen@intel.com>
-
由 Yuan Can 提交于
mainline inclusion from mainline-v6.1 commit d1083fd0 category: feature bugzilla: https://gitee.com/openeuler/intel-kernel/issues/I596WO CVE: NA Intel-SIG: commit d1083fd0 dmaengine: idxd: Remove unused struct idxd_fault. Incremental backporting patches for DSA/IAA on Intel Xeon platform. -------------------------------- Since fault processing code has been removed, struct idxd_fault is not used any more and can be removed as well. Signed-off-by: NYuan Can <yuancan@huawei.com> Link: https://lore.kernel.org/r/20220928014747.106808-1-yuancan@huawei.comSigned-off-by: NVinod Koul <vkoul@kernel.org> Signed-off-by: NXiaochen Shen <xiaochen.shen@intel.com>
-
由 Jerry Snitselaar 提交于
mainline inclusion from mainline-v6.1 commit de5819b9 category: bugfix bugzilla: https://gitee.com/openeuler/intel-kernel/issues/I596WO CVE: NA Intel-SIG: commit de5819b9 dmaengine: idxd: track enabled workqueues in bitmap. Incremental backporting patches for DSA/IAA on Intel Xeon platform. -------------------------------- Now that idxd_wq_disable_cleanup() sets the workqueue state to IDXD_WQ_DISABLED, use a bitmap to track which workqueues have been enabled. This will then be used to determine which workqueues should be re-enabled when attempting a software reset to recover from a device halt state. Cc: Fenghua Yu <fenghua.yu@intel.com> Cc: Dave Jiang <dave.jiang@intel.com> Cc: Vinod Koul <vkoul@kernel.org> Signed-off-by: NJerry Snitselaar <jsnitsel@redhat.com> Reviewed-by: NDave Jiang <dave.jiang@intel.com> Link: https://lore.kernel.org/r/20220928154856.623545-3-jsnitsel@redhat.comSigned-off-by: NVinod Koul <vkoul@kernel.org> Signed-off-by: NXiaochen Shen <xiaochen.shen@intel.com>
-
由 Tariq Toukan 提交于
mainline inclusion from mainline-v5.16 commit 7529cc7f category: feature bugzilla: https://gitee.com/openeuler/intel-kernel/issues/I596WO CVE: NA Intel-SIG: commit 7529cc7f lib: bitmap: Introduce node-aware alloc API. Incremental backporting patches for DSA/IAA on Intel Xeon platform. -------------------------------- Expose new node-aware API for bitmap allocation: bitmap_alloc_node() / bitmap_zalloc_node(). Signed-off-by: NTariq Toukan <tariqt@nvidia.com> Reviewed-by: NMoshe Shemesh <moshe@nvidia.com> Signed-off-by: NSaeed Mahameed <saeedm@nvidia.com> Signed-off-by: NXiaochen Shen <xiaochen.shen@intel.com>
-
由 Jerry Snitselaar 提交于
minline inclusion from mainline-v6.1 commit 8e527aac category: bugfix bugzilla: https://gitee.com/openeuler/intel-kernel/issues/I596WO CVE: NA Intel-SIG: commit 8e527aac dmaengine: idxd: Set wq state to disabled in idxd_wq_disable_cleanup(). Incremental backporting patches for DSA/IAA on Intel Xeon platform. -------------------------------- If we are calling idxd_wq_disable_cleanup(), the workqueue should be in a disabled state. So set the workqueue state to IDXD_WQ_DISABLED so that the state reflects that. Currently if there is a device failure, and a software reset is attempted the workqueues will not be re-enabled due to idxd_wq_enable() seeing that state as already being IDXD_WQ_ENABLED. Cc: Fenghua Yu <fenghua.yu@intel.com> Cc: Dave Jiang <dave.jiang@intel.com> Cc: Vinod Koul <vkoul@kernel.org> Signed-off-by: NJerry Snitselaar <jsnitsel@redhat.com> Reviewed-by: NDave Jiang <dave.jiang@intel.com> Link: https://lore.kernel.org/r/20220928154856.623545-2-jsnitsel@redhat.comSigned-off-by: NVinod Koul <vkoul@kernel.org> Signed-off-by: NXiaochen Shen <xiaochen.shen@intel.com>
-
由 Jerry Snitselaar 提交于
mainline inclusion from mainline-v6.1 commit 40717171 category: bugfix bugzilla: https://gitee.com/openeuler/intel-kernel/issues/I596WO CVE: NA Intel-SIG: 40717171 dmaengine: idxd: avoid deadlock in process_misc_interrupts(). Incremental backporting patches for DSA/IAA on Intel Xeon platform. -------------------------------- idxd_device_clear_state() now grabs the idxd->dev_lock itself, so don't grab the lock prior to calling it. This was seen in testing after dmar fault occurred on system, resulting in lockup stack traces. Cc: Fenghua Yu <fenghua.yu@intel.com> Cc: Dave Jiang <dave.jiang@intel.com> Cc: Vinod Koul <vkoul@kernel.org> Cc: dmaengine@vger.kernel.org Fixes: cf4ac3fe ("dmaengine: idxd: fix lockdep warning on device driver removal") Signed-off-by: NJerry Snitselaar <jsnitsel@redhat.com> Reviewed-by: NDave Jiang <dave.jiang@intel.com> Link: https://lore.kernel.org/r/20220823163709.2102468-1-jsnitsel@redhat.comSigned-off-by: NVinod Koul <vkoul@kernel.org> Signed-off-by: NXiaochen Shen <xiaochen.shen@intel.com>
-
由 Fenghua Yu 提交于
mainline inclusion from mainline-v6.0 commit d0b55afa category: feature bugzilla: https://gitee.com/openeuler/intel-kernel/issues/I596WO CVE: NA Intel-SIG: commit d0b55afa dmaengine: idxd: Correct IAX operation code names. Incremental backporting patches for DSA/IAA on Intel Xeon platform. -------------------------------- Some IAX operation code nomenclatures are misleading or don't match with others: 1. Operation code 0x4c is Zero Compress 32. IAX_OPCODE_DECOMP_32 is a misleading name. Change it to IAX_OPCODE_ZERO_COMP_32. 2. Operation code 0x4d is Zero Compress 16. IAX_OPCODE_DECOMP_16 is a misleading name. Change it to IAX_OPCODE_ZERO_COMP_16. 3. IAX_OPCDE_FIND_UNIQUE is corrected to match with other nomenclatures. Co-developed-by: NLi Zhang <li4.zhang@intel.com> Signed-off-by: NLi Zhang <li4.zhang@intel.com> Signed-off-by: NFenghua Yu <fenghua.yu@intel.com> Reviewed-by: NDave Jiang <dave.jiang@intel.com> Link: https://lore.kernel.org/r/20220707002052.1546361-1-fenghua.yu@intel.comSigned-off-by: NVinod Koul <vkoul@kernel.org> Signed-off-by: NXiaochen Shen <xiaochen.shen@intel.com>
-
由 Dave Jiang 提交于
mainline inclusion from mainline-v6.0 commit 5dc86388 category: feature bugzilla: https://gitee.com/openeuler/intel-kernel/issues/I596WO CVE: NA Intel-SIG: commit 5dc86388 MAINTAINERS: idxd driver maintainer update. Incremental backporting patches for DSA/IAA on Intel Xeon platform. -------------------------------- Add Fenghua as maintainer of the idxd driver. Signed-off-by: NFenghua Yu <fenghua.yu@intel.com> Signed-off-by: NDave Jiang <dave.jiang@intel.com> Link: https://lore.kernel.org/r/20220615232651.177098-1-fenghua.yu@intel.comSigned-off-by: NVinod Koul <vkoul@kernel.org> Signed-off-by: NXiaochen Shen <xiaochen.shen@intel.com>
-
由 Jerry Snitselaar 提交于
mainline inclusion from mainline-v5.19 commit 8ffccd11 category: bugfix bugzilla: https://gitee.com/openeuler/intel-kernel/issues/I596WO CVE: NA Intel-SIG: commit 8ffccd11 dmaengine: idxd: Only call idxd_enable_system_pasid() if succeeded in enabling SVA feature. Incremental backporting patches for DSA/IAA on Intel Xeon platform. -------------------------------- On a Sapphire Rapids system if boot without intel_iommu=on, the IDXD driver will crash during probe in iommu_sva_bind_device(). [ 21.423729] BUG: kernel NULL pointer dereference, address: 0000000000000038 [ 21.445108] #PF: supervisor read access in kernel mode [ 21.450912] #PF: error_code(0x0000) - not-present page [ 21.456706] PGD 0 [ 21.459047] Oops: 0000 [#1] PREEMPT SMP NOPTI [ 21.464004] CPU: 0 PID: 1420 Comm: kworker/0:3 Not tainted 5.19.0-0.rc3.27.eln120.x86_64 #1 [ 21.464011] Hardware name: Intel Corporation EAGLESTREAM/EAGLESTREAM, BIOS EGSDCRB1.SYS.0067.D12.2110190954 10/19/2021 [ 21.464015] Workqueue: events work_for_cpu_fn [ 21.464030] RIP: 0010:iommu_sva_bind_device+0x1d/0xe0 [ 21.464046] Code: c3 cc 66 66 2e 0f 1f 84 00 00 00 00 00 0f 1f 44 00 00 41 57 41 56 49 89 d6 41 55 41 54 55 53 48 83 ec 08 48 8b 87 d8 02 00 00 <48> 8b 40 38 48 8b 50 10 48 83 7a 70 00 48 89 14 24 0f 84 91 00 00 [ 21.464050] RSP: 0018:ff7245d9096b7db8 EFLAGS: 00010296 [ 21.464054] RAX: 0000000000000000 RBX: ff1eadeec8a51000 RCX: 0000000000000000 [ 21.464058] RDX: ff7245d9096b7e24 RSI: 0000000000000000 RDI: ff1eadeec8a510d0 [ 21.464060] RBP: ff1eadeec8a51000 R08: ffffffffb1a12300 R09: ff1eadffbfce25b4 [ 21.464062] R10: ffffffffffffffff R11: 0000000000000038 R12: ffffffffc09f8000 [ 21.464065] R13: ff1eadeec8a510d0 R14: ff7245d9096b7e24 R15: ff1eaddf54429000 [ 21.464067] FS: 0000000000000000(0000) GS:ff1eadee7f600000(0000) knlGS:0000000000000000 [ 21.464070] CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 [ 21.464072] CR2: 0000000000000038 CR3: 00000008c0e10006 CR4: 0000000000771ef0 [ 21.464074] DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000 [ 21.464076] DR3: 0000000000000000 DR6: 00000000fffe07f0 DR7: 0000000000000400 [ 21.464078] PKRU: 55555554 [ 21.464079] Call Trace: [ 21.464083] <TASK> [ 21.464092] idxd_pci_probe+0x259/0x1070 [idxd] [ 21.464121] local_pci_probe+0x3e/0x80 [ 21.464132] work_for_cpu_fn+0x13/0x20 [ 21.464136] process_one_work+0x1c4/0x380 [ 21.464143] worker_thread+0x1ab/0x380 [ 21.464147] ? _raw_spin_lock_irqsave+0x23/0x50 [ 21.464158] ? process_one_work+0x380/0x380 [ 21.464161] kthread+0xe6/0x110 [ 21.464168] ? kthread_complete_and_exit+0x20/0x20 [ 21.464172] ret_from_fork+0x1f/0x30 iommu_sva_bind_device() requires SVA has been enabled successfully on the IDXD device before it's called. Otherwise, iommu_sva_bind_device() will access a NULL pointer. If Intel IOMMU is disabled, SVA cannot be enabled and thus idxd_enable_system_pasid() and iommu_sva_bind_device() should not be called. Fixes: 42a1b738 ("dmaengine: idxd: Separate user and kernel pasid enabling") Cc: Vinod Koul <vkoul@kernel.org> Cc: linux-kernel@vger.kernel.org Cc: Dave Jiang <dave.jiang@intel.com> Cc: Fenghua Yu <fenghua.yu@intel.com> Link: https://lore.kernel.org/dmaengine/20220623170232.6whonfjuh3m5vcoy@cantor/Signed-off-by: NJerry Snitselaar <jsnitsel@redhat.com> Acked-by: NFenghua Yu <fenghua.yu@intel.com> Link: https://lore.kernel.org/r/20220626051648.14249-1-jsnitsel@redhat.comSigned-off-by: NVinod Koul <vkoul@kernel.org> Signed-off-by: NXiaochen Shen <xiaochen.shen@intel.com>
-
由 Dave Jiang 提交于
mainline inclusion from mainline-v5.19 commit 44c4237c category: bugfix bugzilla: https://gitee.com/openeuler/intel-kernel/issues/I596WO CVE: NA Intel-SIG: commit 44c4237c dmaengine: idxd: force wq context cleanup on device disable path. Incremental backporting patches for DSA/IAA on Intel Xeon platform. -------------------------------- Testing shown that when a wq mode is setup to be dedicated and then torn down and reconfigured to shared, the wq configured end up being dedicated anyays. The root cause is when idxd_device_wqs_clear_state() gets called during idxd_driver removal, idxd_wq_disable_cleanup() does not get called vs when the wq driver is removed first. The check of wq state being "enabled" causes the cleanup to be bypassed. However, idxd_driver->remove() releases all wq drivers. So the wqs goes to "disabled" state and will never be "enabled". By that point, the driver has no idea if the wq was previously configured or clean. So force call idxd_wq_disable_cleanup() on all wqs always to make sure everything gets cleaned up. Reported-by: NTony Zhu <tony.zhu@intel.com> Tested-by: NTony Zhu <tony.zhu@intel.com> Fixes: 0dcfe41e ("dmanegine: idxd: cleanup all device related bits after disabling device") Signed-off-by: NDave Jiang <dave.jiang@intel.com> Co-developed-by: NFenghua Yu <fenghua.yu@intel.com> Signed-off-by: NFenghua Yu <fenghua.yu@intel.com> Link: https://lore.kernel.org/r/20220628230056.2527816-1-fenghua.yu@intel.comSigned-off-by: NVinod Koul <vkoul@kernel.org> Signed-off-by: NXiaochen Shen <xiaochen.shen@intel.com>
-
由 Dave Jiang 提交于
mainline inclusion from mainline-v5.19 commit d1a28597 category: feature bugzilla: https://gitee.com/openeuler/intel-kernel/issues/I596WO CVE: NA Intel-SIG: commit d1a28597 dmaengine: idxd: make idxd_wq_enable() return 0 if wq is already enabled. Incremental backporting patches for DSA/IAA on Intel Xeon platform. -------------------------------- When calling idxd_wq_enable() and wq is already enabled, code should return 0 and indicate function is successful instead of return error code and fail. This should also put idxd_wq_enable() in sync with idxd_wq_disable() where it returns 0 if wq is already disabled. Signed-off-by: NDave Jiang <dave.jiang@intel.com> Link: https://lore.kernel.org/r/165090980906.1378449.1939401700832432886.stgit@djiang5-desk3.ch.intel.comSigned-off-by: NVinod Koul <vkoul@kernel.org> Signed-off-by: NXiaochen Shen <xiaochen.shen@intel.com>
-
由 Minghao Chi 提交于
mainline inclusion from mainline-v5.19 commit 411dccf9 category: feature bugzilla: https://gitee.com/openeuler/intel-kernel/issues/I596WO CVE: NA Intel-SIG: commit 411dccf9 dmaengine: idxd: Remove unnecessary synchronize_irq() before free_irq(). Incremental backporting patches for DSA/IAA on Intel Xeon platform. -------------------------------- Calling synchronize_irq() right before free_irq() is quite useless. On one hand the IRQ can easily fire again before free_irq() is entered, on the other hand free_irq() itself calls synchronize_irq() internally (in a race condition free way), before any state associated with the IRQ is freed. Signed-off-by: NMinghao Chi <chi.minghao@zte.com.cn> Link: https://lore.kernel.org/r/20220516115412.1651772-1-chi.minghao@zte.com.cnAcked-by: NDave Jiang <dave.jiang@intel.com> Signed-off-by: NVinod Koul <vkoul@kernel.org> Signed-off-by: NXiaochen Shen <xiaochen.shen@intel.com>
-
由 Dave Jiang 提交于
mainline inclusion from mainline-v5.19 commit d0ad4238 category: bugfix bugzilla: https://gitee.com/openeuler/intel-kernel/issues/I596WO CVE: NA Intel-SIG: commit d0ad4238 dmaengine: idxd: skip irq free when wq type is not kernel. Incremental backporting patches for DSA/IAA on Intel Xeon platform. -------------------------------- Skip wq irq resources freeing when wq type is not kernel since the driver skips the irq alloction during wq enable. Add check in wq type check in idxd_wq_free_irq() to mirror idxd_wq_request_irq(). Fixes: 63c14ae6 ("dmaengine: idxd: refactor wq driver enable/disable operations") Reported-by: NTony Zu <tony.zhu@intel.com> Tested-by: NTony Zu <tony.zhu@intel.com> Signed-off-by: NDave Jiang <dave.jiang@intel.com> Link: https://lore.kernel.org/r/165176310726.2112428.7474366910758522079.stgit@djiang5-desk3.ch.intel.comSigned-off-by: NVinod Koul <vkoul@kernel.org> Signed-off-by: NXiaochen Shen <xiaochen.shen@intel.com>
-
由 Dave Jiang 提交于
mainline inclusion from mainline-v5.19 commit 8e6226f0 category: feature bugzilla: https://gitee.com/openeuler/intel-kernel/issues/I596WO CVE: NA Intel-SIG: commit 8e6226f0 dmaengine: idxd: make idxd_register/unregister_dma_channel() static. Incremental backporting patches for DSA/IAA on Intel Xeon platform. -------------------------------- Since idxd_register/unregister_dma_channel() are only called locally, make them static. Reported-by: Nkernel test robot <lkp@intel.com> Signed-off-by: NDave Jiang <dave.jiang@intel.com> Link: https://lore.kernel.org/r/165187583222.3287435.12882651040433040246.stgit@djiang5-desk3.ch.intel.comSigned-off-by: NVinod Koul <vkoul@kernel.org> Signed-off-by: NXiaochen Shen <xiaochen.shen@intel.com>
-
由 Dave Jiang 提交于
mainline inclusion from mainline-v5.19 commit 9120c879 category: bugfix bugzilla: https://gitee.com/openeuler/intel-kernel/issues/I596WO CVE: NA Intel-SIG: commit 9120c879 dmaengine: idxd: free irq before wq type is reset. Incremental backporting patches for DSA/IAA on Intel Xeon platform. -------------------------------- Call idxd_wq_free_irq() in the drv_disable_wq() function before idxd_wq_reset() is called. Otherwise the wq type is reset and the irq does not get freed. Fixes: 63c14ae6 ("dmaengine: idxd: refactor wq driver enable/disable operations") Signed-off-by: NDave Jiang <dave.jiang@intel.com> Link: https://lore.kernel.org/r/165231367316.986407.11001767338124941736.stgit@djiang5-desk3.ch.intel.comSigned-off-by: NVinod Koul <vkoul@kernel.org> Signed-off-by: NXiaochen Shen <xiaochen.shen@intel.com>
-
由 Dave Jiang 提交于
mainline inclusion from mainline-v5.19 commit cf4ac3fe category: feature bugzilla: https://gitee.com/openeuler/intel-kernel/issues/I596WO CVE: NA Intel-SIG: commit cf4ac3fe dmaengine: idxd: fix lockdep warning on device driver removal. Incremental backporting patches for DSA/IAA on Intel Xeon platform. -------------------------------- Jacob reported that with lockdep debug turned on, idxd_device_driver removal causes kernel splat from lock assert warning for idxd_device_wqs_clear_state(). Make sure idxd_device_wqs_clear_state() holds the wq lock for each wq when cleaning the wq state. Move the call outside of the device spinlock. Reported-by: NJacob Pan <jacob.jun.pan@intel.com> Signed-off-by: NDave Jiang <dave.jiang@intel.com> Link: https://lore.kernel.org/r/165231364426.986304.9294302800482492780.stgit@djiang5-desk3.ch.intel.comSigned-off-by: NVinod Koul <vkoul@kernel.org> Signed-off-by: NXiaochen Shen <xiaochen.shen@intel.com>
-
由 Dave Jiang 提交于
mainline inclusion from mainline-v5.19 commit 42a1b738 category: feature bugzilla: https://gitee.com/openeuler/intel-kernel/issues/I596WO CVE: NA Intel-SIG: commit 42a1b738 dmaengine: idxd: Separate user and kernel pasid enabling. Incremental backporting patches for DSA/IAA on Intel Xeon platform. -------------------------------- The idxd driver always gated the pasid enabling under a single knob and this assumption is incorrect. The pasid used for kernel operation can be independently toggled and has no dependency on the user pasid (and vice versa). Split the two so they are independent "enabled" flags. Signed-off-by: NDave Jiang <dave.jiang@intel.com> Link: https://lore.kernel.org/r/165231431746.986466.5666862038354800551.stgit@djiang5-desk3.ch.intel.comSigned-off-by: NVinod Koul <vkoul@kernel.org> Signed-off-by: NXiaochen Shen <xiaochen.shen@intel.com>
-
由 Dave Jiang 提交于
mainline inclusion from mainline-v5.19 commit 63c14ae6 category: feature bugzilla: https://gitee.com/openeuler/intel-kernel/issues/I596WO CVE: NA Intel-SIG: commit 63c14ae6 dmaengine: idxd: refactor wq driver enable/disable operations. Incremental backporting patches for DSA/IAA on Intel Xeon platform. -------------------------------- Move the core driver operations from wq driver to the drv_enable_wq() and drv_disable_wq() functions. The move should reduce the wq driver's knowledge of the core driver operations and prevent code confusion for future wq drivers. Signed-off-by: NDave Jiang <dave.jiang@intel.com> Link: https://lore.kernel.org/r/165047301643.3841827.11222723219862233060.stgit@djiang5-desk3.ch.intel.comSigned-off-by: NVinod Koul <vkoul@kernel.org> Signed-off-by: NXiaochen Shen <xiaochen.shen@intel.com>
-
由 Dave Jiang 提交于
mainline inclusion from mainline-v5.19 commit 439b5e76 category: feature bugzilla: https://gitee.com/openeuler/intel-kernel/issues/I596WO CVE: NA Intel-SIG: commit 439b5e76 dmaengine: idxd: move wq irq enabling to after device enable. Incremental backporting patches for DSA/IAA on Intel Xeon platform. -------------------------------- Move the calling of request_irq() and other related irq setup code until after the WQ is successfully enabled. This reduces the amount of setup/teardown if the wq is not configured correctly and cannot be enabled. Signed-off-by: NDave Jiang <dave.jiang@intel.com> Link: https://lore.kernel.org/r/164642777730.179702.1880317757087484299.stgit@djiang5-desk3.ch.intel.comSigned-off-by: NVinod Koul <vkoul@kernel.org> Signed-off-by: NXiaochen Shen <xiaochen.shen@intel.com>
-
由 Dave Jiang 提交于
mainline inclusion from mainline-v5.19 commit 23084545 category: feature bugzilla: https://gitee.com/openeuler/intel-kernel/issues/I596WO CVE: NA Intel-SIG: commit 23084545 dmaengine: idxd: set max_xfer and max_batch for RO device. Incremental backporting patches for DSA/IAA on Intel Xeon platform. -------------------------------- Load the max_xfer_size and max_batch_size values from the values read from registers to the shadow variables. This will allow the read-only device to display the correct values for the sysfs attributes. Signed-off-by: NDave Jiang <dave.jiang@intel.com> Link: https://lore.kernel.org/r/164971507673.2201761.11244446608988838897.stgit@djiang5-desk3.ch.intel.comSigned-off-by: NVinod Koul <vkoul@kernel.org> Signed-off-by: NXiaochen Shen <xiaochen.shen@intel.com>
-
由 Dave Jiang 提交于
mainline inclusion from mainline-v5.19 commit 2d7991fe category: feature bugzilla: https://gitee.com/openeuler/intel-kernel/issues/I596WO CVE: NA Intel-SIG: commit 2d7991fe dmaengine: idxd: update IAA definitions for user header. Incremental backporting patches for DSA/IAA on Intel Xeon platform. -------------------------------- Add additional structure definitions for Intel In-memory Analytics Accelerator (IAA/IAX). See specification (1) for more details. 1: https://cdrdv2.intel.com/v1/dl/getContent/721858Signed-off-by: NDave Jiang <dave.jiang@intel.com> Link: https://lore.kernel.org/r/164704100212.1373038.18362680016033557757.stgit@djiang5-desk3.ch.intel.comSigned-off-by: NVinod Koul <vkoul@kernel.org> Signed-off-by: NXiaochen Shen <xiaochen.shen@intel.com>
-
由 Dave Jiang 提交于
mainline inclusion from mainline-v5.19 commit 81f5eb2b category: feature bugzilla: https://gitee.com/openeuler/intel-kernel/issues/I596WO CVE: NA Intel-SIG: commit 81f5eb2b dmaengine: idxd: remove trailing white space on input str for wq name. Incremental backporting patches for DSA/IAA on Intel Xeon platform. -------------------------------- Add string processing with strim() in order to remove trailing white spaces that may be input by user for the wq->name. Signed-off-by: NDave Jiang <dave.jiang@intel.com> Link: https://lore.kernel.org/r/164789525123.2799661.13795829125221129132.stgit@djiang5-desk3.ch.intel.comSigned-off-by: NVinod Koul <vkoul@kernel.org> Signed-off-by: NXiaochen Shen <xiaochen.shen@intel.com>
-
由 Dave Jiang 提交于
mainline inclusion from mainline-v5.19 commit 3157dd0a category: feature bugzilla: https://gitee.com/openeuler/intel-kernel/issues/I596WO CVE: NA Intel-SIG: commit 3157dd0a dmaengine: idxd: don't load pasid config until needed. Incremental backporting patches for DSA/IAA on Intel Xeon platform. -------------------------------- The driver currently programs the system pasid to the WQ preemptively when system pasid is enabled. Given that a dwq will reprogram the pasid and possibly a different pasid, the programming is not necessary. The pasid_en bit can be set for swq as it does not need pasid programming but needs the pasid_en bit. Remove system pasid programming on device config write. Add pasid programming for kernel wq type on wq driver enable. The char dev driver already reprograms the dwq on ->open() call so there's no change. Signed-off-by: NDave Jiang <dave.jiang@intel.com> Link: https://lore.kernel.org/r/164935607115.1660372.6734518676950372366.stgit@djiang5-desk3.ch.intel.comSigned-off-by: NVinod Koul <vkoul@kernel.org> Signed-off-by: NXiaochen Shen <xiaochen.shen@intel.com>
-
由 Dave Jiang 提交于
mainline inclusion from mainline-v5.18 commit 1cd8e751 category: bugfix bugzilla: https://gitee.com/openeuler/intel-kernel/issues/I596WO CVE: NA Intel-SIG: commit 1cd8e751 dmaengine: idxd: skip clearing device context when device is read-only. Incremental backporting patches for DSA/IAA on Intel Xeon platform. -------------------------------- If the device shows up as read-only configuration, skip the clearing of the state as the context must be preserved for device re-enable after being disabled. Fixes: 0dcfe41e ("dmanegine: idxd: cleanup all device related bits after disabling device") Reported-by: NTony Zhu <tony.zhu@intel.com> Tested-by: NTony Zhu <tony.zhu@intel.com> Signed-off-by: NDave Jiang <dave.jiang@intel.com> Link: https://lore.kernel.org/r/164971479479.2200566.13980022473526292759.stgit@djiang5-desk3.ch.intel.comSigned-off-by: NVinod Koul <vkoul@kernel.org> Signed-off-by: NXiaochen Shen <xiaochen.shen@intel.com>
-