WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-devel

[Xen-devel] Re: [PATCH]mini-os: Fix to get netfront running on ia64

To: Dietmar Hahn <dietmar.hahn@xxxxxxxxxxxxxxxxxxx>
Subject: [Xen-devel] Re: [PATCH]mini-os: Fix to get netfront running on ia64
From: Grzegorz Milos <gm281@xxxxxxxxx>
Date: Tue, 06 Feb 2007 21:59:49 +0000
Cc: xen-devel@xxxxxxxxxxxxxxxxxxx
Delivery-date: Tue, 06 Feb 2007 13:59:40 -0800
Envelope-to: www-data@xxxxxxxxxxxxxxxxxx
In-reply-to: <200702060803.21254.dietmar.hahn@xxxxxxxxxxxxxxxxxxx>
List-help: <mailto:xen-devel-request@lists.xensource.com?subject=help>
List-id: Xen developer discussion <xen-devel.lists.xensource.com>
List-post: <mailto:xen-devel@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=unsubscribe>
References: <200702060803.21254.dietmar.hahn@xxxxxxxxxxxxxxxxxxx>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
User-agent: Thunderbird 1.5 (X11/20051025)
That looks good. Keir could you apply please (if you haven't done so already).

Thanks
Gregor

Hi,

to get the netfront stuff on ia64 architecture running I still need to include the attached patch.
Please have a look and send comments!
Thanks.

Dietmar.


------------------------------------------------------------------------

# HG changeset patch
# User dietmar.hahn@xxxxxxxxxxxxxxxxxxx
# Date 1170687542 -3600
# Node ID 80cd2c0ee40cddec1914542f221159b5911368b3
# Parent  01ec7dba9ff805a5c74a0318997b747d3e3e3327
2 Fixes for supporting netfront on ia64.

Signed-off-by: Dietmar Hahn <dietmar.hahn@xxxxxxxxxxxxxxxxxxx>


diff -r 01ec7dba9ff8 -r 80cd2c0ee40c extras/mini-os/gnttab.c
--- a/extras/mini-os/gnttab.c   Fri Feb 02 16:07:13 2007 +0000
+++ b/extras/mini-os/gnttab.c   Mon Feb 05 15:59:02 2007 +0100
@@ -21,7 +21,12 @@
#define NR_RESERVED_ENTRIES 8 +/* NR_GRANT_FRAMES must be less than or equal to that configured in Xen */
+#ifdef __ia64__
+#define NR_GRANT_FRAMES 1
+#else
 #define NR_GRANT_FRAMES 4
+#endif
 #define NR_GRANT_ENTRIES (NR_GRANT_FRAMES * PAGE_SIZE / sizeof(grant_entry_t))
static grant_entry_t *gnttab_table;
diff -r 01ec7dba9ff8 -r 80cd2c0ee40c extras/mini-os/netfront.c
--- a/extras/mini-os/netfront.c Fri Feb 02 16:07:13 2007 +0000
+++ b/extras/mini-os/netfront.c Mon Feb 05 15:59:02 2007 +0100
@@ -349,7 +349,9 @@ done:
     init_rx_buffers();
unsigned char rawmac[6];
-    sscanf(mac,"%x:%x:%x:%x:%x:%x",
+        /* Special conversion specifier 'hh' needed for __ia64__. Without
+           this mini-os panics with 'Unaligned reference'. */
+    sscanf(mac,"%hhx:%hhx:%hhx:%hhx:%hhx:%hhx",
             &rawmac[0],
             &rawmac[1],
             &rawmac[2],

_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel