Patchwork mxc_v4l2_capture sometimes not being modprobed

login
register
mail settings
Submitter Otavio Salvador
Date June 9, 2014, 1:52 p.m.
Message ID <CAP9ODKoG_1+Vva0p3MG_pTQ=WWgA28EMY2jBaG1HVevfMavEXA@mail.gmail.com>
Download mbox | patch
Permalink /patch/73495/
State Not Applicable
Delegated to: Otavio Salvador
Headers show

Comments

Otavio Salvador - June 9, 2014, 1:52 p.m.
On Mon, Jun 9, 2014 at 10:51 AM, Otavio Salvador
<otavio@ossystems.com.br> wrote:
> On Sun, Jun 8, 2014 at 12:51 PM, John Weber <rjohnweber@gmail.com> wrote:
>> On 6/6/14, 6:10 PM, Eric Nelson wrote:
>>> On 06/05/2014 01:33 PM, Eric Nelson wrote:
>>>> On 06/05/2014 01:30 PM, John Weber wrote:
>>>>>
>>>>> <snip>
>>>>>
>>>>> I think you're right, but as far as I know the only other entity that
>>>>> could confirm this would be Boundary Devices.  Eric - do you see this
>>>>> same issue when connecting your camera to Nitrogen6x?
>>>>>
>>>> I've kinda followed this thread, but I'm kinda buried and it will take
>>>> a day or two for me to confirm or deny this.
>>>>
>>> I just tested across a dozen assorted reboots/resets/power-cycles
>>> and didn't see the issue with an OV5642 parallel camera and 3.10.17.
>>>
>>> I **don't** have udev-cache configured.
>>
>> I suspect that we will need to disable it on Wandboard as well.
>
> This is not a good fix.
>
> I added a patch, for OE-Core/Poky, attached; please confirm it fixes it.

Oops!
John Weber - June 9, 2014, 4 p.m.
Hi Otavio,

On 6/9/14, 8:52 AM, Otavio Salvador wrote:
> On Mon, Jun 9, 2014 at 10:51 AM, Otavio Salvador
> <otavio@ossystems.com.br> wrote:
>> On Sun, Jun 8, 2014 at 12:51 PM, John Weber <rjohnweber@gmail.com> wrote:
>>> On 6/6/14, 6:10 PM, Eric Nelson wrote:
>>>> On 06/05/2014 01:33 PM, Eric Nelson wrote:
>>>>> On 06/05/2014 01:30 PM, John Weber wrote:
>>>>>> <snip>
>>>>>>
>>>>>> I think you're right, but as far as I know the only other entity that
>>>>>> could confirm this would be Boundary Devices.  Eric - do you see this
>>>>>> same issue when connecting your camera to Nitrogen6x?
>>>>>>
>>>>> I've kinda followed this thread, but I'm kinda buried and it will take
>>>>> a day or two for me to confirm or deny this.
>>>>>
>>>> I just tested across a dozen assorted reboots/resets/power-cycles
>>>> and didn't see the issue with an OV5642 parallel camera and 3.10.17.
>>>>
>>>> I **don't** have udev-cache configured.
>>> I suspect that we will need to disable it on Wandboard as well.
>> This is not a good fix.
>>
>> I added a patch, for OE-Core/Poky, attached; please confirm it fixes it.
> Oops!
>
Thanks!  From my testing this will work.
Eric Nelson - June 9, 2014, 5:16 p.m.
Hi all,

On 06/09/2014 06:52 AM, Otavio Salvador wrote:
> On Mon, Jun 9, 2014 at 10:51 AM, Otavio Salvador
> <otavio@ossystems.com.br> wrote:
>> On Sun, Jun 8, 2014 at 12:51 PM, John Weber <rjohnweber@gmail.com> wrote:
>>> On 6/6/14, 6:10 PM, Eric Nelson wrote:
>>>> On 06/05/2014 01:33 PM, Eric Nelson wrote:
>>>>> On 06/05/2014 01:30 PM, John Weber wrote:
>>>>>>
>>>>>> <snip>
>>>>>>
>>>>>> I think you're right, but as far as I know the only other entity that
>>>>>> could confirm this would be Boundary Devices.  Eric - do you see this
>>>>>> same issue when connecting your camera to Nitrogen6x?
>>>>>>
>>>>> I've kinda followed this thread, but I'm kinda buried and it will take
>>>>> a day or two for me to confirm or deny this.
>>>>>
>>>> I just tested across a dozen assorted reboots/resets/power-cycles
>>>> and didn't see the issue with an OV5642 parallel camera and 3.10.17.
>>>>
>>>> I **don't** have udev-cache configured.
>>>
>>> I suspect that we will need to disable it on Wandboard as well.
>>
>> This is not a good fix.
>>
>> I added a patch, for OE-Core/Poky, attached; please confirm it fixes it.
> 

