Skip to content

Commit

Permalink
rust: regulator: add abstraction for writing drivers
Browse files Browse the repository at this point in the history
This commit adds a Rust abstraction to write Regulator drivers. Only
the features used by the NCV6336 driver were added to this abstraction.

Signed-off-by: Fabien Parent <[email protected]>
  • Loading branch information
Fabo committed Mar 6, 2024
1 parent e352481 commit 2ddd7f5
Show file tree
Hide file tree
Showing 3 changed files with 752 additions and 0 deletions.
1 change: 1 addition & 0 deletions rust/bindings/bindings_helper.h
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@
#include <linux/refcount.h>
#include <linux/regmap.h>
#include <linux/regulator/consumer.h>
#include <linux/regulator/driver.h>
#include <linux/sched.h>
#include <linux/security.h>
#include <linux/slab.h>
Expand Down
1 change: 1 addition & 0 deletions rust/kernel/regulator.rs
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
//! SoC Regulators

pub mod consumer;
pub mod driver;

use crate::{
bindings,
Expand Down
Loading

0 comments on commit 2ddd7f5

Please sign in to comment.