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

fuzz_nvme_driver: use additional arbitrary inputs #628

Open
wants to merge 5 commits into
base: main
Choose a base branch
from

Conversation

gurasinghMS
Copy link
Contributor

Previously there were some hard coded values in the nvme fuzzer. These values are now being determined using the fuzzer input with arbitrary_data::<>()? command. See Issue: #521

@gurasinghMS gurasinghMS requested review from a team as code owners January 7, 2025 22:33
@gurasinghMS gurasinghMS changed the title Resolving all use-arbitrary-value tags Resolving [use-arbitrary-value] tags in the nvme fuzzer. See Issue #521 Jan 7, 2025
@mattkur mattkur changed the title Resolving [use-arbitrary-value] tags in the nvme fuzzer. See Issue #521 nvme_driver: fuzz_nvme_driver: use more arbitrary inputs Jan 7, 2025
@mattkur mattkur changed the title nvme_driver: fuzz_nvme_driver: use more arbitrary inputs fuzz_nvme_driver: use additional arbitrary inputs Jan 7, 2025
.await
.unwrap();

let device = FuzzEmulatedDevice::new(nvme, msi_set, mem);
let nvme_driver = NvmeDriver::new(&driver_source, 64, device).await.unwrap(); // TODO: [use-arbitrary-input]
let namespace = nvme_driver.namespace(1).await.unwrap(); // TODO: [use-arbitrary-input]
let nvme_driver = NvmeDriver::new(&driver_source, arbitrary_data::<u32>()?, device).await.unwrap();
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't think this will work ... in development of #585 , I tried to use arbitrary cpu here and ran into panic when issuing IO (and in other places).

So ... did your fuzzer not run into panics here? :)

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That's a great point. Local runs of the fuzzer don't seem to panic because of bad cpu (Maybe it is using a different seed to begin with?). Anywho, i will fix this :)

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Or, just wait for my PR and then revisit. This is one of those wonky areas - one of my devices ran into these quite quickly, but others have run for hours without any change.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

(by that, I mean - don't make the cpu arbitrary)

@mattkur
Copy link
Contributor

mattkur commented Jan 8, 2025

Thanks for the PR! Please fix the ci failures and make the cpu count fix, and then I'll take another look.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants