Displaying 20 results from an estimated 21 matches for "nouveau_dsm_get_client_id".
2018 Apr 24
0
[PATCH] drm/nouveau: fix nouveau_dsm_get_client_id()'s return type
The method struct vga_switcheroo_handler::get_client_id() is defined
as returning an 'enum vga_switcheroo_client_id' but the implementation
in this driver, nouveau_dsm_get_client_id(), returns an 'int'.
Fix this by returning 'enum vga_switcheroo_client_id' in this driver too.
Signed-off-by: Luc Van Oostenryck <luc.vanoostenryck at gmail.com>
---
drivers/gpu/drm/nouveau/nouveau_acpi.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/d...
2015 Oct 20
2
[PATCH 0/1] vga_switcheroo: Constify vga_switcheroo_handler
Another vga_switcheroo cleanup. Maintainers, is it okay to include the
one-line change of each driver in here or do you want that split into
separate patches?
Thanks,
Lukas
Lukas Wunner (1):
vga_switcheroo: Constify vga_switcheroo_handler
drivers/gpu/drm/amd/amdgpu/amdgpu_atpx_handler.c | 2 +-
drivers/gpu/drm/nouveau/nouveau_acpi.c | 2 +-
2016 May 25
3
[PATCH 4/4] drm/nouveau/acpi: fix lockup with PCIe runtime PM
...;
> bool optimus_detected;
> bool optimus_flags_detected;
> + bool optimus_skip_dsm;
> acpi_handle dhandle;
> acpi_handle rom_handle;
> } nouveau_dsm_priv;
> @@ -212,8 +213,26 @@ 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_upst...
2020 Apr 23
1
[PATCH 1/1] drm/nouveau: Use generic helper to check _PR3 presence
...ouveau/nouveau_acpi.c b/drivers/gpu/drm/nouveau/nouveau_acpi.c
index fe3a10255c36..b84dff1b0f28 100644
--- a/drivers/gpu/drm/nouveau/nouveau_acpi.c
+++ b/drivers/gpu/drm/nouveau/nouveau_acpi.c
@@ -212,37 +212,6 @@ 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 a...
2016 May 27
3
[PATCH 4/4] drm/nouveau/acpi: fix lockup with PCIe runtime PM
...;
> bool optimus_flags_detected;
> + bool optimus_skip_dsm;
> acpi_handle dhandle;
> acpi_handle rom_handle;
> } nouveau_dsm_priv;
> @@ -212,8 +213,26 @@ 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_...
2016 May 24
7
[PATCH 0/4] nouveau fixes for RPM/Optimus-related hangs
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).
An older (obsolete) patch for the first issue was tested by the reporter:
https://bugzilla.kernel.org/show_bug.cgi?id=104791#c11
(it is replaced by "check for function 0x1B
2016 May 14
1
[PATCH] drm/nouveau: check function before using it
...IMUS_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)
@@ -212,7 +216,7 @@ 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 int nouveau_dsm_pci_probe(struct pci_dev *pdev, uint32_t *optimus_funcs)
{
acpi_handle dhandle;
int retval = 0;
@@ -228,10 +232,8 @@ static int nouveau_dsm_pci_probe(struct pci_dev *pdev)
1 << NOUVEAU_DSM_POWER...
2016 May 30
2
[PATCH 4/4] drm/nouveau/acpi: fix lockup with PCIe runtime PM
...tected;
> > > + bool optimus_skip_dsm;
> > > acpi_handle dhandle;
> > > acpi_handle rom_handle;
> > > } nouveau_dsm_priv;
> > > @@ -212,8 +213,26 @@ 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)
>...
2016 Jul 07
6
[PATCH v2 0/4] nouveau RPM fixes for Optimus
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).
See the first version[1] for a background on the fixed problems. This is the
second revision of incorporating feedback from Emil Velikov (patch 1), Mika
Westerberg (patch 4).
2016 May 30
2
[PATCH 4/4] drm/nouveau/acpi: fix lockup with PCIe runtime PM
...gt; + bool optimus_skip_dsm;
>> > acpi_handle dhandle;
>> > acpi_handle rom_handle;
>> > } nouveau_dsm_priv;
>> > @@ -212,8 +213,26 @@ 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)
>> &...
2016 May 24
0
[PATCH 4/4] drm/nouveau/acpi: fix lockup with PCIe runtime PM
...t 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,8 +213,26 @@ 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_de...
2016 Jul 07
0
[PATCH v2 1/4] drm/nouveau/acpi: ensure matching ACPI handle and supported functions
...-#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(&...
2016 May 27
0
[PATCH 4/4] drm/nouveau/acpi: fix lockup with PCIe runtime PM
...; > bool optimus_flags_detected;
> > + bool optimus_skip_dsm;
> > acpi_handle dhandle;
> > acpi_handle rom_handle;
> > } nouveau_dsm_priv;
> > @@ -212,8 +213,26 @@ 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)
> > +{
> > + str...
2016 Jul 15
0
[PATCH v3 1/4] drm/nouveau/acpi: ensure matching ACPI handle and supported functions
...-#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(&...
2016 Jul 07
0
[PATCH v2 4/4] drm/nouveau/acpi: fix lockup with PCIe runtime PM
...t 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,26 @@ 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_de...
2016 May 27
0
[PATCH 4/4] drm/nouveau/acpi: fix lockup with PCIe runtime PM
...ags_detected;
> > + bool optimus_skip_dsm;
> > acpi_handle dhandle;
> > acpi_handle rom_handle;
> > } nouveau_dsm_priv;
> > @@ -212,8 +213,26 @@ 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)
> > +{
> > +...
2016 May 30
0
[PATCH 4/4] drm/nouveau/acpi: fix lockup with PCIe runtime PM
...bool optimus_skip_dsm;
> > > > acpi_handle dhandle;
> > > > acpi_handle rom_handle;
> > > > } nouveau_dsm_priv;
> > > > @@ -212,8 +213,26 @@ 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(...
2015 Jan 17
0
[PATCH RFC] nouveau: Add support for Gmux _DSM method
...0x69, 0x86, 0x99, 0xE9, 0x8B, 0xFB, 0x49,
+ 0xBD, 0xDB, 0x51, 0xA1, 0xEF, 0xE1, 0x9C, 0x3D,
+};
+
static int nouveau_optimus_dsm(acpi_handle handle, int func, int arg, uint32_t *result)
{
int i;
@@ -212,6 +225,63 @@ static struct vga_switcheroo_handler nouveau_dsm_handler = {
.get_client_id = nouveau_dsm_get_client_id,
};
+static int nouveau_gmux_dsm(acpi_handle handle, int func, int arg, uint32_t *result)
+{
+ int i;
+ union acpi_object *obj;
+ char args_buff[4];
+ union acpi_object argv4 = {
+ .buffer.type = ACPI_TYPE_BUFFER,
+ .buffer.length = 4,
+ .buffer.pointer = args_buff
+ };
+
+ /* ACPI is little...
2016 May 30
0
[PATCH 4/4] drm/nouveau/acpi: fix lockup with PCIe runtime PM
...skip_dsm;
> >> > acpi_handle dhandle;
> >> > acpi_handle rom_handle;
> >> > } nouveau_dsm_priv;
> >> > @@ -212,8 +213,26 @@ 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...
2016 Jul 15
8
[PATCH v3 0/4] nouveau RPM fixes for Optimus (final)
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