* [PATCH] net/i40e: change warning log to flow error set
@ 2018-04-08 6:22 Wei Zhao
2018-04-09 2:26 ` [PATCH v2] " Wei Zhao
0 siblings, 1 reply; 4+ messages in thread
From: Wei Zhao @ 2018-04-08 6:22 UTC (permalink / raw)
To: dev, stable; +Cc: qi.z.zhang, Wei Zhao
Ther is a specific error set fucntiong for flow
error configuration, so change to this mode.
Fixes: ecad87d22383 ("net/i40e: move RSS to flow API")
Signed-off-by: Wei Zhao <wei.zhao1@intel.com>
Tested-by: Peng Yuan <yuan.peng@intel.com>
---
drivers/net/i40e/i40e_flow.c | 22 +++++++++++++++++-----
1 file changed, 17 insertions(+), 5 deletions(-)
diff --git a/drivers/net/i40e/i40e_flow.c b/drivers/net/i40e/i40e_flow.c
index fb7ad51..2068026 100644
--- a/drivers/net/i40e/i40e_flow.c
+++ b/drivers/net/i40e/i40e_flow.c
@@ -4255,20 +4255,29 @@ i40e_flow_parse_rss_action(struct rte_eth_dev *dev,
conf_info->region[n].flowtype_num) {
if (!((rte_is_power_of_2(rss->num)) &&
rss->num <= 64)) {
- PMD_DRV_LOG(ERR, "The region sizes should be any of the following values: 1, 2, 4, 8, 16, 32, 64 as long as the "
- "total number of queues do not exceed the VSI allocation");
+ rte_flow_error_set(error, EINVAL,
+ RTE_FLOW_ERROR_TYPE_ACTION,
+ act,
+ "The region sizes should be any of the following values: 1, 2, 4, 8, 16, 32, 64 as long as the "
+ "total number of queues do not exceed the VSI allocation");
return -rte_errno;
}
if (conf_info->region[n].user_priority[n] >=
I40E_MAX_USER_PRIORITY) {
- PMD_DRV_LOG(ERR, "the user priority max index is 7");
+ rte_flow_error_set(error, EINVAL,
+ RTE_FLOW_ERROR_TYPE_ACTION,
+ act,
+ "the user priority max index is 7");
return -rte_errno;
}
if (conf_info->region[n].hw_flowtype[n] >=
I40E_FILTER_PCTYPE_MAX) {
- PMD_DRV_LOG(ERR, "the hw_flowtype or PCTYPE max index is 63");
+ rte_flow_error_set(error, EINVAL,
+ RTE_FLOW_ERROR_TYPE_ACTION,
+ act,
+ "the hw_flowtype or PCTYPE max index is 63");
return -rte_errno;
}
@@ -4281,7 +4290,10 @@ i40e_flow_parse_rss_action(struct rte_eth_dev *dev,
if (i == info->queue_region_number) {
if (i > I40E_REGION_MAX_INDEX) {
- PMD_DRV_LOG(ERR, "the queue region max index is 7");
+ rte_flow_error_set(error, EINVAL,
+ RTE_FLOW_ERROR_TYPE_ACTION,
+ act,
+ "the queue region max index is 7");
return -rte_errno;
}
--
2.7.5
^ permalink raw reply related [flat|nested] 4+ messages in thread
* [PATCH v2] net/i40e: change warning log to flow error set
2018-04-08 6:22 [PATCH] net/i40e: change warning log to flow error set Wei Zhao
@ 2018-04-09 2:26 ` Wei Zhao
2018-04-11 12:36 ` Zhang, Qi Z
0 siblings, 1 reply; 4+ messages in thread
From: Wei Zhao @ 2018-04-09 2:26 UTC (permalink / raw)
To: dev; +Cc: stable, qi.z.zhang, Wei Zhao
There is a specific error set function for flow
error configuration, so change to this mode.
Fixes: ecad87d22383 ("net/i40e: move RSS to flow API")
Signed-off-by: Wei Zhao <wei.zhao1@intel.com>
Tested-by: Peng Yuan <yuan.peng@intel.com>
---
v2:
-fix spelling mistake in comment.
---
drivers/net/i40e/i40e_flow.c | 22 +++++++++++++++++-----
1 file changed, 17 insertions(+), 5 deletions(-)
diff --git a/drivers/net/i40e/i40e_flow.c b/drivers/net/i40e/i40e_flow.c
index fb7ad51..2068026 100644
--- a/drivers/net/i40e/i40e_flow.c
+++ b/drivers/net/i40e/i40e_flow.c
@@ -4255,20 +4255,29 @@ i40e_flow_parse_rss_action(struct rte_eth_dev *dev,
conf_info->region[n].flowtype_num) {
if (!((rte_is_power_of_2(rss->num)) &&
rss->num <= 64)) {
- PMD_DRV_LOG(ERR, "The region sizes should be any of the following values: 1, 2, 4, 8, 16, 32, 64 as long as the "
- "total number of queues do not exceed the VSI allocation");
+ rte_flow_error_set(error, EINVAL,
+ RTE_FLOW_ERROR_TYPE_ACTION,
+ act,
+ "The region sizes should be any of the following values: 1, 2, 4, 8, 16, 32, 64 as long as the "
+ "total number of queues do not exceed the VSI allocation");
return -rte_errno;
}
if (conf_info->region[n].user_priority[n] >=
I40E_MAX_USER_PRIORITY) {
- PMD_DRV_LOG(ERR, "the user priority max index is 7");
+ rte_flow_error_set(error, EINVAL,
+ RTE_FLOW_ERROR_TYPE_ACTION,
+ act,
+ "the user priority max index is 7");
return -rte_errno;
}
if (conf_info->region[n].hw_flowtype[n] >=
I40E_FILTER_PCTYPE_MAX) {
- PMD_DRV_LOG(ERR, "the hw_flowtype or PCTYPE max index is 63");
+ rte_flow_error_set(error, EINVAL,
+ RTE_FLOW_ERROR_TYPE_ACTION,
+ act,
+ "the hw_flowtype or PCTYPE max index is 63");
return -rte_errno;
}
@@ -4281,7 +4290,10 @@ i40e_flow_parse_rss_action(struct rte_eth_dev *dev,
if (i == info->queue_region_number) {
if (i > I40E_REGION_MAX_INDEX) {
- PMD_DRV_LOG(ERR, "the queue region max index is 7");
+ rte_flow_error_set(error, EINVAL,
+ RTE_FLOW_ERROR_TYPE_ACTION,
+ act,
+ "the queue region max index is 7");
return -rte_errno;
}
--
2.7.5
^ permalink raw reply related [flat|nested] 4+ messages in thread
* Re: [PATCH v2] net/i40e: change warning log to flow error set
2018-04-09 2:26 ` [PATCH v2] " Wei Zhao
@ 2018-04-11 12:36 ` Zhang, Qi Z
2018-04-12 0:12 ` Zhang, Helin
0 siblings, 1 reply; 4+ messages in thread
From: Zhang, Qi Z @ 2018-04-11 12:36 UTC (permalink / raw)
To: Zhao1, Wei, dev; +Cc: stable
> -----Original Message-----
> From: Zhao1, Wei
> Sent: Monday, April 9, 2018 10:27 AM
> To: dev@dpdk.org
> Cc: stable@dpdk.org; Zhang, Qi Z <qi.z.zhang@intel.com>; Zhao1, Wei
> <wei.zhao1@intel.com>
> Subject: [PATCH v2] net/i40e: change warning log to flow error set
>
> There is a specific error set function for flow error configuration, so change to
> this mode.
>
> Fixes: ecad87d22383 ("net/i40e: move RSS to flow API")
> Signed-off-by: Wei Zhao <wei.zhao1@intel.com>
> Tested-by: Peng Yuan <yuan.peng@intel.com>
Acked-by: Qi Zhang <qi.z.zhang@intel.com>
s/ Tested-by: Peng Yuan/ Tested-by: Yuan Peng
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH v2] net/i40e: change warning log to flow error set
2018-04-11 12:36 ` Zhang, Qi Z
@ 2018-04-12 0:12 ` Zhang, Helin
0 siblings, 0 replies; 4+ messages in thread
From: Zhang, Helin @ 2018-04-12 0:12 UTC (permalink / raw)
To: Zhang, Qi Z, Zhao1, Wei, dev; +Cc: stable
> -----Original Message-----
> From: dev [mailto:dev-bounces@dpdk.org] On Behalf Of Zhang, Qi Z
> Sent: Wednesday, April 11, 2018 8:37 PM
> To: Zhao1, Wei; dev@dpdk.org
> Cc: stable@dpdk.org
> Subject: Re: [dpdk-dev] [PATCH v2] net/i40e: change warning log to flow error
> set
>
>
>
> > -----Original Message-----
> > From: Zhao1, Wei
> > Sent: Monday, April 9, 2018 10:27 AM
> > To: dev@dpdk.org
> > Cc: stable@dpdk.org; Zhang, Qi Z <qi.z.zhang@intel.com>; Zhao1, Wei
> > <wei.zhao1@intel.com>
> > Subject: [PATCH v2] net/i40e: change warning log to flow error set
> >
> > There is a specific error set function for flow error configuration,
> > so change to this mode.
> >
> > Fixes: ecad87d22383 ("net/i40e: move RSS to flow API")
> > Signed-off-by: Wei Zhao <wei.zhao1@intel.com>
> > Tested-by: Peng Yuan <yuan.peng@intel.com>
>
> Acked-by: Qi Zhang <qi.z.zhang@intel.com>
Applied to dpdk-next-net-intel, thanks!
/Helin
>
> s/ Tested-by: Peng Yuan/ Tested-by: Yuan Peng
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2018-04-12 0:12 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-04-08 6:22 [PATCH] net/i40e: change warning log to flow error set Wei Zhao
2018-04-09 2:26 ` [PATCH v2] " Wei Zhao
2018-04-11 12:36 ` Zhang, Qi Z
2018-04-12 0:12 ` Zhang, Helin
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.