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] [thread-next>] [day] [month] [year] [list]
Message-Id: <D6G3H3AXXVAJ.3F1WMBTWLX2KV@cknow.org>
Date: Fri, 20 Dec 2024 01:17:42 +0100
From: "Diederik de Haas" <didi.debian@...ow.org>
To: "Dmitry Baryshkov" <dmitry.baryshkov@...aro.org>, "Damon Ding"
 <damon.ding@...k-chips.com>
Cc: <robh@...nel.org>, <conor+dt@...nel.org>, <algea.cao@...k-chips.com>,
 <rfoss@...nel.org>, <heiko@...ech.de>, <devicetree@...r.kernel.org>,
 <linux-phy@...ts.infradead.org>, <linux-kernel@...r.kernel.org>,
 <sebastian.reichel@...labora.com>, <dri-devel@...ts.freedesktop.org>,
 <hjc@...k-chips.com>, <kever.yang@...k-chips.com>,
 <linux-rockchip@...ts.infradead.org>, <vkoul@...nel.org>,
 <andy.yan@...k-chips.com>, <krzk+dt@...nel.org>,
 <linux-arm-kernel@...ts.infradead.org>, <l.stach@...gutronix.de>
Subject: Re: [PATCH v3 07/15] drm/bridge: analogix_dp: Add support for phy
 configuration.

On Fri Dec 20, 2024 at 1:13 AM CET, Dmitry Baryshkov wrote:
> On Thu, Dec 19, 2024 at 04:05:56PM +0800, Damon Ding wrote:
> >  void analogix_dp_get_lane_count(struct analogix_dp_device *dp, u32 *count)
> > @@ -546,10 +575,37 @@ void analogix_dp_get_lane_count(struct analogix_dp_device *dp, u32 *count)
> >  void analogix_dp_set_lane_link_training(struct analogix_dp_device *dp)
> >  {
> >  	u8 lane;
> > +	int ret;
> >  
> >  	for (lane = 0; lane < dp->link_train.lane_count; lane++)
> >  		writel(dp->link_train.training_lane[lane],
> >  		       dp->reg_base + ANALOGIX_DP_LN0_LINK_TRAINING_CTL + 4 * lane);
> > +
> > +	if (dp->phy) {
> > +		union phy_configure_opts phy_cfg = {0};
> > +
> > +		for (lane = 0; lane < dp->link_train.lane_count; lane++) {
> > +			u8 training_lane = dp->link_train.training_lane[lane];
> > +			u8 vs, pe;
> > +
> > +			vs = (training_lane & DP_TRAIN_VOLTAGE_SWING_MASK) >>
> > +			     DP_TRAIN_VOLTAGE_SWING_SHIFT;
> > +			pe = (training_lane & DP_TRAIN_PRE_EMPHASIS_MASK) >>
> > +			     DP_TRAIN_PRE_EMPHASIS_SHIFT;
> > +			phy_cfg.dp.voltage[lane] = vs;
> > +			phy_cfg.dp.pre[lane] = pe;
> > +		}
> > +
> > +		phy_cfg.dp.lanes = dp->link_train.lane_count;
> > +		phy_cfg.dp.link_rate =
> > +			drm_dp_bw_code_to_link_rate(dp->link_train.link_rate) / 100;
>
> This two should not be necessary, please drop them.

This too or These two (statements)?

> > +		phy_cfg.dp.set_voltages = true;
> > +		ret = phy_configure(dp->phy, &phy_cfg);
> > +		if (ret && ret != -EOPNOTSUPP) {
> > +			dev_err(dp->dev, "%s: phy_configure() failed: %d\n", __func__, ret);
> > +			return;
> > +		}
> > +	}
> >  }
> >  
> >  u32 analogix_dp_get_lane_link_training(struct analogix_dp_device *dp, u8 lane)
> > -- 
> > 2.34.1
> > 


Download attachment "signature.asc" of type "application/pgp-signature" (229 bytes)

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