summaryrefslogtreecommitdiff
path: root/src/southbridge
diff options
context:
space:
mode:
authorAngel Pons <th3fanbus@gmail.com>2021-04-19 13:21:41 +0200
committerPatrick Georgi <pgeorgi@google.com>2021-04-21 08:59:53 +0000
commit5daa412939bfb35cec7a876d68860fe0f4bb9515 (patch)
tree3bfad5197bd17158d9398792096ac43a6a9b86bc /src/southbridge
parent0a937754ee81ba7491d9687f9473096d8364e9f4 (diff)
downloadcoreboot-5daa412939bfb35cec7a876d68860fe0f4bb9515.tar.xz
sb/intel/bd82x6x: Use {get,set}_int_option
Change-Id: Icbfea8c516c42b45d689da92b7e426cb6d5112a5 Signed-off-by: Angel Pons <th3fanbus@gmail.com> Reviewed-on: https://review.coreboot.org/c/coreboot/+/52509 Tested-by: build bot (Jenkins) <no-reply@coreboot.org> Reviewed-by: Patrick Rudolph <siro@das-labor.org>
Diffstat (limited to 'src/southbridge')
-rw-r--r--src/southbridge/intel/bd82x6x/me.c7
-rw-r--r--src/southbridge/intel/bd82x6x/me_8.x.c7
2 files changed, 6 insertions, 8 deletions
diff --git a/src/southbridge/intel/bd82x6x/me.c b/src/southbridge/intel/bd82x6x/me.c
index cda2540d82..7ffef42140 100644
--- a/src/southbridge/intel/bd82x6x/me.c
+++ b/src/southbridge/intel/bd82x6x/me.c
@@ -178,15 +178,14 @@ static int mkhi_get_fwcaps(void)
static void intel_me_init(struct device *dev)
{
me_bios_path path = intel_me_path(dev);
- u8 me_state = 0, me_state_prev = 0;
bool need_reset = false;
union me_hfs hfs;
/* Do initial setup and determine the BIOS path */
printk(BIOS_NOTICE, "ME: BIOS path: %s\n", me_get_bios_path_string(path));
- get_option(&me_state, "me_state");
- get_option(&me_state_prev, "me_state_prev");
+ u8 me_state = get_int_option("me_state", 0);
+ u8 me_state_prev = get_int_option("me_state_prev", 0);
printk(BIOS_DEBUG, "ME: me_state=%u, me_state_prev=%u\n", me_state, me_state_prev);
@@ -269,7 +268,7 @@ static void intel_me_init(struct device *dev)
set the 'changed' bit here. */
if (me_state != CMOS_ME_STATE(me_state_prev) || need_reset) {
u8 new_state = me_state | CMOS_ME_STATE_CHANGED;
- set_option("me_state_prev", &new_state);
+ set_int_option("me_state_prev", new_state);
}
if (need_reset) {
diff --git a/src/southbridge/intel/bd82x6x/me_8.x.c b/src/southbridge/intel/bd82x6x/me_8.x.c
index abca881398..3c5fcd1796 100644
--- a/src/southbridge/intel/bd82x6x/me_8.x.c
+++ b/src/southbridge/intel/bd82x6x/me_8.x.c
@@ -176,15 +176,14 @@ static void intel_me_init(struct device *dev)
{
me_bios_path path = intel_me_path(dev);
me_bios_payload mbp_data;
- u8 me_state = 0, me_state_prev = 0;
bool need_reset = false;
union me_hfs hfs;
/* Do initial setup and determine the BIOS path */
printk(BIOS_NOTICE, "ME: BIOS path: %s\n", me_get_bios_path_string(path));
- get_option(&me_state, "me_state");
- get_option(&me_state_prev, "me_state_prev");
+ u8 me_state = get_int_option("me_state", 0);
+ u8 me_state_prev = get_int_option("me_state_prev", 0);
printk(BIOS_DEBUG, "ME: me_state=%u, me_state_prev=%u\n", me_state, me_state_prev);
@@ -268,7 +267,7 @@ static void intel_me_init(struct device *dev)
set the 'changed' bit here. */
if (me_state != CMOS_ME_STATE(me_state_prev) || need_reset) {
u8 new_state = me_state | CMOS_ME_STATE_CHANGED;
- set_option("me_state_prev", &new_state);
+ set_int_option("me_state_prev", new_state);
}
if (need_reset) {