Intel-XE Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Rodrigo Vivi <rodrigo.vivi@intel.com>
To: Jani Nikula <jani.nikula@linux.intel.com>
Cc: lucas.demarchi@intel.com, matthew.d.roper@intel.com,
	john.fleck@intel.com, intel-xe@lists.freedesktop.org
Subject: Re: [Intel-xe] [PATCH 1/3] drm/xe: Introduce a module parameter to control XeLink
Date: Thu, 10 Aug 2023 18:17:28 -0400	[thread overview]
Message-ID: <ZNVh+Ph/kaOQm8ex@intel.com> (raw)
In-Reply-To: <87edkcse9d.fsf@intel.com>

On Wed, Aug 09, 2023 at 01:26:22PM +0300, Jani Nikula wrote:
> On Tue, 08 Aug 2023, Rodrigo Vivi <rodrigo.vivi@intel.com> wrote:
> > On Tue, Aug 08, 2023 at 12:45:32PM -0400, David Kershner wrote:
> >> Add a new module parameter to control enable/disable of the XeLink
> >> feature.
> >> 
> >> Signed-off-by: David Kershner <david.kershner@intel.com>
> >
> > Reviewed-by: Rodrigo Vivi <rodrigo.vivi@intel.com>
> 
> Basically the direction from upstream is crystal clear, and has been for
> years: never ask users to modify module parameters for normal operation.
> 
> Also, it's not possible to adjust this per-device.
> 
> Why are we still doing this?

Well, the last time that I looked to it was many years ago. So, someone
from the XeLink team can correct me if I am wrong or add more info.

From what I can remember, the DPA configuration needs to be set at
probe and after set I'm not confident that we have a way out of it.
And if that was set, the SRIOV cannot be used.

But right, it should be better if we could rewind the DPA settings,
and unload xelink when SRIOV starts?
Or do we have a way to block the 'child-modules'? Maybe that would
be better than the modparam itself in case we cannot rewind DPA
settings.

> 
> 
> BR,
> Jani.
> 
> 
> >
> >> ---
> >>  drivers/gpu/drm/xe/Makefile    |  3 ++-
> >>  drivers/gpu/drm/xe/xe_xelink.c | 17 +++++++++++++++++
> >>  2 files changed, 19 insertions(+), 1 deletion(-)
> >>  create mode 100644 drivers/gpu/drm/xe/xe_xelink.c
> >> 
> >> diff --git a/drivers/gpu/drm/xe/Makefile b/drivers/gpu/drm/xe/Makefile
> >> index 1b59702cd9f9..d46558cf12a9 100644
> >> --- a/drivers/gpu/drm/xe/Makefile
> >> +++ b/drivers/gpu/drm/xe/Makefile
> >> @@ -115,7 +115,8 @@ xe-y += xe_bb.o \
> >>  	xe_vm_madvise.o \
> >>  	xe_wait_user_fence.o \
> >>  	xe_wa.o \
> >> -	xe_wopcm.o
> >> +	xe_wopcm.o \
> >> +	xe_xelink.o
> >>  
> >>  # i915 Display compat #defines and #includes
> >>  subdir-ccflags-$(CONFIG_DRM_XE_DISPLAY) += \
> >> diff --git a/drivers/gpu/drm/xe/xe_xelink.c b/drivers/gpu/drm/xe/xe_xelink.c
> >> new file mode 100644
> >> index 000000000000..51a31f6a4740
> >> --- /dev/null
> >> +++ b/drivers/gpu/drm/xe/xe_xelink.c
> >> @@ -0,0 +1,17 @@
> >> +// SPDX-License-Identifier: MIT
> >> +/*
> >> + * Copyright © 2023 Intel Corporation
> >> + */
> >> +
> >> +#include <linux/moduleparam.h>
> >> +
> >> +/*
> >> + * This module parameter is needed because SRIOV PF and XeLink are mutually
> >> + * exclusive. The driver needs to be able to enable/disable the XeLink
> >> + * infrastructure (specifically Device Physical Addressing).  Since there
> >> + * will be no enable/disable for the SRIOV PF path, this parameter is
> >> + * needed to explicitly disable XeLink when SRIOV PF is required.
> >> + */
> >> +static bool xe_enable_xelink = true;
> >> +module_param_named(enable_xelink, xe_enable_xelink, bool, 0400);
> >> +MODULE_PARM_DESC(enable_xelink, "Enable XeLink feature (default: true)");
> >> -- 
> >> 2.35.1
> >> 
> 
> -- 
> Jani Nikula, Intel Open Source Graphics Center

  reply	other threads:[~2023-08-10 22:17 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-08-08 16:45 [Intel-xe] [PATCH 0/3] Add support for XeLink device David Kershner
2023-08-08 16:45 ` [Intel-xe] [PATCH 1/3] drm/xe: Introduce a module parameter to control XeLink David Kershner
2023-08-08 18:43   ` Rodrigo Vivi
2023-08-09 10:26     ` Jani Nikula
2023-08-10 22:17       ` Rodrigo Vivi [this message]
2023-08-09  3:19   ` Matthew Brost
2023-08-08 16:45 ` [Intel-xe] [PATCH 2/3] drm/xe: Introduce XeLink device David Kershner
2023-08-08 18:43   ` Rodrigo Vivi
2023-08-08 16:45 ` [Intel-xe] [PATCH 3/3] drm/xe: Teach i915 how to use objects with XeLink connectivity David Kershner
2023-08-08 18:41   ` Rodrigo Vivi

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=ZNVh+Ph/kaOQm8ex@intel.com \
    --to=rodrigo.vivi@intel.com \
    --cc=intel-xe@lists.freedesktop.org \
    --cc=jani.nikula@linux.intel.com \
    --cc=john.fleck@intel.com \
    --cc=lucas.demarchi@intel.com \
    --cc=matthew.d.roper@intel.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox