Received: by 2002:a05:6a10:c604:0:0:0:0 with SMTP id y4csp3764028pxt; Tue, 10 Aug 2021 10:46:13 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxBGOoFRStjCVh6a/AvaxqlQRdWNg5//TVV9bq0jcXxGDjEE5oPdSRXpskZaqhf3vfcmbHk X-Received: by 2002:a5d:938a:: with SMTP id c10mr157111iol.0.1628617573341; Tue, 10 Aug 2021 10:46:13 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1628617573; cv=none; d=google.com; s=arc-20160816; b=NKm28bLFRTQj1kLkJWbPgPVeVzGcrkis6r8aFVQTiw6uLgJCssk9uQ/9CtpdSo8ads 2KGk8nX0t5x+DFCvo4WJ5z+my0jvhQJTWIAfG+RWmC8tWpNY8UlCzRn2zXtf1LBlLhXS KI0EB1vVToJU6/L9bHtrihVhamwRsT6+9el5FdqPnzx29aaGj6jW3UAtnKGsKoaSDwxl n35M1PDRdlym61M2ClHe1pSoYE0BvGMTCWw+rb5ApBoT2ZGc0RF/PCxbN3Afn4Ai7YbM AsW08E6A1BS5R40DT8sSVDVO4auWb9/0x7fRSl5Dq0o2puRawbx9NTXjQOYjaRzDU1pF JpQw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=buhWa6S44sfLfpOHJqaHfEMtQjbXrs8z+pkbROHqpR4=; b=YFsbJHZhf/1/VR2AI9EAeIWEDyG7JdTJo8R6EOyLtTjkjz+QNIY1dHPBIMX3NSgHhw NNTIymCB+ZsojlhLBqJ6wI3tH6Xoaon0CwNd6rdjSdT5qmea2+Itlbv7MWIntXSELENT //FptU2R2O7cNI3mJ3QZFm9Jw3+d+TOmXzcHObkOryxgQFwH9XRBNSh2Pt8Wn9q5IWAj GtdcGf0QuchGh8XBLMcsFwuZOOLDK4evrrb/5yKDVItimoi53AGbfT/yO1cwrwf5j3Xp DrsUw6PfLafQme73E6TSqPVuYG1+3wPJRwUAqJe1CTqBob2xugU/9Cj3WGGamK84ShQI nVZg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=cUOYNbFE; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id b11si29052785ilj.10.2021.08.10.10.46.01; Tue, 10 Aug 2021 10:46:13 -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; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=cUOYNbFE; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232312AbhHJRpi (ORCPT + 99 others); Tue, 10 Aug 2021 13:45:38 -0400 Received: from mail.kernel.org ([198.145.29.99]:60974 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232903AbhHJRlb (ORCPT ); Tue, 10 Aug 2021 13:41:31 -0400 Received: by mail.kernel.org (Postfix) with ESMTPSA id E55DF6120C; Tue, 10 Aug 2021 17:38:18 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1628617099; bh=eruWmCDdOrFlPApK/VNzIClH3t/nzTHsZ2nO7fXXNck=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=cUOYNbFEJ04nPrdNefx+fm2vor/rCLnGVtNIq2fdJz1PG9Vww1ch+6cltgOUN37Sv 9D8ODKeGqk1yUSehd3kj3AeHt9vKQp2zBPwsqxbds1V1/UkUBfa2Cn/dCcNyPAQO1/ IgmJO2KxmvIS6QY+cM3BVDLKcInHS9jYWXmYypGY= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, "H. Nikolaus Schaller" , Masahiro Yamada , Sasha Levin Subject: [PATCH 5.10 045/135] mips: Fix non-POSIX regexp Date: Tue, 10 Aug 2021 19:29:39 +0200 Message-Id: <20210810172957.221170580@linuxfoundation.org> X-Mailer: git-send-email 2.32.0 In-Reply-To: <20210810172955.660225700@linuxfoundation.org> References: <20210810172955.660225700@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: H. Nikolaus Schaller [ Upstream commit 28bbbb9875a35975904e46f9b06fa689d051b290 ] When cross compiling a MIPS kernel on a BSD based HOSTCC leads to errors like SYNC include/config/auto.conf.cmd - due to: .config egrep: empty (sub)expression UPD include/config/kernel.release HOSTCC scripts/dtc/dtc.o - due to target missing It turns out that egrep uses this egrep pattern: (|MINOR_|PATCHLEVEL_) This is not valid syntax or gives undefined results according to POSIX 9.5.3 ERE Grammar https://pubs.opengroup.org/onlinepubs/9699919799/basedefs/V1_chap09.html It seems to be silently accepted by the Linux egrep implementation while a BSD host complains. Such patterns can be replaced by a transformation like "(|p1|p2)" -> "(p1|p2)?" Fixes: 48c35b2d245f ("[MIPS] There is no __GNUC_MAJOR__") Signed-off-by: H. Nikolaus Schaller Signed-off-by: Masahiro Yamada Signed-off-by: Sasha Levin --- arch/mips/Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/arch/mips/Makefile b/arch/mips/Makefile index 686990fcc5f0..acab8018ab44 100644 --- a/arch/mips/Makefile +++ b/arch/mips/Makefile @@ -320,7 +320,7 @@ KBUILD_LDFLAGS += -m $(ld-emul) ifdef CONFIG_MIPS CHECKFLAGS += $(shell $(CC) $(KBUILD_CFLAGS) -dM -E -x c /dev/null | \ - egrep -vw '__GNUC_(|MINOR_|PATCHLEVEL_)_' | \ + egrep -vw '__GNUC_(MINOR_|PATCHLEVEL_)?_' | \ sed -e "s/^\#define /-D'/" -e "s/ /'='/" -e "s/$$/'/" -e 's/\$$/&&/g') endif -- 2.30.2