Change in coreboot[master]: drivers/pc80/mc146818rtc: Remove read_option_lowlevel()
Kyösti Mälkki has uploaded this change for review. ( https://review.coreboot.org/c/coreboot/+/37954 ) Change subject: drivers/pc80/mc146818rtc: Remove read_option_lowlevel() ...................................................................... drivers/pc80/mc146818rtc: Remove read_option_lowlevel() This was a workaround for romcc. Change-Id: I34f41390afbd88f3ace7003fd18c2edd56712a67 Signed-off-by: Kyösti Mälkki <kyosti.malkki@gmail.com> --- M src/drivers/pc80/rtc/mc146818rtc.c M src/include/pc80/mc146818rtc.h 2 files changed, 0 insertions(+), 17 deletions(-) git pull ssh://review.coreboot.org:29418/coreboot refs/changes/54/37954/1 diff --git a/src/drivers/pc80/rtc/mc146818rtc.c b/src/drivers/pc80/rtc/mc146818rtc.c index d3efdec..2029b1e 100644 --- a/src/drivers/pc80/rtc/mc146818rtc.c +++ b/src/drivers/pc80/rtc/mc146818rtc.c @@ -345,18 +345,6 @@ return CB_SUCCESS; } -unsigned int read_option_lowlevel(unsigned int start, unsigned int size, - unsigned int def) -{ - printk(BIOS_NOTICE, "NOTICE: read_option() used to access CMOS " - "from non-ROMCC code, please use get_option() instead.\n"); - if (CONFIG(USE_OPTION_TABLE)) { - const unsigned char byte = cmos_read(start / 8); - return (byte >> (start & 7U)) & ((1U << size) - 1U); - } - return def; -} - enum cb_err set_option(const char *name, void *value) { struct cmos_option_table *ct; diff --git a/src/include/pc80/mc146818rtc.h b/src/include/pc80/mc146818rtc.h index afa4d97..61fa211 100644 --- a/src/include/pc80/mc146818rtc.h +++ b/src/include/pc80/mc146818rtc.h @@ -185,14 +185,9 @@ enum cb_err set_option(const char *name, void *val); enum cb_err get_option(void *dest, const char *name); -unsigned int read_option_lowlevel(unsigned int start, unsigned int size, - unsigned int def); int do_normal_boot(void); -#define read_option(name, default) read_option_lowlevel(CMOS_VSTART_ ##name, \ - CMOS_VLEN_ ##name, (default)) - #if CONFIG(CMOS_POST) #if CONFIG(USE_OPTION_TABLE) # include "option_table.h" -- To view, visit https://review.coreboot.org/c/coreboot/+/37954 To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings Gerrit-Project: coreboot Gerrit-Branch: master Gerrit-Change-Id: I34f41390afbd88f3ace7003fd18c2edd56712a67 Gerrit-Change-Number: 37954 Gerrit-PatchSet: 1 Gerrit-Owner: Kyösti Mälkki <kyosti.malkki@gmail.com> Gerrit-MessageType: newchange
HAOUAS Elyes has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/37954 ) Change subject: drivers/pc80/mc146818rtc: Remove read_option_lowlevel() ...................................................................... Patch Set 1: Code-Review+2 -- To view, visit https://review.coreboot.org/c/coreboot/+/37954 To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings Gerrit-Project: coreboot Gerrit-Branch: master Gerrit-Change-Id: I34f41390afbd88f3ace7003fd18c2edd56712a67 Gerrit-Change-Number: 37954 Gerrit-PatchSet: 1 Gerrit-Owner: Kyösti Mälkki <kyosti.malkki@gmail.com> Gerrit-Reviewer: HAOUAS Elyes <ehaouas@noos.fr> Gerrit-Comment-Date: Fri, 27 Dec 2019 18:45:29 +0000 Gerrit-HasComments: No Gerrit-Has-Labels: Yes Gerrit-MessageType: comment
Angel Pons has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/37954 ) Change subject: drivers/pc80/mc146818rtc: Remove read_option_lowlevel() ...................................................................... Patch Set 2: Code-Review+2 -- To view, visit https://review.coreboot.org/c/coreboot/+/37954 To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings Gerrit-Project: coreboot Gerrit-Branch: master Gerrit-Change-Id: I34f41390afbd88f3ace7003fd18c2edd56712a67 Gerrit-Change-Number: 37954 Gerrit-PatchSet: 2 Gerrit-Owner: Kyösti Mälkki <kyosti.malkki@gmail.com> Gerrit-Reviewer: Angel Pons <th3fanbus@gmail.com> Gerrit-Reviewer: HAOUAS Elyes <ehaouas@noos.fr> Gerrit-Reviewer: Kyösti Mälkki <kyosti.malkki@gmail.com> Gerrit-Reviewer: Nico Huber <nico.h@gmx.de> Gerrit-Reviewer: Patrick Georgi <pgeorgi@google.com> Gerrit-Reviewer: build bot (Jenkins) <no-reply@coreboot.org> Gerrit-CC: Paul Menzel <paulepanter@users.sourceforge.net> Gerrit-Comment-Date: Tue, 31 Dec 2019 21:15:30 +0000 Gerrit-HasComments: No Gerrit-Has-Labels: Yes Gerrit-MessageType: comment
Paul Menzel has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/37954 ) Change subject: drivers/pc80/mc146818rtc: Remove read_option_lowlevel() ...................................................................... Patch Set 2: Code-Review+1 -- To view, visit https://review.coreboot.org/c/coreboot/+/37954 To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings Gerrit-Project: coreboot Gerrit-Branch: master Gerrit-Change-Id: I34f41390afbd88f3ace7003fd18c2edd56712a67 Gerrit-Change-Number: 37954 Gerrit-PatchSet: 2 Gerrit-Owner: Kyösti Mälkki <kyosti.malkki@gmail.com> Gerrit-Reviewer: Angel Pons <th3fanbus@gmail.com> Gerrit-Reviewer: HAOUAS Elyes <ehaouas@noos.fr> Gerrit-Reviewer: Kyösti Mälkki <kyosti.malkki@gmail.com> Gerrit-Reviewer: Nico Huber <nico.h@gmx.de> Gerrit-Reviewer: Patrick Georgi <pgeorgi@google.com> Gerrit-Reviewer: Paul Menzel <paulepanter@users.sourceforge.net> Gerrit-Reviewer: build bot (Jenkins) <no-reply@coreboot.org> Gerrit-Comment-Date: Thu, 02 Jan 2020 11:54:09 +0000 Gerrit-HasComments: No Gerrit-Has-Labels: Yes Gerrit-MessageType: comment
Nico Huber has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/37954 ) Change subject: drivers/pc80/mc146818rtc: Remove read_option_lowlevel() ...................................................................... Patch Set 2: Code-Review+2 -- To view, visit https://review.coreboot.org/c/coreboot/+/37954 To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings Gerrit-Project: coreboot Gerrit-Branch: master Gerrit-Change-Id: I34f41390afbd88f3ace7003fd18c2edd56712a67 Gerrit-Change-Number: 37954 Gerrit-PatchSet: 2 Gerrit-Owner: Kyösti Mälkki <kyosti.malkki@gmail.com> Gerrit-Reviewer: Angel Pons <th3fanbus@gmail.com> Gerrit-Reviewer: HAOUAS Elyes <ehaouas@noos.fr> Gerrit-Reviewer: Kyösti Mälkki <kyosti.malkki@gmail.com> Gerrit-Reviewer: Nico Huber <nico.h@gmx.de> Gerrit-Reviewer: Patrick Georgi <pgeorgi@google.com> Gerrit-Reviewer: Paul Menzel <paulepanter@users.sourceforge.net> Gerrit-Reviewer: build bot (Jenkins) <no-reply@coreboot.org> Gerrit-Comment-Date: Thu, 02 Jan 2020 12:33:24 +0000 Gerrit-HasComments: No Gerrit-Has-Labels: Yes Gerrit-MessageType: comment
Kyösti Mälkki has submitted this change. ( https://review.coreboot.org/c/coreboot/+/37954 ) Change subject: drivers/pc80/mc146818rtc: Remove read_option_lowlevel() ...................................................................... drivers/pc80/mc146818rtc: Remove read_option_lowlevel() This was a workaround for romcc. Change-Id: I34f41390afbd88f3ace7003fd18c2edd56712a67 Signed-off-by: Kyösti Mälkki <kyosti.malkki@gmail.com> Reviewed-on: https://review.coreboot.org/c/coreboot/+/37954 Reviewed-by: Angel Pons <th3fanbus@gmail.com> Reviewed-by: Paul Menzel <paulepanter@users.sourceforge.net> Reviewed-by: Nico Huber <nico.h@gmx.de> Reviewed-by: HAOUAS Elyes <ehaouas@noos.fr> Tested-by: build bot (Jenkins) <no-reply@coreboot.org> --- M src/drivers/pc80/rtc/mc146818rtc.c M src/include/pc80/mc146818rtc.h 2 files changed, 0 insertions(+), 17 deletions(-) Approvals: build bot (Jenkins): Verified Nico Huber: Looks good to me, approved Paul Menzel: Looks good to me, but someone else must approve HAOUAS Elyes: Looks good to me, approved Angel Pons: Looks good to me, approved diff --git a/src/drivers/pc80/rtc/mc146818rtc.c b/src/drivers/pc80/rtc/mc146818rtc.c index d3efdec..2029b1e 100644 --- a/src/drivers/pc80/rtc/mc146818rtc.c +++ b/src/drivers/pc80/rtc/mc146818rtc.c @@ -345,18 +345,6 @@ return CB_SUCCESS; } -unsigned int read_option_lowlevel(unsigned int start, unsigned int size, - unsigned int def) -{ - printk(BIOS_NOTICE, "NOTICE: read_option() used to access CMOS " - "from non-ROMCC code, please use get_option() instead.\n"); - if (CONFIG(USE_OPTION_TABLE)) { - const unsigned char byte = cmos_read(start / 8); - return (byte >> (start & 7U)) & ((1U << size) - 1U); - } - return def; -} - enum cb_err set_option(const char *name, void *value) { struct cmos_option_table *ct; diff --git a/src/include/pc80/mc146818rtc.h b/src/include/pc80/mc146818rtc.h index ecfa76d..aa50773 100644 --- a/src/include/pc80/mc146818rtc.h +++ b/src/include/pc80/mc146818rtc.h @@ -185,14 +185,9 @@ enum cb_err set_option(const char *name, void *val); enum cb_err get_option(void *dest, const char *name); -unsigned int read_option_lowlevel(unsigned int start, unsigned int size, - unsigned int def); int do_normal_boot(void); -#define read_option(name, default) read_option_lowlevel(CMOS_VSTART_ ##name, \ - CMOS_VLEN_ ##name, (default)) - #if CONFIG(CMOS_POST) #if CONFIG(USE_OPTION_TABLE) # include "option_table.h" -- To view, visit https://review.coreboot.org/c/coreboot/+/37954 To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings Gerrit-Project: coreboot Gerrit-Branch: master Gerrit-Change-Id: I34f41390afbd88f3ace7003fd18c2edd56712a67 Gerrit-Change-Number: 37954 Gerrit-PatchSet: 3 Gerrit-Owner: Kyösti Mälkki <kyosti.malkki@gmail.com> Gerrit-Reviewer: Angel Pons <th3fanbus@gmail.com> Gerrit-Reviewer: HAOUAS Elyes <ehaouas@noos.fr> Gerrit-Reviewer: Kyösti Mälkki <kyosti.malkki@gmail.com> Gerrit-Reviewer: Nico Huber <nico.h@gmx.de> Gerrit-Reviewer: Patrick Georgi <pgeorgi@google.com> Gerrit-Reviewer: Paul Menzel <paulepanter@users.sourceforge.net> Gerrit-Reviewer: build bot (Jenkins) <no-reply@coreboot.org> Gerrit-MessageType: merged
participants (5)
-
Angel Pons (Code Review) -
HAOUAS Elyes (Code Review) -
Kyösti Mälkki (Code Review) -
Nico Huber (Code Review) -
Paul Menzel (Code Review)