All of lore.kernel.org
 help / color / mirror / Atom feed
* [rostedt-trace:pmem-on-reserve-mem-fail 2/10] kernel/trace/ring_buffer.c:1943:34: warning: variable 'bmeta' set but not used
@ 2025-02-12  0:48 kernel test robot
  2025-02-12  0:54 ` Steven Rostedt
  0 siblings, 1 reply; 7+ messages in thread
From: kernel test robot @ 2025-02-12  0:48 UTC (permalink / raw)
  To: Steven Rostedt; +Cc: oe-kbuild-all

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/rostedt/linux-trace.git pmem-on-reserve-mem-fail
head:   d877ee1b587be39c141df16a6f92efb0e90b30fd
commit: 04e1e84239466de5fe5310ddc8899b8b404a5ccc [2/10] ring-buffer: Add buffer meta data for persistent ring buffer
config: i386-buildonly-randconfig-002-20250212 (https://download.01.org/0day-ci/archive/20250212/202502120851.VulVvSyg-lkp@intel.com/config)
compiler: gcc-12 (Debian 12.2.0-14) 12.2.0
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20250212/202502120851.VulVvSyg-lkp@intel.com/reproduce)

If you fix the issue in a separate patch/commit (i.e. not just a new version of
the same patch/commit), kindly add following tags
| Reported-by: kernel test robot <lkp@intel.com>
| Closes: https://lore.kernel.org/oe-kbuild-all/202502120851.VulVvSyg-lkp@intel.com/

All warnings (new ones prefixed by >>):

   kernel/trace/ring_buffer.c: In function 'rb_range_meta_init':
>> kernel/trace/ring_buffer.c:1943:34: warning: variable 'bmeta' set but not used [-Wunused-but-set-variable]
    1943 |         struct ring_buffer_meta *bmeta;
         |                                  ^~~~~


vim +/bmeta +1943 kernel/trace/ring_buffer.c

  1939	
  1940	static void rb_range_meta_init(struct trace_buffer *buffer, int nr_pages)
  1941	{
  1942		struct ring_buffer_cpu_meta *meta;
> 1943		struct ring_buffer_meta *bmeta;
  1944		unsigned long delta;
  1945		void *subbuf;
  1946		bool valid = false;
  1947		int cpu;
  1948		int i;
  1949	
  1950		if (rb_meta_init(buffer))
  1951			valid = true;
  1952	
  1953		bmeta = buffer->meta;
  1954	
  1955		for (cpu = 0; cpu < nr_cpu_ids; cpu++) {
  1956			void *next_meta;
  1957	
  1958			meta = rb_range_meta(buffer, nr_pages, cpu);
  1959	
  1960			if (valid && rb_cpu_meta_valid(meta, cpu, buffer, nr_pages)) {
  1961				/* Make the mappings match the current address */
  1962				subbuf = rb_subbufs_from_meta(meta);
  1963				delta = (unsigned long)subbuf - meta->first_buffer;
  1964				meta->first_buffer += delta;
  1965				meta->head_buffer += delta;
  1966				meta->commit_buffer += delta;
  1967				buffer->kaslr_addr = meta->kaslr_addr;
  1968				continue;
  1969			}
  1970	
  1971			if (cpu < nr_cpu_ids - 1)
  1972				next_meta = rb_range_meta(buffer, nr_pages, cpu + 1);
  1973			else
  1974				next_meta = (void *)buffer->range_addr_end;
  1975	
  1976			memset(meta, 0, next_meta - (void *)meta);
  1977	
  1978			meta->nr_subbufs = nr_pages + 1;
  1979			meta->subbuf_size = PAGE_SIZE;
  1980	
  1981			subbuf = rb_subbufs_from_meta(meta);
  1982	
  1983			meta->first_buffer = (unsigned long)subbuf;
  1984			rb_meta_init_text_addr(meta);
  1985	
  1986			/*
  1987			 * The buffers[] array holds the order of the sub-buffers
  1988			 * that are after the meta data. The sub-buffers may
  1989			 * be swapped out when read and inserted into a different
  1990			 * location of the ring buffer. Although their addresses
  1991			 * remain the same, the buffers[] array contains the
  1992			 * index into the sub-buffers holding their actual order.
  1993			 */
  1994			for (i = 0; i < meta->nr_subbufs; i++) {
  1995				meta->buffers[i] = i;
  1996				rb_init_page(subbuf);
  1997				subbuf += meta->subbuf_size;
  1998			}
  1999		}
  2000	}
  2001	

-- 
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki

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

* Re: [rostedt-trace:pmem-on-reserve-mem-fail 2/10] kernel/trace/ring_buffer.c:1943:34: warning: variable 'bmeta' set but not used
  2025-02-12  0:48 [rostedt-trace:pmem-on-reserve-mem-fail 2/10] kernel/trace/ring_buffer.c:1943:34: warning: variable 'bmeta' set but not used kernel test robot
@ 2025-02-12  0:54 ` Steven Rostedt
  2025-02-13  3:05   ` Philip Li
  0 siblings, 1 reply; 7+ messages in thread
From: Steven Rostedt @ 2025-02-12  0:54 UTC (permalink / raw)
  To: kernel test robot; +Cc: oe-kbuild-all


Hi,

I sometimes push WIP changes up to my repo to share with others that have
known issues in it. This branch being one of them. Is there any keyword
that I can add to the branch to make the kernel test robot not waste CPU
cycles on testing it?

Like: notest-my-wip-branch

or something?

Thanks,

-- Steve


On Wed, 12 Feb 2025 08:48:01 +0800
kernel test robot <lkp@intel.com> wrote:

> tree:   https://git.kernel.org/pub/scm/linux/kernel/git/rostedt/linux-trace.git pmem-on-reserve-mem-fail
> head:   d877ee1b587be39c141df16a6f92efb0e90b30fd
> commit: 04e1e84239466de5fe5310ddc8899b8b404a5ccc [2/10] ring-buffer: Add buffer meta data for persistent ring buffer
> config: i386-buildonly-randconfig-002-20250212 (https://download.01.org/0day-ci/archive/20250212/202502120851.VulVvSyg-lkp@intel.com/config)
> compiler: gcc-12 (Debian 12.2.0-14) 12.2.0
> reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20250212/202502120851.VulVvSyg-lkp@intel.com/reproduce)
> 
> If you fix the issue in a separate patch/commit (i.e. not just a new version of
> the same patch/commit), kindly add following tags
> | Reported-by: kernel test robot <lkp@intel.com>
> | Closes: https://lore.kernel.org/oe-kbuild-all/202502120851.VulVvSyg-lkp@intel.com/
> 
> All warnings (new ones prefixed by >>):
> 
>    kernel/trace/ring_buffer.c: In function 'rb_range_meta_init':
> >> kernel/trace/ring_buffer.c:1943:34: warning: variable 'bmeta' set but not used [-Wunused-but-set-variable]  
>     1943 |         struct ring_buffer_meta *bmeta;
>          |                                  ^~~~~
> 

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

* Re: [rostedt-trace:pmem-on-reserve-mem-fail 2/10] kernel/trace/ring_buffer.c:1943:34: warning: variable 'bmeta' set but not used
  2025-02-12  0:54 ` Steven Rostedt
