diff mbox series

hwmon: (npcm-750-pwm-fan): Change initial pwm target to 255

Message ID 20181008214925.86281-1-kunyi@google.com (mailing list archive)
State Accepted
Headers show
Series hwmon: (npcm-750-pwm-fan): Change initial pwm target to 255 | expand

Commit Message

Kun Yi Oct. 8, 2018, 9:49 p.m. UTC
Change initial PWM target to 255 to prevent overheating, for example
when BMC hangs in userspace or when userspace fan control application is
not implemented yet.

Signed-off-by: Kun Yi <kunyi@google.com>
---
 drivers/hwmon/npcm750-pwm-fan.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Guenter Roeck Oct. 10, 2018, 12:38 a.m. UTC | #1
On Mon, Oct 08, 2018 at 02:49:25PM -0700, Kun Yi wrote:
> Change initial PWM target to 255 to prevent overheating, for example
> when BMC hangs in userspace or when userspace fan control application is
> not implemented yet.
> 
> Signed-off-by: Kun Yi <kunyi@google.com>

Makes sense to me, and in line with other drivers. Applied to hwmon-next.

Thanks,
Guenter

> ---
>  drivers/hwmon/npcm750-pwm-fan.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/hwmon/npcm750-pwm-fan.c b/drivers/hwmon/npcm750-pwm-fan.c
> index 96634fd54e0b..c0fab54c0094 100644
> --- a/drivers/hwmon/npcm750-pwm-fan.c
> +++ b/drivers/hwmon/npcm750-pwm-fan.c
> @@ -52,7 +52,7 @@
>  
>  /* Define the Counter Register, value = 100 for match 100% */
>  #define NPCM7XX_PWM_COUNTER_DEFAULT_NUM		255
> -#define NPCM7XX_PWM_CMR_DEFAULT_NUM		127
> +#define NPCM7XX_PWM_CMR_DEFAULT_NUM		255
>  #define NPCM7XX_PWM_CMR_MAX			255
>  
>  /* default all PWM channels PRESCALE2 = 1 */
Kun Yi Oct. 10, 2018, 3:55 a.m. UTC | #2
Great, thanks!

On Tue, Oct 9, 2018 at 5:38 PM Guenter Roeck <linux@roeck-us.net> wrote:
>
> On Mon, Oct 08, 2018 at 02:49:25PM -0700, Kun Yi wrote:
> > Change initial PWM target to 255 to prevent overheating, for example
> > when BMC hangs in userspace or when userspace fan control application is
> > not implemented yet.
> >
> > Signed-off-by: Kun Yi <kunyi@google.com>
>
> Makes sense to me, and in line with other drivers. Applied to hwmon-next.
>
> Thanks,
> Guenter
>
> > ---
> >  drivers/hwmon/npcm750-pwm-fan.c | 2 +-
> >  1 file changed, 1 insertion(+), 1 deletion(-)
> >
> > diff --git a/drivers/hwmon/npcm750-pwm-fan.c b/drivers/hwmon/npcm750-pwm-fan.c
> > index 96634fd54e0b..c0fab54c0094 100644
> > --- a/drivers/hwmon/npcm750-pwm-fan.c
> > +++ b/drivers/hwmon/npcm750-pwm-fan.c
> > @@ -52,7 +52,7 @@
> >
> >  /* Define the Counter Register, value = 100 for match 100% */
> >  #define NPCM7XX_PWM_COUNTER_DEFAULT_NUM              255
> > -#define NPCM7XX_PWM_CMR_DEFAULT_NUM          127
> > +#define NPCM7XX_PWM_CMR_DEFAULT_NUM          255
> >  #define NPCM7XX_PWM_CMR_MAX                  255
> >
> >  /* default all PWM channels PRESCALE2 = 1 */
diff mbox series

Patch

diff --git a/drivers/hwmon/npcm750-pwm-fan.c b/drivers/hwmon/npcm750-pwm-fan.c
index 96634fd54e0b..c0fab54c0094 100644
--- a/drivers/hwmon/npcm750-pwm-fan.c
+++ b/drivers/hwmon/npcm750-pwm-fan.c
@@ -52,7 +52,7 @@ 
 
 /* Define the Counter Register, value = 100 for match 100% */
 #define NPCM7XX_PWM_COUNTER_DEFAULT_NUM		255
-#define NPCM7XX_PWM_CMR_DEFAULT_NUM		127
+#define NPCM7XX_PWM_CMR_DEFAULT_NUM		255
 #define NPCM7XX_PWM_CMR_MAX			255
 
 /* default all PWM channels PRESCALE2 = 1 */