From 2d510fef8ddc82e663cf80cea025cdefe7b326b8 Mon Sep 17 00:00:00 2001 From: Sam Hurst Date: Mon, 6 Feb 2023 19:20:53 -0800 Subject: [PATCH] usb_c: Notify DPM of Unsupported message reception Notify the Device Policy Manager when an unsupported message is received. Signed-off-by: Sam Hurst --- subsys/usb/usb_c/usbc_pe_common.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/subsys/usb/usb_c/usbc_pe_common.c b/subsys/usb/usb_c/usbc_pe_common.c index 2ccc450716a..560ff2d27e0 100644 --- a/subsys/usb/usb_c/usbc_pe_common.c +++ b/subsys/usb/usb_c/usbc_pe_common.c @@ -898,6 +898,9 @@ static void pe_send_not_supported_entry(void *obj) LOG_INF("PE_Not_Supported"); + /* Notify the Device Policy Manager of unsupported message reception */ + policy_notify(dev, MSG_NOT_SUPPORTED_RECEIVED); + /* Request the Protocol Layer to send a Not_Supported or Reject Message. */ if (prl_get_rev(dev, PD_PACKET_SOP) > PD_REV20) { pe_send_ctrl_msg(dev, PD_PACKET_SOP, PD_CTRL_NOT_SUPPORTED);