Displaying 20 results from an estimated 39 matches for "nouveau_backlight_init".
2018 Feb 17
3
[PATCH] drm/nouveau/bl: Fix oops on driver unbind
Unbinding nouveau on a dual GPU MacBook Pro oopses because we iterate
over the bl_connectors list in nouveau_backlight_exit() but skipped
initializing it in nouveau_backlight_init(). Stacktrace for posterity:
BUG: unable to handle kernel NULL pointer dereference at 0000000000000010
IP: nouveau_backlight_exit+0x2b/0x70 [nouveau]
nouveau_display_destroy+0x29/0x80 [nouveau]
nouveau_drm_unload+0x65/0xe0 [nouveau]
drm_dev_unregister+0x3c/0xe0 [drm]
drm_p...
2016 Apr 15
11
[PATCH 1/2] nouveau/bl: Assign different names to interfaces
Currently, every backlight interface created by Nouveau uses the same name,
nv_backlight. This leads to a sysfs warning as it tries to create an already
existing folder. This patch adds a incremented number to the name, but keeps
the initial name as nv_backlight, to avoid possibly breaking userspace; the
second interface will be named nv_backlight1, and so on.
Fixes: fdo#86539
Signed-off-by:
2018 Mar 14
1
[PATCH] drm/nouveau/bl: Fix oops on driver unbind
On Mon, Feb 19, 2018 at 10:38:04AM +0100, Pierre Moreau wrote:
> On 2018-02-17 13:40, Lukas Wunner wrote:
> > Unbinding nouveau on a dual GPU MacBook Pro oopses because we iterate
> > over the bl_connectors list in nouveau_backlight_exit() but skipped
> > initializing it in nouveau_backlight_init().
> > --- a/drivers/gpu/drm/nouveau/nouveau_backlight.c
> > +++ b/drivers/gpu/drm/nouveau/nouveau_backlight.c
> > @@ -268,13 +268,13 @@ nouveau_backlight_init(struct drm_device *dev)
> > struct nvif_device *device = &drm->client.device;
> > struct drm_conne...
2016 Nov 13
1
[PATCH v3 1/2] nouveau/bl: Assign different names to interfaces
...or.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 = bd->ops->get_brightness(bd);
backlight_update_status(bd);
@@ -221,6 +258,8 @@ nouveau_backlight_init(struct drm_device *dev)
struct nvif_device *device = &drm->device;
struct drm_connector *connector;
+ INIT_LIST_HEAD(&drm->bl_connectors);
+
list_for_each_entry(connector, &dev->mode_config.connector_list, head) {
if (connector->connector_type != DRM_MODE_CONNECTO...
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 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
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 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:
2016 Apr 17
3
[PATCH REBASED 2/2] nouveau/bl: Do not register interface if Apple GMUX detected
...644
--- a/drm/nouveau/nouveau_backlight.c
+++ b/drm/nouveau/nouveau_backlight.c
@@ -30,6 +30,7 @@
* Register locations derived from NVClock by Roderick Colenbrander
*/
+#include <linux/apple-gmux.h>
#include <linux/backlight.h>
#include <linux/idr.h>
@@ -257,6 +258,12 @@ nouveau_backlight_init(struct drm_device *dev)
struct nvif_device *device = &drm->device;
struct drm_connector *connector;
+ if (apple_gmux_present()) {
+ NV_INFO(drm, "Apple GMUX detected: not registering Nouveau"
+ " backlight interface");
+ return 0;
+ }
+
INIT_LIST_HEAD(&...
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:
2016 Apr 17
0
[PATCH v2 1/2] nouveau/bl: Assign different names to interfaces
...or.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 = bd->ops->get_brightness(bd);
backlight_update_status(bd);
@@ -221,6 +257,8 @@ nouveau_backlight_init(struct drm_device *dev)
struct nvif_device *device = &drm->device;
struct drm_connector *connector;
+ INIT_LIST_HEAD(&drm->bl_connectors);
+
list_for_each_entry(connector, &dev->mode_config.connector_list, head) {
if (connector->connector_type != DRM_MODE_CONNECTO...
2016 May 21
2
[PATCH] drm/nouveau: add Maxwell to backlight initialization
...light.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/drivers/gpu/drm/nouveau/nouveau_backlight.c b/drivers/gpu/drm/nouveau/nouveau_backlight.c
index 89eb460..dd1cc9b 100644
--- a/drivers/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
2016 Dec 07
0
[PATCH v4 1/2] nouveau/bl: Assign different names to interfaces
...or.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 = bd->ops->get_brightness(bd);
backlight_update_status(bd);
@@ -221,6 +267,8 @@ nouveau_backlight_init(struct drm_device *dev)
struct nvif_device *device = &drm->device;
struct drm_connector *connector;
+ INIT_LIST_HEAD(&drm->bl_connectors);
+
list_for_each_entry(connector, &dev->mode_config.connector_list, head) {
if (connector->connector_type != DRM_MODE_CONNECTO...
2016 Nov 14
0
[PATCH v3 1/2] nouveau/bl: Assign different names to interfaces
...;bl_ida, bl_connector.id);
> return PTR_ERR(bd);
> + }
>
> + list_add(&bl_connector.head, &drm->bl_connectors);
> drm->backlight = bd;
> bd->props.brightness = bd->ops->get_brightness(bd);
> backlight_update_status(bd);
> @@ -221,6 +258,8 @@ nouveau_backlight_init(struct drm_device *dev)
> struct nvif_device *device = &drm->device;
> struct drm_connector *connector;
>
> + INIT_LIST_HEAD(&drm->bl_connectors);
> +
> list_for_each_entry(connector, &dev->mode_config.connector_list, head) {
> if (connector->...
2016 Dec 07
1
[PATCH v3 2/2] Do not register interface if Apple GMUX detected
...644
--- a/drm/nouveau/nouveau_backlight.c
+++ b/drm/nouveau/nouveau_backlight.c
@@ -30,6 +30,7 @@
* Register locations derived from NVClock by Roderick Colenbrander
*/
+#include <linux/apple-gmux.h>
#include <linux/backlight.h>
#include <linux/idr.h>
@@ -267,6 +268,11 @@ nouveau_backlight_init(struct drm_device *dev)
struct nvif_device *device = &drm->device;
struct drm_connector *connector;
+ if (apple_gmux_present()) {
+ NV_INFO(drm, "Apple GMUX detected: not registering Nouveau backlight interface\n");
+ return 0;
+ }
+
INIT_LIST_HEAD(&drm->bl_connect...
2018 Feb 19
0
[PATCH] drm/nouveau/bl: Fix oops on driver unbind
...well, as the driver gets unloaded? I don’t remember
seeing that issue there though.
On 2018-02-17 — 13:40, Lukas Wunner wrote:
> Unbinding nouveau on a dual GPU MacBook Pro oopses because we iterate
> over the bl_connectors list in nouveau_backlight_exit() but skipped
> initializing it in nouveau_backlight_init(). Stacktrace for posterity:
>
> BUG: unable to handle kernel NULL pointer dereference at 0000000000000010
> IP: nouveau_backlight_exit+0x2b/0x70 [nouveau]
> nouveau_display_destroy+0x29/0x80 [nouveau]
> nouveau_drm_unload+0x65/0xe0 [nouveau]
> drm_dev_unregi...
2013 Sep 01
0
[PATCH] drm/nv50: Fix backlight not working when PWM_DIV is uninitialised
...m/nouveau/nouveau_display.h
index 1ea3e47..d4113be 100644
--- a/drivers/gpu/drm/nouveau/nouveau_display.h
+++ b/drivers/gpu/drm/nouveau/nouveau_display.h
@@ -75,6 +75,7 @@ void nouveau_hdmi_mode_set(struct drm_encoder *, struct drm_display_mode *);
#ifdef CONFIG_DRM_NOUVEAU_BACKLIGHT
extern int nouveau_backlight_init(struct drm_device *);
+extern int nouveau_backlight_config(struct nouveau_drm *);
extern void nouveau_backlight_exit(struct drm_device *);
#else
static inline int
@@ -83,6 +84,12 @@ nouveau_backlight_init(struct drm_device *dev)
return 0;
}
+static inline int
+nouveau_backlight_config(struc...
2016 Nov 13
1
[PATCH REBASED 2/2] Do not register interface if Apple GMUX detected
...m/nouveau/nouveau_backlight.c
+++ b/drivers/gpu/drm/nouveau/nouveau_backlight.c
@@ -30,6 +30,7 @@
* Register locations derived from NVClock by Roderick Colenbrander
*/
+#include <linux/apple-gmux.h>
#include <linux/backlight.h>
#include <linux/idr.h>
@@ -258,6 +259,11 @@ nouveau_backlight_init(struct drm_device *dev)
struct nvif_device *device = &drm->device;
struct drm_connector *connector;
+ if (apple_gmux_present()) {
+ NV_INFO(drm, "Apple GMUX detected: not registering Nouveau backlight interface");
+ return 0;
+ }
+
INIT_LIST_HEAD(&drm->bl_connector...
2009 Feb 18
1
[PATCH] Add in-kernel backlight control support
...nv_backlight", &dev->pdev->dev, dev,
+ &nv50_bl_ops);
+ if (IS_ERR(bd))
+ return PTR_ERR(bd);
+
+ dev_priv->backlight = bd;
+ bd->props.max_brightness = 1025;
+ bd->props.brightness = nv50_get_intensity(bd);
+ backlight_update_status(bd);
+ return 0;
+}
+
+int nouveau_backlight_init(struct drm_device *dev)
+{
+ struct drm_nouveau_private *dev_priv = dev->dev_private;
+
+ switch (dev_priv->card_type) {
+ case NV_40:
+ case NV_44:
+ return nouveau_nv40_backlight_init(dev);
+ break;
+ case NV_50:
+ return nouveau_nv50_backlight_init(dev);
+ break;
+ }
+ return 0;
+}
+
+...
2024 May 23
4
[PATCH 0/4] drm: enable -Wformat-truncation
Jani Nikula (4):
drm/amdgpu: fix -Wformat-truncation warning in
amdgpu_gfx_kiq_init_ring()
drm/nouveau: fix -Wformat-truncation warning in
nouveau_backlight_init()
drm/imx: fix -Wformat-truncation warning in imx_ldb_probe()
drm: enable -Wformat-truncation across the subsystem
drivers/gpu/drm/Makefile | 3 +--
drivers/gpu/drm/amd/amdgpu/amdgpu_gfx.c | 6 ++++--
drivers/gpu/drm/imx/ipuv3/imx-ldb.c | 6 +++++-
drivers/gpu/d...