Received: by 2002:ac0:a5a6:0:0:0:0:0 with SMTP id m35-v6csp4971091imm; Tue, 18 Sep 2018 02:08:00 -0700 (PDT) X-Google-Smtp-Source: ANB0VdZyQy388ceTviXn9Sn8FALC9V+BY0NWlpwQfkjHUFTSstIE+/Ezu35XgHlJGeujtGSlC/vz X-Received: by 2002:a17:902:6b47:: with SMTP id g7-v6mr28927348plt.128.1537261680827; Tue, 18 Sep 2018 02:08:00 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1537261680; cv=none; d=google.com; s=arc-20160816; b=CraVc+ciPT7F3QKIfy2bZJUKU9ZcKBhmSZ7/uvkGODjg/wfA/WNLcSv1ydVU5knX+W u21n2yPxthI5IaHiY3+X+Z8EBtlSTrOdh1EeUUW8NqJNftFUcqiSPsInwWr+V302cUGc eA0RaxQTlncxnFPvLNH/ye9uN2FTUY3P7XzvE1WbDlLRd++kNZS8OQ087dKi1j8yRWCv TRxYaE02MbiJzVX1fZCMFUmAAKsgke8VMw4GDNmOFnzFO13J9zLDl7Fw5V41F2/AL/3g K10IVZ3uvskxgcMKt1tKGY4mXvJSQptuahVH7Fk2f843MeKc3CZ5vI4kcTjW0zqUq/w6 4REQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date:from :references:in-reply-to:mime-version:dkim-signature; bh=RAHJL0lGoWq6uWnB1ukyuHe+h39naM7YH9rnMFt9+Qc=; b=HkPeUY8N7KiLkqwnfDygogp4G8TlAVROFXFRJG0jh8Y9kd7sVsbtxhNb54ZypzUImw UBb8PTK36qGLkeiEXERR6YDyTRjL5fHkB2NJKZkKdQZjrfqZ1I/aypVc8KqZAysf4TuC MAM8tbM2d4DzZHFhdjakUSfak9IoAzDy8BbjYB8ZbKN325n8crpy8yqhEtQQXyBF5BIx GJWQHdmArUuXRZSMvZAkuvo4rFIlXXUaNA3exQIWRtk6Pbnly5rQwYymjIlxr+RhX0JJ s2RHZj141CRe0aRdqcpH28XTQEN0Fkr1KwRKexm7DowpnjSKDOWAZSrR6Pl6WPqD7Ep0 dUDQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=WHVP1Mv3; 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=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id d2-v6si18888813pfb.262.2018.09.18.02.07.44; Tue, 18 Sep 2018 02:08:00 -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=@linaro.org header.s=google header.b=WHVP1Mv3; 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=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729385AbeIROh7 (ORCPT + 99 others); Tue, 18 Sep 2018 10:37:59 -0400 Received: from mail-yw1-f68.google.com ([209.85.161.68]:42083 "EHLO mail-yw1-f68.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728645AbeIROh6 (ORCPT ); Tue, 18 Sep 2018 10:37:58 -0400 Received: by mail-yw1-f68.google.com with SMTP id n207-v6so469033ywn.9 for ; Tue, 18 Sep 2018 02:06:18 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc; bh=RAHJL0lGoWq6uWnB1ukyuHe+h39naM7YH9rnMFt9+Qc=; b=WHVP1Mv3C+P6QPGYITdxqnu9lCmDIfL3gru/kX3xrzaj9SrnwBMNF25a3rkMU+e9qU ub67R23G6prBJnFU+sKmEsEZfLIEfpmoSbJLNiGcMVSEuN4QhfBKy4hghbeLnavSA6jS xjvLwVFxAUeRPB37bWCmUmrvahzRsvDuzWB2M= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc; bh=RAHJL0lGoWq6uWnB1ukyuHe+h39naM7YH9rnMFt9+Qc=; b=Kw2qT7F6MGvBszEdqbsqELYBW+sCOhcpcd6LDFKKcrBp4Z+kzVG4Mu5mqr00odcqzh NBTvsUM2YFW/usMNosuWBvt4Uzktzx8wDC+4ixlQ0iq1a8nIB3juPT7A8PyO21koH+VT Xv3Ya+3pk4BdA68p24T0kETO5CyqKQ33bADw4hlSCYIK9MvqJZX/Q4AFT5To2qMpP8IE OZu7IIJYUQOUbeOrdUlgpJenCON0Gbh4Tv1CJ9n6SV+Qm8I6PF85Igi5yWidTjaK5Eez iTbnXhHMu2tK5gPrh/KmX3jYXYmyQNhv6sab7p0XmxYXLvNT64j2F7MVZtYwIKicKTMR j+yw== X-Gm-Message-State: APzg51B2QMOoG8FIuZRnvOocQVI1twl95aLzFFAkqC4uYfosUSRWaL/7 1lsyG4htyXWZ0R0GrM1uxvgyWfuw4cu/ZqI8OJ4nbg== X-Received: by 2002:a81:3b88:: with SMTP id i130-v6mr11338726ywa.82.1537261577574; Tue, 18 Sep 2018 02:06:17 -0700 (PDT) MIME-Version: 1.0 Received: by 2002:a0d:cc4f:0:0:0:0:0 with HTTP; Tue, 18 Sep 2018 02:06:17 -0700 (PDT) In-Reply-To: <20180810153852.720e2143@gandalf.local.home> References: <1533793005-4525-2-git-send-email-firoz.khan@linaro.org> <201808092020.H3Qhfo8m%fengguang.wu@intel.com> <20180810153852.720e2143@gandalf.local.home> From: Firoz Khan Date: Tue, 18 Sep 2018 14:36:17 +0530 Message-ID: Subject: Re: [PATCH 1/3] sh: Rename NR_syscalls macro to __NR_syscalls To: Steven Rostedt Cc: kbuild test robot , kbuild-all@01.org, linux-sh@vger.kernel.org, Yoshinori Sato , Rich Felker , Ingo Molnar , Greg Kroah-Hartman , Philippe Ombredanne , Thomas Gleixner , Kate Stewart , y2038 Mailman List , Linux Kernel Mailing List , Linux-Arch , Arnd Bergmann , Deepa Dinamani , Marcin Juszkiewicz Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 11 August 2018 at 01:08, Steven Rostedt wrote: > On Thu, 9 Aug 2018 20:58:58 +0800 > kbuild test robot wrote: > >> Hi Firoz, >> >> Thank you for the patch! Yet something to improve: >> >> [auto build test ERROR on linus/master] >> [also build test ERROR on v4.18-rc8 next-20180808] >> [if your patch is applied to the wrong git tree, please drop us a note to help improve the system] >> >> url: https://github.com/0day-ci/linux/commits/Firoz-Khan/sh-Rename-NR_syscalls-macro-to-__NR_syscalls/20180809-171759 >> config: sh-allmodconfig (attached as .config) >> compiler: sh4-linux-gnu-gcc (Debian 7.2.0-11) 7.2.0 >> reproduce: >> wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross >> chmod +x ~/bin/make.cross >> # save the attached .config to linux build tree >> GCC_VERSION=7.2.0 make.cross ARCH=sh >> >> All errors (new ones prefixed by >>): >> >> In file included from kernel/trace/trace_selftest_dynamic.c:3:0: >> >> kernel/trace/trace.h:243:53: error: 'NR_syscalls' undeclared here (not in a function); did you mean '__NR_syscalls'? >> struct trace_event_file __rcu *enter_syscall_files[NR_syscalls]; >> ^~~~~~~~~~~ >> __NR_syscalls >> -- >> In file included from kernel/trace/trace_output.h:6:0, >> from kernel/trace/trace_syscalls.c:12: >> >> kernel/trace/trace.h:243:53: error: 'NR_syscalls' undeclared here (not in a function); did you mean '__NR_syscalls'? >> struct trace_event_file __rcu *enter_syscall_files[NR_syscalls]; >> ^~~~~~~~~~~ >> __NR_syscalls > > Most archs have a: > > #define NR_syscalls __NR_syscalls Thanks for your reply! Sorry for the delayed response :( Yes. I'll add this change in the next version of the patch series. - Firoz > >> In file included from include/linux/smp.h:11:0, >> from include/linux/tracepoint.h:17, >> from include/trace/syscall.h:5, >> from kernel/trace/trace_syscalls.c:2: >> kernel/trace/trace_syscalls.c:559:23: warning: 'enabled_perf_exit_syscalls' defined but not used [-Wunused-variable] >> static DECLARE_BITMAP(enabled_perf_exit_syscalls, NR_syscalls); >> ^ >> include/linux/types.h:11:16: note: in definition of macro 'DECLARE_BITMAP' >> unsigned long name[BITS_TO_LONGS(bits)] >> ^~~~ >> kernel/trace/trace_syscalls.c:558:23: warning: 'enabled_perf_enter_syscalls' defined but not used [-Wunused-variable] >> static DECLARE_BITMAP(enabled_perf_enter_syscalls, NR_syscalls); >> ^ >> include/linux/types.h:11:16: note: in definition of macro 'DECLARE_BITMAP' >> unsigned long name[BITS_TO_LONGS(bits)] >> ^~~~ >> >> vim +243 kernel/trace/trace.h >> >> 490901078 Steven Rostedt (Red Hat 2015-09-24 196) >> bc0c38d13 Steven Rostedt 2008-05-12 197 /* >> bc0c38d13 Steven Rostedt 2008-05-12 198 * The trace array - an array of per-CPU trace arrays. This is the >> bc0c38d13 Steven Rostedt 2008-05-12 199 * highest level data structure that individual tracers deal with. >> bc0c38d13 Steven Rostedt 2008-05-12 200 * They have on/off state as well: >> bc0c38d13 Steven Rostedt 2008-05-12 201 */ >> bc0c38d13 Steven Rostedt 2008-05-12 202 struct trace_array { >> ae63b31e4 Steven Rostedt 2012-05-03 203 struct list_head list; >> 277ba0446 Steven Rostedt 2012-08-03 204 char *name; >> 12883efb6 Steven Rostedt (Red Hat 2013-03-05 205) struct trace_buffer trace_buffer; >> 12883efb6 Steven Rostedt (Red Hat 2013-03-05 206) #ifdef CONFIG_TRACER_MAX_TRACE >> 12883efb6 Steven Rostedt (Red Hat 2013-03-05 207) /* >> 12883efb6 Steven Rostedt (Red Hat 2013-03-05 208) * The max_buffer is used to snapshot the trace when a maximum >> 12883efb6 Steven Rostedt (Red Hat 2013-03-05 209) * latency is reached, or when the user initiates a snapshot. >> 12883efb6 Steven Rostedt (Red Hat 2013-03-05 210) * Some tracers will use this to store a maximum trace while >> 12883efb6 Steven Rostedt (Red Hat 2013-03-05 211) * it continues examining live traces. >> 12883efb6 Steven Rostedt (Red Hat 2013-03-05 212) * >> 12883efb6 Steven Rostedt (Red Hat 2013-03-05 213) * The buffers for the max_buffer are set up the same as the trace_buffer >> 12883efb6 Steven Rostedt (Red Hat 2013-03-05 214) * When a snapshot is taken, the buffer of the max_buffer is swapped >> 12883efb6 Steven Rostedt (Red Hat 2013-03-05 215) * with the buffer of the trace_buffer and the buffers are reset for >> 12883efb6 Steven Rostedt (Red Hat 2013-03-05 216) * the trace_buffer so the tracing can continue. >> 12883efb6 Steven Rostedt (Red Hat 2013-03-05 217) */ >> 12883efb6 Steven Rostedt (Red Hat 2013-03-05 218) struct trace_buffer max_buffer; >> 45ad21ca5 Steven Rostedt (Red Hat 2013-03-05 219) bool allocated_snapshot; >> f971cc9aa Steven Rostedt (Red Hat 2016-09-07 220) #endif >> f971cc9aa Steven Rostedt (Red Hat 2016-09-07 221) #if defined(CONFIG_TRACER_MAX_TRACE) || defined(CONFIG_HWLAT_TRACER) >> 6d9b3fa5e Steven Rostedt (Red Hat 2014-01-14 222) unsigned long max_latency; >> 12883efb6 Steven Rostedt (Red Hat 2013-03-05 223) #endif >> 490901078 Steven Rostedt (Red Hat 2015-09-24 224) struct trace_pid_list __rcu *filtered_pids; >> 0b9b12c1b Steven Rostedt (Red Hat 2014-01-14 225) /* >> 0b9b12c1b Steven Rostedt (Red Hat 2014-01-14 226) * max_lock is used to protect the swapping of buffers >> 0b9b12c1b Steven Rostedt (Red Hat 2014-01-14 227) * when taking a max snapshot. The buffers themselves are >> 0b9b12c1b Steven Rostedt (Red Hat 2014-01-14 228) * protected by per_cpu spinlocks. But the action of the swap >> 0b9b12c1b Steven Rostedt (Red Hat 2014-01-14 229) * needs its own lock. >> 0b9b12c1b Steven Rostedt (Red Hat 2014-01-14 230) * >> 0b9b12c1b Steven Rostedt (Red Hat 2014-01-14 231) * This is defined as a arch_spinlock_t in order to help >> 0b9b12c1b Steven Rostedt (Red Hat 2014-01-14 232) * with performance when lockdep debugging is enabled. >> 0b9b12c1b Steven Rostedt (Red Hat 2014-01-14 233) * >> 0b9b12c1b Steven Rostedt (Red Hat 2014-01-14 234) * It is also used in other places outside the update_max_tr >> 0b9b12c1b Steven Rostedt (Red Hat 2014-01-14 235) * so it needs to be defined outside of the >> 0b9b12c1b Steven Rostedt (Red Hat 2014-01-14 236) * CONFIG_TRACER_MAX_TRACE. >> 0b9b12c1b Steven Rostedt (Red Hat 2014-01-14 237) */ >> 0b9b12c1b Steven Rostedt (Red Hat 2014-01-14 238) arch_spinlock_t max_lock; >> 499e54705 Steven Rostedt 2012-02-22 239 int buffer_disabled; >> 12ab74ee0 Steven Rostedt 2012-08-08 240 #ifdef CONFIG_FTRACE_SYSCALLS >> 12ab74ee0 Steven Rostedt 2012-08-08 241 int sys_refcount_enter; >> 12ab74ee0 Steven Rostedt 2012-08-08 242 int sys_refcount_exit; >> 7f1d2f821 Steven Rostedt (Red Hat 2015-05-05 @243) struct trace_event_file __rcu *enter_syscall_files[NR_syscalls]; >> 7f1d2f821 Steven Rostedt (Red Hat 2015-05-05 244) struct trace_event_file __rcu *exit_syscall_files[NR_syscalls]; >> 12ab74ee0 Steven Rostedt 2012-08-08 245 #endif >> 2b6080f28 Steven Rostedt 2012-05-11 246 int stop_count; >> 2b6080f28 Steven Rostedt 2012-05-11 247 int clock_id; >> 37aea98b8 Steven Rostedt (Red Hat 2015-09-30 248) int nr_topts; >> 065e63f95 Steven Rostedt (VMware 2017-08-31 249) bool clear_trace; >> 2b6080f28 Steven Rostedt 2012-05-11 250 struct tracer *current_trace; >> 983f938ae Steven Rostedt (Red Hat 2015-09-30 251) unsigned int trace_flags; >> 9a38a8856 Steven Rostedt (Red Hat 2015-09-30 252) unsigned char trace_flags_index[TRACE_FLAGS_MAX_SIZE]; >> ae63b31e4 Steven Rostedt 2012-05-03 253 unsigned int flags; >> 2b6080f28 Steven Rostedt 2012-05-11 254 raw_spinlock_t start_lock; >> ae63b31e4 Steven Rostedt 2012-05-03 255 struct dentry *dir; >> 2b6080f28 Steven Rostedt 2012-05-11 256 struct dentry *options; >> 2b6080f28 Steven Rostedt 2012-05-11 257 struct dentry *percpu_dir; >> ae63b31e4 Steven Rostedt 2012-05-03 258 struct dentry *event_dir; >> 37aea98b8 Steven Rostedt (Red Hat 2015-09-30 259) struct trace_options *topts; >> ae63b31e4 Steven Rostedt 2012-05-03 260 struct list_head systems; >> ae63b31e4 Steven Rostedt 2012-05-03 261 struct list_head events; >> 3dd809536 Steven Rostedt (VMware 2018-05-09 262) struct trace_event_file *trace_marker_file; >> ccfe9e42e Alexander Z Lam 2013-08-08 263 cpumask_var_t tracing_cpumask; /* only trace on set CPUs */ >> a695cb581 Steven Rostedt (Red Hat 2013-03-06 264) int ref; >> f20a58062 Steven Rostedt (Red Hat 2013-11-07 265) #ifdef CONFIG_FUNCTION_TRACER >> f20a58062 Steven Rostedt (Red Hat 2013-11-07 266) struct ftrace_ops *ops; >> 345ddcc88 Steven Rostedt (Red Hat 2016-04-22 267) struct trace_pid_list __rcu *function_pids; >> 04ec7bb64 Steven Rostedt (VMware 2017-04-05 268) #ifdef CONFIG_DYNAMIC_FTRACE >> 673feb9d7 Steven Rostedt (VMware 2017-06-23 269) /* All of these are protected by the ftrace_lock */ >> 04ec7bb64 Steven Rostedt (VMware 2017-04-05 270) struct list_head func_probes; >> 673feb9d7 Steven Rostedt (VMware 2017-06-23 271) struct list_head mod_trace; >> 673feb9d7 Steven Rostedt (VMware 2017-06-23 272) struct list_head mod_notrace; >> 04ec7bb64 Steven Rostedt (VMware 2017-04-05 273) #endif >> f20a58062 Steven Rostedt (Red Hat 2013-11-07 274) /* function tracing enabled */ >> f20a58062 Steven Rostedt (Red Hat 2013-11-07 275) int function_enabled; >> f20a58062 Steven Rostedt (Red Hat 2013-11-07 276) #endif >> 00b414529 Tom Zanussi 2018-01-15 277 int time_stamp_abs_ref; >> 067fe038e Tom Zanussi 2018-01-15 278 struct list_head hist_vars; >> bc0c38d13 Steven Rostedt 2008-05-12 279 }; >> bc0c38d13 Steven Rostedt 2008-05-12 280 >> >> :::::: The code at line 243 was first introduced by commit >> :::::: 7f1d2f8210195c8c309d424a77dbf06a6d2186f4 tracing: Rename ftrace_event_file to trace_event_file >> >> :::::: TO: Steven Rostedt (Red Hat) >> :::::: CC: Steven Rostedt >> >> --- >> 0-DAY kernel test infrastructure Open Source Technology Center >> https://lists.01.org/pipermail/kbuild-all Intel Corporation >