Re: [PATCH 2/2] drm: adv7511: Add support for i2c_new_secondary_device

From: Kieran Bingham
Date: Wed Feb 07 2018 - 18:40:23 EST


Hi Archit,

On 07/02/18 12:33, Kieran Bingham wrote:
> Hi Archit,
>
> Thank you for your review,
>

<snip>

>>> ÂÂÂÂÂ unsigned int val;
>>> ÂÂÂÂÂ int ret;
>>> Â @@ -1153,24 +1151,35 @@ static int adv7511_probe(struct i2c_client *i2c,
>>> const struct i2c_device_id *id)
>>> ÂÂÂÂÂ if (ret)
>>> ÂÂÂÂÂÂÂÂÂ goto uninit_regulators;
>>> Â -ÂÂÂ regmap_write(adv7511->regmap, ADV7511_REG_EDID_I2C_ADDR, edid_i2c_addr);
>>> -ÂÂÂ regmap_write(adv7511->regmap, ADV7511_REG_PACKET_I2C_ADDR,
>>> -ÂÂÂÂÂÂÂÂÂÂÂÂ main_i2c_addr - 0xa);
>
>
> Packet address here is written as an offset of -0x0a, which gives 0x2f or 0x33 ... ?
>
> I think these current offsets are platform specific to a specific platform :)

I appear to be using platform specific maths specific to a non-conforming
platform or universe :-)

Sorry for the incorrect assertion here. - I mixed up 8bit and 7bit values.

The offsets are valid (when calculated correctly) - however - as per my reply to
Laurent - I believe the patch which determined the offsets was using the wrong
base :).

Also - due to a hardware issue on the ADV7511 - the Wheat (as the only known
user of two chips on the same bus) will need to be updated to ensure the current
assignments don't conflict.

--
Kieran