summaryrefslogtreecommitdiff
path: root/src/drivers/siemens/nc_fpga
diff options
context:
space:
mode:
authorWerner Zeh <werner.zeh@siemens.com>2017-07-27 13:48:18 +0200
committerMartin Roth <martinroth@google.com>2017-07-28 16:16:42 +0000
commitc38ab85cd44457a6dd522a81d6c14b075796c1b0 (patch)
treebcfc79bb3464b7e9a4ef9844ec945b65c0ff7f32 /src/drivers/siemens/nc_fpga
parent909536a666d9f42b4e27e8ce93251d85ef9fcb74 (diff)
downloadcoreboot-c38ab85cd44457a6dd522a81d6c14b075796c1b0.tar.xz
siemens/nc_fpga: Add support for lowest FAN speed to FAN controller
The functionality of the FAN controller is extended to provide a lowest startup speed of the FAN. Add the parameter "fanmin" to the fan_ctrl_t structure and initialize the value. Change-Id: Ib2e093ed6f5fc29bbea879779eb4777eb371b937 Signed-off-by: Werner Zeh <werner.zeh@siemens.com> Reviewed-on: https://review.coreboot.org/20789 Tested-by: build bot (Jenkins) <no-reply@coreboot.org> Reviewed-by: Mario Scheithauer <mario.scheithauer@siemens.com> Reviewed-by: Paul Menzel <paulepanter@users.sourceforge.net>
Diffstat (limited to 'src/drivers/siemens/nc_fpga')
-rw-r--r--src/drivers/siemens/nc_fpga/nc_fpga.c3
-rw-r--r--src/drivers/siemens/nc_fpga/nc_fpga.h5
2 files changed, 5 insertions, 3 deletions
diff --git a/src/drivers/siemens/nc_fpga/nc_fpga.c b/src/drivers/siemens/nc_fpga/nc_fpga.c
index ab44e2387b..61d9e0841e 100644
--- a/src/drivers/siemens/nc_fpga/nc_fpga.c
+++ b/src/drivers/siemens/nc_fpga/nc_fpga.c
@@ -1,7 +1,7 @@
/*
* This file is part of the coreboot project.
*
- * Copyright (C) 2016 Siemens AG.
+ * Copyright (C) 2016-2017 Siemens AG.
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
@@ -73,6 +73,7 @@ static void init_fan_ctrl (void *base_adr)
FPGA_SET_PARAM(FANKi, ctrl->ki);
FPGA_SET_PARAM(FANKd, ctrl->kd);
FPGA_SET_PARAM(FANMaxSpeed, ctrl->fanmax);
+ FPGA_SET_PARAM(FANStartSpeed, ctrl->fanmin);
/* Set freeze and FAN configuration. */
if ((hwilib_get_field(FF_FanReq, &fan_req, 1) == 1) &&
(hwilib_get_field(FF_FreezeDis, &freeze_disable, 1) == 1)) {
diff --git a/src/drivers/siemens/nc_fpga/nc_fpga.h b/src/drivers/siemens/nc_fpga/nc_fpga.h
index 2cb020012b..7bf087b69a 100644
--- a/src/drivers/siemens/nc_fpga/nc_fpga.h
+++ b/src/drivers/siemens/nc_fpga/nc_fpga.h
@@ -1,7 +1,7 @@
/*
* This file is part of the coreboot project.
*
- * Copyright (C) 2016 Siemens AG.
+ * Copyright (C) 2016-2017 Siemens AG.
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
@@ -60,7 +60,8 @@ typedef struct {
uint16_t kp;
uint16_t ki;
uint16_t kd;
- uint16_t res8[2];
+ uint16_t fanmin;
+ uint16_t res8;
uint16_t fanmax;
uint16_t hystval;
uint16_t hystthreshold;