search for: vga_switcheroo_off

Displaying 16 results from an estimated 16 matches for "vga_switcheroo_off".

2018 Feb 11
2
[PATCH 0/5] Fix deadlock on runtime suspend in DRM drivers
...suspend(struct device *dev) return -EBUSY; } + printk("waiting 12 sec\n"); + msleep(12*1000); + printk("done waiting 12 sec\n"); drm_dev->switch_power_state = DRM_SWITCH_POWER_CHANGING; drm_kms_helper_poll_disable(drm_dev); vga_switcheroo_set_dynamic_switch(pdev, VGA_SWITCHEROO_OFF); diff --git a/drivers/gpu/drm/drm_probe_helper.c b/drivers/gpu/drm/drm_probe_helper.c index 555fbe5..ee7cf0d 100644 --- a/drivers/gpu/drm/drm_probe_helper.c +++ b/drivers/gpu/drm/drm_probe_helper.c @@ -586,6 +586,7 @@ static void output_poll_execute(struct work_struct *work) repoll = true; g...
2018 Feb 11
0
[PATCH 0/5] Fix deadlock on runtime suspend in DRM drivers
...suspend(struct device *dev) return -EBUSY; } + printk("waiting 12 sec\n"); + msleep(12*1000); + printk("done waiting 12 sec\n"); drm_dev->switch_power_state = DRM_SWITCH_POWER_CHANGING; drm_kms_helper_poll_disable(drm_dev); vga_switcheroo_set_dynamic_switch(pdev, VGA_SWITCHEROO_OFF); diff --git a/drivers/gpu/drm/drm_probe_helper.c b/drivers/gpu/drm/drm_probe_helper.c index 555fbe5..ee7cf0d 100644 --- a/drivers/gpu/drm/drm_probe_helper.c +++ b/drivers/gpu/drm/drm_probe_helper.c @@ -586,6 +586,7 @@ static void output_poll_execute(struct work_struct *work) repoll = true; g...
2015 May 28
12
[PATCH v2 1/9] acpi: Rename v1 DSM to mux to avoid ambiguity
...eau_vga.c index c7592ec..6297566 100644 --- a/drm/nouveau/nouveau_vga.c +++ b/drm/nouveau/nouveau_vga.c @@ -36,7 +36,7 @@ nouveau_switcheroo_set_state(struct pci_dev *pdev, { struct drm_device *dev = pci_get_drvdata(pdev); - if ((nouveau_is_optimus() || nouveau_is_v1_dsm()) && state == VGA_SWITCHEROO_OFF) + if ((nouveau_is_optimus() || nouveau_has_mux()) && state == VGA_SWITCHEROO_OFF) return; if (state == VGA_SWITCHEROO_ON) { @@ -96,11 +96,11 @@ nouveau_vga_init(struct nouveau_drm *drm) if (nouveau_runtime_pm == 1) runtime = true; - if ((nouveau_runtime_pm == -1) && (...
2015 May 28
3
[PATCH v2 8/9] acpi: Add support for Apple Gmux _DMS
...4 > --- a/drm/nouveau/nouveau_vga.c > +++ b/drm/nouveau/nouveau_vga.c > @@ -36,7 +36,7 @@ nouveau_switcheroo_set_state(struct pci_dev *pdev, > { > struct drm_device *dev = pci_get_drvdata(pdev); > > - if ((nouveau_is_optimus() || nouveau_has_mux()) && state == > VGA_SWITCHEROO_OFF) If I understand it correctly, if the laptop is an Optimus one or has a mux, we are not "allowed" to opt-out of DynPwr/DynOff by powering down the card? In the same commit adding this conditional (5addcf0a5f0fadceba6bd562d0616a1c5d4c1a4d), you added the possibility to enable/disable dynp...
2014 Mar 19
2
[PATCH] drm: compute runpm on load, don't register autosuspend for non-runpm
...f (nouveau_runtime_pm == -1 && !nouveau_is_optimus() && !nouveau_is_v1_dsm()) { - DRM_DEBUG_DRIVER("failing to power off - not optimus\n"); - return -EINVAL; - } - nv_debug_level(SILENT); drm_kms_helper_poll_disable(drm_dev); vga_switcheroo_set_dynamic_switch(pdev, VGA_SWITCHEROO_OFF); @@ -951,12 +949,6 @@ static int nouveau_pmops_runtime_idle(struct device *dev) if (nouveau_runtime_pm == 0) return -EBUSY; - /* are we optimus enabled? */ - if (nouveau_runtime_pm == -1 && !nouveau_is_optimus() && !nouveau_is_v1_dsm()) { - DRM_DEBUG_DRIVER("failing to...
2018 Feb 18
12
[PATCH 0/7] Modernize vga_switcheroo by using device link for HDA
Modernize vga_switcheroo by using a "device link" to enforce a runtime PM dependency from an HDA controller to the GPU it's integrated into. Remove thereby obsoleted code and fix a bunch of bugs. Device links were introduced in v4.10. Users might see a small power saving if the discrete GPU is in use and its HDA controller is not, because the HDA controller is now allowed to runtime
2018 Mar 03
12
[PATCH v2 0/7] Modernize vga_switcheroo by using device link for HDA
Modernize vga_switcheroo by using a device link to enforce a runtime PM dependency from an HDA controller to the GPU it's integrated into, v2. Changes since v1: - Replace patch [1/7] to use pci_save_state() / pci_restore_state() for consistency between runtime PM code path of bound and unbound devices. (Rafael, Bjorn) - Patch [5/7]: Drop an unnecessary initialization. (Bjorn) Rephrase
2018 Feb 18
0
[PATCH 5/7] vga_switcheroo: Use device link for HDA controller
...drm/amd/amdgpu/amdgpu_drv.c +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c @@ -720,7 +720,6 @@ static int amdgpu_pmops_runtime_suspend(struct device *dev) drm_dev->switch_power_state = DRM_SWITCH_POWER_CHANGING; drm_kms_helper_poll_disable(drm_dev); - vga_switcheroo_set_dynamic_switch(pdev, VGA_SWITCHEROO_OFF); ret = amdgpu_device_suspend(drm_dev, false, false); pci_save_state(pdev); @@ -757,7 +756,6 @@ static int amdgpu_pmops_runtime_resume(struct device *dev) ret = amdgpu_device_resume(drm_dev, false, false); drm_kms_helper_poll_enable(drm_dev); - vga_switcheroo_set_dynamic_switch(pdev, VG...
2013 Dec 12
1
[PATCH] drm/nouveau: only runtime suspend by default in optimus configuration
...f (nouveau_runtime_pm == -1 && !nouveau_is_optimus() && !nouveau_is_v1_dsm()) { + DRM_DEBUG_DRIVER("failing to power off - not optimus\n"); + return -EINVAL; + } + nv_debug_level(SILENT); drm_kms_helper_poll_disable(drm_dev); vga_switcheroo_set_dynamic_switch(pdev, VGA_SWITCHEROO_OFF); -- 1.8.3.2
2014 Mar 19
0
[PATCH] drm: compute runpm on load, don't register autosuspend for non-runpm
...1_dsm()) { > - DRM_DEBUG_DRIVER("failing to power off - not optimus\n"); > - return -EINVAL; > - } > - > nv_debug_level(SILENT); > drm_kms_helper_poll_disable(drm_dev); > vga_switcheroo_set_dynamic_switch(pdev, VGA_SWITCHEROO_OFF); > @@ -951,12 +949,6 @@ static int nouveau_pmops_runtime_idle(struct device *dev) > if (nouveau_runtime_pm == 0) > return -EBUSY; > > - /* are we optimus enabled? */ > - if (nouveau_runtime_pm == -1 && !nouveau_is_optimus() && !...
2018 Feb 20
2
[PATCH 5/7] vga_switcheroo: Use device link for HDA controller
...t; +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c > @@ -720,7 +720,6 @@ static int amdgpu_pmops_runtime_suspend(struct device *dev) > > drm_dev->switch_power_state = DRM_SWITCH_POWER_CHANGING; > drm_kms_helper_poll_disable(drm_dev); > - vga_switcheroo_set_dynamic_switch(pdev, VGA_SWITCHEROO_OFF); > > ret = amdgpu_device_suspend(drm_dev, false, false); > pci_save_state(pdev); > @@ -757,7 +756,6 @@ static int amdgpu_pmops_runtime_resume(struct device *dev) > > ret = amdgpu_device_resume(drm_dev, false, false); > drm_kms_helper_poll_enable(drm_dev); > - vg...
2015 Jan 17
0
[PATCH RFC] nouveau: Add support for Gmux _DSM method
...to get some comments. Not sure if it is really related to the gmux or if it is a different Optimus _DSM version. I tested it on my laptop (MCP79/7A + G96) and the G96 successfully goes to sleep, however it is still marked as PWR in vga_switcheroo, despite `vga_switcheroo_set_dynamic_switch(pdev, VGA_SWITCHEROO_OFF)` being called. --- drm/nouveau_acpi.c | 94 +++++++++++++++++++++++++++++++++++++++++++++++++++--- drm/nouveau_acpi.h | 2 ++ drm/nouveau_drm.c | 4 +-- 3 files changed, 94 insertions(+), 6 deletions(-) diff --git a/drm/nouveau_acpi.c b/drm/nouveau_acpi.c index 6224246..a71229a 100644 --- a/d...
2016 Jan 11
0
[PATCH v5 01/12] vga_switcheroo: Add handler flags infrastructure
...ed by handlers to declare their capabilities upon + * registering with vga_switcheroo. + */ +enum vga_switcheroo_handler_flags_t { + VGA_SWITCHEROO_CAN_SWITCH_DDC = (1 << 0), + VGA_SWITCHEROO_NEEDS_EDP_CONFIG = (1 << 1), +}; + +/** * enum vga_switcheroo_state - client power state * @VGA_SWITCHEROO_OFF: off * @VGA_SWITCHEROO_ON: on @@ -132,8 +152,10 @@ int vga_switcheroo_register_audio_client(struct pci_dev *pdev, void vga_switcheroo_client_fb_set(struct pci_dev *dev, struct fb_info *info); -int vga_switcheroo_register_handler(const struct vga_switcheroo_handler *handler); +int vga_sw...
2015 May 25
15
[PATCH 1/8] acpi: Rename v1 DSM to mux to avoid ambiguity
...eau_vga.c index c7592ec..6297566 100644 --- a/drm/nouveau/nouveau_vga.c +++ b/drm/nouveau/nouveau_vga.c @@ -36,7 +36,7 @@ nouveau_switcheroo_set_state(struct pci_dev *pdev, { struct drm_device *dev = pci_get_drvdata(pdev); - if ((nouveau_is_optimus() || nouveau_is_v1_dsm()) && state == VGA_SWITCHEROO_OFF) + if ((nouveau_is_optimus() || nouveau_has_mux()) && state == VGA_SWITCHEROO_OFF) return; if (state == VGA_SWITCHEROO_ON) { @@ -96,11 +96,11 @@ nouveau_vga_init(struct nouveau_drm *drm) if (nouveau_runtime_pm == 1) runtime = true; - if ((nouveau_runtime_pm == -1) && (...
2018 Feb 11
19
[PATCH 0/5] Fix deadlock on runtime suspend in DRM drivers
Fix a deadlock on hybrid graphics laptops that's been present since 2013: DRM drivers poll connectors in 10 sec intervals. The poll worker is stopped on ->runtime_suspend with cancel_delayed_work_sync(). However the poll worker invokes the DRM drivers' ->detect callbacks, which call pm_runtime_get_sync(). If the poll worker starts after runtime suspend has begun,
2016 Jan 11
8
[PATCH v5 00/12] Enable GPU switching on pre-retina MacBook Pro
Enable GPU switching on the pre-retina MacBook Pro (2008 - 2013), v5. The main obstacle on these machines is that the panel mode in VBIOS is bogus. Fortunately gmux can switch DDC independently from the display, thereby allowing the inactive GPU to probe the panel's EDID. In short, vga_switcheroo and apple-gmux are amended with hooks to switch DDC, DRM core is amended with a