aboutsummaryrefslogtreecommitdiff
path: root/src/include
diff options
context:
space:
mode:
authorMichael Brown <mcb30@ipxe.org>2014-03-14 14:05:38 +0000
committerMichael Brown <mcb30@ipxe.org>2014-03-14 14:05:38 +0000
commit87465258abbd1056c8be4e934385d6c7197dc655 (patch)
tree930d2882cef8f9671839dde9945517e7b37bedbd /src/include
parent24bbaf6a38f52ef7e942fb4cea36529091af2a0c (diff)
downloadipxe-87465258abbd1056c8be4e934385d6c7197dc655.zip
ipxe-87465258abbd1056c8be4e934385d6c7197dc655.tar.gz
ipxe-87465258abbd1056c8be4e934385d6c7197dc655.tar.bz2
[netdevice] Notify upper-layer drivers when RX processing is (un)frozen
Signed-off-by: Michael Brown <mcb30@ipxe.org>
Diffstat (limited to 'src/include')
-rw-r--r--src/include/ipxe/netdevice.h22
1 files changed, 2 insertions, 20 deletions
diff --git a/src/include/ipxe/netdevice.h b/src/include/ipxe/netdevice.h
index 2ea3c8b..6ef9cb1 100644
--- a/src/include/ipxe/netdevice.h
+++ b/src/include/ipxe/netdevice.h
@@ -658,6 +658,8 @@ netdev_rx_frozen ( struct net_device *netdev ) {
return ( netdev->state & NETDEV_RX_FROZEN );
}
+extern void netdev_rx_freeze ( struct net_device *netdev );
+extern void netdev_rx_unfreeze ( struct net_device *netdev );
extern void netdev_link_err ( struct net_device *netdev, int rc );
extern void netdev_link_down ( struct net_device *netdev );
extern int netdev_tx ( struct net_device *netdev, struct io_buffer *iobuf );
@@ -733,24 +735,4 @@ netdev_link_up ( struct net_device *netdev ) {
netdev_link_err ( netdev, 0 );
}
-/**
- * Freeze network device receive queue processing
- *
- * @v netdev Network device
- */
-static inline __attribute__ (( always_inline )) void
-netdev_rx_freeze ( struct net_device *netdev ) {
- netdev->state |= NETDEV_RX_FROZEN;
-}
-
-/**
- * Unfreeze network device receive queue processing
- *
- * @v netdev Network device
- */
-static inline __attribute__ (( always_inline )) void
-netdev_rx_unfreeze ( struct net_device *netdev ) {
- netdev->state &= ~NETDEV_RX_FROZEN;
-}
-
#endif /* _IPXE_NETDEVICE_H */