[PATCH v15 0/1] drm/i915: Allow user to set cache at BO creation

2023-05-31 Thread fei . yang
From: Fei Yang This series introduce a new extension for GEM_CREATE, 1. end support for set caching ioctl [PATCH 1/2] 2. add set_pat extension for gem_create [PATCH 2/2] v2: drop one patch that was merged separately commit 341ad0e8e254 ("drm/i915/mtl: Add PTE encode function") v

[PATCH v15 1/1] drm/i915: Allow user to set cache at BO creation

2023-05-31 Thread fei . yang
From: Fei Yang To comply with the design that buffer objects shall have immutable cache setting through out their life cycle, {set, get}_caching ioctl's are no longer supported from MTL onward. With that change caching policy can only be set at object creation time. The current code applies

[PATCH v12 1/1] drm/i915: Allow user to set cache at BO creation

2023-05-24 Thread fei . yang
From: Fei Yang To comply with the design that buffer objects shall have immutable cache setting through out their life cycle, {set, get}_caching ioctl's are no longer supported from MTL onward. With that change caching policy can only be set at object creation time. The current code applies

[PATCH v12 0/1] drm/i915: Allow user to set cache at BO creation

2023-05-24 Thread fei . yang
From: Fei Yang This series introduce a new extension for GEM_CREATE, 1. end support for set caching ioctl [PATCH 1/2] 2. add set_pat extension for gem_create [PATCH 2/2] v2: drop one patch that was merged separately commit 341ad0e8e254 ("drm/i915/mtl: Add PTE encode function") v

[PATCH v11 1/1] drm/i915: Allow user to set cache at BO creation

2023-05-24 Thread fei . yang
From: Fei Yang To comply with the design that buffer objects shall have immutable cache setting through out their life cycle, {set, get}_caching ioctl's are no longer supported from MTL onward. With that change caching policy can only be set at object creation time. The current code applies

[PATCH v11 0/1] drm/i915: Allow user to set cache at BO creation

2023-05-24 Thread fei . yang
From: Fei Yang This series introduce a new extension for GEM_CREATE, 1. end support for set caching ioctl [PATCH 1/2] 2. add set_pat extension for gem_create [PATCH 2/2] v2: drop one patch that was merged separately commit 341ad0e8e254 ("drm/i915/mtl: Add PTE encode function") v

[PATCH v10 1/2] drm/i915/mtl: end support for set caching ioctl

2023-05-18 Thread fei . yang
From: Fei Yang The design is to keep Buffer Object's caching policy immutable through out its life cycle. This patch ends the support for set caching ioctl from MTL onward. While doing that we also set BO's to be 1-way coherent at creation time because GPU is no longer automatically snooping CPU

[PATCH v10 2/2] drm/i915: Allow user to set cache at BO creation

2023-05-18 Thread fei . yang
From: Fei Yang To comply with the design that buffer objects shall have immutable cache setting through out their life cycle, {set, get}_caching ioctl's are no longer supported from MTL onward. With that change caching policy can only be set at object creation time. The current code applies

[PATCH v10 0/2] drm/i915: Allow user to set cache at BO creation

2023-05-18 Thread fei . yang
From: Fei Yang This series introduce a new extension for GEM_CREATE, 1. end support for set caching ioctl [PATCH 1/2] 2. add set_pat extension for gem_create [PATCH 2/2] v2: drop one patch that was merged separately commit 341ad0e8e254 ("drm/i915/mtl: Add PTE encode function") v

[PATCH v9 2/2] drm/i915: Allow user to set cache at BO creation

2023-05-16 Thread fei . yang
From: Fei Yang To comply with the design that buffer objects shall have immutable cache setting through out their life cycle, {set, get}_caching ioctl's are no longer supported from MTL onward. With that change caching policy can only be set at object creation time. The current code applies

[PATCH v9 1/2] drm/i915/mtl: end support for set caching ioctl

2023-05-16 Thread fei . yang
From: Fei Yang The design is to keep Buffer Object's caching policy immutable through out its life cycle. This patch ends the support for set caching ioctl from MTL onward. While doing that we also set BO's to be 1-way coherent at creation time because GPU is no longer automatically snooping CPU

[PATCH v9 0/2] drm/i915: Allow user to set cache at BO creation

2023-05-16 Thread fei . yang
From: Fei Yang This series introduce a new extension for GEM_CREATE, 1. end support for set caching ioctl [PATCH 4/5] 2. add set_pat extension for gem_create [PATCH 5/5] v2: drop one patch that was merged separately commit 341ad0e8e254 ("drm/i915/mtl: Add PTE encode function") v

[PATCH v8 2/2] drm/i915: Allow user to set cache at BO creation