@ 2025-02-13  3:05   ` Philip Li
  2025-02-13 16:42     ` Steven Rostedt
  0 siblings, 1 reply; 7+ messages in thread
From: Philip Li @ 2025-02-13  3:05 UTC (permalink / raw)
  To: Steven Rostedt; +Cc: kernel test robot, oe-kbuild-all

On Tue, Feb 11, 2025 at 07:54:21PM -0500, Steven Rostedt wrote:
> 
> Hi,
> 
> I sometimes push WIP changes up to my repo to share with others that have
> known issues in it. This branch being one of them. Is there any keyword
> that I can add to the branch to make the kernel test robot not waste CPU
> cycles on testing it?
> 
> Like: notest-my-wip-branch
> 
> or something?

Thanks Steve, by default, if the branch is named like below, it will be
ignored.

	.*experimental.*
	.*dont-build

If you prefer any customized branch name or pattern, you can also share
with us, e.g. ".*-wip". We can configure the bot per your needs.

Thanks

> 
> Thanks,
> 
> -- Steve
> 
> 
> On Wed, 12 Feb 2025 08:48:01 +0800
> kernel test robot <lkp@intel.com> wrote:
> 
> > tree:   https://git.kernel.org/pub/scm/linux/kernel/git/rostedt/linux-trace.git pmem-on-reserve-mem-fail
> > head:   d877ee1b587be39c141df16a6f92efb0e90b30fd
> > commit: 04e1e84239466de5fe5310ddc8899b8b404a5ccc [2/10] ring-buffer: Add buffer meta data for persistent ring buffer
> > config: i386-buildonly-randconfig-002-20250212 (https://download.01.org/0day-ci/archive/20250212/202502120851.VulVvSyg-lkp@intel.com/config)
> > compiler: gcc-12 (Debian 12.2.0-14) 12.2.0
> > reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20250212/202502120851.VulVvSyg-lkp@intel.com/reproduce)
> > 
> > If you fix the issue in a separate patch/commit (i.e. not just a new version of
> > the same patch/commit), kindly add following tags
> > | Reported-by: kernel test robot <lkp@intel.com>
> > | Closes: https://lore.kernel.org/oe-kbuild-all/202502120851.VulVvSyg-lkp@intel.com/
> > 
> > All warnings (new ones prefixed by >>):
> > 
> >    kernel/trace/ring_buffer.c: In function 'rb_range_meta_init':
> > >> kernel/trace/ring_buffer.c:1943:34: warning: variable 'bmeta' set but not used [-Wunused-but-set-variable]  
> >     1943 |         struct ring_buffer_meta *bmeta;
> >          |                                  ^~~~~
> > 
> 

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

