netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH net] net/sched: taprio: Fix init procedure
@ 2021-07-30 16:53 Yannick Vignon
  2021-08-02 10:50 ` patchwork-bot+netdevbpf
  0 siblings, 1 reply; 2+ messages in thread
From: Yannick Vignon @ 2021-07-30 16:53 UTC (permalink / raw)
  To: yannick.vignon, sebastien.laveze, Vinicius Costa Gomes,
	Jamal Hadi Salim, Cong Wang, Jiri Pirko, David S. Miller,
	Jakub Kicinski, netdev, Joakim Zhang, Vladimir Oltean,
	Xiaoliang Yang
  Cc: Yannick Vignon

From: Yannick Vignon <yannick.vignon@nxp.com>

Commit 13511704f8d759 ("net: taprio offload: enforce qdisc to netdev queue mapping")
resulted in duplicate entries in the qdisc hash.
While this did not impact the overall operation of the qdisc and taprio
code paths, it did result in an infinite loop when dumping the qdisc
properties, at least on one target (NXP LS1028 ARDB).
Removing the duplicate call to qdisc_hash_add() solves the problem.

Signed-off-by: Yannick Vignon <yannick.vignon@nxp.com>
Fixes: 13511704f8d759 ("net: taprio offload: enforce qdisc to netdev queue mapping")
---
 net/sched/sch_taprio.c | 2 --
 1 file changed, 2 deletions(-)

diff --git a/net/sched/sch_taprio.c b/net/sched/sch_taprio.c
index 07b30d0601d7..9c79374457a0 100644
--- a/net/sched/sch_taprio.c
+++ b/net/sched/sch_taprio.c
@@ -1739,8 +1739,6 @@ static void taprio_attach(struct Qdisc *sch)
 		if (FULL_OFFLOAD_IS_ENABLED(q->flags)) {
 			qdisc->flags |= TCQ_F_ONETXQUEUE | TCQ_F_NOPARENT;
 			old = dev_graft_qdisc(qdisc->dev_queue, qdisc);
-			if (ntx < dev->real_num_tx_queues)
-				qdisc_hash_add(qdisc, false);
 		} else {
 			old = dev_graft_qdisc(qdisc->dev_queue, sch);
 			qdisc_refcount_inc(sch);
-- 
2.25.1


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

* Re: [PATCH net] net/sched: taprio: Fix init procedure
  2021-07-30 16:53 [PATCH net] net/sched: taprio: Fix init procedure Yannick Vignon
@ 2021-08-02 10:50 ` patchwork-bot+netdevbpf
  0 siblings, 0 replies; 2+ messages in thread
From: patchwork-bot+netdevbpf @ 2021-08-02 10:50 UTC (permalink / raw)
  To: Yannick Vignon
  Cc: sebastien.laveze, vinicius.gomes, jhs, xiyou.wangcong, jiri,
	davem, kuba, netdev, qiangqing.zhang, olteanv, xiaoliang.yang_1,
	yannick.vignon

Hello:

This patch was applied to netdev/net.git (refs/heads/master):

On Fri, 30 Jul 2021 18:53:21 +0200 you wrote:
> From: Yannick Vignon <yannick.vignon@nxp.com>
> 
> Commit 13511704f8d759 ("net: taprio offload: enforce qdisc to netdev queue mapping")
> resulted in duplicate entries in the qdisc hash.
> While this did not impact the overall operation of the qdisc and taprio
> code paths, it did result in an infinite loop when dumping the qdisc
> properties, at least on one target (NXP LS1028 ARDB).
> Removing the duplicate call to qdisc_hash_add() solves the problem.
> 
> [...]

Here is the summary with links:
  - [net] net/sched: taprio: Fix init procedure
    https://git.kernel.org/netdev/net/c/ebca25ead071

You are awesome, thank you!
--
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/patchwork/pwbot.html



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

end of thread, other threads:[~2021-08-02 10:50 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-07-30 16:53 [PATCH net] net/sched: taprio: Fix init procedure Yannick Vignon
2021-08-02 10:50 ` patchwork-bot+netdevbpf

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).