From: Nandor Han Date: Wed, 25 Apr 2018 14:56:59 +0000 (+0200) Subject: board: ge: bx50v3: unify two switch statements X-Git-Url: http://git.dujemihanovic.xyz/?a=commitdiff_plain;h=5ce9a1c84fdf6a4562a5072fcd95076e9cc333d6;p=u-boot.git board: ge: bx50v3: unify two switch statements Simplify process_vpd() by unifying the switch statements handling product specific configurations. Signed-off-by: Nandor Han Signed-off-by: Sebastian Reichel --- diff --git a/board/ge/bx50v3/bx50v3.c b/board/ge/bx50v3/bx50v3.c index 9d8d4780cf..be6a9fc470 100644 --- a/board/ge/bx50v3/bx50v3.c +++ b/board/ge/bx50v3/bx50v3.c @@ -593,23 +593,16 @@ static void process_vpd(struct vpd_cache *vpd) switch (vpd->product_id) { case VPD_PRODUCT_B450: env_set("confidx", "1"); + i210_index = 0; + fec_index = 1; break; case VPD_PRODUCT_B650: env_set("confidx", "2"); - break; - case VPD_PRODUCT_B850: - env_set("confidx", "3"); - break; - } - - switch (vpd->product_id) { - case VPD_PRODUCT_B450: - /* fall thru */ - case VPD_PRODUCT_B650: i210_index = 0; fec_index = 1; break; case VPD_PRODUCT_B850: + env_set("confidx", "3"); i210_index = 1; fec_index = 2; break;