linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 1/2] rv/dot2c: Make automaton definition static
@ 2022-08-23 15:20 Daniel Bristot de Oliveira
  2022-08-23 15:20 ` [PATCH 2/2] rv/monitors: Make monitor's automata " Daniel Bristot de Oliveira
  2022-10-18 22:25 ` [PATCH 1/2] rv/dot2c: Make automaton " Steven Rostedt
  0 siblings, 2 replies; 6+ messages in thread
From: Daniel Bristot de Oliveira @ 2022-08-23 15:20 UTC (permalink / raw)
  To: Steven Rostedt
  Cc: linux-kernel, linux-trace-devel, Daniel Bristot de Oliveira,
	kernel test robot

Monitor's automata definition is only used locally, so make dot2c generate
a static definition.

Link: https://lore.kernel.org/all/202208210332.gtHXje45-lkp@intel.com
Link: https://lore.kernel.org/all/202208210358.6HH3OrVs-lkp@intel.com

Cc: Steven Rostedt <rostedt@goodmis.org>
Fixes: e3c9fc78f096 ("tools/rv: Add dot2c")
Reported-by: kernel test robot <lkp@intel.com>
Signed-off-by: Daniel Bristot de Oliveira <bristot@kernel.org>
---
 tools/verification/dot2/dot2c.py | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/tools/verification/dot2/dot2c.py b/tools/verification/dot2/dot2c.py
index fa73353f7e56..be8a364a469b 100644
--- a/tools/verification/dot2/dot2c.py
+++ b/tools/verification/dot2/dot2c.py
@@ -111,7 +111,7 @@ class Dot2c(Automata):
 
     def format_aut_init_header(self):
         buff = []
-        buff.append("struct %s %s = {" % (self.struct_automaton_def, self.var_automaton_def))
+        buff.append("static struct %s %s = {" % (self.struct_automaton_def, self.var_automaton_def))
         return buff
 
     def __get_string_vector_per_line_content(self, buff):
-- 
2.35.1


^ permalink raw reply related	[flat|nested] 6+ messages in thread

* [PATCH 2/2] rv/monitors: Make monitor's automata definition static
  2022-08-23 15:20 [PATCH 1/2] rv/dot2c: Make automaton definition static Daniel Bristot de Oliveira
@ 2022-08-23 15:20 ` Daniel Bristot de Oliveira
  2022-10-18 22:25 ` [PATCH 1/2] rv/dot2c: Make automaton " Steven Rostedt
  1 sibling, 0 replies; 6+ messages in thread
From: Daniel Bristot de Oliveira @ 2022-08-23 15:20 UTC (permalink / raw)
  To: Steven Rostedt
  Cc: linux-kernel, linux-trace-devel, Daniel Bristot de Oliveira,
	kernel test robot

Monitor's automata definition is only used locally, so make
them static for all existing monitors.

Link: https://lore.kernel.org/all/202208210332.gtHXje45-lkp@intel.com
Link: https://lore.kernel.org/all/202208210358.6HH3OrVs-lkp@intel.com

Cc: Steven Rostedt <rostedt@goodmis.org>
Fixes: ccc319dcb450 ("rv/monitor: Add the wwnr monitor")
Fixes: 8812d21219b9 ("rv/monitor: Add the wip monitor skeleton created by dot2k")
Reported-by: kernel test robot <lkp@intel.com>
Signed-off-by: Daniel Bristot de Oliveira <bristot@kernel.org>
---
 kernel/trace/rv/monitors/wip/wip.h   | 2 +-
 kernel/trace/rv/monitors/wwnr/wwnr.h | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/kernel/trace/rv/monitors/wip/wip.h b/kernel/trace/rv/monitors/wip/wip.h
index c1c47e2305ef..dacc37b62a2c 100644
--- a/kernel/trace/rv/monitors/wip/wip.h
+++ b/kernel/trace/rv/monitors/wip/wip.h
@@ -27,7 +27,7 @@ struct automaton_wip {
 	bool final_states[state_max_wip];
 };
 
