Re: PATCH 1/3] blktrace: support per-partition tracing

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

 



* Li Zefan <lizf@xxxxxxxxxxxxxx> wrote:

> From: Shawn Du <duyuyang@xxxxxxxxx>
> 
> Though one can specify '-d /dev/sda1' when using blktrace, it 
> still traces the whole sda.
> 
> To support per-partition tracing, when we start tracing, we 
> initialize bt->start_lba and bt->end_lba to the start and end 
> sector of that partition.
> 
> Note some actions are per device, thus we don't filter 0-sector 
> events.
> 
> The original patch and discussion can be found here:
> 	http://marc.info/?l=linux-btrace&m=122949374214540&w=2
> 
> Signed-off-by: Shawn Du <duyuyang@xxxxxxxxx>
> Signed-off-by: Li Zefan <lizf@xxxxxxxxxxxxxx>

Thanks - beyond the small detail i mailed about a few minutes ago 
the series looks good: i'll queue this up in tracing/blktrace unless 
Jens has second thoughts.

Lets note that this approach still has the (long existing) 
limitation that only one device can be block-traced at a time.

Furthermore, various other aspects of act_log_check() itself could 
be expressed in terms of per tracepoint filters as well: the PID 
filter field for example - which is supported in the ioctl ABI but 
currently not exposed in the user-space blktrace utility. Same goes 
for the action mask which is frequently used.

But before we can lift all these limitations and can have equivalent 
functionality in the generic event tracer we still need more filter 
engine infrastructure work (range operators and dev_t field 
support). Plus TRACE_EVENT() based blk tracepoints.

Once we have that, the conversion will be straightforward: all 
existing filter functionality of blktrace is static, so it will map 
directly to new-style filter expressions. That will give us block 
tracing for an arbitrary number of block devices (including the 
basic mode of 'trace all block IO in the system') and a much wider 
range of filtering capabilities.

Thanks,

	Ingo
--
To unsubscribe from this list: send the line "unsubscribe linux-btrace" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Netdev]     [Linux Wireless]     [Kernel Newbies]     [Security]     [Linux for Hams]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux Admin]     [Samba]

  Powered by Linux