mirror of
https://github.com/asterinas/asterinas.git
synced 2025-06-28 03:43:23 +00:00
Add a runtime check for scheduler with spin locks
This commit is contained in:
committed by
Tate, Hongliang Tian
parent
08f50ac085
commit
9cb759efa2
@ -38,11 +38,11 @@ impl IfaceCommon {
|
||||
}
|
||||
}
|
||||
|
||||
pub(super) fn interface(&self) -> SpinLockIrqDisabledGuard<smoltcp::iface::Interface> {
|
||||
pub(super) fn interface(&self) -> SpinLockGuard<smoltcp::iface::Interface> {
|
||||
self.interface.lock_irq_disabled()
|
||||
}
|
||||
|
||||
pub(super) fn sockets(&self) -> SpinLockIrqDisabledGuard<smoltcp::iface::SocketSet<'static>> {
|
||||
pub(super) fn sockets(&self) -> SpinLockGuard<smoltcp::iface::SocketSet<'static>> {
|
||||
self.sockets.lock_irq_disabled()
|
||||
}
|
||||
|
||||
|
@ -65,11 +65,11 @@ mod internal {
|
||||
pub trait IfaceInternal {
|
||||
fn common(&self) -> &IfaceCommon;
|
||||
/// The inner socket set
|
||||
fn sockets(&self) -> SpinLockIrqDisabledGuard<SocketSet<'static>> {
|
||||
fn sockets(&self) -> SpinLockGuard<SocketSet<'static>> {
|
||||
self.common().sockets()
|
||||
}
|
||||
/// The inner iface.
|
||||
fn iface_inner(&self) -> SpinLockIrqDisabledGuard<smoltcp::iface::Interface> {
|
||||
fn iface_inner(&self) -> SpinLockGuard<smoltcp::iface::Interface> {
|
||||
self.common().interface()
|
||||
}
|
||||
/// The time we should do another poll.
|
||||
|
Reference in New Issue
Block a user