All of lore.kernel.org
 help / color / mirror / Atom feed
* [Intel-wired-lan] Clang warning in drivers/net/ethernet/intel/igc/igc_ethtool.c
@ 2019-02-08  5:09 ` Nathan Chancellor
  0 siblings, 0 replies; 8+ messages in thread
From: Nathan Chancellor @ 2019-02-08  5:09 UTC (permalink / raw)
  To: intel-wired-lan

Hi all,

After commit 8c5ad0dae93c ("igc: Add ethtool support"), Clang warns:

drivers/net/ethernet/intel/igc/igc_ethtool.c:9:19: warning: variable 'igc_priv_flags_strings' is not needed and will not be emitted [-Wunneeded-internal-declaration]
static const char igc_priv_flags_strings[][ETH_GSTRING_LEN] = {
                  ^
1 warning generated.

igc_priv_flags_strings is only used in an ARRAY_SIZE macro, which is a
compile time evaluation, so no reference to it is being emitted in the
final assembly. Is it actually needed and was forgotten to be used
somewhere or could it be eliminated so that Clang no longer warns?

Thanks,
Nathan

^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2019-03-01 20:40 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2019-02-08  5:09 [Intel-wired-lan] Clang warning in drivers/net/ethernet/intel/igc/igc_ethtool.c Nathan Chancellor
2019-02-08  5:09 ` Nathan Chancellor
2019-02-08 14:34 ` [Intel-wired-lan] " Michal Kubecek
2019-02-08 14:34   ` Michal Kubecek
2019-03-01 18:28   ` [Intel-wired-lan] " Nick Desaulniers
2019-03-01 18:28     ` Nick Desaulniers
2019-03-01 20:40     ` [Intel-wired-lan] " Michal Kubecek
2019-03-01 20:40       ` Michal Kubecek

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.