siemens/nc_fpga: Rename freeze_mode to freeze_disable
The flag FF_FreezeDis marks if this feature is disabled. For a better readability rename freeze_mode to freeze_disable and invert the meaning of this information. Change-Id: I648b2392d2c8046965479511fde485a9cb934378 Signed-off-by: Werner Zeh <werner.zeh@siemens.com> Reviewed-on: https://review.coreboot.org/20432 Tested-by: build bot (Jenkins) <no-reply@coreboot.org> Reviewed-by: Paul Menzel <paulepanter@users.sourceforge.net> Reviewed-by: Stefan Reinauer <stefan.reinauer@coreboot.org>
This commit is contained in:
parent
5e21cd450c
commit
89a7b6bd24
|
@ -58,7 +58,7 @@ static void init_temp_mon (void *base_adr)
|
||||||
|
|
||||||
static void init_fan_ctrl (void *base_adr)
|
static void init_fan_ctrl (void *base_adr)
|
||||||
{
|
{
|
||||||
uint8_t mask = 0, freeze_mode = 0, fan_req = 0;
|
uint8_t mask = 0, freeze_disable = 0, fan_req = 0;
|
||||||
volatile fan_ctrl_t *ctrl = (fan_ctrl_t *)base_adr;
|
volatile fan_ctrl_t *ctrl = (fan_ctrl_t *)base_adr;
|
||||||
|
|
||||||
/* Program all needed fields of FAN controller. */
|
/* Program all needed fields of FAN controller. */
|
||||||
|
@ -76,10 +76,10 @@ static void init_fan_ctrl (void *base_adr)
|
||||||
FPGA_SET_PARAM(FANMaxSpeed, ctrl->fanmax);
|
FPGA_SET_PARAM(FANMaxSpeed, ctrl->fanmax);
|
||||||
/* Set freeze and FAN configuration. */
|
/* Set freeze and FAN configuration. */
|
||||||
if ((hwilib_get_field(FF_FanReq, &fan_req, 1) == 1) &&
|
if ((hwilib_get_field(FF_FanReq, &fan_req, 1) == 1) &&
|
||||||
(hwilib_get_field(FF_FreezeDis, &freeze_mode, 1) == 1)) {
|
(hwilib_get_field(FF_FreezeDis, &freeze_disable, 1) == 1)) {
|
||||||
if (!fan_req)
|
if (!fan_req)
|
||||||
mask = 1;
|
mask = 1;
|
||||||
else if (fan_req && freeze_mode)
|
else if (fan_req && !freeze_disable)
|
||||||
mask = 2;
|
mask = 2;
|
||||||
else
|
else
|
||||||
mask = 3;
|
mask = 3;
|
||||||
|
|
Loading…
Reference in New Issue