Skip to content

Commit

Permalink
[accton/as4630-54pe] Fix ypeb-1200am psu_fan dir issue (#4626)
Browse files Browse the repository at this point in the history
3y Power YPEB-1200am PSU doens't support read fan_dir from pmbus register

Check with vendor this PUS type only support F2B fan direction. So add to show "F2B"
when red psu_fan_dir sysfs.
  • Loading branch information
jostar-yang authored May 26, 2020
1 parent bf54f48 commit f532fb9
Showing 1 changed file with 5 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -355,6 +355,11 @@ static ssize_t show_ascii(struct device *dev, struct device_attribute *da,

switch (attr->index) {
case PSU_FAN_DIRECTION: /* psu_fan_dir */
if (data->chip==YPEB1200AM)
{
memcpy(data->fan_dir, "F2B", 3);
data->fan_dir[3]='\0';
}
ptr = data->fan_dir;
break;
case PSU_MFR_ID: /* psu_mfr_id */
Expand Down

0 comments on commit f532fb9

Please sign in to comment.