Received: by 2002:a05:6358:16cc:b0:ea:6187:17c9 with SMTP id r12csp1508890rwl; Thu, 5 Jan 2023 14:53:01 -0800 (PST) X-Google-Smtp-Source: AMrXdXuOU3h0sP60tLtc4Kc4yuRCaIX4IQVb74PRafI/txuC0hI7NQNVvvH7aUtajHClk/Vy5Bfq X-Received: by 2002:aa7:94b7:0:b0:583:a62:d840 with SMTP id a23-20020aa794b7000000b005830a62d840mr6271297pfl.29.1672959181210; Thu, 05 Jan 2023 14:53:01 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1672959181; cv=none; d=google.com; s=arc-20160816; b=fsqVTukdlEzHzCwgKa9uIrI+Db08AAoaQyf5N9hMnJfVg+1hv/5ISKtAuxinZiVoPY c6RcdOA0GU0GZadRBbMrWjiKNnsh/7oGyggupiozTioMtISl/ILuT0sUkRsTH1+HIvgJ CrF+j1qTrRsNoGAs/XWAwAY0223azI89O2hcp3cKNF1mBIfqVaRLkaZiwjKjThrbvqF5 r562sRKibjfdrxg45rZ7DWAvUCLdPFGWDrbo5tQ1zWRMdnweYoBujATH1I/lnHbt4nzH 5tkCDSrjRVG4JOob3q7UCsmhw749oRd9N0LGHsG/TuH4M2jqAHqLlMOIScXLAroQZvt5 F+bQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:user-agent :content-transfer-encoding:references:in-reply-to:date:cc:to:from :subject:message-id; bh=oGGwMpzgrzsD5O9zvpqlzuLdOV8A4iqw0qRumK438iA=; b=I/IzznMzklwzALZC8z47bvuwW1cyg82nZEQmZzlVN2ZqBOYU96MaKKPnOS10iOI/2I 7sqH7UObBCNc48BPXPFlkDvkZD3yYsVEnbiFEpf3I4Nw3j+oCBid0hBEEBMJxk3DCpS0 fc11hh0t7kX0RsvINNF75QrqdalsZL1trRG86Tpvqhp6TLlOCF0e1J3CCTE/+D/MvT7i 2LcEpA4g9RYCkWKqQce1miRDfziKXFJjJO852dByjoGm93qRhNo+AIPhh/4WPn7t8G/7 fmaI29XBFqcf0fB7SFPKCtZ+N7kfM6qQjkqy1McLHdaYC42D2pc7m3lx/gFJwL3fMsgh MgPw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id g4-20020a056a0023c400b005778bad9750si5349816pfc.17.2023.01.05.14.52.53; Thu, 05 Jan 2023 14:53:01 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S235717AbjAEWZF convert rfc822-to-8bit (ORCPT + 57 others); Thu, 5 Jan 2023 17:25:05 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:55304 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235605AbjAEWYe (ORCPT ); Thu, 5 Jan 2023 17:24:34 -0500 Received: from relay.hostedemail.com (smtprelay0012.hostedemail.com [216.40.44.12]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id C112B6B180 for ; Thu, 5 Jan 2023 14:24:32 -0800 (PST) Received: from omf15.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay05.hostedemail.com (Postfix) with ESMTP id 372BC4099C; Thu, 5 Jan 2023 22:24:31 +0000 (UTC) Received: from [HIDDEN] (Authenticated sender: joe@perches.com) by omf15.hostedemail.com (Postfix) with ESMTPA id F0A4D1A; Thu, 5 Jan 2023 22:24:28 +0000 (UTC) Message-ID: <435e1e0fd256bc2e58f0abe1255d9f13a786ca11.camel@perches.com> Subject: Re: [PATCH v2] checkpatch: Ignore ETHTOOL_LINK_MODE_ enum values From: Joe Perches To: Gerhard Engleder , linux-kernel@vger.kernel.org, Andrew Morton Cc: apw@canonical.com, dwaipayanray1@gmail.com, lukas.bulwahn@gmail.com Date: Thu, 05 Jan 2023 14:24:27 -0800 In-Reply-To: <20230104201524.28078-1-gerhard@engleder-embedded.com> References: <20230104201524.28078-1-gerhard@engleder-embedded.com> Content-Type: text/plain; charset="ISO-8859-1" Content-Transfer-Encoding: 8BIT User-Agent: Evolution 3.44.4 (3.44.4-2.fc36) MIME-Version: 1.0 X-Rspamd-Server: rspamout08 X-Rspamd-Queue-Id: F0A4D1A X-Stat-Signature: 35icq1hyn9cdhiepgdkqkbwgpzcce8dp X-Spam-Status: No, score=-0.9 required=5.0 tests=BAYES_00,FORGED_SPF_HELO, RCVD_IN_DNSWL_NONE,RCVD_IN_MSPIKE_H3,RCVD_IN_MSPIKE_WL,SPF_HELO_PASS, SPF_NONE,UNPARSEABLE_RELAY autolearn=no autolearn_force=no version=3.4.6 X-Session-Marker: 6A6F6540706572636865732E636F6D X-Session-ID: U2FsdGVkX19m6apyys1znSTNSVp7hTXcBoETH8aCbbA= X-HE-Tag: 1672957468-421589 X-HE-Meta: U2FsdGVkX18XfOpJ1qol28hLsx696dg5jhQaDAyXJ11Udt2ekWU0FdWTq7KxQkfNVp4BN2DFf12F8FZTVKKF2w== X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, 2023-01-04 at 21:15 +0100, Gerhard Engleder wrote: > Since commit 4104a20646 enum values like > ETHTOOL_LINK_MODE_Asym_Pause_BIT are ignored. But there are other enums > like ETHTOOL_LINK_MODE_1000baseT_Full_BIT, which are not ignored > because of the not matching '1000baseT' substring. > > Add regex to match all ETHTOOL_LINK_MODE enums. [] > diff --git a/scripts/checkpatch.pl b/scripts/checkpatch.pl [] > @@ -5783,6 +5783,8 @@ sub process { > $var !~ /^(?:[A-Z]+_){1,5}[A-Z]{1,3}[a-z]/ && > #Ignore Page variants > $var !~ /^(?:Clear|Set|TestClear|TestSet|)Page[A-Z]/ && > +#Ignore ETHTOOL_LINK_MODE_ variants > + $var !~ /^ETHTOOL_LINK_MODE_/ && > #Ignore SI style variants like nS, mV and dB > #(ie: max_uV, regulator_min_uA_show, RANGE_mA_VALUE) > $var !~ /^(?:[a-z0-9_]*|[A-Z0-9_]*)?_?[a-z][A-Z](?:_[a-z0-9_]+|_[A-Z0-9_]+)?$/ && These ETHTOOL enums also exist but are caught by the SI style variants test ETHTOOL_A_CABLE_PULSE_mV ETHTOOL_A_CABLE_AMPLITUDE_mV So I guess it's OK. Thanks.