diff options
author | David S. Miller <davem@sunset.davemloft.net> | 2006-01-12 21:22:32 (GMT) |
---|---|---|
committer | David S. Miller <davem@sunset.davemloft.net> | 2006-01-12 22:06:41 (GMT) |
commit | 880b005f294454d989783d0984dc554dfe3c8214 (patch) | |
tree | d1cffd5367f0bc939ef6952f6dacd78fb8592f39 /net/tipc | |
parent | e86eaa3abc285a988524d95e867285aad5d026a7 (diff) | |
download | linux-880b005f294454d989783d0984dc554dfe3c8214.tar.xz |
[TIPC]: Fix 64-bit build warnings.
When storing u32 values in a pointer, need to do
some long casts to keep GCC happy.
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/tipc')
-rw-r--r-- | net/tipc/bcast.c | 4 | ||||
-rw-r--r-- | net/tipc/port.c | 3 | ||||
-rw-r--r-- | net/tipc/subscr.c | 8 |
3 files changed, 9 insertions, 6 deletions
diff --git a/net/tipc/bcast.c b/net/tipc/bcast.c index 24d949c..9713d62 100644 --- a/net/tipc/bcast.c +++ b/net/tipc/bcast.c @@ -114,12 +114,12 @@ static inline u32 buf_seqno(struct sk_buff *buf) static inline u32 bcbuf_acks(struct sk_buff *buf) { - return (u32)TIPC_SKB_CB(buf)->handle; + return (u32)(unsigned long)TIPC_SKB_CB(buf)->handle; } static inline void bcbuf_set_acks(struct sk_buff *buf, u32 acks) { - TIPC_SKB_CB(buf)->handle = (void *)acks; + TIPC_SKB_CB(buf)->handle = (void *)(unsigned long)acks; } static inline void bcbuf_decr_acks(struct sk_buff *buf) diff --git a/net/tipc/port.c b/net/tipc/port.c index bb94046..66caca7 100644 --- a/net/tipc/port.c +++ b/net/tipc/port.c @@ -1234,7 +1234,8 @@ int tipc_connect2port(u32 ref, struct tipc_portid const *peer) p_ptr->publ.connected = 1; k_start_timer(&p_ptr->timer, p_ptr->probing_interval); - nodesub_subscribe(&p_ptr->subscription,peer->node, (void *)ref, + nodesub_subscribe(&p_ptr->subscription,peer->node, + (void *)(unsigned long)ref, (net_ev_handler)port_handle_node_down); res = TIPC_OK; exit: diff --git a/net/tipc/subscr.c b/net/tipc/subscr.c index 451d875..80e219b 100644 --- a/net/tipc/subscr.c +++ b/net/tipc/subscr.c @@ -329,9 +329,10 @@ static void subscr_conn_shutdown_event(void *usr_handle, unsigned int size, int reason) { - struct subscriber *subscriber = ref_lock((u32)usr_handle); + struct subscriber *subscriber; spinlock_t *subscriber_lock; + subscriber = ref_lock((u32)(unsigned long)usr_handle); if (subscriber == NULL) return; @@ -350,9 +351,10 @@ static void subscr_conn_msg_event(void *usr_handle, const unchar *data, u32 size) { - struct subscriber *subscriber = ref_lock((u32)usr_handle); + struct subscriber *subscriber; spinlock_t *subscriber_lock; + subscriber = ref_lock((u32)(unsigned long)usr_handle); if (subscriber == NULL) return; @@ -409,7 +411,7 @@ static void subscr_named_msg_event(void *usr_handle, /* Establish a connection to subscriber */ tipc_createport(topsrv.user_ref, - (void *)subscriber->ref, + (void *)(unsigned long)subscriber->ref, importance, 0, 0, |