+/* SPDX-License-Identifier: GPL-2.0+ */
/*
* Copyright 2007 Freescale Semiconductor.
- *
- * See file CREDITS for list of people who contributed to this
- * project.
- *
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of the GNU General Public License as
- * published by the Free Software Foundation; either version 2 of
- * the License, or (at your option) any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston,
- * MA 02111-1307 USA
*/
#ifndef __BCSR_H_
7 cfg boot seq
* BCSR 1 *
- 0:2 cfg rom lock
- 3:5 cfg host agent
+ 0:2 cfg rom lock
+ 3:5 cfg host agent
6 PCI IO
7 cfg RIO size
0 TSEC1 reduce
1 TSEC2 reduce
2:3 TSEC1 protocol
- 4:5 TSEC2 protocol
+ 4:5 TSEC2 protocol
6 PHY1 slave
7 PHY2 slave
7 Power on reset
* BCSR 7 *
- 2 board host mode indication
- 5 enable TSEC1 PHY
- 6 enable TSEC2 PHY
+ 2 board host mode indication
+ 5 enable TSEC1 PHY
+ 6 enable TSEC2 PHY
* BCSR 8 *
0 UCC GETH1 enable
7 Flash write protect
*/
+#define BCSR_UCC1_GETH_EN (0x1 << 7)
+#define BCSR_UCC2_GETH_EN (0x1 << 7)
+#define BCSR_UCC1_MODE_MSK (0x3 << 4)
+#define BCSR_UCC2_MODE_MSK (0x3 << 0)
+
/*BCSR Utils functions*/
void enable_8568mds_duart(void);
void disable_8568mds_flash_write(void);
void enable_8568mds_qe_mdio(void);
+#if defined(CONFIG_UEC_ETH1) || defined(CONFIG_UEC_ETH2)
+void reset_8568mds_uccs(void);
+#endif
+
#endif /* __BCSR_H_ */