[dpdk-dev] [PATCH v2 06/12] net/bnxt: combine default and regular flows
Ferruh Yigit
ferruh.yigit at amd.com
Tue May 24 17:31:54 CEST 2022
On 10/10/2020 5:11 AM, Ajit Khaparde wrote:
> From: Kishore Padmanabha <kishore.padmanabha at broadcom.com>
>
> The default and regular flows are stored in the same flow table
> instead of different flow tables. This should help code reuse
> and reducing the number of allocations.
> So combine default and regular flows in flow database.
>
> Signed-off-by: Kishore Padmanabha <kishore.padmanabha at broadcom.com>
> Reviewed-by: Mike Baucom <michael.baucom at broadcom.com>
> Reviewed-by: Ajit Khaparde <ajit.khaparde at broadcom.com>
<...>
> *
> * returns 0 on success or negative number on failure
> */
> -int32_t ulp_flow_db_flush_flows(struct bnxt_ulp_context *ulp_ctx,
> - uint32_t idx)
> +int32_t
> +ulp_flow_db_flush_flows(struct bnxt_ulp_context *ulp_ctx,
> + enum bnxt_ulp_fdb_type flow_type)
Above change is causing build error [1] because the function declaration
[2] differs from definition. Reproduced by latest gcc [3].
[1]
../drivers/net/bnxt/tf_ulp/ulp_flow_db.c:962:1: error: conflicting types
for ‘ulp_flow_db_flush_flows’ due to enum/integer mismatch;
have ‘int32_t(struct bnxt_ulp_context *, enum bnxt_ulp_fdb_type)’
{aka ‘int(struct bnxt_ulp_context *, enum bnxt_ulp_fdb_type)’}
[-Werror=enum-int-mismatch]
962 | ulp_flow_db_flush_flows(struct bnxt_ulp_context *ulp_ctx,
| ^~~~~~~~~~~~~~~~~~~~~~~
In file included from ../drivers/net/bnxt/tf_ulp/ulp_flow_db.c:12:
../drivers/net/bnxt/tf_ulp/ulp_flow_db.h:211:1: note: previous
declaration of ‘ulp_flow_db_flush_flows’ with type ‘int32_t(struct
bnxt_ulp_context *,uint32_t)’ {aka ‘int(struct bnxt_ulp_context *,
unsigned int)’}
211 | ulp_flow_db_flush_flows(struct bnxt_ulp_context *ulp_ctx,
| ^~~~~~~~~~~~~~~~~~~~~~~
[2]
> +ulp_flow_db_flush_flows(struct bnxt_ulp_context *ulp_ctx,
> + uint32_t idx);
>
[3]
gcc 13.0.0 "gcc (GCC) 13.0.0 20220524 (experimental)")
More information about the dev
mailing list