From owner-svn-src-head@FreeBSD.ORG Sat Mar 2 02:19:05 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 125E8C66; Sat, 2 Mar 2013 02:19:05 +0000 (UTC) (envelope-from andrew@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id EF2D3286; Sat, 2 Mar 2013 02:19:04 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.5/8.14.5) with ESMTP id r222J4Ni090048; Sat, 2 Mar 2013 02:19:04 GMT (envelope-from andrew@svn.freebsd.org) Received: (from andrew@localhost) by svn.freebsd.org (8.14.5/8.14.5/Submit) id r222J4hZ090047; Sat, 2 Mar 2013 02:19:04 GMT (envelope-from andrew@svn.freebsd.org) Message-Id: <201303020219.r222J4hZ090047@svn.freebsd.org> From: Andrew Turner Date: Sat, 2 Mar 2013 02:19:04 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r247608 - head/sys/arm/arm X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 02 Mar 2013 02:19:05 -0000 Author: andrew Date: Sat Mar 2 02:19:04 2013 New Revision: 247608 URL: http://svnweb.freebsd.org/changeset/base/247608 Log: Ensure the stack is correctly aligned before calling the first C function. Modified: head/sys/arm/arm/locore.S Modified: head/sys/arm/arm/locore.S ============================================================================== --- head/sys/arm/arm/locore.S Sat Mar 2 01:04:02 2013 (r247607) +++ head/sys/arm/arm/locore.S Sat Mar 2 02:19:04 2013 (r247608) @@ -204,6 +204,7 @@ mmu_done: virt_done: mov r1, #20 /* loader info size is 20 bytes also second arg */ subs sp, sp, r1 /* allocate arm_boot_params struct on stack */ + bic sp, sp, #7 /* align stack to 8 bytes */ mov r0, sp /* loader info pointer is first arg */ str r1, [r0] /* Store length of loader info */ str r9, [r0, #4] /* Store r0 from boot loader */