Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add USDT probes for NVMe flush operations #494

Closed
wants to merge 1 commit into from
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 8 additions & 1 deletion lib/propolis/src/hw/nvme/requests.rs
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,9 @@ mod probes {

fn nvme_write_enqueue(cid: u16, off: u64, sz: u64) {}
fn nvme_write_complete(cid: u16) {}

fn nvme_flush_enqueue(cid: u16) {}
fn nvme_flush_complete(cid: u16) {}
}

impl block::Device for PciNvme {
Expand Down Expand Up @@ -97,6 +100,8 @@ impl PciNvme {
return Some(req);
}
Ok(NvmCmd::Flush) => {
probes::nvme_flush_enqueue!(|| (cid));

let req = Request::new_flush(
0,
0, // TODO: is 0 enough or do we pass total size?
Expand Down Expand Up @@ -137,7 +142,9 @@ impl PciNvme {
Operation::Write(..) => {
probes::nvme_write_complete!(|| (cid));
}
_ => {}
Operation::Flush(..) => {
probes::nvme_flush_complete!(|| (cid));
}
}

let mem = self.mem_access();
Expand Down
Loading