mirror of
https://github.com/edk2-porting/linux-next.git
synced 2024-12-20 19:23:57 +08:00
nfp: flower-ct: fix error return code in nfp_fl_ct_add_offload()
If nfp_tunnel_add_ipv6_off() fails, it should return error code
in nfp_fl_ct_add_offload().
Fixes: 5a2b930416
("nfp: flower-ct: compile match sections of flow_payload")
Reported-by: Hulk Robot <hulkci@huawei.com>
Signed-off-by: Yang Yingliang <yangyingliang@huawei.com>
Signed-off-by: Louis Peens <louis.peens@corigine.com>
Reviewed-by: Simon Horman <simon.horman@corigine.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
parent
3bdc70669e
commit
d80f6d6665
@ -710,8 +710,10 @@ static int nfp_fl_ct_add_offload(struct nfp_fl_nft_tc_merge *m_entry)
|
||||
dst = &gre_match->ipv6.dst;
|
||||
|
||||
entry = nfp_tunnel_add_ipv6_off(priv->app, dst);
|
||||
if (!entry)
|
||||
if (!entry) {
|
||||
err = -ENOMEM;
|
||||
goto ct_offload_err;
|
||||
}
|
||||
|
||||
flow_pay->nfp_tun_ipv6 = entry;
|
||||
} else {
|
||||
@ -760,8 +762,10 @@ static int nfp_fl_ct_add_offload(struct nfp_fl_nft_tc_merge *m_entry)
|
||||
dst = &udp_match->ipv6.dst;
|
||||
|
||||
entry = nfp_tunnel_add_ipv6_off(priv->app, dst);
|
||||
if (!entry)
|
||||
if (!entry) {
|
||||
err = -ENOMEM;
|
||||
goto ct_offload_err;
|
||||
}
|
||||
|
||||
flow_pay->nfp_tun_ipv6 = entry;
|
||||
} else {
|
||||
|
Loading…
Reference in New Issue
Block a user