Received: by 2002:a25:6193:0:0:0:0:0 with SMTP id v141csp3358304ybb; Tue, 31 Mar 2020 03:42:40 -0700 (PDT) X-Google-Smtp-Source: ADFU+vuaX3qCds6H5CX66EhDOkKjGR50qCfoB+AmH0pdSb3COTtuz9z1FPvNczNDzW+O7cV80NA5 X-Received: by 2002:a05:6830:4038:: with SMTP id i24mr2774344ots.0.1585651360169; Tue, 31 Mar 2020 03:42:40 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1585651360; cv=none; d=google.com; s=arc-20160816; b=hNMytL8ZTsdE3m1xhzbiPmMZRtCRfmSI7T/IzpvXXSiLV+M2WTk3VvSGzsKgt6JsGW Tu54RqI3xseRv2QpaZ6P4eO4UBQef2uoNWSDd59EAqz8AfpQLBHVdg7DIegv8l4q/KaP laeRO9kKqMlFAqPM9mE6XB8x4cG+WqXSyHbl98P4/WWee5sShspZ2Q//UWIAHdtd2paY 4Ov0svo6Kuw3X+6QcdPeHPeMUTBzQRX0bSYgE6KJcYL76kzVZlYOauvOu4zePTUq+tV0 9O/aU0PhH8wdBfQUvuyj+UKZbcEjFDHCZmWRCKgP2HLtzY3J1B1vdKAg7TUmyflGqW2F zA7Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:in-reply-to:content-disposition :mime-version:references:message-id:subject:cc:to:from:date :dkim-signature; bh=8rKzWZmH2bjCeGeT3/AzL+62oYg6vXGE5u/evYUel8Q=; b=nTNnWQkgfhQxWBavOECmVLpGjpo9QOYBJuWT8c/sC4Tb+EtA3tbCTc/4JoADo+JGN7 8wKqzUxtICMgFeF2I0XIDYa1BbNFwmIDaWDW1YJQpK4s9E7RqjQvUBdLNziTVdUH9Mol Te4TypeA70gOXda5RHenv+WSKbP13OSN80gkMfmOwmFJwxBEz+ZhJoFBsxKn9qVzQMH6 zWvzI8D8QSXCqbPsxRLMLlQH4FQlqRP3bfte+WvxHnmQJmHRZ9xYJrpqCauc2YWKVaQd 3ZPm+mZWQXMuDDRbbQegatDlj0LbruqYcyCILXPSP/OJVr9EubpGYFLxCWzbgPxxEECl 9OjA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=QVDUBY08; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id z5si7956017otm.267.2020.03.31.03.42.28; Tue, 31 Mar 2020 03:42:40 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=QVDUBY08; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1730380AbgCaKmF (ORCPT + 99 others); Tue, 31 Mar 2020 06:42:05 -0400 Received: from mail.kernel.org ([198.145.29.99]:41268 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729925AbgCaKmF (ORCPT ); Tue, 31 Mar 2020 06:42:05 -0400 Received: from localhost (83-86-89-107.cable.dynamic.v4.ziggo.nl [83.86.89.107]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 35DC9208E0; Tue, 31 Mar 2020 10:42:02 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1585651322; bh=IMaARxto1wU2KuadB9baG/GU1gTRr4yDXBIObte9rUE=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=QVDUBY08T61oYJnGnL0TYd5PkxZhrsSrplWX1MhZo7JJEuh9dJxaOImZkAvEbAI5J hqGnj93Lfu+MKj1InKmcNS983cH/JEzFzymScBkzf5emnjN9TzSFzc9FPYu+7zIxDs YVtxYf1hxh5Rs16+hwNcZLrkddy47YtFvM+xcMD8= Date: Tue, 31 Mar 2020 12:02:38 +0200 From: Greg Kroah-Hartman To: Nathan Chancellor Cc: linux-kernel@vger.kernel.org, stable@vger.kernel.org, Dirk Mueller , David Gibson , Rob Herring Subject: Re: [PATCH 5.5 102/170] scripts/dtc: Remove redundant YYLOC global declaration Message-ID: <20200331100238.GA1204199@kroah.com> References: <20200331085423.990189598@linuxfoundation.org> <20200331085435.053942582@linuxfoundation.org> <20200331095323.GA32667@ubuntu-m2-xlarge-x86> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20200331095323.GA32667@ubuntu-m2-xlarge-x86> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Mar 31, 2020 at 02:53:23AM -0700, Nathan Chancellor wrote: > On Tue, Mar 31, 2020 at 10:58:36AM +0200, Greg Kroah-Hartman wrote: > > From: Dirk Mueller > > > > commit e33a814e772cdc36436c8c188d8c42d019fda639 upstream. > > > > gcc 10 will default to -fno-common, which causes this error at link > > time: > > > > (.text+0x0): multiple definition of `yylloc'; dtc-lexer.lex.o (symbol from plugin):(.text+0x0): first defined here > > > > This is because both dtc-lexer as well as dtc-parser define the same > > global symbol yyloc. Before with -fcommon those were merged into one > > defintion. The proper solution would be to to mark this as "extern", > > however that leads to: > > > > dtc-lexer.l:26:16: error: redundant redeclaration of 'yylloc' [-Werror=redundant-decls] > > 26 | extern YYLTYPE yylloc; > > | ^~~~~~ > > In file included from dtc-lexer.l:24: > > dtc-parser.tab.h:127:16: note: previous declaration of 'yylloc' was here > > 127 | extern YYLTYPE yylloc; > > | ^~~~~~ > > cc1: all warnings being treated as errors > > > > which means the declaration is completely redundant and can just be > > dropped. > > > > Signed-off-by: Dirk Mueller > > Signed-off-by: David Gibson > > [robh: cherry-pick from upstream] > > Cc: stable@vger.kernel.org > > Signed-off-by: Rob Herring > > Signed-off-by: Greg Kroah-Hartman > > > > --- > > scripts/dtc/dtc-lexer.l | 1 - > > 1 file changed, 1 deletion(-) > > > > --- a/scripts/dtc/dtc-lexer.l > > +++ b/scripts/dtc/dtc-lexer.l > > @@ -23,7 +23,6 @@ LINECOMMENT "//".*\n > > #include "srcpos.h" > > #include "dtc-parser.tab.h" > > > > -YYLTYPE yylloc; > > extern bool treesource_error; > > > > /* CAUTION: this will stop working if we ever use yyless() or yyunput() */ > > > > > > Hi Greg, > > Replying here simply because I am not subscribed to the stable-commits > mailing list and there does not appear to be an easy way to reply to one > of those emails through the existing archives because they are not as > nice as lore.kernel.org. > > This patch is fine for the current releases in review but 4.4, 4.9, and > 4.14 need to have the patch applied to scripts/dtc/dtc-lexer.lex.c_shipped > because prior to commit e039139be8c2 ("scripts/dtc: generate lexer and > parser during build instead of shipping"), that was the file that was > being built. Running the command below in the stable-queue repo works > for me and I have tested all of the patches to make sure they still > apply (albeit with some fuzz). > > $ sed -i 's;scripts/dtc/dtc-lexer.l;scripts/dtc/dtc-lexer.lex.c_shipped;g' \ > queue-{4.4,4.9,4.14}/scripts-dtc-remove-redundant-yyloc-global-declaration.patch > > If you would prefer a set of patches, let me know. Should I just drop the patch from 4.4, 4.9, and 4.14 instead? If not, yes, I can run the above script on the patches. thanks, greg k-h