From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 25135 invoked by alias); 12 Jun 2006 20:03:04 -0000 Received: (qmail 25126 invoked by uid 22791); 12 Jun 2006 20:03:03 -0000 X-Spam-Check-By: sourceware.org Received: from test-dk.vitesse.com (HELO mx-dk1.vsc.vitesse.com) (217.74.214.36) by sourceware.org (qpsmtpd/0.31) with ESMTP; Mon, 12 Jun 2006 20:03:00 +0000 content-class: urn:content-classes:message MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable Date: Mon, 12 Jun 2006 20:03:00 -0000 Message-ID: <4635C7499BD3A14C9361477F0613ED9B9B953F@mx-dk1.vsc.vitesse.com> From: "Lars Povlsen" To: "eCos Disuss" X-IsSubscribed: yes Mailing-List: contact ecos-discuss-help@ecos.sourceware.org; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: ecos-discuss-owner@ecos.sourceware.org Subject: [ECOS] Thumb support for arm9 variants? X-SW-Source: 2006-06/txt/msg00111.txt.bz2 Hello All! I have been tinkering with a couple of ARM9/ARM926 platforms for which I have built an eCos HAL modeled after the ARM9 variants in packages/hal/arm/arm9/*. Everything (mostly) is looking great, but wanting to test the thumb-mode of my chips turned out to be less than straight-forward... I deduced that I was unable to just "enable" in configtool due to missing "implements CYGINT_HAL_ARM_THUMB_ARCH". But with that added (and the -mthumb compile options that goes along), it seems that not all code in hal/arm/arm9 is "thumb"-compatible: arm-elf-gcc -c -I/proj/sw/usr/lpovlsen/ecos/build_luton28_ram/install/include -I/users/lpovlsen/project/ecos/base/packages/hal/arm/arm9/var/current -I/users/lpovlsen/project/ecos/base/packages/hal/arm/arm9/var/current/sr c -I/users/lpovlsen/project/ecos/base/packages/hal/arm/arm9/var/current/te sts -I. -I/users/lpovlsen/project/ecos/base/packages/hal/arm/arm9/var/current/sr c/ -finline-limit=3D7000 -mthumb -mthumb-interwork -mcpu=3Darm9 -Wall -Wpointer-arith -Wstrict-prototypes -Winline -Wundef -g -O2 -ffunction-sections -fdata-sections -fno-exceptions -Wp,-MD,src/arm9_misc.tmp -o src/hal_arm_arm9_var_arm9_misc.o /users/lpovlsen/project/ecos/base/packages/hal/arm/arm9/var/current/src/ arm9_misc.c /tmp/ccmyIUwO.s: Assembler messages: /tmp/ccmyIUwO.s:24: Error: bad instruction `mrc p15,0,r1,c1,c0,0' /tmp/ccmyIUwO.s:24: Error: register expected, not '#0x000F' -- `orr r1,r1,#0x000F' /tmp/ccmyIUwO.s:24: Error: bad instruction `mcr p15,0,r1,c1,c0,0' /tmp/ccmyIUwO.s:26: Error: bad instruction `mrc p15,0,r1,c1,c0,0' /tmp/ccmyIUwO.s:26: Error: register expected, not '#0x1000' -- `orr r1,r1,#0x1000' /tmp/ccmyIUwO.s:26: Error: register expected, not '#0x0002' -- `orr r1,r1,#0x0002' /tmp/ccmyIUwO.s:26: Error: bad instruction `mcr p15,0,r1,c1,c0,0' /tmp/ccmyIUwO.s:45: Error: bad instruction `mrs r1,cpsr' /tmp/ccmyIUwO.s:45: Error: register expected, not '#0x1F' -- `bic r1,r1,#0x1F' /tmp/ccmyIUwO.s:45: Error: register expected, not '#0x13' -- `orr r1,r1,#0x13' /tmp/ccmyIUwO.s:45: Error: bad instruction `msr cpsr,r1' /tmp/ccmyIUwO.s:45: Error: bad instruction `mcr p15,0,r1,c7,c7,0' /tmp/ccmyIUwO.s:45: Error: bad instruction `mcr p15,0,r1,c7,c10,4' /tmp/ccmyIUwO.s:45: Error: bad instruction `mcr p15,0,r1,c8,c7,0' /tmp/ccmyIUwO.s:45: Error: bad instruction `mrc p15,0,r1,c1,c0,0' /tmp/ccmyIUwO.s:45: Error: register expected, not '#0x1000' -- `bic r1,r1,#0x1000' /tmp/ccmyIUwO.s:45: Error: register expected, not '#0x0007' -- `bic r1,r1,#0x0007' /tmp/ccmyIUwO.s:45: Error: bad instruction `mcr p15,0,r1,c1,c0,0' make[1]: *** [src/arm9_misc.o.d] Error 1=20 It seems, however that the ARM PID has both ARM9 and thumb support - and so does at91 etc. Where did I go wrong? Is thumb "out of fashion" - or did I just set off from the wrong place? None of the hal/arm/arm9 HAL's have thumb...? Sincerely Lars Povlsen Senior member of technical staff Vitesse Semiconductor Corp Direct: +45 44855957 PS: While I have your attention - I would like to thank everyone here supporting eCos for the immense patience shown in answering everything from deep-tech to novice questions. Thanks - I am full of awe, sometimes you really deserve a medal!=20 -- Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss