Hi Stefan,

Did we missed the 'umac_prph_offset' constant value in 
iwm_clear_persistence_bit function? From linux code, it is read_umac_prph, not 
read_prph, so the function should be looks like this:

 int
+iwm_clear_persistence_bit(struct iwm_softc *sc)
+{
+ uint32_t hpm, wprot;
+
+ hpm = iwm_read_prph_unlocked(sc, umac_prph_offset + IWM_HPM_DEBUG);
+ if (hpm != 0xa5a5a5a0 && (hpm & IWM_HPM_PERSISTENCE_BIT)) {
+ wprot = iwm_read_prph_unlocked(sc, umac_prph_offset + 
IWM_PREG_PRPH_WPROT_9000);
+ if (wprot & IWM_PREG_WFPM_ACCESS) {
+ printf("%s: cannot clear persistence bit\n",
+     DEVNAME(sc));
+ return EPERM;
+ }
+ iwm_write_prph_unlocked(sc, umac_prph_offset + IWM_HPM_DEBUG,
+     hpm & ~IWM_HPM_PERSISTENCE_BIT);
+ }

Thank you for the big work!


------------------ Original ------------------
From: "Stefan Sperling" <[email protected]>;
Date: Tue, May 25, 2021 09:48 PM
To: "tech"<[email protected]>;
Subject: iwm(4): use new firmware images with fragattack fixes

This patch allows iwm(4) to use new firmware images which are part
of the iwm-20210512 firmware package, available via fw_update (you
need to run fw_update *before* booting with this patch).

The new firmware images were published right after the fragattacks
embargo period ended. An advisory was published by Intel:
https://www.intel.com/content/www/us/en/security-center/advisory/intel-sa-00473.html

I have tested the following cards successfully:
7265, 8265, 9260, 9560

I cannot test any other devices myself right now; help with testing this
patch would be much appreciated. It is likely that all devices will work.
But I would still prefer to see test reports for the following cards before
committing this patch:
7260, 3160, 3165, 3168, 8260

The 7260 and 3160 cards did not receive firmware updates from Intel. Which
could be good or bad news, depending on whether the devices are vulnerable
to fragattacks. The fragattacks test tools might shed light on this if you
are curious. I'd be interested to learn more if you have test results or
any other solid information regarding this.

Reply via email to