Skip to content

Commit e57b33a

Browse files
committed
Reverted bounds juggling
1 parent 5ec6004 commit e57b33a

File tree

5 files changed

+6
-24
lines changed

5 files changed

+6
-24
lines changed

rust/kernel/sync/mutex.rs

+1-4
Original file line numberDiff line numberDiff line change
@@ -35,10 +35,7 @@ macro_rules! new_mutex {
3535
/// [`struct mutex`]: ../../../include/linux/mutex.h
3636
/// [init]: ../init/index.html
3737
#[pin_project]
38-
pub struct Mutex<T>
39-
where
40-
T: ?Sized,
41-
{
38+
pub struct Mutex<T: ?Sized> {
4239
/// The kernel `struct mutex` object.
4340
#[pin]
4441
mutex: Opaque<bindings::mutex>,

rust/kernel/sync/revocable.rs

+1-4
Original file line numberDiff line numberDiff line change
@@ -102,10 +102,7 @@ impl<T> Drop for Inner<T> {
102102
/// ```
103103
/// [init]: ../init/index.html
104104
#[pin_project]
105-
pub struct Revocable<F, T>
106-
where
107-
F: LockFactory,
108-
{
105+
pub struct Revocable<F: LockFactory, T> {
109106
#[pin]
110107
inner: <F as LockFactory>::LockedType<Inner<T>>,
111108
}

rust/kernel/sync/rwsem.rs

+1-4
Original file line numberDiff line numberDiff line change
@@ -40,10 +40,7 @@ macro_rules! new_rwsemaphore {
4040
/// [`struct rw_semaphore`]: ../../../include/linux/rwsem.h
4141
/// [init]: ../init/index.html
4242
#[pin_project]
43-
pub struct RwSemaphore<T>
44-
where
45-
T: ?Sized,
46-
{
43+
pub struct RwSemaphore<T: ?Sized> {
4744
/// The kernel `struct rw_semaphore` object.
4845
#[pin]
4946
rwsem: Opaque<bindings::rw_semaphore>,

rust/kernel/sync/seqlock.rs

+1-4
Original file line numberDiff line numberDiff line change
@@ -63,10 +63,7 @@ use core::{cell::UnsafeCell, marker::PhantomPinned, ops::Deref};
6363
/// ```
6464
/// [init]: ../init/index.html
6565
#[pin_project]
66-
pub struct SeqLock<L>
67-
where
68-
L: ?Sized + Lock,
69-
{
66+
pub struct SeqLock<L: ?Sized + Lock> {
7067
#[pin]
7168
_p: PhantomPinned,
7269
#[pin]

rust/kernel/sync/spinlock.rs

+2-8
Original file line numberDiff line numberDiff line change
@@ -83,10 +83,7 @@ macro_rules! new_spinlock {
8383
/// [`spinlock_t`]: ../../../include/linux/spinlock.h
8484
/// [init]: ../init/index.html
8585
#[pin_project]
86-
pub struct SpinLock<T>
87-
where
88-
T: ?Sized,
89-
{
86+
pub struct SpinLock<T: ?Sized> {
9087
#[pin]
9188
spin_lock: Opaque<bindings::spinlock>,
9289

@@ -277,10 +274,7 @@ macro_rules! new_rawspinlock {
277274
///
278275
/// [`raw_spinlock_t`]: ../../../include/linux/spinlock.h
279276
#[pin_project]
280-
pub struct RawSpinLock<T>
281-
where
282-
T: ?Sized,
283-
{
277+
pub struct RawSpinLock<T: ?Sized> {
284278
#[pin]
285279
spin_lock: Opaque<bindings::raw_spinlock>,
286280

0 commit comments

Comments
 (0)