-
Notifications
You must be signed in to change notification settings - Fork 72
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
feat!: expand wdk-sys
coverage to include hid-related headers
#260
base: main
Are you sure you want to change the base?
Conversation
Signed-off-by: Melvin Wang <[email protected]>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Copilot reviewed 14 out of 28 changed files in this pull request and generated no comments.
Files not reviewed (14)
- .vscode/settings.json: Language not supported
- crates/wdk-sys/src/input.h: Language not supported
- crates/wdk-sys/src/wdf.c: Language not supported
- tests/umdf-driver-workspace/crates/driver_1/src/lib.rs: Evaluated as low risk
- examples/sample-kmdf-driver/src/lib.rs: Evaluated as low risk
- tests/umdf-driver-workspace/crates/driver_2/src/lib.rs: Evaluated as low risk
- examples/sample-umdf-driver/src/lib.rs: Evaluated as low risk
- tests/mixed-package-kmdf-workspace/crates/driver/src/lib.rs: Evaluated as low risk
- crates/wdk-build/src/bindgen.rs: Evaluated as low risk
- Cargo.toml: Evaluated as low risk
- crates/wdk-sys/src/lib.rs: Evaluated as low risk
- crates/wdk-sys/Cargo.toml: Evaluated as low risk
- crates/wdk-build/Cargo.toml: Evaluated as low risk
- examples/sample-wdm-driver/Cargo.toml: Evaluated as low risk
@@ -31,6 +31,9 @@ wdk-sys = { path = "../../crates/wdk-sys", version = "0.3.0" } | |||
|
|||
[features] | |||
default = [] | |||
|
|||
hid = ["wdk-sys/hid"] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
--all-features
should probably be passed to all the CI jobs for now. Eventually, we should probably use something like cargo-hack
for more thorough testing
This pull request introduces several significant changes to the
wdk-sys
andwdk-build
crates. The main changes include adding headers related to Windows HID support via a newhid
feature, and laying the groundwork for future features to be added to further expand API coverage. Bindgen input has moved from a static input header to a dynamically generated header passed to bindgen's header_contents method, allowing for the inputs to more easily be adaptable to different cargo features.HID Support:
crates/wdk-sys/build.rs
: Added thegenerate_hid
function to generate bindings for HID-related headers and avoid duplicate definitions.crates/wdk-sys/src/hid-input.h
: Added a new header file for HID input with the necessary includes and comments for future improvements.crates/wdk-sys/src/hid.rs
: Added a new source file for HID bindings, including the necessary modules and imports.crates/wdk-sys/src/lib.rs
: Added a new module for HID support, ensuring it is included for all driver models.Kernel Mode Definitions:
crates/wdk-build/src/lib.rs
: Updated theConfig
implementation to include_KERNEL_MODE
definition for both WDM and KMDF driver configurations.Import Reordering:
crates/wdk-sys/build.rs
: Reordered imports to group related items together and improve readability.Breaking Changes:
BREAKING CHANGE:
wdk_default
no longer takes in a list of c header files. Users are expected to specifyheaders
orheader_contents
via their respectivebindgen::Builder
APIs