From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752092AbcF1Ggl (ORCPT ); Tue, 28 Jun 2016 02:36:41 -0400 Received: from mail2.asahi-net.or.jp ([202.224.39.198]:57084 "EHLO mail2.asahi-net.or.jp" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750753AbcF1Ggj (ORCPT ); Tue, 28 Jun 2016 02:36:39 -0400 From: Yoshinori Sato To: linux-sh@veger.kernel.org, linux-kernel@vger.kernel.org Cc: Yoshinori Sato Subject: [PATCH v3 04/19] sh: command line passing chosen/bootargs in devicetree Date: Tue, 28 Jun 2016 15:36:20 +0900 Message-Id: <1467095795-5082-5-git-send-email-ysato@users.sourceforge.jp> X-Mailer: git-send-email 2.7.0 In-Reply-To: <1467095795-5082-1-git-send-email-ysato@users.sourceforge.jp> References: <1467095795-5082-1-git-send-email-ysato@users.sourceforge.jp> Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Signed-off-by: Yoshinori Sato --- arch/sh/kernel/setup.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/arch/sh/kernel/setup.c b/arch/sh/kernel/setup.c index 8e3b099..bdf57e5 100644 --- a/arch/sh/kernel/setup.c +++ b/arch/sh/kernel/setup.c @@ -280,6 +280,7 @@ void __init setup_arch(char **cmdline_p) #endif enable_mmu(); +#ifndef CONFIG_OF ROOT_DEV = old_decode_dev(ORIG_ROOT_DEV); printk(KERN_NOTICE "Boot params:\n" @@ -301,6 +302,7 @@ void __init setup_arch(char **cmdline_p) if (!MOUNT_ROOT_RDONLY) root_mountflags &= ~MS_RDONLY; +#endif init_mm.start_code = (unsigned long) _text; init_mm.end_code = (unsigned long) _etext; init_mm.end_data = (unsigned long) _edata; @@ -323,9 +325,13 @@ void __init setup_arch(char **cmdline_p) #endif #endif +#if !defined(CONFIG_OF) || defined(CONFIG_USE_BUILTIN_DTB) /* Save unparsed command line copy for /proc/cmdline */ memcpy(boot_command_line, command_line, COMMAND_LINE_SIZE); *cmdline_p = command_line; +#else + *cmdline_p = boot_command_line; +#endif parse_early_param(); -- 2.7.0