makeobjops.awk only accepts an uppercase DEFAULT before a default kobj method.
This commit fixes a typo introduced in 949804c81909 so non-PCI drivers actually
use nvme_is_storage_device_default instead of kobj_error_method. Note that even
though kobj_error_method returns ENXIO (6), it does not get implicitly cast to a
bool due to the function pointer casting in the nvme_if.h generated by
makeobjops. Instead the codegen for the NVME_IS_STORAGE_DEVICE callsite shows
that only the lowest bit is being checked as if it were always a bool. Without
this any nvme driver that doesn't implement is_storage_device is not treated as
a storage device.
Details
Details
I tested this on an out-of-tree nvme bus for an aarch64 machine. Without it the
nvme driver was not treated as a storage device and I was not able to mount the
root filesystem during boot.
Diff Detail
Diff Detail
- Repository
- rG FreeBSD src repository
- Lint
Lint Passed - Unit
No Test Coverage - Build Status
Buildable 77431 Build 74314: arc lint + arc unit