diff options
author | Jiri Pirko <jpirko@redhat.com> | 2009-08-13 00:11:52 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2009-08-13 19:43:32 -0400 |
commit | e5e2a8fd8358d1b3a2c51c3248edee72e4194703 (patch) | |
tree | 5fcbbd0d82b370446dd2745296caa37b374ecf03 /drivers/net/bonding | |
parent | 26ced1e4aa181c01379b0b7ef156a29c000d1f8c (diff) |
bonding: wipe out printk's
I did not introduce new lines over 80 chars. I even eliminated some of
them.
Signed-off-by: Jiri Pirko <jpirko@redhat.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/bonding')
-rw-r--r-- | drivers/net/bonding/bond_3ad.c | 96 | ||||
-rw-r--r-- | drivers/net/bonding/bond_alb.c | 26 | ||||
-rw-r--r-- | drivers/net/bonding/bond_ipv6.c | 4 | ||||
-rw-r--r-- | drivers/net/bonding/bond_main.c | 6 | ||||
-rw-r--r-- | drivers/net/bonding/bond_sysfs.c | 63 |
5 files changed, 102 insertions, 93 deletions
diff --git a/drivers/net/bonding/bond_3ad.c b/drivers/net/bonding/bond_3ad.c index be799d2a8a8d..cea5cfe23b71 100644 --- a/drivers/net/bonding/bond_3ad.c +++ b/drivers/net/bonding/bond_3ad.c | |||
@@ -1124,7 +1124,7 @@ static void ad_rx_machine(struct lacpdu *lacpdu, struct port *port) | |||
1124 | // detect loopback situation | 1124 | // detect loopback situation |
1125 | if (!MAC_ADDRESS_COMPARE(&(lacpdu->actor_system), &(port->actor_system))) { | 1125 | if (!MAC_ADDRESS_COMPARE(&(lacpdu->actor_system), &(port->actor_system))) { |
1126 | // INFO_RECEIVED_LOOPBACK_FRAMES | 1126 | // INFO_RECEIVED_LOOPBACK_FRAMES |
1127 | printk(KERN_ERR DRV_NAME ": %s: An illegal loopback occurred on " | 1127 | pr_err(DRV_NAME ": %s: An illegal loopback occurred on " |
1128 | "adapter (%s). Check the configuration to verify that all " | 1128 | "adapter (%s). Check the configuration to verify that all " |
1129 | "Adapters are connected to 802.3ad compliant switch ports\n", | 1129 | "Adapters are connected to 802.3ad compliant switch ports\n", |
1130 | port->slave->dev->master->name, port->slave->dev->name); | 1130 | port->slave->dev->master->name, port->slave->dev->name); |
@@ -1306,11 +1306,13 @@ static void ad_port_selection_logic(struct port *port) | |||
1306 | } | 1306 | } |
1307 | } | 1307 | } |
1308 | if (!curr_port) { // meaning: the port was related to an aggregator but was not on the aggregator port list | 1308 | if (!curr_port) { // meaning: the port was related to an aggregator but was not on the aggregator port list |
1309 | printk(KERN_WARNING DRV_NAME ": %s: Warning: Port %d (on %s) was " | 1309 | pr_warning(DRV_NAME ": %s: Warning: Port %d (on %s) " |
1310 | "related to aggregator %d but was not on its port list\n", | 1310 | "was related to aggregator %d but was not " |
1311 | port->slave->dev->master->name, | 1311 | "on its port list\n", |
1312 | port->actor_port_number, port->slave->dev->name, | 1312 | port->slave->dev->master->name, |
1313 | port->aggregator->aggregator_identifier); | 1313 | port->actor_port_number, |
1314 | port->slave->dev->name, | ||
1315 | port->aggregator->aggregator_identifier); | ||
1314 | } | 1316 | } |
1315 | } | 1317 | } |
1316 | // search on all aggregators for a suitable aggregator for this port | 1318 | // search on all aggregators for a suitable aggregator for this port |
@@ -1379,7 +1381,8 @@ static void ad_port_selection_logic(struct port *port) | |||
1379 | 1381 | ||
1380 | pr_debug("Port %d joined LAG %d(new LAG)\n", port->actor_port_number, port->aggregator->aggregator_identifier); | 1382 | pr_debug("Port %d joined LAG %d(new LAG)\n", port->actor_port_number, port->aggregator->aggregator_identifier); |
1381 | } else { | 1383 | } else { |
1382 | printk(KERN_ERR DRV_NAME ": %s: Port %d (on %s) did not find a suitable aggregator\n", | 1384 | pr_err(DRV_NAME ": %s: Port %d (on %s) did not find " |
1385 | "a suitable aggregator\n", | ||
1383 | port->slave->dev->master->name, | 1386 | port->slave->dev->master->name, |
1384 | port->actor_port_number, port->slave->dev->name); | 1387 | port->actor_port_number, port->slave->dev->name); |
1385 | } | 1388 | } |
@@ -1456,10 +1459,10 @@ static struct aggregator *ad_agg_selection_test(struct aggregator *best, | |||
1456 | break; | 1459 | break; |
1457 | 1460 | ||
1458 | default: | 1461 | default: |
1459 | printk(KERN_WARNING DRV_NAME | 1462 | pr_warning(DRV_NAME |
1460 | ": %s: Impossible agg select mode %d\n", | 1463 | ": %s: Impossible agg select mode %d\n", |
1461 | curr->slave->dev->master->name, | 1464 | curr->slave->dev->master->name, |
1462 | __get_agg_selection_mode(curr->lag_ports)); | 1465 | __get_agg_selection_mode(curr->lag_ports)); |
1463 | break; | 1466 | break; |
1464 | } | 1467 | } |
1465 | 1468 | ||
@@ -1562,7 +1565,7 @@ static void ad_agg_selection_logic(struct aggregator *agg) | |||
1562 | 1565 | ||
1563 | // check if any partner replys | 1566 | // check if any partner replys |
1564 | if (best->is_individual) { | 1567 | if (best->is_individual) { |
1565 | printk(KERN_WARNING DRV_NAME ": %s: Warning: No 802.3ad" | 1568 | pr_warning(DRV_NAME ": %s: Warning: No 802.3ad" |
1566 | " response from the link partner for any" | 1569 | " response from the link partner for any" |
1567 | " adapters in the bond\n", | 1570 | " adapters in the bond\n", |
1568 | best->slave->dev->master->name); | 1571 | best->slave->dev->master->name); |
@@ -1885,7 +1888,8 @@ int bond_3ad_bind_slave(struct slave *slave) | |||
1885 | struct aggregator *aggregator; | 1888 | struct aggregator *aggregator; |
1886 | 1889 | ||
1887 | if (bond == NULL) { | 1890 | if (bond == NULL) { |
1888 | printk(KERN_ERR DRV_NAME ": %s: The slave %s is not attached to its bond\n", | 1891 | pr_err(DRV_NAME ": %s: The slave %s is not attached to " |
1892 | "its bond\n", | ||
1889 | slave->dev->master->name, slave->dev->name); | 1893 | slave->dev->master->name, slave->dev->name); |
1890 | return -1; | 1894 | return -1; |
1891 | } | 1895 | } |
@@ -1961,9 +1965,9 @@ void bond_3ad_unbind_slave(struct slave *slave) | |||
1961 | 1965 | ||
1962 | // if slave is null, the whole port is not initialized | 1966 | // if slave is null, the whole port is not initialized |
1963 | if (!port->slave) { | 1967 | if (!port->slave) { |
1964 | printk(KERN_WARNING DRV_NAME ": Warning: %s: Trying to " | 1968 | pr_warning(DRV_NAME ": Warning: %s: Trying to " |
1965 | "unbind an uninitialized port on %s\n", | 1969 | "unbind an uninitialized port on %s\n", |
1966 | slave->dev->master->name, slave->dev->name); | 1970 | slave->dev->master->name, slave->dev->name); |
1967 | return; | 1971 | return; |
1968 | } | 1972 | } |
1969 | 1973 | ||
@@ -1994,8 +1998,8 @@ void bond_3ad_unbind_slave(struct slave *slave) | |||
1994 | pr_debug("Some port(s) related to LAG %d - replaceing with LAG %d\n", aggregator->aggregator_identifier, new_aggregator->aggregator_identifier); | 1998 | pr_debug("Some port(s) related to LAG %d - replaceing with LAG %d\n", aggregator->aggregator_identifier, new_aggregator->aggregator_identifier); |
1995 | 1999 | ||
1996 | if ((new_aggregator->lag_ports == port) && new_aggregator->is_active) { | 2000 | if ((new_aggregator->lag_ports == port) && new_aggregator->is_active) { |
1997 | printk(KERN_INFO DRV_NAME ": %s: Removing an active aggregator\n", | 2001 | pr_info(DRV_NAME ": %s: Removing an active aggregator\n", |
1998 | aggregator->slave->dev->master->name); | 2002 | aggregator->slave->dev->master->name); |
1999 | // select new active aggregator | 2003 | // select new active aggregator |
2000 | select_new_active_agg = 1; | 2004 | select_new_active_agg = 1; |
2001 | } | 2005 | } |
@@ -2025,17 +2029,17 @@ void bond_3ad_unbind_slave(struct slave *slave) | |||
2025 | ad_agg_selection_logic(__get_first_agg(port)); | 2029 | ad_agg_selection_logic(__get_first_agg(port)); |
2026 | } | 2030 | } |
2027 | } else { | 2031 | } else { |
2028 | printk(KERN_WARNING DRV_NAME ": %s: Warning: unbinding aggregator, " | 2032 | pr_warning(DRV_NAME ": %s: Warning: unbinding aggregator, " |
2029 | "and could not find a new aggregator for its ports\n", | 2033 | "and could not find a new aggregator for its ports\n", |
2030 | slave->dev->master->name); | 2034 | slave->dev->master->name); |
2031 | } | 2035 | } |
2032 | } else { // in case that the only port related to this aggregator is the one we want to remove | 2036 | } else { // in case that the only port related to this aggregator is the one we want to remove |
2033 | select_new_active_agg = aggregator->is_active; | 2037 | select_new_active_agg = aggregator->is_active; |
2034 | // clear the aggregator | 2038 | // clear the aggregator |
2035 | ad_clear_agg(aggregator); | 2039 | ad_clear_agg(aggregator); |
2036 | if (select_new_active_agg) { | 2040 | if (select_new_active_agg) { |
2037 | printk(KERN_INFO DRV_NAME ": %s: Removing an active aggregator\n", | 2041 | pr_info(DRV_NAME ": %s: Removing an active aggregator\n", |
2038 | slave->dev->master->name); | 2042 | slave->dev->master->name); |
2039 | // select new active aggregator | 2043 | // select new active aggregator |
2040 | ad_agg_selection_logic(__get_first_agg(port)); | 2044 | ad_agg_selection_logic(__get_first_agg(port)); |
2041 | } | 2045 | } |
@@ -2061,8 +2065,8 @@ void bond_3ad_unbind_slave(struct slave *slave) | |||
2061 | // clear the aggregator | 2065 | // clear the aggregator |
2062 | ad_clear_agg(temp_aggregator); | 2066 | ad_clear_agg(temp_aggregator); |
2063 | if (select_new_active_agg) { | 2067 | if (select_new_active_agg) { |
2064 | printk(KERN_INFO DRV_NAME ": %s: Removing an active aggregator\n", | 2068 | pr_info(DRV_NAME ": %s: Removing an active aggregator\n", |
2065 | slave->dev->master->name); | 2069 | slave->dev->master->name); |
2066 | // select new active aggregator | 2070 | // select new active aggregator |
2067 | ad_agg_selection_logic(__get_first_agg(port)); | 2071 | ad_agg_selection_logic(__get_first_agg(port)); |
2068 | } | 2072 | } |
@@ -2110,8 +2114,8 @@ void bond_3ad_state_machine_handler(struct work_struct *work) | |||
2110 | // select the active aggregator for the bond | 2114 | // select the active aggregator for the bond |
2111 | if ((port = __get_first_port(bond))) { | 2115 | if ((port = __get_first_port(bond))) { |
2112 | if (!port->slave) { | 2116 | if (!port->slave) { |
2113 | printk(KERN_WARNING DRV_NAME ": %s: Warning: bond's first port is " | 2117 | pr_warning(DRV_NAME ": %s: Warning: bond's first port is " |
2114 | "uninitialized\n", bond->dev->name); | 2118 | "uninitialized\n", bond->dev->name); |
2115 | goto re_arm; | 2119 | goto re_arm; |
2116 | } | 2120 | } |
2117 | 2121 | ||
@@ -2124,8 +2128,8 @@ void bond_3ad_state_machine_handler(struct work_struct *work) | |||
2124 | // for each port run the state machines | 2128 | // for each port run the state machines |
2125 | for (port = __get_first_port(bond); port; port = __get_next_port(port)) { | 2129 | for (port = __get_first_port(bond); port; port = __get_next_port(port)) { |
2126 | if (!port->slave) { | 2130 | if (!port->slave) { |
2127 | printk(KERN_WARNING DRV_NAME ": %s: Warning: Found an uninitialized " | 2131 | pr_warning(DRV_NAME ": %s: Warning: Found an uninitialized " |
2128 | "port\n", bond->dev->name); | 2132 | "port\n", bond->dev->name); |
2129 | goto re_arm; | 2133 | goto re_arm; |
2130 | } | 2134 | } |
2131 | 2135 | ||
@@ -2166,8 +2170,9 @@ static void bond_3ad_rx_indication(struct lacpdu *lacpdu, struct slave *slave, u | |||
2166 | port = &(SLAVE_AD_INFO(slave).port); | 2170 | port = &(SLAVE_AD_INFO(slave).port); |
2167 | 2171 | ||
2168 | if (!port->slave) { | 2172 | if (!port->slave) { |
2169 | printk(KERN_WARNING DRV_NAME ": %s: Warning: port of slave %s is " | 2173 | pr_warning(DRV_NAME ": %s: Warning: port of slave %s " |
2170 | "uninitialized\n", slave->dev->name, slave->dev->master->name); | 2174 | "is uninitialized\n", |
2175 | slave->dev->name, slave->dev->master->name); | ||
2171 | return; | 2176 | return; |
2172 | } | 2177 | } |
2173 | 2178 | ||
@@ -2212,9 +2217,9 @@ void bond_3ad_adapter_speed_changed(struct slave *slave) | |||
2212 | 2217 | ||
2213 | // if slave is null, the whole port is not initialized | 2218 | // if slave is null, the whole port is not initialized |
2214 | if (!port->slave) { | 2219 | if (!port->slave) { |
2215 | printk(KERN_WARNING DRV_NAME ": Warning: %s: speed " | 2220 | pr_warning(DRV_NAME ": Warning: %s: speed " |
2216 | "changed for uninitialized port on %s\n", | 2221 | "changed for uninitialized port on %s\n", |
2217 | slave->dev->master->name, slave->dev->name); | 2222 | slave->dev->master->name, slave->dev->name); |
2218 | return; | 2223 | return; |
2219 | } | 2224 | } |
2220 | 2225 | ||
@@ -2240,9 +2245,9 @@ void bond_3ad_adapter_duplex_changed(struct slave *slave) | |||
2240 | 2245 | ||
2241 | // if slave is null, the whole port is not initialized | 2246 | // if slave is null, the whole port is not initialized |
2242 | if (!port->slave) { | 2247 | if (!port->slave) { |
2243 | printk(KERN_WARNING DRV_NAME ": %s: Warning: duplex changed " | 2248 | pr_warning(DRV_NAME ": %s: Warning: duplex changed " |
2244 | "for uninitialized port on %s\n", | 2249 | "for uninitialized port on %s\n", |
2245 | slave->dev->master->name, slave->dev->name); | 2250 | slave->dev->master->name, slave->dev->name); |
2246 | return; | 2251 | return; |
2247 | } | 2252 | } |
2248 | 2253 | ||
@@ -2269,9 +2274,9 @@ void bond_3ad_handle_link_change(struct slave *slave, char link) | |||
2269 | 2274 | ||
2270 | // if slave is null, the whole port is not initialized | 2275 | // if slave is null, the whole port is not initialized |
2271 | if (!port->slave) { | 2276 | if (!port->slave) { |
2272 | printk(KERN_WARNING DRV_NAME ": Warning: %s: link status changed for " | 2277 | pr_warning(DRV_NAME ": Warning: %s: link status changed for " |
2273 | "uninitialized port on %s\n", | 2278 | "uninitialized port on %s\n", |
2274 | slave->dev->master->name, slave->dev->name); | 2279 | slave->dev->master->name, slave->dev->name); |
2275 | return; | 2280 | return; |
2276 | } | 2281 | } |
2277 | 2282 | ||
@@ -2375,8 +2380,8 @@ int bond_3ad_xmit_xor(struct sk_buff *skb, struct net_device *dev) | |||
2375 | } | 2380 | } |
2376 | 2381 | ||
2377 | if (bond_3ad_get_active_agg_info(bond, &ad_info)) { | 2382 | if (bond_3ad_get_active_agg_info(bond, &ad_info)) { |
2378 | printk(KERN_DEBUG DRV_NAME ": %s: Error: " | 2383 | pr_debug(DRV_NAME ": %s: Error: " |
2379 | "bond_3ad_get_active_agg_info failed\n", dev->name); | 2384 | "bond_3ad_get_active_agg_info failed\n", dev->name); |
2380 | goto out; | 2385 | goto out; |
2381 | } | 2386 | } |
2382 | 2387 | ||
@@ -2385,9 +2390,8 @@ int bond_3ad_xmit_xor(struct sk_buff *skb, struct net_device *dev) | |||
2385 | 2390 | ||
2386 | if (slaves_in_agg == 0) { | 2391 | if (slaves_in_agg == 0) { |
2387 | /*the aggregator is empty*/ | 2392 | /*the aggregator is empty*/ |
2388 | printk(KERN_DEBUG DRV_NAME ": %s: Error: active " | 2393 | pr_debug(DRV_NAME ": %s: Error: active aggregator is empty\n", |
2389 | "aggregator is empty\n", | 2394 | dev->name); |
2390 | dev->name); | ||
2391 | goto out; | 2395 | goto out; |
2392 | } | 2396 | } |
2393 | 2397 | ||
@@ -2405,7 +2409,7 @@ int bond_3ad_xmit_xor(struct sk_buff *skb, struct net_device *dev) | |||
2405 | } | 2409 | } |
2406 | 2410 | ||
2407 | if (slave_agg_no >= 0) { | 2411 | if (slave_agg_no >= 0) { |
2408 | printk(KERN_ERR DRV_NAME ": %s: Error: Couldn't find a slave to tx on " | 2412 | pr_err(DRV_NAME ": %s: Error: Couldn't find a slave to tx on " |
2409 | "for aggregator ID %d\n", dev->name, agg_id); | 2413 | "for aggregator ID %d\n", dev->name, agg_id); |
2410 | goto out; | 2414 | goto out; |
2411 | } | 2415 | } |
diff --git a/drivers/net/bonding/bond_alb.c b/drivers/net/bonding/bond_alb.c index bf45d2002924..2108706d2f0c 100644 --- a/drivers/net/bonding/bond_alb.c +++ b/drivers/net/bonding/bond_alb.c | |||
@@ -194,7 +194,7 @@ static int tlb_initialize(struct bonding *bond) | |||
194 | 194 | ||
195 | new_hashtbl = kzalloc(size, GFP_KERNEL); | 195 | new_hashtbl = kzalloc(size, GFP_KERNEL); |
196 | if (!new_hashtbl) { | 196 | if (!new_hashtbl) { |
197 | printk(KERN_ERR DRV_NAME | 197 | pr_err(DRV_NAME |
198 | ": %s: Error: Failed to allocate TLB hash table\n", | 198 | ": %s: Error: Failed to allocate TLB hash table\n", |
199 | bond->dev->name); | 199 | bond->dev->name); |
200 | return -1; | 200 | return -1; |
@@ -510,7 +510,7 @@ static void rlb_update_client(struct rlb_client_info *client_info) | |||
510 | client_info->slave->dev->dev_addr, | 510 | client_info->slave->dev->dev_addr, |
511 | client_info->mac_dst); | 511 | client_info->mac_dst); |
512 | if (!skb) { | 512 | if (!skb) { |
513 | printk(KERN_ERR DRV_NAME | 513 | pr_err(DRV_NAME |
514 | ": %s: Error: failed to create an ARP packet\n", | 514 | ": %s: Error: failed to create an ARP packet\n", |
515 | client_info->slave->dev->master->name); | 515 | client_info->slave->dev->master->name); |
516 | continue; | 516 | continue; |
@@ -521,7 +521,7 @@ static void rlb_update_client(struct rlb_client_info *client_info) | |||
521 | if (client_info->tag) { | 521 | if (client_info->tag) { |
522 | skb = vlan_put_tag(skb, client_info->vlan_id); | 522 | skb = vlan_put_tag(skb, client_info->vlan_id); |
523 | if (!skb) { | 523 | if (!skb) { |
524 | printk(KERN_ERR DRV_NAME | 524 | pr_err(DRV_NAME |
525 | ": %s: Error: failed to insert VLAN tag\n", | 525 | ": %s: Error: failed to insert VLAN tag\n", |
526 | client_info->slave->dev->master->name); | 526 | client_info->slave->dev->master->name); |
527 | continue; | 527 | continue; |
@@ -605,7 +605,7 @@ static void rlb_req_update_subnet_clients(struct bonding *bond, __be32 src_ip) | |||
605 | client_info = &(bond_info->rx_hashtbl[hash_index]); | 605 | client_info = &(bond_info->rx_hashtbl[hash_index]); |
606 | 606 | ||
607 | if (!client_info->slave) { | 607 | if (!client_info->slave) { |
608 | printk(KERN_ERR DRV_NAME | 608 | pr_err(DRV_NAME |
609 | ": %s: Error: found a client with no channel in " | 609 | ": %s: Error: found a client with no channel in " |
610 | "the client's hash table\n", | 610 | "the client's hash table\n", |
611 | bond->dev->name); | 611 | bond->dev->name); |
@@ -802,7 +802,7 @@ static int rlb_initialize(struct bonding *bond) | |||
802 | 802 | ||
803 | new_hashtbl = kmalloc(size, GFP_KERNEL); | 803 | new_hashtbl = kmalloc(size, GFP_KERNEL); |
804 | if (!new_hashtbl) { | 804 | if (!new_hashtbl) { |
805 | printk(KERN_ERR DRV_NAME | 805 | pr_err(DRV_NAME |
806 | ": %s: Error: Failed to allocate RLB hash table\n", | 806 | ": %s: Error: Failed to allocate RLB hash table\n", |
807 | bond->dev->name); | 807 | bond->dev->name); |
808 | return -1; | 808 | return -1; |
@@ -924,7 +924,7 @@ static void alb_send_learning_packets(struct slave *slave, u8 mac_addr[]) | |||
924 | 924 | ||
925 | skb = vlan_put_tag(skb, vlan->vlan_id); | 925 | skb = vlan_put_tag(skb, vlan->vlan_id); |
926 | if (!skb) { | 926 | if (!skb) { |
927 | printk(KERN_ERR DRV_NAME | 927 | pr_err(DRV_NAME |
928 | ": %s: Error: failed to insert VLAN tag\n", | 928 | ": %s: Error: failed to insert VLAN tag\n", |
929 | bond->dev->name); | 929 | bond->dev->name); |
930 | continue; | 930 | continue; |
@@ -954,7 +954,7 @@ static int alb_set_slave_mac_addr(struct slave *slave, u8 addr[], int hw) | |||
954 | memcpy(s_addr.sa_data, addr, dev->addr_len); | 954 | memcpy(s_addr.sa_data, addr, dev->addr_len); |
955 | s_addr.sa_family = dev->type; | 955 | s_addr.sa_family = dev->type; |
956 | if (dev_set_mac_address(dev, &s_addr)) { | 956 | if (dev_set_mac_address(dev, &s_addr)) { |
957 | printk(KERN_ERR DRV_NAME | 957 | pr_err(DRV_NAME |
958 | ": %s: Error: dev_set_mac_address of dev %s failed! ALB " | 958 | ": %s: Error: dev_set_mac_address of dev %s failed! ALB " |
959 | "mode requires that the base driver support setting " | 959 | "mode requires that the base driver support setting " |
960 | "the hw address also when the network device's " | 960 | "the hw address also when the network device's " |
@@ -1170,13 +1170,15 @@ static int alb_handle_addr_collision_on_attach(struct bonding *bond, struct slav | |||
1170 | alb_set_slave_mac_addr(slave, free_mac_slave->perm_hwaddr, | 1170 | alb_set_slave_mac_addr(slave, free_mac_slave->perm_hwaddr, |
1171 | bond->alb_info.rlb_enabled); | 1171 | bond->alb_info.rlb_enabled); |
1172 | 1172 | ||
1173 | printk(KERN_WARNING DRV_NAME | 1173 | pr_warning(DRV_NAME |
1174 | ": %s: Warning: the hw address of slave %s is in use by " | 1174 | ": %s: Warning: the hw address of slave %s is " |
1175 | "the bond; giving it the hw address of %s\n", | 1175 | "in use by the bond; giving it the hw address " |
1176 | bond->dev->name, slave->dev->name, free_mac_slave->dev->name); | 1176 | "of %s\n", |
1177 | bond->dev->name, slave->dev->name, | ||
1178 | free_mac_slave->dev->name); | ||
1177 | 1179 | ||
1178 | } else if (has_bond_addr) { | 1180 | } else if (has_bond_addr) { |
1179 | printk(KERN_ERR DRV_NAME | 1181 | pr_err(DRV_NAME |
1180 | ": %s: Error: the hw address of slave %s is in use by the " | 1182 | ": %s: Error: the hw address of slave %s is in use by the " |
1181 | "bond; couldn't find a slave with a free hw address to " | 1183 | "bond; couldn't find a slave with a free hw address to " |
1182 | "give it (this should not have happened)\n", | 1184 | "give it (this should not have happened)\n", |
diff --git a/drivers/net/bonding/bond_ipv6.c b/drivers/net/bonding/bond_ipv6.c index 0d73bf5ac5a5..83921abae12d 100644 --- a/drivers/net/bonding/bond_ipv6.c +++ b/drivers/net/bonding/bond_ipv6.c | |||
@@ -79,14 +79,14 @@ static void bond_na_send(struct net_device *slave_dev, | |||
79 | ND_OPT_TARGET_LL_ADDR); | 79 | ND_OPT_TARGET_LL_ADDR); |
80 | 80 | ||
81 | if (!skb) { | 81 | if (!skb) { |
82 | printk(KERN_ERR DRV_NAME ": NA packet allocation failed\n"); | 82 | pr_err(DRV_NAME ": NA packet allocation failed\n"); |
83 | return; | 83 | return; |
84 | } | 84 | } |
85 | 85 | ||
86 | if (vlan_id) { | 86 | if (vlan_id) { |
87 | skb = vlan_put_tag(skb, vlan_id); | 87 | skb = vlan_put_tag(skb, vlan_id); |
88 | if (!skb) { | 88 | if (!skb) { |
89 | printk(KERN_ERR DRV_NAME ": failed to insert VLAN tag\n"); | 89 | pr_err(DRV_NAME ": failed to insert VLAN tag\n"); |
90 | return; | 90 | return; |
91 | } | 91 | } |
92 | } | 92 | } |
diff --git a/drivers/net/bonding/bond_main.c b/drivers/net/bonding/bond_main.c index 3bf0cc61e92c..4798d30c9545 100644 --- a/drivers/net/bonding/bond_main.c +++ b/drivers/net/bonding/bond_main.c | |||
@@ -4837,7 +4837,7 @@ static int bond_check_params(struct bond_params *params) | |||
4837 | } | 4837 | } |
4838 | 4838 | ||
4839 | if (bond_mode == BOND_MODE_ALB) { | 4839 | if (bond_mode == BOND_MODE_ALB) { |
4840 | printk(KERN_NOTICE DRV_NAME | 4840 | pr_notice(DRV_NAME |
4841 | ": In ALB mode you might experience client " | 4841 | ": In ALB mode you might experience client " |
4842 | "disconnections upon reconnection of a link if the " | 4842 | "disconnections upon reconnection of a link if the " |
4843 | "bonding module updelay parameter (%d msec) is " | 4843 | "bonding module updelay parameter (%d msec) is " |
@@ -4961,9 +4961,9 @@ static int bond_check_params(struct bond_params *params) | |||
4961 | arp_ip_count); | 4961 | arp_ip_count); |
4962 | 4962 | ||
4963 | for (i = 0; i < arp_ip_count; i++) | 4963 | for (i = 0; i < arp_ip_count; i++) |
4964 | printk(" %s", arp_ip_target[i]); | 4964 | pr_info(" %s", arp_ip_target[i]); |
4965 | 4965 | ||
4966 | printk("\n"); | 4966 | pr_info("\n"); |
4967 | 4967 | ||
4968 | } else if (max_bonds) { | 4968 | } else if (max_bonds) { |
4969 | /* miimon and arp_interval not set, we need one so things | 4969 | /* miimon and arp_interval not set, we need one so things |
diff --git a/drivers/net/bonding/bond_sysfs.c b/drivers/net/bonding/bond_sysfs.c index 55bf34f59bbf..6044e12ff9fc 100644 --- a/drivers/net/bonding/bond_sysfs.c +++ b/drivers/net/bonding/bond_sysfs.c | |||
@@ -218,9 +218,8 @@ static ssize_t bonding_store_slaves(struct device *d, | |||
218 | 218 | ||
219 | /* Quick sanity check -- is the bond interface up? */ | 219 | /* Quick sanity check -- is the bond interface up? */ |
220 | if (!(bond->dev->flags & IFF_UP)) { | 220 | if (!(bond->dev->flags & IFF_UP)) { |
221 | printk(KERN_WARNING DRV_NAME | 221 | pr_warning(DRV_NAME ": %s: doing slave updates when " |
222 | ": %s: doing slave updates when interface is down.\n", | 222 | "interface is down.\n", bond->dev->name); |
223 | bond->dev->name); | ||
224 | } | 223 | } |
225 | 224 | ||
226 | /* Note: We can't hold bond->lock here, as bond_create grabs it. */ | 225 | /* Note: We can't hold bond->lock here, as bond_create grabs it. */ |
@@ -778,12 +777,14 @@ static ssize_t bonding_store_downdelay(struct device *d, | |||
778 | goto out; | 777 | goto out; |
779 | } else { | 778 | } else { |
780 | if ((new_value % bond->params.miimon) != 0) { | 779 | if ((new_value % bond->params.miimon) != 0) { |
781 | printk(KERN_WARNING DRV_NAME | 780 | pr_warning(DRV_NAME |
782 | ": %s: Warning: down delay (%d) is not a multiple " | 781 | ": %s: Warning: down delay (%d) is not a " |
783 | "of miimon (%d), delay rounded to %d ms\n", | 782 | "multiple of miimon (%d), delay rounded " |
784 | bond->dev->name, new_value, bond->params.miimon, | 783 | "to %d ms\n", |
785 | (new_value / bond->params.miimon) * | 784 | bond->dev->name, new_value, |
786 | bond->params.miimon); | 785 | bond->params.miimon, |
786 | (new_value / bond->params.miimon) * | ||
787 | bond->params.miimon); | ||
787 | } | 788 | } |
788 | bond->params.downdelay = new_value / bond->params.miimon; | 789 | bond->params.downdelay = new_value / bond->params.miimon; |
789 | pr_info(DRV_NAME ": %s: Setting down delay to %d.\n", | 790 | pr_info(DRV_NAME ": %s: Setting down delay to %d.\n", |
@@ -838,12 +839,14 @@ static ssize_t bonding_store_updelay(struct device *d, | |||
838 | goto out; | 839 | goto out; |
839 | } else { | 840 | } else { |
840 | if ((new_value % bond->params.miimon) != 0) { | 841 | if ((new_value % bond->params.miimon) != 0) { |
841 | printk(KERN_WARNING DRV_NAME | 842 | pr_warning(DRV_NAME |
842 | ": %s: Warning: up delay (%d) is not a multiple " | 843 | ": %s: Warning: up delay (%d) is not a " |
843 | "of miimon (%d), updelay rounded to %d ms\n", | 844 | "multiple of miimon (%d), updelay rounded " |
844 | bond->dev->name, new_value, bond->params.miimon, | 845 | "to %d ms\n", |
845 | (new_value / bond->params.miimon) * | 846 | bond->dev->name, new_value, |
846 | bond->params.miimon); | 847 | bond->params.miimon, |
848 | (new_value / bond->params.miimon) * | ||
849 | bond->params.miimon); | ||
847 | } | 850 | } |
848 | bond->params.updelay = new_value / bond->params.miimon; | 851 | bond->params.updelay = new_value / bond->params.miimon; |
849 | pr_info(DRV_NAME ": %s: Setting up delay to %d.\n", | 852 | pr_info(DRV_NAME ": %s: Setting up delay to %d.\n", |
@@ -1299,9 +1302,9 @@ static ssize_t bonding_store_active_slave(struct device *d, | |||
1299 | new_active = slave; | 1302 | new_active = slave; |
1300 | if (new_active == old_active) { | 1303 | if (new_active == old_active) { |
1301 | /* do nothing */ | 1304 | /* do nothing */ |
1302 | printk(KERN_INFO DRV_NAME | 1305 | pr_info(DRV_NAME |
1303 | ": %s: %s is already the current active slave.\n", | 1306 | ": %s: %s is already the current active slave.\n", |
1304 | bond->dev->name, slave->dev->name); | 1307 | bond->dev->name, slave->dev->name); |
1305 | goto out; | 1308 | goto out; |
1306 | } | 1309 | } |
1307 | else { | 1310 | else { |
@@ -1309,17 +1312,17 @@ static ssize_t bonding_store_active_slave(struct device *d, | |||
1309 | (old_active) && | 1312 | (old_active) && |
1310 | (new_active->link == BOND_LINK_UP) && | 1313 | (new_active->link == BOND_LINK_UP) && |
1311 | IS_UP(new_active->dev)) { | 1314 | IS_UP(new_active->dev)) { |
1312 | printk(KERN_INFO DRV_NAME | 1315 | pr_info(DRV_NAME |
1313 | ": %s: Setting %s as active slave.\n", | 1316 | ": %s: Setting %s as active slave.\n", |
1314 | bond->dev->name, slave->dev->name); | 1317 | bond->dev->name, slave->dev->name); |
1315 | bond_change_active_slave(bond, new_active); | 1318 | bond_change_active_slave(bond, new_active); |
1316 | } | 1319 | } |
1317 | else { | 1320 | else { |
1318 | printk(KERN_INFO DRV_NAME | 1321 | pr_info(DRV_NAME |
1319 | ": %s: Could not set %s as active slave; " | 1322 | ": %s: Could not set %s as active slave; " |
1320 | "either %s is down or the link is down.\n", | 1323 | "either %s is down or the link is down.\n", |
1321 | bond->dev->name, slave->dev->name, | 1324 | bond->dev->name, slave->dev->name, |
1322 | slave->dev->name); | 1325 | slave->dev->name); |
1323 | } | 1326 | } |
1324 | goto out; | 1327 | goto out; |
1325 | } | 1328 | } |
@@ -1537,8 +1540,8 @@ int bond_create_sysfs(void) | |||
1537 | /* Is someone being kinky and naming a device bonding_master? */ | 1540 | /* Is someone being kinky and naming a device bonding_master? */ |
1538 | if (__dev_get_by_name(&init_net, | 1541 | if (__dev_get_by_name(&init_net, |
1539 | class_attr_bonding_masters.attr.name)) | 1542 | class_attr_bonding_masters.attr.name)) |
1540 | printk(KERN_ERR | 1543 | pr_err("network device named %s already " |
1541 | "network device named %s already exists in sysfs", | 1544 | "exists in sysfs", |
1542 | class_attr_bonding_masters.attr.name); | 1545 | class_attr_bonding_masters.attr.name); |
1543 | ret = 0; | 1546 | ret = 0; |
1544 | } | 1547 | } |
@@ -1566,7 +1569,7 @@ int bond_create_sysfs_entry(struct bonding *bond) | |||
1566 | 1569 | ||
1567 | err = sysfs_create_group(&(dev->dev.kobj), &bonding_group); | 1570 | err = sysfs_create_group(&(dev->dev.kobj), &bonding_group); |
1568 | if (err) | 1571 | if (err) |
1569 | printk(KERN_EMERG "eek! didn't create group!\n"); | 1572 | pr_emerg("eek! didn't create group!\n"); |
1570 | 1573 | ||
1571 | return err; | 1574 | return err; |
1572 | } | 1575 | } |