Re: [PATCH 1/2] net-next: stmmac: add adjust_link function

2017-05-17 Thread Corentin Labbe
On Tue, May 16, 2017 at 09:43:04AM -0700, Florian Fainelli wrote: > On 05/15/2017 04:41 AM, Corentin Labbe wrote: > > My dwmac-sun8i serie will add some if (has_sun8i) to > > stmmac_adjust_link() > > Since the current stmmac_adjust_link() alreaady have lots of if > > (has_gmac/gmac4), > > It is no

Re: [PATCH 1/2] net-next: stmmac: add adjust_link function

2017-05-16 Thread Corentin Labbe
On Tue, May 16, 2017 at 09:43:04AM -0700, Florian Fainelli wrote: > On 05/15/2017 04:41 AM, Corentin Labbe wrote: > > My dwmac-sun8i serie will add some if (has_sun8i) to > > stmmac_adjust_link() > > Since the current stmmac_adjust_link() alreaady have lots of if > > (has_gmac/gmac4), > > It is no

Re: [PATCH 1/2] net-next: stmmac: add adjust_link function

2017-05-16 Thread Florian Fainelli
On 05/15/2017 04:41 AM, Corentin Labbe wrote: > My dwmac-sun8i serie will add some if (has_sun8i) to > stmmac_adjust_link() > Since the current stmmac_adjust_link() alreaady have lots of if > (has_gmac/gmac4), > It is now better to create an adjust_link() function for each dwmac. Is it really, be

Re: [PATCH 1/2] net-next: stmmac: add adjust_link function

2017-05-16 Thread David Miller
From: Corentin Labbe Date: Mon, 15 May 2017 13:41:39 +0200 > My dwmac-sun8i serie will add some if (has_sun8i) to > stmmac_adjust_link() > Since the current stmmac_adjust_link() alreaady have lots of if > (has_gmac/gmac4), > It is now better to create an adjust_link() function for each dwmac. >

[PATCH 1/2] net-next: stmmac: add adjust_link function

2017-05-15 Thread Corentin Labbe
My dwmac-sun8i serie will add some if (has_sun8i) to stmmac_adjust_link() Since the current stmmac_adjust_link() alreaady have lots of if (has_gmac/gmac4), It is now better to create an adjust_link() function for each dwmac. So this patch add an adjust_link() function pointer, and move code out o