Commit 1f0bb3940876c9b0be6f3c5fc320dde81ced4d97
1 parent
7f00c72e17
Exists in
smarc-rel_imx_4.1.15_2.0.0_ga
MLK-12800 imx: mx7dsabresd: support revC
Add revC board support. Signed-off-by: Peng Fan <peng.fan@nxp.com>
Showing 1 changed file with 13 additions and 4 deletions Side-by-side Diff
board/freescale/mx7dsabresd/mx7dsabresd.c
... | ... | @@ -272,6 +272,7 @@ |
272 | 272 | gpio_direction_output(IOX_STCP, 1); |
273 | 273 | }; |
274 | 274 | |
275 | +#define BOARD_REV_C 0x300 | |
275 | 276 | #define BOARD_REV_B 0x200 |
276 | 277 | #define BOARD_REV_A 0x100 |
277 | 278 | |
... | ... | @@ -289,6 +290,9 @@ |
289 | 290 | |
290 | 291 | if (reg != 0) { |
291 | 292 | switch (reg >> 8 & 0x0F) { |
293 | + case 0x3: | |
294 | + ret = BOARD_REV_C; | |
295 | + break; | |
292 | 296 | case 0x02: |
293 | 297 | ret = BOARD_REV_B; |
294 | 298 | break; |
295 | 299 | |
... | ... | @@ -301,8 +305,10 @@ |
301 | 305 | /* If the gp1 fuse is not burn, we have to use TO rev for the board rev */ |
302 | 306 | if (is_soc_rev(CHIP_REV_1_0)) |
303 | 307 | ret = BOARD_REV_A; |
304 | - else | |
308 | + else if (is_soc_rev(CHIP_REV_1_1)) | |
305 | 309 | ret = BOARD_REV_B; |
310 | + else | |
311 | + ret = BOARD_REV_C; | |
306 | 312 | } |
307 | 313 | |
308 | 314 | return ret; |
... | ... | @@ -562,7 +568,7 @@ |
562 | 568 | if (0 == CONFIG_FEC_ENET_DEV) { |
563 | 569 | imx_iomux_v3_setup_multiple_pads(fec1_pads, ARRAY_SIZE(fec1_pads)); |
564 | 570 | } else { |
565 | - if (mx7sabre_rev() == BOARD_REV_B) { | |
571 | + if (mx7sabre_rev() >= BOARD_REV_B) { | |
566 | 572 | /* On RevB, GPIO1_IO04 is used for ENET2 EN, |
567 | 573 | * so set its output to low to enable ENET2 signals |
568 | 574 | */ |
... | ... | @@ -873,7 +879,7 @@ |
873 | 879 | imx_iomux_v3_setup_multiple_pads(usb_otg1_pads, |
874 | 880 | ARRAY_SIZE(usb_otg1_pads)); |
875 | 881 | |
876 | - if (mx7sabre_rev() == BOARD_REV_B) | |
882 | + if (mx7sabre_rev() >= BOARD_REV_B) | |
877 | 883 | imx_iomux_v3_setup_multiple_pads(usb_otg2_revB_pads, |
878 | 884 | ARRAY_SIZE(usb_otg2_revB_pads)); |
879 | 885 | else |
... | ... | @@ -928,7 +934,7 @@ |
928 | 934 | #endif |
929 | 935 | |
930 | 936 | #ifdef CONFIG_MXC_EPDC |
931 | - if (mx7sabre_rev() == BOARD_REV_B) { | |
937 | + if (mx7sabre_rev() >= BOARD_REV_B) { | |
932 | 938 | /* On RevB, GPIO1_IO04 is used for ENET2 EN, |
933 | 939 | * so set its output to high to isolate the ENET2 signals for EPDC |
934 | 940 | */ |
... | ... | @@ -1026,6 +1032,9 @@ |
1026 | 1032 | char *revname; |
1027 | 1033 | |
1028 | 1034 | switch (rev) { |
1035 | + case BOARD_REV_C: | |
1036 | + revname = "C"; | |
1037 | + break; | |
1029 | 1038 | case BOARD_REV_B: |
1030 | 1039 | revname = "B"; |
1031 | 1040 | break; |