All of lore.kernel.org
 help / color / mirror / Atom feed
* Fan control in nouveau driver with geforce 9600gt
@ 2012-12-13 10:02 Ozan Çağlayan
  2012-12-17  1:44 ` Martin Peres
  0 siblings, 1 reply; 12+ messages in thread
From: Ozan Çağlayan @ 2012-12-13 10:02 UTC (permalink / raw)
  To: dri-devel

Hi,

I have a geforce 9600gt (nv94) display adapter which has its fan
running at 100% speed. Yesterday I've compiled and booted with the
latest nouveau-2.6 tree. sensors from lm_sensors can correctly acquire
GPU temperature and PWM speed but as far as I understood setting the
speed is still not supported, am I right?

dmesg lists 3 performance levels with 100% fanspeed all of them.

Are there any other things that I can try? I saw a prlvl_wr module
parameter which enables setting performance level but it is indicated
that it is dangerous. Anyway, anything that I can try and help you?

Thanks.

-- 
Ozan Çağlayan
Research Assistant
Galatasaray University - Computer Engineering Dept.
http://www.ozancaglayan.com
_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/dri-devel

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: Fan control in nouveau driver with geforce 9600gt
  2012-12-13 10:02 Fan control in nouveau driver with geforce 9600gt Ozan Çağlayan
@ 2012-12-17  1:44 ` Martin Peres
  2012-12-17 12:35   ` Ozan Çağlayan
  0 siblings, 1 reply; 12+ messages in thread
From: Martin Peres @ 2012-12-17  1:44 UTC (permalink / raw)
  To: Ozan Çağlayan; +Cc: dri-devel


[-- Attachment #1.1: Type: text/plain, Size: 961 bytes --]

On 13/12/2012 11:02, Ozan Çağlayan wrote:
> Hi,
>
> I have a geforce 9600gt (nv94) display adapter which has its fan
> running at 100% speed. Yesterday I've compiled and booted with the
> latest nouveau-2.6 tree. sensors from lm_sensors can correctly acquire
> GPU temperature and PWM speed but as far as I understood setting the
> speed is still not supported, am I right?
>
> dmesg lists 3 performance levels with 100% fanspeed all of them.
>
> Are there any other things that I can try? I saw a prlvl_wr module
> parameter which enables setting performance level but it is indicated
> that it is dangerous. Anyway, anything that I can try and help you?
>
> Thanks.
>
Hi Ozan,

Please have a look at this documentation: 
http://cgit.freedesktop.org/nouveau/linux-2.6/tree/Documentation/thermal/nouveau_thermal
It will tell you how to use fan management on your card :)

Please report back! I am interested in your results!

Martin

[-- Attachment #1.2: Type: text/html, Size: 1561 bytes --]

[-- Attachment #2: Type: text/plain, Size: 159 bytes --]

_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/dri-devel

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: Fan control in nouveau driver with geforce 9600gt
  2012-12-17  1:44 ` Martin Peres
@ 2012-12-17 12:35   ` Ozan Çağlayan
  2012-12-17 22:48     ` Martin Peres
  0 siblings, 1 reply; 12+ messages in thread
From: Ozan Çağlayan @ 2012-12-17 12:35 UTC (permalink / raw)
  To: Martin Peres; +Cc: dri-devel

>
> Hi Ozan,
>
> Please have a look at this documentation:
> http://cgit.freedesktop.org/nouveau/linux-2.6/tree/Documentation/thermal/nouveau_thermal
> It will tell you how to use fan management on your card :)
>
> Please report back! I am interested in your results!
>
> Martin

Hey this is nice! I'll try it tonight when I'm back home.

Thanks :)

