[PATCH 09/10] ARM: mvebu: clearfog: add Clearfog GTR support

Stefan Roese sr at denx.de
Mon Jan 13 08:29:41 CET 2020


On 25.11.19 11:30, Baruch Siach wrote:
> Select the serdes configuration table based on the platform identity
> read from EEPROM TLV data. Clearfog GTR needs a slightly different
> serdes configuration.
> 
> Signed-off-by: Baruch Siach <baruch at tkos.co.il>
> ---
>   board/solidrun/clearfog/clearfog.c | 10 ++++++++++
>   1 file changed, 10 insertions(+)
> 
> diff --git a/board/solidrun/clearfog/clearfog.c b/board/solidrun/clearfog/clearfog.c
> index 00c1306e9c80..70bea1e8dc65 100644
> --- a/board/solidrun/clearfog/clearfog.c
> +++ b/board/solidrun/clearfog/clearfog.c
> @@ -25,6 +25,8 @@ DECLARE_GLOBAL_DATA_PTR;
>    */
>   static char tlv_product_name[2][32];
>   
> +static void read_tlv_data(void);
> +
>   /*
>    * Those values and defines are taken from the Marvell U-Boot version
>    * "u-boot-2013.01-15t1-clearfog"
> @@ -48,6 +50,8 @@ static struct serdes_map board_serdes_map[] = {
>   
>   int hws_board_topology_load(struct serdes_map **serdes_map_array, u8 *count)
>   {
> +	read_tlv_data();
> +
>   	*serdes_map_array = board_serdes_map;
>   	*count = ARRAY_SIZE(board_serdes_map);
>   	return 0;
> @@ -188,6 +192,12 @@ static void read_tlv_data(void)
>   			continue;
>   		parse_tlv_data(eeprom_data, tlv_hdr, tlv_entry);
>   	}
> +
> +	if (sr_product_is("Clearfog GTR")) {
> +		board_serdes_map[0].serdes_type = PEX0;
> +		board_serdes_map[0].serdes_speed = SERDES_SPEED_5_GBPS;
> +		board_serdes_map[0].serdes_mode = PEX_ROOT_COMPLEX_X1;
> +	}
>   }
>   
>   struct mv_ddr_topology_map *mv_ddr_topology_map_get(void)
> 

Reviewed-by: Stefan Roese <sr at denx.de>

Thanks,
Stefan


More information about the U-Boot mailing list