[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <hpq4j7-0tp.ln1@chipmunk.wormnet.eu>
Date: Mon, 9 Aug 2010 09:28:01 +0100
From: Alexander Clouter <alex@...riz.org.uk>
To: linux-kernel@...r.kernel.org
Subject: Re: how to transplant a driver from 2.4 to 2.6?
hacklu <embedway.linux@...il.com> wrote:
>
> I have a driver project programmed under the 2.4 kernel.
> but now ,I want to transplant it to 2.6.
> the driver has some directions;
> like 1/1.c 2/2.c 3/3_1.c 3_2.c
> in this case ,how can I imtate the template Makefile of 2.6's driver
>
I use the following 2.6 Makefile template for an out of kernel drive I
am forced to use:
----
alex@...k:~$ cat /usr/src/wag54g/sangam-atm/Makefile
ifneq ($(KERNELRELEASE),)
include Kbuild
else
KERNELDIR := /usr/src/wag54g/linux/
all::
$(MAKE) -C $(KERNELDIR) M=`pwd` tiatm.ko
endif
alex@...k:~$ cat /usr/src/wag54g/sangam-atm/Kbuild
obj-m := tiatm.o
tiatm-y := cpsar.o aal5sar.o tn7sar.o tn7atm.o tn7dsl.o dsl_hal_api.o dsl_hal_support.o dsl_hal_advcfg.o
ccflags-y += -I$(PWD) -DPOST_SILICON -DCOMMON_NSP -D__NO__VOICE_PATCH__ -DEL -DCPATM_TASKLET_MODE
#ccflags-$(DEBUG) += -D....
----
It's not great, but it works.
Cheers
--
Alexander Clouter
.sigmonster says: Never eat more than you can lift.
-- Miss Piggy
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists