intel-gfx.lists.freedesktop.org archive mirror
 help / color / mirror / Atom feed
* [Intel-gfx] [PATCH] drm/i915: Use Transparent Hugepages when IOMMU is enabled
@ 2021-07-28 14:12 Tvrtko Ursulin
  2021-07-28 15:57 ` [Intel-gfx] ✗ Fi.CI.CHECKPATCH: warning for " Patchwork
                   ` (3 more replies)
  0 siblings, 4 replies; 5+ messages in thread
From: Tvrtko Ursulin @ 2021-07-28 14:12 UTC (permalink / raw)
  To: Intel-gfx; +Cc: Eero Tamminen, dri-devel, Chris Wilson, Matthew Auld

From: Tvrtko Ursulin <tvrtko.ursulin@intel.com>

Usage of Transparent Hugepages was disabled in 9987da4b5dcf
("drm/i915: Disable THP until we have a GPU read BW W/A"), but since it
appears majority of performance regressions reported with an enabled IOMMU
can be almost eliminated by turning them on, lets do that by adding a
couple of Kconfig options.

To err on the side of safety we keep the current default in cases where
IOMMU is not active, and only when it is default to the "huge=within_size"
mode. Although there probably would be wins to enable them throughout,
more extensive testing across benchmarks and platforms would need to be
done.

With the patch and IOMMU enabled my local testing on a small Skylake part
shows OglVSTangent regression being reduced from ~14% to ~2%.

References: b901bb89324a ("drm/i915/gemfs: enable THP")
References: 9987da4b5dcf ("drm/i915: Disable THP until we have a GPU read BW W/A")
References: https://gitlab.freedesktop.org/drm/intel/-/issues/430
Co-developed-by: Chris Wilson <chris@chris-wilson.co.uk>
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Cc: Joonas Lahtinen <joonas.lahtinen@linux.intel.com>
Cc: Matthew Auld <matthew.auld@intel.com>
Cc: Eero Tamminen <eero.t.tamminen@intel.com>
Cc: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
---
 drivers/gpu/drm/i915/Kconfig.profile  | 46 +++++++++++++++++++++++++++
 drivers/gpu/drm/i915/gem/i915_gemfs.c | 11 +++++--
 2 files changed, 55 insertions(+), 2 deletions(-)

diff --git a/drivers/gpu/drm/i915/Kconfig.profile b/drivers/gpu/drm/i915/Kconfig.profile
index 39328567c200..c64c3d39a0f9 100644
--- a/drivers/gpu/drm/i915/Kconfig.profile
+++ b/drivers/gpu/drm/i915/Kconfig.profile
@@ -119,3 +119,49 @@ config DRM_I915_TIMESLICE_DURATION
 	  /sys/class/drm/card?/engine/*/timeslice_duration_ms
 
 	  May be 0 to disable timeslicing.
+
+choice
+	prompt "Transparent Hugepage Support (native)"
+	default DRM_I915_THP_NATIVE_NEVER
+	help
+	  Select the preferred method for allocating from Transparent Hugepages
+	  when IOMMU is not enabled.
+
+	config DRM_I915_THP_NATIVE_NEVER
+	bool "Never"
+
+	config DRM_I915_THP_NATIVE_WITHIN
+	bool "Within"
+
+	config DRM_I915_THP_NATIVE_ALWAYS
+	bool "Always"
+endchoice
+
+config DRM_I915_THP_NATIVE
+	string
+	default "always" if DRM_I915_THP_NATIVE_ALWAYS
+	default "within_size" if DRM_I915_THP_NATIVE_WITHIN
+	default "never" if DRM_I915_THP_NATIVE_NEVER
+
+choice
+	prompt "Transparent Hugepage Support (IOMMU)"
+	default DRM_I915_THP_IOMMU_WITHIN
+	help
+	  Select the preferred method for allocating from Transparent Hugepages
+	  with IOMMU active.
+
+	config DRM_I915_THP_IOMMU_NEVER
+	bool "Never"
+
+	config DRM_I915_THP_IOMMU_WITHIN
+	bool "Within"
+
+	config DRM_I915_THP_IOMMU_ALWAYS
+	bool "Always"
+endchoice
+
+config DRM_I915_THP_IOMMU
+	string
+	default "always" if DRM_I915_THP_IOMMU_ALWAYS
+	default "within_size" if DRM_I915_THP_IOMMU_WITHIN
+	default "never" if DRM_I915_THP_IOMMU_NEVER
diff --git a/drivers/gpu/drm/i915/gem/i915_gemfs.c b/drivers/gpu/drm/i915/gem/i915_gemfs.c
index 5e6e8c91ab38..b71d2b2d2ada 100644
--- a/drivers/gpu/drm/i915/gem/i915_gemfs.c
+++ b/drivers/gpu/drm/i915/gem/i915_gemfs.c
@@ -13,8 +13,11 @@
 
 int i915_gemfs_init(struct drm_i915_private *i915)
 {
+	char thp_native[] = "huge=" CONFIG_DRM_I915_THP_NATIVE;
+	char thp_iommu[] = "huge=" CONFIG_DRM_I915_THP_IOMMU;
 	struct file_system_type *type;
 	struct vfsmount *gemfs;
+	char *opts;
 
 	type = get_fs_type("tmpfs");
 	if (!type)
@@ -26,15 +29,19 @@ int i915_gemfs_init(struct drm_i915_private *i915)
 	 *
 	 * One example, although it is probably better with a per-file
 	 * control, is selecting huge page allocations ("huge=within_size").
-	 * Currently unused due to bandwidth issues (slow reads) on Broadwell+.
+	 * However, we only do so to offset the overhead of iommu lookups
+	 * due to bandwidth issues (slow reads) on Broadwell+.
 	 */
+	opts = intel_vtd_active() ? thp_iommu : thp_native;
 
-	gemfs = kern_mount(type);
+	gemfs = vfs_kern_mount(type, SB_KERNMOUNT, type->name, opts);
 	if (IS_ERR(gemfs))
 		return PTR_ERR(gemfs);
 
 	i915->mm.gemfs = gemfs;
 
+	drm_info(&i915->drm, "Transparent Hugepage mode '%s'", opts);
+
 	return 0;
 }
 
-- 
2.30.2

_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

^ permalink raw reply related	[flat|nested] 5+ messages in thread

* [Intel-gfx] ✗ Fi.CI.CHECKPATCH: warning for drm/i915: Use Transparent Hugepages when IOMMU is enabled
  2021-07-28 14:12 [Intel-gfx] [PATCH] drm/i915: Use Transparent Hugepages when IOMMU is enabled Tvrtko Ursulin
@ 2021-07-28 15:57 ` Patchwork
  2021-07-28 16:16 ` [Intel-gfx] [PATCH] " Rodrigo Vivi
                   ` (2 subsequent siblings)
  3 siblings, 0 replies; 5+ messages in thread
From: Patchwork @ 2021-07-28 15:57 UTC (permalink / raw)
  To: Tvrtko Ursulin; +Cc: intel-gfx

== Series Details ==

Series: drm/i915: Use Transparent Hugepages when IOMMU is enabled
URL   : https://patchwork.freedesktop.org/series/93122/
State : warning

== Summary ==

$ dim checkpatch origin/drm-tip
1e72a7f59823 drm/i915: Use Transparent Hugepages when IOMMU is enabled
-:6: ERROR:GIT_COMMIT_ID: Please use git commit description style 'commit <12+ chars of sha1> ("<title line>")' - ie: 'commit 9987da4b5dcf ("drm/i915: Disable THP until we have a GPU read BW W/A")'
#6: 
Usage of Transparent Hugepages was disabled in 9987da4b5dcf

-:21: ERROR:GIT_COMMIT_ID: Please use git commit description style 'commit <12+ chars of sha1> ("<title line>")' - ie: 'commit b901bb89324a ("drm/i915/gemfs: enable THP")'
#21: 
References: b901bb89324a ("drm/i915/gemfs: enable THP")

-:22: WARNING:COMMIT_LOG_LONG_LINE: Possible unwrapped commit description (prefer a maximum 75 chars per line)
#22: 
References: 9987da4b5dcf ("drm/i915: Disable THP until we have a GPU read BW W/A")

-:22: ERROR:GIT_COMMIT_ID: Please use git commit description style 'commit <12+ chars of sha1> ("<title line>")' - ie: 'commit 9987da4b5dcf ("drm/i915: Disable THP until we have a GPU read BW W/A")'
#22: 
References: 9987da4b5dcf ("drm/i915: Disable THP until we have a GPU read BW W/A")

total: 3 errors, 1 warnings, 0 checks, 81 lines checked


_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [Intel-gfx] [PATCH] drm/i915: Use Transparent Hugepages when IOMMU is enabled
  2021-07-28 14:12 [Intel-gfx] [PATCH] drm/i915: Use Transparent Hugepages when IOMMU is enabled Tvrtko Ursulin
  2021-07-28 15:57 ` [Intel-gfx] ✗ Fi.CI.CHECKPATCH: warning for " Patchwork
