search for: nv50_backlight_init

Displaying 20 results from an estimated 28 matches for "nv50_backlight_init".

2023 Mar 26
1
[PATCH 6.2 regression fix] drm/nouveau/kms: Fix backlight registration
...After commit 4a16dd9d18a0 ("drm/nouveau/kms: switch to drm fbdev helpers") the fbdev emulation code, which now is a drm-client, can only run after drm_dev_register(). So during backlight registration the connectors are not probed yet and the drm_connector->status == connected check in nv50_backlight_init() would now always fail. Replace the drm_connector->status == connected check with a drm_helper_probe_detect() == connected check to fix nv_backlight no longer getting registered because of this. Fixes: 4a16dd9d18a0 ("drm/nouveau/kms: switch to drm fbdev helpers") Link: https://gitla...
2023 Mar 28
1
[PATCH 6.2 regression fix] drm/nouveau/kms: Fix backlight registration
...9d18a0 ("drm/nouveau/kms: switch to drm fbdev helpers") > the fbdev emulation code, which now is a drm-client, can only run after > drm_dev_register(). So during backlight registration the connectors are > not probed yet and the drm_connector->status == connected check in > nv50_backlight_init() would now always fail. > > Replace the drm_connector->status == connected check with > a drm_helper_probe_detect() == connected check to fix nv_backlight > no longer getting registered because of this. > > Fixes: 4a16dd9d18a0 ("drm/nouveau/kms: switch to drm fbdev help...
2016 May 21
2
[PATCH] drm/nouveau: add Maxwell to backlight initialization
.../gpu/drm/nouveau/nouveau_backlight.c +++ b/drivers/gpu/drm/nouveau/nouveau_backlight.c @@ -232,6 +232,7 @@ nouveau_backlight_init(struct drm_device *dev) case NV_DEVICE_INFO_V0_TESLA: case NV_DEVICE_INFO_V0_FERMI: case NV_DEVICE_INFO_V0_KEPLER: + case NV_DEVICE_INFO_V0_MAXWELL: return nv50_backlight_init(connector); default: break; -- 2.1.4
2018 Aug 23
6
[PATCH 0/5] drm/nouveau: Backlight fixes and cleanup
This series fixes some issues with nouveau's backlight support that were causing kernel panics on module reloads, specifically on systems with nouveau handling the backlight of one of the displays. While we're at it, let's cleanup nouveau_backlight.c as well Lyude Paul (5): drm/nouveau: Check backlight IDs are >= 0, not > 0 drm/nouveau: Move backlight device into
2016 Apr 15
11
[PATCH 1/2] nouveau/bl: Assign different names to interfaces
...= backlight_device_register(backlight_name , connector->kdev, drm, &nv40_bl_ops, &props); + + // backlight_device_register() makes a copy + kfree(backlight_name); + backlight_name = NULL; + if (IS_ERR(bd)) return PTR_ERR(bd); drm->backlight = bd; @@ -182,6 +193,7 @@ nv50_backlight_init(struct drm_connector *connector) struct backlight_properties props; struct backlight_device *bd; const struct backlight_ops *ops; + char* backlight_name = NULL; nv_encoder = find_encoder(connector, DCB_OUTPUT_LVDS); if (!nv_encoder) { @@ -203,8 +215,14 @@ nv50_backlight_init(struct drm_...
2018 Aug 29
5
[PATCH v2 0/5] drm/nouveau: Backlight fixes and cleanup
Next version of https://patchwork.freedesktop.org/series/48596/ . Made some important changes to the refactoring patch, but everything else is the same. Lyude Paul (5): drm/nouveau: Check backlight IDs are >= 0, not > 0 drm/nouveau: Move backlight device into nouveau_connector drm/nouveau: s/nouveau_backlight_exit/nouveau_backlight_fini/ drm/nouveau: Cleanup indenting in
2018 Aug 29
6
[PATCH RESEND v3 0/6] drm/nouveau: Backlight fixes and cleanup
Forgot to send 6 patches instead of five since there's one new one now, whoops! No actual changes, next version of https://patchwork.freedesktop.org/series/48596/ Lyude Paul (6): drm/nouveau: Check backlight IDs are >= 0, not > 0 drm/nouveau: Add NV_PRINTK_ONCE and variants drm/nouveau: Move backlight device into nouveau_connector drm/nouveau:
2018 Sep 06
7
[PATCH v4 0/6] Backlight fixes and cleanup
Refactor for Ben, hopefully this time this should apply to his tree. Next version of https://patchwork.freedesktop.org/series/48596/ No changes otherwise. Lyude Paul (6): drm/nouveau: Check backlight IDs are >= 0, not > 0 drm/nouveau: Add NV_PRINTK_ONCE and variants drm/nouveau: Move backlight device into nouveau_connector drm/nouveau:
2018 Aug 29
5
[PATCH v3 0/5] drm/nouveau: Backlight fixes and cleanup
Next version of https://patchwork.freedesktop.org/series/48596/ . Added NV_INFO_ONCE and made "Move backlight device into nouveau_connector" use that instead so we don't print the GMUX warning more then once. Lyude Paul (5): drm/nouveau: Add NV_PRINTK_ONCE and variants drm/nouveau: Move backlight device into nouveau_connector drm/nouveau:
2018 Feb 16
0
[PATCH] bl: fix backlight regression
...c +++ b/drm/nouveau/nouveau_backlight.c @@ -38,6 +38,8 @@ #include "nouveau_reg.h" #include "nouveau_encoder.h" +#include "nv50_display.h" + static struct ida bl_ida; #define BL_NAME_SIZE 15 // 12 for name + 2 for digits + 1 for '\0' @@ -220,6 +222,7 @@ nv50_backlight_init(struct drm_connector *connector) const struct backlight_ops *ops; struct backlight_connector bl_connector; char backlight_name[BL_NAME_SIZE]; + int ret; nv_encoder = find_encoder(connector, DCB_OUTPUT_LVDS); if (!nv_encoder) { @@ -228,8 +231,12 @@ nv50_backlight_init(struct drm_connecto...
2013 Sep 01
0
[PATCH] drm/nv50: Fix backlight not working when PWM_DIV is uninitialised
...vice(drm->device); + int or = nv_encoder->or; + + if (device->card_type == NV_50 && + (device->chipset <= 0xa0 || + device->chipset == 0xaa || + device->chipset == 0xac)) + nv_wr32(device, NV50_PDISP_SOR_PWM_DIV(or), 0x5e); + + return 0; +} + static int nv50_backlight_init(struct drm_connector *connector) { @@ -191,9 +208,6 @@ nv50_backlight_init(struct drm_connector *connector) return -ENODEV; } - if (!nv_rd32(device, NV50_PDISP_SOR_PWM_CTL(nv_encoder->or))) - return 0; - if (device->chipset <= 0xa0 || device->chipset == 0xaa || d...
2018 Aug 23
1
[PATCH 1/5] drm/nouveau: Check backlight IDs are >= 0, not > 0
...ops); > > if (IS_ERR(bd)) { > - if (bl_connector.id > 0) > + if (bl_connector.id >= 0) > ida_simple_remove(&bl_ida, bl_connector.id); > return PTR_ERR(bd); > } > @@ -249,7 +249,7 @@ nv50_backlight_init(struct drm_connector *connector) > nv_encoder, ops, &props); > > if (IS_ERR(bd)) { > - if (bl_connector.id > 0) > + if (bl_connector.id >= 0) > ida_simple_remove(&bl_id...
2016 Apr 15
0
[PATCH 1/2] nouveau/bl: Assign different names to interfaces
...v40_bl_ops, &props); > + > + // backlight_device_register() makes a copy > + kfree(backlight_name); > + backlight_name = NULL; > + > if (IS_ERR(bd)) > return PTR_ERR(bd); > drm->backlight = bd; > @@ -182,6 +193,7 @@ nv50_backlight_init(struct drm_connector *connector) > struct backlight_properties props; > struct backlight_device *bd; > const struct backlight_ops *ops; > + char* backlight_name = NULL; > > nv_encoder = find_encoder(connector, DCB_OUTPUT_LVDS); > if...
2016 Nov 13
1
[PATCH v3 1/2] nouveau/bl: Assign different names to interfaces
...f (bl_connector.id > 0) + ida_simple_remove(&bl_ida, bl_connector.id); return PTR_ERR(bd); + } + list_add(&bl_connector.head, &drm->bl_connectors); drm->backlight = bd; bd->props.brightness = nv40_get_intensity(bd); backlight_update_status(bd); @@ -182,6 +211,8 @@ nv50_backlight_init(struct drm_connector *connector) struct backlight_properties props; struct backlight_device *bd; const struct backlight_ops *ops; + struct backlight_connector bl_connector; + char backlight_name[BL_NAME_SIZE]; nv_encoder = find_encoder(connector, DCB_OUTPUT_LVDS); if (!nv_encoder) { @@...
2018 Feb 19
1
[PATCH v2] bl: fix backlight regression
...t nouveau_drm *drm = nouveau_drm(nv_encoder->base.base.dev); struct nvif_object *device = &drm->client.device.object; - int or = nv_encoder->or; + int or = ffs(nv_encoder->dcb->or) - 1; u32 div, val; div = nvif_rd32(device, NV50_PDISP_SOR_PWM_DIV(or)); @@ -228,7 +228,7 @@ nv50_backlight_init(struct drm_connector *connector) return -ENODEV; } - if (!nvif_rd32(device, NV50_PDISP_SOR_PWM_CTL(nv_encoder->or))) + if (!nvif_rd32(device, NV50_PDISP_SOR_PWM_CTL(ffs(nv_encoder->dcb->or) - 1))) return 0; if (drm->client.device.info.chipset <= 0xa0 || -- 2.14.3
2016 Apr 17
0
[PATCH v2 1/2] nouveau/bl: Assign different names to interfaces
...f (bl_connector.id > 0) + ida_simple_remove(&bl_ida, bl_connector.id); return PTR_ERR(bd); + } + list_add(&bl_connector.head, &drm->bl_connectors); drm->backlight = bd; bd->props.brightness = nv40_get_intensity(bd); backlight_update_status(bd); @@ -182,6 +210,8 @@ nv50_backlight_init(struct drm_connector *connector) struct backlight_properties props; struct backlight_device *bd; const struct backlight_ops *ops; + struct backlight_connector bl_connector; + char backlight_name[15]; // 12 for name + 2 for digits + 1 for '\0' nv_encoder = find_encoder(connector, D...
2016 Dec 07
0
[PATCH v4 1/2] nouveau/bl: Assign different names to interfaces
...f (bl_connector.id > 0) + ida_simple_remove(&bl_ida, bl_connector.id); return PTR_ERR(bd); + } + list_add(&bl_connector.head, &drm->bl_connectors); drm->backlight = bd; bd->props.brightness = nv40_get_intensity(bd); backlight_update_status(bd); @@ -182,6 +217,8 @@ nv50_backlight_init(struct drm_connector *connector) struct backlight_properties props; struct backlight_device *bd; const struct backlight_ops *ops; + struct backlight_connector bl_connector; + char backlight_name[BL_NAME_SIZE]; nv_encoder = find_encoder(connector, DCB_OUTPUT_LVDS); if (!nv_encoder) { @@...
2016 Nov 14
0
[PATCH v3 1/2] nouveau/bl: Assign different names to interfaces
...simple_remove(&bl_ida, bl_connector.id); > return PTR_ERR(bd); > + } > + list_add(&bl_connector.head, &drm->bl_connectors); > drm->backlight = bd; > bd->props.brightness = nv40_get_intensity(bd); > backlight_update_status(bd); > @@ -182,6 +211,8 @@ nv50_backlight_init(struct drm_connector *connector) > struct backlight_properties props; > struct backlight_device *bd; > const struct backlight_ops *ops; > + struct backlight_connector bl_connector; > + char backlight_name[BL_NAME_SIZE]; > > nv_encoder = find_encoder(connector, DCB_OUT...
2016 Apr 15
2
[PATCH 1/2] nouveau/bl: Assign different names to interfaces
...; + // backlight_device_register() makes a copy > > + kfree(backlight_name); > > + backlight_name = NULL; > > + > > if (IS_ERR(bd)) > > return PTR_ERR(bd); > > drm->backlight = bd; > > @@ -182,6 +193,7 @@ nv50_backlight_init(struct drm_connector *connector) > > struct backlight_properties props; > > struct backlight_device *bd; > > const struct backlight_ops *ops; > > + char* backlight_name = NULL; > > > > nv_encoder = find_encoder(connector, DCB...
2018 Jul 05
4
[PATCH 0/2] drm/nouveau: Fix panic on nouveau unload.
If have a couple patches I found while looking at a panic I was seeing while unloading the nouveau module. Unloading the nouveau module on my optimus notebook machine causes the system to panic. This started occuring when moving from 4.4 to 4.14. These patches make it such that the system does not panic when unloading the module. 4.14 also requires commit 34112bf4935d ("drm/nouveau/fbcon: