Re: [Bonding-devel] Re: [PATCH] fix ifenslave to not fail on lack of IP information

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Fri, Nov 11, 2005 at 10:35:01AM -0800, Jay Vosburgh wrote:
> 
> 	You never did say which version of bonding you're using (or I
> just cleverly missed it) , but I assume it's an old one, 2.5.something
> I'd guess, with the old abi.  For that case, yes, your patch makes
> sense.
> 
The RHEL kernel series use a variety of different versions of the bonding
driver, and yes, some of the prievious update releases use a older version of
the bonding abi.

> 	Can you rework your patch to also remove the fprintf and post
> that to the usual lists?  If it's not an error to fail to set the
> address, there's no reason to complain about it.  In truth, the
> set_if_addr() is all cosmetic; the kernel doesn't actually use that
> information for the slaves, so we could arguably remove it totally, but
> that might confuse end users.  Plus, ifenslave is on its way out, so I'd
> just as soon not change it more than necessary.
> 
> 	-J
> 
As requested, here is a rework of my previous patch, removing the unneeded
fprintf bits.  Tested successfully by me, and several of the origional reporters.

Regards
Neil

Signed-off-by: Neil Horman <[email protected]>


 ifenslave.c |    9 +--------
 1 files changed, 1 insertion(+), 8 deletions(-)



diff --git a/Documentation/networking/ifenslave.c b/Documentation/networking/ifenslave.c
--- a/Documentation/networking/ifenslave.c
+++ b/Documentation/networking/ifenslave.c
@@ -693,13 +693,7 @@ static int enslave(char *master_ifname, 
 		/* Older bonding versions would panic if the slave has no IP
 		 * address, so get the IP setting from the master.
 		 */
-		res = set_if_addr(master_ifname, slave_ifname);
-		if (res) {
-			fprintf(stderr,
-				"Slave '%s': Error: set address failed\n",
-				slave_ifname);
-			return res;
-		}
+		set_if_addr(master_ifname, slave_ifname);
 	} else {
 		res = clear_if_addr(slave_ifname);
 		if (res) {
@@ -1085,7 +1079,6 @@ static int set_if_addr(char *master_ifna
 				slave_ifname, ifra[i].req_name,
 				strerror(saved_errno));
 
-			return res;
 		}
 
 		ipaddr = ifr.ifr_addr.sa_data;
-- 
/***************************************************
 *Neil Horman
 *Software Engineer
 *gpg keyid: 1024D / 0x92A74FA1 - http://pgp.mit.edu
 ***************************************************/

Attachment: pgp113SZyc5Vn.pgp
Description: PGP signature


[Index of Archives]     [Kernel Newbies]     [Netfilter]     [Bugtraq]     [Photo]     [Stuff]     [Gimp]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Video 4 Linux]     [Linux for the blind]     [Linux Resources]
  Powered by Linux