* [PATCH v2 1/5] net/ice: detect stopping a flow-director queue twice
[not found] ` <20241015151957.1413286-1-bruce.richardson@intel.com>
@ 2024-10-15 15:19 ` Bruce Richardson
0 siblings, 0 replies; 3+ messages in thread
From: Bruce Richardson @ 2024-10-15 15:19 UTC (permalink / raw)
To: dev; +Cc: Bruce Richardson, stable, Stephen Hemminger
If the flow-director queue is stopped at some point during the running
of an application, the shutdown procedure for the port issues an error
as it tries to stop the queue a second time, and fails to do so. We can
eliminate this error by setting the tail-register pointer to NULL on
stop, and checking for that condition in subsequent stop calls. Since
the register pointer is set on start, any restarting of the queue will
allow a stop call to progress as normal.
Fixes: 84dc7a95a2d3 ("net/ice: enable flow director engine")
Cc: stable@dpdk.org
Signed-off-by: Bruce Richardson <bruce.richardson@intel.com>
Acked-by: Stephen Hemminger <stephen@networkplumber.org>
---
drivers/net/ice/ice_rxtx.c | 5 +++++
1 file changed, 5 insertions(+)
diff --git a/drivers/net/ice/ice_rxtx.c b/drivers/net/ice/ice_rxtx.c
index d2f9edc221..024d97cb46 100644
--- a/drivers/net/ice/ice_rxtx.c
+++ b/drivers/net/ice/ice_rxtx.c
@@ -1139,6 +1139,10 @@ ice_fdir_tx_queue_stop(struct rte_eth_dev *dev, uint16_t tx_queue_id)
tx_queue_id);
return -EINVAL;
}
+ if (txq->qtx_tail == NULL) {
+ PMD_DRV_LOG(INFO, "TX queue %u not started", tx_queue_id);
+ return 0;
+ }
vsi = txq->vsi;
q_ids[0] = txq->reg_idx;
@@ -1153,6 +1157,7 @@ ice_fdir_tx_queue_stop(struct rte_eth_dev *dev, uint16_t tx_queue_id)
}
txq->tx_rel_mbufs(txq);
+ txq->qtx_tail = NULL;
return 0;
}
--
2.43.0
^ permalink raw reply [flat|nested] 3+ messages in thread
* [PATCH v3 1/4] net/ice: detect stopping a flow-director queue twice
[not found] ` <20241018143822.2784548-1-bruce.richardson@intel.com>
@ 2024-10-18 14:38 ` Bruce Richardson
0 siblings, 0 replies; 3+ messages in thread
From: Bruce Richardson @ 2024-10-18 14:38 UTC (permalink / raw)
To: dev; +Cc: Bruce Richardson, stable, Stephen Hemminger
If the flow-director queue is stopped at some point during the running
of an application, the shutdown procedure for the port issues an error
as it tries to stop the queue a second time, and fails to do so. We can
eliminate this error by setting the tail-register pointer to NULL on
stop, and checking for that condition in subsequent stop calls. Since
the register pointer is set on start, any restarting of the queue will
allow a stop call to progress as normal.
Fixes: 84dc7a95a2d3 ("net/ice: enable flow director engine")
Cc: stable@dpdk.org
Signed-off-by: Bruce Richardson <bruce.richardson@intel.com>
Acked-by: Stephen Hemminger <stephen@networkplumber.org>
---
drivers/net/ice/ice_rxtx.c | 5 +++++
1 file changed, 5 insertions(+)
diff --git a/drivers/net/ice/ice_rxtx.c b/drivers/net/ice/ice_rxtx.c
index d2f9edc221..024d97cb46 100644
--- a/drivers/net/ice/ice_rxtx.c
+++ b/drivers/net/ice/ice_rxtx.c
@@ -1139,6 +1139,10 @@ ice_fdir_tx_queue_stop(struct rte_eth_dev *dev, uint16_t tx_queue_id)
tx_queue_id);
return -EINVAL;
}
+ if (txq->qtx_tail == NULL) {
+ PMD_DRV_LOG(INFO, "TX queue %u not started", tx_queue_id);
+ return 0;
+ }
vsi = txq->vsi;
q_ids[0] = txq->reg_idx;
@@ -1153,6 +1157,7 @@ ice_fdir_tx_queue_stop(struct rte_eth_dev *dev, uint16_t tx_queue_id)
}
txq->tx_rel_mbufs(txq);
+ txq->qtx_tail = NULL;
return 0;
}
--
2.43.0
^ permalink raw reply [flat|nested] 3+ messages in thread
* [PATCH v4 1/4] net/ice: detect stopping a flow-director queue twice
[not found] ` <20241022163944.3564662-1-bruce.richardson@intel.com>
@ 2024-10-22 16:39 ` Bruce Richardson
0 siblings, 0 replies; 3+ messages in thread
From: Bruce Richardson @ 2024-10-22 16:39 UTC (permalink / raw)
To: dev; +Cc: Bruce Richardson, stable, Stephen Hemminger
If the flow-director queue is stopped at some point during the running
of an application, the shutdown procedure for the port issues an error
as it tries to stop the queue a second time, and fails to do so. We can
eliminate this error by setting the tail-register pointer to NULL on
stop, and checking for that condition in subsequent stop calls. Since
the register pointer is set on start, any restarting of the queue will
allow a stop call to progress as normal.
Fixes: 84dc7a95a2d3 ("net/ice: enable flow director engine")
Cc: stable@dpdk.org
Signed-off-by: Bruce Richardson <bruce.richardson@intel.com>
Acked-by: Stephen Hemminger <stephen@networkplumber.org>
---
drivers/net/ice/ice_rxtx.c | 5 +++++
1 file changed, 5 insertions(+)
diff --git a/drivers/net/ice/ice_rxtx.c b/drivers/net/ice/ice_rxtx.c
index d2f9edc221..024d97cb46 100644
--- a/drivers/net/ice/ice_rxtx.c
+++ b/drivers/net/ice/ice_rxtx.c
@@ -1139,6 +1139,10 @@ ice_fdir_tx_queue_stop(struct rte_eth_dev *dev, uint16_t tx_queue_id)
tx_queue_id);
return -EINVAL;
}
+ if (txq->qtx_tail == NULL) {
+ PMD_DRV_LOG(INFO, "TX queue %u not started", tx_queue_id);
+ return 0;
+ }
vsi = txq->vsi;
q_ids[0] = txq->reg_idx;
@@ -1153,6 +1157,7 @@ ice_fdir_tx_queue_stop(struct rte_eth_dev *dev, uint16_t tx_queue_id)
}
txq->tx_rel_mbufs(txq);
+ txq->qtx_tail = NULL;
return 0;
}
--
2.43.0
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2024-10-22 16:39 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
[not found] <20241009170822.344716-1-bruce.richardson@intel.com>
[not found] ` <20241015151957.1413286-1-bruce.richardson@intel.com>
2024-10-15 15:19 ` [PATCH v2 1/5] net/ice: detect stopping a flow-director queue twice Bruce Richardson
[not found] ` <20241018143822.2784548-1-bruce.richardson@intel.com>
2024-10-18 14:38 ` [PATCH v3 1/4] " Bruce Richardson
[not found] ` <20241022163944.3564662-1-bruce.richardson@intel.com>
2024-10-22 16:39 ` [PATCH v4 " Bruce Richardson
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).