From: Dan Carpenter <error27@gmail.com>
To: shayne.chen@mediatek.com
Cc: linux-wireless@vger.kernel.org, linux-mediatek@lists.infradead.org
Subject: [bug report] wifi: mt76: mt7996: add driver for MediaTek Wi-Fi 7 (802.11be) devices
Date: Sat, 3 Dec 2022 15:54:53 +0300 [thread overview]
Message-ID: <Y4tHHYLPX/6x6ztK@kili> (raw)
Hello Shayne Chen,
The patch 98686cd21624: "wifi: mt76: mt7996: add driver for MediaTek
Wi-Fi 7 (802.11be) devices" from Nov 22, 2022, leads to the following
Smatch static checker warning:
drivers/net/wireless/mediatek/mt76/mt7996/debugfs.c:657 mt7996_rf_regval_set()
warn: passing casted pointer '&val' to 'mt7996_mcu_rf_regval()' 64 vs 32.
drivers/net/wireless/mediatek/mt76/mt7996/debugfs.c
652 static int
653 mt7996_rf_regval_set(void *data, u64 val)
654 {
655 struct mt7996_dev *dev = data;
656
--> 657 return mt7996_mcu_rf_regval(dev, dev->mt76.debugfs_reg, (u32 *)&val, true);
^^^^^^^^^^^
This code only "works" on little endian systems. You have to do
something like:
u32 u32_val = val;
return mt7996_mcu_rf_regval(dev, dev->mt76.debugfs_reg, &u32_val, true);
658 }
regards,
dan carpenter
next reply other threads:[~2022-12-03 12:55 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-12-03 12:54 Dan Carpenter [this message]
-- strict thread matches above, loose matches on Subject: below --
2022-12-03 12:55 [bug report] wifi: mt76: mt7996: add driver for MediaTek Wi-Fi 7 (802.11be) devices Dan Carpenter
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=Y4tHHYLPX/6x6ztK@kili \
--to=error27@gmail.com \
--cc=linux-mediatek@lists.infradead.org \
--cc=linux-wireless@vger.kernel.org \
--cc=shayne.chen@mediatek.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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.