mirror of
https://github.com/edk2-porting/linux-next.git
synced 2024-12-29 15:43:59 +08:00
735bb39ca3
With gcc-7, I got a new warning for this driver: wilc1000/linux_wlan.c: In function 'wilc_netdev_cleanup': wilc1000/linux_wlan.c:1224:15: error: 'vif[1]' may be used uninitialized in this function [-Werror=maybe-uninitialized] wilc1000/linux_wlan.c:1224:15: error: 'vif[0]' may be used uninitialized in this function [-Werror=maybe-uninitialized] A closer look at the function reveals that it's more complex than it needs to be, given that based on how the device is created we always get netdev_priv(vif->ndev) == vif Based on this assumption, I found a few other places in the same file that can be simplified. That code appears to be a relic from times when the assumption above was not valid. Signed-off-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> |
||
---|---|---|
.. | ||
coreconfigurator.c | ||
coreconfigurator.h | ||
host_interface.c | ||
host_interface.h | ||
Kconfig | ||
linux_mon.c | ||
linux_wlan.c | ||
Makefile | ||
TODO | ||
wilc_debugfs.c | ||
wilc_sdio.c | ||
wilc_spi.c | ||
wilc_wfi_cfgoperations.c | ||
wilc_wfi_cfgoperations.h | ||
wilc_wfi_netdevice.h | ||
wilc_wlan_cfg.c | ||
wilc_wlan_cfg.h | ||
wilc_wlan_if.h | ||
wilc_wlan.c | ||
wilc_wlan.h |