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

Re: [PATCH v3 08/14] xen/asm-generic: introduce generic div64.h header



Hi Julien,

On Fri, 2023-11-24 at 11:29 +0000, Julien Grall wrote:
> Hi,
> 
> On 17/11/2023 12:24, Oleksii Kurochko wrote:
> > All archs have the do_div implementation for BITS_PER_LONG == 64
> > so do_div64.h is moved to asm-generic.
> 
> You are saying "all archs" but ...
> 
> > 
> > x86 and PPC were switched to asm-generic version of div64.h.
> 
> ... you only switch x86/PPC to div64.h.
You are right. I wasn't precise enough. Also RISC-V uses asm-generic
version of div64.h but for that I have separate patch series.

> 
> I guess this is because for arm we have a different implementation
> for 
> 32-bits. The 64-bits version is the same as x86/PPC.
> 
> So I wonder if it is possible to include asm-generic/div64.h from 
> arch/arm/include/asm/div64.h?
> 
> This will avoid duplicating some code.
Yes, you are right. Arm wasn't switched to asm-generic/div64.h because
of different implementaion for 32-bit.

I think we can include asm-generic/div64.h excplicitly for Arm. I made
a little test and it works so I started full CI and if it won't any
issue with Arm I'll update the patch.


Thanks for the comments.

> Cheers,
> 




 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.