I just tested again on an image with udev-cache, and don't see any
issues on a Nitrogen6x board (CSI camera).

I'm not sure what's different about my environment.

Regards,


Eric
John Weber - June 9, 2014, 5:35 p.m.
Hi Eric,

On 6/9/14, 12:16 PM, Eric Nelson wrote:
> Hi all,
>
> On 06/09/2014 06:52 AM, Otavio Salvador wrote:
>> On Mon, Jun 9, 2014 at 10:51 AM, Otavio Salvador
>> <otavio@ossystems.com.br> wrote:
>>> On Sun, Jun 8, 2014 at 12:51 PM, John Weber <rjohnweber@gmail.com> wrote:
>>>> On 6/6/14, 6:10 PM, Eric Nelson wrote:
>>>>> On 06/05/2014 01:33 PM, Eric Nelson wrote:
>>>>>> On 06/05/2014 01:30 PM, John Weber wrote:
>>>>>>> <snip>
>>>>>>>
>>>>>>> I think you're right, but as far as I know the only other entity that
>>>>>>> could confirm this would be Boundary Devices.  Eric - do you see this
>>>>>>> same issue when connecting your camera to Nitrogen6x?
>>>>>>>
>>>>>> I've kinda followed this thread, but I'm kinda buried and it will take
>>>>>> a day or two for me to confirm or deny this.
>>>>>>
>>>>> I just tested across a dozen assorted reboots/resets/power-cycles
>>>>> and didn't see the issue with an OV5642 parallel camera and 3.10.17.
>>>>>
>>>>> I **don't** have udev-cache configured.
>>>> I suspect that we will need to disable it on Wandboard as well.
>>> This is not a good fix.
>>>
>>> I added a patch, for OE-Core/Poky, attached; please confirm it fixes it.
> I just tested again on an image with udev-cache, and don't see any
> issues on a Nitrogen6x board (CSI camera).
>
> I'm not sure what's different about my environment.
>
> Regards,
>
>
> Eric
>
Not sure either, but are you testing with the parallel CSI or MIPI CSI camera?  
Could there be a difference in the how the drivers are loaded?

John
Eric Nelson - June 9, 2014, 5:49 p.m.
Hi John,

On 06/09/2014 10:35 AM, John Weber wrote:
> Hi Eric,
> 
> On 6/9/14, 12:16 PM, Eric Nelson wrote:
>> Hi all,
>>
>> On 06/09/2014 06:52 AM, Otavio Salvador wrote:
>>> On Mon, Jun 9, 2014 at 10:51 AM, Otavio Salvador
>>> <otavio@ossystems.com.br> wrote:
>>>> On Sun, Jun 8, 2014 at 12:51 PM, John Weber <rjohnweber@gmail.com>
>>>> wrote:
>>>>> On 6/6/14, 6:10 PM, Eric Nelson wrote:
>>>>>> On 06/05/2014 01:33 PM, Eric Nelson wrote:
>>>>>>> On 06/05/2014 01:30 PM, John Weber wrote:
>>>>>>>> <snip>
>>>>>>>>
>>>>>>>> I think you're right, but as far as I know the only other entity
>>>>>>>> that
>>>>>>>> could confirm this would be Boundary Devices.  Eric - do you see
>>>>>>>> this
>>>>>>>> same issue when connecting your camera to Nitrogen6x?
>>>>>>>>
>>>>>>> I've kinda followed this thread, but I'm kinda buried and it will
>>>>>>> take
>>>>>>> a day or two for me to confirm or deny this.
>>>>>>>
>>>>>> I just tested across a dozen assorted reboots/resets/power-cycles
>>>>>> and didn't see the issue with an OV5642 parallel camera and 3.10.17.
>>>>>>
>>>>>> I **don't** have udev-cache configured.
>>>>> I suspect that we will need to disable it on Wandboard as well.
>>>> This is not a good fix.
>>>>
>>>> I added a patch, for OE-Core/Poky, attached; please confirm it fixes
>>>> it.
>> I just tested again on an image with udev-cache, and don't see any
>> issues on a Nitrogen6x board (CSI camera).
>>
>> I'm not sure what's different about my environment.
>>
>> Regards,
>>
>>
>> Eric
>>
> Not sure either, but are you testing with the parallel CSI or MIPI CSI
> camera?  Could there be a difference in the how the drivers are loaded?
> 

