Date: Wed, 12 Feb 2025 22:17:16 GMT From: John Baldwin <jhb@FreeBSD.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org Subject: git: d6cce475cb5f - main - mtw: Pass the right pointer to the constructed command in mtw_mcu_radio Message-ID: <202502122217.51CMHGO1060001@gitrepo.freebsd.org>
next in thread | raw e-mail | index | archive | help
The branch main has been updated by jhb: URL: https://cgit.FreeBSD.org/src/commit/?id=d6cce475cb5f5c449532984e9c661596950fa26e commit d6cce475cb5f5c449532984e9c661596950fa26e Author: John Baldwin <jhb@FreeBSD.org> AuthorDate: 2025-02-12 22:13:33 +0000 Commit: John Baldwin <jhb@FreeBSD.org> CommitDate: 2025-02-12 22:17:00 +0000 mtw: Pass the right pointer to the constructed command in mtw_mcu_radio This was just using random stack garbage before. Reported by: GCC -Wunused-but-set-variable --- sys/dev/usb/wlan/if_mtw.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/dev/usb/wlan/if_mtw.c b/sys/dev/usb/wlan/if_mtw.c index ecd4693e2361..d7970af5d876 100644 --- a/sys/dev/usb/wlan/if_mtw.c +++ b/sys/dev/usb/wlan/if_mtw.c @@ -4384,7 +4384,7 @@ mtw_mcu_radio(struct mtw_softc *sc, int func, uint32_t val) cmd.r2 = htole32(val); cmd.r3 = 0; cmd.r4 = 0; - return (mtw_mcu_cmd(sc, 8, &val, sizeof(struct mtw_mcu_cmd_16))); + return (mtw_mcu_cmd(sc, 8, &cmd, sizeof(struct mtw_mcu_cmd_16))); } static void mtw_init_locked(struct mtw_softc *sc)
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?202502122217.51CMHGO1060001>