From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 30739 invoked by alias); 23 Oct 2014 11:50:29 -0000 Mailing-List: contact ecos-discuss-help@ecos.sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: ecos-discuss-owner@ecos.sourceware.org Received: (qmail 30729 invoked by uid 89); 23 Oct 2014 11:50:28 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-0.3 required=5.0 tests=AWL,BAYES_00,RCVD_IN_SORBS_WEB autolearn=no version=3.3.2 X-HELO: xm21.hostsila.net Received: from xm21.hostsila.net (HELO xm21.hostsila.net) (80.91.189.41) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with (AES256-SHA encrypted) ESMTPS; Thu, 23 Oct 2014 11:50:26 +0000 Received: from [195.20.130.1] (port=53986 helo=[10.1.7.235]) by xm21.hostsila.net with esmtpsa (TLSv1:DHE-RSA-AES128-SHA:128) (Exim 4.82) (envelope-from ) id 1XhGvt-000vZP-SB; Thu, 23 Oct 2014 14:51:57 +0300 Message-ID: <5448EB7B.5080203@unicore.co.ua> Date: Thu, 23 Oct 2014 11:50:00 -0000 From: Oleg Uzenkov User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:24.0) Gecko/20100101 Thunderbird/24.6.0 MIME-Version: 1.0 To: Rainer Arndt , Edgar Grimberg , Sergei Gavrikov CC: eCos Discussion References: <544618E5.90101@unicore.co.ua> <54479031.9080106@unicore.co.ua> <1C548879-90CC-458E-966B-0A8C88C4D7A6@ibehs.de> In-Reply-To: <1C548879-90CC-458E-966B-0A8C88C4D7A6@ibehs.de> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Get-Message-Sender-Via: xm21.hostsila.net: authenticated_id: o.uzenkov@unicore.co.ua X-IsSubscribed: yes Subject: Re: [ECOS] small custom bootloader to start an app stored in flash X-SW-Source: 2014-10/txt/msg00039.txt.bz2 Hi, Please have a look to this document: http://infocenter.arm.com/help/topic/com.arm.doc.ihi0044e/IHI0044E_aaelf.pdf on page 21 it says: "Note This allows a linker to distinguish ARM and Thumb code symbols without having to refer to the map. An ARM symbol will always have an even value, while a Thumb symbol will always have an odd value. However, a linker should strip the discriminating bit from the value before using it for relocation." May be this is why I have: Entry point address: 0x8000111 entry point of odd value Cortex-M4 supports only Thumb Mode and the entry point should probably be always odd. My compiler flags: -Wall -Wpointer-arith -Wstrict-prototypes -Wundef -Woverloaded-virtual -Wno-write-strings -mthumb -g -O2 -ffunction-sections -fdata-sections -fno-rtti -fno-exceptions -mcpu=cortex-m4 Linker flags: -mthumb -Wl,--gc-sections -Wl,-static -Wl,-n -g -nostdlib -mcpu=cortex-m4 Oleg -- Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss