forked from ~ljy/RK356X_SDK_RELEASE

hc
2024-05-10 9999e48639b3cecb08ffb37358bcba3b48161b29
kernel/drivers/net/ethernet/stmicro/stmmac/altr_tse_pcs.c
....@@ -1,16 +1,5 @@
1
+// SPDX-License-Identifier: GPL-2.0-only
12 /* Copyright Altera Corporation (C) 2016. All rights reserved.
2
- *
3
- * This program is free software; you can redistribute it and/or modify
4
- * it under the terms of the GNU General Public License, version 2,
5
- * as published by the Free Software Foundation.
6
- *
7
- * This program is distributed in the hope that it will be useful,
8
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
9
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
10
- * GNU General Public License for more details.
11
- *
12
- * You should have received a copy of the GNU General Public License
13
- * along with this program. If not, see <http://www.gnu.org/licenses/>.
143 *
154 * Author: Tien Hock Loh <thloh@altera.com>
165 */
....@@ -67,10 +56,6 @@
6756 #define TSE_PCS_USE_SGMII_AN_MASK BIT(1)
6857 #define TSE_PCS_USE_SGMII_ENA BIT(0)
6958 #define TSE_PCS_IF_USE_SGMII 0x03
70
-
71
-#define SGMII_ADAPTER_CTRL_REG 0x00
72
-#define SGMII_ADAPTER_DISABLE 0x0001
73
-#define SGMII_ADAPTER_ENABLE 0x0000
7459
7560 #define AUTONEGO_LINK_TIMER 20
7661
....@@ -213,11 +198,7 @@
213198 unsigned int speed)
214199 {
215200 void __iomem *tse_pcs_base = pcs->tse_pcs_base;
216
- void __iomem *sgmii_adapter_base = pcs->sgmii_adapter_base;
217201 u32 val;
218
-
219
- writew(SGMII_ADAPTER_ENABLE,
220
- sgmii_adapter_base + SGMII_ADAPTER_CTRL_REG);
221202
222203 pcs->autoneg = phy_dev->autoneg;
223204