search for: vga_switcheroo_client_probe_def

Displaying 19 results from an estimated 19 matches for "vga_switcheroo_client_probe_def".

2016 May 21
3
[PATCH v5] vga_switcheroo: Add helper for deferred probing
...ed on dual GPU MacBook Pro - * to probe the panel if we're the inactive GPU. - */ - if (IS_ENABLED(CONFIG_VGA_ARB) && IS_ENABLED(CONFIG_VGA_SWITCHEROO) && - apple_gmux_present() && pdev != vga_default_device() && - !vga_switcheroo_handler_flags()) + if (vga_switcheroo_client_probe_defer(pdev)) return -EPROBE_DEFER; return drm_get_pci_dev(pdev, ent, &driver); diff --git a/drivers/gpu/drm/nouveau/nouveau_drm.c b/drivers/gpu/drm/nouveau/nouveau_drm.c index 11f8dd9..5c4d4df 100644 --- a/drivers/gpu/drm/nouveau/nouveau_drm.c +++ b/drivers/gpu/drm/nouveau/nouveau_drm.c @@ -...
2016 May 31
2
[PATCH v6 1/2] vga_switcheroo: Add helper for deferred probing
...ed on dual GPU MacBook Pro - * to probe the panel if we're the inactive GPU. - */ - if (IS_ENABLED(CONFIG_VGA_ARB) && IS_ENABLED(CONFIG_VGA_SWITCHEROO) && - apple_gmux_present() && pdev != vga_default_device() && - !vga_switcheroo_handler_flags()) + if (vga_switcheroo_client_probe_defer(pdev)) return -EPROBE_DEFER; return drm_get_pci_dev(pdev, ent, &driver); diff --git a/drivers/gpu/drm/nouveau/nouveau_drm.c b/drivers/gpu/drm/nouveau/nouveau_drm.c index 11f8dd9..5c4d4df 100644 --- a/drivers/gpu/drm/nouveau/nouveau_drm.c +++ b/drivers/gpu/drm/nouveau/nouveau_drm.c @@ -...
2016 May 19
2
[PATCH v4] vga_switcheroo: Add helper for deferred probing
...ed on dual GPU MacBook Pro - * to probe the panel if we're the inactive GPU. - */ - if (IS_ENABLED(CONFIG_VGA_ARB) && IS_ENABLED(CONFIG_VGA_SWITCHEROO) && - apple_gmux_present() && pdev != vga_default_device() && - !vga_switcheroo_handler_flags()) + if (vga_switcheroo_client_probe_defer(pdev)) return -EPROBE_DEFER; return drm_get_pci_dev(pdev, ent, &driver); diff --git a/drivers/gpu/drm/nouveau/nouveau_drm.c b/drivers/gpu/drm/nouveau/nouveau_drm.c index db5c7d0..a0bb1d0 100644 --- a/drivers/gpu/drm/nouveau/nouveau_drm.c +++ b/drivers/gpu/drm/nouveau/nouveau_drm.c @@ -...
2016 May 23
0
[Intel-gfx] [PATCH v5] vga_switcheroo: Add helper for deferred probing
...; - * to probe the panel if we're the inactive GPU. > - */ > - if (IS_ENABLED(CONFIG_VGA_ARB) && IS_ENABLED(CONFIG_VGA_SWITCHEROO) && > - apple_gmux_present() && pdev != vga_default_device() && > - !vga_switcheroo_handler_flags()) > + if (vga_switcheroo_client_probe_defer(pdev)) > return -EPROBE_DEFER; > > return drm_get_pci_dev(pdev, ent, &driver); > diff --git a/drivers/gpu/drm/nouveau/nouveau_drm.c b/drivers/gpu/drm/nouveau/nouveau_drm.c > index 11f8dd9..5c4d4df 100644 > --- a/drivers/gpu/drm/nouveau/nouveau_drm.c > +++ b/drivers...
2016 May 31
0
[PATCH v6 2/2] vga_switcheroo: Support deferred probing of audio clients
Daniel Vetter pointed out that vga_switcheroo_client_probe_defer() could be needed by audio clients as well. To avoid mistakes when someone adds conditions for these in the future, constrain the single existing condition to VGA clients by checking for PCI_BASE_CLASS_DISPLAY. This encompasses both PCI_CLASS_DISPLAY_VGA as well as PCI_CLASS_DISPLAY_3D, which is...
2016 May 23
1
[PATCH v4] vga_switcheroo: Add helper for deferred probing
On 21 May 2016 at 15:08, Lukas Wunner <lukas at wunner.de> wrote: > Hi Emil, > > On Fri, May 20, 2016 at 12:41:04AM +0100, Emil Velikov wrote: >> On 19 May 2016 at 15:39, Lukas Wunner <lukas at wunner.de> wrote: >> > +bool vga_switcheroo_client_probe_defer(struct pci_dev *pdev) >> > +{ >> > + if ((pdev->class >> 8) == PCI_CLASS_DISPLAY_VGA) { >> Not sure if we want/need this, yet at least. This changes behaviour >> which is not what refactoring patches should be doing, right ? if >> needed it ought...
2016 May 21
1
[PATCH v4] vga_switcheroo: Add helper for deferred probing
Hi Emil, On Fri, May 20, 2016 at 12:41:04AM +0100, Emil Velikov wrote: > On 19 May 2016 at 15:39, Lukas Wunner <lukas at wunner.de> wrote: > > +bool vga_switcheroo_client_probe_defer(struct pci_dev *pdev) > > +{ > > + if ((pdev->class >> 8) == PCI_CLASS_DISPLAY_VGA) { > Not sure if we want/need this, yet at least. This changes behaviour > which is not what refactoring patches should be doing, right ? if > needed it ought to be a separate pa...
2018 Dec 07
2
next/master boot bisection: Oops in nouveau driver on jetson-tk1
...@@ -458,75 +458,8 @@ nouveau_accel_init(struct nouveau_drm *drm) nouveau_bo_move_init(drm); } -static int nouveau_drm_probe(struct pci_dev *pdev, - const struct pci_device_id *pent) -{ - struct nvkm_device *device; - struct apertures_struct *aper; - bool boot = false; - int ret; - - if (vga_switcheroo_client_probe_defer(pdev)) - return -EPROBE_DEFER; - - /* We need to check that the chipset is supported before booting - * fbdev off the hardware, as there's no way to put it back. - */ - ret = nvkm_device_pci_new(pdev, NULL, "error", true, false, 0, &device); - if (ret) - return ret; - - nvkm...
2018 Feb 18
0
[PATCH 5/7] vga_switcheroo: Use device link for HDA controller
...struct vga_switcheroo_client { struct pci_dev *pdev; @@ -332,8 +331,8 @@ EXPORT_SYMBOL(vga_switcheroo_register_client); * @ops: client callbacks * @id: client identifier * - * Register audio client (audio device on a GPU). The power state of the - * client is assumed to be ON. Beforehand, vga_switcheroo_client_probe_defer() + * Register audio client (audio device on a GPU). The client is assumed + * to use runtime PM. Beforehand, vga_switcheroo_client_probe_defer() * shall be called to ensure that all prerequisites are met. * * Return: 0 on success, -ENOMEM on memory allocation error. @@ -342,7 +341,7 @@ int...
2020 Nov 06
2
[PATCH 2/3] drm/nouveau: manage nouveau_drm lifetime with devres
...; > - kfree(drm); > } > > /* > @@ -720,6 +715,7 @@ static int nouveau_drm_probe(struct pci_dev *pdev, > { > struct nvkm_device *device; > struct drm_device *drm_dev; > + struct nouveau_drm *nv_dev; > int ret; > > if (vga_switcheroo_client_probe_defer(pdev)) > @@ -750,15 +746,16 @@ static int nouveau_drm_probe(struct pci_dev *pdev, > if (nouveau_atomic) > driver_pci.driver_features |= DRIVER_ATOMIC; > > - drm_dev = drm_dev_alloc(&driver_pci, &pdev->dev); > - if (IS_ERR(drm_dev))...
2018 Feb 20
2
[PATCH 5/7] vga_switcheroo: Use device link for HDA controller
...t; struct pci_dev *pdev; > @@ -332,8 +331,8 @@ EXPORT_SYMBOL(vga_switcheroo_register_client); > * @ops: client callbacks > * @id: client identifier > * > - * Register audio client (audio device on a GPU). The power state of the > - * client is assumed to be ON. Beforehand, vga_switcheroo_client_probe_defer() > + * Register audio client (audio device on a GPU). The client is assumed > + * to use runtime PM. Beforehand, vga_switcheroo_client_probe_defer() > * shall be called to ensure that all prerequisites are met. > * > * Return: 0 on success, -ENOMEM on memory allocation error...
2018 Dec 08
0
next/master boot bisection: Oops in nouveau driver on jetson-tk1
...drm) > nouveau_bo_move_init(drm); > } > > -static int nouveau_drm_probe(struct pci_dev *pdev, > - const struct pci_device_id *pent) > -{ > - struct nvkm_device *device; > - struct apertures_struct *aper; > - bool boot = false; > - int ret; > - > - if (vga_switcheroo_client_probe_defer(pdev)) > - return -EPROBE_DEFER; > - > - /* We need to check that the chipset is supported before booting > - * fbdev off the hardware, as there's no way to put it back. > - */ > - ret = nvkm_device_pci_new(pdev, NULL, "error", true, false, 0, > &device);...
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
2016 May 19
0
[PATCH v4] vga_switcheroo: Add helper for deferred probing
Hi Lukas, On 19 May 2016 at 15:39, Lukas Wunner <lukas at wunner.de> wrote: > +bool vga_switcheroo_client_probe_defer(struct pci_dev *pdev) > +{ > + if ((pdev->class >> 8) == PCI_CLASS_DISPLAY_VGA) { Not sure if we want/need this, yet at least. This changes behaviour which is not what refactoring patches should be doing, right ? if needed it ought to be a separate patch, imho. Furthermore o...
2018 Dec 10
2
next/master boot bisection: Oops in nouveau driver on jetson-tk1
...gt; } >> >> -static int nouveau_drm_probe(struct pci_dev *pdev, >> - const struct pci_device_id *pent) >> -{ >> - struct nvkm_device *device; >> - struct apertures_struct *aper; >> - bool boot = false; >> - int ret; >> - >> - if (vga_switcheroo_client_probe_defer(pdev)) >> - return -EPROBE_DEFER; >> - >> - /* We need to check that the chipset is supported before booting >> - * fbdev off the hardware, as there's no way to put it back. >> - */ >> - ret = nvkm_device_pci_new(pdev, NULL, "error", true, fals...
2020 Nov 06
0
[PATCH 2/3] drm/nouveau: manage nouveau_drm lifetime with devres
...gt;client); nouveau_cli_fini(&drm->master); nvif_parent_dtor(&drm->parent); - kfree(drm); } /* @@ -720,6 +715,7 @@ static int nouveau_drm_probe(struct pci_dev *pdev, { struct nvkm_device *device; struct drm_device *drm_dev; + struct nouveau_drm *nv_dev; int ret; if (vga_switcheroo_client_probe_defer(pdev)) @@ -750,15 +746,16 @@ static int nouveau_drm_probe(struct pci_dev *pdev, if (nouveau_atomic) driver_pci.driver_features |= DRIVER_ATOMIC; - drm_dev = drm_dev_alloc(&driver_pci, &pdev->dev); - if (IS_ERR(drm_dev)) { - ret = PTR_ERR(drm_dev); + nv_dev = devm_drm_dev_alloc(...
2018 Aug 23
3
[PATCH 0/3] drm/nouveau: Fixup module probe to add ->shutdown()
This series is intended to add support for shutting down the GPU on kernel shutdown/reboot using the ->shutdown() hook, similar to what amdgpu does. This is mainly intended to workaround a bios issue on the P50 that was preventing nouveau from initializing the dedicated GM107 GPU on that system properly. You can find more details on this issue in the patch labeled "Shut down GPU on kernel
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
2020 Nov 06
4
[PATCH 0/3] drm/nouveau: extend the lifetime of nouveau_drm
Hi folks, Currently, when the device is removed (or the driver is unbound) the nouveau_drm structure de-allocated. However, it's still accessible from and used by some DRM layer callbacks. For example, file handles can be closed after the device has been removed (physically or otherwise). This series converts the Nouveau device structure to be allocated and de-allocated with the