Re: [PATCH] media: ov5640: fix frame interval enumeration

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

 



Hi Mauro,

Thanks for review, I've just sent a v2 to rearrange code as per your 
suggestion and also add a NULL test case for mode even if this should 
not happen.

Best regards,
Hugues.

On 03/08/2018 11:46 AM, Mauro Carvalho Chehab wrote:
> Em Thu, 8 Mar 2018 07:39:09 -0300
> Mauro Carvalho Chehab <mchehab@xxxxxxxxxx> escreveu:
> 
>> Also, if this function starts returning NULL, I suspect that you also
>> need to change ov5640_s_frame_interval(), as currently it is called
>> at ov5640_s_frame_interval() as:
>>
>> 	sensor->current_mode = ov5640_find_mode(sensor, frame_rate, mode->width,
>> 						mode->height, true);
>>
>> without checking if the returned value is NULL. Setting
>> current_mode to NULL can cause oopses at ov5640_set_mode().
> 
> Actually, as ov5640_s_frame_interval() calls ov5640_try_fmt_internal()
> first. So, this should never happen.
> 
> 
> Thanks,
> Mauro
> 




[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