@ 2021-07-28 16:16 ` Rodrigo Vivi
  2021-07-28 16:25 ` [Intel-gfx] ✗ Fi.CI.BAT: failure for " Patchwork
  2021-08-01 14:27 ` [Intel-gfx] [PATCH] " kernel test robot
  3 siblings, 0 replies; 5+ messages in thread
From: Rodrigo Vivi @ 2021-07-28 16:16 UTC (permalink / raw)
  To: Tvrtko Ursulin
  Cc: Intel-gfx, dri-devel, Chris Wilson, Matthew Auld, Eero Tamminen

On Wed, Jul 28, 2021 at 03:12:49PM +0100, Tvrtko Ursulin wrote:
> From: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
> 
> Usage of Transparent Hugepages was disabled in 9987da4b5dcf
> ("drm/i915: Disable THP until we have a GPU read BW W/A"), but since it
> appears majority of performance regressions reported with an enabled IOMMU
> can be almost eliminated by turning them on, lets do that by adding a
> couple of Kconfig options.
> 
> To err on the side of safety we keep the current default in cases where
> IOMMU is not active, and only when it is default to the "huge=within_size"
> mode. Although there probably would be wins to enable them throughout,
> more extensive testing across benchmarks and platforms would need to be
> done.
> 
> With the patch and IOMMU enabled my local testing on a small Skylake part
> shows OglVSTangent regression being reduced from ~14% to ~2%.
> 
> References: b901bb89324a ("drm/i915/gemfs: enable THP")
> References: 9987da4b5dcf ("drm/i915: Disable THP until we have a GPU read BW W/A")
> References: https://gitlab.freedesktop.org/drm/intel/-/issues/430
> Co-developed-by: Chris Wilson <chris@chris-wilson.co.uk>
> Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
> Cc: Joonas Lahtinen <joonas.lahtinen@linux.intel.com>
> Cc: Matthew Auld <matthew.auld@intel.com>
> Cc: Eero Tamminen <eero.t.tamminen@intel.com>
> Cc: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
> Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
> ---
>  drivers/gpu/drm/i915/Kconfig.profile  | 46 +++++++++++++++++++++++++++
>  drivers/gpu/drm/i915/gem/i915_gemfs.c | 11 +++++--
>  2 files changed, 55 insertions(+), 2 deletions(-)
> 
> diff --git a/drivers/gpu/drm/i915/Kconfig.profile b/drivers/gpu/drm/i915/Kconfig.profile
> index 39328567c200..c64c3d39a0f9 100644
> --- a/drivers/gpu/drm/i915/Kconfig.profile
> +++ b/drivers/gpu/drm/i915/Kconfig.profile
> @@ -119,3 +119,49 @@ config DRM_I915_TIMESLICE_DURATION
>  	  /sys/class/drm/card?/engine/*/timeslice_duration_ms
>  
>  	  May be 0 to disable timeslicing.
> +
> +choice
> +	prompt "Transparent Hugepage Support (native)"
> +	default DRM_I915_THP_NATIVE_NEVER
> +	help
> +	  Select the preferred method for allocating from Transparent Hugepages
> +	  when IOMMU is not enabled.
> +
> +	config DRM_I915_THP_NATIVE_NEVER
> +	bool "Never"
> +
> +	config DRM_I915_THP_NATIVE_WITHIN
> +	bool "Within"
> +
> +	config DRM_I915_THP_NATIVE_ALWAYS
> +	bool "Always"
> +endchoice
> +
> +config DRM_I915_THP_NATIVE
> +	string
> +	default "always" if DRM_I915_THP_NATIVE_ALWAYS
> +	default "within_size" if DRM_I915_THP_NATIVE_WITHIN
> +	default "never" if DRM_I915_THP_NATIVE_NEVER
> +
> +choice
> +	prompt "Transparent Hugepage Support (IOMMU)"
> +	default DRM_I915_THP_IOMMU_WITHIN
> +	help
> +	  Select the preferred method for allocating from Transparent Hugepages
> +	  with IOMMU active.
> +
> +	config DRM_I915_THP_IOMMU_NEVER
> +	bool "Never"
> +
> +	config DRM_I915_THP_IOMMU_WITHIN
> +	bool "Within"
> +
> +	config DRM_I915_THP_IOMMU_ALWAYS
> +	bool "Always"
> +endchoice
> +
> +config DRM_I915_THP_IOMMU
> +	string
> +	default "always" if DRM_I915_THP_IOMMU_ALWAYS
> +	default "within_size" if DRM_I915_THP_IOMMU_WITHIN
> +	default "never" if DRM_I915_THP_IOMMU_NEVER
> diff --git a/drivers/gpu/drm/i915/gem/i915_gemfs.c b/drivers/gpu/drm/i915/gem/i915_gemfs.c
> index 5e6e8c91ab38..b71d2b2d2ada 100644
> --- a/drivers/gpu/drm/i915/gem/i915_gemfs.c
> +++ b/drivers/gpu/drm/i915/gem/i915_gemfs.c
> @@ -13,8 +13,11 @@
>  
>  int i915_gemfs_init(struct drm_i915_private *i915)
>  {
> +	char thp_native[] = "huge=" CONFIG_DRM_I915_THP_NATIVE;
> +	char thp_iommu[] = "huge=" CONFIG_DRM_I915_THP_IOMMU;
>  	struct file_system_type *type;
>  	struct vfsmount *gemfs;
> +	char *opts;
>  
>  	type = get_fs_type("tmpfs");
>  	if (!type)
> @@ -26,15 +29,19 @@ int i915_gemfs_init(struct drm_i915_private *i915)
>  	 *
>  	 * One example, although it is probably better with a per-file
>  	 * control, is selecting huge page allocations ("huge=within_size").
> -	 * Currently unused due to bandwidth issues (slow reads) on Broadwell+.
> +	 * However, we only do so to offset the overhead of iommu lookups
> +	 * due to bandwidth issues (slow reads) on Broadwell+.
>  	 */
> +	opts = intel_vtd_active() ? thp_iommu : thp_native;

at first sight I got confused on why we where having to configs, then
very few drivers using the mount option there, so it took me a few
minutes to realize it... but I know understood the goal...

Reviewed-by: Rodrigo Vivi <rodrigo.vivi@intel.com>

>  
> -	gemfs = kern_mount(type);
> +	gemfs = vfs_kern_mount(type, SB_KERNMOUNT, type->name, opts);
>  	if (IS_ERR(gemfs))
>  		return PTR_ERR(gemfs);
>  
>  	i915->mm.gemfs = gemfs;
>  
> +	drm_info(&i915->drm, "Transparent Hugepage mode '%s'", opts);
> +
>  	return 0;
>  }
>  
> -- 
> 2.30.2
> 
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

^ permalink raw reply	[flat|nested] 5+ messages in thread

* [Intel-gfx] ✗ Fi.CI.BAT: failure for drm/i915: Use Transparent Hugepages when IOMMU is enabled
  2021-07-28 14:12 [Intel-gfx] [PATCH] drm/i915: Use Transparent Hugepages when IOMMU is enabled Tvrtko Ursulin
  2021-07-28 15:57 ` [Intel-gfx] ✗ Fi.CI.CHECKPATCH: warning for " Patchwork
  2021-07-28 16:16 ` [Intel-gfx] [PATCH] " Rodrigo Vivi
@ 2021-07-28 16:25 ` Patchwork
  2021-08-01 14:27 ` [Intel-gfx] [PATCH] " kernel test robot
  3 siblings, 0 replies; 5+ messages in thread
From: Patchwork @ 2021-07-28 16:25 UTC (permalink / raw)
  To: Tvrtko Ursulin; +Cc: intel-gfx


[-- Attachment #1.1: Type: text/plain, Size: 5956 bytes --]

== Series Details ==

Series: drm/i915: Use Transparent Hugepages when IOMMU is enabled
URL   : https://patchwork.freedesktop.org/series/93122/
State : failure

== Summary ==

CI Bug Log - changes from CI_DRM_10411 -> Patchwork_20724
====================================================

Summary
-------

  **FAILURE**

  Serious unknown changes coming with Patchwork_20724 absolutely need to be
  verified manually.
  
  If you think the reported changes have nothing to do with the changes
  introduced in Patchwork_20724, please notify your bug team to allow them
  to document this new failure mode, which will reduce false positives in CI.

  External URL: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20724/index.html

Possible new issues
-------------------

  Here are the unknown changes that may have been introduced in Patchwork_20724:

### IGT changes ###

#### Possible regressions ####

  * igt@i915_selftest@live@hugepages:
    - fi-tgl-u2:          [PASS][1] -> [DMESG-FAIL][2]
   [1]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10411/fi-tgl-u2/igt@i915_selftest@live@hugepages.html
   [2]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20724/fi-tgl-u2/igt@i915_selftest@live@hugepages.html
    - fi-icl-y:           [PASS][3] -> [DMESG-FAIL][4]
   [3]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10411/fi-icl-y/igt@i915_selftest@live@hugepages.html
   [4]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20724/fi-icl-y/igt@i915_selftest@live@hugepages.html
    - fi-ivb-3770:        [PASS][5] -> [DMESG-FAIL][6]
   [5]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10411/fi-ivb-3770/igt@i915_selftest@live@hugepages.html
   [6]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20724/fi-ivb-3770/igt@i915_selftest@live@hugepages.html
    - fi-kbl-x1275:       [PASS][7] -> [DMESG-FAIL][8]
   [7]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10411/fi-kbl-x1275/igt@i915_selftest@live@hugepages.html
   [8]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20724/fi-kbl-x1275/igt@i915_selftest@live@hugepages.html
    - fi-tgl-1115g4:      [PASS][9] -> [DMESG-FAIL][10]
   [9]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10411/fi-tgl-1115g4/igt@i915_selftest@live@hugepages.html
   [10]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20724/fi-tgl-1115g4/igt@i915_selftest@live@hugepages.html

  
#### Suppressed ####

  The following results come from untrusted machines, tests, or statuses.
  They do not affect the overall result.

  * igt@i915_selftest@live@hugepages:
    - {fi-ehl-2}:         [PASS][11] -> [DMESG-FAIL][12]
   [11]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10411/fi-ehl-2/igt@i915_selftest@live@hugepages.html
   [12]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20724/fi-ehl-2/igt@i915_selftest@live@hugepages.html
    - {fi-jsl-1}:         [PASS][13] -> [DMESG-FAIL][14]
   [13]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10411/fi-jsl-1/igt@i915_selftest@live@hugepages.html
   [14]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20724/fi-jsl-1/igt@i915_selftest@live@hugepages.html

  
Known issues
------------

  Here are the changes found in Patchwork_20724 that come from known issues:

### IGT changes ###

#### Issues hit ####

  * igt@i915_selftest@live@late_gt_pm:
    - fi-bsw-nick:        [PASS][15] -> [DMESG-FAIL][16] ([i915#2927])
   [15]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10411/fi-bsw-nick/igt@i915_selftest@live@late_gt_pm.html
   [16]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20724/fi-bsw-nick/igt@i915_selftest@live@late_gt_pm.html

  * igt@runner@aborted:
    - fi-bsw-nick:        NOTRUN -> [FAIL][17] ([fdo#109271] / [i915#1436])
   [17]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20724/fi-bsw-nick/igt@runner@aborted.html
    - fi-kbl-soraka:      NOTRUN -> [FAIL][18] ([i915#1569] / [i915#192] / [i915#193] / [i915#194] / [i915#2426] / [i915#3363])
   [18]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20724/fi-kbl-soraka/igt@runner@aborted.html

  
#### Possible fixes ####

  * igt@gem_exec_suspend@basic-s3:
    - fi-tgl-u2:          [FAIL][19] ([i915#1888]) -> [PASS][20]
   [19]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10411/fi-tgl-u2/igt@gem_exec_suspend@basic-s3.html
   [20]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20724/fi-tgl-u2/igt@gem_exec_suspend@basic-s3.html

  
  {name}: This element is suppressed. This means it is ignored when computing
          the status of the difference (SUCCESS, WARNING, or FAILURE).

  [fdo#109271]: https://bugs.freedesktop.org/show_bug.cgi?id=109271
  [i915#1436]: https://gitlab.freedesktop.org/drm/intel/issues/1436
  [i915#1569]: https://gitlab.freedesktop.org/drm/intel/issues/1569
  [i915#1888]: https://gitlab.freedesktop.org/drm/intel/issues/1888
  [i915#192]: https://gitlab.freedesktop.org/drm/intel/issues/192
  [i915#193]: https://gitlab.freedesktop.org/drm/intel/issues/193
  [i915#194]: https://gitlab.freedesktop.org/drm/intel/issues/194
  [i915#2426]: https://gitlab.freedesktop.org/drm/intel/issues/2426
  [i915#2927]: https://gitlab.freedesktop.org/drm/intel/issues/2927
  [i915#3363]: https://gitlab.freedesktop.org/drm/intel/issues/3363


Participating hosts (41 -> 36)
------------------------------

  Missing    (5): fi-ilk-m540 fi-hsw-4200u fi-bsw-cyan fi-ctg-p8600 fi-bdw-samus 


Build changes
-------------

  * Linux: CI_DRM_10411 -> Patchwork_20724

  CI-20190529: 20190529
  CI_DRM_10411: 2c25ff42a7175b652d93ac3555d4ae13456beb4a @ git://anongit.freedesktop.org/gfx-ci/linux
  IGT_6153: a5dffe7499a2f7189718ddf1ccf49060b7c1529d @ https://gitlab.freedesktop.org/drm/igt-gpu-tools.git
  Patchwork_20724: 1e72a7f598239d1265a99ab616be7f4fe4773bd0 @ git://anongit.freedesktop.org/gfx-ci/linux


== Linux commits ==

1e72a7f59823 drm/i915: Use Transparent Hugepages when IOMMU is enabled

== Logs ==

For more details see: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20724/index.html

[-- Attachment #1.2: Type: text/html, Size: 6806 bytes --]

[-- Attachment #2: Type: text/plain, Size: 160 bytes --]

_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [Intel-gfx] [PATCH] drm/i915: Use Transparent Hugepages when IOMMU is enabled
  2021-07-28 14:12 [Intel-gfx] [PATCH] drm/i915: Use Transparent Hugepages when IOMMU is enabled Tvrtko Ursulin
                   ` (2 preceding siblings ...)
  2021-07-28 16:25 ` [Intel-gfx] ✗ Fi.CI.BAT: failure for " Patchwork
@ 2021-08-01 14:27 ` kernel test robot
  3 siblings, 0 replies; 5+ messages in thread
