summaryrefslogtreecommitdiff
path: root/drivers/misc/issei/ham.c
AgeCommit message (Collapse)Author
2026-07-31misc: issei: check bus message length before reading the commandLinmao Li
__issei_ham_process_ham_rsp() dispatches on hdr->cmd before the message length is validated. The length comes from the firmware-owned DMA header read in issei_dma_read(), which only bounds it from above, so firmware sending a short bus message reaches the dispatch with less than sizeof(struct ham_bus_message) bytes available. For a zero-length message kmemdup() returns ZERO_SIZE_PTR, which passes the NULL check in issei_dma_read(), and the dispatch dereferences it. A length of one to three bytes gives a slab out-of-bounds read instead. Reject bus messages shorter than the header before touching it, the way the individual response handlers already validate their own length. Fixes: 7bd4b9991db20 ("issei: implement main thread and ham messages") Signed-off-by: Linmao Li <lilinmao@kylinos.cn> Link: https://patch.msgid.link/20260731025952.3505287-1-lilinmao@kylinos.cn Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2026-07-17issei: implement main thread and ham messagesAlexander Usyskin
Introduce the main thread and HECI Active Management (HAM) message handling for the ISSEI (Intel Silicon Security Engine Interface) subsystem. The main thread is responsible for managing the reset flow and processing messages, while the HAM message handling is crucial for initializing communication with the firmware and managing clients. With this implementation, the ISSEI driver is capable of performing the required initialization and management of communication between the host and the firmware. Reviewed-by: Karol Wachowski <karol.wachowski@linux.intel.com> Co-developed-by: Vitaly Lubart <lubvital@gmail.com> Signed-off-by: Vitaly Lubart <lubvital@gmail.com> Signed-off-by: Alexander Usyskin <alexander.usyskin@intel.com> Link: https://patch.msgid.link/20260513-issei-for-upstream-v1-3-f590038678f9@intel.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>