]> git.itanic.dy.fi Git - linux-stable/commit
wifi: iwlwifi: fw: fix DBGI dump
authorJohannes Berg <johannes.berg@intel.com>
Sun, 14 May 2023 09:15:48 +0000 (12:15 +0300)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 24 May 2023 16:30:18 +0000 (17:30 +0100)
commit7bb1ebccfcb2513bc7a61d6c1fc322688efa4e71
tree2f5c0c97e7bcc9eaf7a7e673ab45f575b42e4a1b
parent22a7ee202b3af3f06528a3354d68345eb7cb04e1
wifi: iwlwifi: fw: fix DBGI dump

[ Upstream commit d3ae69180bbd74bcbc03a2b6d10ed7eccbe98c23 ]

The DBGI dump is (unsurprisingly) of type DBGI, not SRAM.
This leads to bad register accesses because the union is
built differently, there's no allocation ID, and thus the
allocation ID ends up being 0x8000.

Note that this was already wrong for DRAM vs. SMEM since
they use different parts of the union, but the allocation
ID is at the same place, so it worked.

Fix all of this but set the allocation ID in a way that
the offset calculation ends up without any offset.

Fixes: 34bc27783a31 ("iwlwifi: yoyo: fix DBGI_SRAM ini dump header.")
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: Gregory Greenman <gregory.greenman@intel.com>
Link: https://lore.kernel.org/r/20230514120631.19a302ae4c65.I12272599f7c1930666157b9d5e7f81fe9ec4c421@changeid
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/net/wireless/intel/iwlwifi/fw/dbg.c