-- 
Ozan Çağlayan
Research Assistant
Galatasaray University - Computer Engineering Dept.
http://www.ozancaglayan.com
_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/dri-devel

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: Fan control in nouveau driver with geforce 9600gt
  2012-12-17 12:35   ` Ozan Çağlayan
@ 2012-12-17 22:48     ` Martin Peres
  2012-12-19 19:39       ` Ozan Çağlayan
  0 siblings, 1 reply; 12+ messages in thread
From: Martin Peres @ 2012-12-17 22:48 UTC (permalink / raw)
  To: Ozan Çağlayan; +Cc: dri-devel

[-- Attachment #1: Type: text/plain, Size: 530 bytes --]

On 17/12/2012 13:35, Ozan Çağlayan wrote:
>> Hi Ozan,
>>
>> Please have a look at this documentation:
>> http://cgit.freedesktop.org/nouveau/linux-2.6/tree/Documentation/thermal/nouveau_thermal
>> It will tell you how to use fan management on your card :)
>>
>> Please report back! I am interested in your results!
>>
>> Martin
> Hey this is nice! I'll try it tonight when I'm back home.
>
> Thanks :)
>
Here you go :)

I managed to reproduce the issue. Please test this patch!

Thanks for reporting,
Martin

[-- Attachment #2: 0001-drm-nouveau-fan-handle-the-cases-where-we-are-outsid.patch --]
[-- Type: text/x-patch, Size: 1153 bytes --]

>From 0227e8a93c697c325fb89b31b16aa5fe565c64d5 Mon Sep 17 00:00:00 2001
From: Martin Peres <martin.peres@labri.fr>
Date: Mon, 17 Dec 2012 23:46:22 +0100
Subject: [PATCH] drm/nouveau/fan: handle the cases where we are outside of the
 linear zone

Signed-off-by: Martin Peres <martin.peres@labri.fr>
---
 drivers/gpu/drm/nouveau/core/subdev/therm/base.c | 7 +++++++
 1 file changed, 7 insertions(+)

diff --git a/drivers/gpu/drm/nouveau/core/subdev/therm/base.c b/drivers/gpu/drm/nouveau/core/subdev/therm/base.c
index b35b4a2..25b7f6a 100644
--- a/drivers/gpu/drm/nouveau/core/subdev/therm/base.c
+++ b/drivers/gpu/drm/nouveau/core/subdev/therm/base.c
@@ -71,6 +71,13 @@ nouveau_therm_update_linear(struct nouveau_therm *therm)
 	u8  temp = therm->temp_get(therm);
 	u16 duty;
 
+	/* handle the non-linear part first */
+	if (temp < linear_min_temp)
+		return priv->fan->bios.min_duty;
+	else if (temp > linear_max_temp)
+		return priv->fan->bios.max_duty;
+
+	/* we are in the linear zone */
 	duty  = (temp - linear_min_temp);
 	duty *= (priv->fan->bios.max_duty - priv->fan->bios.min_duty);
 	duty /= (linear_max_temp - linear_min_temp);
-- 
1.8.0.2


[-- Attachment #3: Type: text/plain, Size: 159 bytes --]

_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/dri-devel

^ permalink raw reply related	[flat|nested] 12+ messages in thread

* Re: Fan control in nouveau driver with geforce 9600gt
  2012-12-17 22:48     ` Martin Peres
@ 2012-12-19 19:39       ` Ozan Çağlayan
  2012-12-20  0:27         ` Martin Peres
  0 siblings, 1 reply; 12+ messages in thread
From: Ozan Çağlayan @ 2012-12-19 19:39 UTC (permalink / raw)
  To: Martin Peres; +Cc: dri-devel

> Here you go :)
>
> I managed to reproduce the issue. Please test this patch!

Okay switching to automatic mode when pwm1 == 100 now gradually (in a
few seconds, it is not cut down to 35 suddenly) lowers it down to 35.
Switching to automatic mode while in manual mode doesn't make the pwm
increase until 100.

It seems okay I think.

(Another point,

Shouldn't we expect that the pwm is set to full power back again when
I disable thermal management? Currently when I echo 0 to pwm1_enable,
the fan power stays the same, e.g. 35 for example.)

You can add a <Tested-by> for me for a future reference.

Thanks!
Ozan Çağlayan
_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/dri-devel

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: Fan control in nouveau driver with geforce 9600gt
  2012-12-19 19:39       ` Ozan Çağlayan
@ 2012-12-20  0:27         ` Martin Peres
  2012-12-20 13:07           ` Ozan Çağlayan
  0 siblings, 1 reply; 12+ messages in thread
From: Martin Peres @ 2012-12-20  0:27 UTC (permalink / raw)
  To: Ozan Çağlayan; +Cc: dri-devel

On 19/12/2012 20:39, Ozan Çağlayan wrote:
>> Here you go :)
>>
>> I managed to reproduce the issue. Please test this patch!
> Okay switching to automatic mode when pwm1 == 100 now gradually (in a
> few seconds, it is not cut down to 35 suddenly) lowers it down to 35.
> Switching to automatic mode while in manual mode doesn't make the pwm
> increase until 100.
Yep, exactly what I meant to :)
> It seems okay I think.
>
> (Another point,
>
> Shouldn't we expect that the pwm is set to full power back again when
> I disable thermal management? Currently when I echo 0 to pwm1_enable,
> the fan power stays the same, e.g. 35 for example.)
So, we had some discussions within the nouveau community about
this and we decided that 0 would mean, no updates on the current status.

Anything against it?
>
> You can add a <Tested-by> for me for a future reference.
Sure, let me send a pull-request to the nouveau maintainer then :)
>
> Thanks!
> Ozan Çağlayan
Thanks for your testing and feedback!

Martin
_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/dri-devel

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: Fan control in nouveau driver with geforce 9600gt
  2012-12-20  0:27         ` Martin Peres
@ 2012-12-20 13:07           ` Ozan Çağlayan
  2012-12-20 18:33             ` Martin Peres
  0 siblings, 1 reply; 12+ messages in thread
From: Ozan Çağlayan @ 2012-12-20 13:07 UTC (permalink / raw)
  To: Martin Peres; +Cc: dri-devel

> So, we had some discussions within the nouveau community about
> this and we decided that 0 would mean, no updates on the current status.
>
> Anything against it?

So if I switch automatic mode on and then disable it then do some heavy GPU
processing, the fan power will stay at what it was in the low-load
state, am I wrong?
Isn't this dangerous?




