diff options
| author | Samuel Thibault <samuel.thibault@ens-lyon.org> | 2011-05-08 22:45:06 +0200 |
|---|---|---|
| committer | Samuel Thibault <samuel.thibault@ens-lyon.org> | 2011-05-08 22:45:06 +0200 |
| commit | 878c5456c5a2f9bff741a7b7bcdccd5c1694db22 (patch) | |
| tree | bcf3d101215fa70b953aa7e9d0de805c5f8865b4 /libdde_linux26/lib/src/arch/l4/net.c | |
| parent | 9062642230b7bfb48e7b30f98cba8528172b2d36 (diff) | |
| parent | c8f311a7a32d4b0cb0c21672f63bca8efdf5d83a (diff) | |
Merge branch 'dde' into HEAD
Diffstat (limited to 'libdde_linux26/lib/src/arch/l4/net.c')
| -rw-r--r-- | libdde_linux26/lib/src/arch/l4/net.c | 36 |
1 files changed, 36 insertions, 0 deletions
diff --git a/libdde_linux26/lib/src/arch/l4/net.c b/libdde_linux26/lib/src/arch/l4/net.c new file mode 100644 index 00000000..6e799119 --- /dev/null +++ b/libdde_linux26/lib/src/arch/l4/net.c @@ -0,0 +1,36 @@ +/****************************************************************************** + * DDELinux networking utilities. * + * * + * Bjoern Doebel <doebel@tudos.org> * + * * + * (c) 2005 - 2007 Technische Universitaet Dresden * + * This file is part of DROPS, which is distributed under the terms of the * + * GNU General Public License 2. Please see the COPYING file for details. * + ******************************************************************************/ + +#include <dde26_net.h> + +#include <linux/kernel.h> +#include <linux/skbuff.h> + +#include "local.h" + + +/* Callback function to be called if a network packet arrives and needs to + * be handled by netif_rx() or netif_receive_skb() + */ +linux_rx_callback l4dde26_rx_callback = NULL; + + +/* Register a netif_rx callback function. + * + * \return pointer to old callback function + */ +linux_rx_callback l4dde26_register_rx_callback(linux_rx_callback cb) +{ + linux_rx_callback old = l4dde26_rx_callback; + l4dde26_rx_callback = cb; + DEBUG_MSG("New rx callback @ %p.", cb); + + return old; +} |
