From patchwork Wed Dec 10 19:59:59 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andrew Jones X-Patchwork-Id: 5471861 Return-Path: X-Original-To: patchwork-kvm@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork2.web.kernel.org (Postfix) with ESMTP id 3A8F5BEEA8 for ; Wed, 10 Dec 2014 20:00:36 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 4FF7A2017D for ; Wed, 10 Dec 2014 20:00:35 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 7A9382018E for ; Wed, 10 Dec 2014 20:00:34 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932986AbaLJUAa (ORCPT ); Wed, 10 Dec 2014 15:00:30 -0500 Received: from mx1.redhat.com ([209.132.183.28]:48788 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932890AbaLJUA3 (ORCPT ); Wed, 10 Dec 2014 15:00:29 -0500 Received: from int-mx09.intmail.prod.int.phx2.redhat.com (int-mx09.intmail.prod.int.phx2.redhat.com [10.5.11.22]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id sBAK0OFm007665 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=FAIL); Wed, 10 Dec 2014 15:00:25 -0500 Received: from hawk.usersys.redhat.com ([10.34.1.145]) by int-mx09.intmail.prod.int.phx2.redhat.com (8.14.4/8.14.4) with ESMTP id sBAK0CaR028915; Wed, 10 Dec 2014 15:00:23 -0500 From: Andrew Jones To: kvmarm@lists.cs.columbia.edu, kvm@vger.kernel.org Cc: christoffer.dall@linaro.org, pbonzini@redhat.com, alex.bennee@linaro.org Subject: [PATCH 06/15] arm: setup: drop unused arguments Date: Wed, 10 Dec 2014 20:59:59 +0100 Message-Id: <1418241608-13966-7-git-send-email-drjones@redhat.com> In-Reply-To: <1418241608-13966-1-git-send-email-drjones@redhat.com> References: <1418241608-13966-1-git-send-email-drjones@redhat.com> X-Scanned-By: MIMEDefang 2.68 on 10.5.11.22 Sender: kvm-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: kvm@vger.kernel.org X-Spam-Status: No, score=-6.9 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_HI, T_RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Drop the unused arguments from setup(), passing only the fdt. This allows setup() to be more easily shared with arm64. Signed-off-by: Andrew Jones --- arm/cstart.S | 12 ++++++++++-- lib/arm/setup.c | 3 +-- 2 files changed, 11 insertions(+), 4 deletions(-) diff --git a/arm/cstart.S b/arm/cstart.S index 1e3c3a32375fd..da496e9eae7e0 100644 --- a/arm/cstart.S +++ b/arm/cstart.S @@ -19,15 +19,23 @@ start: /* * bootloader params are in r0-r2 * See the kernel doc Documentation/arm/Booting + * r0 = 0 + * r1 = machine type number + * r2 = physical address of the dtb + * + * As we have no need for r0's nor r1's value, then + * put the dtb in r0. This allows setup to be consistent + * with arm64. */ ldr sp, =stacktop - push {r0-r3} + mov r0, r2 + push {r0-r1} /* set up vector table and mode stacks */ bl exceptions_init /* complete setup */ - pop {r0-r3} + pop {r0-r1} bl setup /* run the test */ diff --git a/lib/arm/setup.c b/lib/arm/setup.c index 9d2094da8a29c..8f58802e958ac 100644 --- a/lib/arm/setup.c +++ b/lib/arm/setup.c @@ -62,8 +62,7 @@ static void mem_init(phys_addr_t freemem_start) mmu_enable_idmap(); } -void setup(unsigned long arg __unused, unsigned long id __unused, - const void *fdt) +void setup(const void *fdt) { const char *bootargs; u32 fdt_size;