2023-05-12 Thread fei . yang
From: Fei Yang To comply with the design that buffer objects shall have immutable cache setting through out their life cycle, {set, get}_caching ioctl's are no longer supported from MTL onward. With that change caching policy can only be set at object creation time. The current code applies

[PATCH v8 0/2] drm/i915: Allow user to set cache at BO creation

2023-05-12 Thread fei . yang
From: Fei Yang The first three patches in this series are taken from https://patchwork.freedesktop.org/series/116868/ These patches are included here because the last patch has dependency on the pat_index refactor. This series is focusing on uAPI changes, 1. end support for set caching ioctl

[PATCH v8 1/2] drm/i915/mtl: end support for set caching ioctl

2023-05-12 Thread fei . yang
From: Fei Yang The design is to keep Buffer Object's caching policy immutable through out its life cycle. This patch ends the support for set caching ioctl from MTL onward. While doing that we also set BO's to be 1-way coherent at creation time because GPU is no longer automatically snooping CPU

[PATCH v7 2/4] drm/i915: use pat_index instead of cache_level

2023-05-09 Thread fei . yang
From: Fei Yang Currently the KMD is using enum i915_cache_level to set caching policy for buffer objects. This is flaky because the PAT index which really controls the caching behavior in PTE has far more levels than what's defined in the enum. In addition, the PAT index is platform dependent

[PATCH v7 3/4] drm/i915/mtl: end support for set caching ioctl

2023-05-09 Thread fei . yang
From: Fei Yang The design is to keep Buffer Object's caching policy immutable through out its life cycle. This patch ends the support for set caching ioctl from MTL onward. While doing that we also set BO's to be 1-way coherent at creation time because GPU is no longer automatically snooping CPU

[PATCH v7 0/4] drm/i915: Allow user to set cache at BO creation

2023-05-09 Thread fei . yang
From: Fei Yang The first three patches in this series are taken from https://patchwork.freedesktop.org/series/116868/ These patches are included here because the last patch has dependency on the pat_index refactor. This series is focusing on uAPI changes, 1. end support for set caching ioctl

[PATCH v7 1/4] drm/i915: preparation for using PAT index

2023-05-09 Thread fei . yang
From: Fei Yang This patch is a preparation for replacing enum i915_cache_level with PAT index. Caching policy for buffer objects is set through the PAT index in PTE, the old i915_cache_level is not sufficient to represent all caching modes supported by the hardware. Preparing the transition

[PATCH v7 4/4] drm/i915: Allow user to set cache at BO creation

2023-05-09 Thread fei . yang
From: Fei Yang To comply with the design that buffer objects shall have immutable cache setting through out their life cycle, {set, get}_caching ioctl's are no longer supported from MTL onward. With that change caching policy can only be set at object creation time. The current code applies

[PATCH v8 2/2] drm/i915: use pat_index instead of cache_level

2023-05-09 Thread fei . yang
From: Fei Yang Currently the KMD is using enum i915_cache_level to set caching policy for buffer objects. This is flaky because the PAT index which really controls the caching behavior in PTE has far more levels than what's defined in the enum. In addition, the PAT index is platform dependent

[PATCH v8 0/2] drm/i915: use pat_index instead of cache_level

2023-05-09 Thread fei . yang
From: Fei Yang This patch set was posted at https://patchwork.freedesktop.org/series/116868/ Change title since the PTE patch was merged separately. These patches are extracted from series https://patchwork.freedesktop.org/series/115980/ This series refactor the cache policy programming so

[PATCH v8 1/2] drm/i915: preparation for using PAT index

2023-05-09 Thread fei . yang
From: Fei Yang This patch is a preparation for replacing enum i915_cache_level with PAT index. Caching policy for buffer objects is set through the PAT index in PTE, the old i915_cache_level is not sufficient to represent all caching modes supported by the hardware. Preparing the transition

[PATCH v6 4/4] drm/i915: Allow user to set cache at BO creation

2023-05-08 Thread fei . yang
From: Fei Yang To comply with the design that buffer objects shall have immutable cache setting through out their life cycle, {set, get}_caching ioctl's are no longer supported from MTL onward. With that change caching policy can only be set at object creation time. The current code applies

[PATCH v6 2/4] drm/i915: use pat_index instead of cache_level

2023-05-08 Thread fei . yang
From: Fei Yang Currently the KMD is using enum i915_cache_level to set caching policy for buffer objects. This is flaky because the PAT index which really controls the caching behavior in PTE has far more levels than what's defined in the enum. In addition, the PAT index is platform dependent

[PATCH v6 3/4] drm/i915/mtl: end support for set caching ioctl

2023-05-08 Thread fei . yang
From: Fei Yang The design is to keep Buffer Object's caching policy immutable through out its life cycle. This patch ends the support for set caching ioctl from MTL onward. While doing that we also set BO's to be 1-way coherent at creation time because GPU is no longer automatically snooping CPU

[PATCH v6 0/4] drm/i915: Allow user to set cache at BO creation

2023-05-08 Thread fei . yang
From: Fei Yang The first three patches in this series are taken from https://patchwork.freedesktop.org/series/116868/ These patches are included here because the last patch has dependency on the pat_index refactor. This series is focusing on uAPI changes, 1. end support for set caching ioctl

[PATCH v6 1/4] drm/i915: preparation for using PAT index

2023-05-08 Thread fei . yang
From: Fei Yang This patch is a preparation for replacing enum i915_cache_level with PAT index. Caching policy for buffer objects is set through the PAT index in PTE, the old i915_cache_level is not sufficient to represent all caching modes supported by the hardware. Preparing the transition

[PATCH v7 1/2] drm/i915: preparation for using PAT index

2023-05-08 Thread fei . yang
From: Fei Yang This patch is a preparation for replacing enum i915_cache_level with PAT index. Caching policy for buffer objects is set through the PAT index in PTE, the old i915_cache_level is not sufficient to represent all caching modes supported by the hardware. Preparing the transition

[PATCH v7 2/2] drm/i915: use pat_index instead of cache_level

2023-05-08 Thread fei . yang
From: Fei Yang Currently the KMD is using enum i915_cache_level to set caching policy for buffer objects. This is flaky because the PAT index which really controls the caching behavior in PTE has far more levels than what's defined in the enum. In addition, the PAT index is platform dependent

[PATCH v7 0/2] drm/i915: use pat_index instead of cache_level

2023-05-08 Thread fei . yang
From: Fei Yang This patch set was posted at https://patchwork.freedesktop.org/series/116868/ Change title since the PTE patch was merged separately. These patches are extracted from series https://patchwork.freedesktop.org/series/115980/ This series refactor the cache policy programming so

[PATCH v6 2/2] drm/i915: use pat_index instead of cache_level

2023-05-08 Thread fei . yang
From: Fei Yang Currently the KMD is using enum i915_cache_level to set caching policy for buffer objects. This is flaky because the PAT index which really controls the caching behavior in PTE has far more levels than what's defined in the enum. In addition, the PAT index is platform dependent

[PATCH v6 0/2] drm/i915: use pat_index instead of cache_level

2023-05-08 Thread fei . yang
From: Fei Yang This patch set was posted at https://patchwork.freedesktop.org/series/116868/ Change title since the PTE patch was merged separately. These patches are extracted from series https://patchwork.freedesktop.org/series/115980/ This series refactor the cache policy programming so

[PATCH v6 1/2] drm/i915: preparation for using PAT index

2023-05-08 Thread fei . yang
From: Fei Yang This patch is a preparation for replacing enum i915_cache_level with PAT index. Caching policy for buffer objects is set through the PAT index in PTE, the old i915_cache_level is not sufficient to represent all caching modes supported by the hardware. Preparing the transition

[PATCH v5 2/5] drm/i915: use pat_index instead of cache_level

2023-05-03 Thread fei . yang
From: Fei Yang Currently the KMD is using enum i915_cache_level to set caching policy for buffer objects. This is flaky because the PAT index which really controls the caching behavior in PTE has far more levels than what's defined in the enum. In addition, the PAT index is platform dependent

[PATCH v5 3/5] drm/i915: make sure correct pte encode is used

2023-05-03 Thread fei . yang
From: Fei Yang PTE encode is platform dependent. After replacing cache_level with pat_index, the newly introduced mtl_pte_encode is actually generic for all gen12 platforms, thus rename it to gen12_pte_encode and apply it to all gen12 platforms. Cc: Chris Wilson Cc: Matt Roper Signed-off

[PATCH v5 5/5] drm/i915: Allow user to set cache at BO creation

2023-05-03 Thread fei . yang
From: Fei Yang To comply with the design that buffer objects shall have immutable cache setting through out their life cycle, {set, get}_caching ioctl's are no longer supported from MTL onward. With that change caching policy can only be set at object creation time. The current code applies

[PATCH v5 4/5] drm/i915/mtl: end support for set caching ioctl

2023-05-03 Thread fei . yang
From: Fei Yang The design is to keep Buffer Object's caching policy immutable through out its life cycle. This patch ends the support for set caching ioctl from MTL onward. While doing that we also set BO's to be 1-way coherent at creation time because GPU is no longer automatically snooping CPU

[PATCH v5 0/5] drm/i915: Allow user to set cache at BO creation

