Skip to content
This repository was archived by the owner on Mar 7, 2021. It is now read-only.

Commit a562953

Browse files
committed
More updates
1 parent 7963376 commit a562953

File tree

2 files changed

+3
-10
lines changed

2 files changed

+3
-10
lines changed

src/filesystem.rs

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -36,12 +36,6 @@ bitflags::bitflags! {
3636
}
3737
}
3838

39-
impl FileSystemFlags {
40-
pub const fn const_empty() -> FileSystemFlags {
41-
FileSystemFlags { bits: 0 }
42-
}
43-
}
44-
4539
extern "C" fn fill_super_callback<T: FileSystem>(
4640
_sb: *mut bindings::super_block,
4741
_data: *mut c_types::c_void,

static-filesystem/src/lib.rs

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
#![no_std]
22

3-
#[macro_use]
4-
extern crate linux_kernel_module;
3+
use linux_kernel_module;
54

65
struct StaticFileSystemModule {
76
_fs: linux_kernel_module::filesystem::FileSystemRegistration<StaticFileSystem>,
@@ -20,10 +19,10 @@ struct StaticFileSystem;
2019
impl linux_kernel_module::filesystem::FileSystem for StaticFileSystem {
2120
const NAME: &'static str = "rust_static_filesystem\x00";
2221
const FLAGS: linux_kernel_module::filesystem::FileSystemFlags =
23-
linux_kernel_module::filesystem::FileSystemFlags::const_empty();
22+
linux_kernel_module::filesystem::FileSystemFlags::empty();
2423
}
2524

26-
kernel_module!(
25+
linux_kernel_module::kernel_module!(
2726
StaticFileSystemModule,
2827
author: "Alex Gaynor and Geoffrey Thomas",
2928
description: "An example Rust kernel module that implements a static file system",

0 commit comments

Comments
 (0)