* Re: [rostedt-trace:pmem-on-reserve-mem-fail 2/10] kernel/trace/ring_buffer.c:1943:34: warning: variable 'bmeta' set but not used
  2025-02-13  3:05   ` Philip Li
@ 2025-02-13 16:42     ` Steven Rostedt
  2025-02-14  3:24       ` Philip Li
  0 siblings, 1 reply; 7+ messages in thread
From: Steven Rostedt @ 2025-02-13 16:42 UTC (permalink / raw)
  To: Philip Li; +Cc: kernel test robot, oe-kbuild-all

On Thu, 13 Feb 2025 11:05:04 +0800
Philip Li <philip.li@intel.com> wrote:

> Thanks Steve, by default, if the branch is named like below, it will be
> ignored.
> 
> 	.*experimental.*
> 	.*dont-build
> 
> If you prefer any customized branch name or pattern, you can also share
> with us, e.g. ".*-wip". We can configure the bot per your needs.

No need. If I knew about that, I would have used it.

Actually, you can just remove my personal tree altogether. All my real
tracing code goes to:

  git://git.kernel.org/pub/scm/linux/kernel/git/trace/linux-trace.git

But I only push stuff to:

  https://git.kernel.org/pub/scm/linux/kernel/git/rostedt/linux-trace.git/

That I want to share with someone and not something heading toward mainline
(at least not in that state).

So, you can just remove the rostedt/linux-trace.git tree from being tested.

Thanks,

-- Steve

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

* Re: [rostedt-trace:pmem-on-reserve-mem-fail 2/10] kernel/trace/ring_buffer.c:1943:34: warning: variable 'bmeta' set but not used
  2025-02-13 16:42     ` Steven Rostedt
@ 2025-02-14  3:24       ` Philip Li
  2025-02-17 16:14         ` Steven Rostedt
  0 siblings, 1 reply; 7+ messages in thread
From: Philip Li @ 2025-02-14  3:24 UTC (permalink / raw)
  To: Steven Rostedt; +Cc: kernel test robot, oe-kbuild-all

On Thu, Feb 13, 2025 at 11:42:31AM -0500, Steven Rostedt wrote:
> On Thu, 13 Feb 2025 11:05:04 +0800
> Philip Li <philip.li@intel.com> wrote:
> 
> > Thanks Steve, by default, if the branch is named like below, it will be
> > ignored.
> > 
> > 	.*experimental.*
> > 	.*dont-build
> > 
> > If you prefer any customized branch name or pattern, you can also share
> > with us, e.g. ".*-wip". We can configure the bot per your needs.
> 
> No need. If I knew about that, I would have used it.
> 
> Actually, you can just remove my personal tree altogether. All my real
> tracing code goes to:
> 
>   git://git.kernel.org/pub/scm/linux/kernel/git/trace/linux-trace.git
> 
> But I only push stuff to:
> 
>   https://git.kernel.org/pub/scm/linux/kernel/git/rostedt/linux-trace.git/
> 
> That I want to share with someone and not something heading toward mainline
> (at least not in that state).
> 
> So, you can just remove the rostedt/linux-trace.git tree from being tested.

