[Beaglebone] Helloworld kernel module

Hey guys,

I’ve been trying this for a while now but I can’t seem to figure out what’s wrong.

kernel source location should be:

/media/linuxdata/setup-scripts/build/tmp-angstrom_v2012_05-eglibc/work/beaglebone-angstrom-linux-gnueabi/linux-ti33x-psp-3.2.28-r16b+gitr720e07b4c1f687b61b147b31c698cb6816d72f01/git

CROSS_COMPILER=/usr/local/oecore-x86_64/sysroots/x86_64-angstromsdk-linux/usr/bin/armv7a-angstrom-linux-gnueabi/arm-angstrom-linux-gnueabi-
ARCH=ARM

this is my output:
http://pastebin.com/Rft5c3bv

with makefile:
http://pastebin.com/hMduECPe

hello-1.c
http://pastebin.com/UZd5dP6n

I think I’m missing the kernel-headers.

I’ve tried to get all the header files seperate. Copied them over but I was only making it worse! Any ideas?

This is probably the 1000th post about this subject but I can’t find an solution on the internet.

Some pointers,

Please refer to the
https://github.com/hvaibhav/sample-applications/tree/master/timer

This is kernel module which I use for validating timer. You just need to
look at Makefile and make sure that,

  - The kernel path is proper
  - Change the toolchain name according to your toolchain
  - Make sure that kernel is build before building modules
          through this makefile

Thanks,
Vaibhav

Thank you! It’s working. I’ve got to learn more about make files…