|
@@ -151,6 +151,9 @@ static CXLRetCode cmd_tunnel_management_cmd(const struct cxl_cmd *cmd,
|
|
in = (void *)payload_in;
|
|
in = (void *)payload_in;
|
|
out = (void *)payload_out;
|
|
out = (void *)payload_out;
|
|
|
|
|
|
|
|
+ if (len_in < sizeof(*in)) {
|
|
|
|
+ return CXL_MBOX_INVALID_PAYLOAD_LENGTH;
|
|
|
|
+ }
|
|
/* Enough room for minimum sized message - no payload */
|
|
/* Enough room for minimum sized message - no payload */
|
|
if (in->size < sizeof(in->ccimessage)) {
|
|
if (in->size < sizeof(in->ccimessage)) {
|
|
return CXL_MBOX_INVALID_PAYLOAD_LENGTH;
|
|
return CXL_MBOX_INVALID_PAYLOAD_LENGTH;
|