From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-3.8 required=3.0 tests=BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 9C2F8C388F9 for ; Thu, 22 Oct 2020 16:14:51 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 4792D24182 for ; Thu, 22 Oct 2020 16:14:51 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2901587AbgJVQOu (ORCPT ); Thu, 22 Oct 2020 12:14:50 -0400 Received: from smtprelay0126.hostedemail.com ([216.40.44.126]:34006 "EHLO smtprelay.hostedemail.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S2901579AbgJVQOt (ORCPT ); Thu, 22 Oct 2020 12:14:49 -0400 Received: from filter.hostedemail.com (clb03-v110.bra.tucows.net [216.40.38.60]) by smtprelay04.hostedemail.com (Postfix) with ESMTP id 27835180A8459; Thu, 22 Oct 2020 16:14:48 +0000 (UTC) X-Session-Marker: 6A6F6540706572636865732E636F6D X-HE-Tag: plant29_570b19927252 X-Filterd-Recvd-Size: 1688 Received: from XPS-9350.home (unknown [47.151.133.149]) (Authenticated sender: joe@perches.com) by omf11.hostedemail.com (Postfix) with ESMTPA; Thu, 22 Oct 2020 16:14:47 +0000 (UTC) Message-ID: <3b706950110fe35c566dd00b684dc426867261e5.camel@perches.com> Subject: Re: [PATCH RFC] checkpatch: extend attributes check to handle more patterns From: Joe Perches To: Dwaipayan Ray Cc: linux-kernel-mentees@lists.linuxfoundation.org, linux-kernel , Lukas Bulwahn Date: Thu, 22 Oct 2020 09:14:45 -0700 In-Reply-To: References: <20201022145224.645538-1-dwaipayanray1@gmail.com> Content-Type: text/plain; charset="ISO-8859-1" User-Agent: Evolution 3.36.4-0ubuntu1 MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, 2020-10-22 at 20:29 +0530, Dwaipayan Ray wrote: > On Thu, Oct 22, 2020 at 8:22 PM Dwaipayan Ray wrote: > > It is generally preferred that the macros from > > include/linux/compiler_attributes.h are used, unless there > > is a reason not to. [] > I am a bit worried about the code size though. Is it better altogether > to have a shared function for parameterized/non parameterized > __attribute__ arguments? Might have to categorize the macros then. > > What do you think is better? I think A single shared mechanism better and more extensible. Renaming all the code types from PREFER_ to something else like PREFER_DEFINED_ATTRIBUTE_MACRO would be OK.