Skip to contentSkip to conversation

blktrace on my block device

DISCUSSION Tao Ma 2 participants 3 messages Jul 7, 2011

lore
Share & tools
lore

Tao Ma

author
#0 lore raw
Quoted 10 lines · Gangadhar Mylapuram

Hi,

As for my understanding I no need to handle (BLKRESTART, BLKTRACESTOP, BLKTRACESETUP ..) in my device ioctl handling. It is block l/O layer which intercepts the
statistics and does the job.

But for my device (not sda or hda), blktrace only show the Q events. It is not showing even C (completed) events. Do I need to add the support in my device ioctl handling code?

These trace pointers are only recorded if they are met.
So I guess the reason is that your device implements your own make_request_fn(So you can see 'Q' event) and no other trace point is met at all.

Thanks,
Tao

#1 lore raw

Hi,

As for my understanding I no need to handle (BLKRESTART, BLKTRACESTOP, BLKTRACESETUP ..) in my device ioctl handling. It is block l/O layer which intercepts the
statistics and does the job.

But for my device (not sda or hda), blktrace only show the Q events. It is not showing even C (completed) events. Do I need to add the support in my device ioctl handling code?

Thanks,
Gangadhar

#2 lore raw
In reply to Tao Ma

Thanks. yes, that is the reason. I just found that our block driver is not using request queue because our device is flash memory.

-Gangadhar

Quoted 19 lines · Tao Ma
Quoted 10 lines · Gangadhar Mylapuram

Hi,

As for my understanding I no need to handle (BLKRESTART, BLKTRACESTOP, BLKTRACESETUP ..) in my device ioctl handling. It is block l/O layer which intercepts the
statistics and does the job.

But for my device (not sda or hda), blktrace only show the Q events. It is not showing even C (completed) events. Do I need to add the support in my device ioctl handling code?

These trace pointers are only recorded if they are met.
So I guess the reason is that your device implements your own make_request_fn(So you can see 'Q' event) and no other trace point is met at all.

Thanks,
Tao