2023-05-03 Thread fei . yang
From: Fei Yang The first three patches in this series are taken from https://patchwork.freedesktop.org/series/116868/ These patches are included here because the last patch has dependency on the pat_index refactor. This series is focusing on uAPI changes, 1. end support for set caching ioctl

[PATCH v5 1/5] drm/i915: preparation for using PAT index

2023-05-03 Thread fei . yang
From: Fei Yang This patch is a preparation for replacing enum i915_cache_level with PAT index. Caching policy for buffer objects is set through the PAT index in PTE, the old i915_cache_level is not sufficient to represent all caching modes supported by the hardware. Preparing the transition

[PATCH v5 2/3] drm/i915: use pat_index instead of cache_level

2023-05-03 Thread fei . yang
From: Fei Yang Currently the KMD is using enum i915_cache_level to set caching policy for buffer objects. This is flaky because the PAT index which really controls the caching behavior in PTE has far more levels than what's defined in the enum. In addition, the PAT index is platform dependent

[PATCH v5 0/3] drm/i915: use pat_index instead of cache_level

2023-05-03 Thread fei . yang
From: Fei Yang This patch set was posted at https://patchwork.freedesktop.org/series/116868/ Change title since the PTE patch was merged separately. These patches are extracted from series https://patchwork.freedesktop.org/series/115980/ This series refactor the cache policy programming so

[PATCH v5 1/3] drm/i915: preparation for using PAT index

2023-05-03 Thread fei . yang
From: Fei Yang This patch is a preparation for replacing enum i915_cache_level with PAT index. Caching policy for buffer objects is set through the PAT index in PTE, the old i915_cache_level is not sufficient to represent all caching modes supported by the hardware. Preparing the transition

[PATCH v5 3/3] drm/i915: make sure correct pte encode is used

2023-05-03 Thread fei . yang
From: Fei Yang PTE encode is platform dependent. After replacing cache_level with pat_index, the newly introduced mtl_pte_encode is actually generic for all gen12 platforms, thus rename it to gen12_pte_encode and apply it to all gen12 platforms. Cc: Chris Wilson Cc: Matt Roper Signed-off

[PATCH v4 5/5] drm/i915: Allow user to set cache at BO creation

2023-05-01 Thread fei . yang
From: Fei Yang To comply with the design that buffer objects shall have immutable cache setting through out their life cycle, {set, get}_caching ioctl's are no longer supported from MTL onward. With that change caching policy can only be set at object creation time. The current code applies

[PATCH v4 3/5] drm/i915: make sure correct pte encode is used

2023-05-01 Thread fei . yang
From: Fei Yang PTE encode is platform dependent. After replacing cache_level with pat_index, the newly introduced mtl_pte_encode is actually generic for all gen12 platforms, thus rename it to gen12_pte_encode and apply it to all gen12 platforms. Cc: Chris Wilson Cc: Matt Roper Signed-off

[PATCH v4 2/5] drm/i915: use pat_index instead of cache_level

2023-05-01 Thread fei . yang
From: Fei Yang Currently the KMD is using enum i915_cache_level to set caching policy for buffer objects. This is flaky because the PAT index which really controls the caching behavior in PTE has far more levels than what's defined in the enum. In addition, the PAT index is platform dependent

[PATCH v4 1/5] drm/i915: preparation for using PAT index

2023-05-01 Thread fei . yang
From: Fei Yang This patch is a preparation for replacing enum i915_cache_level with PAT index. Caching policy for buffer objects is set through the PAT index in PTE, the old i915_cache_level is not sufficient to represent all caching modes supported by the hardware. Preparing the transition

[PATCH v4 4/5] drm/i915/mtl: end support for set caching ioctl

2023-05-01 Thread fei . yang
From: Fei Yang The design is to keep Buffer Object's caching policy immutable through out its life cycle. This patch ends the support for set caching ioctl from MTL onward. While doing that we also set BO's to be 1-way coherent at creation time because GPU is no longer automatically snooping CPU

[PATCH v4 0/5] drm/i915: Allow user to set cache at BO creation

2023-05-01 Thread fei . yang
From: Fei Yang The first three patches in this series are taken from https://patchwork.freedesktop.org/series/116868/ These patches are included here because the last patch has dependency on the pat_index refactor. This series is focusing on uAPI changes, 1. end support for set caching ioctl

[PATCH v4 2/3] drm/i915: use pat_index instead of cache_level

2023-05-01 Thread fei . yang
From: Fei Yang Currently the KMD is using enum i915_cache_level to set caching policy for buffer objects. This is flaky because the PAT index which really controls the caching behavior in PTE has far more levels than what's defined in the enum. In addition, the PAT index is platform dependent

