linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH net-next 0/3] net: stmmac: Add ethtool support for get|set channels
@ 2020-09-15  1:28 Wong Vee Khee
  2020-09-15  1:28 ` [PATCH net-next 2/3] net: stmmac: Fix incorrect location to set real_num_rx|tx_queues Wong Vee Khee
  2020-09-15 22:43 ` [PATCH net-next 0/3] net: stmmac: Add ethtool support for get|set channels David Miller
  0 siblings, 2 replies; 6+ messages in thread
From: Wong Vee Khee @ 2020-09-15  1:28 UTC (permalink / raw)
  To: Giuseppe Cavallaro, Alexandre Torgue, Jose Abreu,
	David S . Miller, Maxime Coquelin, Jakub Kicinski
  Cc: Joao Pinto, Arnd Bergmann, Rusell King, netdev, linux-stm32,
	linux-arm-kernel, linux-kernel, Ong Boon Leong, Voon Wei Feng,
	Wong Vee Khee, Vijaya Balan Sadhishkhanna, Seow Chen Yong

This patch set is to add support for user to get or set Tx/Rx channel
via ethtool. There are two patches that fixes bug introduced on upstream
in order to have the feature work.

Tested on Intel Tigerlake Platform.

Aashish Verma (1):
  net: stmmac: Fix incorrect location to set real_num_rx|tx_queues

Ong Boon Leong (2):
  net: stmmac: add ethtool support for get/set channels
  net: stmmac: use netif_tx_start|stop_all_queues() function

 drivers/net/ethernet/stmicro/stmmac/stmmac.h  |   1 +
 .../ethernet/stmicro/stmmac/stmmac_ethtool.c  |  26 ++++
 .../net/ethernet/stmicro/stmmac/stmmac_main.c | 135 +++++++++---------
 3 files changed, 98 insertions(+), 64 deletions(-)

-- 
2.17.0


^ permalink raw reply	[flat|nested] 6+ messages in thread

* [PATCH net-next 2/3] net: stmmac: Fix incorrect location to set real_num_rx|tx_queues
  2020-09-15  1:28 [PATCH net-next 0/3] net: stmmac: Add ethtool support for get|set channels Wong Vee Khee
@ 2020-09-15  1:28 ` Wong Vee Khee
  2020-09-15 22:43 ` [PATCH net-next 0/3] net: stmmac: Add ethtool support for get|set channels David Miller
  1 sibling, 0 replies; 6+ messages in thread
From: Wong Vee Khee @ 2020-09-15  1:28 UTC (permalink / raw)
  To: Giuseppe Cavallaro, Alexandre Torgue, Jose Abreu,
	David S . Miller, Maxime Coquelin, Jakub Kicinski
  Cc: Joao Pinto, Arnd Bergmann, Rusell King, netdev, linux-stm32,
	linux-arm-kernel, linux-kernel, Ong Boon Leong, Voon Wei Feng,
	Wong Vee Khee, Vijaya Balan Sadhishkhanna, Seow Chen Yong

From: Aashish Verma <aashishx.verma@intel.com>

netif_set_real_num_tx_queues() & netif_set_real_num_rx_queues() should be
used to inform network stack about the real Tx & Rx queue (active) number
in both stmmac_open() and stmmac_resume(), therefore, we move the code
from stmmac_dvr_probe() to stmmac_hw_setup().

Fixes: c02b7a914551 net: stmmac: use netif_set_real_num_{rx,tx}_queues

Signed-off-by: Aashish Verma <aashishx.verma@intel.com>
Signed-off-by: Ong Boon Leong <boon.leong.ong@intel.com>
---
 drivers/net/ethernet/stmicro/stmmac/stmmac_main.c | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/drivers/net/ethernet/stmicro/stmmac/stmmac_main.c b/drivers/net/ethernet/stmicro/stmmac/stmmac_main.c
index 9302d8012a10..fea3b77892ab 100644
--- a/drivers/net/ethernet/stmicro/stmmac/stmmac_main.c
+++ b/drivers/net/ethernet/stmicro/stmmac/stmmac_main.c
@@ -2733,6 +2733,10 @@ static int stmmac_hw_setup(struct net_device *dev, bool init_ptp)
 		stmmac_enable_tbs(priv, priv->ioaddr, enable, chan);
 	}
 
