diff options
author | Al Viro <viro@zeniv.linux.org.uk> | 2006-06-20 06:27:27 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2006-06-20 06:27:27 -0400 |
commit | ff7512e1a2a3504649d3716a757f43807b6d26ef (patch) | |
tree | bda8de186c3990142701d9b97cf2f7d18f01b2a1 /net/atm/mpoa_caches.c | |
parent | 8ca84481b69513f7bf341c7dd9897023a04d7d1d (diff) |
[ATM]: fix broken uses of NIPQUAD in net/atm
NIPQUAD expects an l-value of type __be32, _NOT_ a pointer to __be32.
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/atm/mpoa_caches.c')
-rw-r--r-- | net/atm/mpoa_caches.c | 12 |
1 files changed, 4 insertions, 8 deletions
diff --git a/net/atm/mpoa_caches.c b/net/atm/mpoa_caches.c index 64ddebb64060..781ed1b9329d 100644 --- a/net/atm/mpoa_caches.c +++ b/net/atm/mpoa_caches.c | |||
@@ -223,7 +223,6 @@ static void in_cache_remove_entry(in_cache_entry *entry, | |||
223 | but an easy one... */ | 223 | but an easy one... */ |
224 | static void clear_count_and_expired(struct mpoa_client *client) | 224 | static void clear_count_and_expired(struct mpoa_client *client) |
225 | { | 225 | { |
226 | unsigned char *ip; | ||
227 | in_cache_entry *entry, *next_entry; | 226 | in_cache_entry *entry, *next_entry; |
228 | struct timeval now; | 227 | struct timeval now; |
229 | 228 | ||
@@ -236,8 +235,7 @@ static void clear_count_and_expired(struct mpoa_client *client) | |||
236 | next_entry = entry->next; | 235 | next_entry = entry->next; |
237 | if((now.tv_sec - entry->tv.tv_sec) | 236 | if((now.tv_sec - entry->tv.tv_sec) |
238 | > entry->ctrl_info.holding_time){ | 237 | > entry->ctrl_info.holding_time){ |
239 | ip = (unsigned char*)&entry->ctrl_info.in_dst_ip; | 238 | dprintk("mpoa: mpoa_caches.c: holding time expired, ip = %u.%u.%u.%u\n", NIPQUAD(entry->ctrl_info.in_dst_ip)); |
240 | dprintk("mpoa: mpoa_caches.c: holding time expired, ip = %u.%u.%u.%u\n", NIPQUAD(ip)); | ||
241 | client->in_ops->remove_entry(entry, client); | 239 | client->in_ops->remove_entry(entry, client); |
242 | } | 240 | } |
243 | entry = next_entry; | 241 | entry = next_entry; |
@@ -455,7 +453,6 @@ static void eg_cache_remove_entry(eg_cache_entry *entry, | |||
455 | 453 | ||
456 | static eg_cache_entry *eg_cache_add_entry(struct k_message *msg, struct mpoa_client *client) | 454 | static eg_cache_entry *eg_cache_add_entry(struct k_message *msg, struct mpoa_client *client) |
457 | { | 455 | { |
458 | unsigned char *ip; | ||
459 | eg_cache_entry *entry = kmalloc(sizeof(eg_cache_entry), GFP_KERNEL); | 456 | eg_cache_entry *entry = kmalloc(sizeof(eg_cache_entry), GFP_KERNEL); |
460 | 457 | ||
461 | if (entry == NULL) { | 458 | if (entry == NULL) { |
@@ -463,8 +460,7 @@ static eg_cache_entry *eg_cache_add_entry(struct k_message *msg, struct mpoa_cli | |||
463 | return NULL; | 460 | return NULL; |
464 | } | 461 | } |
465 | 462 | ||
466 | ip = (unsigned char *)&msg->content.eg_info.eg_dst_ip; | 463 | dprintk("mpoa: mpoa_caches.c: adding an egress entry, ip = %u.%u.%u.%u, this should be our IP\n", NIPQUAD(msg->content.eg_info.eg_dst_ip)); |
467 | dprintk("mpoa: mpoa_caches.c: adding an egress entry, ip = %u.%u.%u.%u, this should be our IP\n", NIPQUAD(ip)); | ||
468 | memset(entry, 0, sizeof(eg_cache_entry)); | 464 | memset(entry, 0, sizeof(eg_cache_entry)); |
469 | 465 | ||
470 | atomic_set(&entry->use, 1); | 466 | atomic_set(&entry->use, 1); |
@@ -481,8 +477,8 @@ static eg_cache_entry *eg_cache_add_entry(struct k_message *msg, struct mpoa_cli | |||
481 | do_gettimeofday(&(entry->tv)); | 477 | do_gettimeofday(&(entry->tv)); |
482 | entry->entry_state = EGRESS_RESOLVED; | 478 | entry->entry_state = EGRESS_RESOLVED; |
483 | dprintk("mpoa: mpoa_caches.c: new_eg_cache_entry cache_id %lu\n", ntohl(entry->ctrl_info.cache_id)); | 479 | dprintk("mpoa: mpoa_caches.c: new_eg_cache_entry cache_id %lu\n", ntohl(entry->ctrl_info.cache_id)); |
484 | ip = (unsigned char *)&entry->ctrl_info.mps_ip; | 480 | dprintk("mpoa: mpoa_caches.c: mps_ip = %u.%u.%u.%u\n", |
485 | dprintk("mpoa: mpoa_caches.c: mps_ip = %u.%u.%u.%u\n", NIPQUAD(ip)); | 481 | NIPQUAD(entry->ctrl_info.mps_ip)); |
486 | atomic_inc(&entry->use); | 482 | atomic_inc(&entry->use); |
487 | 483 | ||
488 | write_unlock_irq(&client->egress_lock); | 484 | write_unlock_irq(&client->egress_lock); |