LinuxSir.cn,穿越时空的Linuxsir!

 找回密码
 注册
搜索
热搜: shell linux mysql
查看: 1344|回复: 0

porting linux to new platform

[复制链接]
发表于 2007-4-27 12:04:12 | 显示全部楼层 |阅读模式
I am porting linux to an ARM 926EGS core.
I have written some code for it ,and try to compile them,but it can't work.
the chip is TU3710.
I use the lasted version of Linux that i can get from the kernel.org.the version is 2.6.21.
and have done the following work.
1. add a directory mach-tu3710 in /arch/arm/ and write the arch code there .
2. add a new line  machine-$(CONFIG_ARCH_TU3710)           := tu3710 to the Makefile in the arm directory
3.add a directory arch-tu3710 in /include/asm and write headerfiles there.
4. add following lines to kconfig in /arch/arm
config ARCH_TU3710
        bool "tu3710"
        help
          Support for tu3710 platform.

when I compile it ,i get the info:
scripts/kconfig/conf -s arch/arm/Kconfig
  CHK     include/linux/version.h
  SYMLINK include/asm-arm/arch -> include/asm-arm/arch-tu3310
make[1]: “include/asm-arm/mach-types.h”是最新的。
  CHK     include/linux/utsrelease.h
  CC      arch/arm/kernel/asm-offsets.s
In file included from include/linux/irqflags.h:46,
                 from include/asm/system.h:77,
                 from include/asm/bitops.h:23,
                 from include/linux/bitops.h:9,
                 from include/linux/thread_info.h:20,
                 from include/linux/preempt.h:9,
                 from include/linux/spinlock.h:49,
                 from include/linux/capability.h:45,
                 from include/linux/sched.h:46,
                 from arch/arm/kernel/asm-offsets.c:13:
include/asm/irqflags.h:11:5: warning: "__LINUX_ARM_ARCH__" is not defined
In file included from include/asm/bitops.h:23,
                 from include/linux/bitops.h:9,
                 from include/linux/thread_info.h:20,
                 from include/linux/preempt.h:9,
                 from include/linux/spinlock.h:49,
                 from include/linux/capability.h:45,
                 from include/linux/sched.h:46,
                 from arch/arm/kernel/asm-offsets.c:13:
include/asm/system.h:152:5: warning: "__LINUX_ARM_ARCH__" is not defined
include/asm/system.h:158:33: warning: "__LINUX_ARM_ARCH__" is not defined
include/asm/system.h:288:5: warning: "__LINUX_ARM_ARCH__" is not defined
include/asm/system.h:293:5: warning: "__LINUX_ARM_ARCH__" is not defined
In file included from include/linux/bitops.h:9,
                 from include/linux/thread_info.h:20,
                 from include/linux/preempt.h:9,
                 from include/linux/spinlock.h:49,
                 from include/linux/capability.h:45,
                 from include/linux/sched.h:46,
                 from arch/arm/kernel/asm-offsets.c:13:
include/asm/bitops.h:233:5: warning: "__LINUX_ARM_ARCH__" is not defined
In file included from include/asm/thread_info.h:16,
                 from include/linux/thread_info.h:21,
                 from include/linux/preempt.h:9,
                 from include/linux/spinlock.h:49,
                 from include/linux/capability.h:45,
                 from include/linux/sched.h:46,
                 from arch/arm/kernel/asm-offsets.c:13:
include/asm/fpstate.h:28:5: warning: "__LINUX_ARM_ARCH__" is not defined
In file included from include/linux/spinlock.h:326,
                 from include/linux/capability.h:45,
                 from include/linux/sched.h:46,
                 from arch/arm/kernel/asm-offsets.c:13:
include/asm/atomic.h:24:5: warning: "__LINUX_ARM_ARCH__" is not defined
In file included from include/linux/prefetch.h:14,
                 from include/linux/list.h:8,
                 from include/linux/wait.h:22,
                 from include/asm/semaphore.h:9,
                 from include/linux/sched.h:59,
                 from arch/arm/kernel/asm-offsets.c:13:
include/asm/processor.h:103:5: warning: "__LINUX_ARM_ARCH__" is not defined
In file included from include/asm/semaphore.h:13,
                 from include/linux/sched.h:59,
                 from arch/arm/kernel/asm-offsets.c:13:
include/asm/locks.h:15:5: warning: "__LINUX_ARM_ARCH__" is not defined
In file included from include/asm/page.h:32,
                 from include/linux/sched.h:60,
                 from arch/arm/kernel/asm-offsets.c:13:
include/asm/glue.h:110:2: #error Unknown data abort handler type
In file included from include/linux/sched.h:60,
                 from arch/arm/kernel/asm-offsets.c:13:
include/asm/page.h:106:2: #error Unknown user operations model
In file included from include/linux/sched.h:62,
                 from arch/arm/kernel/asm-offsets.c:13:
include/asm/mmu.h:7:5: warning: "__LINUX_ARM_ARCH__" is not defined
include/asm/mmu.h:13:5: warning: "__LINUX_ARM_ARCH__" is not defined
arch/arm/kernel/asm-offsets.c:88:5: warning: "__LINUX_ARM_ARCH__" is not definedmake[1]: *** [arch/arm/kernel/asm-offsets.s] error 1
make: *** [prepare0] error 2


I think that maybe the configuration was not properly seted. How Kbuild works?Should I do anything else?
您需要登录后才可以回帖 登录 | 注册

本版积分规则

快速回复 返回顶部 返回列表