kernel: bump to 4.9.105

Refresh patches.

Drop patches that have been upstreamed:
target/linux/ar71xx/patches-4.9/106-01-MIPS-ath79-fix-AR724X_PLL_REG_PCIE_CONFIG-offset.patch
target/linux/generic/backport-4.9/095-v4.12-ipv6-Need-to-export-ipv6_push_frag_opts-for-tunnelin.patch
target/linux/generic/pending-4.9/180-net-phy-at803x-add-support-for-AT8032.patch
target/linux/generic/pending-4.9/181-net-usb-add-lte-modem-wistron-neweb-d18q1.patch
target/linux/generic/pending-4.9/182-net-qmi_wwan-add-BroadMobi-BM806U-2020-2033.patch

Compile & run tested: ar71xx Archer C7 v2

Signed-off-by: Kevin Darbyshire-Bryant <ldir@darbyshire-bryant.me.uk>
This commit is contained in:
Kevin Darbyshire-Bryant
2018-05-31 19:49:08 +00:00
committed by John Crispin
parent 5b0c899bfd
commit 7dca1bae82
36 changed files with 439 additions and 681 deletions

View File

@@ -2317,7 +2317,7 @@
priv->xstats.tx_clean++;
@@ -1393,22 +1394,17 @@ static void stmmac_tx_clean(struct stmma
@@ -1398,22 +1399,17 @@ static void stmmac_tx_clean(struct stmma
netdev_completed_queue(priv->dev, pkts_compl, bytes_compl);
if (unlikely(netif_queue_stopped(priv->dev) &&
@@ -2345,7 +2345,7 @@
}
static inline void stmmac_enable_dma_irq(struct stmmac_priv *priv)
@@ -1512,7 +1508,7 @@ static void stmmac_mmc_setup(struct stmm
@@ -1517,7 +1513,7 @@ static void stmmac_mmc_setup(struct stmm
dwmac_mmc_ctrl(priv->mmcaddr, mode);
memset(&priv->mmc, 0, sizeof(struct stmmac_counters));
} else
@@ -2354,7 +2354,7 @@
}
/**
@@ -1525,18 +1521,18 @@ static void stmmac_mmc_setup(struct stmm
@@ -1530,18 +1526,18 @@ static void stmmac_mmc_setup(struct stmm
static void stmmac_selec_desc_mode(struct stmmac_priv *priv)
{
if (priv->plat->enh_desc) {
@@ -2377,7 +2377,7 @@
priv->hw->desc = &ndesc_ops;
}
}
@@ -1577,8 +1573,8 @@ static void stmmac_check_ether_addr(stru
@@ -1582,8 +1578,8 @@ static void stmmac_check_ether_addr(stru
priv->dev->dev_addr, 0);
if (!is_valid_ether_addr(priv->dev->dev_addr))
eth_hw_addr_random(priv->dev);
@@ -2388,7 +2388,7 @@
}
}
@@ -1592,16 +1588,12 @@ static void stmmac_check_ether_addr(stru
@@ -1597,16 +1593,12 @@ static void stmmac_check_ether_addr(stru
*/
static int stmmac_init_dma_engine(struct stmmac_priv *priv)
{
@@ -2408,7 +2408,7 @@
}
if (priv->extend_desc && (priv->mode == STMMAC_RING_MODE))
@@ -1613,8 +1605,8 @@ static int stmmac_init_dma_engine(struct
@@ -1618,8 +1610,8 @@ static int stmmac_init_dma_engine(struct
return ret;
}
@@ -2419,7 +2419,7 @@
if (priv->synopsys_id >= DWMAC_CORE_4_00) {
priv->rx_tail_addr = priv->dma_rx_phy +
@@ -1686,7 +1678,8 @@ static int stmmac_hw_setup(struct net_de
@@ -1691,7 +1683,8 @@ static int stmmac_hw_setup(struct net_de
/* DMA initialization and SW reset */
ret = stmmac_init_dma_engine(priv);
if (ret < 0) {
@@ -2429,7 +2429,7 @@
return ret;
}
@@ -1715,7 +1708,7 @@ static int stmmac_hw_setup(struct net_de
@@ -1720,7 +1713,7 @@ static int stmmac_hw_setup(struct net_de
ret = priv->hw->mac->rx_ipc(priv->hw);
if (!ret) {
@@ -2438,7 +2438,7 @@
priv->plat->rx_coe = STMMAC_RX_COE_NONE;
priv->hw->rx_csum = 0;
}
@@ -1740,10 +1733,11 @@ static int stmmac_hw_setup(struct net_de
@@ -1745,10 +1738,11 @@ static int stmmac_hw_setup(struct net_de
#ifdef CONFIG_DEBUG_FS
ret = stmmac_init_fs(dev);
if (ret < 0)
@@ -2452,7 +2452,7 @@
priv->hw->dma->start_tx(priv->ioaddr);
priv->hw->dma->start_rx(priv->ioaddr);
@@ -1798,8 +1792,9 @@ static int stmmac_open(struct net_device
@@ -1803,8 +1797,9 @@ static int stmmac_open(struct net_device
priv->hw->pcs != STMMAC_PCS_RTBI) {
ret = stmmac_init_phy(dev);
if (ret) {
@@ -2464,7 +2464,7 @@
return ret;
}
}
@@ -1814,33 +1809,36 @@ static int stmmac_open(struct net_device
@@ -1819,33 +1814,36 @@ static int stmmac_open(struct net_device
ret = alloc_dma_desc_resources(priv);
if (ret < 0) {
@@ -2508,7 +2508,7 @@
goto init_error;
}
@@ -1849,8 +1847,9 @@ static int stmmac_open(struct net_device
@@ -1854,8 +1852,9 @@ static int stmmac_open(struct net_device
ret = request_irq(priv->wol_irq, stmmac_interrupt,
IRQF_SHARED, dev->name, dev);
if (unlikely(ret < 0)) {
@@ -2520,7 +2520,7 @@
goto wolirq_error;
}
}
@@ -1860,8 +1859,9 @@ static int stmmac_open(struct net_device
@@ -1865,8 +1864,9 @@ static int stmmac_open(struct net_device
ret = request_irq(priv->lpi_irq, stmmac_interrupt, IRQF_SHARED,
dev->name, dev);
if (unlikely(ret < 0)) {
@@ -2532,7 +2532,7 @@
goto lpiirq_error;
}
}
@@ -1880,8 +1880,8 @@ wolirq_error:
@@ -1885,8 +1885,8 @@ wolirq_error:
init_error:
free_dma_desc_resources(priv);
dma_desc_error:
@@ -2543,7 +2543,7 @@
return ret;
}
@@ -1900,10 +1900,9 @@ static int stmmac_release(struct net_dev
@@ -1905,10 +1905,9 @@ static int stmmac_release(struct net_dev
del_timer_sync(&priv->eee_ctrl_timer);
/* Stop and disconnect the PHY */
@@ -2557,7 +2557,7 @@
}
netif_stop_queue(dev);
@@ -1963,13 +1962,13 @@ static void stmmac_tso_allocator(struct
@@ -1968,13 +1967,13 @@ static void stmmac_tso_allocator(struct
priv->cur_tx = STMMAC_GET_ENTRY(priv->cur_tx, DMA_TX_SIZE);
desc = priv->dma_tx + priv->cur_tx;
@@ -2573,7 +2573,7 @@
0, 0);
tmp_len -= TSO_MAX_BUFF_SIZE;
@@ -2014,8 +2013,6 @@ static netdev_tx_t stmmac_tso_xmit(struc
@@ -2019,8 +2018,6 @@ static netdev_tx_t stmmac_tso_xmit(struc
u8 proto_hdr_len;
int i;
@@ -2582,7 +2582,7 @@
/* Compute header lengths */
proto_hdr_len = skb_transport_offset(skb) + tcp_hdrlen(skb);
@@ -2025,9 +2022,10 @@ static netdev_tx_t stmmac_tso_xmit(struc
@@ -2030,9 +2027,10 @@ static netdev_tx_t stmmac_tso_xmit(struc
if (!netif_queue_stopped(dev)) {
netif_stop_queue(dev);
/* This is a hard error, log it. */
@@ -2595,7 +2595,7 @@
return NETDEV_TX_BUSY;
}
@@ -2065,11 +2063,11 @@ static netdev_tx_t stmmac_tso_xmit(struc
@@ -2070,11 +2068,11 @@ static netdev_tx_t stmmac_tso_xmit(struc
priv->tx_skbuff_dma[first_entry].len = skb_headlen(skb);
priv->tx_skbuff[first_entry] = skb;
@@ -2609,7 +2609,7 @@
/* If needed take extra descriptors to fill the remaining payload */
tmp_pay_len = pay_len - TSO_MAX_BUFF_SIZE;
@@ -2098,8 +2096,8 @@ static netdev_tx_t stmmac_tso_xmit(struc
@@ -2103,8 +2101,8 @@ static netdev_tx_t stmmac_tso_xmit(struc
priv->cur_tx = STMMAC_GET_ENTRY(priv->cur_tx, DMA_TX_SIZE);
if (unlikely(stmmac_tx_avail(priv) <= (MAX_SKB_FRAGS + 1))) {
@@ -2620,7 +2620,7 @@
netif_stop_queue(dev);
}
@@ -2143,7 +2141,7 @@ static netdev_tx_t stmmac_tso_xmit(struc
@@ -2155,7 +2153,7 @@ static netdev_tx_t stmmac_tso_xmit(struc
* descriptor and then barrier is needed to make sure that
* all is coherent before granting the DMA engine.
*/
@@ -2629,7 +2629,7 @@
if (netif_msg_pktdata(priv)) {
pr_info("%s: curr=%d dirty=%d f=%d, e=%d, f_p=%p, nfrags %d\n",
@@ -2162,11 +2160,9 @@ static netdev_tx_t stmmac_tso_xmit(struc
@@ -2174,11 +2172,9 @@ static netdev_tx_t stmmac_tso_xmit(struc
priv->hw->dma->set_tx_tail_ptr(priv->ioaddr, priv->tx_tail_addr,
STMMAC_CHAN0);
@@ -2641,7 +2641,7 @@
dev_err(priv->device, "Tx dma map failed\n");
dev_kfree_skb(skb);
priv->dev->stats.tx_dropped++;
@@ -2198,14 +2194,13 @@ static netdev_tx_t stmmac_xmit(struct sk
@@ -2210,14 +2206,13 @@ static netdev_tx_t stmmac_xmit(struct sk
return stmmac_tso_xmit(skb, dev);
}
@@ -2659,7 +2659,7 @@
}
return NETDEV_TX_BUSY;
}
@@ -2258,13 +2253,11 @@ static netdev_tx_t stmmac_xmit(struct sk
@@ -2270,13 +2265,11 @@ static netdev_tx_t stmmac_xmit(struct sk
priv->tx_skbuff[entry] = NULL;
@@ -2678,7 +2678,7 @@
priv->tx_skbuff_dma[entry].map_as_page = true;
priv->tx_skbuff_dma[entry].len = len;
@@ -2282,9 +2275,10 @@ static netdev_tx_t stmmac_xmit(struct sk
@@ -2294,9 +2287,10 @@ static netdev_tx_t stmmac_xmit(struct sk
if (netif_msg_pktdata(priv)) {
void *tx_head;
@@ -2692,7 +2692,7 @@
if (priv->extend_desc)
tx_head = (void *)priv->dma_etx;
@@ -2293,13 +2287,13 @@ static netdev_tx_t stmmac_xmit(struct sk
@@ -2305,13 +2299,13 @@ static netdev_tx_t stmmac_xmit(struct sk
priv->hw->desc->display_ring(tx_head, DMA_TX_SIZE, false);
@@ -2709,7 +2709,7 @@
netif_stop_queue(dev);
}
@@ -2335,13 +2329,11 @@ static netdev_tx_t stmmac_xmit(struct sk
@@ -2347,13 +2341,11 @@ static netdev_tx_t stmmac_xmit(struct sk
if (dma_mapping_error(priv->device, des))
goto dma_map_err;
@@ -2728,7 +2728,7 @@
priv->tx_skbuff_dma[first_entry].len = nopaged_len;
priv->tx_skbuff_dma[first_entry].last_segment = last_segment;
@@ -2362,7 +2354,7 @@ static netdev_tx_t stmmac_xmit(struct sk
@@ -2374,7 +2366,7 @@ static netdev_tx_t stmmac_xmit(struct sk
* descriptor and then barrier is needed to make sure that
* all is coherent before granting the DMA engine.
*/
@@ -2737,7 +2737,7 @@
}
netdev_sent_queue(dev, skb->len);
@@ -2373,12 +2365,10 @@ static netdev_tx_t stmmac_xmit(struct sk
@@ -2385,12 +2377,10 @@ static netdev_tx_t stmmac_xmit(struct sk
priv->hw->dma->set_tx_tail_ptr(priv->ioaddr, priv->tx_tail_addr,
STMMAC_CHAN0);
@@ -2751,7 +2751,7 @@
dev_kfree_skb(skb);
priv->dev->stats.tx_dropped++;
return NETDEV_TX_OK;
@@ -2449,16 +2439,16 @@ static inline void stmmac_rx_refill(stru
@@ -2461,16 +2451,16 @@ static inline void stmmac_rx_refill(stru
DMA_FROM_DEVICE);
if (dma_mapping_error(priv->device,
priv->rx_skbuff_dma[entry])) {
@@ -2771,7 +2771,7 @@
}
if (priv->hw->mode->refill_desc3)
priv->hw->mode->refill_desc3(priv, p);
@@ -2466,17 +2456,17 @@ static inline void stmmac_rx_refill(stru
@@ -2478,17 +2468,17 @@ static inline void stmmac_rx_refill(stru
if (priv->rx_zeroc_thresh > 0)
priv->rx_zeroc_thresh--;
@@ -2793,7 +2793,7 @@
entry = STMMAC_GET_ENTRY(entry, DMA_RX_SIZE);
}
@@ -2500,7 +2490,7 @@ static int stmmac_rx(struct stmmac_priv
@@ -2512,7 +2502,7 @@ static int stmmac_rx(struct stmmac_priv
if (netif_msg_rx_status(priv)) {
void *rx_head;
@@ -2802,7 +2802,7 @@
if (priv->extend_desc)
rx_head = (void *)priv->dma_erx;
else
@@ -2562,9 +2552,9 @@ static int stmmac_rx(struct stmmac_priv
@@ -2574,9 +2564,9 @@ static int stmmac_rx(struct stmmac_priv
unsigned int des;
if (unlikely(priv->synopsys_id >= DWMAC_CORE_4_00))
@@ -2814,7 +2814,7 @@
frame_len = priv->hw->desc->get_rx_frame_len(p, coe);
@@ -2573,9 +2563,9 @@ static int stmmac_rx(struct stmmac_priv
@@ -2585,9 +2575,9 @@ static int stmmac_rx(struct stmmac_priv
* ignored
*/
if (frame_len > priv->dma_buf_sz) {
@@ -2827,7 +2827,7 @@
priv->dev->stats.rx_length_errors++;
break;
}
@@ -2587,11 +2577,11 @@ static int stmmac_rx(struct stmmac_priv
@@ -2599,11 +2589,11 @@ static int stmmac_rx(struct stmmac_priv
frame_len -= ETH_FCS_LEN;
if (netif_msg_rx_status(priv)) {
@@ -2843,7 +2843,7 @@
}
/* The zero-copy is always used for all the sizes
@@ -2628,8 +2618,9 @@ static int stmmac_rx(struct stmmac_priv
@@ -2640,8 +2630,9 @@ static int stmmac_rx(struct stmmac_priv
} else {
skb = priv->rx_skbuff[entry];
if (unlikely(!skb)) {
@@ -2855,7 +2855,7 @@
priv->dev->stats.rx_dropped++;
break;
}
@@ -2645,7 +2636,8 @@ static int stmmac_rx(struct stmmac_priv
@@ -2657,7 +2648,8 @@ static int stmmac_rx(struct stmmac_priv
}
if (netif_msg_pktdata(priv)) {
@@ -2865,7 +2865,7 @@
print_pkt(skb->data, frame_len);
}
@@ -2748,7 +2740,7 @@ static int stmmac_change_mtu(struct net_
@@ -2760,7 +2752,7 @@ static int stmmac_change_mtu(struct net_
int max_mtu;
if (netif_running(dev)) {
@@ -2874,7 +2874,7 @@
return -EBUSY;
}
@@ -2840,7 +2832,7 @@ static irqreturn_t stmmac_interrupt(int
@@ -2852,7 +2844,7 @@ static irqreturn_t stmmac_interrupt(int
pm_wakeup_event(priv->device, 0);
if (unlikely(!dev)) {
@@ -2883,7 +2883,7 @@
return IRQ_NONE;
}
@@ -2898,7 +2890,6 @@ static void stmmac_poll_controller(struc
@@ -2910,7 +2902,6 @@ static void stmmac_poll_controller(struc
*/
static int stmmac_ioctl(struct net_device *dev, struct ifreq *rq, int cmd)
{
@@ -2891,7 +2891,7 @@
int ret = -EOPNOTSUPP;
if (!netif_running(dev))
@@ -2908,9 +2899,9 @@ static int stmmac_ioctl(struct net_devic
@@ -2920,9 +2911,9 @@ static int stmmac_ioctl(struct net_devic
case SIOCGMIIPHY:
case SIOCGMIIREG:
case SIOCSMIIREG:
@@ -2903,7 +2903,7 @@
break;
case SIOCSHWTSTAMP:
ret = stmmac_hwtstamp_ioctl(dev, rq);
@@ -2938,14 +2929,17 @@ static void sysfs_display_ring(void *hea
@@ -2950,14 +2941,17 @@ static void sysfs_display_ring(void *hea
x = *(u64 *) ep;
seq_printf(seq, "%d [0x%x]: 0x%x 0x%x 0x%x 0x%x\n",
i, (unsigned int)virt_to_phys(ep),
@@ -2924,7 +2924,7 @@
p++;
}
seq_printf(seq, "\n");
@@ -2977,6 +2971,8 @@ static int stmmac_sysfs_ring_open(struct
@@ -2989,6 +2983,8 @@ static int stmmac_sysfs_ring_open(struct
return single_open(file, stmmac_sysfs_ring_read, inode->i_private);
}
@@ -2933,7 +2933,7 @@
static const struct file_operations stmmac_rings_status_fops = {
.owner = THIS_MODULE,
.open = stmmac_sysfs_ring_open,
@@ -2999,11 +2995,11 @@ static int stmmac_sysfs_dma_cap_read(str
@@ -3011,11 +3007,11 @@ static int stmmac_sysfs_dma_cap_read(str
seq_printf(seq, "\tDMA HW features\n");
seq_printf(seq, "==============================\n");
@@ -2948,7 +2948,7 @@
(priv->dma_cap.half_duplex) ? "Y" : "N");
seq_printf(seq, "\tHash Filter: %s\n",
(priv->dma_cap.hash_filter) ? "Y" : "N");
@@ -3021,9 +3017,9 @@ static int stmmac_sysfs_dma_cap_read(str
@@ -3033,9 +3029,9 @@ static int stmmac_sysfs_dma_cap_read(str
(priv->dma_cap.rmon) ? "Y" : "N");
seq_printf(seq, "\tIEEE 1588-2002 Time Stamp: %s\n",
(priv->dma_cap.time_stamp) ? "Y" : "N");
@@ -2960,7 +2960,7 @@
(priv->dma_cap.eee) ? "Y" : "N");
seq_printf(seq, "\tAV features: %s\n", (priv->dma_cap.av) ? "Y" : "N");
seq_printf(seq, "\tChecksum Offload in TX: %s\n",
@@ -3070,8 +3066,7 @@ static int stmmac_init_fs(struct net_dev
@@ -3082,8 +3078,7 @@ static int stmmac_init_fs(struct net_dev
priv->dbgfs_dir = debugfs_create_dir(dev->name, stmmac_fs_dir);
if (!priv->dbgfs_dir || IS_ERR(priv->dbgfs_dir)) {
@@ -2970,7 +2970,7 @@
return -ENOMEM;
}
@@ -3083,7 +3078,7 @@ static int stmmac_init_fs(struct net_dev
@@ -3095,7 +3090,7 @@ static int stmmac_init_fs(struct net_dev
&stmmac_rings_status_fops);
if (!priv->dbgfs_rings_status || IS_ERR(priv->dbgfs_rings_status)) {
@@ -2979,7 +2979,7 @@
debugfs_remove_recursive(priv->dbgfs_dir);
return -ENOMEM;
@@ -3095,7 +3090,7 @@ static int stmmac_init_fs(struct net_dev
@@ -3107,7 +3102,7 @@ static int stmmac_init_fs(struct net_dev
dev, &stmmac_dma_cap_fops);
if (!priv->dbgfs_dma_cap || IS_ERR(priv->dbgfs_dma_cap)) {
@@ -2988,7 +2988,7 @@
debugfs_remove_recursive(priv->dbgfs_dir);
return -ENOMEM;
@@ -3167,11 +3162,11 @@ static int stmmac_hw_init(struct stmmac_
@@ -3179,11 +3174,11 @@ static int stmmac_hw_init(struct stmmac_
} else {
if (chain_mode) {
priv->hw->mode = &chain_mode_ops;
@@ -3002,7 +3002,7 @@
priv->mode = STMMAC_RING_MODE;
}
}
@@ -3179,7 +3174,7 @@ static int stmmac_hw_init(struct stmmac_
@@ -3191,7 +3186,7 @@ static int stmmac_hw_init(struct stmmac_
/* Get the HW capability (new GMAC newer than 3.50a) */
priv->hw_cap_support = stmmac_get_hw_features(priv);
if (priv->hw_cap_support) {
@@ -3011,7 +3011,7 @@
/* We can override some gmac/dma configuration fields: e.g.
* enh_desc, tx_coe (e.g. that are passed through the
@@ -3204,8 +3199,9 @@ static int stmmac_hw_init(struct stmmac_
@@ -3216,8 +3211,9 @@ static int stmmac_hw_init(struct stmmac_
else if (priv->dma_cap.rx_coe_type1)
priv->plat->rx_coe = STMMAC_RX_COE_TYPE1;
@@ -3023,7 +3023,7 @@
/* To use alternate (extended), normal or GMAC4 descriptor structures */
if (priv->synopsys_id >= DWMAC_CORE_4_00)
@@ -3215,20 +3211,20 @@ static int stmmac_hw_init(struct stmmac_
@@ -3227,20 +3223,20 @@ static int stmmac_hw_init(struct stmmac_
if (priv->plat->rx_coe) {
priv->hw->rx_csum = priv->plat->rx_coe;
@@ -3049,7 +3049,7 @@
return 0;
}
@@ -3287,8 +3283,8 @@ int stmmac_dvr_probe(struct device *devi
@@ -3299,8 +3295,8 @@ int stmmac_dvr_probe(struct device *devi
priv->stmmac_clk = devm_clk_get(priv->device, STMMAC_RESOURCE_NAME);
if (IS_ERR(priv->stmmac_clk)) {
@@ -3060,7 +3060,7 @@
/* If failed to obtain stmmac_clk and specific clk_csr value
* is NOT passed from the platform, probe fail.
*/
@@ -3337,7 +3333,7 @@ int stmmac_dvr_probe(struct device *devi
@@ -3349,7 +3345,7 @@ int stmmac_dvr_probe(struct device *devi
if ((priv->plat->tso_en) && (priv->dma_cap.tsoen)) {
ndev->hw_features |= NETIF_F_TSO;
priv->tso = true;
@@ -3069,7 +3069,7 @@
}
ndev->features |= ndev->hw_features | NETIF_F_HIGHDMA;
ndev->watchdog_timeo = msecs_to_jiffies(watchdog);
@@ -3357,13 +3353,13 @@ int stmmac_dvr_probe(struct device *devi
@@ -3369,13 +3365,13 @@ int stmmac_dvr_probe(struct device *devi
*/
if ((priv->synopsys_id >= DWMAC_CORE_3_50) && (!priv->plat->riwt_off)) {
priv->use_riwt = 1;
@@ -3085,7 +3085,7 @@
/* If a specific clk_csr value is passed from the platform
* this means that the CSR Clock Range selection cannot be
@@ -3384,15 +3380,17 @@ int stmmac_dvr_probe(struct device *devi
@@ -3396,15 +3392,17 @@ int stmmac_dvr_probe(struct device *devi
/* MDIO bus Registration */
ret = stmmac_mdio_register(ndev);
if (ret < 0) {
@@ -3107,7 +3107,7 @@
goto error_netdev_register;
}
@@ -3403,7 +3401,7 @@ error_netdev_register:
@@ -3415,7 +3413,7 @@ error_netdev_register:
priv->hw->pcs != STMMAC_PCS_TBI &&
priv->hw->pcs != STMMAC_PCS_RTBI)
stmmac_mdio_unregister(ndev);
@@ -3116,7 +3116,7 @@
netif_napi_del(&priv->napi);
error_hw_init:
clk_disable_unprepare(priv->pclk);
@@ -3427,7 +3425,7 @@ int stmmac_dvr_remove(struct device *dev
@@ -3439,7 +3437,7 @@ int stmmac_dvr_remove(struct device *dev
struct net_device *ndev = dev_get_drvdata(dev);
struct stmmac_priv *priv = netdev_priv(ndev);
@@ -3125,7 +3125,7 @@
priv->hw->dma->stop_rx(priv->ioaddr);
priv->hw->dma->stop_tx(priv->ioaddr);
@@ -3465,8 +3463,8 @@ int stmmac_suspend(struct device *dev)
@@ -3477,8 +3475,8 @@ int stmmac_suspend(struct device *dev)
if (!ndev || !netif_running(ndev))
return 0;
@@ -3136,7 +3136,7 @@
spin_lock_irqsave(&priv->lock, flags);
@@ -3560,8 +3558,8 @@ int stmmac_resume(struct device *dev)
@@ -3572,8 +3570,8 @@ int stmmac_resume(struct device *dev)
spin_unlock_irqrestore(&priv->lock, flags);

View File

@@ -418,7 +418,7 @@
};
static void meson8b_dwmac_mask_bits(struct meson8b_dwmac *dwmac, u32 reg,
@@ -179,11 +177,19 @@ static int meson8b_init_prg_eth(struct m
@@ -181,11 +179,19 @@ static int meson8b_init_prg_eth(struct m
{
int ret;
unsigned long clk_rate;
@@ -439,7 +439,7 @@
case PHY_INTERFACE_MODE_RGMII_TXID:
/* Generate a 25MHz clock for the PHY */
clk_rate = 25 * 1000 * 1000;
@@ -196,9 +202,8 @@ static int meson8b_init_prg_eth(struct m
@@ -198,9 +204,8 @@ static int meson8b_init_prg_eth(struct m
meson8b_dwmac_mask_bits(dwmac, PRG_ETH0,
PRG_ETH0_INVERTED_RMII_CLK, 0);
@@ -450,7 +450,7 @@
break;
case PHY_INTERFACE_MODE_RMII:
@@ -284,6 +289,11 @@ static int meson8b_dwmac_probe(struct pl
@@ -286,6 +291,11 @@ static int meson8b_dwmac_probe(struct pl
goto err_remove_config_dt;
}
@@ -1671,7 +1671,7 @@
* stmmac_dma_operation_mode - HW DMA operation mode
* @priv: driver private structure
* Description: it is used for configuring the DMA operation mode register in
@@ -1686,10 +1687,6 @@ static int stmmac_hw_setup(struct net_de
@@ -1691,10 +1692,6 @@ static int stmmac_hw_setup(struct net_de
/* Copy the MAC addr into the HW */
priv->hw->mac->set_umac_addr(priv->hw, dev->dev_addr, 0);
@@ -1682,7 +1682,7 @@
/* PS and related bits will be programmed according to the speed */
if (priv->hw->pcs) {
int speed = priv->plat->mac_port_sel_speed;
@@ -1706,6 +1703,10 @@ static int stmmac_hw_setup(struct net_de
@@ -1711,6 +1708,10 @@ static int stmmac_hw_setup(struct net_de
/* Initialize the MAC Core */
priv->hw->mac->core_init(priv->hw, dev->mtu);
@@ -1693,7 +1693,7 @@
ret = priv->hw->mac->rx_ipc(priv->hw);
if (!ret) {
netdev_warn(priv->dev, "RX IPC Checksum Offload disabled\n");
@@ -1726,8 +1727,10 @@ static int stmmac_hw_setup(struct net_de
@@ -1731,8 +1732,10 @@ static int stmmac_hw_setup(struct net_de
if (init_ptp) {
ret = stmmac_init_ptp(priv);
@@ -1706,7 +1706,7 @@
}
#ifdef CONFIG_DEBUG_FS
@@ -1741,11 +1744,6 @@ static int stmmac_hw_setup(struct net_de
@@ -1746,11 +1749,6 @@ static int stmmac_hw_setup(struct net_de
priv->hw->dma->start_tx(priv->ioaddr);
priv->hw->dma->start_rx(priv->ioaddr);
@@ -1718,7 +1718,7 @@
priv->tx_lpi_timer = STMMAC_DEFAULT_TWT_LS;
if ((priv->use_riwt) && (priv->hw->dma->rx_watchdog)) {
@@ -2535,7 +2533,7 @@ static int stmmac_rx(struct stmmac_priv
@@ -2547,7 +2545,7 @@ static int stmmac_rx(struct stmmac_priv
if (unlikely(status == discard_frame)) {
priv->dev->stats.rx_errors++;
if (priv->hwts_rx_en && !priv->extend_desc) {
@@ -1727,7 +1727,7 @@
* with timestamp value, hence reinitialize
* them in stmmac_rx_refill() function so that
* device can reuse it.
@@ -2558,7 +2556,7 @@ static int stmmac_rx(struct stmmac_priv
@@ -2570,7 +2568,7 @@ static int stmmac_rx(struct stmmac_priv
frame_len = priv->hw->desc->get_rx_frame_len(p, coe);
@@ -1736,7 +1736,7 @@
* (preallocated during init) then the packet is
* ignored
*/
@@ -2778,7 +2776,7 @@ static netdev_features_t stmmac_fix_feat
@@ -2790,7 +2788,7 @@ static netdev_features_t stmmac_fix_feat
/* Some GMAC devices have a bugged Jumbo frame support that
* needs to have the Tx COE disabled for oversized frames
* (due to limited buffer sizes). In this case we disable
@@ -1745,7 +1745,7 @@
*/
if (priv->plat->bugged_jumbo && (dev->mtu > ETH_DATA_LEN))
features &= ~NETIF_F_CSUM_MASK;
@@ -2924,9 +2922,7 @@ static void sysfs_display_ring(void *hea
@@ -2936,9 +2934,7 @@ static void sysfs_display_ring(void *hea
struct dma_desc *p = (struct dma_desc *)head;
for (i = 0; i < size; i++) {
@@ -1755,7 +1755,7 @@
seq_printf(seq, "%d [0x%x]: 0x%x 0x%x 0x%x 0x%x\n",
i, (unsigned int)virt_to_phys(ep),
le32_to_cpu(ep->basic.des0),
@@ -2935,7 +2931,6 @@ static void sysfs_display_ring(void *hea
@@ -2947,7 +2943,6 @@ static void sysfs_display_ring(void *hea
le32_to_cpu(ep->basic.des3));
ep++;
} else {
@@ -1763,7 +1763,7 @@
seq_printf(seq, "%d [0x%x]: 0x%x 0x%x 0x%x 0x%x\n",
i, (unsigned int)virt_to_phys(ep),
le32_to_cpu(p->des0), le32_to_cpu(p->des1),
@@ -3005,7 +3000,7 @@ static int stmmac_sysfs_dma_cap_read(str
@@ -3017,7 +3012,7 @@ static int stmmac_sysfs_dma_cap_read(str
(priv->dma_cap.hash_filter) ? "Y" : "N");
seq_printf(seq, "\tMultiple MAC address registers: %s\n",
(priv->dma_cap.multi_addr) ? "Y" : "N");
@@ -1772,7 +1772,7 @@
(priv->dma_cap.pcs) ? "Y" : "N");
seq_printf(seq, "\tSMA (MDIO) Interface: %s\n",
(priv->dma_cap.sma_mdio) ? "Y" : "N");
@@ -3281,44 +3276,8 @@ int stmmac_dvr_probe(struct device *devi
@@ -3293,44 +3288,8 @@ int stmmac_dvr_probe(struct device *devi
if ((phyaddr >= 0) && (phyaddr <= 31))
priv->plat->phy_addr = phyaddr;
@@ -1819,7 +1819,7 @@
/* Init MAC and get the capabilities */
ret = stmmac_hw_init(priv);
@@ -3404,10 +3363,6 @@ error_netdev_register:
@@ -3416,10 +3375,6 @@ error_netdev_register:
error_mdio_register:
netif_napi_del(&priv->napi);
error_hw_init:
@@ -1830,7 +1830,7 @@
free_netdev(ndev);
return ret;
@@ -3433,10 +3388,10 @@ int stmmac_dvr_remove(struct device *dev
@@ -3445,10 +3400,10 @@ int stmmac_dvr_remove(struct device *dev
stmmac_set_mac(priv->ioaddr, false);
netif_carrier_off(ndev);
unregister_netdev(ndev);
@@ -1845,7 +1845,7 @@
if (priv->hw->pcs != STMMAC_PCS_RGMII &&
priv->hw->pcs != STMMAC_PCS_TBI &&
priv->hw->pcs != STMMAC_PCS_RTBI)
@@ -3485,14 +3440,14 @@ int stmmac_suspend(struct device *dev)
@@ -3497,14 +3452,14 @@ int stmmac_suspend(struct device *dev)
stmmac_set_mac(priv->ioaddr, false);
pinctrl_pm_select_sleep_state(priv->device);
/* Disable clock in case of PWM is off */
@@ -1864,7 +1864,7 @@
return 0;
}
EXPORT_SYMBOL_GPL(stmmac_suspend);
@@ -3525,9 +3480,9 @@ int stmmac_resume(struct device *dev)
@@ -3537,9 +3492,9 @@ int stmmac_resume(struct device *dev)
priv->irq_wake = 0;
} else {
pinctrl_pm_select_default_state(priv->device);

File diff suppressed because it is too large Load Diff

View File

@@ -1491,7 +1491,7 @@
free_dma_tx_desc_resources(priv);
return ret;
@@ -2902,8 +2900,7 @@ static netdev_tx_t stmmac_tso_xmit(struc
@@ -2907,8 +2905,7 @@ static netdev_tx_t stmmac_tso_xmit(struc
priv->xstats.tx_set_ic_bit++;
}
@@ -1501,7 +1501,7 @@
if (unlikely((skb_shinfo(skb)->tx_flags & SKBTX_HW_TSTAMP) &&
priv->hwts_tx_en)) {
@@ -2981,7 +2978,7 @@ static netdev_tx_t stmmac_xmit(struct sk
@@ -2993,7 +2990,7 @@ static netdev_tx_t stmmac_xmit(struct sk
/* Manage oversized TCP frames for GMAC4 device */
if (skb_is_gso(skb) && priv->tso) {
@@ -1510,7 +1510,7 @@
return stmmac_tso_xmit(skb, dev);
}
@@ -3112,8 +3109,7 @@ static netdev_tx_t stmmac_xmit(struct sk
@@ -3124,8 +3121,7 @@ static netdev_tx_t stmmac_xmit(struct sk
priv->xstats.tx_set_ic_bit++;
}
@@ -1520,7 +1520,7 @@
/* Ready to fill the first descriptor and set the OWN bit w/o any
* problems because all the descriptors are actually ready to be
@@ -3990,7 +3986,9 @@ static int stmmac_hw_init(struct stmmac_
@@ -4002,7 +3998,9 @@ static int stmmac_hw_init(struct stmmac_
struct mac_device_info *mac;
/* Identify the MAC HW device */
@@ -1531,7 +1531,7 @@
priv->dev->priv_flags |= IFF_UNICAST_FLT;
mac = dwmac1000_setup(priv->ioaddr,
priv->plat->multicast_filter_bins,
@@ -4010,6 +4008,10 @@ static int stmmac_hw_init(struct stmmac_
@@ -4022,6 +4020,10 @@ static int stmmac_hw_init(struct stmmac_
priv->hw = mac;
@@ -1542,7 +1542,7 @@
/* To use the chained or ring mode */
if (priv->synopsys_id >= DWMAC_CORE_4_00) {
priv->hw->mode = &dwmac4_ring_mode_ops;
@@ -4138,8 +4140,15 @@ int stmmac_dvr_probe(struct device *devi
@@ -4150,8 +4152,15 @@ int stmmac_dvr_probe(struct device *devi
if ((phyaddr >= 0) && (phyaddr <= 31))
priv->plat->phy_addr = phyaddr;
@@ -1559,7 +1559,7 @@
/* Init MAC and get the capabilities */
ret = stmmac_hw_init(priv);
@@ -4156,7 +4165,7 @@ int stmmac_dvr_probe(struct device *devi
@@ -4168,7 +4177,7 @@ int stmmac_dvr_probe(struct device *devi
NETIF_F_RXCSUM;
if ((priv->plat->tso_en) && (priv->dma_cap.tsoen)) {
@@ -1568,7 +1568,7 @@
priv->tso = true;
dev_info(priv->device, "TSO feature enabled\n");
}
@@ -4318,7 +4327,7 @@ int stmmac_suspend(struct device *dev)
@@ -4330,7 +4339,7 @@ int stmmac_suspend(struct device *dev)
}
spin_unlock_irqrestore(&priv->lock, flags);