All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH v3 0/4] nouveau RPM fixes for Optimus (final)
@ 2016-07-15 13:12 ` Peter Wu
  0 siblings, 0 replies; 20+ messages in thread
From: Peter Wu @ 2016-07-15 13:12 UTC (permalink / raw)
  To: Dave Airlie; +Cc: nouveau, dri-devel, Mika Westerberg, Bjorn Helgaas, linux-pci

Hi,

Here are two patches to fix an issue reported on kernel bugzilla (infinite loop
due to unchecked function) and a more important fix to fix hanging Optimus
machines when runtime PM is enabled (with pm/pci patches).

These are the final patches targeting v4.8. Changes compared to v2[1]:
collected R-b from Hans and Mika and fixed a minor comment style issue.

I recommend it to be merged before the pci/pm patches[2], otherwise there is a
window where newer Nvidia Optimus laptops might fail to runtime resume and/or
lock up.  Once the pci/pm branch is merged I will propose another patch to
improve reliability[3].

Known issue with patch 4: when a Nvidia HDMI audio function is present, the
bridge will not suspend and hence the Nvidia card will still be powered. Fixing
this properly will require more work[4], until then you can kill the audio
device and make runtime PM work properly:

    echo 1 > /sys/bus/pci/devices/0000:01:00.1/remove

Kind regards,
Peter

 [1]: https://lists.freedesktop.org/archives/nouveau/2016-July/025519.html
 [2]: https://git.kernel.org/cgit/linux/kernel/git/helgaas/pci.git/?h=pci/pm
 [3]: http://www.spinics.net/lists/linux-pci/msg52601.html
 [4]: https://lists.freedesktop.org/archives/dri-devel/2016-July/112759.html

Peter Wu (4):
  drm/nouveau/acpi: ensure matching ACPI handle and supported functions
  drm/nouveau/acpi: return supported DSM functions
  drm/nouveau/acpi: check for function 0x1B before using it
  drm/nouveau/acpi: fix lockup with PCIe runtime PM

 drivers/gpu/drm/nouveau/nouveau_acpi.c | 105 +++++++++++++++++++++------------
 1 file changed, 68 insertions(+), 37 deletions(-)

-- 
2.9.0

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

* [PATCH v3 0/4] nouveau RPM fixes for Optimus (final)
@ 2016-07-15 13:12 ` Peter Wu
  0 siblings, 0 replies; 20+ messages in thread
From: Peter Wu @ 2016-07-15 13:12 UTC (permalink / raw)
  To: Dave Airlie
  Cc: nouveau-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW, Bjorn Helgaas,
	Mika Westerberg, dri-devel-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW,
	linux-pci-u79uwXL29TY76Z2rM5mHXA

Hi,

Here are two patches to fix an issue reported on kernel bugzilla (infinite loop
due to unchecked function) and a more important fix to fix hanging Optimus
machines when runtime PM is enabled (with pm/pci patches).

These are the final patches targeting v4.8. Changes compared to v2[1]:
collected R-b from Hans and Mika and fixed a minor comment style issue.

I recommend it to be merged before the pci/pm patches[2], otherwise there is a
window where newer Nvidia Optimus laptops might fail to runtime resume and/or
lock up.  Once the pci/pm branch is merged I will propose another patch to
improve reliability[3].

Known issue with patch 4: when a Nvidia HDMI audio function is present, the
bridge will not suspend and hence the Nvidia card will still be powered. Fixing
this properly will require more work[4], until then you can kill the audio
device and make runtime PM work properly:

    echo 1 > /sys/bus/pci/devices/0000:01:00.1/remove

Kind regards,
Peter

 [1]: https://lists.freedesktop.org/archives/nouveau/2016-July/025519.html
 [2]: https://git.kernel.org/cgit/linux/kernel/git/helgaas/pci.git/?h=pci/pm
 [3]: http://www.spinics.net/lists/linux-pci/msg52601.html
 [4]: https://lists.freedesktop.org/archives/dri-devel/2016-July/112759.html

Peter Wu (4):
  drm/nouveau/acpi: ensure matching ACPI handle and supported functions
  drm/nouveau/acpi: return supported DSM functions
  drm/nouveau/acpi: check for function 0x1B before using it
  drm/nouveau/acpi: fix lockup with PCIe runtime PM

 drivers/gpu/drm/nouveau/nouveau_acpi.c | 105 +++++++++++++++++++++------------
 1 file changed, 68 insertions(+), 37 deletions(-)

-- 
2.9.0

_______________________________________________
Nouveau mailing list
Nouveau@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/nouveau

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

* [PATCH v3 1/4] drm/nouveau/acpi: ensure matching ACPI handle and supported functions
       [not found] ` <20160715131218.2416-1-peter-VTkQYDcBqhK7DlmcbJSQ7g@public.gmane.org>
@ 2016-07-15 13:12   ` Peter Wu
  2016-07-15 13:12   ` [PATCH v3 2/4] drm/nouveau/acpi: return supported DSM functions Peter Wu
                     ` (2 subsequent siblings)
  3 siblings, 0 replies; 20+ messages in thread
From: Peter Wu @ 2016-07-15 13:12 UTC (permalink / raw)
  To: Dave Airlie
  Cc: nouveau-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW,
	dri-devel-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW

Ensure that the returned set of supported DSM functions (MUX, Optimus)
match the ACPI handle that is set in nouveau_dsm_pci_probe.

As there are no machines with a MUX function on just one PCI device and
an Optimus on another, there should not be a functional impact. This
change however makes this implicit assumption more obvious.

Convert int to bool and rename has_dsm to has_mux while at it. Let the
caller set nouveau_dsm_priv.dhandle as needed.

 v2: pass dhandle to the caller.

Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Peter Wu <peter@lekensteyn.nl>
---
 drivers/gpu/drm/nouveau/nouveau_acpi.c | 58 +++++++++++++++-------------------
 1 file changed, 26 insertions(+), 32 deletions(-)

diff --git a/drivers/gpu/drm/nouveau/nouveau_acpi.c b/drivers/gpu/drm/nouveau/nouveau_acpi.c
index db76b94..886a67c 100644
--- a/drivers/gpu/drm/nouveau/nouveau_acpi.c
+++ b/drivers/gpu/drm/nouveau/nouveau_acpi.c
@@ -57,9 +57,6 @@ bool nouveau_is_v1_dsm(void) {
 	return nouveau_dsm_priv.dsm_detected;
 }
 
-#define NOUVEAU_DSM_HAS_MUX 0x1
-#define NOUVEAU_DSM_HAS_OPT 0x2
-
 #ifdef CONFIG_VGA_SWITCHEROO
 static const char nouveau_dsm_muid[] = {
 	0xA0, 0xA0, 0x95, 0x9D, 0x60, 0x00, 0x48, 0x4D,
@@ -212,26 +209,33 @@ static const struct vga_switcheroo_handler nouveau_dsm_handler = {
 	.get_client_id = nouveau_dsm_get_client_id,
 };
 
-static int nouveau_dsm_pci_probe(struct pci_dev *pdev)
+static void nouveau_dsm_pci_probe(struct pci_dev *pdev, acpi_handle *dhandle_out,
+				  bool *has_mux, bool *has_opt)
 {
 	acpi_handle dhandle;
-	int retval = 0;
+	bool supports_mux;
+	bool supports_opt;
 
 	dhandle = ACPI_HANDLE(&pdev->dev);
 	if (!dhandle)
-		return false;
+		return;
 
 	if (!acpi_has_method(dhandle, "_DSM"))
-		return false;
+		return;
 
-	if (acpi_check_dsm(dhandle, nouveau_dsm_muid, 0x00000102,
-			   1 << NOUVEAU_DSM_POWER))
-		retval |= NOUVEAU_DSM_HAS_MUX;
+	supports_mux = acpi_check_dsm(dhandle, nouveau_dsm_muid, 0x00000102,
+				      1 << NOUVEAU_DSM_POWER);
+	supports_opt = nouveau_check_optimus_dsm(dhandle);
 
-	if (nouveau_check_optimus_dsm(dhandle))
-		retval |= NOUVEAU_DSM_HAS_OPT;
+	/* Does not look like a Nvidia device. */
+	if (!supports_mux && !supports_opt)
+		return;
 
-	if (retval & NOUVEAU_DSM_HAS_OPT) {
+	*dhandle_out = dhandle;
+	*has_mux = supports_mux;
+	*has_opt = supports_opt;
+
+	if (supports_opt) {
 		uint32_t result;
 		nouveau_optimus_dsm(dhandle, NOUVEAU_DSM_OPTIMUS_CAPS, 0,
 				    &result);
@@ -240,10 +244,6 @@ static int nouveau_dsm_pci_probe(struct pci_dev *pdev)
 			 (result & OPTIMUS_DYNAMIC_PWR_CAP) ? "dynamic power, " : "",
 			 (result & OPTIMUS_HDA_CODEC_MASK) ? "hda bios codec supported" : "");
 	}
-	if (retval)
-		nouveau_dsm_priv.dhandle = dhandle;
-
-	return retval;
 }
 
 static bool nouveau_dsm_detect(void)
@@ -251,11 +251,11 @@ static bool nouveau_dsm_detect(void)
 	char acpi_method_name[255] = { 0 };
 	struct acpi_buffer buffer = {sizeof(acpi_method_name), acpi_method_name};
 	struct pci_dev *pdev = NULL;
-	int has_dsm = 0;
-	int has_optimus = 0;
+	acpi_handle dhandle = NULL;
+	bool has_mux = false;
+	bool has_optimus = false;
 	int vga_count = 0;
 	bool guid_valid;
-	int retval;
 	bool ret = false;
 
 	/* lookup the MXM GUID */
@@ -268,32 +268,26 @@ static bool nouveau_dsm_detect(void)
 	while ((pdev = pci_get_class(PCI_CLASS_DISPLAY_VGA << 8, pdev)) != NULL) {
 		vga_count++;
 
-		retval = nouveau_dsm_pci_probe(pdev);
-		if (retval & NOUVEAU_DSM_HAS_MUX)
-			has_dsm |= 1;
-		if (retval & NOUVEAU_DSM_HAS_OPT)
-			has_optimus = 1;
+		nouveau_dsm_pci_probe(pdev, &dhandle, &has_mux, &has_optimus);
 	}
 
 	while ((pdev = pci_get_class(PCI_CLASS_DISPLAY_3D << 8, pdev)) != NULL) {
 		vga_count++;
 
-		retval = nouveau_dsm_pci_probe(pdev);
-		if (retval & NOUVEAU_DSM_HAS_MUX)
-			has_dsm |= 1;
-		if (retval & NOUVEAU_DSM_HAS_OPT)
-			has_optimus = 1;
+		nouveau_dsm_pci_probe(pdev, &dhandle, &has_mux, &has_optimus);
 	}
 
 	/* find the optimus DSM or the old v1 DSM */
-	if (has_optimus == 1) {
+	if (has_optimus) {
+		nouveau_dsm_priv.dhandle = dhandle;
 		acpi_get_name(nouveau_dsm_priv.dhandle, ACPI_FULL_PATHNAME,
 			&buffer);
 		printk(KERN_INFO "VGA switcheroo: detected Optimus DSM method %s handle\n",
 			acpi_method_name);
 		nouveau_dsm_priv.optimus_detected = true;
 		ret = true;
-	} else if (vga_count == 2 && has_dsm && guid_valid) {
+	} else if (vga_count == 2 && has_mux && guid_valid) {
+		nouveau_dsm_priv.dhandle = dhandle;
 		acpi_get_name(nouveau_dsm_priv.dhandle, ACPI_FULL_PATHNAME,
 			&buffer);
 		printk(KERN_INFO "VGA switcheroo: detected DSM switching method %s handle\n",
-- 
2.9.0

_______________________________________________
Nouveau mailing list
Nouveau@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/nouveau

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

* [PATCH v3 2/4] drm/nouveau/acpi: return supported DSM functions
       [not found] ` <20160715131218.2416-1-peter-VTkQYDcBqhK7DlmcbJSQ7g@public.gmane.org>
  2016-07-15 13:12   ` [PATCH v3 1/4] drm/nouveau/acpi: ensure matching ACPI handle and supported functions Peter Wu
@ 2016-07-15 13:12   ` Peter Wu
  2016-07-15 13:12   ` [PATCH v3 3/4] drm/nouveau/acpi: check for function 0x1B before using it Peter Wu
  2016-07-27 12:02   ` [PATCH v3 0/4] nouveau RPM fixes for Optimus (final) Peter Wu
  3 siblings, 0 replies; 20+ messages in thread
From: Peter Wu @ 2016-07-15 13:12 UTC (permalink / raw)
  To: Dave Airlie
  Cc: nouveau-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW,
	dri-devel-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW

Return the set of supported functions to the caller. No functional
changes.

Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Peter Wu <peter@lekensteyn.nl>
---
 drivers/gpu/drm/nouveau/nouveau_acpi.c | 16 +++++++++-------
 1 file changed, 9 insertions(+), 7 deletions(-)

diff --git a/drivers/gpu/drm/nouveau/nouveau_acpi.c b/drivers/gpu/drm/nouveau/nouveau_acpi.c
index 886a67c..572ac30 100644
--- a/drivers/gpu/drm/nouveau/nouveau_acpi.c
+++ b/drivers/gpu/drm/nouveau/nouveau_acpi.c
@@ -107,7 +107,7 @@ static int nouveau_optimus_dsm(acpi_handle handle, int func, int arg, uint32_t *
  * requirements on the fourth parameter, so a private implementation
  * instead of using acpi_check_dsm().
  */
-static int nouveau_check_optimus_dsm(acpi_handle handle)
+static int nouveau_dsm_get_optimus_functions(acpi_handle handle)
 {
 	int result;
 
@@ -122,7 +122,9 @@ static int nouveau_check_optimus_dsm(acpi_handle handle)
 	 * ACPI Spec v4 9.14.1: if bit 0 is zero, no function is supported.
 	 * If the n-th bit is enabled, function n is supported
 	 */
-	return result & 1 && result & (1 << NOUVEAU_DSM_OPTIMUS_CAPS);
+	if (result & 1 && result & (1 << NOUVEAU_DSM_OPTIMUS_CAPS))
+		return result;
+	return 0;
 }
 
 static int nouveau_dsm(acpi_handle handle, int func, int arg)
@@ -214,7 +216,7 @@ static void nouveau_dsm_pci_probe(struct pci_dev *pdev, acpi_handle *dhandle_out
 {
 	acpi_handle dhandle;
 	bool supports_mux;
-	bool supports_opt;
+	int optimus_funcs;
 
 	dhandle = ACPI_HANDLE(&pdev->dev);
 	if (!dhandle)
@@ -225,17 +227,17 @@ static void nouveau_dsm_pci_probe(struct pci_dev *pdev, acpi_handle *dhandle_out
 
 	supports_mux = acpi_check_dsm(dhandle, nouveau_dsm_muid, 0x00000102,
 				      1 << NOUVEAU_DSM_POWER);
-	supports_opt = nouveau_check_optimus_dsm(dhandle);
+	optimus_funcs = nouveau_dsm_get_optimus_functions(dhandle);
 
 	/* Does not look like a Nvidia device. */
-	if (!supports_mux && !supports_opt)
+	if (!supports_mux && !optimus_funcs)
 		return;
 
 	*dhandle_out = dhandle;
 	*has_mux = supports_mux;
-	*has_opt = supports_opt;
+	*has_opt = !!optimus_funcs;
 
-	if (supports_opt) {
+	if (optimus_funcs) {
 		uint32_t result;
 		nouveau_optimus_dsm(dhandle, NOUVEAU_DSM_OPTIMUS_CAPS, 0,
 				    &result);
-- 
2.9.0

_______________________________________________
Nouveau mailing list
Nouveau@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/nouveau

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

* [PATCH v3 3/4] drm/nouveau/acpi: check for function 0x1B before using it
       [not found] ` <20160715131218.2416-1-peter-VTkQYDcBqhK7DlmcbJSQ7g@public.gmane.org>
  2016-07-15 13:12   ` [PATCH v3 1/4] drm/nouveau/acpi: ensure matching ACPI handle and supported functions Peter Wu
  2016-07-15 13:12   ` [PATCH v3 2/4] drm/nouveau/acpi: return supported DSM functions Peter Wu
@ 2016-07-15 13:12   ` Peter Wu
  2016-07-27 12:02   ` [PATCH v3 0/4] nouveau RPM fixes for Optimus (final) Peter Wu
  3 siblings, 0 replies; 20+ messages in thread
From: Peter Wu @ 2016-07-15 13:12 UTC (permalink / raw)
  To: Dave Airlie
  Cc: nouveau-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW,
	dri-devel-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW

Do not unconditionally invoke function 0x1B without checking for its
availability, it leads to an infinite loop on some firmware.

Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=104791
Fixes: 5addcf0a5f0fad ("nouveau: add runtime PM support (v0.9)")
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Peter Wu <peter@lekensteyn.nl>
---
 drivers/gpu/drm/nouveau/nouveau_acpi.c | 18 +++++++++++++-----
 1 file changed, 13 insertions(+), 5 deletions(-)

diff --git a/drivers/gpu/drm/nouveau/nouveau_acpi.c b/drivers/gpu/drm/nouveau/nouveau_acpi.c
index 572ac30..ad273ad 100644
--- a/drivers/gpu/drm/nouveau/nouveau_acpi.c
+++ b/drivers/gpu/drm/nouveau/nouveau_acpi.c
@@ -45,6 +45,7 @@
 static struct nouveau_dsm_priv {
 	bool dsm_detected;
 	bool optimus_detected;
+	bool optimus_flags_detected;
 	acpi_handle dhandle;
 	acpi_handle rom_handle;
 } nouveau_dsm_priv;
@@ -212,7 +213,8 @@ static const struct vga_switcheroo_handler nouveau_dsm_handler = {
 };
 
 static void nouveau_dsm_pci_probe(struct pci_dev *pdev, acpi_handle *dhandle_out,
-				  bool *has_mux, bool *has_opt)
+				  bool *has_mux, bool *has_opt,
+				  bool *has_opt_flags)
 {
 	acpi_handle dhandle;
 	bool supports_mux;
@@ -236,6 +238,7 @@ static void nouveau_dsm_pci_probe(struct pci_dev *pdev, acpi_handle *dhandle_out
 	*dhandle_out = dhandle;
 	*has_mux = supports_mux;
 	*has_opt = !!optimus_funcs;
+	*has_opt_flags = optimus_funcs & (1 << NOUVEAU_DSM_OPTIMUS_FLAGS);
 
 	if (optimus_funcs) {
 		uint32_t result;
@@ -256,6 +259,7 @@ static bool nouveau_dsm_detect(void)
 	acpi_handle dhandle = NULL;
 	bool has_mux = false;
 	bool has_optimus = false;
+	bool has_optimus_flags = false;
 	int vga_count = 0;
 	bool guid_valid;
 	bool ret = false;
@@ -270,13 +274,15 @@ static bool nouveau_dsm_detect(void)
 	while ((pdev = pci_get_class(PCI_CLASS_DISPLAY_VGA << 8, pdev)) != NULL) {
 		vga_count++;
 
-		nouveau_dsm_pci_probe(pdev, &dhandle, &has_mux, &has_optimus);
+		nouveau_dsm_pci_probe(pdev, &dhandle, &has_mux, &has_optimus,
+				      &has_optimus_flags);
 	}
 
 	while ((pdev = pci_get_class(PCI_CLASS_DISPLAY_3D << 8, pdev)) != NULL) {
 		vga_count++;
 
-		nouveau_dsm_pci_probe(pdev, &dhandle, &has_mux, &has_optimus);
+		nouveau_dsm_pci_probe(pdev, &dhandle, &has_mux, &has_optimus,
+				      &has_optimus_flags);
 	}
 
 	/* find the optimus DSM or the old v1 DSM */
@@ -287,6 +293,7 @@ static bool nouveau_dsm_detect(void)
 		printk(KERN_INFO "VGA switcheroo: detected Optimus DSM method %s handle\n",
 			acpi_method_name);
 		nouveau_dsm_priv.optimus_detected = true;
+		nouveau_dsm_priv.optimus_flags_detected = has_optimus_flags;
 		ret = true;
 	} else if (vga_count == 2 && has_mux && guid_valid) {
 		nouveau_dsm_priv.dhandle = dhandle;
@@ -320,8 +327,9 @@ void nouveau_switcheroo_optimus_dsm(void)
 	if (!nouveau_dsm_priv.optimus_detected)
 		return;
 
-	nouveau_optimus_dsm(nouveau_dsm_priv.dhandle, NOUVEAU_DSM_OPTIMUS_FLAGS,
-			    0x3, &result);
+	if (nouveau_dsm_priv.optimus_flags_detected)
+		nouveau_optimus_dsm(nouveau_dsm_priv.dhandle, NOUVEAU_DSM_OPTIMUS_FLAGS,
+				    0x3, &result);
 
 	nouveau_optimus_dsm(nouveau_dsm_priv.dhandle, NOUVEAU_DSM_OPTIMUS_CAPS,
 		NOUVEAU_DSM_OPTIMUS_SET_POWERDOWN, &result);
-- 
2.9.0

_______________________________________________
Nouveau mailing list
Nouveau@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/nouveau

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

* [PATCH v3 4/4] drm/nouveau/acpi: fix lockup with PCIe runtime PM
  2016-07-15 13:12 ` Peter Wu
  (?)
@ 2016-07-15 13:12 ` Peter Wu
  -1 siblings, 0 replies; 20+ messages in thread
From: Peter Wu @ 2016-07-15 13:12 UTC (permalink / raw)
  To: Dave Airlie
  Cc: nouveau, dri-devel, Mika Westerberg, Bjorn Helgaas, linux-pci, linux-pm

Since "PCI: Add runtime PM support for PCIe ports", the parent PCIe port
can be runtime-suspended which disables power resources via ACPI. This
is incompatible with DSM, resulting in a GPU device which is still in D3
and locks up the kernel on resume (on a Clevo P651RA, GTX965M).

Mirror the behavior of Windows 8 and newer[1] (as observed via an AMLi
debugger trace) and stop using the DSM functions for D3cold when power
resources are available on the parent PCIe port.

pci_d3cold_disable() is not used because on some machines, the old DSM
method is broken. On a Lenovo T440p (GT 730M) memory and disk corruption
would occur, but that is fixed with this patch[2].

 [1]: https://msdn.microsoft.com/windows/hardware/drivers/bringup/firmware-requirements-for-d3cold
 [2]: https://github.com/Bumblebee-Project/bbswitch/issues/78#issuecomment-223549072

 v2: simply check directly for _PR3. Added affected machines.
 v3: fixed block comment coding style.

Reviewed-by: Mika Westerberg <mika.westerberg@linux.intel.com>
Signed-off-by: Peter Wu <peter@lekensteyn.nl>
---
 drivers/gpu/drm/nouveau/nouveau_acpi.c | 35 ++++++++++++++++++++++++++++++----
 1 file changed, 31 insertions(+), 4 deletions(-)

diff --git a/drivers/gpu/drm/nouveau/nouveau_acpi.c b/drivers/gpu/drm/nouveau/nouveau_acpi.c
index ad273ad..f2ad17a 100644
--- a/drivers/gpu/drm/nouveau/nouveau_acpi.c
+++ b/drivers/gpu/drm/nouveau/nouveau_acpi.c
@@ -46,6 +46,7 @@ static struct nouveau_dsm_priv {
 	bool dsm_detected;
 	bool optimus_detected;
 	bool optimus_flags_detected;
+	bool optimus_skip_dsm;
 	acpi_handle dhandle;
 	acpi_handle rom_handle;
 } nouveau_dsm_priv;
@@ -212,9 +213,28 @@ static const struct vga_switcheroo_handler nouveau_dsm_handler = {
 	.get_client_id = nouveau_dsm_get_client_id,
 };
 
+/*
+ * Firmware supporting Windows 8 or later do not use _DSM to put the device into
+ * D3cold, they instead rely on disabling power resources on the parent.
+ */
+static bool nouveau_pr3_present(struct pci_dev *pdev)
+{
+	struct pci_dev *parent_pdev = pci_upstream_bridge(pdev);
+	struct acpi_device *parent_adev;
+
+	if (!parent_pdev)
+		return false;
+
+	parent_adev = ACPI_COMPANION(&parent_pdev->dev);
+	if (!parent_adev)
+		return false;
+
+	return acpi_has_method(parent_adev->handle, "_PR3");
+}
+
 static void nouveau_dsm_pci_probe(struct pci_dev *pdev, acpi_handle *dhandle_out,
 				  bool *has_mux, bool *has_opt,
-				  bool *has_opt_flags)
+				  bool *has_opt_flags, bool *has_pr3)
 {
 	acpi_handle dhandle;
 	bool supports_mux;
@@ -239,6 +259,7 @@ static void nouveau_dsm_pci_probe(struct pci_dev *pdev, acpi_handle *dhandle_out
 	*has_mux = supports_mux;
 	*has_opt = !!optimus_funcs;
 	*has_opt_flags = optimus_funcs & (1 << NOUVEAU_DSM_OPTIMUS_FLAGS);
+	*has_pr3 = false;
 
 	if (optimus_funcs) {
 		uint32_t result;
@@ -248,6 +269,8 @@ static void nouveau_dsm_pci_probe(struct pci_dev *pdev, acpi_handle *dhandle_out
 			 (result & OPTIMUS_ENABLED) ? "enabled" : "disabled",
 			 (result & OPTIMUS_DYNAMIC_PWR_CAP) ? "dynamic power, " : "",
 			 (result & OPTIMUS_HDA_CODEC_MASK) ? "hda bios codec supported" : "");
+
+		*has_pr3 = nouveau_pr3_present(pdev);
 	}
 }
 
@@ -260,6 +283,7 @@ static bool nouveau_dsm_detect(void)
 	bool has_mux = false;
 	bool has_optimus = false;
 	bool has_optimus_flags = false;
+	bool has_power_resources = false;
 	int vga_count = 0;
 	bool guid_valid;
 	bool ret = false;
@@ -275,14 +299,14 @@ static bool nouveau_dsm_detect(void)
 		vga_count++;
 
 		nouveau_dsm_pci_probe(pdev, &dhandle, &has_mux, &has_optimus,
-				      &has_optimus_flags);
+				      &has_optimus_flags, &has_power_resources);
 	}
 
 	while ((pdev = pci_get_class(PCI_CLASS_DISPLAY_3D << 8, pdev)) != NULL) {
 		vga_count++;
 
 		nouveau_dsm_pci_probe(pdev, &dhandle, &has_mux, &has_optimus,
-				      &has_optimus_flags);
+				      &has_optimus_flags, &has_power_resources);
 	}
 
 	/* find the optimus DSM or the old v1 DSM */
@@ -292,8 +316,11 @@ static bool nouveau_dsm_detect(void)
 			&buffer);
 		printk(KERN_INFO "VGA switcheroo: detected Optimus DSM method %s handle\n",
 			acpi_method_name);
+		if (has_power_resources)
+			pr_info("nouveau: detected PR support, will not use DSM\n");
 		nouveau_dsm_priv.optimus_detected = true;
 		nouveau_dsm_priv.optimus_flags_detected = has_optimus_flags;
+		nouveau_dsm_priv.optimus_skip_dsm = has_power_resources;
 		ret = true;
 	} else if (vga_count == 2 && has_mux && guid_valid) {
 		nouveau_dsm_priv.dhandle = dhandle;
@@ -324,7 +351,7 @@ void nouveau_register_dsm_handler(void)
 void nouveau_switcheroo_optimus_dsm(void)
 {
 	u32 result = 0;
-	if (!nouveau_dsm_priv.optimus_detected)
+	if (!nouveau_dsm_priv.optimus_detected || nouveau_dsm_priv.optimus_skip_dsm)
 		return;
 
 	if (nouveau_dsm_priv.optimus_flags_detected)
-- 
2.9.0

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

* Re: [Nouveau] [PATCH v3 0/4] nouveau RPM fixes for Optimus (final)
       [not found] ` <20160715131218.2416-1-peter-VTkQYDcBqhK7DlmcbJSQ7g@public.gmane.org>
@ 2016-07-15 16:10   ` Ilia Mirkin
  2016-07-15 13:12   ` [PATCH v3 2/4] drm/nouveau/acpi: return supported DSM functions Peter Wu
                     ` (2 subsequent siblings)
  3 siblings, 0 replies; 20+ messages in thread
From: Ilia Mirkin @ 2016-07-15 16:10 UTC (permalink / raw)
  To: Peter Wu
  Cc: Dave Airlie, nouveau, Bjorn Helgaas, Mika Westerberg, dri-devel,
	linux-pci

On Fri, Jul 15, 2016 at 9:12 AM, Peter Wu <peter@lekensteyn.nl> wrote:
> Hi,
>
> Here are two patches to fix an issue reported on kernel bugzilla (infinite loop
> due to unchecked function) and a more important fix to fix hanging Optimus
> machines when runtime PM is enabled (with pm/pci patches).
>
> These are the final patches targeting v4.8. Changes compared to v2[1]:
> collected R-b from Hans and Mika and fixed a minor comment style issue.
>
> I recommend it to be merged before the pci/pm patches[2], otherwise there is a
> window where newer Nvidia Optimus laptops might fail to runtime resume and/or
> lock up.  Once the pci/pm branch is merged I will propose another patch to
> improve reliability[3].
>
> Known issue with patch 4: when a Nvidia HDMI audio function is present, the
> bridge will not suspend and hence the Nvidia card will still be powered. Fixing

That's basically all optimus gpu's, right? Anything GT21x+ has a HDMI
audio subfunction, and prior to that, the nvidia gpu tended to be the
only gpu, or hard-muxed.

If that's the case, that's pretty much a non-starter, IMO.

  -ilia

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

* Re: [PATCH v3 0/4] nouveau RPM fixes for Optimus (final)
@ 2016-07-15 16:10   ` Ilia Mirkin
  0 siblings, 0 replies; 20+ messages in thread
From: Ilia Mirkin @ 2016-07-15 16:10 UTC (permalink / raw)
  To: Peter Wu
  Cc: linux-pci-u79uwXL29TY76Z2rM5mHXA,
	dri-devel-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW, Bjorn Helgaas,
	nouveau-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW, Dave Airlie,
	Mika Westerberg

On Fri, Jul 15, 2016 at 9:12 AM, Peter Wu <peter@lekensteyn.nl> wrote:
> Hi,
>
> Here are two patches to fix an issue reported on kernel bugzilla (infinite loop
> due to unchecked function) and a more important fix to fix hanging Optimus
> machines when runtime PM is enabled (with pm/pci patches).
>
> These are the final patches targeting v4.8. Changes compared to v2[1]:
> collected R-b from Hans and Mika and fixed a minor comment style issue.
>
> I recommend it to be merged before the pci/pm patches[2], otherwise there is a
> window where newer Nvidia Optimus laptops might fail to runtime resume and/or
> lock up.  Once the pci/pm branch is merged I will propose another patch to
> improve reliability[3].
>
> Known issue with patch 4: when a Nvidia HDMI audio function is present, the
> bridge will not suspend and hence the Nvidia card will still be powered. Fixing

That's basically all optimus gpu's, right? Anything GT21x+ has a HDMI
audio subfunction, and prior to that, the nvidia gpu tended to be the
only gpu, or hard-muxed.

If that's the case, that's pretty much a non-starter, IMO.

  -ilia
_______________________________________________
Nouveau mailing list
Nouveau@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/nouveau

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

* Re: [Nouveau] [PATCH v3 0/4] nouveau RPM fixes for Optimus (final)
  2016-07-15 16:10   ` Ilia Mirkin
  (?)
@ 2016-07-15 16:27   ` Alex Deucher
  2016-07-15 16:31     ` Ilia Mirkin
  -1 siblings, 1 reply; 20+ messages in thread
From: Alex Deucher @ 2016-07-15 16:27 UTC (permalink / raw)
  To: Ilia Mirkin
  Cc: Peter Wu, Linux PCI, dri-devel, Bjorn Helgaas, nouveau,
	Dave Airlie, Mika Westerberg

On Fri, Jul 15, 2016 at 12:10 PM, Ilia Mirkin <imirkin@alum.mit.edu> wrote:
> On Fri, Jul 15, 2016 at 9:12 AM, Peter Wu <peter@lekensteyn.nl> wrote:
>> Hi,
>>
>> Here are two patches to fix an issue reported on kernel bugzilla (infinite loop
>> due to unchecked function) and a more important fix to fix hanging Optimus
>> machines when runtime PM is enabled (with pm/pci patches).
>>
>> These are the final patches targeting v4.8. Changes compared to v2[1]:
>> collected R-b from Hans and Mika and fixed a minor comment style issue.
>>
>> I recommend it to be merged before the pci/pm patches[2], otherwise there is a
>> window where newer Nvidia Optimus laptops might fail to runtime resume and/or
>> lock up.  Once the pci/pm branch is merged I will propose another patch to
>> improve reliability[3].
>>
>> Known issue with patch 4: when a Nvidia HDMI audio function is present, the
>> bridge will not suspend and hence the Nvidia card will still be powered. Fixing
>
> That's basically all optimus gpu's, right? Anything GT21x+ has a HDMI
> audio subfunction, and prior to that, the nvidia gpu tended to be the
> only gpu, or hard-muxed.

I'd imagine there is a strap on the asic so the audio function is only
enabled if there is a connector actually wired to the dGPU.  It
doesn't make much sense to expose audio if there is no way to use it.

Alex

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

* Re: [Nouveau] [PATCH v3 0/4] nouveau RPM fixes for Optimus (final)
  2016-07-15 16:27   ` [Nouveau] " Alex Deucher
@ 2016-07-15 16:31     ` Ilia Mirkin
  2016-07-15 16:40         ` Alex Deucher
  0 siblings, 1 reply; 20+ messages in thread
From: Ilia Mirkin @ 2016-07-15 16:31 UTC (permalink / raw)
  To: Alex Deucher
  Cc: Peter Wu, Linux PCI, dri-devel, Bjorn Helgaas, nouveau,
	Dave Airlie, Mika Westerberg

On Fri, Jul 15, 2016 at 12:27 PM, Alex Deucher <alexdeucher@gmail.com> wrote:
> On Fri, Jul 15, 2016 at 12:10 PM, Ilia Mirkin <imirkin@alum.mit.edu> wrote:
>> On Fri, Jul 15, 2016 at 9:12 AM, Peter Wu <peter@lekensteyn.nl> wrote:
>>> Hi,
>>>
>>> Here are two patches to fix an issue reported on kernel bugzilla (infinite loop
>>> due to unchecked function) and a more important fix to fix hanging Optimus
>>> machines when runtime PM is enabled (with pm/pci patches).
>>>
>>> These are the final patches targeting v4.8. Changes compared to v2[1]:
>>> collected R-b from Hans and Mika and fixed a minor comment style issue.
>>>
>>> I recommend it to be merged before the pci/pm patches[2], otherwise there is a
>>> window where newer Nvidia Optimus laptops might fail to runtime resume and/or
>>> lock up.  Once the pci/pm branch is merged I will propose another patch to
>>> improve reliability[3].
>>>
>>> Known issue with patch 4: when a Nvidia HDMI audio function is present, the
>>> bridge will not suspend and hence the Nvidia card will still be powered. Fixing
>>
>> That's basically all optimus gpu's, right? Anything GT21x+ has a HDMI
>> audio subfunction, and prior to that, the nvidia gpu tended to be the
>> only gpu, or hard-muxed.
>
> I'd imagine there is a strap on the asic so the audio function is only
> enabled if there is a connector actually wired to the dGPU.  It
> doesn't make much sense to expose audio if there is no way to use it.

A lot of the time, there actually is a connector wired up. A lot of
the other time, there is no connector, but the display unit is still
there. Very recently, NVIDIA gpu's have started coming out marked as
"3d accelerator", which sometimes but not always means that there's no
display unit, and for those, I would assume there is no audio
subfunction.

However this is a fraction of all devices using runpm.

  -ilia

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

* Re: [Nouveau] [PATCH v3 0/4] nouveau RPM fixes for Optimus (final)
  2016-07-15 16:10   ` Ilia Mirkin
  (?)
  (?)
@ 2016-07-15 16:36   ` Peter Wu
  2016-07-15 16:41     ` Ilia Mirkin
  -1 siblings, 1 reply; 20+ messages in thread
From: Peter Wu @ 2016-07-15 16:36 UTC (permalink / raw)
  To: Ilia Mirkin
  Cc: Dave Airlie, nouveau, Bjorn Helgaas, Mika Westerberg, dri-devel,
	linux-pci

On Fri, Jul 15, 2016 at 12:10:23PM -0400, Ilia Mirkin wrote:
> On Fri, Jul 15, 2016 at 9:12 AM, Peter Wu <peter@lekensteyn.nl> wrote:
> > Hi,
> >
> > Here are two patches to fix an issue reported on kernel bugzilla (infinite loop
> > due to unchecked function) and a more important fix to fix hanging Optimus
> > machines when runtime PM is enabled (with pm/pci patches).
> >
> > These are the final patches targeting v4.8. Changes compared to v2[1]:
> > collected R-b from Hans and Mika and fixed a minor comment style issue.
> >
> > I recommend it to be merged before the pci/pm patches[2], otherwise there is a
> > window where newer Nvidia Optimus laptops might fail to runtime resume and/or
> > lock up.  Once the pci/pm branch is merged I will propose another patch to
> > improve reliability[3].
> >
> > Known issue with patch 4: when a Nvidia HDMI audio function is present, the
> > bridge will not suspend and hence the Nvidia card will still be powered. Fixing
> 
> That's basically all optimus gpu's, right? Anything GT21x+ has a HDMI
> audio subfunction, and prior to that, the nvidia gpu tended to be the
> only gpu, or hard-muxed.
> 
> If that's the case, that's pretty much a non-starter, IMO.

For some reason the audio function tends to disappear/hide, so maybe it
is not as problematic as it appears (see
https://bugs.freedesktop.org/show_bug.cgi?id=75985). For my laptop I
also had to runtime suspend/resume before lspci -H1 shows the device,
loading with runpm=0 didn't return my HDMI audio device.

The powered on issue will also only appear on devices produced in 2013
and newer that happen to have this ACPI _PR3 ACPI method (which is quite
common for new machines supporting Windows 8 though).

For these newer laptops, after the pci/pm merge and after a patch like
http://www.spinics.net/lists/linux-pci/msg52601.html, the user can
revert to the old DSM method by booting with pcie_port_pm=off which will
retain the current behavior.

The advantage of this patch is that it fixes memory corruption on some
devices. The risk is that the card stays on because the audio subsystem
needs some more work.  FWIW, I was working on some patches that properly
suspended in presence of the HDA controller, but somehow the audio
device was not properly resumed resulting in "no AFG or MFG node found"
and "snd_hda_intel 0000:01:00.1: no codecs initialized".
-- 
Kind regards,
Peter Wu
https://lekensteyn.nl

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

* Re: [Nouveau] [PATCH v3 0/4] nouveau RPM fixes for Optimus (final)
  2016-07-15 16:31     ` Ilia Mirkin
@ 2016-07-15 16:40         ` Alex Deucher
  0 siblings, 0 replies; 20+ messages in thread
From: Alex Deucher @ 2016-07-15 16:40 UTC (permalink / raw)
  To: Ilia Mirkin
  Cc: Peter Wu, Linux PCI, dri-devel, Bjorn Helgaas, nouveau,
	Dave Airlie, Mika Westerberg

On Fri, Jul 15, 2016 at 12:31 PM, Ilia Mirkin <imirkin@alum.mit.edu> wrote:
> On Fri, Jul 15, 2016 at 12:27 PM, Alex Deucher <alexdeucher@gmail.com> wrote:
>> On Fri, Jul 15, 2016 at 12:10 PM, Ilia Mirkin <imirkin@alum.mit.edu> wrote:
>>> On Fri, Jul 15, 2016 at 9:12 AM, Peter Wu <peter@lekensteyn.nl> wrote:
>>>> Hi,
>>>>
>>>> Here are two patches to fix an issue reported on kernel bugzilla (infinite loop
>>>> due to unchecked function) and a more important fix to fix hanging Optimus
>>>> machines when runtime PM is enabled (with pm/pci patches).
>>>>
>>>> These are the final patches targeting v4.8. Changes compared to v2[1]:
>>>> collected R-b from Hans and Mika and fixed a minor comment style issue.
>>>>
>>>> I recommend it to be merged before the pci/pm patches[2], otherwise there is a
>>>> window where newer Nvidia Optimus laptops might fail to runtime resume and/or
>>>> lock up.  Once the pci/pm branch is merged I will propose another patch to
>>>> improve reliability[3].
>>>>
>>>> Known issue with patch 4: when a Nvidia HDMI audio function is present, the
>>>> bridge will not suspend and hence the Nvidia card will still be powered. Fixing
>>>
>>> That's basically all optimus gpu's, right? Anything GT21x+ has a HDMI
>>> audio subfunction, and prior to that, the nvidia gpu tended to be the
>>> only gpu, or hard-muxed.
>>
>> I'd imagine there is a strap on the asic so the audio function is only
>> enabled if there is a connector actually wired to the dGPU.  It
>> doesn't make much sense to expose audio if there is no way to use it.
>
> A lot of the time, there actually is a connector wired up. A lot of
> the other time, there is no connector, but the display unit is still
> there. Very recently, NVIDIA gpu's have started coming out marked as
> "3d accelerator", which sometimes but not always means that there's no
> display unit, and for those, I would assume there is no audio
> subfunction.
>

Just because there is a display block, doesn't mean the audio function
is always enabled.  I suspect it is disabled by hardware straps on
systems with no display connectors or other specific OEM configs.

Alex

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

* Re: [Nouveau] [PATCH v3 0/4] nouveau RPM fixes for Optimus (final)
@ 2016-07-15 16:40         ` Alex Deucher
  0 siblings, 0 replies; 20+ messages in thread
From: Alex Deucher @ 2016-07-15 16:40 UTC (permalink / raw)
  To: Ilia Mirkin
  Cc: Linux PCI, dri-devel, Bjorn Helgaas, Peter Wu, nouveau,
	Dave Airlie, Mika Westerberg

On Fri, Jul 15, 2016 at 12:31 PM, Ilia Mirkin <imirkin@alum.mit.edu> wrote:
> On Fri, Jul 15, 2016 at 12:27 PM, Alex Deucher <alexdeucher@gmail.com> wrote:
>> On Fri, Jul 15, 2016 at 12:10 PM, Ilia Mirkin <imirkin@alum.mit.edu> wrote:
>>> On Fri, Jul 15, 2016 at 9:12 AM, Peter Wu <peter@lekensteyn.nl> wrote:
>>>> Hi,
>>>>
>>>> Here are two patches to fix an issue reported on kernel bugzilla (infinite loop
>>>> due to unchecked function) and a more important fix to fix hanging Optimus
>>>> machines when runtime PM is enabled (with pm/pci patches).
>>>>
>>>> These are the final patches targeting v4.8. Changes compared to v2[1]:
>>>> collected R-b from Hans and Mika and fixed a minor comment style issue.
>>>>
>>>> I recommend it to be merged before the pci/pm patches[2], otherwise there is a
>>>> window where newer Nvidia Optimus laptops might fail to runtime resume and/or
>>>> lock up.  Once the pci/pm branch is merged I will propose another patch to
>>>> improve reliability[3].
>>>>
>>>> Known issue with patch 4: when a Nvidia HDMI audio function is present, the
>>>> bridge will not suspend and hence the Nvidia card will still be powered. Fixing
>>>
>>> That's basically all optimus gpu's, right? Anything GT21x+ has a HDMI
>>> audio subfunction, and prior to that, the nvidia gpu tended to be the
>>> only gpu, or hard-muxed.
>>
>> I'd imagine there is a strap on the asic so the audio function is only
>> enabled if there is a connector actually wired to the dGPU.  It
>> doesn't make much sense to expose audio if there is no way to use it.
>
> A lot of the time, there actually is a connector wired up. A lot of
> the other time, there is no connector, but the display unit is still
> there. Very recently, NVIDIA gpu's have started coming out marked as
> "3d accelerator", which sometimes but not always means that there's no
> display unit, and for those, I would assume there is no audio
> subfunction.
>

Just because there is a display block, doesn't mean the audio function
is always enabled.  I suspect it is disabled by hardware straps on
systems with no display connectors or other specific OEM configs.

Alex
_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

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

* Re: [Nouveau] [PATCH v3 0/4] nouveau RPM fixes for Optimus (final)
  2016-07-15 16:36   ` [Nouveau] " Peter Wu
@ 2016-07-15 16:41     ` Ilia Mirkin
  2016-07-15 16:54         ` Peter Wu
  0 siblings, 1 reply; 20+ messages in thread
From: Ilia Mirkin @ 2016-07-15 16:41 UTC (permalink / raw)
  To: Peter Wu
  Cc: Dave Airlie, nouveau, Bjorn Helgaas, Mika Westerberg, dri-devel,
	Linux PCI

On Fri, Jul 15, 2016 at 12:36 PM, Peter Wu <peter@lekensteyn.nl> wrote:
> On Fri, Jul 15, 2016 at 12:10:23PM -0400, Ilia Mirkin wrote:
>> On Fri, Jul 15, 2016 at 9:12 AM, Peter Wu <peter@lekensteyn.nl> wrote:
>> > Hi,
>> >
>> > Here are two patches to fix an issue reported on kernel bugzilla (infinite loop
>> > due to unchecked function) and a more important fix to fix hanging Optimus
>> > machines when runtime PM is enabled (with pm/pci patches).
>> >
>> > These are the final patches targeting v4.8. Changes compared to v2[1]:
>> > collected R-b from Hans and Mika and fixed a minor comment style issue.
>> >
>> > I recommend it to be merged before the pci/pm patches[2], otherwise there is a
>> > window where newer Nvidia Optimus laptops might fail to runtime resume and/or
>> > lock up.  Once the pci/pm branch is merged I will propose another patch to
>> > improve reliability[3].
>> >
>> > Known issue with patch 4: when a Nvidia HDMI audio function is present, the
>> > bridge will not suspend and hence the Nvidia card will still be powered. Fixing
>>
>> That's basically all optimus gpu's, right? Anything GT21x+ has a HDMI
>> audio subfunction, and prior to that, the nvidia gpu tended to be the
>> only gpu, or hard-muxed.
>>
>> If that's the case, that's pretty much a non-starter, IMO.
>
> For some reason the audio function tends to disappear/hide, so maybe it
> is not as problematic as it appears (see
> https://bugs.freedesktop.org/show_bug.cgi?id=75985). For my laptop I

I'm aware of that bug. I believe this is an exceedingly rare scenario
or it would have been reported a lot more.

> also had to runtime suspend/resume before lspci -H1 shows the device,
> loading with runpm=0 didn't return my HDMI audio device.

Hm ok. Do you have the same laptop as the reporter of that bug?

>
> The powered on issue will also only appear on devices produced in 2013
> and newer that happen to have this ACPI _PR3 ACPI method (which is quite
> common for new machines supporting Windows 8 though).
>
> For these newer laptops, after the pci/pm merge and after a patch like
> http://www.spinics.net/lists/linux-pci/msg52601.html, the user can
> revert to the old DSM method by booting with pcie_port_pm=off which will
> retain the current behavior.
>
> The advantage of this patch is that it fixes memory corruption on some
> devices. The risk is that the card stays on because the audio subsystem
> needs some more work.  FWIW, I was working on some patches that properly
> suspended in presence of the HDA controller, but somehow the audio
> device was not properly resumed resulting in "no AFG or MFG node found"
> and "snd_hda_intel 0000:01:00.1: no codecs initialized".

Does this restriction (runpm being broken in presence of the audio
subfunction) only affect devices with _PR3? If so, that's a lot more
palatable - I bet Windows 8+ is in an era when the display-less thing
became more popular, and thus less likely to affect a ton of people.

  -ilia

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

* Re: [Nouveau] [PATCH v3 0/4] nouveau RPM fixes for Optimus (final)
@ 2016-07-15 16:42           ` Ilia Mirkin
  0 siblings, 0 replies; 20+ messages in thread
From: Ilia Mirkin @ 2016-07-15 16:42 UTC (permalink / raw)
  To: Alex Deucher
  Cc: Peter Wu, Linux PCI, dri-devel, Bjorn Helgaas, nouveau,
	Dave Airlie, Mika Westerberg

On Fri, Jul 15, 2016 at 12:40 PM, Alex Deucher <alexdeucher@gmail.com> wrote:
> On Fri, Jul 15, 2016 at 12:31 PM, Ilia Mirkin <imirkin@alum.mit.edu> wrote:
>> On Fri, Jul 15, 2016 at 12:27 PM, Alex Deucher <alexdeucher@gmail.com> wrote:
>>> On Fri, Jul 15, 2016 at 12:10 PM, Ilia Mirkin <imirkin@alum.mit.edu> wrote:
>>>> On Fri, Jul 15, 2016 at 9:12 AM, Peter Wu <peter@lekensteyn.nl> wrote:
>>>>> Hi,
>>>>>
>>>>> Here are two patches to fix an issue reported on kernel bugzilla (infinite loop
>>>>> due to unchecked function) and a more important fix to fix hanging Optimus
>>>>> machines when runtime PM is enabled (with pm/pci patches).
>>>>>
>>>>> These are the final patches targeting v4.8. Changes compared to v2[1]:
>>>>> collected R-b from Hans and Mika and fixed a minor comment style issue.
>>>>>
>>>>> I recommend it to be merged before the pci/pm patches[2], otherwise there is a
>>>>> window where newer Nvidia Optimus laptops might fail to runtime resume and/or
>>>>> lock up.  Once the pci/pm branch is merged I will propose another patch to
>>>>> improve reliability[3].
>>>>>
>>>>> Known issue with patch 4: when a Nvidia HDMI audio function is present, the
>>>>> bridge will not suspend and hence the Nvidia card will still be powered. Fixing
>>>>
>>>> That's basically all optimus gpu's, right? Anything GT21x+ has a HDMI
>>>> audio subfunction, and prior to that, the nvidia gpu tended to be the
>>>> only gpu, or hard-muxed.
>>>
>>> I'd imagine there is a strap on the asic so the audio function is only
>>> enabled if there is a connector actually wired to the dGPU.  It
>>> doesn't make much sense to expose audio if there is no way to use it.
>>
>> A lot of the time, there actually is a connector wired up. A lot of
>> the other time, there is no connector, but the display unit is still
>> there. Very recently, NVIDIA gpu's have started coming out marked as
>> "3d accelerator", which sometimes but not always means that there's no
>> display unit, and for those, I would assume there is no audio
>> subfunction.
>>
>
> Just because there is a display block, doesn't mean the audio function
> is always enabled.  I suspect it is disabled by hardware straps on
> systems with no display connectors or other specific OEM configs.

That's what I'm saying - it is not. There are straps, and they can be
used to disable the display block. But they're often not set that way.

  -ilia

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

* Re: [PATCH v3 0/4] nouveau RPM fixes for Optimus (final)
@ 2016-07-15 16:42           ` Ilia Mirkin
  0 siblings, 0 replies; 20+ messages in thread
From: Ilia Mirkin @ 2016-07-15 16:42 UTC (permalink / raw)
  To: Alex Deucher
  Cc: Linux PCI, dri-devel-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW,
	Bjorn Helgaas, nouveau-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW,
	Dave Airlie, Mika Westerberg

On Fri, Jul 15, 2016 at 12:40 PM, Alex Deucher <alexdeucher@gmail.com> wrote:
> On Fri, Jul 15, 2016 at 12:31 PM, Ilia Mirkin <imirkin@alum.mit.edu> wrote:
>> On Fri, Jul 15, 2016 at 12:27 PM, Alex Deucher <alexdeucher@gmail.com> wrote:
>>> On Fri, Jul 15, 2016 at 12:10 PM, Ilia Mirkin <imirkin@alum.mit.edu> wrote:
>>>> On Fri, Jul 15, 2016 at 9:12 AM, Peter Wu <peter@lekensteyn.nl> wrote:
>>>>> Hi,
>>>>>
>>>>> Here are two patches to fix an issue reported on kernel bugzilla (infinite loop
>>>>> due to unchecked function) and a more important fix to fix hanging Optimus
>>>>> machines when runtime PM is enabled (with pm/pci patches).
>>>>>
>>>>> These are the final patches targeting v4.8. Changes compared to v2[1]:
>>>>> collected R-b from Hans and Mika and fixed a minor comment style issue.
>>>>>
>>>>> I recommend it to be merged before the pci/pm patches[2], otherwise there is a
>>>>> window where newer Nvidia Optimus laptops might fail to runtime resume and/or
>>>>> lock up.  Once the pci/pm branch is merged I will propose another patch to
>>>>> improve reliability[3].
>>>>>
>>>>> Known issue with patch 4: when a Nvidia HDMI audio function is present, the
>>>>> bridge will not suspend and hence the Nvidia card will still be powered. Fixing
>>>>
>>>> That's basically all optimus gpu's, right? Anything GT21x+ has a HDMI
>>>> audio subfunction, and prior to that, the nvidia gpu tended to be the
>>>> only gpu, or hard-muxed.
>>>
>>> I'd imagine there is a strap on the asic so the audio function is only
>>> enabled if there is a connector actually wired to the dGPU.  It
>>> doesn't make much sense to expose audio if there is no way to use it.
>>
>> A lot of the time, there actually is a connector wired up. A lot of
>> the other time, there is no connector, but the display unit is still
>> there. Very recently, NVIDIA gpu's have started coming out marked as
>> "3d accelerator", which sometimes but not always means that there's no
>> display unit, and for those, I would assume there is no audio
>> subfunction.
>>
>
> Just because there is a display block, doesn't mean the audio function
> is always enabled.  I suspect it is disabled by hardware straps on
> systems with no display connectors or other specific OEM configs.

That's what I'm saying - it is not. There are straps, and they can be
used to disable the display block. But they're often not set that way.

  -ilia
_______________________________________________
Nouveau mailing list
Nouveau@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/nouveau

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

* Re: [Nouveau] [PATCH v3 0/4] nouveau RPM fixes for Optimus (final)
  2016-07-15 16:41     ` Ilia Mirkin
@ 2016-07-15 16:54         ` Peter Wu
  0 siblings, 0 replies; 20+ messages in thread
From: Peter Wu @ 2016-07-15 16:54 UTC (permalink / raw)
  To: Ilia Mirkin
  Cc: Dave Airlie, nouveau, Bjorn Helgaas, Mika Westerberg, dri-devel,
	Linux PCI

On Fri, Jul 15, 2016 at 12:41:49PM -0400, Ilia Mirkin wrote:
> On Fri, Jul 15, 2016 at 12:36 PM, Peter Wu <peter@lekensteyn.nl> wrote:
> > On Fri, Jul 15, 2016 at 12:10:23PM -0400, Ilia Mirkin wrote:
> >> On Fri, Jul 15, 2016 at 9:12 AM, Peter Wu <peter@lekensteyn.nl> wrote:
> >> > Hi,
> >> >
> >> > Here are two patches to fix an issue reported on kernel bugzilla (infinite loop
> >> > due to unchecked function) and a more important fix to fix hanging Optimus
> >> > machines when runtime PM is enabled (with pm/pci patches).
> >> >
> >> > These are the final patches targeting v4.8. Changes compared to v2[1]:
> >> > collected R-b from Hans and Mika and fixed a minor comment style issue.
> >> >
> >> > I recommend it to be merged before the pci/pm patches[2], otherwise there is a
> >> > window where newer Nvidia Optimus laptops might fail to runtime resume and/or
> >> > lock up.  Once the pci/pm branch is merged I will propose another patch to
> >> > improve reliability[3].
> >> >
> >> > Known issue with patch 4: when a Nvidia HDMI audio function is present, the
> >> > bridge will not suspend and hence the Nvidia card will still be powered. Fixing
> >>
> >> That's basically all optimus gpu's, right? Anything GT21x+ has a HDMI
> >> audio subfunction, and prior to that, the nvidia gpu tended to be the
> >> only gpu, or hard-muxed.
> >>
> >> If that's the case, that's pretty much a non-starter, IMO.
> >
> > For some reason the audio function tends to disappear/hide, so maybe it
> > is not as problematic as it appears (see
> > https://bugs.freedesktop.org/show_bug.cgi?id=75985). For my laptop I
> 
> I'm aware of that bug. I believe this is an exceedingly rare scenario
> or it would have been reported a lot more.
> 
> > also had to runtime suspend/resume before lspci -H1 shows the device,
> > loading with runpm=0 didn't return my HDMI audio device.
> 
> Hm ok. Do you have the same laptop as the reporter of that bug?

Nope, I have a Clevo P651RA (GTX965M). That reporter has a Dell XPS 15,
but it also seems present for the Lenovo ThinkPad T420s (see comment on
bug), Asus N56VZ, MSI GT60 2PE, Dell L502x (Launchpad 1377653), Asus
G46vw (Ask Ubuntu user). There is another AU report for a GT 525M
(laptop brand/model unknown).

Maybe there are more affected users, but then they did not notice it
because they did not use HDMI audio.

> >
> > The powered on issue will also only appear on devices produced in 2013
> > and newer that happen to have this ACPI _PR3 ACPI method (which is quite
> > common for new machines supporting Windows 8 though).
> >
> > For these newer laptops, after the pci/pm merge and after a patch like
> > http://www.spinics.net/lists/linux-pci/msg52601.html, the user can
> > revert to the old DSM method by booting with pcie_port_pm=off which will
> > retain the current behavior.
> >
> > The advantage of this patch is that it fixes memory corruption on some
> > devices. The risk is that the card stays on because the audio subsystem
> > needs some more work.  FWIW, I was working on some patches that properly
> > suspended in presence of the HDA controller, but somehow the audio
> > device was not properly resumed resulting in "no AFG or MFG node found"
> > and "snd_hda_intel 0000:01:00.1: no codecs initialized".
> 
> Does this restriction (runpm being broken in presence of the audio
> subfunction) only affect devices with _PR3? If so, that's a lot more
> palatable - I bet Windows 8+ is in an era when the display-less thing
> became more popular, and thus less likely to affect a ton of people.

Yes it only affects those devices with _PR3.
-- 
Kind regards,
Peter Wu
https://lekensteyn.nl

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

* Re: [Nouveau] [PATCH v3 0/4] nouveau RPM fixes for Optimus (final)
@ 2016-07-15 16:54         ` Peter Wu
  0 siblings, 0 replies; 20+ messages in thread
From: Peter Wu @ 2016-07-15 16:54 UTC (permalink / raw)
  To: Ilia Mirkin
  Cc: Linux PCI, dri-devel, Bjorn Helgaas, nouveau, Dave Airlie,
	Mika Westerberg

On Fri, Jul 15, 2016 at 12:41:49PM -0400, Ilia Mirkin wrote:
> On Fri, Jul 15, 2016 at 12:36 PM, Peter Wu <peter@lekensteyn.nl> wrote:
> > On Fri, Jul 15, 2016 at 12:10:23PM -0400, Ilia Mirkin wrote:
> >> On Fri, Jul 15, 2016 at 9:12 AM, Peter Wu <peter@lekensteyn.nl> wrote:
> >> > Hi,
> >> >
> >> > Here are two patches to fix an issue reported on kernel bugzilla (infinite loop
> >> > due to unchecked function) and a more important fix to fix hanging Optimus
> >> > machines when runtime PM is enabled (with pm/pci patches).
> >> >
> >> > These are the final patches targeting v4.8. Changes compared to v2[1]:
> >> > collected R-b from Hans and Mika and fixed a minor comment style issue.
> >> >
> >> > I recommend it to be merged before the pci/pm patches[2], otherwise there is a
> >> > window where newer Nvidia Optimus laptops might fail to runtime resume and/or
> >> > lock up.  Once the pci/pm branch is merged I will propose another patch to
> >> > improve reliability[3].
> >> >
> >> > Known issue with patch 4: when a Nvidia HDMI audio function is present, the
> >> > bridge will not suspend and hence the Nvidia card will still be powered. Fixing
> >>
> >> That's basically all optimus gpu's, right? Anything GT21x+ has a HDMI
> >> audio subfunction, and prior to that, the nvidia gpu tended to be the
> >> only gpu, or hard-muxed.
> >>
> >> If that's the case, that's pretty much a non-starter, IMO.
> >
> > For some reason the audio function tends to disappear/hide, so maybe it
> > is not as problematic as it appears (see
> > https://bugs.freedesktop.org/show_bug.cgi?id=75985). For my laptop I
> 
> I'm aware of that bug. I believe this is an exceedingly rare scenario
> or it would have been reported a lot more.
> 
> > also had to runtime suspend/resume before lspci -H1 shows the device,
> > loading with runpm=0 didn't return my HDMI audio device.
> 
> Hm ok. Do you have the same laptop as the reporter of that bug?

Nope, I have a Clevo P651RA (GTX965M). That reporter has a Dell XPS 15,
but it also seems present for the Lenovo ThinkPad T420s (see comment on
bug), Asus N56VZ, MSI GT60 2PE, Dell L502x (Launchpad 1377653), Asus
G46vw (Ask Ubuntu user). There is another AU report for a GT 525M
(laptop brand/model unknown).

Maybe there are more affected users, but then they did not notice it
because they did not use HDMI audio.

> >
> > The powered on issue will also only appear on devices produced in 2013
> > and newer that happen to have this ACPI _PR3 ACPI method (which is quite
> > common for new machines supporting Windows 8 though).
> >
> > For these newer laptops, after the pci/pm merge and after a patch like
> > http://www.spinics.net/lists/linux-pci/msg52601.html, the user can
> > revert to the old DSM method by booting with pcie_port_pm=off which will
> > retain the current behavior.
> >
> > The advantage of this patch is that it fixes memory corruption on some
> > devices. The risk is that the card stays on because the audio subsystem
> > needs some more work.  FWIW, I was working on some patches that properly
> > suspended in presence of the HDA controller, but somehow the audio
> > device was not properly resumed resulting in "no AFG or MFG node found"
> > and "snd_hda_intel 0000:01:00.1: no codecs initialized".
> 
> Does this restriction (runpm being broken in presence of the audio
> subfunction) only affect devices with _PR3? If so, that's a lot more
> palatable - I bet Windows 8+ is in an era when the display-less thing
> became more popular, and thus less likely to affect a ton of people.

Yes it only affects those devices with _PR3.
-- 
Kind regards,
Peter Wu
https://lekensteyn.nl
_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

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

* Re: [Nouveau] [PATCH v3 0/4] nouveau RPM fixes for Optimus (final)
  2016-07-15 16:54         ` Peter Wu
  (?)
@ 2016-07-15 23:24         ` Peter Wu
  -1 siblings, 0 replies; 20+ messages in thread
From: Peter Wu @ 2016-07-15 23:24 UTC (permalink / raw)
  To: Ilia Mirkin
  Cc: Dave Airlie, nouveau, Bjorn Helgaas, Mika Westerberg, dri-devel,
	Linux PCI

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

On Fri, Jul 15, 2016 at 06:54:27PM +0200, Peter Wu wrote:
> On Fri, Jul 15, 2016 at 12:41:49PM -0400, Ilia Mirkin wrote:
> > On Fri, Jul 15, 2016 at 12:36 PM, Peter Wu <peter@lekensteyn.nl> wrote:
> > > On Fri, Jul 15, 2016 at 12:10:23PM -0400, Ilia Mirkin wrote:
> > >> On Fri, Jul 15, 2016 at 9:12 AM, Peter Wu <peter@lekensteyn.nl> wrote:
> > >> > Hi,
> > >> >
> > >> > Here are two patches to fix an issue reported on kernel bugzilla (infinite loop
> > >> > due to unchecked function) and a more important fix to fix hanging Optimus
> > >> > machines when runtime PM is enabled (with pm/pci patches).
> > >> >
> > >> > These are the final patches targeting v4.8. Changes compared to v2[1]:
> > >> > collected R-b from Hans and Mika and fixed a minor comment style issue.
> > >> >
> > >> > I recommend it to be merged before the pci/pm patches[2], otherwise there is a
> > >> > window where newer Nvidia Optimus laptops might fail to runtime resume and/or
> > >> > lock up.  Once the pci/pm branch is merged I will propose another patch to
> > >> > improve reliability[3].
> > >> >
> > >> > Known issue with patch 4: when a Nvidia HDMI audio function is present, the
> > >> > bridge will not suspend and hence the Nvidia card will still be powered. Fixing
> > >>
> > >> That's basically all optimus gpu's, right? Anything GT21x+ has a HDMI
> > >> audio subfunction, and prior to that, the nvidia gpu tended to be the
> > >> only gpu, or hard-muxed.
> > >>
> > >> If that's the case, that's pretty much a non-starter, IMO.
> > >
> > > For some reason the audio function tends to disappear/hide, so maybe it
> > > is not as problematic as it appears (see
> > > https://bugs.freedesktop.org/show_bug.cgi?id=75985). For my laptop I
> > 
> > I'm aware of that bug. I believe this is an exceedingly rare scenario
> > or it would have been reported a lot more.
> > 
> > > also had to runtime suspend/resume before lspci -H1 shows the device,
> > > loading with runpm=0 didn't return my HDMI audio device.
> > 
> > Hm ok. Do you have the same laptop as the reporter of that bug?
> 
> Nope, I have a Clevo P651RA (GTX965M). That reporter has a Dell XPS 15,
> but it also seems present for the Lenovo ThinkPad T420s (see comment on
> bug), Asus N56VZ, MSI GT60 2PE, Dell L502x (Launchpad 1377653), Asus
> G46vw (Ask Ubuntu user). There is another AU report for a GT 525M
> (laptop brand/model unknown).
> 
> Maybe there are more affected users, but then they did not notice it
> because they did not use HDMI audio.
> 
> > >
> > > The powered on issue will also only appear on devices produced in 2013
> > > and newer that happen to have this ACPI _PR3 ACPI method (which is quite
> > > common for new machines supporting Windows 8 though).
> > >
> > > For these newer laptops, after the pci/pm merge and after a patch like
> > > http://www.spinics.net/lists/linux-pci/msg52601.html, the user can
> > > revert to the old DSM method by booting with pcie_port_pm=off which will
> > > retain the current behavior.
> > >
> > > The advantage of this patch is that it fixes memory corruption on some
> > > devices. The risk is that the card stays on because the audio subsystem
> > > needs some more work.  FWIW, I was working on some patches that properly
> > > suspended in presence of the HDA controller, but somehow the audio
> > > device was not properly resumed resulting in "no AFG or MFG node found"
> > > and "snd_hda_intel 0000:01:00.1: no codecs initialized".
> > 
> > Does this restriction (runpm being broken in presence of the audio
> > subfunction) only affect devices with _PR3? If so, that's a lot more
> > palatable - I bet Windows 8+ is in an era when the display-less thing
> > became more popular, and thus less likely to affect a ton of people.
> 
> Yes it only affects those devices with _PR3.

I downloaded all .tar.gz files from the big Launchpad bug that collects
DSDTs (and more recently also dmidecode/lspci) and ran an analysis. The
result (limited to files which actually had a lspci and dmidecode file):

 - 111 Nvidia video devices
 - 20 out of these have an audio device.
 - 18 use _PR3, 93 use DSM (or gmux).
 - Exactly zero use _PR3 and have an audio device!

The post-processed data (sorted by BIOS date) and (quick and dirty)
scripts are attached.  Hopefully these results are convincing enough :-)
-- 
Kind regards,
Peter Wu
https://lekensteyn.nl

[-- Attachment #2: nv-devs.txt --]
[-- Type: text/plain, Size: 26496 bytes --]

001 Apple_Inc.-MacBookPro6,1
01:00.0 VGA compatible controller [0300]: NVIDIA Corporation GT216M [GeForce GT 330M] [10de:0a29] (rev a2) (prog-if 00 [VGA controller])
01:00.1 Audio device [0403]: NVIDIA Corporation GT216 HDMI Audio Controller [10de:0be2] (rev a1)
Date: bios-release-date     : 07/26/10
Use _DSM!

002 BenQ-Joybook_S42
01:00.0 VGA compatible controller [0300]: NVIDIA Corporation G96 [GeForce 9600M GT] [10de:0649] (rev a1) (prog-if 00 [VGA controller])
(No audio device found)
Date: bios-release-date     : 04/10/2009
Use _DSM!

003 ASUSTeK_Computer_Inc.-UL50VT
01:00.0 VGA compatible controller [0300]: NVIDIA Corporation GT218 [GeForce G210M] [10de:0a74] (rev a2) (prog-if 00 [VGA controller])
01:00.1 Audio device [0403]: NVIDIA Corporation High Definition Audio Controller [10de:0be3] (rev a1)
Date: bios-release-date     : 10/23/2009
Use _DSM!

004 Sony_Corporation-VPCZ11V9R
01:00.0 VGA compatible controller [0300]: nVidia Corporation GT216 [GeForce GT 330M] [10de:0a2b] (rev a2) (prog-if 00 [VGA controller])
01:00.1 Audio device [0403]: nVidia Corporation High Definition Audio Controller [10de:0be2] (rev a1)
Date: bios-release-date     : 02/05/2010
Use _DSM!

005 ASUSTeK_Computer_Inc.-K42Jv
01:00.0 VGA compatible controller [0300]: NVIDIA Corporation GT215M [GeForce GT 335M] [10de:0caf] (rev ff) (prog-if ff)
(No audio device found)
Date: bios-release-date     : 05/24/2010
Use _DSM!

006 LENOVO-INVALID
02:00.0 VGA compatible controller [0300]: nVidia Corporation GT218 [GeForce 310M] [10de:0a70] (rev a2) (prog-if 00 [VGA controller])
(No audio device found)
Date: bios-release-date     : 07/29/2010
Use _DSM!

007 TOSHIBA-Satellite_E205
01:00.0 VGA compatible controller [0300]: NVIDIA Corporation GT218 [GeForce 310M] [10de:0a70] (rev a2) (prog-if 00 [VGA controller])
(No audio device found)
Date: bios-release-date     : 08/26/2010
Use _DSM!

008 CLEVO_CO.-B7130
01:00.0 VGA compatible controller [0300]: nVidia Corporation GF108 [GeForce GT 425M] [10de:0df0] (rev a1) (prog-if 00 [VGA controller])
(No audio device found)
Date: bios-release-date     : 08/27/2010
Use _DSM!

009 LENOVO-2904HHM
01:00.0 VGA compatible controller [0300]: nVidia Corporation GT218 [NVS 3100M] [10de:0a6c] (rev a2) (prog-if 00 [VGA controller])
(No audio device found)
Date: bios-release-date     : 09/16/2010
Use _DSM!

010 LENOVO-2516CTO
01:00.0 VGA compatible controller [0300]: NVIDIA Corporation GT218 [NVS 3100M] [10de:0a6c] (rev a2) (prog-if 00 [VGA controller])
01:00.1 Audio device [0403]: NVIDIA Corporation High Definition Audio Controller [10de:0be3] (rev a1)
Date: bios-release-date     : 10/25/2010
Use _DSM!

011 Acer-Aspire_5935
01:00.0 VGA compatible controller [0300]: NVIDIA Corporation GT216 [GeForce GT 240M] [10de:0a34] (rev a2) (prog-if 00 [VGA controller])
01:00.1 Audio device [0403]: NVIDIA Corporation High Definition Audio Controller [10de:0be2] (rev a1)
Date: bios-release-date     : 11/03/2010
Use _DSM!

012 Dell_Inc.-XPS_L401X
01:00.0 VGA compatible controller [0300]: nVidia Corporation Device [10de:0df1] (rev a1) (prog-if 00 [VGA controller])
(No audio device found)
Date: bios-release-date     : 12/22/2010
Use _DSM!

013 ASUSTeK_Computer_Inc.-UL80VT
01:00.0 VGA compatible controller [0300]: NVIDIA Corporation GT218 [GeForce G210M] [10de:0a74] (rev ff) (prog-if ff)
01:00.1 Audio device [0403]: NVIDIA Corporation High Definition Audio Controller [10de:0be3] (rev ff) (prog-if ff)
Date: bios-release-date     : 01/17/2011
Use _DSM!

014 ASUSTeK_Computer_Inc.-U33Jc
01:00.0 VGA compatible controller [0300]: NVIDIA Corporation GT218M [GeForce 310M] [10de:0a70] (rev a2) (prog-if 00 [VGA controller])
(No audio device found)
Date: bios-release-date     : 01/24/2011
Use _DSM!

015 LENOVO-IdeaPad_Y460
01:00.0 VGA compatible controller [0300]: nVidia Corporation Device [10de:0df0] (rev ff) (prog-if ff)
01:00.1 Audio device [0403]: nVidia Corporation Device [10de:0bea] (rev ff) (prog-if ff)
Date: bios-release-date     : 01/27/2011
Use _DSM!

016 SAMSUNG_ELECTRONICS_CO.,_LTD.-RC512
01:00.0 3D controller [0302]: nVidia Corporation Device [10de:0dec] (rev a1)
(No audio device found)
Date: bios-release-date     : 02/12/2011
Use _DSM!

017 ASUSTeK_Computer_INC.-1015PN
04:00.0 VGA compatible controller [0300]: NVIDIA Corporation GT218 [ION] [10de:0a6f] (rev a2) (prog-if 00 [VGA controller])
04:00.1 Audio device [0403]: NVIDIA Corporation High Definition Audio Controller [10de:0be3] (rev a1)
Date: bios-release-date     : 04/18/2011
Use _DSM!

018 SAMSUNG_ELECTRONICS_CO.,_LTD.-RF511_RF411_RF711
01:00.0 3D controller [0302]: nVidia Corporation GF106 [GeForce GT 555M] [10de:0df4] (rev a1)
(No audio device found)
Date: bios-release-date     : 04/26/2011
Use _DSM!

019 ASUSTeK_Computer_INC.-1215N
05:00.0 VGA compatible controller [0300]: nVidia Corporation Device [10de:0a76] (rev a2) (prog-if 00 [VGA controller])
(No audio device found)
Date: bios-release-date     : 05/05/2011
Use _DSM!

020 Dell_Inc.-Dell_System_Inspiron_N7110
01:00.0 VGA compatible controller [0300]: nVidia Corporation Device [10de:0df5] (rev a1) (prog-if 00 [VGA controller])
(No audio device found)
Date: bios-release-date     : 05/19/2011
Use _DSM!

021 LENOVO-4349WK8
01:00.0 VGA compatible controller [0300]: NVIDIA Corporation GT218 [NVS 3100M] [10de:0a6c] (rev ff) (prog-if ff)
(No audio device found)
Date: bios-release-date     : 05/24/2011
Use _DSM!

022 SAMSUNG_ELECTRONICS_CO.,_LTD.-QX311_QX411_QX412_QX511
01:00.0 3D controller [0302]: nVidia Corporation Device [10de:1050] (rev a1)
(No audio device found)
Date: bios-release-date     : 06/22/2011
Use _DSM!

023 ASUSTeK_Computer_Inc.-K73SV
01:00.0 VGA compatible controller [0300]: nVidia Corporation GF106 [GeForce GT 555M] [10de:0df4] (rev a1) (prog-if 00 [VGA controller])
(No audio device found)
Date: bios-release-date     : 07/01/2011
Use _DSM!

024 Acer-Aspire_5750G
01:00.0 VGA compatible controller [0300]: NVIDIA Corporation GF108M [GeForce GT 520M] [10de:0df7] (rev ff) (prog-if ff)
(No audio device found)
Date: bios-release-date     : 07/11/2011
Use _DSM!

025 ASUSTeK_Computer_Inc.-U36SD
01:00.0 VGA compatible controller [0300]: NVIDIA Corporation GF119M [GeForce GT 520M] [10de:1050] (rev ff) (prog-if ff)
(No audio device found)
Date: bios-release-date     : 07/12/2011
Use _DSM!

026 ASUSTeK_Computer_Inc.-K53SV
01:00.0 VGA compatible controller [0300]: NVIDIA Corporation GF108M [GeForce GT 540M] [10de:0df4] (rev ff) (prog-if ff)
(No audio device found)
Date: bios-release-date     : 07/14/2011
Use _DSM!

027 Dell_Inc.-Vostro_360
01:00.0 VGA compatible controller [0300]: nVidia Corporation Device [10de:0df5] (rev a1) (prog-if 00 [VGA controller])
(No audio device found)
Date: bios-release-date     : 07/19/2011
Use _DSM!

028 LENOVO-20091
01:00.0 VGA compatible controller [0300]: nVidia Corporation Device [10de:0deb] (rev a1) (prog-if 00 [VGA controller])
(No audio device found)
Date: bios-release-date     : 08/01/2011
Use _DSM!

029 Acer-Aspire_8951G
01:00.0 VGA compatible controller [0300]: NVIDIA Corporation GF106 [GeForce GT 555M] [10de:0dce] (rev ff) (prog-if ff)
(No audio device found)
Date: bios-release-date     : 08/02/2011
Use _DSM!

030 ASUSTeK_Computer_Inc.-K53SC
01:00.0 VGA compatible controller [0300]: NVIDIA Corporation GF119 [GeForce GT 520MX] [10de:1051] (rev ff) (prog-if ff)
(No audio device found)
Date: bios-release-date     : 09/26/2011
Use _DSM!

031 Dell_Inc.-Inspiron_N5110
01:00.0 VGA compatible controller [0300]: nVidia Corporation Device [10de:0df5] (rev ff) (prog-if ff)
01:00.1 Audio device [0403]: nVidia Corporation GF108 High Definition Audio Controller [10de:0bea] (rev ff) (prog-if ff)
Date: bios-release-date     : 09/30/2011
Use _DSM!

032 SAMSUNG_ELECTRONICS_CO.,_LTD.-300V3Z_300V4Z_300V5Z_200A4Y_200A5Y
01:00.0 3D controller [0302]: nVidia Corporation Device [10de:1051] (rev ff) (prog-if ff)
(No audio device found)
Date: bios-release-date     : 10/12/2011
Use _DSM!

033 LENOVO-HuronRiver_Platform
01:00.0 VGA compatible controller [0300]: NVIDIA Corporation GF108 [GeForce GT 540M] [10de:0df4] (rev ff) (prog-if ff)
01:00.1 Audio device [0403]: NVIDIA Corporation GF108 High Definition Audio Controller [10de:0bea] (rev ff) (prog-if ff)
Date: bios-release-date     : 10/21/2011
Use _DSM!

034 MEDION-P7624
01:00.0 VGA compatible controller [0300]: nVidia Corporation Device [10de:0de9] (rev ff) (prog-if ff)
(No audio device found)
Date: bios-release-date     : 10/31/2011
Use _DSM!

035 LENOVO-4349PG7
01:00.0 VGA compatible controller [0300]: NVIDIA Corporation GT218 [NVS 3100M] [10de:0a6c] (rev a2) (prog-if 00 [VGA controller])
01:00.1 Audio device [0403]: NVIDIA Corporation High Definition Audio Controller [10de:0be3] (rev a1)
Date: bios-release-date     : 11/28/2011
Use _DSM!

036 LENOVO-4173W2X
01:00.0 VGA compatible controller [0300]: nVidia Corporation GF108 [Quadro NVS 4200M] [10de:1056] (rev a1) (prog-if 00 [VGA controller])
(No audio device found)
Date: bios-release-date     : 11/29/2011
Use _DSM!

037 LENOVO-2912CTO
01:00.0 VGA compatible controller [0300]: NVIDIA Corporation GT218 [NVS 3100M] [10de:0a6c] (rev ff) (prog-if ff)
01:00.1 Audio device [0403]: NVIDIA Corporation High Definition Audio Controller [10de:0be3] (rev ff) (prog-if ff)
Date: bios-release-date     : 12/12/2011
Use _DSM!

038 LENOVO-PIQY0
01:00.0 VGA compatible controller [0300]: nVidia Corporation Device [10de:0deb] (rev a1) (prog-if 00 [VGA controller])
(No audio device found)
Date: bios-release-date     : 01/04/2012
Use _DSM!

039 Sony_Corporation-VPCEG38EC
01:00.0 VGA compatible controller [0300]: NVIDIA Corporation GF119M [GeForce 410M] [10de:1055] (rev a1) (prog-if 00 [VGA controller])
01:00.1 Audio device [0403]: NVIDIA Corporation GF119 HDMI Audio Controller [10de:0e08] (rev a1)
Date: bios-release-date     : 01/06/2012
Use _DSM!

040 ASUSTeK_Computer_Inc.-N53SV
01:00.0 VGA compatible controller [0300]: NVIDIA Corporation GF108M [GeForce GT 540M] [10de:0df4] (rev a1) (prog-if 00 [VGA controller])
(No audio device found)
Date: bios-release-date     : 01/09/2012
Use _DSM!

041 Acer-TravelMate_8481TG
01:00.0 VGA compatible controller [0300]: nVidia Corporation Device [10de:1050] (rev a1) (prog-if 00 [VGA controller])
01:00.1 Audio device [0403]: nVidia Corporation HDMI Audio stub [10de:0e08] (rev ff) (prog-if ff)
Date: bios-release-date     : 02/07/2012
Use _DSM!

042 Dell_Inc.-Dell_System_Vostro_3750
01:00.0 VGA compatible controller [0300]: NVIDIA Corporation GF108M [GeForce GT 525M] [10de:0df5] (rev ff) (prog-if ff)
(No audio device found)
Date: bios-release-date     : 02/22/2012
Use _DSM!

043 ASUSTeK_Computer_Inc.-K53SM
01:00.0 VGA compatible controller [0300]: NVIDIA Corporation GF108M [GeForce GT 630M] [10de:0de9] (rev a1) (prog-if 00 [VGA controller])
(No audio device found)
Date: bios-release-date     : 03/06/2012
Use _DSM!

044 CLEVO_CO.-W150ER
01:00.0 VGA compatible controller [0300]: NVIDIA Corporation GK107 [GeForce GT 650M] [10de:0fd1] (rev a1) (prog-if 00 [VGA controller])
(No audio device found)
Date: bios-release-date     : 03/14/2012
Use _DSM!

045 Micro-Star_International_Co.,_Ltd.-GT70_0NC_GT70_0NC
01:00.0 VGA compatible controller [0300]: NVIDIA Corporation Device [10de:1213] (rev ff) (prog-if ff)
(No audio device found)
Date: bios-release-date     : 03/20/2012
Use _DSM!

046 TOSHIBA-SATELLITE_P870
01:00.0 VGA compatible controller [0300]: NVIDIA Corporation Device [10de:0de9] (rev a1) (prog-if 00 [VGA controller])
(No audio device found)
Date: bios-release-date     : 03/21/2012
Use _DSM!

047 LENOVO-Lenovo_IdeaPad_Y480
01:00.0 VGA compatible controller [0300]: NVIDIA Corporation GF108M [GeForce GT 630M] [10de:0de9] (rev ff) (prog-if ff)
(No audio device found)
Date: bios-release-date     : 03/22/2012
Use _DSM!

048 Dell_Inc.-XPS_L412Z
01:00.0 VGA compatible controller [0300]: NVIDIA Corporation GF119M [GeForce GT 520M] [10de:1050] (rev ff) (prog-if ff)
(No audio device found)
Date: bios-release-date     : 04/20/2012
Use _DSM!

049 LENOVO-814UG01
01:00.0 VGA compatible controller [0300]: NVIDIA Corporation GF108M [GeForce GT 630M] [10de:0de9] (rev a1) (prog-if 00 [VGA controller])
(No audio device found)
Date: bios-release-date     : 04/23/2012
Use _DSM!

050 LENOVO-Lenovo_G580
01:00.0 3D controller [0302]: NVIDIA Corporation Device [10de:1140] (rev a1)
(No audio device found)
Date: bios-release-date     : 04/24/2012
Use _DSM!

051 CLEVO_CO.-W110ER
01:00.0 VGA compatible controller [0300]: NVIDIA Corporation Device [10de:0fd1] (rev a1) (prog-if 00 [VGA controller])
(No audio device found)
Date: bios-release-date     : 04/26/2012
Use _DSM!

052 Acer-Aspire_M3-581TG
01:00.0 VGA compatible controller [0300]: NVIDIA Corporation Device [10de:0fd2] (rev a1) (prog-if 00 [VGA controller])
(No audio device found)
Date: bios-release-date     : 05/12/2012
Use _DSM!

053 Sony_Corporation-SVS13A1C5E
01:00.0 VGA compatible controller [0300]: NVIDIA Corporation Device [10de:0fd3] (rev ff) (prog-if ff)
(No audio device found)
Date: bios-release-date     : 05/17/2012
Use _DSM!

054 LENOVO-2436CTO
01:00.0 VGA compatible controller [0300]: NVIDIA Corporation Device [10de:0ffb] (rev ff) (prog-if ff)
(No audio device found)
Date: bios-release-date     : 05/25/2012
Use _DSM!

055 Dell_Inc.-Dell_System_XPS_L502X
01:00.0 VGA compatible controller [0300]: nVidia Corporation GF106 [GeForce GT 555M SDDR3] [10de:0df4] (rev ff) (prog-if ff)
(No audio device found)
Date: bios-release-date     : 05/29/2012
Use _DSM!

056 LENOVO-2093
01:00.0 VGA compatible controller [0300]: NVIDIA Corporation Device [10de:0fd1] (rev a1) (prog-if 00 [VGA controller])
(No audio device found)
Date: bios-release-date     : 06/26/2012
Use _DSM!

057 Alienware-M18xR2
01:00.0 VGA compatible controller [0300]: NVIDIA Corporation Device [10de:11a0] (rev a1) (prog-if 00 [VGA controller])
07:00.0 VGA compatible controller [0300]: NVIDIA Corporation Device [10de:11a0] (rev a1) (prog-if 00 [VGA controller])
01:00.1 Audio device [0403]: NVIDIA Corporation GK104 HDMI Audio Controller [10de:0e0a] (rev a1)
Date: bios-release-date     : 06/29/2012
Use _DSM!

058 SAMSUNG_ELECTRONICS_CO.,_LTD.-700Z7C
01:00.0 VGA compatible controller [0300]: NVIDIA Corporation GK107 [GeForce GT 650M] [10de:0fd1] (rev a1) (prog-if 00 [VGA controller])
(No audio device found)
Date: bios-release-date     : 08/02/2012
Use _DSM!

059 Apple_Inc.-MacBookPro9,1
01:00.0 VGA compatible controller [0300]: NVIDIA Corporation GK107M [GeForce GT 650M Mac Edition] [10de:0fd5] (rev a1) (prog-if 00 [VGA controller])
01:00.1 Audio device [0403]: NVIDIA Corporation GK107 HDMI Audio Controller [10de:0e1b] (rev a1)
Date: bios-release-date     : 08/08/2012
Use _DSM!

060 Dell_Inc.-Inspiron_5720
01:00.0 3D controller [0302]: NVIDIA Corporation Device [10de:1140] (rev a1)
(No audio device found)
Date: bios-release-date     : 08/16/2012
Use _DSM!

061 Sony_Corporation-SVS13A190X
01:00.0 VGA compatible controller [0300]: NVIDIA Corporation GK107M [GeForce GT 640M LE] [10de:0fd3] (rev ff) (prog-if ff)
(No audio device found)
Date: bios-release-date     : 08/22/2012
Use _DSM!

062 LENOVO-3351CTO
01:00.0 3D controller [0302]: NVIDIA Corporation Device [10de:1140] (rev a1)
(No audio device found)
Date: bios-release-date     : 08/27/2012
Use _DSM!

063 Gigabyte_Technology_Co.,_Ltd.-To_be_filled_by_O.E.M.
01:00.0 VGA compatible controller [0300]: NVIDIA Corporation G94 [GeForce 9600 GT] [10de:0622] (rev a1) (prog-if 00 [VGA controller])
(No audio device found)
Date: bios-release-date     : 10/24/2012
Use _DSM!

064 FUJITSU-LIFEBOOK_NH532
01:00.0 VGA compatible controller [0300]: NVIDIA Corporation Device [10de:0fd3] (rev a1) (prog-if 00 [VGA controller])
(No audio device found)
Date: bios-release-date     : 11/08/2012
Use _DSM!

065 Dell_Inc.-XPS_L421X
01:00.0 3D controller [0302]: NVIDIA Corporation GF117M [GeForce 610M/710M/820M / GT 620M/625M/630M/720M] [10de:1140] (rev a1)
(No audio device found)
Date: bios-release-date     : 12/07/2012
Use _DSM!

066 ASUSTeK_COMPUTER_INC.-N56VB
01:00.0 3D controller [0302]: NVIDIA Corporation GK107M [GeForce GT 740M] [10de:0fdf] (rev a1)
(No audio device found)
Date: bios-release-date     : 01/21/2013
Use _DSM!

067 LENOVO-2359CTO
01:00.0 VGA compatible controller [0300]: NVIDIA Corporation GF108 [Quadro NVS 5400M] [10de:0def] (rev ff) (prog-if ff)
(No audio device found)
Date: bios-release-date     : 02/01/2013
Use _DSM!

068 Notebook-P15SM
01:00.0 VGA compatible controller [0300]: NVIDIA Corporation GK106M [GeForce GTX 770M] [10de:11e0] (rev a1) (prog-if 00 [VGA controller])
(No audio device found)
Date: bios-release-date     : 04/09/2013
Use _DSM!

069 Notebook-W350STQ_W370ST
01:00.0 3D controller [0302]: NVIDIA Corporation GK106M [GeForce GTX 765M] [10de:11e2] (rev a1)
(No audio device found)
Date: bios-release-date     : 04/11/2013
Use _DSM!

070 LENOVO-33643EG
01:00.0 VGA compatible controller [0300]: NVIDIA Corporation Device [10de:0de8] (rev a1) (prog-if 00 [VGA controller])
(No audio device found)
Date: bios-release-date     : 04/24/2013
Use _DSM!

071 Dell_Inc.-Inspiron_5421
02:00.0 VGA compatible controller [0300]: NVIDIA Corporation GK107M [GeForce GT 730M] [10de:0fe1] (rev ff) (prog-if ff)
(No audio device found)
Date: bios-release-date     : 05/18/2013
Use _DSM!

072 Razer-_
01:00.0 3D controller [0302]: NVIDIA Corporation GK106M [GeForce GTX 765M] [10de:11e2] (rev ff) (prog-if ff)
(No audio device found)
Date: bios-release-date     : 05/20/2013
Use _DSM!

073 Micro-Star_International_Co.,_Ltd.-GT60_2OC_2OD
01:00.0 VGA compatible controller [0300]: NVIDIA Corporation GK106M [GeForce GTX 770M] [10de:11e0] (rev ff) (prog-if ff)
(No audio device found)
Date: bios-release-date     : 05/22/2013
Use _DSM!

074 LENOVO-2394CTO
01:00.0 VGA compatible controller [0300]: NVIDIA Corporation GF108M [NVS 5400M] [10de:0def] (rev a1) (prog-if 00 [VGA controller])
(No audio device found)
Date: bios-release-date     : 05/23/2013
Use _DSM!

075 Acer-Aspire_V7-482PG
01:00.0 3D controller [0302]: NVIDIA Corporation GK107M [GeForce GT 750M] [10de:0fe4] (rev a1)
(No audio device found)
Date: bios-release-date     : 06/03/2013
Use _DSM!

076 Acer-Aspire_V5-573G
01:00.0 3D controller [0302]: NVIDIA Corporation GK107M [GeForce GT 750M] [10de:0fe4] (rev a1)
(No audio device found)
Date: bios-release-date     : 06/28/2013
Use _DSM!

077 LENOVO-41786VU
01:00.0 VGA compatible controller [0300]: NVIDIA Corporation GF119 [Quadro NVS 4200M] [10de:1057] (rev ff) (prog-if ff)
(No audio device found)
Date: bios-release-date     : 07/05/2013
Use _DSM!

078 Alienware-Alienware_17
01:00.0 VGA compatible controller [0300]: NVIDIA Corporation GK106M [GeForce GTX 770M] [10de:11e0] (rev a1) (prog-if 00 [VGA controller])
(No audio device found)
Date: bios-release-date     : 07/15/2013
Use _DSM!

079 LENOVO-42395GU
01:00.0 VGA compatible controller [0300]: NVIDIA Corporation GF119M [Quadro NVS 4200M] [10de:1057] (rev a1) (prog-if 00 [VGA controller])
(No audio device found)
Date: bios-release-date     : 07/26/2013
Use _DSM!

080 ASUSTeK_COMPUTER_INC.-G750JHA
01:00.0 VGA compatible controller [0300]: NVIDIA Corporation GK104M [GeForce GTX 780M] [10de:119f] (rev a1) (prog-if 00 [VGA controller])
01:00.1 Audio device [0403]: NVIDIA Corporation GK104 HDMI Audio Controller [10de:0e0a] (rev a1)
Date: bios-release-date     : 07/31/2013
Use _DSM!

081 Alienware-Alienware_14
01:00.0 VGA compatible controller [0300]: NVIDIA Corporation GK106M [GeForce GTX 765M] [10de:11e2] (rev a1) (prog-if 00 [VGA controller])
(No audio device found)
Date: bios-release-date     : 08/12/2013
Use _DSM!

082 Dell_Inc.-Inspiron_7720
01:00.0 VGA compatible controller [0300]: NVIDIA Corporation GK107M [GeForce GT 650M / GTX 660M LE] [10de:0fd1] (rev ff) (prog-if ff)
(No audio device found)
Date: bios-release-date     : 08/23/2013
Use _DSM!

083 LENOVO-20270
09:00.0 3D controller [0302]: NVIDIA Corporation GK208M [GeForce GT 730M] [10de:1290] (rev a1)
(No audio device found)
Date: bios-release-date     : 09/06/2013
Use _DSM!

084 SAMSUNG_ELECTRONICS_CO.,_LTD.-550P5C_550P7C
01:00.0 VGA compatible controller [0300]: NVIDIA Corporation GK107M [GeForce GT 650M] [10de:0fd1] (rev ff) (prog-if ff)
(No audio device found)
Date: bios-release-date     : 09/17/2013
Use _DSM!

085 LENOVO-20217
01:00.0 VGA compatible controller [0300]: NVIDIA Corporation GK107M [GeForce GT 755M] [10de:0fcd] (rev a1) (prog-if 00 [VGA controller])
(No audio device found)
Date: bios-release-date     : 09/18/2013
Got _PR3!

086 Micro-Star_International_Co.,_Ltd.-CR42_2M_GE40_2OC
01:00.0 3D controller [0302]: NVIDIA Corporation GK106M [GeForce GTX 760M] [10de:11e3] (rev a1)
(No audio device found)
Date: bios-release-date     : 09/24/2013
Use _DSM!

087 Hewlett-Packard-HP_EliteBook_8570w
01:00.0 VGA compatible controller [0300]: NVIDIA Corporation GK107GLM [Quadro K2000M] [10de:0ffb] (rev a1) (prog-if 00 [VGA controller])
01:00.1 Audio device [0403]: NVIDIA Corporation GK107 HDMI Audio Controller [10de:0e1b] (rev a1)
Date: bios-release-date     : 10/08/2013
Use _DSM!

088 Dell_Inc.-Inspiron_7737
04:00.0 3D controller [0302]: NVIDIA Corporation GK107M [GeForce GT 750M] [10de:0fe4] (rev a1)
(No audio device found)
Date: bios-release-date     : 10/09/2013
Use _DSM!

089 LENOVO-20AWS02A00
02:00.0 VGA compatible controller [0300]: NVIDIA Corporation GK208M [GeForce GT 730M] [10de:1290] (rev a1) (prog-if 00 [VGA controller])
(No audio device found)
Date: bios-release-date     : 10/27/2013
Got _PR3!

090 Dell_Inc.-Inspiron_7537
04:00.0 3D controller [0302]: NVIDIA Corporation GK107M [GeForce GT 750M] [10de:0fe4] (rev a1)
(No audio device found)
Date: bios-release-date     : 10/31/2013
Use _DSM!

091 Dell_Inc.-XPS_2720
01:00.0 VGA compatible controller [0300]: NVIDIA Corporation GK107M [GeForce GT 750M] [10de:0fe4] (rev a1) (prog-if 00 [VGA controller])
(No audio device found)
Date: bios-release-date     : 12/11/2013
Use _DSM!

092 ASUS-All_Series
01:00.0 VGA compatible controller [0300]: NVIDIA Corporation GK106 [GeForce GTX 660] [10de:11c0] (rev a1) (prog-if 00 [VGA controller])
01:00.1 Audio device [0403]: NVIDIA Corporation GK106 HDMI Audio Controller [10de:0e0b] (rev a1)
Date: bios-release-date     : 01/06/2014
Use _DSM!

093 ASUSTeK_COMPUTER_INC.-N750JK
01:00.0 3D controller [0302]: NVIDIA Corporation Device [10de:1391] (rev a2)
(No audio device found)
Date: bios-release-date     : 01/17/2014
Got _PR3!

094 Novatech_Ltd.-Novatech_15.6_NSPIRE_Laptop
01:00.0 3D controller [0302]: NVIDIA Corporation GK107M [GeForce GT 745M] [10de:0fe3] (rev ff) (prog-if ff)
(No audio device found)
Date: bios-release-date     : 01/20/2014
Got _PR3!

095 Notebook-W35xSTQ_370ST
01:00.0 3D controller [0302]: NVIDIA Corporation GK106M [GeForce GTX 765M] [10de:11e2] (rev a1)
(No audio device found)
Date: bios-release-date     : 03/12/2014
Use _DSM!

096 Notebook-P17SM-A
01:00.0 VGA compatible controller [0300]: NVIDIA Corporation GK104M [GeForce GTX 860M] [10de:119a] (rev ff) (prog-if ff)
(No audio device found)
Date: bios-release-date     : 03/27/2014
Got _PR3!

097 Dell_Inc.-XPS_15_9530
02:00.0 3D controller [0302]: NVIDIA Corporation GK107M [GeForce GT 750M] [10de:0fe4] (rev ff) (prog-if ff)
(No audio device found)
Date: bios-release-date     : 03/28/2014
Got _PR3!

098 ASUSTeK_Computer_INC.-EB1037
01:00.0 3D controller [0302]: NVIDIA Corporation GF117M [GeForce 610M/710M/820M / GT 620M/625M/630M/720M] [10de:1140] (rev a1)
(No audio device found)
Date: bios-release-date     : 06/23/2014
Got _PR3!

099 ASUSTeK_COMPUTER_INC.-Q551LN
04:00.0 3D controller [0302]: NVIDIA Corporation GM108M [GeForce 840M] [10de:1341] (rev ff) (prog-if ff)
(No audio device found)
Date: bios-release-date     : 06/26/2014
Got _PR3!

100 LENOVO-20BG0011US
01:00.0 VGA compatible controller [0300]: NVIDIA Corporation GK107GLM [Quadro K1100M] [10de:0ff6] (rev a1) (prog-if 00 [VGA controller])
(No audio device found)
Date: bios-release-date     : 07/02/2014
Got _PR3!

101 ASUSTeK_COMPUTER_INC.-X555LD
04:00.0 3D controller [0302]: NVIDIA Corporation GF117M [GeForce 610M/710M/820M / GT 620M/625M/630M/720M] [10de:1140] (rev ff) (prog-if ff)
(No audio device found)
Date: bios-release-date     : 08/14/2014
Got _PR3!

102 Dell_Inc.-Latitude_E6530
01:00.0 VGA compatible controller [0300]: NVIDIA Corporation GF108GLM [NVS 5200M] [10de:0dfc] (rev a1) (prog-if 00 [VGA controller])
(No audio device found)
Date: bios-release-date     : 09/24/2014
Use _DSM!

103 Dell_Inc.-Inspiron_3543
08:00.0 3D controller [0302]: NVIDIA Corporation GF117M [GeForce 610M/710M/820M / GT 620M/625M/630M/720M] [10de:1140] (rev a1)
(No audio device found)
Date: bios-release-date     : 11/04/2014
Got _PR3!

104 Hewlett-Packard-HP_ENVY_TS_15_Notebook_PC
01:00.0 3D controller [0302]: NVIDIA Corporation GK208M [GeForce GT 740M] [10de:1292] (rev a1)
(No audio device found)
Date: bios-release-date     : 11/20/2014
Got _PR3!

105 ASUSTeK_COMPUTER_INC.-UX303LNB
03:00.0 3D controller [0302]: NVIDIA Corporation GM108M [GeForce 840M] [10de:1341] (rev a2)
(No audio device found)
Date: bios-release-date     : 12/10/2014
Got _PR3!

106 Micro-Star_International_Co.,_Ltd.-GS70_2PC_Stealth
01:00.0 3D controller [0302]: NVIDIA Corporation GK104M [GeForce GTX 860M] [10de:119a] (rev ff) (prog-if ff)
(No audio device found)
Date: bios-release-date     : 01/13/2015
Got _PR3!

107 Hewlett-Packard-HP_ZBook_15
01:00.0 VGA compatible controller [0300]: NVIDIA Corporation GK208GLM [Quadro K610M] [10de:12b9] (rev a1) (prog-if 00 [VGA controller])
01:00.1 Audio device [0403]: NVIDIA Corporation GK208 HDMI/DP Audio Controller [10de:0e0f] (rev a1)
Date: bios-release-date     : 03/31/2015
Use _DSM!

108 CLEVO-P65xSE-A
01:00.0 3D controller [0302]: NVIDIA Corporation Device [10de:13d8] (rev ff) (prog-if ff)
(No audio device found)
Date: bios-release-date     : 10/12/2015
Got _PR3!

109 ASUSTeK_COMPUTER_INC.-G501JW
01:00.0 3D controller [0302]: NVIDIA Corporation GM107M [GeForce GTX 960M] [10de:139b] (rev ff) (prog-if ff)
(No audio device found)
Date: bios-release-date     : 10/28/2015
Got _PR3!

110 Notebook-P65_P67RGRERA
01:00.0 VGA compatible controller [0300]: NVIDIA Corporation GM204M [GeForce GTX 970M] [10de:13d8] (rev a1) (prog-if 00 [VGA controller])
(No audio device found)
Date: bios-release-date     : 12/21/2015
Got _PR3!

111 Notebook-N15_17RD
01:00.0 VGA compatible controller [0300]: NVIDIA Corporation GM107M [GeForce GTX 960M] [10de:139b] (rev a2) (prog-if 00 [VGA controller])
(No audio device found)
Date: bios-release-date     : 12/25/2015
Got _PR3!


[-- Attachment #3: get-urls.awk --]
[-- Type: text/plain, Size: 1218 bytes --]

#!/usr/bin/gawk -f
# Example usage to download the files, preserving time and following redirs:
# curl -o 752542.html https://bugs.launchpad.net/lpbugreporter/+bug/752542 &&
# ./get-urls.awk 752542.html |
# awk 'NR<=50{print "-O", $0}' | (cd /tmp/lp/dl/ && time xargs curl -qvRL)
BEGIN {
        FS="\""
        delete entries
}
/portlet-attachments/ { p = 1}
# The few .zip and .tar and .tar.bz2 did not seem interesting. Also ignore plain
# .dsl{,.gz,.bz2}, .txt and .dat files.
p && /+files\/.*\.tar\.gz"/ {
        url = $2
        split(url, parts, "/")
        name = parts[10]
        id = parts[8]

        #print url;
        # Overwrite older names with newer submissions.
        entries[name] = url
        ids[id] = name
}

END {
        # Sort by attachment ID
        asorti(ids, ids_sorted)
        # Print attachments in reverse (newest first)
        for (i = length(ids_sorted); i > 0; i--) {
                id = ids_sorted[i]
                name = ids[id]
                if (entries[name]) {
                        url = entries[name]
                        print url
                        # Do not print duplicates
                        delete entries[name]
                }
        }
}

[-- Attachment #4: has-audio-problem.sh --]
[-- Type: application/x-sh, Size: 2084 bytes --]

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

* Re: [PATCH v3 0/4] nouveau RPM fixes for Optimus (final)
       [not found] ` <20160715131218.2416-1-peter-VTkQYDcBqhK7DlmcbJSQ7g@public.gmane.org>
                     ` (2 preceding siblings ...)
  2016-07-15 13:12   ` [PATCH v3 3/4] drm/nouveau/acpi: check for function 0x1B before using it Peter Wu
@ 2016-07-27 12:02   ` Peter Wu
  3 siblings, 0 replies; 20+ messages in thread
From: Peter Wu @ 2016-07-27 12:02 UTC (permalink / raw)
  To: Dave Airlie, Ben Skeggs
  Cc: nouveau-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW,
	dri-devel-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW

Ping, would it be possible to get some acks and merge it for 4.8?
Current -next is broken (on modern laptops as expected) and these series
fix the issues according to an IRC report.

The audio issue mentioned below should not give issues, modern laptops
do not seem to expose the audio device by default
(https://bugs.freedesktop.org/show_bug.cgi?id=75985). On Windows the
audio device only appears after inserting the HDMI/miniDP cable (my
laptop has no other connectors), enabling the card for rendering
purposes has no effect on the availability of the audio device.

Kind regards,
Peter

On Fri, Jul 15, 2016 at 03:12:14PM +0200, Peter Wu wrote:
> Hi,
> 
> Here are two patches to fix an issue reported on kernel bugzilla (infinite loop
> due to unchecked function) and a more important fix to fix hanging Optimus
> machines when runtime PM is enabled (with pm/pci patches).
> 
> These are the final patches targeting v4.8. Changes compared to v2[1]:
> collected R-b from Hans and Mika and fixed a minor comment style issue.
> 
> I recommend it to be merged before the pci/pm patches[2], otherwise there is a
> window where newer Nvidia Optimus laptops might fail to runtime resume and/or
> lock up.  Once the pci/pm branch is merged I will propose another patch to
> improve reliability[3].
> 
> Known issue with patch 4: when a Nvidia HDMI audio function is present, the
> bridge will not suspend and hence the Nvidia card will still be powered. Fixing
> this properly will require more work[4], until then you can kill the audio
> device and make runtime PM work properly:
> 
>     echo 1 > /sys/bus/pci/devices/0000:01:00.1/remove
> 
> Kind regards,
> Peter
> 
>  [1]: https://lists.freedesktop.org/archives/nouveau/2016-July/025519.html
>  [2]: https://git.kernel.org/cgit/linux/kernel/git/helgaas/pci.git/?h=pci/pm
>  [3]: http://www.spinics.net/lists/linux-pci/msg52601.html
>  [4]: https://lists.freedesktop.org/archives/dri-devel/2016-July/112759.html
> 
> Peter Wu (4):
>   drm/nouveau/acpi: ensure matching ACPI handle and supported functions
>   drm/nouveau/acpi: return supported DSM functions
>   drm/nouveau/acpi: check for function 0x1B before using it
>   drm/nouveau/acpi: fix lockup with PCIe runtime PM
> 
>  drivers/gpu/drm/nouveau/nouveau_acpi.c | 105 +++++++++++++++++++++------------
>  1 file changed, 68 insertions(+), 37 deletions(-)
> 
> -- 
> 2.9.0
_______________________________________________
Nouveau mailing list
Nouveau@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/nouveau

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

end of thread, other threads:[~2016-07-27 12:02 UTC | newest]

Thread overview: 20+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-07-15 13:12 [PATCH v3 0/4] nouveau RPM fixes for Optimus (final) Peter Wu
2016-07-15 13:12 ` Peter Wu
2016-07-15 13:12 ` [PATCH v3 4/4] drm/nouveau/acpi: fix lockup with PCIe runtime PM Peter Wu
2016-07-15 16:10 ` [Nouveau] [PATCH v3 0/4] nouveau RPM fixes for Optimus (final) Ilia Mirkin
2016-07-15 16:10   ` Ilia Mirkin
2016-07-15 16:27   ` [Nouveau] " Alex Deucher
2016-07-15 16:31     ` Ilia Mirkin
2016-07-15 16:40       ` Alex Deucher
2016-07-15 16:40         ` Alex Deucher
2016-07-15 16:42         ` Ilia Mirkin
2016-07-15 16:42           ` Ilia Mirkin
2016-07-15 16:36   ` [Nouveau] " Peter Wu
2016-07-15 16:41     ` Ilia Mirkin
2016-07-15 16:54       ` Peter Wu
2016-07-15 16:54         ` Peter Wu
2016-07-15 23:24         ` Peter Wu
     [not found] ` <20160715131218.2416-1-peter-VTkQYDcBqhK7DlmcbJSQ7g@public.gmane.org>
2016-07-15 13:12   ` [PATCH v3 1/4] drm/nouveau/acpi: ensure matching ACPI handle and supported functions Peter Wu
2016-07-15 13:12   ` [PATCH v3 2/4] drm/nouveau/acpi: return supported DSM functions Peter Wu
2016-07-15 13:12   ` [PATCH v3 3/4] drm/nouveau/acpi: check for function 0x1B before using it Peter Wu
2016-07-27 12:02   ` [PATCH v3 0/4] nouveau RPM fixes for Optimus (final) Peter Wu

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.