]> git.baikalelectronics.ru Git - kernel.git/commit
iwlwifi: mei: don't rely on the size from the shared area
authorEmmanuel Grumbach <emmanuel.grumbach@intel.com>
Sun, 28 Nov 2021 12:15:09 +0000 (14:15 +0200)
committerLuca Coelho <luciano.coelho@intel.com>
Tue, 7 Dec 2021 10:58:04 +0000 (12:58 +0200)
commitd45a242d98fe98a14c1bb8c1e33343a59d63841e
tree957061d560436b55483369d0722527e24766a943
parent54e363043f8fc0467c8b3f4a20ce48a9a15b91de
iwlwifi: mei: don't rely on the size from the shared area

If CSME is compromised, it could report a bigger queue size
in the share area and make the host perform an out of bound
access.
Instead of reading the size of the queue from the shared area,
store it in the regular context which is not accessible by CSME.

While at it, fix a small typo in an error print.

Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
Link: https://lore.kernel.org/r/20211128121509.3952-1-emmanuel.grumbach@intel.com
Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
drivers/net/wireless/intel/iwlwifi/mei/main.c