ltib
[Top][All Lists]
Advanced

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

Re: [Ltib] how to build a kernel module using ltib? (docu)


From: Stuart Hughes
Subject: Re: [Ltib] how to build a kernel module using ltib? (docu)
Date: Tue, 20 Mar 2007 08:50:18 +0000

Hi David,

If videodev is part of the kernel then if it doesn't behave as expected,
you'll have get help from a kernel mailing list or the maintainer.  I
haven't directly worked on that kernel.

Perhaps what is confusing you are the kernel config settings.  The one
you see in: ltib/rootfs/lib/modules/2.6.13.4/build
is actually a symlink to /usr/src/linux/.  So if you
have /usr/src/linux/.config if you look at this on you host, you'll
actually be seeing the kernel config file for your host machine.  The
correct way to interpret this would be if you looked on your target
board.  In this case, if you'd selected to install the kernel source,
you'd see the right thing.

As far as ltib goes, the BSP maintainer for the itx has it setup so that
if you select kernel-2.6.13.4-mpc8349itx (which is recommended), the
starting config will be: nas_linux-2.6.13.4-mpc8349itx.config
If you need to change the configuration, you can do this by selecting:
'[*] Configure the kernel' when you run ltib and then when the kernel
builds, you'll be dropped to the normal kernel config screen.  After
running this kernel configuration, the kernel will be built.  Note that
a new file:
ltib/config/platform/mpc8349itx/nas_linux-2.6.13.4-mpc8349itx.config.dev
This will contain the kernel configuration after your changes.  If you
later re-configure, this will be used as the starting point.

Regards, Stuart

On Mon, 2007-03-19 at 10:58 -0700, David Warman wrote:
> Hi Stuart,
> 
> Thanks;
> 
> I thought videodev was part of the V4L subsystem and was handled by  
> ltib, since it is not explicitly called out in the --configure menu,  
> but does get built when I turn on V4L. So, in fact, I have no idea  
> how videodev is being built because I am not doing that myself.
> 
> Most puzzling is the fact that I get different behaviors after a ltib  
> --configure session even when I am sure I made o changes that should  
> have affected it. In fact, the first time I turned on V4L everything  
> seemed OK, not that I knew as much about testing that part at the  
> time as I do now.
> 
> Re the modules I am going to be adding, thanks for the pointer to  
> hello_mod, that will take me a long way.
> 
> While I have your ear, there is another puzzle: there seem to be two  
> kernel config files involved - the one called out in the ltib menu:
> 
> ltib/config/platform/mpc8349itx/nas_linux-2.6.13.4-mpc8349itx.config
> 
> 
> and the one that gets changed when I make changes in the kernel  
> configure menu:
> 
> ltib/rootfs/lib/modules/2.6.13.4/build/.config
> 
> What is the relationship here? the first has CONFIG_KMOD off, the  
> second has it =y. There are other differences too.
> 
> 
> Thanks for your help with this,
> 
> David Warman
> 
> On Mar 19, 2007, at 7:36 AM, Stuart Hughes wrote:
> 
> > Hi David,
> >
> > You'll have to ask the maintainer of videodev how to build it, I'm not
> > familiar with this.
> >
> > As far as ltib goes, there is a module example.  If you do:
> >
> > $ ./ltib hello_mod -m prep
> >
> > It will unpack a module example.  You can the take a look at the files
> > in rpm/BUILD/hello_mod-1.2, which include:
> > COPYING  Makefile  message_mod.c  mod_main.c  README
> >
> > The README has some explanations and also some links to further
> > information regarding building modules.
> >
> > To actually build this example:
> >
> > $ ./ltib -p hello_mod
> >
> > If you're still having problems after then, please get back in  
> > touch on
> > the list.  You'll need to say how your building the videodev module.
> >
> > Regards, Stuart
> >
> > On Fri, 2007-03-16 at 17:19 -0700, David Warman wrote:
> >> Hi folks,
> >>
> >> <resend after subscribing to the list - sorry if this is then  
> >> repeated>
> >>
> >> I am having a related problem: I am setting up to use the ov511
> >> camera and the usbvideo usb capture device. Both depend on the
> >> videodev module. When I modprobe videodev, I get "Unknown symbol
> >> request_module" error and the probe fails. Yet I have verified that
> >> kmod.o exports this label.  I am guessing that there is something
> >> missing from the link commands for building videodev, but I have not
> >> yet been able to find the file that contains that invocation. Forcing
> >> as rebuild by deleting kmod.o and videodev.o does not fix the
> >> problem. Has anybody any ideas on this?
> >>
> >> update:
> >> I was getting this response to modprobe:
> >>
> >> 11:59 PM root DavesHybrid ~]$ modprobe videodev
> >> videodev: Unknown symbol request_module
> >> insmod: cannot insert `/lib/modules/2.6.13.4/kernel/drivers/media/
> >> video/videodev.ko': Unknown symbol in module (-1): No such file or
> >> directory
> >> modprobe: failed to load module videodev
> >>
> >>
> >> then I deleted videodev.o, ran ./ltib -- configure, forgot to check
> >> kernel build, then ran it again with kernel build, and now I get this
> >> response instead:
> >>
> >> [12:06 AM root DavesHybrid ~]$ modprobe videodev
> >> modprobe: QM_MODULES: Function not implemented
> >>
> >> modprobe: QM_MODULES: Function not implemented
> >>
> >> modprobe: Can't locate module videodev
> >> [12:07 AM root DavesHybrid ~]$ find / -name videodev.* -print
> >> /lib/modules/2.6.13.4/kernel/drivers/media/video/videodev.ko
> >>
> >> [12:08 AM root DavesHybrid ~]$
> >>
> >>
> >> Also, and btw, I think the sample_ltib_ko.tgz would be a great help,
> >> but it does not show as a link; where would I find it?
> >>
> >>
> >> thanks in advance,
> >>
> >> David Warman
> >>
> >>
> >> _______________________________________________
> >> LTIB home page: http://bitshrine.org
> >>
> >> Ltib mailing list
> >> address@hidden
> >> http://lists.nongnu.org/mailman/listinfo/ltib
> >
> >
> >
> 
> 
> 
> _______________________________________________
> LTIB home page: http://bitshrine.org
> 
> Ltib mailing list
> address@hidden
> http://lists.nongnu.org/mailman/listinfo/ltib





reply via email to

[Prev in Thread] Current Thread [Next in Thread]