I tested using parallel CSI.

AFAIK, the driver load process is the same for both.

Regards,


Eric
John Weber - June 9, 2014, 5:59 p.m.
Hi Eric,

On 6/9/14, 12:49 PM, Eric Nelson wrote:
> Hi John,
>
> On 06/09/2014 10:35 AM, John Weber wrote:
>> Hi Eric,
>>
>> On 6/9/14, 12:16 PM, Eric Nelson wrote:
>>> Hi all,
>>>
>>> On 06/09/2014 06:52 AM, Otavio Salvador wrote:
>>>> On Mon, Jun 9, 2014 at 10:51 AM, Otavio Salvador
>>>> <otavio@ossystems.com.br> wrote:
>>>>> On Sun, Jun 8, 2014 at 12:51 PM, John Weber <rjohnweber@gmail.com>
>>>>> wrote:
>>>>>> On 6/6/14, 6:10 PM, Eric Nelson wrote:
>>>>>>> On 06/05/2014 01:33 PM, Eric Nelson wrote:
>>>>>>>> On 06/05/2014 01:30 PM, John Weber wrote:
>>>>>>>>> <snip>
>>>>>>>>>
>>>>>>>>> I think you're right, but as far as I know the only other entity
>>>>>>>>> that
>>>>>>>>> could confirm this would be Boundary Devices.  Eric - do you see
>>>>>>>>> this
>>>>>>>>> same issue when connecting your camera to Nitrogen6x?
>>>>>>>>>
>>>>>>>> I've kinda followed this thread, but I'm kinda buried and it will
>>>>>>>> take
>>>>>>>> a day or two for me to confirm or deny this.
>>>>>>>>
>>>>>>> I just tested across a dozen assorted reboots/resets/power-cycles
>>>>>>> and didn't see the issue with an OV5642 parallel camera and 3.10.17.
>>>>>>>
>>>>>>> I **don't** have udev-cache configured.
>>>>>> I suspect that we will need to disable it on Wandboard as well.
>>>>> This is not a good fix.
>>>>>
>>>>> I added a patch, for OE-Core/Poky, attached; please confirm it fixes
>>>>> it.
>>> I just tested again on an image with udev-cache, and don't see any
>>> issues on a Nitrogen6x board (CSI camera).
>>>
>>> I'm not sure what's different about my environment.
>>>
>>> Regards,
>>>
>>>
>>> Eric
>>>
>> Not sure either, but are you testing with the parallel CSI or MIPI CSI
>> camera?  Could there be a difference in the how the drivers are loaded?
>>
> I tested using parallel CSI.
>
> AFAIK, the driver load process is the same for both.
>
> Regards,
>
>
> Eric
OK.  I don't think our environments are very different, so I suspect that it 
might be one of the few kernel enhancements that you've made.

BTW - did you disable udev-cache by default?  If so where did you do this in Yocto?

John
Eric Nelson - June 9, 2014, 6:09 p.m.
Hi John,

