Commit 1c380f03 authored by Vikram Narayanan's avatar Vikram Narayanan

Merge branch 'dev_netdummy' into dev_ixgbe

parents 47bd898b 0ffa0e7a
......@@ -106,10 +106,9 @@ netdev_tx_t dummy_xmit(struct sk_buff *skb, struct net_device *dev)
g_dstats.tx_bytes += skb->len;
#endif
#ifndef NO_HASHING
#ifdef SENDER_DISPATCH_LOOP
dev_kfree_skb(skb);
#endif
//printk("%s, got packet\n", __func__);
return NETDEV_TX_OK;
}
......
......@@ -80,7 +80,7 @@ struct skbuff_members {
#define CONSUME_SKB_SEND_ONLY
#define CONSUME_SKB_NO_HASHING
#define SENDER_DISPATCH_LOOP
//#define SENDER_DISPATCH_LOOP
//#define NO_AWE
//#define NO_HASHING
......@@ -91,6 +91,8 @@ struct skbuff_members {
//#define CACHE_ALIGNED __attribute__((aligned(64)))
#define fipc_test_pause() asm volatile ( "pause\n": : :"memory" );
#define PMFS_ASYNC_RPC_BUFFER_ORDER 12
// LCD_DEBUG
/* CONTAINERS ---------- */
......@@ -351,4 +353,54 @@ retry:
}
#endif /* #if 0 */
static inline
int fipc_test_blocking_recv_start ( struct thc_channel *chnl, struct fipc_message** out)
{
int ret;
while ( 1 )
{
#ifdef ONE_SLOT
// Poll until we get a message or error
ret = fipc_recv_msg_start_0( thc_channel_to_fipc(chnl),
out );
#else
// Poll until we get a message or error
ret = fipc_recv_msg_start( thc_channel_to_fipc(chnl),
out );
#endif
if ( !ret || ret != -EWOULDBLOCK )
{
return ret;
}
fipc_test_pause();
}
return 0;
}
/**
* This function will block until a message slot is available and stored in out.
*/
static inline
int fipc_test_blocking_send_start ( struct thc_channel * chnl, struct fipc_message** out )
{
int ret;
while ( 1 )
{
// Poll until we get a free slot or error
ret = fipc_send_msg_start( thc_channel_to_fipc(chnl), out );
if ( !ret || ret != -EWOULDBLOCK )
{
return ret;
}
fipc_test_pause();
}
return 0;
}
#endif /* _GLUE_HELPER_H_ */
......@@ -3,7 +3,7 @@ obj-m += lcd_test_mod_nullnet_net_klcd.o
lcd_test_mod_nullnet_net_klcd-y += main.o
# glue code
lcd_test_mod_nullnet_net_klcd-y += $(addprefix glue/, nullnet_callee.o \
lcd_test_mod_nullnet_net_klcd-y += $(addprefix glue/, nullnet_callee.o nullnet_xmit.o \
dispatch.o )
lcd_test_mod_nullnet_net_klcd-y += $(addprefix ../, cap.o)
......
This diff is collapsed.
......@@ -17,6 +17,15 @@ struct net_info *
add_net(struct thc_channel *chnl, struct glue_cspace *cspace,
cptr_t sync_endpoint);
struct trampoline_hidden_args {
void *struct_container;
struct glue_cspace *cspace;
struct lcd_trampoline_handle *t_handle;
struct thc_channel *async_chnl;
struct cptr sync_ep;
};
int dispatch_async_loop(struct thc_channel *chnl,
struct fipc_message *msg,
struct glue_cspace *cspace,
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment