Message ID | 20230309162212.2096573-4-trini@konsulko.com |
---|---|
State | Changes Requested |
Delegated to: | Tom Rini |
Headers | show |
Series | [1/6] arm: Correct cpu_reset function prototype on some platforms | expand |
Hi Tom, Maybe we should fix the header by changing it to u8? Because the eeprom only returns one byte for the DDRSUBIND value. Yours, Paul On Fri, 10 Mar 2023 at 00:22, Tom Rini <trini@konsulko.com> wrote: > We have a few places here we the function declarations do not match > their prototypes in another header, correct them. > > Signed-off-by: Tom Rini <trini@konsulko.com> > --- > Cc: "Ying-Chun Liu (PaulLiu)" <paul.liu@linaro.org> > --- > board/compulab/imx8mm-cl-iot-gate/eeprom_spl.c | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) > > diff --git a/board/compulab/imx8mm-cl-iot-gate/eeprom_spl.c > b/board/compulab/imx8mm-cl-iot-gate/eeprom_spl.c > index 90cc33a6e460..b8573aaac283 100644 > --- a/board/compulab/imx8mm-cl-iot-gate/eeprom_spl.c > +++ b/board/compulab/imx8mm-cl-iot-gate/eeprom_spl.c > @@ -101,7 +101,7 @@ u32 cl_eeprom_set_ddrinfo(u32 ddrinfo) > return board_ddrinfo; > }; > > -u8 cl_eeprom_get_subind(void) > +u32 cl_eeprom_get_subind(void) > { > if (cl_eeprom_read(BOARD_DDRSUBIND_OFFSET, (uchar > *)&board_ddrsubind, BOARD_DDRSUBIND_SIZE)) > return 0xff; > @@ -109,7 +109,7 @@ u8 cl_eeprom_get_subind(void) > return board_ddrsubind; > }; > > -u8 cl_eeprom_set_subind(u8 ddrsubind) > +u32 cl_eeprom_set_subind(u32 ddrsubind) > { > if (cl_eeprom_write(BOARD_DDRSUBIND_OFFSET, (uchar *)&ddrsubind, > BOARD_DDRSUBIND_SIZE)) > return 0xff; > -- > 2.34.1 > >
On Fri, Mar 10, 2023 at 03:34:14AM +0800, Paul Liu wrote: > Hi Tom, > > Maybe we should fix the header by changing it to u8? > Because the eeprom only returns one byte for the DDRSUBIND value. As the board maintainer, yes, please feel free to submit a new patch to better correct the issue. I hit this as part of enabling LTO for all of ARM, and it errored out here.
diff --git a/board/compulab/imx8mm-cl-iot-gate/eeprom_spl.c b/board/compulab/imx8mm-cl-iot-gate/eeprom_spl.c index 90cc33a6e460..b8573aaac283 100644 --- a/board/compulab/imx8mm-cl-iot-gate/eeprom_spl.c +++ b/board/compulab/imx8mm-cl-iot-gate/eeprom_spl.c @@ -101,7 +101,7 @@ u32 cl_eeprom_set_ddrinfo(u32 ddrinfo) return board_ddrinfo; }; -u8 cl_eeprom_get_subind(void) +u32 cl_eeprom_get_subind(void) { if (cl_eeprom_read(BOARD_DDRSUBIND_OFFSET, (uchar *)&board_ddrsubind, BOARD_DDRSUBIND_SIZE)) return 0xff; @@ -109,7 +109,7 @@ u8 cl_eeprom_get_subind(void) return board_ddrsubind; }; -u8 cl_eeprom_set_subind(u8 ddrsubind) +u32 cl_eeprom_set_subind(u32 ddrsubind) { if (cl_eeprom_write(BOARD_DDRSUBIND_OFFSET, (uchar *)&ddrsubind, BOARD_DDRSUBIND_SIZE)) return 0xff;
We have a few places here we the function declarations do not match their prototypes in another header, correct them. Signed-off-by: Tom Rini <trini@konsulko.com> --- Cc: "Ying-Chun Liu (PaulLiu)" <paul.liu@linaro.org> --- board/compulab/imx8mm-cl-iot-gate/eeprom_spl.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)