From mboxrd@z Thu Jan 1 00:00:00 1970 From: Jose Abreu Subject: [PATCH net-next 00/10] net: stmmac: Be less dependent on Synopsys ID Date: Tue, 8 May 2018 15:45:23 +0100 Message-ID: Cc: Jose Abreu , "David S. Miller" , Joao Pinto , Vitor Soares , Giuseppe Cavallaro , Alexandre Torgue To: netdev@vger.kernel.org Return-path: Received: from smtprelay6.synopsys.com ([198.182.37.59]:35774 "EHLO smtprelay.synopsys.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932334AbeEHOq4 (ORCPT ); Tue, 8 May 2018 10:46:56 -0400 Received: from mailhost.synopsys.com (mailhost1.synopsys.com [10.12.238.239]) by smtprelay.synopsys.com (Postfix) with ESMTP id 8BC651E0676 for ; Tue, 8 May 2018 16:46:54 +0200 (CEST) Sender: netdev-owner@vger.kernel.org List-ID: David, This series was based on top of [1]. Please see my reply on [1] and let me know if I need to rebase against -next without this dependecy. All, This targets to uniformize the handling of the different GMAC versions in stmmac_main.c file. Currently there are some if/else conditions in the main source file which calls different callbacks depending on the ID of GMAC. With the introducion of a generic HW interface handling which automatically selects the GMAC callbacks to be used, it is now unpleasant to see if conditions in the main code because this should be completely agnostic of the GMAC version. This series removes most of these conditions. There are some if conditions that remain untouched but the callbacks handling are now uniformized. Tested in GMAC5, hope I didn't break any previous versions. [1] https://patchwork.ozlabs.org/patch/908618/ Cc: David S. Miller Cc: Joao Pinto Cc: Vitor Soares Cc: Giuseppe Cavallaro Cc: Alexandre Torgue Jose Abreu (10): net: stmmac: Let descriptor code set skbuff address net: stmmac: Let descriptor code clear the descriptor net: stmmac: Uniformize the use of dma_{rx/tx}_mode callbacks net: stmmac: Remove uneeded checks for GMAC version net: stmmac: Move PTP and MMC base address calculation to hwif.c net: stmmac: Uniformize the use of dma_init_* callbacks net: stmmac: Remove uneeded check for GMAC version in stmmac_xmit net: stmmac: Do not initialize the RX Descriptor twice net: stmmac: Let descriptor code get skbuff address net: stmmac: Remove if condition by taking advantage of hwif return code drivers/net/ethernet/stmicro/stmmac/dwmac-sun8i.c | 57 ++++--- .../net/ethernet/stmicro/stmmac/dwmac1000_dma.c | 92 ++++++---- drivers/net/ethernet/stmicro/stmmac/dwmac100_dma.c | 35 +++-- drivers/net/ethernet/stmicro/stmmac/dwmac4_descs.c | 22 +++ drivers/net/ethernet/stmicro/stmmac/dwmac4_dma.c | 3 +- drivers/net/ethernet/stmicro/stmmac/dwmac4_dma.h | 1 - drivers/net/ethernet/stmicro/stmmac/enh_desc.c | 18 ++ drivers/net/ethernet/stmicro/stmmac/hwif.c | 34 ++++ drivers/net/ethernet/stmicro/stmmac/hwif.h | 25 ++- drivers/net/ethernet/stmicro/stmmac/norm_desc.c | 18 ++ drivers/net/ethernet/stmicro/stmmac/stmmac_main.c | 193 +++++++------------- 11 files changed, 286 insertions(+), 212 deletions(-)