[PATCH v4 1/3] drm/i915: preparation for using PAT index

2023-05-01 Thread fei . yang
From: Fei Yang This patch is a preparation for replacing enum i915_cache_level with PAT index. Caching policy for buffer objects is set through the PAT index in PTE, the old i915_cache_level is not sufficient to represent all caching modes supported by the hardware. Preparing the transition

[PATCH v4 3/3] drm/i915: make sure correct pte encode is used

2023-05-01 Thread fei . yang
From: Fei Yang PTE encode is platform dependent. After replacing cache_level with pat_index, the newly introduced mtl_pte_encode is actually generic for all gen12 platforms, thus rename it to gen12_pte_encode and apply it to all gen12 platforms. Cc: Chris Wilson Cc: Matt Roper Signed-off

[PATCH v4 0/3] drm/i915: use pat_index instead of cache_level

2023-05-01 Thread fei . yang
From: Fei Yang This patch set was posted at https://patchwork.freedesktop.org/series/116868/ Change title since the PTE patch was merged separately. These patches are extracted from series https://patchwork.freedesktop.org/series/115980/ This series refactor the cache policy programming so

[PATCH v3 2/5] drm/i915: use pat_index instead of cache_level

2023-04-27 Thread fei . yang
From: Fei Yang Currently the KMD is using enum i915_cache_level to set caching policy for buffer objects. This is flaky because the PAT index which really controls the caching behavior in PTE has far more levels than what's defined in the enum. In addition, the PAT index is platform dependent

[PATCH v3 4/5] drm/i915/mtl: end support for set caching ioctl

2023-04-27 Thread fei . yang
From: Fei Yang The design is to keep Buffer Object's caching policy immutable through out its life cycle. This patch ends the support for set caching ioctl from MTL onward. While doing that we also set BO's to be 1-way coherent at creation time because GPU is no longer automatically snooping CPU

[PATCH v3 3/5] drm/i915: make sure correct pte encode is used

2023-04-27 Thread fei . yang
From: Fei Yang PTE encode is platform dependent. After replacing cache_level with pat_index, the newly introduced mtl_pte_encode is actually generic for all gen12 platforms, thus rename it to gen12_pte_encode and apply it to all gen12 platforms. Cc: Chris Wilson Cc: Matt Roper Signed-off

[PATCH v3 1/5] drm/i915: preparation for using PAT index

2023-04-27 Thread fei . yang
From: Fei Yang This patch is a preparation for replacing enum i915_cache_level with PAT index. Caching policy for buffer objects is set through the PAT index in PTE, the old i915_cache_level is not sufficient to represent all caching modes supported by the hardware. Preparing the transition

[PATCH v3 5/5] drm/i915: Allow user to set cache at BO creation

2023-04-27 Thread fei . yang
From: Fei Yang To comply with the design that buffer objects shall have immutable cache setting through out their life cycle, {set, get}_caching ioctl's are no longer supported from MTL onward. With that change caching policy can only be set at object creation time. The current code applies

[PATCH v3 0/5] drm/i915: Allow user to set cache at BO creation

2023-04-27 Thread fei . yang
From: Fei Yang The first three patches in this series are taken from https://patchwork.freedesktop.org/series/116868/ These patches are included here because the last patch has dependency on the pat_index refactor. This series is focusing on uAPI changes, 1. end support for set caching ioctl

[PATCH v3 1/3] drm/i915: preparation for using PAT index

2023-04-27 Thread fei . yang
From: Fei Yang This patch is a preparation for replacing enum i915_cache_level with PAT index. Caching policy for buffer objects is set through the PAT index in PTE, the old i915_cache_level is not sufficient to represent all caching modes supported by the hardware. Preparing the transition

[PATCH v3 3/3] drm/i915: make sure correct pte encode is used

2023-04-27 Thread fei . yang
From: Fei Yang PTE encode is platform dependent. After replacing cache_level with pat_index, the newly introduced mtl_pte_encode is actually generic for all gen12 platforms, thus rename it to gen12_pte_encode and apply it to all gen12 platforms. Cc: Chris Wilson Cc: Matt Roper Signed-off

[PATCH v3 0/3] drm/i915: use pat_index instead of cache_level

2023-04-27 Thread fei . yang
From: Fei Yang This patch set was posted at https://patchwork.freedesktop.org/series/116868/ Change title since the PTE patch was merged separately. These patches are extracted from series https://patchwork.freedesktop.org/series/115980/ This series refactor the cache policy programming so

[PATCH v3 2/3] drm/i915: use pat_index instead of cache_level

