In efx_mon_init() the monitor type switch only has cases when
EFSYS_OPT_MON_MCDI is enabled. DPDK builds with it set to zero, so
only the default case which jumps to the error path remains and
clang reports the assignment after the switch as unreachable.

The code is correct in the upstream libefx where the option is
enabled, so add the flag to the list of warnings already disabled
for this base code.

Signed-off-by: Stephen Hemminger <[email protected]>
---
 drivers/common/sfc_efx/base/meson.build | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/common/sfc_efx/base/meson.build 
b/drivers/common/sfc_efx/base/meson.build
index 78383a38a2..885bf837cd 100644
--- a/drivers/common/sfc_efx/base/meson.build
+++ b/drivers/common/sfc_efx/base/meson.build
@@ -80,6 +80,7 @@ else
             '-Wno-unused-variable',
             '-Wno-empty-body',
             '-Wno-unused-but-set-variable',
+            '-Wno-unreachable-code',
     ]
 endif
 
-- 
2.53.0

Reply via email to