Skip to contentSkip to conversation

FanPwm interface

DISCUSSION Derek Lin23 3 participants 4 messages Oct 30, 2019 – Nov 1, 2019

lore
Share & tools
lore
#0 lore raw

Hi team:

I have a question regarding of FanPwm interface on hwmon.
Does this interface get updated while PWM is changing in sysfs?
For example, if I setup a fan points to a PWM like below configuration, now, FanPwm interface does not get updated when I update PWM in sysfs, only my fan inputs (rpms) do.

Example:
LABEL_fan1 = "FAN0_Speed"
...
PWM_TARGET_fan1 = "1"

Is there a configuration or label which I can use so FanPwm interface would get updated when I change PWM in sysfs?

Thanks,

Derek

#1 lore raw
Quoted 17 lines · On Thu, Oct 31, 2019 at 3:27 PM Derek Lin23 <[email protected]> wrote:

Hi team:

I have a question regarding of FanPwm interface on hwmon.

Does this interface get updated while PWM is changing in sysfs?

For example, if I setup a fan points to a PWM like below configuration, now, FanPwm interface does not get updated when I update PWM in sysfs, only my fan inputs (rpms) do.

Example:

LABEL_fan1 = "FAN0_Speed"

Quoted 7 lines

…

PWM_TARGET_fan1 = "1"

Is there a configuration or label which I can use so FanPwm interface would get updated when I change PWM in sysfs?

Unless I'm mistaken, it's currently treated only as a Target -- so it's updated only via dbus calls to set it.

Quoted 12 lines

Thanks,

Derek

#2 lore raw
Quoted 21 lines · Patrick Venture
Quoted 19 lines · On Thu, Oct 31, 2019 at 3:27 PM Derek Lin23 <[email protected]> wrote:

Hi team:

I have a question regarding of FanPwm interface on hwmon.

Does this interface get updated while PWM is changing in sysfs?

For example, if I setup a fan points to a PWM like below configuration, now, FanPwm interface does not get updated when I update PWM in sysfs, only my fan inputs (rpms) do.

Example:

LABEL_fan1 = "FAN0_Speed"

…

Quoted 8 lines
Quoted 5 lines

PWM_TARGET_fan1 = "1"

Is there a configuration or label which I can use so FanPwm interface would get updated when I change PWM in sysfs?

Unless I'm mistaken, it's currently treated only as a Target -- so it's updated only via dbus calls to set it.

Exactly, it will not update if you change it directly in sysfs. This is OK in field because a regular user should access the BMC via Redfish/REST API/ipmi.

But for debugging purpose it does have some trouble that updating pwm in sysfs does not reflact on D-Bus.
So patches are welcome :)

#3 lore raw
Quoted 43 lines

-----Original Message-----
From: Lei YU <[email protected]>
Sent: Friday, November 1, 2019 10:58 AM
To: Patrick Venture <[email protected]>
Cc: Derek Lin23 <[email protected]>; OpenBMC Maillist <[email protected]>
Subject: [External] Re: FanPwm interface

Quoted 10 lines · Patrick Venture
Quoted 8 lines · On Thu, Oct 31, 2019 at 3:27 PM Derek Lin23 <[email protected]> wrote:

Hi team:

I have a question regarding of FanPwm interface on hwmon.

Does this interface get updated while PWM is changing in

sysfs?

Quoted 2 lines
Quoted 2 lines

For example, if I setup a fan points to a PWM like below

configuration, now, FanPwm interface does not get updated when I update PWM in sysfs, only my fan inputs (rpms) do.

Quoted 7 lines
Quoted 7 lines


          Example:

          LABEL_fan1 = "FAN0_Speed"
Quoted 7 lines
Quoted 7 lines

…

PWM_TARGET_fan1 = "1"

Is there a configuration or label which I can use so FanPwm

interface would get updated when I change PWM in sysfs?

Quoted 3 lines

Unless I'm mistaken, it's currently treated only as a Target -- so it's updated only via dbus calls to set it.

Quoted 7 lines

Exactly, it will not update if you change it directly in sysfs. This is OK in field because a regular user should access the BMC via Redfish/REST API/ipmi.

But for debugging purpose it does have some trouble that updating pwm in sysfs does not reflact on D-Bus.
So patches are welcome :)

Hi Patrick & Lei:

Thank you for your comments. Appreciate the help.

Derek