From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-alma10-1.taild15c8.ts.net [100.103.45.18]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 19A6B3264DC; Sat, 30 May 2026 16:47:51 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=100.103.45.18 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1780159672; cv=none; b=Afsy3blvKk/4QEkSD6ks2aWbxXLFBI+rpEWi6ZGUd0EEUSSlIRRWaPWnAcaJwti2KKnyYVExTYN/OlGarxEnckKiSQOcJbJYj38MdNrIqILetr2o1ly6xwvj9u9DrcSEVk3ys48QmIohynPy7xgAC3ZDl8r8KtKjvF/wsyVuy5A= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1780159672; c=relaxed/simple; bh=Ay/DTvjvROpLTH4MBeDQWBG8sJYGXflNnDFTPX+wklk=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=KtWHBqnRYU8TAUZUSMpvy70kVtXd08njV7yZ7FDb1++QgDhfjUWCroOgx+xUoCbIplcFrW4N/GySJB19fDSpWOALl3X/fgjKBWP8s7x5frifxl8paDF/x8q0lu2w08OysZvgK89fTAAtHxr5Cf/Mk5PtdKURGwjnv2wUPyNA7BI= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=MMzdhO5t; arc=none smtp.client-ip=100.103.45.18 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b="MMzdhO5t" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 0DC171F00893; Sat, 30 May 2026 16:47:48 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linuxfoundation.org; s=korg; t=1780159671; bh=+QAz4AS/HTKFOiVUqbXFXxrDQn2SRjN2JAKzRkcHoCU=; h=From:To:Cc:Subject:Date:In-Reply-To:References; b=MMzdhO5tSLf13bpWgUPdGXUn/dv/hOXu9hFUYSECNCJW6lYLCmdjMrjL0tmqt3FZh LCYI5WdXxxLjvphW6WwwPU8nX8LCrsIyUsJcxdHDNRnuO6Mh3/typczXwWP4nVxkaq ko75lI0goWCtms8gKiMSatPWwCbWBhpfVLHE0c+w= From: Greg Kroah-Hartman To: stable@vger.kernel.org Cc: Greg Kroah-Hartman , patches@lists.linux.dev, "stable@vger.kernel.org, devicetree@vger.kernel.org, Nathan Chancellor" , Nathan Chancellor Subject: [PATCH 6.1 139/969] scripts/dtc: Remove unused dts_version in dtc-lexer.l Date: Sat, 30 May 2026 17:54:23 +0200 Message-ID: <20260530160304.401346831@linuxfoundation.org> X-Mailer: git-send-email 2.53.0 In-Reply-To: <20260530160300.485627683@linuxfoundation.org> References: <20260530160300.485627683@linuxfoundation.org> User-Agent: quilt/0.69 X-stable: review X-Patchwork-Hint: ignore Precedence: bulk X-Mailing-List: patches@lists.linux.dev List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit 6.1-stable review patch. If anyone has any objections, please let me know. ------------------ From: Nathan Chancellor This patch is for stable only. Commit 5a09df20872c ("scripts/dtc: Update to upstream version v1.7.2-69-g53373d135579") upstream applied it as part of a regular scripts/dtc sync, which may be unsuitable for older versions of stable where the warning it fixes is present. A recent strengthening of -Wunused-but-set-variable (enabled with -Wall) in clang under a new subwarning, -Wunused-but-set-global, points out an unused static global variable in dtc-lexer.lex.c (compiled from dtc-lexer.l): scripts/dtc/dtc-lexer.lex.c:641:12: warning: variable 'dts_version' set but not used [-Wunused-but-set-global] 641 | static int dts_version = 1; | ^ Remove it to clear up the warning, as it is truly unused. Fixes: 658f29a51e98 ("of/flattree: Update dtc to current mainline.") Signed-off-by: Nathan Chancellor Signed-off-by: Greg Kroah-Hartman --- This should apply cleanly to all supported stable branches. Signed-off-by: Greg Kroah-Hartman --- scripts/dtc/dtc-lexer.l | 3 --- 1 file changed, 3 deletions(-) --- a/scripts/dtc/dtc-lexer.l +++ b/scripts/dtc/dtc-lexer.l @@ -39,8 +39,6 @@ extern bool treesource_error; #define DPRINT(fmt, ...) do { } while (0) #endif -static int dts_version = 1; - #define BEGIN_DEFAULT() DPRINT("\n"); \ BEGIN(V1); \ @@ -101,7 +99,6 @@ static void PRINTF(1, 2) lexical_error(c <*>"/dts-v1/" { DPRINT("Keyword: /dts-v1/\n"); - dts_version = 1; BEGIN_DEFAULT(); return DT_V1; }