Got it, thanks for the info, I will remove this repo.

BTW: the 0day bot records 2 other repos from your side, do we need keep
them or also remove?

https://git.kernel.org/pub/scm/linux/kernel/git/rostedt/linux-ktest.git
https://git.kernel.org/pub/scm/linux/kernel/git/rostedt/linux-kconfig.git

> 
> Thanks,
> 
> -- Steve

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

* Re: [rostedt-trace:pmem-on-reserve-mem-fail 2/10] kernel/trace/ring_buffer.c:1943:34: warning: variable 'bmeta' set but not used
  2025-02-14  3:24       ` Philip Li
@ 2025-02-17 16:14         ` Steven Rostedt
  2025-02-18  0:33           ` Philip Li
  0 siblings, 1 reply; 7+ messages in thread
From: Steven Rostedt @ 2025-02-17 16:14 UTC (permalink / raw)
  To: Philip Li; +Cc: kernel test robot, oe-kbuild-all

On Fri, 14 Feb 2025 11:24:09 +0800
Philip Li <philip.li@intel.com> wrote:


> Got it, thanks for the info, I will remove this repo.
> 
> BTW: the 0day bot records 2 other repos from your side, do we need keep
> them or also remove?
> 
> https://git.kernel.org/pub/scm/linux/kernel/git/rostedt/linux-ktest.git

Although I do use this to send code upstream, you don't need to test this
repo, because ktest is a user space tool. Unless you are using the ktest
code (tools/testing/ktest/ktest.pl), there's nothing changing there that
would affect the kernel.

> https://git.kernel.org/pub/scm/linux/kernel/git/rostedt/linux-kconfig.git

This one I would still keep. I use it to modify the build system some
times, and this can cause regressions in the build of the Linux kernel.
I seldom modify it though, as I don't touch the build system that often.

-- Steve

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

* Re: [rostedt-trace:pmem-on-reserve-mem-fail 2/10] kernel/trace/ring_buffer.c:1943:34: warning: variable 'bmeta' set but not used
  2025-02-17 16:14         ` Steven Rostedt
@ 2025-02-18  0:33           ` Philip Li
  0 siblings, 0 replies; 7+ messages in thread
From: Philip Li @ 2025-02-18  0:33 UTC (permalink / raw)
  To: Steven Rostedt; +Cc: kernel test robot, oe-kbuild-all

On Mon, Feb 17, 2025 at 11:14:30AM -0500, Steven Rostedt wrote:
> On Fri, 14 Feb 2025 11:24:09 +0800
> Philip Li <philip.li@intel.com> wrote:
> 
> 
> > Got it, thanks for the info, I will remove this repo.
> > 
> > BTW: the 0day bot records 2 other repos from your side, do we need keep
> > them or also remove?
> > 
> > https://git.kernel.org/pub/scm/linux/kernel/git/rostedt/linux-ktest.git
> 
> Although I do use this to send code upstream, you don't need to test this
> repo, because ktest is a user space tool. Unless you are using the ktest
> code (tools/testing/ktest/ktest.pl), there's nothing changing there that
> would affect the kernel.

Thanks for info, currently we don't use this ktest.pl, and we will remove this repo.

> 
> > https://git.kernel.org/pub/scm/linux/kernel/git/rostedt/linux-kconfig.git
> 
> This one I would still keep. I use it to modify the build system some
> times, and this can cause regressions in the build of the Linux kernel.
> I seldom modify it though, as I don't touch the build system that often.

Got it, we will continue monitoring this one.

> 
> -- Steve

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

end of thread, other threads:[~2025-02-18  0:34 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-02-12  0:48 [rostedt-trace:pmem-on-reserve-mem-fail 2/10] kernel/trace/ring_buffer.c:1943:34: warning: variable 'bmeta' set but not used kernel test robot
2025-02-12  0:54 ` Steven Rostedt
2025-02-13  3:05   ` Philip Li
2025-02-13 16:42     ` Steven Rostedt
2025-02-14  3:24       ` Philip Li
2025-02-17 16:14         ` Steven Rostedt
2025-02-18  0:33           ` Philip Li

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.