-struct automaton_wip automaton_wip = {
+static struct automaton_wip automaton_wip = {
 	.state_names = {
 		"preemptive",
 		"non_preemptive"
diff --git a/kernel/trace/rv/monitors/wwnr/wwnr.h b/kernel/trace/rv/monitors/wwnr/wwnr.h
index d1afe55cdd4c..118e576b91b4 100644
--- a/kernel/trace/rv/monitors/wwnr/wwnr.h
+++ b/kernel/trace/rv/monitors/wwnr/wwnr.h
@@ -27,7 +27,7 @@ struct automaton_wwnr {
 	bool final_states[state_max_wwnr];
 };
 
-struct automaton_wwnr automaton_wwnr = {
+static struct automaton_wwnr automaton_wwnr = {
 	.state_names = {
 		"not_running",
 		"running"
-- 
2.35.1


^ permalink raw reply related	[flat|nested] 6+ messages in thread

* Re: [PATCH 1/2] rv/dot2c: Make automaton definition static
  2022-08-23 15:20 [PATCH 1/2] rv/dot2c: Make automaton definition static Daniel Bristot de Oliveira
  2022-08-23 15:20 ` [PATCH 2/2] rv/monitors: Make monitor's automata " Daniel Bristot de Oliveira
@ 2022-10-18 22:25 ` Steven Rostedt
  2022-10-18 22:28   ` Steven Rostedt
  2022-10-19 13:15   ` Daniel Bristot de Oliveira
  1 sibling, 2 replies; 6+ messages in thread
From: Steven Rostedt @ 2022-10-18 22:25 UTC (permalink / raw)
  To: Daniel Bristot de Oliveira
  Cc: linux-kernel, linux-trace-devel, kernel test robot

On Tue, 23 Aug 2022 17:20:28 +0200
Daniel Bristot de Oliveira <bristot@kernel.org> wrote:

> Monitor's automata definition is only used locally, so make dot2c generate
> a static definition.
> 
> Link: https://lore.kernel.org/all/202208210332.gtHXje45-lkp@intel.com
> Link: https://lore.kernel.org/all/202208210358.6HH3OrVs-lkp@intel.com
> 

Somehow this fell through the cracks.

Daniel, is there any reason I shouldn't pull this in now?

-- Steve

> Cc: Steven Rostedt <rostedt@goodmis.org>
> Fixes: e3c9fc78f096 ("tools/rv: Add dot2c")
> Reported-by: kernel test robot <lkp@intel.com>
> Signed-off-by: Daniel Bristot de Oliveira <bristot@kernel.org>
> ---
>  tools/verification/dot2/dot2c.py | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/tools/verification/dot2/dot2c.py b/tools/verification/dot2/dot2c.py
> index fa73353f7e56..be8a364a469b 100644
> --- a/tools/verification/dot2/dot2c.py
> +++ b/tools/verification/dot2/dot2c.py
> @@ -111,7 +111,7 @@ class Dot2c(Automata):
>  
>      def format_aut_init_header(self):
>          buff = []
> -        buff.append("struct %s %s = {" % (self.struct_automaton_def, self.var_automaton_def))
> +        buff.append("static struct %s %s = {" % (self.struct_automaton_def, self.var_automaton_def))
>          return buff
>  
>      def __get_string_vector_per_line_content(self, buff):


^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [PATCH 1/2] rv/dot2c: Make automaton definition static
  2022-10-18 22:25 ` [PATCH 1/2] rv/dot2c: Make automaton " Steven Rostedt
@ 2022-10-18 22:28   ` Steven Rostedt
  2022-10-19 13:15   ` Daniel Bristot de Oliveira
  1 sibling, 0 replies; 6+ messages in thread
From: Steven Rostedt @ 2022-10-18 22:28 UTC (permalink / raw)
  To: Daniel Bristot de Oliveira
  Cc: linux-kernel, linux-trace-devel, kernel test robot

On Tue, 18 Oct 2022 18:25:53 -0400
Steven Rostedt <rostedt@goodmis.org> wrote:

> On Tue, 23 Aug 2022 17:20:28 +0200
> Daniel Bristot de Oliveira <bristot@kernel.org> wrote:
> 
> > Monitor's automata definition is only used locally, so make dot2c generate
> > a static definition.
> > 
> > Link: https://lore.kernel.org/all/202208210332.gtHXje45-lkp@intel.com
> > Link: https://lore.kernel.org/all/202208210358.6HH3OrVs-lkp@intel.com
> >   
> 
> Somehow this fell through the cracks.
> 
> Daniel, is there any reason I shouldn't pull this in now?

I think when I applied:

  https://patchwork.kernel.org/project/linux-trace-devel/patch/a50e27c3738d6ef809f4201857229fed64799234.1661266564.git.bristot@kernel.org/

I mistook that to be a new version of this patch.

-- Steve

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [PATCH 1/2] rv/dot2c: Make automaton definition static
  2022-10-18 22:25 ` [PATCH 1/2] rv/dot2c: Make automaton " Steven Rostedt
  2022-10-18 22:28   ` Steven Rostedt
@ 2022-10-19 13:15   ` Daniel Bristot de Oliveira
  2022-10-20 20:55     ` Steven Rostedt
  1 sibling, 1 reply; 6+ messages in thread
From: Daniel Bristot de Oliveira @ 2022-10-19 13:15 UTC (permalink / raw)
  To: Steven Rostedt; +Cc: linux-kernel, linux-trace-devel, kernel test robot

On 10/19/22 00:25, Steven Rostedt wrote:
> On Tue, 23 Aug 2022 17:20:28 +0200
> Daniel Bristot de Oliveira <bristot@kernel.org> wrote:
> 
>> Monitor's automata definition is only used locally, so make dot2c generate
>> a static definition.
>>
>> Link: https://lore.kernel.org/all/202208210332.gtHXje45-lkp@intel.com
>> Link: https://lore.kernel.org/all/202208210358.6HH3OrVs-lkp@intel.com
>>
> Somehow this fell through the cracks.
> 
> Daniel, is there any reason I shouldn't pull this in now?

Oops... yes, it can be pulled.

-- Daniel

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [PATCH 1/2] rv/dot2c: Make automaton definition static
  2022-10-19 13:15   ` Daniel Bristot de Oliveira
@ 2022-10-20 20:55     ` Steven Rostedt
  0 siblings, 0 replies; 6+ messages in thread
From: Steven Rostedt @ 2022-10-20 20:55 UTC (permalink / raw)
  To: Daniel Bristot de Oliveira
  Cc: linux-kernel, linux-trace-devel, kernel test robot, Masami Hiramatsu

On Wed, 19 Oct 2022 15:15:54 +0200
Daniel Bristot de Oliveira <bristot@kernel.org> wrote:

> On 10/19/22 00:25, Steven Rostedt wrote:
> > On Tue, 23 Aug 2022 17:20:28 +0200
> > Daniel Bristot de Oliveira <bristot@kernel.org> wrote:
> >   
> >> Monitor's automata definition is only used locally, so make dot2c generate
> >> a static definition.
> >>
> >> Link: https://lore.kernel.org/all/202208210332.gtHXje45-lkp@intel.com
> >> Link: https://lore.kernel.org/all/202208210358.6HH3OrVs-lkp@intel.com
> >>  
> > Somehow this fell through the cracks.
> > 
> > Daniel, is there any reason I shouldn't pull this in now?  
> 
> Oops... yes, it can be pulled.
> 

OK, I'm going to push this up as tools/urgent and send a pull request to
Linus.

-- Steve

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2022-10-20 20:55 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-08-23 15:20 [PATCH 1/2] rv/dot2c: Make automaton definition static Daniel Bristot de Oliveira
2022-08-23 15:20 ` [PATCH 2/2] rv/monitors: Make monitor's automata " Daniel Bristot de Oliveira
2022-10-18 22:25 ` [PATCH 1/2] rv/dot2c: Make automaton " Steven Rostedt
2022-10-18 22:28   ` Steven Rostedt
2022-10-19 13:15   ` Daniel Bristot de Oliveira
2022-10-20 20:55     ` Steven Rostedt

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).