Received: by 2002:a05:6a10:c7c6:0:0:0:0 with SMTP id h6csp629342pxy; Sat, 31 Jul 2021 20:02:28 -0700 (PDT) X-Google-Smtp-Source: ABdhPJy4c07sS0SQcBvFS9qEB3e8rSuhszK+3XshbtMJJ5knKAc7Ql4kzoCyLtW0g5FPKhfB58HK X-Received: by 2002:aa7:cb86:: with SMTP id r6mr11722711edt.181.1627786948371; Sat, 31 Jul 2021 20:02:28 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1627786948; cv=none; d=google.com; s=arc-20160816; b=helYUT54NtgSL7GNxNsauVXhovIRGOwZHJ3wEUQP4Kh/mKEexTdvB4WUDyi1glfWFY Qwq0gS+57Vpk54fUdTQw0OIy6pbDth/ZpF1on8bDEolj47JyozVGDVU5rJwM6ELgkBIr jQhmkW4AmG5TWTdaIPt2YCkdDdNiBzmH4Xj3XoHgER9IPxgjkIUFgACbwHQzSRvsp3xc XQDYovykNaIkJVeIHVq8dCUnlSlGhdTJeW03PpDRT6aTSUSi3QEPHsvmmzBe+vI9VCda rOAdrawnXd2cnxPAiZpNciX0mUjCX+ySPRM+cu69EI8oGOWwjYII3T0DquDoQyhRHSEr Zt7w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:subject:message-id:date:from:in-reply-to :references:mime-version:dkim-signature:dkim-filter; bh=JLMXmFWJsvNubT3+ZUP/uEKw77wJzyXbzMGUgT1DCaw=; b=XdOopG1Ts6geli5jklQuoGD+A1DEAPmUm6goyZgurEvIHQ1FtIDjWm+qMPwsFjVD8h rxmsRagmYrQYbXtq4fn5yunDnyxdFwVYMxJJzzGL1hd2tO47hE/M5GCgKcTlEaeZgrBZ CKLDNNXJHyInPYcXLaEOusBf5VD1bhRdxF1KDQ4IBepfddHcDR/OhAJJdi4obIUftV2f aQZdR79cfwiA2oslg9phzUBncHMfNeat5UK21qJjo83osaB57DzTrzrLGddshiv45olL oOg7B7L7GCU/4gnx3qICPM7Rl2ApF4fwXPwWod3QqEOVJpt7UWz3Fo85dp+eUBfrjcOC qNhA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@nifty.com header.s=dec2015msa header.b=XlsvPAzu; 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=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id v10si5794749eds.297.2021.07.31.20.02.04; Sat, 31 Jul 2021 20:02:28 -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=@nifty.com header.s=dec2015msa header.b=XlsvPAzu; 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=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230392AbhHADA7 (ORCPT + 99 others); Sat, 31 Jul 2021 23:00:59 -0400 Received: from conssluserg-05.nifty.com ([210.131.2.90]:20803 "EHLO conssluserg-05.nifty.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229761AbhHADA6 (ORCPT ); Sat, 31 Jul 2021 23:00:58 -0400 Received: from mail-pj1-f45.google.com (mail-pj1-f45.google.com [209.85.216.45]) (authenticated) by conssluserg-05.nifty.com with ESMTP id 17130LOM006884 for ; Sun, 1 Aug 2021 12:00:22 +0900 DKIM-Filter: OpenDKIM Filter v2.10.3 conssluserg-05.nifty.com 17130LOM006884 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nifty.com; s=dec2015msa; t=1627786822; bh=JLMXmFWJsvNubT3+ZUP/uEKw77wJzyXbzMGUgT1DCaw=; h=References:In-Reply-To:From:Date:Subject:To:Cc:From; b=XlsvPAzuXGoiILmIqWFaXZNh/N3RD1RwD85ttCtdEUKiFeUnTuXcjLn+eVhdMwlCc U+/HTKRo8Mb9YpxLbkgHN47w9RwHVh8fIgmWxyfOYsLdlyxc9VPRb1S7Wz+TgVWE8N K0/o6/vAYdRtJq8Ux13/TTfSwt9KXQFAkOWAIFfv20GpZV+f7JeRd2vrQTPddTJlK3 9GPE9QFSPg/2hYZc7zr1Yy98H+v2Pstc7EluXiimJlR31lSsx+GMMNTp6Sc7n3646A ZSwgSZgYOrzeOrUAEibykxrDLOXA6/tfj/lCsykk79zf3NKd+WSPId9jkhgmfVPNts fm4uKd2CwxWOQ== X-Nifty-SrcIP: [209.85.216.45] Received: by mail-pj1-f45.google.com with SMTP id nh14so8991322pjb.2 for ; Sat, 31 Jul 2021 20:00:22 -0700 (PDT) X-Gm-Message-State: AOAM533J2eSpj8TNQUYTwBxnVRdCUlPhtvZ9/d2wcwNQNaldQ9iX0DHM THAHit3A/gIT9dc41EN3U+iblMRdBtqrCqBclcU= X-Received: by 2002:aa7:8593:0:b029:32b:c173:cd96 with SMTP id w19-20020aa785930000b029032bc173cd96mr10328541pfn.63.1627786821471; Sat, 31 Jul 2021 20:00:21 -0700 (PDT) MIME-Version: 1.0 References: <20210727025737.30553-1-rdunlap@infradead.org> In-Reply-To: <20210727025737.30553-1-rdunlap@infradead.org> From: Masahiro Yamada Date: Sun, 1 Aug 2021 11:59:44 +0900 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: [PATCH] scripts: checkversion: modernize linux/version.h search strings To: Randy Dunlap Cc: Linux Kernel Mailing List , Andrew Morton Content-Type: text/plain; charset="UTF-8" Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Jul 27, 2021 at 11:57 AM Randy Dunlap wrote: > > Update scripts/checkversion.pl to recognize the current contents > of and both of its current locations. > > Also update my email address. > > Signed-off-by: Randy Dunlap > Cc: Masahiro Yamada > Cc: Andrew Morton > --- > scripts/checkversion.pl | 18 +++++++++++------- > 1 file changed, 11 insertions(+), 7 deletions(-) Applied to linux-kbuild. Thanks. > --- linux-next-20210723.orig/scripts/checkversion.pl > +++ linux-next-20210723/scripts/checkversion.pl > @@ -1,10 +1,10 @@ > #! /usr/bin/env perl > # SPDX-License-Identifier: GPL-2.0 > # > -# checkversion find uses of LINUX_VERSION_CODE or KERNEL_VERSION > -# without including , or cases of > -# including that don't need it. > -# Copyright (C) 2003, Randy Dunlap > +# checkversion finds uses of all macros in > +# where the source files do not #include ; or cases > +# of including where it is not needed. > +# Copyright (C) 2003, Randy Dunlap > > use strict; > > @@ -13,7 +13,8 @@ $| = 1; > my $debugging; > > foreach my $file (@ARGV) { > - next if $file =~ "include/linux/version\.h"; > + next if $file =~ "include/generated/uapi/linux/version\.h"; > + next if $file =~ "usr/include/linux/version\.h"; > # Open this file. > open( my $f, '<', $file ) > or die "Can't open $file: $!\n"; > @@ -41,8 +42,11 @@ foreach my $file (@ARGV) { > $iLinuxVersion = $. if m/^\s*#\s*include\s*/o; > } > > - # Look for uses: LINUX_VERSION_CODE, KERNEL_VERSION, UTS_RELEASE > - if (($_ =~ /LINUX_VERSION_CODE/) || ($_ =~ /\WKERNEL_VERSION/)) { > + # Look for uses: LINUX_VERSION_CODE, KERNEL_VERSION, > + # LINUX_VERSION_MAJOR, LINUX_VERSION_PATCHLEVEL, LINUX_VERSION_SUBLEVEL > + if (($_ =~ /LINUX_VERSION_CODE/) || ($_ =~ /\WKERNEL_VERSION/) || > + ($_ =~ /LINUX_VERSION_MAJOR/) || ($_ =~ /LINUX_VERSION_PATCHLEVEL/) || > + ($_ =~ /LINUX_VERSION_SUBLEVEL/)) { > $fUseVersion = 1; > last if $iLinuxVersion; > } -- Best Regards Masahiro Yamada