lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <Y8AKEZzbxyYaYjg1@kuha.fi.intel.com>
Date:   Thu, 12 Jan 2023 15:24:33 +0200
From:   Heikki Krogerus <heikki.krogerus@...ux.intel.com>
To:     Prashant Malani <pmalani@...omium.org>
Cc:     linux-kernel@...r.kernel.org, linux-usb@...r.kernel.org,
        bleung@...omium.org,
        Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
        Guillaume Ranquet <granquet@...libre.com>,
        Macpaul Lin <macpaul.lin@...iatek.com>,
        Pablo Sun <pablo.sun@...iatek.com>
Subject: Re: [PATCH 3/3] usb: typec: altmodes/displayport: Use proper macro
 for pin assignment check

On Wed, Jan 11, 2023 at 02:05:43AM +0000, Prashant Malani wrote:
> While looking at the DP configuration VDO to determine the peripheral
> configuration, the spec (Table 8-5: DisplayPort Configurations, VESA
> DisplayPort Alt Mode Standard v2.0) lists the options as "UFP_U as a DP
> Source/Sink Device".
> 
> So, use the correct macro while performing this check. Effectively it's
> the same as the existing code, but the proposed macro describes the
> state a little better.
> 
> No functional changes introduced.
> 
> Cc: Heikki Krogerus <heikki.krogerus@...ux.intel.com>
> Signed-off-by: Prashant Malani <pmalani@...omium.org>

Reviewed-by: Heikki Krogerus <heikki.krogerus@...ux.intel.com>

> ---
>  drivers/usb/typec/altmodes/displayport.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/usb/typec/altmodes/displayport.c b/drivers/usb/typec/altmodes/displayport.c
> index c0d65c93cefe..746bfbf3d557 100644
> --- a/drivers/usb/typec/altmodes/displayport.c
> +++ b/drivers/usb/typec/altmodes/displayport.c
> @@ -426,7 +426,7 @@ static const char * const pin_assignments[] = {
>   */
>  static u8 get_current_pin_assignments(struct dp_altmode *dp)
>  {
> -	if (DP_CONF_CURRENTLY(dp->data.conf) == DP_CONF_DFP_D)
> +	if (DP_CONF_CURRENTLY(dp->data.conf) == DP_CONF_UFP_U_AS_DFP_D)
>  		return DP_CAP_PIN_ASSIGN_DFP_D(dp->alt->vdo);
>  	else
>  		return DP_CAP_PIN_ASSIGN_UFP_D(dp->alt->vdo);
> -- 
> 2.39.0.314.g84b9a713c41-goog

-- 
heikki

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