From: kernel test robot @ 2021-08-01 14:27 UTC (permalink / raw)
  To: Tvrtko Ursulin, Intel-gfx
  Cc: kbuild-all, Eero Tamminen, dri-devel, Chris Wilson, Matthew Auld

[-- Attachment #1: Type: text/plain, Size: 3247 bytes --]

Hi Tvrtko,

Thank you for the patch! Yet something to improve:

[auto build test ERROR on drm-intel/for-linux-next]
[also build test ERROR on v5.14-rc3 next-20210730]
[If your patch is applied to the wrong git tree, kindly drop us a note.
And when submitting patch, we suggest to use '--base' as documented in
https://git-scm.com/docs/git-format-patch]

url:    https://github.com/0day-ci/linux/commits/Tvrtko-Ursulin/drm-i915-Use-Transparent-Hugepages-when-IOMMU-is-enabled/20210728-221515
base:   git://anongit.freedesktop.org/drm-intel for-linux-next
config: i386-randconfig-a015-20210728 (attached as .config)
compiler: gcc-10 (Ubuntu 10.3.0-1ubuntu1~20.04) 10.3.0
reproduce (this is a W=1 build):
        # https://github.com/0day-ci/linux/commit/26ad4b5023a428526c23ce544b593eced1916b49
        git remote add linux-review https://github.com/0day-ci/linux
        git fetch --no-tags linux-review Tvrtko-Ursulin/drm-i915-Use-Transparent-Hugepages-when-IOMMU-is-enabled/20210728-221515
        git checkout 26ad4b5023a428526c23ce544b593eced1916b49
        # save the attached .config to linux build tree
        mkdir build_dir
        make W=1 O=build_dir ARCH=i386 SHELL=/bin/bash

If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@intel.com>

All errors (new ones prefixed by >>):

   drivers/gpu/drm/i915/gem/i915_gemfs.c: In function 'i915_gemfs_init':
>> drivers/gpu/drm/i915/gem/i915_gemfs.c:16:30: error: expected ',' or ';' before 'CONFIG_DRM_I915_THP_NATIVE'
      16 |  char thp_native[] = "huge=" CONFIG_DRM_I915_THP_NATIVE;
         |                              ^~~~~~~~~~~~~~~~~~~~~~~~~~
>> drivers/gpu/drm/i915/gem/i915_gemfs.c:17:29: error: expected ',' or ';' before 'CONFIG_DRM_I915_THP_IOMMU'
      17 |  char thp_iommu[] = "huge=" CONFIG_DRM_I915_THP_IOMMU;
         |                             ^~~~~~~~~~~~~~~~~~~~~~~~~


vim +16 drivers/gpu/drm/i915/gem/i915_gemfs.c

    13	
    14	int i915_gemfs_init(struct drm_i915_private *i915)
    15	{
  > 16		char thp_native[] = "huge=" CONFIG_DRM_I915_THP_NATIVE;
  > 17		char thp_iommu[] = "huge=" CONFIG_DRM_I915_THP_IOMMU;
    18		struct file_system_type *type;
    19		struct vfsmount *gemfs;
    20		char *opts;
    21	
    22		type = get_fs_type("tmpfs");
    23		if (!type)
    24			return -ENODEV;
    25	
    26		/*
    27		 * By creating our own shmemfs mountpoint, we can pass in
    28		 * mount flags that better match our usecase.
    29		 *
    30		 * One example, although it is probably better with a per-file
    31		 * control, is selecting huge page allocations ("huge=within_size").
    32		 * However, we only do so to offset the overhead of iommu lookups
    33		 * due to bandwidth issues (slow reads) on Broadwell+.
    34		 */
    35		opts = intel_vtd_active() ? thp_iommu : thp_native;
    36	
    37		gemfs = vfs_kern_mount(type, SB_KERNMOUNT, type->name, opts);
    38		if (IS_ERR(gemfs))
    39			return PTR_ERR(gemfs);
    40	
    41		i915->mm.gemfs = gemfs;
    42	
    43		drm_info(&i915->drm, "Transparent Hugepage mode '%s'", opts);
    44	
    45		return 0;
    46	}
    47	

---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org

[-- Attachment #2: .config.gz --]
[-- Type: application/gzip, Size: 36415 bytes --]

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2021-08-01 14:27 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-07-28 14:12 [Intel-gfx] [PATCH] drm/i915: Use Transparent Hugepages when IOMMU is enabled Tvrtko Ursulin
2021-07-28 15:57 ` [Intel-gfx] ✗ Fi.CI.CHECKPATCH: warning for " Patchwork
2021-07-28 16:16 ` [Intel-gfx] [PATCH] " Rodrigo Vivi
2021-07-28 16:25 ` [Intel-gfx] ✗ Fi.CI.BAT: failure for " Patchwork
2021-08-01 14:27 ` [Intel-gfx] [PATCH] " kernel test robot

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).