From mboxrd@z Thu Jan 1 00:00:00 1970 From: Grzegorz Milos Subject: Re: [PATCH]mini-os: Fix to get netfront running on ia64 Date: Tue, 06 Feb 2007 21:59:49 +0000 Message-ID: <45C8FA55.6060901@cam.ac.uk> References: <200702060803.21254.dietmar.hahn@fujitsu-siemens.com> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <200702060803.21254.dietmar.hahn@fujitsu-siemens.com> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xensource.com Errors-To: xen-devel-bounces@lists.xensource.com To: Dietmar Hahn Cc: xen-devel@lists.xensource.com List-Id: xen-devel@lists.xenproject.org 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@fujitsu-siemens.com > # Date 1170687542 -3600 > # Node ID 80cd2c0ee40cddec1914542f221159b5911368b3 > # Parent 01ec7dba9ff805a5c74a0318997b747d3e3e3327 > 2 Fixes for supporting netfront on ia64. > > Signed-off-by: Dietmar Hahn > > > 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],