Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 17 Jan 2011 11:52:26 +0100
From:      =?ISO-8859-1?Q?G=F3t_Andr=E1s?= <got.andras@deployis.eu>
To:        Janne Snabb <snabb@epipe.com>
Cc:        freebsd-xen@freebsd.org
Subject:   Re: xn0: Error 2 parsing device/vif/0/mac [PATCH]
Message-ID:  <4D341F6A.2010804@deployis.eu>
In-Reply-To: <alpine.BSF.2.00.1101171026200.20212@tiktik.epipe.com>
References:  <alpine.BSF.2.00.1101150731240.20212@tiktik.epipe.com>	<alpine.BSF.2.00.1101151002450.20212@tiktik.epipe.com>	<alpine.BSF.2.00.1101171018400.20212@tiktik.epipe.com> <alpine.BSF.2.00.1101171026200.20212@tiktik.epipe.com>

next in thread | previous in thread | raw e-mail | index | archive | help
I'll give it a try today or later tomorrow with AMD and Xeon machines 
with Xen 3.4.3. I hope Colin can also make this for 8.2 release, if 
these are fine.



Janne Snabb wrote:
> On Mon, 17 Jan 2011, Janne Snabb wrote:
> 
>> This patch might be a bit neater.
> 
> Oops, bug. A bracket at the wrong place. This one should be better.
> 
> Sorry about the noise,
> --
> Janne Snabb / EPIPE Communications
> snabb@epipe.com - http://epipe.com/
> 
> 
> --- sys/dev/xen/netfront/netfront.c.orig	2010-12-21 17:09:25.000000000 +0000
> +++ sys/dev/xen/netfront/netfront.c	2011-01-17 10:11:06.000000000 +0000
> @@ -401,13 +401,14 @@
>  xen_net_read_mac(device_t dev, uint8_t mac[])
>  {
>  	int error, i;
>  	char *s, *e, *macstr;
>  
> -	error = xs_read(XST_NIL, xenbus_get_node(dev), "mac", NULL,
> -	    (void **) &macstr);
> -	if (error)
> +	if ((error = xs_read(XST_NIL, xenbus_get_node(dev), "mac", NULL,
> +	    (void **) &macstr)) != 0 &&
> +	    (error = xs_read(XST_NIL, xenbus_get_otherend_path(dev), 
> +	    "mac", NULL, (void **) &macstr)) != 0)
>  		return (error);
>  
>  	s = macstr;
>  	for (i = 0; i < ETHER_ADDR_LEN; i++) {
>  		mac[i] = strtoul(s, &e, 16);
> _______________________________________________
> freebsd-xen@freebsd.org mailing list
> http://lists.freebsd.org/mailman/listinfo/freebsd-xen
> To unsubscribe, send any mail to "freebsd-xen-unsubscribe@freebsd.org"



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?4D341F6A.2010804>