samples: rust_misc_device: use vertical import style

Convert `use` imports to vertical layout for better readability and
maintainability.

Signed-off-by: Alvin Sun <alvin.sun@linux.dev>
Reviewed-by: Onur Özkan <work@onurozkan.dev>
Link: https://patch.msgid.link/20260520-miscdev-use-format-v2-2-64dc48fc1345@linux.dev
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
Alvin Sun
2026-05-20 10:40:09 +08:00
committed by Greg Kroah-Hartman
parent 1dbd8c44fc
commit bc58905eb0

View File

@@ -97,14 +97,36 @@
use kernel::{
device::Device,
fs::{File, Kiocb},
ioctl::{_IO, _IOC_SIZE, _IOR, _IOW},
iov::{IovIterDest, IovIterSource},
miscdevice::{MiscDevice, MiscDeviceOptions, MiscDeviceRegistration},
fs::{
File,
Kiocb, //
},
ioctl::{
_IO,
_IOC_SIZE,
_IOR,
_IOW, //
},
iov::{
IovIterDest,
IovIterSource, //
},
miscdevice::{
MiscDevice,
MiscDeviceOptions,
MiscDeviceRegistration, //
},
new_mutex,
prelude::*,
sync::{aref::ARef, Mutex},
uaccess::{UserSlice, UserSliceReader, UserSliceWriter},
sync::{
aref::ARef,
Mutex, //
},
uaccess::{
UserSlice,
UserSliceReader,
UserSliceWriter, //
},
};
const RUST_MISC_DEV_HELLO: u32 = _IO('|' as u32, 0x80);