board: gateworks: venice: gsc: fix typo
PATCH 1/5 board: gateworks: venice: gsc: fix typo
Fix typo in error message.
--- board/gateworks/venice/gsc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
board/gateworks/venice/gsc.c +1 -1
@@ -176,7 +176,7 @@ static int gsc_read_eeprom(int bus, int slave, int alen, struct venice_board_inf chksum += buf[i];if ((info->chksum[0 ] != chksum >>8 ) || (info->chksum[1 ] != (chksum &0xff ))) { -printf ("EEPROM: I2C%d@0x%02x: Invalid Model in EEPROM\n" , bus, slave); +printf ("EEPROM: I2C%d@0x%02x: Invalid Checksum\n" , bus, slave);print_hex_dump_bytes ("" ,DUMP_PREFIX_NONE , buf,sizeof (*info));memset (info,0 ,sizeof (*info));return -EINVAL ;
Signature · 1 line
2.17.1
PATCH 2/5 board: gateworks: venice: gsc: fix voltage offset
The voltage offset property is in microvolts so must be scaled accordingly.
--- board/gateworks/venice/gsc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
board/gateworks/venice/gsc.c +1 -1
@@ -298,7 +298,7 @@ int gsc_hwmon(void) }/* adjust by offset */ - val += offset; + val += (offset /1000 );printf ("%-8s: %d.%03dV\n" , label, val /1000 , val %1000 );break ;
Signature · 1 line
2.17.1
PATCH 2/5 board: gateworks: venice: gsc: fix voltage offset
Quoted 3 lines
The voltage offset property is in microvolts so must be scaled accordingly.
Signed-off-by Tim Harvey <[email protected]>
Applied to u-boot-imx, master, thanks !
Best regards,
Stefano Babic
Signature · 5 lines
===================================================================== DENX Software Engineering GmbH, Managing Director: Wolfgang Denk HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany Phone: +49-8142-66989-53 Fax: +49-8142-66989-80 Email: [email protected] =====================================================================
PATCH 3/5 board: gateworks: venice: display DTB used
In reply to Tim HarveyDisplay the DTB file used for U-Boot.
--- board/gateworks/venice/imx8mm_venice.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-)
board/gateworks/venice/imx8mm_venice.c +5 -1
@@ -42,12 +42,16 @@ int board_fit_config_name_match(const char *name) {int i =0 ;const char *dtb; +static char init;char buf[32 ];do { dtb =gsc_get_dtb_name (i++, buf,sizeof (buf)); -if (!strcmp (dtb, name)) +if (!strcmp (dtb, name)) { +if (!init++) +printf ("DTB : %s\n" , name);return 0 ; + } }while (dtb);return -1 ;
Signature · 1 line
2.17.1
PATCH 3/5 board: gateworks: venice: display DTB used
Quoted 2 lines
Display the DTB file used for U-Boot.
Signed-off-by Tim Harvey <[email protected]>
Applied to u-boot-imx, master, thanks !
Best regards,
Stefano Babic
Signature · 5 lines
===================================================================== DENX Software Engineering GmbH, Managing Director: Wolfgang Denk HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany Phone: +49-8142-66989-53 Fax: +49-8142-66989-80 Email: [email protected] =====================================================================
PATCH 4/5 board: gateworks: venice: add ftd_file env vars on boot
In reply to Tim HarveyThe ftd_file* vars can be used by bootscripts to look for appropriate dtb's
--- board/gateworks/venice/imx8mm_venice.c | 19 ++++++++++++++++--- 1 file changed, 16 insertions(+), 3 deletions(-)
board/gateworks/venice/imx8mm_venice.c +16 -3
@@ -105,13 +105,26 @@ int board_init(void)int board_late_init (void ) { -const char *ethmac; +const char *str;char env[32 ];int ret, i;u8 enetaddr[6 ]; +char fdt[64 ];led_default_state (); +/* Set fdt_file vars */ + i =0 ; +do { + str =gsc_get_dtb_name (i, fdt,sizeof (fdt)); +if (str) { +sprintf (env,"fdt_file%d" , i +1 ); +strcat (fdt,".dtb" ); +env_set (env, fdt); + } + i++; + }while (str); +/* Set mac addrs */ i =0 ; do {
@@ -119,8 +132,8 @@ int board_late_init(void)sprintf (env,"eth%daddr" , i); else sprintf(env, "ethaddr"); - ethmac =env_get (env); -if (!ethmac) { + str =env_get (env); +if (!str) { ret =gsc_getmac (i, enetaddr);if (!ret)eth_env_set_enetaddr (env, enetaddr);
Signature · 1 line
2.17.1
PATCH 4/5 board: gateworks: venice: add ftd_file env vars on boot
Quoted 3 lines
The ftd_file* vars can be used by bootscripts to look for appropriate dtb's
Signed-off-by Tim Harvey <[email protected]>
Applied to u-boot-imx, master, thanks !
Best regards,
Stefano Babic
Signature · 5 lines
===================================================================== DENX Software Engineering GmbH, Managing Director: Wolfgang Denk HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany Phone: +49-8142-66989-53 Fax: +49-8142-66989-80 Email: [email protected] =====================================================================
PATCH 5/5 board: gateworks: venice: remove forced enable of GSC thermal protection
In reply to Tim HarveyThe Gateworks System Controller thermal protection feature will disable the board primary power supply if the on-board temperature sensor reaches 86C. In many cases this could occur before the temperature critical components such as CPU, DRAM, eMMC, and power supplies have reached their max temperature.
Remove the forced re-enable of thermal protection so that users can knowingly disable it.
--- board/gateworks/venice/gsc.c | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-)
board/gateworks/venice/gsc.c +5 -3
@@ -221,9 +221,11 @@ static const char *gsc_get_rst_cause(struct udevice *dev)/* thermal protection */ if (!dm_i2c_read (dev,GSC_SC_THERM_PROTECT , ®,1 )) { - reg |=1 ; -dm_i2c_write (dev,GSC_SC_THERM_PROTECT , ®,1 ); -strcat (str," Thermal Protection Enabled" ); +strcat (str," Thermal Protection " ); +if (reg &BIT (0 )) +strcat (str,"Enabled" ); +else +strcat (str,"Disabled" ); }return str;
Signature · 1 line
2.17.1
PATCH 5/5 board: gateworks: venice: remove forced enable of GSC thermal protection
Quoted 8 lines
The Gateworks System Controller thermal protection feature will disable the board primary power supply if the on-board temperature sensor reaches 86C. In many cases this could occur before the temperature critical components such as CPU, DRAM, eMMC, and power supplies have reached their max temperature.
Remove the forced re-enable of thermal protection so that users can knowingly disable it.Signed-off-by Tim Harvey <[email protected]>
Applied to u-boot-imx, master, thanks !
Best regards,
Stefano Babic
Signature · 5 lines
===================================================================== DENX Software Engineering GmbH, Managing Director: Wolfgang Denk HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany Phone: +49-8142-66989-53 Fax: +49-8142-66989-80 Email: [email protected] =====================================================================
PATCH 1/5 board: gateworks: venice: gsc: fix typo
In reply to Tim HarveyQuoted 2 lines
Fix typo in error message.
Signed-off-by Tim Harvey <[email protected]>
Applied to u-boot-imx, master, thanks !
Best regards,
Stefano Babic
Signature · 5 lines
===================================================================== DENX Software Engineering GmbH, Managing Director: Wolfgang Denk HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany Phone: +49-8142-66989-53 Fax: +49-8142-66989-80 Email: [email protected] =====================================================================