Displaying 15 results from an estimated 15 matches for "nouveau_led_suspend".
2016 Nov 08
2
[PATCH] drm/nouveau: fix LEDS_CLASS=m configuration
...d {
struct led_classdev led;
};
static inline struct nouveau_led *
nouveau_led(struct drm_device *dev)
{
return nouveau_drm(dev)->led;
}
/* nouveau_led.c */
-#if IS_ENABLED(CONFIG_LEDS_CLASS)
+#if IS_REACHABLE(CONFIG_LEDS_CLASS)
int nouveau_led_init(struct drm_device *dev);
void nouveau_led_suspend(struct drm_device *dev);
void nouveau_led_resume(struct drm_device *dev);
void nouveau_led_fini(struct drm_device *dev);
#else
static inline int nouveau_led_init(struct drm_device *dev) { return 0; };
static inline void nouveau_led_suspend(struct drm_device *dev) { };
static inline void nouv...
2016 Aug 22
10
[PATCH v2] drm/nouveau: add a LED driver for the NVIDIA logo
...nouveau_drm *drm = nouveau_drm(dev);
pm_runtime_get_sync(dev->dev);
+ nouveau_led_fini(dev);
nouveau_fbcon_fini(dev);
nouveau_accel_fini(drm);
nouveau_hwmon_fini(dev);
@@ -550,6 +553,8 @@ nouveau_do_suspend(struct drm_device *dev, bool runtime)
struct nouveau_cli *cli;
int ret;
+ nouveau_led_suspend(dev);
+
if (dev->mode_config.num_crtc) {
NV_INFO(drm, "suspending console...\n");
nouveau_fbcon_set_suspend(dev, 1);
@@ -638,6 +643,8 @@ nouveau_do_resume(struct drm_device *dev, bool runtime)
nouveau_fbcon_set_suspend(dev, 0);
}
+ nouveau_led_resume(dev);
+
return 0;...
2016 Sep 16
7
[PATCH 1/3] drm/nouveau/led: don't access led subdev if it wasn't initialized
...crash on suspend/resume.
---
drm/nouveau/nouveau_led.c | 7 ++++---
1 file changed, 4 insertions(+), 3 deletions(-)
diff --git a/drm/nouveau/nouveau_led.c b/drm/nouveau/nouveau_led.c
index 9eed5a6..5e28b5f 100644
--- a/drm/nouveau/nouveau_led.c
+++ b/drm/nouveau/nouveau_led.c
@@ -107,7 +107,8 @@ nouveau_led_suspend(struct drm_device *dev)
{
struct nouveau_drm *drm = nouveau_drm(dev);
- led_classdev_suspend(&drm->led->led);
+ if (drm->led)
+ led_classdev_suspend(&drm->led->led);
}
void
@@ -115,8 +116,8 @@ nouveau_led_resume(struct drm_device *dev)
{
struct nouveau_drm *drm =...
2016 Nov 08
0
[PATCH] drm/nouveau: fix LEDS_CLASS=m configuration
...ruct nouveau_led *
> nouveau_led(struct drm_device *dev)
> {
> return nouveau_drm(dev)->led;
> }
>
> /* nouveau_led.c */
> -#if IS_ENABLED(CONFIG_LEDS_CLASS)
> +#if IS_REACHABLE(CONFIG_LEDS_CLASS)
> int nouveau_led_init(struct drm_device *dev);
> void nouveau_led_suspend(struct drm_device *dev);
> void nouveau_led_resume(struct drm_device *dev);
> void nouveau_led_fini(struct drm_device *dev);
> #else
> static inline int nouveau_led_init(struct drm_device *dev) { return 0; };
> static inline void nouveau_led_suspend(struct drm_device *dev) { };...
2016 Aug 22
0
[PATCH v2] drm/nouveau: add a LED driver for the NVIDIA logo
...rm_unload(struct drm_device *dev)
pm_runtime_forbid(dev->dev);
}
+ nouveau_led_fini(dev);
nouveau_fbcon_fini(dev);
nouveau_accel_fini(drm);
nouveau_hwmon_fini(dev);
@@ -561,6 +564,8 @@ nouveau_do_suspend(struct drm_device *dev, bool runtime)
struct nouveau_cli *cli;
int ret;
+ nouveau_led_suspend(dev);
+
if (dev->mode_config.num_crtc) {
NV_INFO(drm, "suspending console...\n");
nouveau_fbcon_set_suspend(dev, 1);
@@ -649,6 +654,8 @@ nouveau_do_resume(struct drm_device *dev, bool runtime)
nouveau_fbcon_set_suspend(dev, 0);
}
+ nouveau_led_resume(dev);
+
return 0;...
2016 Nov 08
4
[PATCH] drm/nouveau: fix LEDS_CLASS=m configuration
The newly introduced LED handling for nouveau fails to link when the
driver is built-in but the LED subsystem is a loadable module:
drivers/gpu/drm/nouveau/nouveau.o: In function `nouveau_do_suspend':
tvnv17.c:(.text.nouveau_do_suspend+0x10): undefined reference to `nouveau_led_suspend'
drivers/gpu/drm/nouveau/nouveau.o: In function `nouveau_do_resume':
tvnv17.c:(.text.nouveau_do_resume+0xf0): undefined reference to `nouveau_led_resume'
drivers/gpu/drm/nouveau/nouveau.o: In function `nouveau_drm_unload':
tvnv17.c:(.text.nouveau_drm_unload+0x34): undefined referenc...
2016 May 03
0
[PATCH] drm/nouveau: add a LED driver for the NVIDIA logo
...nouveau_led_fini(dev);
> nouveau_fbcon_fini(dev);
> nouveau_accel_fini(drm);
> nouveau_hwmon_fini(dev);
> @@ -550,6 +553,8 @@ nouveau_do_suspend(struct drm_device *dev, bool runtime)
> struct nouveau_cli *cli;
> int ret;
>
> + nouveau_led_suspend(dev);
> +
> if (dev->mode_config.num_crtc) {
> NV_INFO(drm, "suspending console...\n");
> nouveau_fbcon_set_suspend(dev, 1);
> @@ -638,6 +643,8 @@ nouveau_do_resume(struct drm_device *dev, bool runtime)
> nouveau...
2016 Aug 23
0
[PATCH v2] drm/nouveau: add a LED driver for the NVIDIA logo
...nouveau_led_fini(dev);
> nouveau_fbcon_fini(dev);
> nouveau_accel_fini(drm);
> nouveau_hwmon_fini(dev);
> @@ -550,6 +553,8 @@ nouveau_do_suspend(struct drm_device *dev, bool runtime)
> struct nouveau_cli *cli;
> int ret;
>
> + nouveau_led_suspend(dev);
> +
> if (dev->mode_config.num_crtc) {
> NV_INFO(drm, "suspending console...\n");
> nouveau_fbcon_set_suspend(dev, 1);
> @@ -638,6 +643,8 @@ nouveau_do_resume(struct drm_device *dev, bool runtime)
> nouveau...
2016 May 07
0
[PATCH] drm/nouveau: add a LED driver for the NVIDIA logo
...nouveau_led_fini(dev);
> nouveau_fbcon_fini(dev);
> nouveau_accel_fini(drm);
> nouveau_hwmon_fini(dev);
> @@ -550,6 +553,8 @@ nouveau_do_suspend(struct drm_device *dev, bool runtime)
> struct nouveau_cli *cli;
> int ret;
>
> + nouveau_led_suspend(dev);
> +
> if (dev->mode_config.num_crtc) {
> NV_INFO(drm, "suspending console...\n");
> nouveau_fbcon_set_suspend(dev, 1);
> @@ -638,6 +643,8 @@ nouveau_do_resume(struct drm_device *dev, bool runtime)
> nouveau...
2016 Dec 07
3
[PATCH] nouveau/led: introduce CONFIG_DRM_NOUVEAU_LEDS
This fixes the auto-magic detection of LEDS_CLASS by fixing the case
where nouveau would be built-in and the LEDS_CLASS would be built as
as module.
Cc: <stable at vger.kernel.org> # 4.9.x-
Reported-by: Intel's 0-DAY
Signed-off-by: Martin Peres <martin.peres at free.fr>
---
drivers/gpu/drm/nouveau/Kbuild | 2 +-
drivers/gpu/drm/nouveau/Kconfig | 9 +++++++++
2 files changed, 10
2016 Nov 08
2
[PATCH] drm/nouveau: fix LEDS_CLASS=m configuration
On Tuesday, November 8, 2016 10:46:07 AM CET Ilia Mirkin wrote:
> > diff --git a/drivers/gpu/drm/nouveau/Kconfig b/drivers/gpu/drm/nouveau/Kconfig
> > index 78631fb61adf..715cd6f4dc31 100644
> > --- a/drivers/gpu/drm/nouveau/Kconfig
> > +++ b/drivers/gpu/drm/nouveau/Kconfig
> > @@ -46,6 +46,14 @@ config NOUVEAU_DEBUG
> > The paranoia and spam levels
2016 Dec 07
0
[PATCH] nouveau/led: prevent compiling the led-code if nouveau=y and leds=m
...00644
--- a/drivers/gpu/drm/nouveau/nouveau_led.h
+++ b/drivers/gpu/drm/nouveau/nouveau_led.h
@@ -42,7 +42,7 @@ nouveau_led(struct drm_device *dev)
}
/* nouveau_led.c */
-#if IS_ENABLED(CONFIG_LEDS_CLASS)
+#if IS_REACHABLE(CONFIG_LEDS_CLASS)
int nouveau_led_init(struct drm_device *dev);
void nouveau_led_suspend(struct drm_device *dev);
void nouveau_led_resume(struct drm_device *dev);
--
2.10.2
2016 Nov 08
0
[PATCH] drm/nouveau: fix LEDS_CLASS=m configuration
...te:
> The newly introduced LED handling for nouveau fails to link when the
> driver is built-in but the LED subsystem is a loadable module:
>
> drivers/gpu/drm/nouveau/nouveau.o: In function `nouveau_do_suspend':
> tvnv17.c:(.text.nouveau_do_suspend+0x10): undefined reference to `nouveau_led_suspend'
> drivers/gpu/drm/nouveau/nouveau.o: In function `nouveau_do_resume':
> tvnv17.c:(.text.nouveau_do_resume+0xf0): undefined reference to `nouveau_led_resume'
> drivers/gpu/drm/nouveau/nouveau.o: In function `nouveau_drm_unload':
> tvnv17.c:(.text.nouveau_drm_unload+0x34)...
2016 Aug 23
1
[PATCH v2] drm/nouveau: add a LED driver for the NVIDIA logo
...nouveau_fbcon_fini(dev);
>> nouveau_accel_fini(drm);
>> nouveau_hwmon_fini(dev);
>> @@ -550,6 +553,8 @@ nouveau_do_suspend(struct drm_device *dev, bool runtime)
>> struct nouveau_cli *cli;
>> int ret;
>>
>> + nouveau_led_suspend(dev);
>> +
>> if (dev->mode_config.num_crtc) {
>> NV_INFO(drm, "suspending console...\n");
>> nouveau_fbcon_set_suspend(dev, 1);
>> @@ -638,6 +643,8 @@ nouveau_do_resume(struct drm_device *dev, bool runtime)
>&...
2016 Aug 23
4
[PATCH v2] drm/nouveau: add a LED driver for the NVIDIA logo
On 23 August 2016 at 00:42, Martin Peres <martin.peres at free.fr> wrote:
> v2:
> - guard LED framework calls with ifdef CONFIG_LEDS_CLASS
>
IIRC kernel has the tendency of using static inlines in the headers
when CONFIG_foo is not set. Worth using that and removing the ifdef
from the source file ?
-Emil