[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAMFSARfOYWy0a_iZyuh9e8++xHdAYXcs2pT1_yJaJ60tHR17xQ@mail.gmail.com>
Date: Mon, 29 Apr 2024 17:43:16 -0700
From: Jameson Thies <jthies@...gle.com>
To: Greg Kroah-Hartman <gregkh@...uxfoundation.org>
Cc: Markus Elfring <Markus.Elfring@....de>,
Abhishek Pandit-Subedi <abhishekpandit@...omium.org>, linux-usb@...r.kernel.org,
kernel-janitors@...r.kernel.org,
Heikki Krogerus <heikki.krogerus@...ux.intel.com>, LKML <linux-kernel@...r.kernel.org>,
Benson Leung <bleung@...gle.com>, Bjorn Andersson <andersson@...nel.org>,
Dmitry Baryshkov <dmitry.baryshkov@...aro.org>, Fabrice Gasnier <fabrice.gasnier@...s.st.com>,
Hans de Goede <hdegoede@...hat.com>, Neil Armstrong <neil.armstrong@...aro.org>,
Prashant Malani <pmalani@...omium.org>, Rajaram Regupathy <rajaram.regupathy@...el.com>,
Saranya Gopal <saranya.gopal@...el.com>,
Uwe Kleine-König <u.kleine-koenig@...gutronix.de>
Subject: Re: [PATCH v2 1/4] usb: typec: ucsi: Fix null deref in trace
Hi Dmitry,
what are your thoughts on Abhishek's comment? I think we should
attempt to register the alternate mode when CONFIG_TYPEC_DP_ALTMODE is
not enabled. It would give us a more accurate representation of the
partner in user space. I understand your point about ignoring a
potential EOPNOTSUPP response from the non-stub function. What if we
leave ucsi.c alone, and replace the stub function's null return with a
call to typec_port_register_altmode(). That would register DP altmode
as an unsupported mode when CONFIG_TYPEC_DP_ALTMODE is not enabled,
and fix the null pointer dereference. But, it won't change behavior
when CONFIG_TYPEC_DP_ALTMODE is enabled.
Hi Markus,
thanks for your feedback. I'll update the commit message to say "null
pointer dereference" when I upload a v3 series.
Thanks,
Jameson
Powered by blists - more mailing lists