-- 
Ozan Çağlayan
Research Assistant
Galatasaray University - Computer Engineering Dept.
http://www.ozancaglayan.com
_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/dri-devel

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: Fan control in nouveau driver with geforce 9600gt
  2012-12-20 13:07           ` Ozan Çağlayan
@ 2012-12-20 18:33             ` Martin Peres
  2012-12-21 12:04               ` Ozan Çağlayan
  0 siblings, 1 reply; 12+ messages in thread
From: Martin Peres @ 2012-12-20 18:33 UTC (permalink / raw)
  To: Ozan Çağlayan; +Cc: dri-devel

Le 20/12/2012 14:07, Ozan Çağlayan a écrit :
>> So, we had some discussions within the nouveau community about
>> this and we decided that 0 would mean, no updates on the current status.
>>
>> Anything against it?
> So if I switch automatic mode on and then disable it then do some heavy GPU
> processing, the fan power will stay at what it was in the low-load
> state, am I wrong?
> Isn't this dangerous?
Of course it is, but why would you disable automatic fan management?

You are supposed to activate it and let it activated at all time.

_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/dri-devel

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: Fan control in nouveau driver with geforce 9600gt
  2012-12-20 18:33             ` Martin Peres
@ 2012-12-21 12:04               ` Ozan Çağlayan
  2012-12-21 23:43                 ` Martin Peres
  0 siblings, 1 reply; 12+ messages in thread
From: Ozan Çağlayan @ 2012-12-21 12:04 UTC (permalink / raw)
  To: Martin Peres; +Cc: dri-devel

> Of course it is, but why would you disable automatic fan management?
>
> You are supposed to activate it and let it activated at all time.

It's not me but someone inexperienced playing with sysfs tunables for example :)



-- 
Ozan Çağlayan
Research Assistant
Galatasaray University - Computer Engineering Dept.
http://www.ozancaglayan.com
_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/dri-devel

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: Fan control in nouveau driver with geforce 9600gt
  2012-12-21 12:04               ` Ozan Çağlayan
@ 2012-12-21 23:43                 ` Martin Peres
  2013-01-07 16:25                   ` Ozan Çağlayan
  0 siblings, 1 reply; 12+ messages in thread
From: Martin Peres @ 2012-12-21 23:43 UTC (permalink / raw)
  To: Ozan Çağlayan; +Cc: dri-devel

On 21/12/2012 13:04, Ozan Çağlayan wrote:
>> Of course it is, but why would you disable automatic fan management?
>>
>> You are supposed to activate it and let it activated at all time.
> It's not me but someone inexperienced playing with sysfs tunables for example :)

Ah, sure. Well, there is documentation. And it isn't more dangerous than 
the current situation (always disabled).

We will be waiting a until one kernel is released before activating fan 
management by default.
_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/dri-devel

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: Fan control in nouveau driver with geforce 9600gt
  2012-12-21 23:43                 ` Martin Peres
@ 2013-01-07 16:25                   ` Ozan Çağlayan
  2013-01-14 14:12                     ` Martin Peres
  0 siblings, 1 reply; 12+ messages in thread
From: Ozan Çağlayan @ 2013-01-07 16:25 UTC (permalink / raw)
  To: Martin Peres; +Cc: dri-devel

> We will be waiting a until one kernel is released before activating fan
> management by default.

So these fan stuff will be merged into 3.9?



-- 
Ozan Çağlayan
Research Assistant
Galatasaray University - Computer Engineering Dept.
http://www.ozancaglayan.com
_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/dri-devel

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: Fan control in nouveau driver with geforce 9600gt
  2013-01-07 16:25                   ` Ozan Çağlayan
@ 2013-01-14 14:12                     ` Martin Peres
  0 siblings, 0 replies; 12+ messages in thread
From: Martin Peres @ 2013-01-14 14:12 UTC (permalink / raw)
  To: Ozan Çağlayan; +Cc: dri-devel

Le 07/01/2013 17:25, Ozan Çağlayan a écrit :
>> We will be waiting a until one kernel is released before activating fan
>> management by default.
> So these fan stuff will be merged into 3.9?
Yeah, quite likely :)

I see no reasons for us not to. So far, all bugs have been fixed.

_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/dri-devel

^ permalink raw reply	[flat|nested] 12+ messages in thread

end of thread, other threads:[~2013-01-14 14:13 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2012-12-13 10:02 Fan control in nouveau driver with geforce 9600gt Ozan Çağlayan
2012-12-17  1:44 ` Martin Peres
2012-12-17 12:35   ` Ozan Çağlayan
2012-12-17 22:48     ` Martin Peres
2012-12-19 19:39       ` Ozan Çağlayan
2012-12-20  0:27         ` Martin Peres
2012-12-20 13:07           ` Ozan Çağlayan
2012-12-20 18:33             ` Martin Peres
2012-12-21 12:04               ` Ozan Çağlayan
2012-12-21 23:43                 ` Martin Peres
2013-01-07 16:25                   ` Ozan Çağlayan
2013-01-14 14:12                     ` Martin Peres

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.