Received: by 2002:a05:6a10:1287:0:0:0:0 with SMTP id d7csp3866653pxv; Mon, 19 Jul 2021 10:38:06 -0700 (PDT) X-Google-Smtp-Source: ABdhPJx32mCAOXDeu4DU3FUWu+6C9xLSLw3fqHwibk+yC+NvNd19EB0aXsnAVmjqaALgZDdcpNrB X-Received: by 2002:a17:906:f145:: with SMTP id gw5mr27584635ejb.249.1626716286173; Mon, 19 Jul 2021 10:38:06 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1626716286; cv=none; d=google.com; s=arc-20160816; b=pcAydksipe7k72pKJ3+GdVbWm4YGcfdbl3G4Zz73ihwGodvghiFudNNYbOcDfnWCTT 98Kyk8wfMK6UwdI0jsWG+HIYRmxn+lp+2gBdkuiNoSmPtmcWgmgLuWlxx/yaJZ9s145a 18GtCHTD3BGqC1Ov0mH/73VmX+7pj8KSZHc/w8P4jKVKrI/pScBE2XUEjydqNW9wgQRy pqa1my7eSjX8OVhif/RUzkwGVpDcgKuBYVQJ93zGomZJ2txgqa2PEL3tNWZ4md4fh7bo JSnz6BVf8CEh8eN3P27Sk0GccoEyRS4JRw/1Y/VxGnN/qxJvljzVn4DyE5Qb3A8UYVBO 459A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=MrHZMqnerbuQMdIQOCZB3sjT6jum44jZr7zwjtWNQ1I=; b=eax5+rLRuWGcFqqA1wG1KQgh7MtPzvq4WB+BSG6GKs7D1UZy0UKR3PstcPDJyt+YbA mEC0PpVU7wG3TECDl9QpgnGGUCyKUCZSiEH0hd/gzaeuyWwv6uT9Sn1e34wz/J/5uQ1y kjpTI8XcwlXL3lFt6YBJrp4kN3AKBZ0gnIRDId6MYssAd7toJiQSmmlNGJrebRo9eliF ndhUI0q0pfKKuFA97wqdc3HTc/B+2g1+VBfrf+MuH4YOupa/QIe5eHS3OqzoaQ/I4dfO wp4S9ZXDmkDzEOwh19jfUm45uI/4x4Ct/nvfWK7GE00BVIBdObSNB3MmLPkCuO52Prt5 RnJA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=gJ4oIgni; 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=linuxfoundation.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id m21si22989331edj.470.2021.07.19.10.37.43; Mon, 19 Jul 2021 10:38:06 -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=@linuxfoundation.org header.s=korg header.b=gJ4oIgni; 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=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1357913AbhGSQwb (ORCPT + 99 others); Mon, 19 Jul 2021 12:52:31 -0400 Received: from mail.kernel.org ([198.145.29.99]:59504 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1347823AbhGSPVu (ORCPT ); Mon, 19 Jul 2021 11:21:50 -0400 Received: by mail.kernel.org (Postfix) with ESMTPSA id 8B13161427; Mon, 19 Jul 2021 15:59:13 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1626710354; bh=wsIh+jGczAMVFbBo4ONafmK+bREhMF5LDyj1DJOuSng=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=gJ4oIgnizIAKSw77I7wndxe5N+y/z7N/509xmJW3/hXj8Dm+pwDmpL2NC0FRTSuqc rxm44m+yIEkmX7fY05j2ba+gn2Ouu05uRDfzv0r/JH0+5Bo1Jg5PLQiA5mXVxbQ3Xa GaEskEKTC019ZmHzjHAmNS0YlcmNKoNli30F7uc8= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, David Wysochanski , Chuck Lever , Steven Rostedt , "J. Bruce Fields" , Sasha Levin Subject: [PATCH 5.10 147/243] NFSD: Fix TP_printk() format specifier in nfsd_clid_class Date: Mon, 19 Jul 2021 16:52:56 +0200 Message-Id: <20210719144945.657682587@linuxfoundation.org> X-Mailer: git-send-email 2.32.0 In-Reply-To: <20210719144940.904087935@linuxfoundation.org> References: <20210719144940.904087935@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Chuck Lever [ Upstream commit a948b1142cae66785521a389cab2cce74069b547 ] Since commit 9a6944fee68e ("tracing: Add a verifier to check string pointers for trace events"), which was merged in v5.13-rc1, TP_printk() no longer tacitly supports the "%.*s" format specifier. These are low value tracepoints, so just remove them. Reported-by: David Wysochanski Fixes: dd5e3fbc1f47 ("NFSD: Add tracepoints to the NFSD state management code") Signed-off-by: Chuck Lever Cc: Steven Rostedt Signed-off-by: J. Bruce Fields Signed-off-by: Sasha Levin --- fs/nfsd/nfs4state.c | 3 --- fs/nfsd/trace.h | 29 ----------------------------- 2 files changed, 32 deletions(-) diff --git a/fs/nfsd/nfs4state.c b/fs/nfsd/nfs4state.c index ac20f79bbedd..80e394a2e3fd 100644 --- a/fs/nfsd/nfs4state.c +++ b/fs/nfsd/nfs4state.c @@ -7158,7 +7158,6 @@ nfs4_client_to_reclaim(struct xdr_netobj name, struct xdr_netobj princhash, unsigned int strhashval; struct nfs4_client_reclaim *crp; - trace_nfsd_clid_reclaim(nn, name.len, name.data); crp = alloc_reclaim(); if (crp) { strhashval = clientstr_hashval(name); @@ -7208,8 +7207,6 @@ nfsd4_find_reclaim_client(struct xdr_netobj name, struct nfsd_net *nn) unsigned int strhashval; struct nfs4_client_reclaim *crp = NULL; - trace_nfsd_clid_find(nn, name.len, name.data); - strhashval = clientstr_hashval(name); list_for_each_entry(crp, &nn->reclaim_str_hashtbl[strhashval], cr_strhash) { if (compare_blob(&crp->cr_name, &name) == 0) { diff --git a/fs/nfsd/trace.h b/fs/nfsd/trace.h index 99bf07800cd0..c8ca73d69ad0 100644 --- a/fs/nfsd/trace.h +++ b/fs/nfsd/trace.h @@ -368,35 +368,6 @@ DEFINE_EVENT(nfsd_net_class, nfsd_##name, \ DEFINE_NET_EVENT(grace_start); DEFINE_NET_EVENT(grace_complete); -DECLARE_EVENT_CLASS(nfsd_clid_class, - TP_PROTO(const struct nfsd_net *nn, - unsigned int namelen, - const unsigned char *namedata), - TP_ARGS(nn, namelen, namedata), - TP_STRUCT__entry( - __field(unsigned long long, boot_time) - __field(unsigned int, namelen) - __dynamic_array(unsigned char, name, namelen) - ), - TP_fast_assign( - __entry->boot_time = nn->boot_time; - __entry->namelen = namelen; - memcpy(__get_dynamic_array(name), namedata, namelen); - ), - TP_printk("boot_time=%16llx nfs4_clientid=%.*s", - __entry->boot_time, __entry->namelen, __get_str(name)) -) - -#define DEFINE_CLID_EVENT(name) \ -DEFINE_EVENT(nfsd_clid_class, nfsd_clid_##name, \ - TP_PROTO(const struct nfsd_net *nn, \ - unsigned int namelen, \ - const unsigned char *namedata), \ - TP_ARGS(nn, namelen, namedata)) - -DEFINE_CLID_EVENT(find); -DEFINE_CLID_EVENT(reclaim); - TRACE_EVENT(nfsd_clid_inuse_err, TP_PROTO(const struct nfs4_client *clp), TP_ARGS(clp), -- 2.30.2