Received: by 2002:a05:6a10:f347:0:0:0:0 with SMTP id d7csp2926847pxu; Sun, 29 Nov 2020 09:11:30 -0800 (PST) X-Google-Smtp-Source: ABdhPJybsDbqn39ZZ9QQ6xR8VPGh45HYrtAbQflL6tFnH2RmOqlVMpqRvbqjUkXWQDf/2nxP4jWG X-Received: by 2002:a05:6402:149a:: with SMTP id e26mr18227678edv.232.1606669890396; Sun, 29 Nov 2020 09:11:30 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1606669890; cv=none; d=google.com; s=arc-20160816; b=B8MTnoSxmFczlfQSUpsCq4wfcToPsBXtuSbD1m6MVTAo3olE+G2RqCu90P9HxPE0vn shy+XDCHO36H7SgMYpcbgucwJ3/Extu3Kjk4bDZf1AsN5vHtzvVxhXp/fcp2gDnAOV4M /p1sJp8GZ3sc8vCCZ7kGOYyjLPFQo4y6ODI8GU21jFk14rOyPI0xbGHgz+ADJdHUoKUY 6nN0ukJ7GEytOlMPOKUaa0V6tGLWq9b966G8IKl1qnT9VdOhmGVRbb4sCMN2dJsK6Bcy sM+N09MXKJITq8PHU1Wz0ektZQjwfRUMG2tJbIpmydSSIpt7fIrKFuVMxvb6/lZAxoA3 jdpQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-language:content-transfer-encoding :in-reply-to:mime-version:user-agent:date:message-id:from:references :cc:to:subject:dkim-signature; bh=TyjVqTa6NUPGToY9p6hor+b7VRN4ayK0LceC/nKvy/8=; b=ANvk5RVyiD7fd4zpp/5S9C+AuM0eji846exdyY/AV83oXkjRowaQP6FyyU/3RK9ahR gT75YNGj32xf5mcbzJ9QjYaKBkYvG9oumnq14FF0mKOTG4azFu9ubaiZNOpCBTzz/uRN qTRiwP8lHroepIO4VC44B7iGZLlWv3sGcld/p6KUEgd3D19G0+QuiALVotJob/5KMo6E XKNw53Jy141DRiZ7b8r7mfe5KXdMmOoDtsAACaMO2ypi2e1y7cdmQus+IQ485Eh7zGGw boTuB6VK4TDr5AbXLD9dHmO19ws69fhHdi1lA08wQ2HqpItkmOHBktCdk7OaVXx1k8CC hCbg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=ZaMizYOK; spf=pass (google.com: domain of linux-nfs-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-nfs-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id y4si9546070edv.83.2020.11.29.09.10.57; Sun, 29 Nov 2020 09:11:30 -0800 (PST) Received-SPF: pass (google.com: domain of linux-nfs-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=@redhat.com header.s=mimecast20190719 header.b=ZaMizYOK; spf=pass (google.com: domain of linux-nfs-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-nfs-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728098AbgK2RIv (ORCPT + 99 others); Sun, 29 Nov 2020 12:08:51 -0500 Received: from us-smtp-delivery-124.mimecast.com ([216.205.24.124]:56318 "EHLO us-smtp-delivery-124.mimecast.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727879AbgK2RIv (ORCPT ); Sun, 29 Nov 2020 12:08:51 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1606669644; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=TyjVqTa6NUPGToY9p6hor+b7VRN4ayK0LceC/nKvy/8=; b=ZaMizYOKNep+3m0+JUy15Qlo+z9EzAS09CUQmKsD+V8Agd0EHH5xwOqfBe+3aaxHeThgV0 nLbpexWPFphZYxTAcLuOcbhWuIlSy0ASiwl4wRTbCb7VFMdkeV6gdjKeLJ5y+G0BMelcX4 plnSHaf/1gJ2lzfvL837PV0GY7oKbcs= Received: from mail-qt1-f198.google.com (mail-qt1-f198.google.com [209.85.160.198]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-327--q3dmLt2M9STNZZPJbmRuA-1; Sun, 29 Nov 2020 12:07:22 -0500 X-MC-Unique: -q3dmLt2M9STNZZPJbmRuA-1 Received: by mail-qt1-f198.google.com with SMTP id v18so6673993qta.22 for ; Sun, 29 Nov 2020 09:07:22 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:to:cc:references:from:message-id:date :user-agent:mime-version:in-reply-to:content-transfer-encoding :content-language; bh=TyjVqTa6NUPGToY9p6hor+b7VRN4ayK0LceC/nKvy/8=; b=aaa24wJmAUSOgWHLPsY92N/SzQaoxJUWrnQYIxhQ1JhiTFJ/dXdh5xriPWG01P02KO BY4AYnhAKxuKZaQSfMQPZ0YHiNtgFR/lqawGLjqhM+pwCEf6U2aj9GYduI3op9yY76hM J9vJlzFQOYb3hWvOOfCWgQK2ZBqT3eBPgKTXpTJwfCI6IqNWIwLng+KPtQGeVD131xWk RApNVgKOcnkusBBGIPYVw/vuFP1K1araQYQ2GEvoVilZlWZ4qwWxwbn5Ay+5AFRoZxv9 Z8tVoDhubuF4/z1ep3hWGI3Mrz4Fv3MR8vk5UDAF3AMGn3rxw1i6KAeqeTtJKAjhGrwa c95g== X-Gm-Message-State: AOAM532LdYUuZ2pFrzVrDdHgV9E0Y4NsnBPurDyeGcRmyggGC5p1Dh2V GXllf8XFBdZ1kpxqo36oW67cT+Xc4vw+QhyAp6VGhW565iHnSy6x5W4D27rL4vfw0AtzoPfnilA Y2N9m6/jBaZzrhns0sok3 X-Received: by 2002:ac8:6b92:: with SMTP id z18mr17731424qts.30.1606669641856; Sun, 29 Nov 2020 09:07:21 -0800 (PST) X-Received: by 2002:ac8:6b92:: with SMTP id z18mr17731398qts.30.1606669641579; Sun, 29 Nov 2020 09:07:21 -0800 (PST) Received: from trix.remote.csb (075-142-250-213.res.spectrum.com. [75.142.250.213]) by smtp.gmail.com with ESMTPSA id r125sm12970308qke.129.2020.11.29.09.07.19 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Sun, 29 Nov 2020 09:07:21 -0800 (PST) Subject: Re: [PATCH] NFS: remove trailing semicolon in macro definition To: Trond Myklebust , "bfields@fieldses.org" , "davem@davemloft.net" , "kuba@kernel.org" , "anna.schumaker@netapp.com" , "chuck.lever@oracle.com" Cc: "linux-nfs@vger.kernel.org" , "netdev@vger.kernel.org" , "linux-kernel@vger.kernel.org" References: <20201127194325.2881566-1-trix@redhat.com> <96657eff83195fba1762cb046b3f15d337e5daad.camel@hammerspace.com> <110444322a9c301c520c1e57e9a6f02b29ad25c1.camel@hammerspace.com> From: Tom Rix Message-ID: <4805ce94-b522-b774-031c-7091b7ac7c5e@redhat.com> Date: Sun, 29 Nov 2020 09:07:19 -0800 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.12.0 MIME-Version: 1.0 In-Reply-To: <110444322a9c301c520c1e57e9a6f02b29ad25c1.camel@hammerspace.com> Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit Content-Language: en-US Precedence: bulk List-ID: X-Mailing-List: linux-nfs@vger.kernel.org On 11/29/20 8:50 AM, Trond Myklebust wrote: > On Sun, 2020-11-29 at 16:42 +0000, Trond Myklebust wrote: >> Hi Tom, >> >> On Fri, 2020-11-27 at 11:43 -0800, trix@redhat.com wrote: >>> From: Tom Rix >>> >>> The macro use will already have a semicolon. >>> >>> Signed-off-by: Tom Rix >>> --- >>>  net/sunrpc/auth_gss/gss_generic_token.c | 2 +- >>>  1 file changed, 1 insertion(+), 1 deletion(-) >>> >>> diff --git a/net/sunrpc/auth_gss/gss_generic_token.c >>> b/net/sunrpc/auth_gss/gss_generic_token.c >>> index fe97f3106536..9ae22d797390 100644 >>> --- a/net/sunrpc/auth_gss/gss_generic_token.c >>> +++ b/net/sunrpc/auth_gss/gss_generic_token.c >>> @@ -46,7 +46,7 @@ >>>  /* TWRITE_STR from gssapiP_generic.h */ >>>  #define TWRITE_STR(ptr, str, len) \ >>>         memcpy((ptr), (char *) (str), (len)); \ >>> -       (ptr) += (len); >>> +       (ptr) += (len) >>>   >>>  /* XXXX this code currently makes the assumption that a mech oid >>> will >>>     never be longer than 127 bytes.  This assumption is not >>> inherent >>> in >> There is exactly 1 use of this macro in the code AFAICS. Can we >> please >> just get rid of it, and make the code trivially easier to read? >> > > BTW: To illustrate just how obfuscating this kind of macro can be, note > that the line you are changing above will be completely optimised away > in the 1 use case we're talking about. It is bumping a pointer value > that immediately gets discarded. Yes, I agree. I was wondering about expanding treewide, all the single shot macros defined/used in c files. other fixers that cleanup unused variables would remove the unneeded expansions like this one.