From patchwork Fri Oct 11 12:22:12 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ankit Jindal X-Patchwork-Id: 20960 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-ob0-f200.google.com (mail-ob0-f200.google.com [209.85.214.200]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id 31D6325EA1 for ; Fri, 11 Oct 2013 12:22:59 +0000 (UTC) Received: by mail-ob0-f200.google.com with SMTP id wo20sf16404201obc.11 for ; Fri, 11 Oct 2013 05:22:58 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=mime-version:x-gm-message-state:delivered-to:from:to:cc:subject :date:message-id:in-reply-to:references:x-original-sender :x-original-authentication-results:precedence:mailing-list:list-id :list-post:list-help:list-archive:list-unsubscribe; bh=y4LYhRuY+zLoeIPlwP7LfxiHkwbMSMlDNFpLI4Oiupo=; b=WFgdAGVa2W2m8RxYo267dGT0b2bhsSjbW/i8QEohHhw1dhkD08Wm2+U9n8SFp5sFBW /Wb3adIs0GK46BWJwZVeNuRu23CEMax8xZn3rtQkcTsooQtSuw1eqQpf7Z/jd6UEsoA7 GXOLuHawfT7ob0/qDvHAemoiwR/pgxu9GO4PY3y3K8VwEKp/ODZflGiAsLiSxS0iQ6IZ 9bHzeAE/Tm0EGo6NsXXE8cTLgqopDyrpOYBmBnDffVOkCqGrov+JmcsFfPoU4MBg9uCx nerUoUNBCwuJ1aZq7DdW9ix/488DZOyC1SvbNoEA28KZfLG0pqHO9PDe4bf+OpSHquUM h8tQ== X-Received: by 10.50.130.9 with SMTP id oa9mr1238173igb.4.1381494178779; Fri, 11 Oct 2013 05:22:58 -0700 (PDT) MIME-Version: 1.0 X-BeenThere: patchwork-forward@linaro.org Received: by 10.49.35.111 with SMTP id g15ls127505qej.21.gmail; Fri, 11 Oct 2013 05:22:58 -0700 (PDT) X-Received: by 10.220.237.208 with SMTP id kp16mr21192380vcb.4.1381494178667; Fri, 11 Oct 2013 05:22:58 -0700 (PDT) Received: from mail-vb0-f54.google.com (mail-vb0-f54.google.com [209.85.212.54]) by mx.google.com with ESMTPS id ta3si16570675vcb.146.1969.12.31.16.00.00 (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Fri, 11 Oct 2013 05:22:58 -0700 (PDT) Received-SPF: neutral (google.com: 209.85.212.54 is neither permitted nor denied by best guess record for domain of patch+caf_=patchwork-forward=linaro.org@linaro.org) client-ip=209.85.212.54; Received: by mail-vb0-f54.google.com with SMTP id q14so2683058vbe.41 for ; Fri, 11 Oct 2013 05:22:58 -0700 (PDT) X-Gm-Message-State: ALoCoQk/SddWIh3H2xb0JdtRJbNcW72NFctzrG+h89xfAiQ37VnbA81FVEFFdYBLDR43A3183ZbU X-Received: by 10.220.79.204 with SMTP id q12mr21070751vck.20.1381494178519; Fri, 11 Oct 2013 05:22:58 -0700 (PDT) X-Forwarded-To: patchwork-forward@linaro.org X-Forwarded-For: patch@linaro.org patchwork-forward@linaro.org Delivered-To: patches@linaro.org Received: by 10.220.174.196 with SMTP id u4csp34920vcz; Fri, 11 Oct 2013 05:22:57 -0700 (PDT) X-Received: by 10.68.234.10 with SMTP id ua10mr19832088pbc.116.1381494177435; Fri, 11 Oct 2013 05:22:57 -0700 (PDT) Received: from mail-pa0-f44.google.com (mail-pa0-f44.google.com [209.85.220.44]) by mx.google.com with ESMTPS id bc2si22047396pad.274.1969.12.31.16.00.00 (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Fri, 11 Oct 2013 05:22:57 -0700 (PDT) Received-SPF: neutral (google.com: 209.85.220.44 is neither permitted nor denied by best guess record for domain of ankit.jindal@linaro.org) client-ip=209.85.220.44; Received: by mail-pa0-f44.google.com with SMTP id lf10so4315564pab.17 for ; Fri, 11 Oct 2013 05:22:57 -0700 (PDT) X-Received: by 10.67.1.203 with SMTP id bi11mr21570316pad.137.1381494175480; Fri, 11 Oct 2013 05:22:55 -0700 (PDT) Received: from pnqlab023.amcc.com ([182.73.239.130]) by mx.google.com with ESMTPSA id uw6sm59608947pbc.8.1969.12.31.16.00.00 (version=TLSv1.1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Fri, 11 Oct 2013 05:22:54 -0700 (PDT) From: Ankit Jindal To: linux-arm-kernel@lists.infradead.org Cc: patches@linaro.org, linaro-networking@linaro.org, linaro-kernel@lists.linaro.org, steve.mcintyre@linaro.org, tushar.jagad@linaro.org, catalin.marinas@arm.com, Ankit Jindal Subject: [RFC PATCH 1/4] ARM64: Add Kconfig option to enable Big Endian kernel Date: Fri, 11 Oct 2013 17:52:12 +0530 Message-Id: <1381494135-15085-2-git-send-email-ankit.jindal@linaro.org> X-Mailer: git-send-email 1.7.9.5 In-Reply-To: <1381494135-15085-1-git-send-email-ankit.jindal@linaro.org> References: <1381494135-15085-1-git-send-email-ankit.jindal@linaro.org> X-Removed-Original-Auth: Dkim didn't pass. X-Original-Sender: ankit.jindal@linaro.org X-Original-Authentication-Results: mx.google.com; spf=neutral (google.com: 209.85.212.54 is neither permitted nor denied by best guess record for domain of patch+caf_=patchwork-forward=linaro.org@linaro.org) smtp.mail=patch+caf_=patchwork-forward=linaro.org@linaro.org Precedence: list Mailing-list: list patchwork-forward@linaro.org; contact patchwork-forward+owners@linaro.org List-ID: X-Google-Group-Id: 836684582541 List-Post: , List-Help: , List-Archive: List-Unsubscribe: , This patch adds Kconfig options and relevant Big Endian compiler flags. Signed-off-by: Ankit Jindal Signed-off-by: Tushar Jagad --- arch/arm64/Kconfig | 2 ++ arch/arm64/Makefile | 7 +++++++ arch/arm64/mm/Kconfig | 7 +++++++ 3 files changed, 16 insertions(+) create mode 100644 arch/arm64/mm/Kconfig diff --git a/arch/arm64/Kconfig b/arch/arm64/Kconfig index f558058..2214ab9 100644 --- a/arch/arm64/Kconfig +++ b/arch/arm64/Kconfig @@ -285,6 +285,8 @@ config SYSVIPC_COMPAT endmenu +source "arch/arm64/mm/Kconfig" + source "net/Kconfig" source "drivers/Kconfig" diff --git a/arch/arm64/Makefile b/arch/arm64/Makefile index d90cf79..c92b0f9 100644 --- a/arch/arm64/Makefile +++ b/arch/arm64/Makefile @@ -20,9 +20,16 @@ LIBGCC := $(shell $(CC) $(KBUILD_CFLAGS) -print-libgcc-file-name) KBUILD_DEFCONFIG := defconfig KBUILD_CFLAGS += -mgeneral-regs-only + +ifeq ($(CONFIG_CPU_BIG_ENDIAN),y) +KBUILD_CPPFLAGS += -mbig-endian +AS += -EB +LD += -EB +else KBUILD_CPPFLAGS += -mlittle-endian AS += -EL LD += -EL +endif comma = , diff --git a/arch/arm64/mm/Kconfig b/arch/arm64/mm/Kconfig new file mode 100644 index 0000000..e4122ac --- /dev/null +++ b/arch/arm64/mm/Kconfig @@ -0,0 +1,7 @@ +config CPU_BIG_ENDIAN + bool "Build big-endian kernel" + help + Say Y if you plan on running a kernel in big-endian mode. + Note that your board must be properly built and your board + port must properly enable any big-endian related features + of your chipset/board/processor.