Tom Rini | 10e4779 | 2018-05-06 17:58:06 -0400 | [diff] [blame] | 1 | /* SPDX-License-Identifier: GPL-2.0+ */ |
Haiying Wang | bd25537 | 2009-03-27 17:02:45 -0400 | [diff] [blame] | 2 | /* |
Kumar Gala | 6a6d948 | 2009-07-28 21:49:52 -0500 | [diff] [blame] | 3 | * Copyright (C) 2009 Freescale Semiconductor, Inc. |
Haiying Wang | bd25537 | 2009-03-27 17:02:45 -0400 | [diff] [blame] | 4 | */ |
| 5 | |
| 6 | #ifndef __BCSR_H_ |
| 7 | #define __BCSR_H_ |
| 8 | |
| 9 | #include <common.h> |
| 10 | |
| 11 | /* BCSR Bit definitions*/ |
| 12 | /****************************************/ |
| 13 | /* BCSR defines */ |
| 14 | /****************************************/ |
| 15 | #define BCSR6_UPC1_EN 0x80 |
| 16 | #define BCSR6_UPC1_POS_EN 0x40 |
| 17 | #define BCSR6_UPC1_ADDR_EN 0x20 |
| 18 | #define BCSR6_UPC1_DEV2 0x10 |
Anton Vorontsov | da22594 | 2009-10-15 17:47:06 +0400 | [diff] [blame] | 19 | #define BCSR6_SD_CARD_1BIT 0x08 |
| 20 | #define BCSR6_SD_CARD_4BITS 0x04 |
Haiying Wang | bd25537 | 2009-03-27 17:02:45 -0400 | [diff] [blame] | 21 | #define BCSR6_TDM2G_EN 0x02 |
| 22 | #define BCSR6_UCC7_RMII_EN 0x01 |
| 23 | |
| 24 | #define BCSR7_UCC1_GETH_EN 0x80 |
| 25 | #define BCSR7_UCC1_RGMII_EN 0x40 |
| 26 | #define BCSR7_UCC1_RTBI_EN 0x20 |
| 27 | #define BCSR7_GETHRST_MRVL 0x04 |
| 28 | #define BCSR7_BRD_WRT_PROTECT 0x02 |
| 29 | |
| 30 | #define BCSR8_UCC2_GETH_EN 0x80 |
| 31 | #define BCSR8_UCC2_RGMII_EN 0x40 |
| 32 | #define BCSR8_UCC2_RTBI_EN 0x20 |
| 33 | #define BCSR8_UEM_MARVEL_RESET 0x02 |
| 34 | |
| 35 | #define BCSR9_UCC3_GETH_EN 0x80 |
| 36 | #define BCSR9_UCC3_RGMII_EN 0x40 |
| 37 | #define BCSR9_UCC3_RTBI_EN 0x20 |
| 38 | #define BCSR9_UCC3_RMII_EN 0x10 |
| 39 | #define BCSR9_UCC3_UEM_MICREL 0x01 |
| 40 | |
| 41 | #define BCSR10_UCC4_GETH_EN 0x80 |
| 42 | #define BCSR10_UCC4_RGMII_EN 0x40 |
| 43 | #define BCSR10_UCC4_RTBI_EN 0x20 |
| 44 | |
| 45 | #define BCSR11_LED0 0x40 |
| 46 | #define BCSR11_LED1 0x20 |
| 47 | #define BCSR11_LED2 0x10 |
| 48 | |
| 49 | #define BCSR12_UCC6_RMII_EN 0x20 |
| 50 | #define BCSR12_UCC8_RMII_EN 0x20 |
| 51 | |
| 52 | #define BCSR15_SMII6_DIS 0x08 |
| 53 | #define BCSR15_SMII8_DIS 0x04 |
Anton Vorontsov | 0a154a0 | 2009-10-15 17:47:13 +0400 | [diff] [blame] | 54 | #define BCSR15_QEUART_EN 0x01 |
Haiying Wang | bd25537 | 2009-03-27 17:02:45 -0400 | [diff] [blame] | 55 | |
| 56 | #define BCSR16_UPC1_DEV2 0x02 |
| 57 | |
Anton Vorontsov | d8e7582 | 2009-10-15 17:47:16 +0400 | [diff] [blame] | 58 | #define BCSR17_nUSBEN 0x80 |
| 59 | #define BCSR17_nUSBLOWSPD 0x40 |
| 60 | #define BCSR17_USBVCC 0x20 |
| 61 | #define BCSR17_USBMODE 0x10 |
Haiying Wang | bd25537 | 2009-03-27 17:02:45 -0400 | [diff] [blame] | 62 | #define BCSR17_FLASH_nWP 0x01 |
| 63 | |
| 64 | /*BCSR Utils functions*/ |
| 65 | |
| 66 | void enable_8569mds_flash_write(void); |
| 67 | void disable_8569mds_flash_write(void); |
Haiying Wang | bc759ee | 2009-05-20 12:30:37 -0400 | [diff] [blame] | 68 | void enable_8569mds_qe_uec(void); |
Haiying Wang | bd25537 | 2009-03-27 17:02:45 -0400 | [diff] [blame] | 69 | void disable_8569mds_brd_eeprom_write_protect(void); |
| 70 | |
| 71 | #endif /* __BCSR_H_ */ |