Received: by 2002:a25:ad19:0:0:0:0:0 with SMTP id y25csp4165255ybi; Mon, 29 Jul 2019 20:41:14 -0700 (PDT) X-Google-Smtp-Source: APXvYqwUYz6/l334bCG6ubmj2Jh+7718dahoLgM6wX5fNIekLbaFxOPtsMLUIZtKanr6mPvWNHtY X-Received: by 2002:a62:cec4:: with SMTP id y187mr39398730pfg.84.1564458074533; Mon, 29 Jul 2019 20:41:14 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1564458074; cv=none; d=google.com; s=arc-20160816; b=GO5kDqKDb97qL58jvQf7Z/sUwVxbtdtioGr2OpZW9lWCOLT752b+sUpMvPJzlscwAH zp3GgHdGyh9qZEu904zHmNCtRORuJis7SrjLjxAuzUYl7Ef7LEcK/J0xJWLUBs6e1Gx2 +2ksnaLHbyrDSdJUevIlmAV8scc2NdqaPYCBCinSZaP2RjceZRHV2uM3wFc7frW7icK7 VGz1ECeiD3X9bvENAZrbjsd/unyfpmdL4XTYiAHReWTkI5q8iIY+yoUpq48hicPloiKa VB91ZrxDuWHS6+GVYC2Eolx3wjPuzuLx3LHBi2LxmTRJD95zEwcQWm6zwRPSP6uNODyR GT0g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:message-id:date :subject:cc:to:from:dkim-signature; bh=m3vqu7sDZ7UJADBAyxb1feCtycuAxPeOh7iKw94wR4g=; b=IVcZHC8ZPdv2fJ+1KqhlRxOWc8JAvyR7IDNLxiWcxXZiBjLRjQ2cwIPpj2rftuq77j GewHR0SgTo863CqcIyLsEoOcMm+36ZEGvPT6JlTs1QILw3BIXtGaBzKn6qW+JUwhzLaP KFF3DLMk12u8B8BxQTWjqxHzWu3WgmUXPzWFhOI0ReaMSExmvV0BR4Es5Y1UCEACj2Ve wZG172d6WJPWBz6mz9wfrMiczBpl6QVlAQsrz8MR58/Ts7Yp87CKffmhkIwFqcv3Dyjz 0jGSjsxu4utz/SRhj2XrvNnJyD1QMEKZhjh8wU6pnW3uuOFaatslH515TT8yfbsr0R7D 7wxg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@oracle.com header.s=corp-2018-07-02 header.b=LJcpIinR; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=oracle.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id v1si24915934plb.381.2019.07.29.20.40.59; Mon, 29 Jul 2019 20:41:14 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@oracle.com header.s=corp-2018-07-02 header.b=LJcpIinR; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=oracle.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1730093AbfG3ADR (ORCPT + 99 others); Mon, 29 Jul 2019 20:03:17 -0400 Received: from userp2120.oracle.com ([156.151.31.85]:36760 "EHLO userp2120.oracle.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1730073AbfG3ADQ (ORCPT ); Mon, 29 Jul 2019 20:03:16 -0400 Received: from pps.filterd (userp2120.oracle.com [127.0.0.1]) by userp2120.oracle.com (8.16.0.27/8.16.0.27) with SMTP id x6TNwoMR162451; Tue, 30 Jul 2019 00:02:47 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oracle.com; h=from : to : cc : subject : date : message-id : in-reply-to : references; s=corp-2018-07-02; bh=m3vqu7sDZ7UJADBAyxb1feCtycuAxPeOh7iKw94wR4g=; b=LJcpIinROwnWcWdkdEY6RWn5eVQKlIbXA2ISxhz9AJIDWbP6/X0DU/2C9oFJH1Tso2zA EGRMnz9XdrVFOOPrxEGpFI8DwqdL6FLxX6bVC40I5IP9DWxzOF31yzElI8f1fePCA5rZ xavOjOPfBRdMMkomCGkQhLmFIH8NbsRAQ4j2fYccnBTeNJA7swqwErlPr8C01htnCqqn uzv1HyBfLXeeQ2/ozW8n+q5kwLoTHdumUIW0mILskEgTTqm7CrtZcahUzEWBTRPKlvtS q7oNX1NqC3ngpnTvFQQ+XIuM0Zo8sYLVQj/d3JOTg0khzy0/nix1jVbar6eux5Kitssf 7Q== Received: from aserp3030.oracle.com (aserp3030.oracle.com [141.146.126.71]) by userp2120.oracle.com with ESMTP id 2u0f8qtpgr-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Tue, 30 Jul 2019 00:02:47 +0000 Received: from pps.filterd (aserp3030.oracle.com [127.0.0.1]) by aserp3030.oracle.com (8.16.0.27/8.16.0.27) with SMTP id x6TNvbSm039041; Tue, 30 Jul 2019 00:02:46 GMT Received: from userv0122.oracle.com (userv0122.oracle.com [156.151.31.75]) by aserp3030.oracle.com with ESMTP id 2u0xv7th8v-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Tue, 30 Jul 2019 00:02:46 +0000 Received: from abhmp0012.oracle.com (abhmp0012.oracle.com [141.146.116.18]) by userv0122.oracle.com (8.14.4/8.14.4) with ESMTP id x6U02jUq003732; Tue, 30 Jul 2019 00:02:45 GMT Received: from ca-common-hq.us.oracle.com (/10.211.9.209) by default (Oracle Beehive Gateway v4.0) with ESMTP ; Mon, 29 Jul 2019 17:02:45 -0700 From: Divya Indi To: linux-kernel@vger.kernel.org, Steven Rostedt Cc: Divya Indi , Joe Jin , Aruna Ramakrishna , Srinivas Eeda Subject: [PATCH 1/7] tracing: Required changes to use ftrace_set_clr_event. Date: Mon, 29 Jul 2019 17:02:28 -0700 Message-Id: <1564444954-28685-2-git-send-email-divya.indi@oracle.com> X-Mailer: git-send-email 1.8.3.1 In-Reply-To: <1564444954-28685-1-git-send-email-divya.indi@oracle.com> References: <1564444954-28685-1-git-send-email-divya.indi@oracle.com> X-Proofpoint-Virus-Version: vendor=nai engine=6000 definitions=9333 signatures=668685 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 suspectscore=0 malwarescore=0 phishscore=0 bulkscore=0 spamscore=0 mlxscore=0 mlxlogscore=999 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1906280000 definitions=main-1907290261 X-Proofpoint-Virus-Version: vendor=nai engine=6000 definitions=9333 signatures=668685 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 priorityscore=1501 malwarescore=0 suspectscore=0 phishscore=0 bulkscore=0 spamscore=0 clxscore=1015 lowpriorityscore=0 mlxscore=0 impostorscore=0 mlxlogscore=999 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1906280000 definitions=main-1907290261 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org As part of commit f45d1225adb0 ("tracing: Kernel access to Ftrace instances") ftrace_set_clr_event was exported, but for other kernel modules to use the function, we require the following additional changes 1. Removing the static keyword for this newly exported function. 2. Declaring it in the header file - include/linux/trace_events.h Signed-off-by: Divya Indi Reviewed-By: Aruna Ramakrishna --- include/linux/trace_events.h | 1 + kernel/trace/trace_events.c | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/include/linux/trace_events.h b/include/linux/trace_events.h index 8a62731..0f874fb 100644 --- a/include/linux/trace_events.h +++ b/include/linux/trace_events.h @@ -540,6 +540,7 @@ extern int trace_define_field(struct trace_event_call *call, const char *type, #define is_signed_type(type) (((type)(-1)) < (type)1) int trace_set_clr_event(const char *system, const char *event, int set); +int ftrace_set_clr_event(struct trace_array *tr, char *buf, int set); /* * The double __builtin_constant_p is because gcc will give us an error diff --git a/kernel/trace/trace_events.c b/kernel/trace/trace_events.c index 0ce3db6..b6b4618 100644 --- a/kernel/trace/trace_events.c +++ b/kernel/trace/trace_events.c @@ -795,7 +795,7 @@ static int __ftrace_set_clr_event(struct trace_array *tr, const char *match, return ret; } -static int ftrace_set_clr_event(struct trace_array *tr, char *buf, int set) +int ftrace_set_clr_event(struct trace_array *tr, char *buf, int set) { char *event = NULL, *sub = NULL, *match; int ret; -- 1.8.3.1