mirror of
https://github.com/torvalds/linux.git
synced 2024-11-22 20:22:09 +00:00
wifi: rt2x00: silence sparse warnings
Clearly writing __le32 was intended here, so just put the right casts into the code to silence sparse about it. Signed-off-by: Johannes Berg <johannes.berg@intel.com> Signed-off-by: Kalle Valo <kvalo@kernel.org> Link: https://msgid.link/20240223114023.ce0c714124e9.I2b5710b761f63522574fbe7654d37151c31e0b77@changeid
This commit is contained in:
parent
17672ced7d
commit
e063243036
@ -10946,13 +10946,13 @@ static void rt2800_efuse_read(struct rt2x00_dev *rt2x00dev, unsigned int i)
|
||||
/* Apparently the data is read from end to start */
|
||||
reg = rt2800_register_read_lock(rt2x00dev, efuse_data3_reg);
|
||||
/* The returned value is in CPU order, but eeprom is le */
|
||||
*(u32 *)&rt2x00dev->eeprom[i] = cpu_to_le32(reg);
|
||||
*(__le32 *)&rt2x00dev->eeprom[i] = cpu_to_le32(reg);
|
||||
reg = rt2800_register_read_lock(rt2x00dev, efuse_data2_reg);
|
||||
*(u32 *)&rt2x00dev->eeprom[i + 2] = cpu_to_le32(reg);
|
||||
*(__le32 *)&rt2x00dev->eeprom[i + 2] = cpu_to_le32(reg);
|
||||
reg = rt2800_register_read_lock(rt2x00dev, efuse_data1_reg);
|
||||
*(u32 *)&rt2x00dev->eeprom[i + 4] = cpu_to_le32(reg);
|
||||
*(__le32 *)&rt2x00dev->eeprom[i + 4] = cpu_to_le32(reg);
|
||||
reg = rt2800_register_read_lock(rt2x00dev, efuse_data0_reg);
|
||||
*(u32 *)&rt2x00dev->eeprom[i + 6] = cpu_to_le32(reg);
|
||||
*(__le32 *)&rt2x00dev->eeprom[i + 6] = cpu_to_le32(reg);
|
||||
|
||||
mutex_unlock(&rt2x00dev->csr_mutex);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user