]> git.proxmox.com Git - mirror_ubuntu-hirsute-kernel.git/commit
Revert "flow_offload: action should not be NULL when it is referenced"
authorIdo Schimmel <idosch@nvidia.com>
Thu, 19 Aug 2021 10:58:42 +0000 (13:58 +0300)
committerStefan Bader <stefan.bader@canonical.com>
Fri, 24 Sep 2021 09:58:00 +0000 (11:58 +0200)
commit54d9349bdd4200eb1ea1a1e4c95444bd8bf02789
treededcabe58e5619b3f3d4f04a6972f25d8b4799db
parent9b75f270b1e1f6918b4e8e8e09703a46070277d7
Revert "flow_offload: action should not be NULL when it is referenced"

BugLink: https://bugs.launchpad.net/bugs/1943756
[ Upstream commit fa05bdb89b01b098aad19ec0ebc4d1cc7b11177e ]

This reverts commit 9ea3e52c5bc8bb4a084938dc1e3160643438927a.

Cited commit added a check to make sure 'action' is not NULL, but
'action' is already dereferenced before the check, when calling
flow_offload_has_one_action().

Therefore, the check does not make any sense and results in a smatch
warning:

include/net/flow_offload.h:322 flow_action_mixed_hw_stats_check() warn:
variable dereferenced before check 'action' (see line 319)

Fix by reverting this commit.

Cc: gushengxian <gushengxian@yulong.com>
Fixes: 9ea3e52c5bc8 ("flow_offload: action should not be NULL when it is referenced")
Signed-off-by: Ido Schimmel <idosch@nvidia.com>
Acked-by: Jamal Hadi Salim <jhs@mojatatu.com>
Link: https://lore.kernel.org/r/20210819105842.1315705-1-idosch@idosch.org
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
Signed-off-by: Kamal Mostafa <kamal@canonical.com>
Signed-off-by: Stefan Bader <stefan.bader@canonical.com>
include/net/flow_offload.h