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/mpc.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/mpc.c')
-rw-r--r-- | net/atm/mpc.c | 13 |
1 files changed, 3 insertions, 10 deletions
diff --git a/net/atm/mpc.c b/net/atm/mpc.c index c304ef1513b9..a48a5d580408 100644 --- a/net/atm/mpc.c +++ b/net/atm/mpc.c | |||
@@ -229,20 +229,15 @@ int atm_mpoa_delete_qos(struct atm_mpoa_qos *entry) | |||
229 | /* this is buggered - we need locking for qos_head */ | 229 | /* this is buggered - we need locking for qos_head */ |
230 | void atm_mpoa_disp_qos(struct seq_file *m) | 230 | void atm_mpoa_disp_qos(struct seq_file *m) |
231 | { | 231 | { |
232 | unsigned char *ip; | ||
233 | char ipaddr[16]; | ||
234 | struct atm_mpoa_qos *qos; | 232 | struct atm_mpoa_qos *qos; |
235 | 233 | ||
236 | qos = qos_head; | 234 | qos = qos_head; |
237 | seq_printf(m, "QoS entries for shortcuts:\n"); | 235 | seq_printf(m, "QoS entries for shortcuts:\n"); |
238 | seq_printf(m, "IP address\n TX:max_pcr pcr min_pcr max_cdv max_sdu\n RX:max_pcr pcr min_pcr max_cdv max_sdu\n"); | 236 | seq_printf(m, "IP address\n TX:max_pcr pcr min_pcr max_cdv max_sdu\n RX:max_pcr pcr min_pcr max_cdv max_sdu\n"); |
239 | 237 | ||
240 | ipaddr[sizeof(ipaddr)-1] = '\0'; | ||
241 | while (qos != NULL) { | 238 | while (qos != NULL) { |
242 | ip = (unsigned char *)&qos->ipaddr; | ||
243 | sprintf(ipaddr, "%u.%u.%u.%u", NIPQUAD(ip)); | ||
244 | seq_printf(m, "%u.%u.%u.%u\n %-7d %-7d %-7d %-7d %-7d\n %-7d %-7d %-7d %-7d %-7d\n", | 239 | seq_printf(m, "%u.%u.%u.%u\n %-7d %-7d %-7d %-7d %-7d\n %-7d %-7d %-7d %-7d %-7d\n", |
245 | NIPQUAD(ipaddr), | 240 | NIPQUAD(qos->ipaddr), |
246 | qos->qos.txtp.max_pcr, qos->qos.txtp.pcr, qos->qos.txtp.min_pcr, qos->qos.txtp.max_cdv, qos->qos.txtp.max_sdu, | 241 | qos->qos.txtp.max_pcr, qos->qos.txtp.pcr, qos->qos.txtp.min_pcr, qos->qos.txtp.max_cdv, qos->qos.txtp.max_sdu, |
247 | qos->qos.rxtp.max_pcr, qos->qos.rxtp.pcr, qos->qos.rxtp.min_pcr, qos->qos.rxtp.max_cdv, qos->qos.rxtp.max_sdu); | 242 | qos->qos.rxtp.max_pcr, qos->qos.rxtp.pcr, qos->qos.rxtp.min_pcr, qos->qos.rxtp.max_cdv, qos->qos.rxtp.max_sdu); |
248 | qos = qos->next; | 243 | qos = qos->next; |
@@ -1083,7 +1078,6 @@ static void MPOA_trigger_rcvd(struct k_message *msg, struct mpoa_client *mpc) | |||
1083 | static void check_qos_and_open_shortcut(struct k_message *msg, struct mpoa_client *client, in_cache_entry *entry) | 1078 | static void check_qos_and_open_shortcut(struct k_message *msg, struct mpoa_client *client, in_cache_entry *entry) |
1084 | { | 1079 | { |
1085 | uint32_t dst_ip = msg->content.in_info.in_dst_ip; | 1080 | uint32_t dst_ip = msg->content.in_info.in_dst_ip; |
1086 | unsigned char *ip __attribute__ ((unused)) = (unsigned char *)&dst_ip; | ||
1087 | struct atm_mpoa_qos *qos = atm_mpoa_search_qos(dst_ip); | 1081 | struct atm_mpoa_qos *qos = atm_mpoa_search_qos(dst_ip); |
1088 | eg_cache_entry *eg_entry = client->eg_ops->get_by_src_ip(dst_ip, client); | 1082 | eg_cache_entry *eg_entry = client->eg_ops->get_by_src_ip(dst_ip, client); |
1089 | 1083 | ||
@@ -1097,7 +1091,7 @@ static void check_qos_and_open_shortcut(struct k_message *msg, struct mpoa_clien | |||
1097 | entry->shortcut = eg_entry->shortcut; | 1091 | entry->shortcut = eg_entry->shortcut; |
1098 | } | 1092 | } |
1099 | if(entry->shortcut){ | 1093 | if(entry->shortcut){ |
1100 | dprintk("mpoa: (%s) using egress SVC to reach %u.%u.%u.%u\n",client->dev->name, NIPQUAD(ip)); | 1094 | dprintk("mpoa: (%s) using egress SVC to reach %u.%u.%u.%u\n",client->dev->name, NIPQUAD(dst_ip)); |
1101 | client->eg_ops->put(eg_entry); | 1095 | client->eg_ops->put(eg_entry); |
1102 | return; | 1096 | return; |
1103 | } | 1097 | } |
@@ -1123,8 +1117,7 @@ static void MPOA_res_reply_rcvd(struct k_message *msg, struct mpoa_client *mpc) | |||
1123 | 1117 | ||
1124 | uint32_t dst_ip = msg->content.in_info.in_dst_ip; | 1118 | uint32_t dst_ip = msg->content.in_info.in_dst_ip; |
1125 | in_cache_entry *entry = mpc->in_ops->get(dst_ip, mpc); | 1119 | in_cache_entry *entry = mpc->in_ops->get(dst_ip, mpc); |
1126 | ip = (unsigned char *)&dst_ip; | 1120 | dprintk("mpoa: (%s) MPOA_res_reply_rcvd: ip %u.%u.%u.%u\n", mpc->dev->name, NIPQUAD(dst_ip)); |
1127 | dprintk("mpoa: (%s) MPOA_res_reply_rcvd: ip %u.%u.%u.%u\n", mpc->dev->name, NIPQUAD(ip)); | ||
1128 | ddprintk("mpoa: (%s) MPOA_res_reply_rcvd() entry = %p", mpc->dev->name, entry); | 1121 | ddprintk("mpoa: (%s) MPOA_res_reply_rcvd() entry = %p", mpc->dev->name, entry); |
1129 | if(entry == NULL){ | 1122 | if(entry == NULL){ |
1130 | printk("\nmpoa: (%s) ARGH, received res. reply for an entry that doesn't exist.\n", mpc->dev->name); | 1123 | printk("\nmpoa: (%s) ARGH, received res. reply for an entry that doesn't exist.\n", mpc->dev->name); |