+	/* Configure real RX and TX queues */
+	netif_set_real_num_rx_queues(dev, priv->plat->rx_queues_to_use);
+	netif_set_real_num_tx_queues(dev, priv->plat->tx_queues_to_use);
+
 	/* Start the ball rolling... */
 	stmmac_start_all_dma(priv);
 
@@ -4883,10 +4887,6 @@ int stmmac_dvr_probe(struct device *device,
 
 	stmmac_check_ether_addr(priv);
 
-	/* Configure real RX and TX queues */
-	netif_set_real_num_rx_queues(ndev, priv->plat->rx_queues_to_use);
-	netif_set_real_num_tx_queues(ndev, priv->plat->tx_queues_to_use);
-
 	ndev->netdev_ops = &stmmac_netdev_ops;
 
 	ndev->hw_features = NETIF_F_SG | NETIF_F_IP_CSUM | NETIF_F_IPV6_CSUM |
-- 
2.17.0


^ permalink raw reply related	[flat|nested] 6+ messages in thread

* Re: [PATCH net-next 0/3] net: stmmac: Add ethtool support for get|set channels
  2020-09-15  1:28 [PATCH net-next 0/3] net: stmmac: Add ethtool support for get|set channels Wong Vee Khee
  2020-09-15  1:28 ` [PATCH net-next 2/3] net: stmmac: Fix incorrect location to set real_num_rx|tx_queues Wong Vee Khee
@ 2020-09-15 22:43 ` David Miller
  2020-09-15 22:54   ` Florian Fainelli
  1 sibling, 1 reply; 6+ messages in thread
From: David Miller @ 2020-09-15 22:43 UTC (permalink / raw)
  To: vee.khee.wong
  Cc: peppe.cavallaro, alexandre.torgue, joabreu, mcoquelin.stm32,
	kuba, Joao.Pinto, arnd, linux, netdev, linux-stm32,
	linux-arm-kernel, linux-kernel, boon.leong.ong, weifeng.voon,
	sadhishkhanna.vijaya.balan, chen.yong.seow

From: Wong Vee Khee <vee.khee.wong@intel.com>
Date: Tue, 15 Sep 2020 09:28:37 +0800

> This patch set is to add support for user to get or set Tx/Rx channel
> via ethtool. There are two patches that fixes bug introduced on upstream
> in order to have the feature work.
> 
> Tested on Intel Tigerlake Platform.

Series applied, thank you.

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [PATCH net-next 0/3] net: stmmac: Add ethtool support for get|set channels
  2020-09-15 22:43 ` [PATCH net-next 0/3] net: stmmac: Add ethtool support for get|set channels David Miller
@ 2020-09-15 22:54   ` Florian Fainelli
  2020-09-15 23:59     ` Wong, Vee Khee
  0 siblings, 1 reply; 6+ messages in thread
From: Florian Fainelli @ 2020-09-15 22:54 UTC (permalink / raw)
  To: David Miller, vee.khee.wong
  Cc: peppe.cavallaro, alexandre.torgue, joabreu, mcoquelin.stm32,
	kuba, Joao.Pinto, arnd, linux, netdev, linux-stm32,
	linux-arm-kernel, linux-kernel, boon.leong.ong, weifeng.voon,
	sadhishkhanna.vijaya.balan, chen.yong.seow



On 9/15/2020 3:43 PM, David Miller wrote:
> From: Wong Vee Khee <vee.khee.wong@intel.com>
> Date: Tue, 15 Sep 2020 09:28:37 +0800
> 
>> This patch set is to add support for user to get or set Tx/Rx channel
>> via ethtool. There are two patches that fixes bug introduced on upstream
>> in order to have the feature work.
>>
>> Tested on Intel Tigerlake Platform.
> 
> Series applied, thank you.

patch #2 does not have a proper Fixes: tag format, it should be:

Fixes: cafebabed00d ("some super subject")
-- 
Florian

^ permalink raw reply	[flat|nested] 6+ messages in thread

* RE: [PATCH net-next 0/3] net: stmmac: Add ethtool support for get|set channels
  2020-09-15 22:54   ` Florian Fainelli
@ 2020-09-15 23:59     ` Wong, Vee Khee
  2020-09-16  0:02       ` Florian Fainelli
  0 siblings, 1 reply; 6+ messages in thread
From: Wong, Vee Khee @ 2020-09-15 23:59 UTC (permalink / raw)
  To: Florian Fainelli, David Miller
  Cc: peppe.cavallaro, alexandre.torgue, joabreu, mcoquelin.stm32,
	kuba, Joao.Pinto, arnd, linux, netdev, linux-stm32,
	linux-arm-kernel, linux-kernel, Ong, Boon Leong, Voon, Weifeng,
	Vijaya Balan, Sadhishkhanna, Seow, Chen Yong

My bad...

Hi David Miller,

Can you help with the commit message fix or do you want to to send a new patch with the fix since the patches are applied on net-next?

Regards,
Vee Khee

> -----Original Message-----
> From: Florian Fainelli <f.fainelli@gmail.com>
> Sent: Wednesday, September 16, 2020 6:54 AM
> To: David Miller <davem@davemloft.net>; Wong, Vee Khee
> <vee.khee.wong@intel.com>
> Cc: peppe.cavallaro@st.com; alexandre.torgue@st.com;
> joabreu@synopsys.com; mcoquelin.stm32@gmail.com; kuba@kernel.org;
> Joao.Pinto@synopsys.com; arnd@arndb.de; linux@armlinux.org.uk;
> netdev@vger.kernel.org; linux-stm32@st-md-mailman.stormreply.com;
> linux-arm-kernel@lists.infradead.org; linux-kernel@vger.kernel.org; Ong,
> Boon Leong <boon.leong.ong@intel.com>; Voon, Weifeng
> <weifeng.voon@intel.com>; Vijaya Balan, Sadhishkhanna
> <sadhishkhanna.vijaya.balan@intel.com>; Seow, Chen Yong
> <chen.yong.seow@intel.com>
> Subject: Re: [PATCH net-next 0/3] net: stmmac: Add ethtool support for
> get|set channels
> 
> 
> 
> On 9/15/2020 3:43 PM, David Miller wrote:
> > From: Wong Vee Khee <vee.khee.wong@intel.com>
> > Date: Tue, 15 Sep 2020 09:28:37 +0800
> >
> >> This patch set is to add support for user to get or set Tx/Rx channel
> >> via ethtool. There are two patches that fixes bug introduced on
> >> upstream in order to have the feature work.
> >>
> >> Tested on Intel Tigerlake Platform.
> >
> > Series applied, thank you.
> 
> patch #2 does not have a proper Fixes: tag format, it should be:
> 
> Fixes: cafebabed00d ("some super subject")
> --
> Florian

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [PATCH net-next 0/3] net: stmmac: Add ethtool support for get|set channels
  2020-09-15 23:59     ` Wong, Vee Khee
@ 2020-09-16  0:02       ` Florian Fainelli
  0 siblings, 0 replies; 6+ messages in thread
From: Florian Fainelli @ 2020-09-16  0:02 UTC (permalink / raw)
  To: Wong, Vee Khee, David Miller
  Cc: peppe.cavallaro, alexandre.torgue, joabreu, mcoquelin.stm32,
	kuba, Joao.Pinto, arnd, linux, netdev, linux-stm32,
	linux-arm-kernel, linux-kernel, Ong, Boon Leong, Voon, Weifeng,
	Vijaya Balan, Sadhishkhanna, Seow, Chen Yong



On 9/15/2020 4:59 PM, Wong, Vee Khee wrote:
> My bad...
> 
> Hi David Miller,

(please don't top post)

> 
> Can you help with the commit message fix or do you want to to send a new patch with the fix since the patches are applied on net-next?

It has already been applied, so this is too late, just telling you so 
you can avoid it next time. And it should be part of David's CI while 
applying patching, too.
-- 
Florian

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2020-09-16  0:03 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-09-15  1:28 [PATCH net-next 0/3] net: stmmac: Add ethtool support for get|set channels Wong Vee Khee
2020-09-15  1:28 ` [PATCH net-next 2/3] net: stmmac: Fix incorrect location to set real_num_rx|tx_queues Wong Vee Khee
2020-09-15 22:43 ` [PATCH net-next 0/3] net: stmmac: Add ethtool support for get|set channels David Miller
2020-09-15 22:54   ` Florian Fainelli
2020-09-15 23:59     ` Wong, Vee Khee
2020-09-16  0:02       ` Florian Fainelli

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).