Received: by 2002:a05:6a10:9848:0:0:0:0 with SMTP id x8csp1410729pxf; Fri, 26 Mar 2021 07:22:12 -0700 (PDT) X-Google-Smtp-Source: ABdhPJybPoGp4dv8jMeaRZ1k25GDzucpmCrlqGHA+q9sM+rwrgfBgd5jT1iobuEee32QWAwBVZ0R X-Received: by 2002:a17:906:68c5:: with SMTP id y5mr15890480ejr.371.1616768531814; Fri, 26 Mar 2021 07:22:11 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1616768531; cv=none; d=google.com; s=arc-20160816; b=xHDBxPLVRC2F0gpilJyp/RQ9oqKcXisDDMesI3OlwTAUW8fY4LchZBDsuz5aV5/iOM YrVXNMdsUWV/Do7f98BkcRZwwizAd3wa/3sbZiMkncJ7bfynK56cA5ep+AWIY9l468gu KFeZRgpb+qB3/KSvtvVWctTgjFTkJkrvLqfQpoJSB4Aor75PC7oTKj6h5t2gjDH/+JVY O4wqvxXbZX9GreMN2wwuQRjmuBfvJq3g5QuCdIbS9dXTcugf4ncx44YLBNs8hBM1Ujta hBIXhghvVV0LkJaikIg+bg8eda0YseB907ZIDPHGiRULPspTc2EPwGG3DIdjfkfslYwO BBvQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:content-language :in-reply-to:mime-version:user-agent:date:message-id:from:references :cc:to:subject; bh=GMP9/WpdYDPhe0iXasPnsrZ7vkaotPoGQiHou4JqMD8=; b=zRiztB2ZRtMSz0G3/0eOO2EMZmNzzReWBonPWj5SJBKgjx6nstdo6A19A/K1Y1jF2l b7NUs9HkQchWFbZ2DItmk7Wnw2l/FMagIFQiaiAfY4X+AuaP7NCcC/X29d8ZuViFCYdK i3IQad95ZwGztdcQOpqofNHL3xgp242x6rb1WhmgoU0SOpOYWVbnVtmvAxjO2u/ZYUhu 7c5cwOh7zVH3aqOr95CjrSqXoz49KLXIeJ9TssfxS58klNsAZUuT559H2MYySgVptr5h J66XNJPi2hCJY8EQjiIc3a9OtF5QBnRSFg9eHV+n0SsC8g/q1D2RntdSgzWuJCtWnLsZ ZIQA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id lt12si6952637ejb.158.2021.03.26.07.21.48; Fri, 26 Mar 2021 07:22:11 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230240AbhCZOUv (ORCPT + 99 others); Fri, 26 Mar 2021 10:20:51 -0400 Received: from pegase1.c-s.fr ([93.17.236.30]:43073 "EHLO pegase1.c-s.fr" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230100AbhCZOU1 (ORCPT ); Fri, 26 Mar 2021 10:20:27 -0400 Received: from localhost (mailhub1-int [192.168.12.234]) by localhost (Postfix) with ESMTP id 4F6PJQ0zLJz9v03Q; Fri, 26 Mar 2021 15:20:22 +0100 (CET) X-Virus-Scanned: Debian amavisd-new at c-s.fr Received: from pegase1.c-s.fr ([192.168.12.234]) by localhost (pegase1.c-s.fr [192.168.12.234]) (amavisd-new, port 10024) with ESMTP id s0KOf5I51hUM; Fri, 26 Mar 2021 15:20:22 +0100 (CET) Received: from messagerie.si.c-s.fr (messagerie.si.c-s.fr [192.168.25.192]) by pegase1.c-s.fr (Postfix) with ESMTP id 4F6PJP6Vfbz9v0P3; Fri, 26 Mar 2021 15:20:21 +0100 (CET) Received: from localhost (localhost [127.0.0.1]) by messagerie.si.c-s.fr (Postfix) with ESMTP id 9B5C58B8CF; Fri, 26 Mar 2021 15:20:23 +0100 (CET) X-Virus-Scanned: amavisd-new at c-s.fr Received: from messagerie.si.c-s.fr ([127.0.0.1]) by localhost (messagerie.si.c-s.fr [127.0.0.1]) (amavisd-new, port 10023) with ESMTP id apm4h56oZ3Cq; Fri, 26 Mar 2021 15:20:23 +0100 (CET) Received: from [192.168.4.90] (unknown [192.168.4.90]) by messagerie.si.c-s.fr (Postfix) with ESMTP id 95C5C8B8C7; Fri, 26 Mar 2021 15:20:22 +0100 (CET) Subject: Re: [PATCH v3 11/17] riscv: Convert to GENERIC_CMDLINE To: Andreas Schwab Cc: will@kernel.org, danielwa@cisco.com, robh@kernel.org, daniel@gimpelevich.san-francisco.ca.us, linux-arch@vger.kernel.org, devicetree@vger.kernel.org, linuxppc-dev@lists.ozlabs.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, microblaze , linux-mips@vger.kernel.org, nios2 , openrisc@lists.librecores.org, linux-hexagon@vger.kernel.org, linux-riscv@lists.infradead.org, x86@kernel.org, linux-xtensa@linux-xtensa.org, linux-sh@vger.kernel.org, sparclinux@vger.kernel.org References: <46745e07b04139a22b5bd01dc37df97e6981e643.1616765870.git.christophe.leroy@csgroup.eu> <87zgyqdn3d.fsf@igel.home> From: Christophe Leroy Message-ID: <81a7e63f-57d4-5c81-acc5-35278fe5bb04@csgroup.eu> Date: Fri, 26 Mar 2021 15:20:20 +0100 User-Agent: Mozilla/5.0 (Windows NT 6.1; Win64; x64; rv:78.0) Gecko/20100101 Thunderbird/78.9.0 MIME-Version: 1.0 In-Reply-To: <87zgyqdn3d.fsf@igel.home> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: fr Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Le 26/03/2021 à 15:08, Andreas Schwab a écrit : > On Mär 26 2021, Christophe Leroy wrote: > >> diff --git a/arch/riscv/kernel/setup.c b/arch/riscv/kernel/setup.c >> index f8f15332caa2..e7c91ee478d1 100644 >> --- a/arch/riscv/kernel/setup.c >> +++ b/arch/riscv/kernel/setup.c >> @@ -20,6 +20,7 @@ >> #include >> #include >> #include >> +#include >> >> #include >> #include >> @@ -228,10 +229,8 @@ static void __init parse_dtb(void) >> } >> >> pr_err("No DTB passed to the kernel\n"); >> -#ifdef CONFIG_CMDLINE_FORCE >> - strlcpy(boot_command_line, CONFIG_CMDLINE, COMMAND_LINE_SIZE); >> + cmdline_build(boot_command_line, NULL, COMMAND_LINE_SIZE); >> pr_info("Forcing kernel command line to: %s\n", boot_command_line); > > Shouldn't that message become conditional in some way? > You are right, I did something similar on ARM but looks like I missed it on RISCV. Christophe