mirror of
https://github.com/outbackdingo/mt76.git
synced 2026-10-24 13:26:48 +00:00
Move the initialization of 'dev' before the error path that uses it.
This fixes the compiler warning:
drivers/net/wireless/mediatek/mt76/mt7921/pci.c:347:6: warning:
variable 'dev' is used uninitialized whenever 'if' condition is true
Fixes: 0d56655a74ef ("wifi: mt76: mt7921: fix resource leak in probe error path")
Reported-by: kernel test robot <[email protected]>
Closes: https://lore.kernel.org/oe-kbuild-all/[email protected]/
Signed-off-by: Hongling Zeng <[email protected]>
Link: https://patch.msgid.link/[email protected]
Signed-off-by: Felix Fietkau <[email protected]>