public inbox for intel-gfx@lists.freedesktop.org
 help / color / mirror / Atom feed
From: Imre Deak <imre.deak@intel.com>
To: Animesh Manna <animesh.manna@intel.com>
Cc: Bharath K Veera <bharath.k.veera@intel.com>,
	intel-gfx@lists.freedesktop.org,
	Ananth Krishna R <ananth.krishna.r@intel.com>
Subject: Re: [PATCH v3 1/5] drm/i915/bxt: Corrected the guid for bxt.
Date: Fri, 10 Feb 2017 19:11:17 +0200	[thread overview]
Message-ID: <20170210171117.GC15795@ideak-desk.fi.intel.com> (raw)
In-Reply-To: <1482845396-23408-2-git-send-email-animesh.manna@intel.com>

On Tue, Dec 27, 2016 at 06:59:52PM +0530, Animesh Manna wrote:
> Guid is changed for bxt platform, so corrected the guid for bxt.
> 
> v1: Initial version as RFC.
> 
> v2: Based on review comment from Jani and David,
> have kept guid as binary format.
> 
> v3: Based on review comment from Chris and Jani,
>     - kept the const for guid.
>     - corrected the file permission.
> 
> Signed-off-by: Ananth Krishna R <ananth.krishna.r@intel.com>
> Signed-off-by: Bharath K Veera <bharath.k.veera@intel.com>
> Signed-off-by: Animesh Manna <animesh.manna@intel.com>
> ---
>  drivers/gpu/drm/i915/intel_acpi.c | 32 +++++++++++++++++++++++++-------
>  1 file changed, 25 insertions(+), 7 deletions(-)
> 
> diff --git a/drivers/gpu/drm/i915/intel_acpi.c b/drivers/gpu/drm/i915/intel_acpi.c
> index eb638a1..5c49cef 100644
> --- a/drivers/gpu/drm/i915/intel_acpi.c
> +++ b/drivers/gpu/drm/i915/intel_acpi.c
> @@ -23,6 +23,14 @@ static const u8 intel_dsm_guid[] = {
>  	0x0f, 0x13, 0x17, 0xb0, 0x1c, 0x2c
>  };
>  
> +static const u8 intel_dsm_guid_bxt[] = {
> +	0xc6, 0x41, 0x5b, 0x3e,
> +	0x1d, 0xeb,
> +	0x60, 0x42,
> +	0x9d, 0x15,
> +	0xc7, 0x1f, 0xba, 0xda, 0xe4, 0x14
> +};
> +
>  static char *intel_dsm_port_name(u8 id)
>  {
>  	switch (id) {
> @@ -113,20 +121,30 @@ static void intel_dsm_platform_mux_info(void)
>  static bool intel_dsm_pci_probe(struct pci_dev *pdev)
>  {
>  	acpi_handle dhandle;
> +	struct drm_device *dev = pci_get_drvdata(pdev);
> +	struct drm_i915_private *dev_priv = to_i915(dev);
>  
>  	dhandle = ACPI_HANDLE(&pdev->dev);
>  	if (!dhandle)
>  		return false;
>  
> -	if (!acpi_check_dsm(dhandle, intel_dsm_guid, INTEL_DSM_REVISION_ID,
> -			    1 << INTEL_DSM_FN_PLATFORM_MUX_INFO)) {
> -		DRM_DEBUG_KMS("no _DSM method for intel device\n");
> -		return false;
> -	}
> -
>  	intel_dsm_priv.dhandle = dhandle;
> -	intel_dsm_platform_mux_info();
>  
> +	if (IS_BROXTON(dev_priv)) {
> +		union acpi_object *obj;
> +
> +		obj = acpi_evaluate_dsm(dhandle, intel_dsm_guid_bxt,
> +					INTEL_DSM_REVISION_ID, 0, NULL);
> +		if (!obj)
> +			return false;
> +	} else {
> +		if (acpi_check_dsm(dhandle, intel_dsm_guid,
> +				    INTEL_DSM_REVISION_ID,
> +				    1 << INTEL_DSM_FN_PLATFORM_MUX_INFO))
> +			intel_dsm_platform_mux_info();
> +		else
> +			return false;
> +	}

So the INTEL_DSM_FN_PLATFORM_MUX_INFO handling is removed for BXT, which
isn't mentioned in the commit log. It doesn't seem correct either since
it's used to display the switcheroo DSM switching method, which is
unrelated to the low-level HPD handling you are adding here. So imo just
handle the two things separately adding a new function for the HPD stuff
and calling it from intel_dsm_detect().

>  	return true;
>  }
>  
> -- 
> 2.7.4
> 
> _______________________________________________
> Intel-gfx mailing list
> Intel-gfx@lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/intel-gfx
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

  reply	other threads:[~2017-02-10 17:11 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-12-27 13:29 [PATCH v3 0/5] HPD support during suspend for BXT/APL Animesh Manna
2016-12-27 13:29 ` [PATCH v3 1/5] drm/i915/bxt: Corrected the guid for bxt Animesh Manna
2017-02-10 17:11   ` Imre Deak [this message]
2016-12-27 13:29 ` [PATCH v3 2/5] drm/i915/bxt: VBT changes for hpd as wakeup feature Animesh Manna
2016-12-27 13:29 ` [PATCH v3 3/5] drm/i915/bxt: Added _DSM call to set HPD_CTL Animesh Manna
2017-02-10 17:15   ` Imre Deak
2016-12-27 13:29 ` [PATCH v3 4/5] drm/i915/bxt: Block D3 during suspend Animesh Manna
2016-12-27 13:29 ` [PATCH v3 5/5] drm/i915: Enable HPD interrupts with master ctl interrupt Animesh Manna
2017-02-10 17:37   ` Imre Deak
2017-02-10 18:04     ` Imre Deak
2016-12-27 13:54 ` ✗ Fi.CI.BAT: failure for HPD support during suspend for BXT/APL. (rev2) Patchwork
2016-12-28  7:42   ` [PATCH v3 5/5] drm/i915: Enable HPD interrupts with master ctl interrupt Animesh Manna
2016-12-28  9:24     ` Daniel Vetter
2017-02-10 16:13 ` [PATCH v3 0/5] HPD support during suspend for BXT/APL Imre Deak

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=20170210171117.GC15795@ideak-desk.fi.intel.com \
    --to=imre.deak@intel.com \
    --cc=ananth.krishna.r@intel.com \
    --cc=animesh.manna@intel.com \
    --cc=bharath.k.veera@intel.com \
    --cc=intel-gfx@lists.freedesktop.org \
    /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