2023-04-27 Thread fei . yang
From: Fei Yang Currently the KMD is using enum i915_cache_level to set caching policy for buffer objects. This is flaky because the PAT index which really controls the caching behavior in PTE has far more levels than what's defined in the enum. In addition, the PAT index is platform dependent

[PATCH v2 2/5] drm/i915: use pat_index instead of cache_level

2023-04-26 Thread fei . yang
From: Fei Yang Currently the KMD is using enum i915_cache_level to set caching policy for buffer objects. This is flaky because the PAT index which really controls the caching behavior in PTE has far more levels than what's defined in the enum. In addition, the PAT index is platform dependent

[PATCH v2 1/5] drm/i915: preparation for using PAT index

2023-04-26 Thread fei . yang
From: Fei Yang This patch is a preparation for replacing enum i915_cache_level with PAT index. Caching policy for buffer objects is set through the PAT index in PTE, the old i915_cache_level is not sufficient to represent all caching modes supported by the hardware. Preparing the transition

[PATCH v2 3/5] drm/i915: make sure correct pte encode is used

2023-04-26 Thread fei . yang
From: Fei Yang PTE encode is platform dependent. After replacing cache_level with pat_index, the newly introduced mtl_pte_encode is actually generic for all gen12 platforms, thus rename it to gen12_pte_encode and apply it to all gen12 platforms. Cc: Chris Wilson Cc: Matt Roper Signed-off

[PATCH v2 5/5] drm/i915: Allow user to set cache at BO creation

2023-04-26 Thread fei . yang
From: Fei Yang To comply with the design that buffer objects shall have immutable cache setting through out their life cycle, {set, get}_caching ioctl's are no longer supported from MTL onward. With that change caching policy can only be set at object creation time. The current code applies

[PATCH v2 0/5] drm/i915: Allow user to set cache at BO creation

2023-04-26 Thread fei . yang
From: Fei Yang The first three patches in this series are taken from https://patchwork.freedesktop.org/series/116868/ These patches are included here because the last patch has dependency on the pat_index refactor. This series is focusing on uAPI changes, 1. end support for set caching ioctl

[PATCH v2 4/5] drm/i915/mtl: end support for set caching ioctl

2023-04-26 Thread fei . yang
From: Fei Yang The design is to keep Buffer Object's caching policy immutable through out its life cycle. This patch ends the support for set caching ioctl from MTL onward. While doing that we also set BO's to be 1-way coherent at creation time because GPU is no longer automatically snooping CPU

[PATCH v2 3/3] drm/i915: make sure correct pte encode is used

2023-04-26 Thread fei . yang
From: Fei Yang PTE encode is platform dependent. After replacing cache_level with pat_index, the newly introduced mtl_pte_encode is actually generic for all gen12 platforms, thus rename it to gen12_pte_encode and apply it to all gen12 platforms. Cc: Chris Wilson Cc: Matt Roper Signed-off

[PATCH v2 2/3] drm/i915: use pat_index instead of cache_level

2023-04-26 Thread fei . yang
From: Fei Yang Currently the KMD is using enum i915_cache_level to set caching policy for buffer objects. This is flaky because the PAT index which really controls the caching behavior in PTE has far more levels than what's defined in the enum. In addition, the PAT index is platform dependent

[PATCH v2 0/3] drm/i915/mtl: add PTE encode function

2023-04-26 Thread fei . yang
From: Fei Yang These patches are extracted from series https://patchwork.freedesktop.org/series/115980/ This series refactor the cache policy programming so that the PTE encode functions can be unified across all GEN12 platforms. This refactor is also important in implementing the design which

[PATCH v2 1/3] drm/i915: preparation for using PAT index

2023-04-26 Thread fei . yang
From: Fei Yang This patch is a preparation for replacing enum i915_cache_level with PAT index. Caching policy for buffer objects is set through the PAT index in PTE, the old i915_cache_level is not sufficient to represent all caching modes supported by the hardware. Preparing the transition

[PATCH v2 2/2] drm/i915/mtl: workaround coherency issue for Media

2023-04-24 Thread fei . yang
From: Fei Yang This patch implements Wa_22016122933. In MTL, memory writes initiated by the Media tile update the whole cache line, even for partial writes. This creates a coherency problem for cacheable memory if both CPU and GPU are writing data to different locations within a single cache

[PATCH v2 0/2] drm/i915/mtl: Add PTE encode functions

2023-04-24 Thread fei . yang
From: Fei Yang Extract PTE patch from https://patchwork.freedesktop.org/series/116868/ to fix MTL boot issue caused by MOCS/PAT update. v2: address comment from Matt. Fei Yang (2): drm/i915/mtl: Add PTE encode function drm/i915/mtl: workaround coherency issue for Media drivers/gpu/drm

[PATCH v2 1/2] drm/i915/mtl: Add PTE encode function

2023-04-24 Thread fei . yang
From: Fei Yang PTE encode functions are platform dependent. This patch implements PTE functions for MTL, and ensures the correct PTE encode function is used by calling pte_encode function pointer instead of the hardcoded gen8 version of PTE encode. Fixes: b76c0deef627 ("drm/i915/mtl: D

[PATCH 2/2] drm/i915/mtl: workaround coherency issue for Media

2023-04-24 Thread fei . yang
From: Fei Yang This patch implements Wa_22016122933. In MTL, memory writes initiated by the Media tile update the whole cache line, even for partial writes. This creates a coherency problem for cacheable memory if both CPU and GPU are writing data to different locations within a single cache

[PATCH 1/2] drm/i915/mtl: Add PTE encode function

2023-04-24 Thread fei . yang
From: Fei Yang PTE encode functions are platform dependent. This patch implements PTE functions for MTL, and ensures the correct PTE encode function is used by calling pte_encode function pointer instead of the hardcoded gen8 version of PTE encode. Fixes: b76c0deef627 ("drm/i915/mtl: D

[PATCH 0/2] drm/i915/mtl: Add PTE encode functions

2023-04-24 Thread fei . yang
From: Fei Yang Extract PTE patch from https://patchwork.freedesktop.org/series/116868/ to fix MTL boot issue caused by MOCS/PAT update. Fei Yang (2): drm/i915/mtl: Add PTE encode function drm/i915/mtl: workaround coherency issue for Media drivers/gpu/drm/i915/display/intel_dpt.c | 2

[PATCH v1 6/6] drm/i915: Allow user to set cache at BO creation

2023-04-23 Thread fei . yang
From: Fei Yang To comply with the design that buffer objects shall have immutable cache setting through out their life cycle, {set, get}_caching ioctl's are no longer supported from MTL onward. With that change caching policy can only be set at object creation time. The current code applies

[PATCH v1 5/6] drm/i915/mtl: end support for set caching ioctl

2023-04-23 Thread fei . yang
From: Fei Yang The design is to keep Buffer Object's caching policy immutable through out its life cycle. This patch ends the support for set caching ioctl from MTL onward. While doing that we also set BO's to be 1-way coherent at creation time because GPU is no longer automatically snooping CPU

[PATCH v1 4/6] drm/i915: make sure correct pte encode is used

2023-04-23 Thread fei . yang
From: Fei Yang PTE encode is platform dependent. After replacing cache_level with pat_index, the newly introduced mtl_pte_encode is actually generic for all gen12 platforms, thus rename it to gen12_pte_encode and apply it to all gen12 platforms. Cc: Chris Wilson Cc: Matt Roper Signed-off

[PATCH v1 3/6] drm/i915: use pat_index instead of cache_level

2023-04-23 Thread fei . yang
From: Fei Yang Currently the KMD is using enum i915_cache_level to set caching policy for buffer objects. This is flaky because the PAT index which really controls the caching behavior in PTE has far more levels than what's defined in the enum. In addition, the PAT index is platform dependent

[PATCH v1 2/6] drm/i915: preparation for using PAT index

2023-04-23 Thread fei . yang
From: Fei Yang This patch is a preparation for replacing enum i915_cache_level with PAT index. Caching policy for buffer objects is set through the PAT index in PTE, the old i915_cache_level is not sufficient to represent all caching modes supported by the hardware. Preparing the transition

[PATCH v1 0/6] drm/i915: Allow user to set cache at BO creation

2023-04-23 Thread fei . yang
From: Fei Yang The first four patches in this series are taken from https://patchwork.freedesktop.org/series/116868/ These patches are included here because the last patch has dependency on the pat_index refactor. This series is focusing on uAPI changes, 1. end support for set caching ioctl

[PATCH v1 1/6] drm/i915/mtl: Add PTE encode function

2023-04-23 Thread fei . yang
From: Fei Yang PTE encode functions are platform dependent. This patch implements PTE functions for MTL, and ensures the correct PTE encode function is used by calling pte_encode function pointer instead of the hardcoded gen8 version of PTE encode. Signed-off-by: Fei Yang Reviewed-by: Andrzej

[PATCH v1 4/4] drm/i915: make sure correct pte encode is used

2023-04-23 Thread fei . yang
From: Fei Yang PTE encode is platform dependent. After replacing cache_level with pat_index, the newly introduced mtl_pte_encode is actually generic for all gen12 platforms, thus rename it to gen12_pte_encode and apply it to all gen12 platforms. Cc: Chris Wilson Cc: Matt Roper Signed-off

[PATCH v1 2/4] drm/i915: preparation for using PAT index

2023-04-23 Thread fei . yang
From: Fei Yang This patch is a preparation for replacing enum i915_cache_level with PAT index. Caching policy for buffer objects is set through the PAT index in PTE, the old i915_cache_level is not sufficient to represent all caching modes supported by the hardware. Preparing the transition

[PATCH v1 3/4] drm/i915: use pat_index instead of cache_level

2023-04-23 Thread fei . yang
From: Fei Yang Currently the KMD is using enum i915_cache_level to set caching policy for buffer objects. This is flaky because the PAT index which really controls the caching behavior in PTE has far more levels than what's defined in the enum. In addition, the PAT index is platform dependent

[PATCH v1 0/4] drm/i915/mtl: add PTE encode function

2023-04-23 Thread fei . yang
From: Fei Yang These patches are extracted from series https://patchwork.freedesktop.org/series/115980/ This series start with adding PTE encode functions for MTL as it can no longer reuse the PTE encode functions for GEN8 due to PAT index changes. Then there are patches refactoring the cache

[PATCH v1 1/4] drm/i915/mtl: Add PTE encode function

2023-04-23 Thread fei . yang
From: Fei Yang PTE encode functions are platform dependent. This patch implements PTE functions for MTL, and ensures the correct PTE encode function is used by calling pte_encode function pointer instead of the hardcoded gen8 version of PTE encode. Signed-off-by: Fei Yang Reviewed-by: Andrzej

[PATCH v4 8/8] drm/i915: Allow user to set cache at BO creation

2023-04-21 Thread fei . yang
From: Fei Yang To comply with the design that buffer objects shall have immutable cache setting through out their life cycle, {set, get}_caching ioctl's are no longer supported from MTL onward. With that change caching policy can only be set at object creation time. The current code applies

[PATCH v4 5/8] drm/i915: use pat_index instead of cache_level

2023-04-21 Thread fei . yang
From: Fei Yang Currently the KMD is using enum i915_cache_level to set caching policy for buffer objects. This is flaky because the PAT index which really controls the caching behavior in PTE has far more levels than what's defined in the enum. In addition, the PAT index is platform dependent

[PATCH v4 6/8] drm/i915: make sure correct pte encode is used

2023-04-21 Thread fei . yang
From: Fei Yang PTE encode is platform dependent. After replacing cache_level with pat_index, the newly introduced mtl_pte_encode is actually generic for all gen12 platforms, thus rename it to gen12_pte_encode and apply it to all gen12 platforms. Cc: Chris Wilson Cc: Matt Roper Signed-off

[PATCH v4 3/8] drm/i915/mtl: Add PTE encode function

2023-04-21 Thread fei . yang
From: Fei Yang PTE encode functions are platform dependent. This patch implements PTE functions for MTL, and ensures the correct PTE encode function is used by calling pte_encode function pointer instead of the hardcoded gen8 version of PTE encode. Signed-off-by: Fei Yang Reviewed-by: Andrzej

[PATCH v4 4/8] drm/i915: preparation for using PAT index

2023-04-21 Thread fei . yang
From: Fei Yang This patch is a preparation for replacing enum i915_cache_level with PAT index. Caching policy for buffer objects is set through the PAT index in PTE, the old i915_cache_level is not sufficient to represent all caching modes supported by the hardware. Preparing the transition

[PATCH v4 0/8] drm/i915/mtl: Define MOCS and PAT tables for MTL

2023-04-21 Thread fei . yang
From: Fei Yang The series includes patches needed to enable MTL. Also add new extension for GEM_CREATE uAPI to let user space set cache policy for buffer objects. v2: addressing review comments and checkpatch warnings v3: make mtl_ggtt_pte_encode static v4: addressing more comments from Matt

[PATCH v4 7/8] drm/i915/mtl: end support for set caching ioctl

2023-04-21 Thread fei . yang
From: Fei Yang The design is to keep Buffer Object's caching policy immutable through out its life cycle. This patch ends the support for set caching ioctl from MTL onward. While doing that we also set BO's to be 1-way coherent at creation time because GPU is no longer automatically snooping CPU

[PATCH v4 1/8] drm/i915/mtl: Define MOCS and PAT tables for MTL

2023-04-21 Thread fei . yang
index 7 to 8. This patch makes sure that these registers are programmed in the proper way. BSpec: 44509, 45101, 44235 Cc: Matt Roper Cc: Lucas De Marchi Signed-off-by: Madhumitha Tolakanahalli Pradeep Signed-off-by: Aravind Iddamsetty Signed-off-by: Nirmoy Das Signed-off-by: Fei Yang

  1   2   >