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-ppc-devel

Re: [XenPPC] [patch] Added dev64.h file provided by linux include set bu

To: xen-ppc-devel@xxxxxxxxxxxxxxxxxxx
Subject: Re: [XenPPC] [patch] Added dev64.h file provided by linux include set but not by gcc include set
From: Maria Butrico <butrico@xxxxxxxxxx>
Date: Wed, 8 Mar 2006 16:26:01 -0500
Delivery-date: Wed, 08 Mar 2006 21:29:09 +0000
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
In-reply-to: <200603081501.47427.hollisb@xxxxxxxxxx>
List-help: <mailto:xen-ppc-devel-request@lists.xensource.com?subject=help>
List-id: Xen PPC development <xen-ppc-devel.lists.xensource.com>
List-post: <mailto:xen-ppc-devel@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-ppc-devel>, <mailto:xen-ppc-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-ppc-devel>, <mailto:xen-ppc-devel-request@lists.xensource.com?subject=unsubscribe>
Sender: xen-ppc-devel-bounces@xxxxxxxxxxxxxxxxxxx
We could expect that in my version of things __div64_32 is used only when
"#elif BITS_PER_LONG == 32".  Is this the environment under which we build
xen?

Maria Butrico    <internet or sametime: butrico@xxxxxxxxxx;     Notes:
Maria Butrico/Watson/IBM>



                                                                           
             hollisb@xxxxxxxxx                                             
             .linux.ibm.com                                                
                                                                        To 
             03/08/2006 04:01          xen-ppc-devel@xxxxxxxxxxxxxxxxxxx   
             PM                                                         cc 
                                       Maria Butrico                       
                                       <butrico@xxxxxxxxxxxxxx>            
                                                                   Subject 
                                       Re: [XenPPC] [patch] Added dev64.h  
                                       file provided by linux include set  
                                       but not by gcc include set          
                                                                           
                                                                           
                                                                           
                                                                           
                                                                           
                                                                           




On Wednesday 08 March 2006 13:50, Maria Butrico wrote:
> Signed off by Maria Butrico <butrico@xxxxxxxxxxxxxx>
>
> summary:     Added dev64.h file provided by linux include set but not by
gcc
include set
>
> diff -r 1b222c9ed5d6 -r 28ea10d90b23 xen/include/asm-ppc/div64.h
> --- /dev/null          Thu Jan  1 00:00:00 1970 +0000
> +++ b/xen/include/asm-ppc/div64.h        Wed Mar  8 13:34:53 2006 -0500
> @@ -0,0 +1,18 @@
> +#ifndef __PPC_DIV64
> +#define __PPC_DIV64
> +
> +/* Copyright 2001 PPC64 Team, IBM Corp
> + *
> + * This program is free software; you can redistribute it and/or
> + * modify it under the terms of the GNU General Public License
> + * as published by the Free Software Foundation; either version
> + * 2 of the License, or (at your option) any later version.
> + */
> +
> +#define do_div(n,base) ({ \
> +          int __res; \
> +          __res = ((unsigned long) (n)) % (unsigned) (base); \
> +          (n) = ((unsigned long) (n)) / (unsigned) (base); \
> +          __res; })
> +
> +#endif

Hi Maria, I'm guessing this file came from an older (pre "powerpc" arch)
Linux
tree? The current linux/include/asm-powerpc/div64.h just uses
asm-generic/div64.h, which uses __div64_32 which I think is provided to us
by
libgcc.

Could we copy asm-generic/div64.h instead?

--
Hollis Blanchard
IBM Linux Technology Center



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