Skip to content

Commit da994db

Browse files
quic-bjorandeandersson
authored andcommitted
remoteproc: sysmon: Correct subsys_name_len type in QMI request
The QMI message encoder has up until recently read a single byte (as elem_size == 1), but with the introduction of big endian support it's become apparent that this field is expected to be a full u32 - regardless of the size of the length in the encoded message (which is what elem_size specifies). The result is that the encoder now reads past the length byte and rejects the unreasonably large length formed when including the following 3 bytes from the subsys_name array. Fix this by changing to the expected type. Fixes: 1fb82ee ("remoteproc: qcom: Introduce sysmon") Signed-off-by: Bjorn Andersson <[email protected]> Reviewed-by: Chris Lew <[email protected]> Link: https://lore.kernel.org/r/20260220-qmi-encode-invalid-length-v2-1-5674be35ab29@oss.qualcomm.com Signed-off-by: Bjorn Andersson <[email protected]>
1 parent f9b8885 commit da994db

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

drivers/remoteproc/qcom_sysmon.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -203,7 +203,7 @@ static const struct qmi_elem_info ssctl_shutdown_resp_ei[] = {
203203
};
204204

205205
struct ssctl_subsys_event_req {
206-
u8 subsys_name_len;
206+
u32 subsys_name_len;
207207
char subsys_name[SSCTL_SUBSYS_NAME_LENGTH];
208208
u32 event;
209209
u8 evt_driven_valid;

0 commit comments

Comments
 (0)