On 06/09/2014 10:59 AM, John Weber wrote:
> Hi Eric,
> 
> On 6/9/14, 12:49 PM, Eric Nelson wrote:
>> Hi John,
>>
>> On 06/09/2014 10:35 AM, John Weber wrote:
>>> Hi Eric,
>>>
>>> On 6/9/14, 12:16 PM, Eric Nelson wrote:
>>>> Hi all,
>>>>
>>>> On 06/09/2014 06:52 AM, Otavio Salvador wrote:
>>>>> On Mon, Jun 9, 2014 at 10:51 AM, Otavio Salvador
>>>>> <otavio@ossystems.com.br> wrote:
>>>>>> On Sun, Jun 8, 2014 at 12:51 PM, John Weber <rjohnweber@gmail.com>
>>>>>> wrote:
>>>>>>> On 6/6/14, 6:10 PM, Eric Nelson wrote:
>>>>>>>> On 06/05/2014 01:33 PM, Eric Nelson wrote:
>>>>>>>>> On 06/05/2014 01:30 PM, John Weber wrote:
>>>>>>>>>> <snip>
>>>>>>>>>>
>>>>>>>>>> I think you're right, but as far as I know the only other entity
>>>>>>>>>> that
>>>>>>>>>> could confirm this would be Boundary Devices.  Eric - do you see
>>>>>>>>>> this
>>>>>>>>>> same issue when connecting your camera to Nitrogen6x?
>>>>>>>>>>
>>>>>>>>> I've kinda followed this thread, but I'm kinda buried and it will
>>>>>>>>> take
>>>>>>>>> a day or two for me to confirm or deny this.
>>>>>>>>>
>>>>>>>> I just tested across a dozen assorted reboots/resets/power-cycles
>>>>>>>> and didn't see the issue with an OV5642 parallel camera and
>>>>>>>> 3.10.17.
>>>>>>>>
>>>>>>>> I **don't** have udev-cache configured.
>>>>>>> I suspect that we will need to disable it on Wandboard as well.
>>>>>> This is not a good fix.
>>>>>>
>>>>>> I added a patch, for OE-Core/Poky, attached; please confirm it fixes
>>>>>> it.
>>>> I just tested again on an image with udev-cache, and don't see any
>>>> issues on a Nitrogen6x board (CSI camera).
>>>>
>>>> I'm not sure what's different about my environment.
>>>>
>>>> Regards,
>>>>
>>>>
>>>> Eric
>>>>
>>> Not sure either, but are you testing with the parallel CSI or MIPI CSI
>>> camera?  Could there be a difference in the how the drivers are loaded?
>>>
>> I tested using parallel CSI.
>>
>> AFAIK, the driver load process is the same for both.
>>
>> Regards,
>>
>>
>> Eric
> OK.  I don't think our environments are very different, so I suspect
> that it might be one of the few kernel enhancements that you've made.
> 
> BTW - did you disable udev-cache by default?  If so where did you do
> this in Yocto?
> 

This was purely un-intentional. I think I was working with a build that
started with core-image-minimal.

Regards,


Eric

Patch

From 0d1eaebf86a79089c71eb59711e83e0ca23d8b84 Mon Sep 17 00:00:00 2001
From: Otavio Salvador <otavio@ossystems.com.br>
Date: Mon, 9 Jun 2014 10:48:59 -0300
Subject: [PATCH] udev: Trigger platform events for udev-cache
Organization: O.S. Systems Software LTDA.

Some embedded boards need to have the platform events triggered so the
platform specific drivers are loaded.

This has been found when testing a camera module in Wandboard Quad.

Reported-by: John Weber <rjohnweber@gmail.com>
Signed-off-by: Otavio Salvador <otavio@ossystems.com.br>
---
 meta/recipes-core/udev/udev/init | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/meta/recipes-core/udev/udev/init b/meta/recipes-core/udev/udev/init
index 410a650..649109c 100644
--- a/meta/recipes-core/udev/udev/init
+++ b/meta/recipes-core/udev/udev/init
@@ -102,7 +102,7 @@  case "$1" in
 
     udevadm control --env=STARTUP=1
     if [ "$not_first_boot" != "" ];then
-            udevadm trigger --action=add --subsystem-nomatch=tty --subsystem-nomatch=mem --subsystem-nomatch=vc --subsystem-nomatch=vtconsole --subsystem-nomatch=misc --subsystem-nomatch=dcon --subsystem-nomatch=pci_bus  --subsystem-nomatch=graphics	 --subsystem-nomatch=backlight --subsystem-nomatch=video4linux	--subsystem-nomatch=platform
+            udevadm trigger --action=add --subsystem-nomatch=tty --subsystem-nomatch=mem --subsystem-nomatch=vc --subsystem-nomatch=vtconsole --subsystem-nomatch=misc --subsystem-nomatch=dcon --subsystem-nomatch=pci_bus  --subsystem-nomatch=graphics	 --subsystem-nomatch=backlight --subsystem-nomatch=video4linux
             (udevadm settle --timeout=3; udevadm control --env=STARTUP=)&
     else
             udevadm trigger --action=add
-- 
2.0.0.rc4