Re: [PATCH] adv7604: support EDIDs up to 4 blocks

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 25/03/2021 11:27, Niklas Söderlund wrote:
> Hi Hans,
> 
> Thanks for your work.
> 
> On 2021-03-24 08:11:28 +0100, Hans Verkuil wrote:
>> While the adv7604/11/12 hardware supported EDIDs up to 4 blocks, the
>> driver didn't. This patch adds support for this. It also improves support
>> for EDIDs that do not have a Source Physical Address: in that case the
>> spa location is set to the first byte of the second block, and the
>> 'physical address' is just the two bytes at that location. This is per
>> the suggestion in the adv76xx documentation for such EDIDs.
>>
>> Tested with an adv7604 and adv7612.
> 
> I tested this on my Koelsch together with it's two buddies [1] and [2] 
> to verify that my capture tests still worked. They did not and 
> unfortunately they crashed the kernel instead. A quick check suggests 
> this patch (which I had first in my stack of the 3 patches on-top of 
> media-tree [3]) was the source. Running directly on media-tree and 
> things work as before.
> 
> I managed to reduce the TC to not even having to have a HDMI video 
> source attached just running v4l2-compliance was enough. I tested it 
> using both the latest master of v4l-utils [4] and the one I had on the 
> system since earlier [5] with the same result.
> 
> arm ~ # v4l2-compliance --version
> v4l2-compliance 1.21.0-4752, 32 bits, 32-bit time_t
> v4l2-compliance SHA: 162d4e7221ca 2021-03-25 07:35:09
> 

<snip>

>> @@ -2327,15 +2334,25 @@ static int adv76xx_set_edid(struct v4l2_subdev *sd, struct v4l2_edid *edid)
>>  				__func__, edid->pad, state->edid.present);
>>  		return 0;
>>  	}
>> -	if (edid->blocks > 2) {
>> -		edid->blocks = 2;
>> +	if (info->type == ADV7604 && edid->blocks > ADV76XX_MAX_EDID_BLOCKS) {

Urgh, remove 'info->type == ADV7604 && '. That fixes it.

It's a left-over from an older version of the patch that I forgot to remove.

Luckily v4l2-compliance tests with 256 blocks so this was caught. I should have
run v4l2-compliance myself :-(

I'll post a v2.

Regards,

	Hans

>> +		edid->blocks = ADV76XX_MAX_EDID_BLOCKS;
>>  		return -E2BIG;
>>  	}



[Index of Archives]     [Linux Input]     [Video for Linux]     [Gstreamer Embedded]     [Mplayer Users]     [Linux USB Devel]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Yosemite Backpacking]

  Powered by Linux