From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 76608 invoked by alias); 7 Feb 2020 16:16:02 -0000 Mailing-List: contact systemtap-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Post: List-Help: , Sender: systemtap-owner@sourceware.org Received: (qmail 75715 invoked by uid 89); 7 Feb 2020 16:15:43 -0000 Authentication-Results: sourceware.org; auth=none X-Spam-SWARE-Status: No, score=-26.9 required=5.0 tests=BAYES_00,GIT_PATCH_0,GIT_PATCH_1,GIT_PATCH_2,GIT_PATCH_3,RCVD_IN_DNSWL_NONE autolearn=ham version=3.3.1 spammy=H*r:sk:systemt X-HELO: us-smtp-delivery-1.mimecast.com Received: from us-smtp-1.mimecast.com (HELO us-smtp-delivery-1.mimecast.com) (205.139.110.61) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Fri, 07 Feb 2020 16:15:24 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1581092108; 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; bh=VOr4J6F3uGwvwcwtLAw94BizUAEwzZyrIeLiuS1NYI0=; b=eGK9DT8zLMNgn2HNDbIMXBc1J/kKMiiA9d5DlLgNW7+DSj/CTGagxiofNH5ETIcdpRgRZ0 4yLK8HVbXdKuIyUkGu9kqQkHKRd+1amAhu4TWzlZDHzty04zL6ZR91CqluKDl9bF2hXK+Z iFID8ltvib4Az6wd7BLlVNV8NOPv98U= Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-384-c85UCkm5PsKuMg6kBB_-Rg-1; Fri, 07 Feb 2020 11:14:51 -0500 Received: from smtp.corp.redhat.com (int-mx05.intmail.prod.int.phx2.redhat.com [10.5.11.15]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id E4FE0DB61 for ; Fri, 7 Feb 2020 16:14:50 +0000 (UTC) Received: from hut.sorensonfamily.com.com (ovpn-116-92.phx2.redhat.com [10.3.116.92]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 3ADBC790EB; Fri, 7 Feb 2020 16:14:48 +0000 (UTC) From: Frank Sorenson To: systemtap@sourceware.org Cc: sorenson@redhat.com Subject: [PATCH] Fix vfs.open probe use of 'cred' variable Date: Fri, 07 Feb 2020 16:16:00 -0000 Message-Id: <20200207161446.676036-1-sorenson@redhat.com> MIME-Version: 1.0 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: quoted-printable X-SW-Source: 2020-q1/txt/msg00014.txt Commit f6d683666 adjusted the vfs.open probe to obtain the $cred target variable from a field of the $file target variable on kernels where $cred is not available. This change missed a second reference to the $cred target variable within the probe. Fix the reference to the possibly-unavailable target variable by referencing the systemtap variable just obtained. Fixes: Commit f6d683666 ("Adjust the vfs_open to provide cred variable with= 4.18 kernels") Signed-off-by: Frank Sorenson --- tapset/linux/vfs.stp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tapset/linux/vfs.stp b/tapset/linux/vfs.stp index 7505dfa32..d513ff970 100644 --- a/tapset/linux/vfs.stp +++ b/tapset/linux/vfs.stp @@ -1298,7 +1298,7 @@ probe vfs.open =3D kernel.function("vfs_open") ? path =3D $path cred =3D @defined($cred) ? $cred : $file->f_cred pathname =3D fullpath_struct_path($path) - argstr =3D sprintf("%s, %p", pathname, $cred) + argstr =3D sprintf("%s, %p", pathname, cred) } =20 probe vfs.open.return =3D kernel.function("vfs_open").return ? --=20 2.20.1