Search

Technical Discussion Group Forum

This forum is provided for user discussion. While Beacon EmbeddedWorks support staff and engineers participate, Beacon EmbeddedWorks does not guarantee the accuracy of all information within in the Technical Discussion Group (TDG).

The "Articles" forums provide brief Articles written by Beacon EmbeddedWorks engineers that address the most frequently asked technical questions.

To receive email notifications when updates are posted for a Beacon EmbeddedWorks product download, please subscribe to the TDG Forum of interest.

TDG Forum

PrevPrev Go to previous topic
NextNext Go to next topic
Last Post 09 Apr 2008 04:30 AM by  rbunce
Linux 2.6.19 loadable modules?
 1 Replies
Sort:
You are not authorized to post a reply.
Author Messages
rbunce
New Member
New Member
Posts:


--
09 Apr 2008 03:51 AM
    Has anyone tried using loadable modules yet? I've created modules for older versions of Linux (on other projects) but I understand that there is now a new method which generates *.ko files using kbuild.

    I have set up the kernel to support modules, but so far I can't work out how to build the modules themselves. I'm happy with the "C" code, it's just the build process I'm stuck on.

    If any of you has an example Make file or any other tips it would be appreciated.

    Thanks in advance,

    Roy
    rbunce
    New Member
    New Member
    Posts:


    --
    09 Apr 2008 04:30 AM
    I answered my own question. Here is an example of a very simple makefile in case anyone else needs this info:


    CC = (path to your cross compiler)/arm-none-linux-gnueabi-gcc

    obj-m += my_module.o

    all:
    make -C /home/roy/imx31/kernel/linux-2.6.19 M=$(PWD) modules


    The path in the "make" should be to the source tree of the kernel which is loaded onto the iMX31. This is the bit I was getting wrong, because it originally pointed to the source tree of the kernel running on the host PC. I'm still kicking myself!


    Roy
    You are not authorized to post a reply.