RE: [LINUX-KERNEL] Problem loading any custom driver

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

 



So,
in this case what kind of makefile I should have?
Can you attach an example?
Attached makefile is very similar what I found in the 2.6.9-34.EL-i686 source
I also were thinking that some os includes are not the right ones

--------------------------------------------------

/* Include Files */
#ifdef MODULE
#include <linux/module.h>
#include <linux/version.h>
#endif

#include <linux/config.h>
#include <linux/types.h>
#include <linux/pci.h>
#include <linux/kernel.h>
#include <linux/sched.h>

#include <linux/netdevice.h>
#include <linux/etherdevice.h>
#include <linux/init.h>
#include <linux/skbuff.h>
#include <linux/ethtool.h>

#include <linux/mm.h>
#include <linux/errno.h>
#include <linux/ioport.h>

#include <linux/delay.h>
#include <linux/timer.h>
#include <linux/slab.h>
#include <linux/interrupt.h>
#include <linux/version.h>
#include <linux/inetdevice.h>
#include <linux/bitops.h>

#include <asm/uaccess.h>
#include <linux/if_ether.h>
#include <linux/if_arp.h>
#include <net/arp.h>

#include "atf.h"
#include "atf_host.h"
#include "atf_common.h"

-------------------------------------------------------------

-----Original Message-----
From: Arjan van de Ven [mailto:[email protected]]
Sent: Sunday, May 21, 2006 9:13 PM
To: Libershteyn, Vladimir
Cc: [email protected]
Subject: RE: [LINUX-KERNEL] Problem loading any custom driver


On Sun, 2006-05-21 at 21:05 -0700, Libershteyn, Vladimir wrote:
> Here is a makefile
> -------------------------------------------------
> #
> # Makefile for the Los Angeles PCI Adapter
> # This file supports Red Hat Linux kernel 2.6(included) and above
> #
> HPATH := /usr/src/kernels/2.6.9-34.EL-i686/include
> CFLAGS = -I$(HPATH) -Wall -O2 -fomit-frame-pointer -c
> CFLAGS := $(CFLAGS) -DHOST_LITTLE_ENDIAN -DHOST_SIZE_32
> 
> obj-m += atf_host.o

this is buggy, you have to drop the CFLAGS lines!!!!!


> Our group does not have ability to put files for outside access.
> Can you specify what parts of the code you need me to attach?
> Im not familiar with rules, is it allowed to attach source files?

yeah that's fine if they're not gigantic (50Kb or so is a reasonable
boundary for that)

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

[Index of Archives]     [Kernel Newbies]     [Netfilter]     [Bugtraq]     [Photo]     [Stuff]     [Gimp]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Video 4 Linux]     [Linux for the blind]     [Linux Resources]
  Powered by Linux