Re: [PATCH v11 5/5] ring-buffer/selftest: Add ring-buffer mapping test

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Sun, 14 Jan 2024 23:17:11 +0900
Masami Hiramatsu (Google) <mhiramat@xxxxxxxxxx> wrote:
> > 
> > Looks good to me and tested.
> > 
> > Reviewed-by: Masami Hiramatsu (Google) <mhiramat@xxxxxxxxxx>
> > Tested-by: Masami Hiramatsu (Google) <mhiramat@xxxxxxxxxx>  
> 
> Sorry, I should cancel these. I found this test did not pass if I set
> the function tracer on.
> 
> / # cd /sys/kernel/tracing/
> /sys/kernel/tracing # echo function > current_tracer 
> /sys/kernel/tracing # /mnt/map_test 
> TAP version 13
> 1..2
> # Starting 2 tests from 2 test cases.
> #  RUN           map.subbuf_size_4k.meta_page_check ...
> # map_test.c:174:meta_page_check:Expected self->meta->entries (15293) == 16 (16)
> # meta_page_check: Test terminated by assertion
> #          FAIL  map.subbuf_size_4k.meta_page_check
> not ok 1 map.subbuf_size_4k.meta_page_check
> #  RUN           map.subbuf_size_8k.meta_page_check ...
> # map_test.c:174:meta_page_check:Expected self->meta->entries (15270) == 16 (16)
> # meta_page_check: Test terminated by assertion
> #          FAIL  map.subbuf_size_8k.meta_page_check
> not ok 2 map.subbuf_size_8k.meta_page_check
> # FAILED: 0 / 2 tests passed.
> # Totals: pass:0 fail:2 xfail:0 xpass:0 skip:0 error:0
> 
> Does this depend on "nop" tracer?

Yes.

> > > +
> > > +static int tracefs_reset(void)
> > > +{
> > > +	if (__tracefs_write_int(TRACEFS_ROOT"/tracing_on", 0))
> > > +		return -1;
> > > +	if (__tracefs_write_int(TRACEFS_ROOT"/trace", 0))
> > > +		return -1;
> > > +	if (__tracefs_write(TRACEFS_ROOT"/set_event", ""))
> > > +		return -1;

Looks like the below is needed:

	if (__traces_write(TRACEFS_ROOT"/current_tracer", "nop"))
		return -1;

> > > +
> > > +	return 0;
> > > +}
> > > +

-- Steve




[Index of Archives]     [Linux Wireless]     [Linux Kernel]     [ATH6KL]     [Linux Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [Share Photos]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Samba]     [Device Mapper]

  Powered by Linux