>>> Julien Grall <julien.gr...@arm.com> 09/28/17 9:30 PM >>> >On 09/22/2017 10:15 AM, Jan Beulich wrote: >>>>> On 21.09.17 at 14:40, <julien.gr...@arm.com> wrote: >>> Also take the opportunity to: >>> - move from 1 << * to 1UL << *. >>> - use unsigned when possible >>> - move from unsigned int -> unsigned long for some induction >>> variables >> >> I don't understand this last point, btw - the largest order page the >> code needs to deal with right now is 1Gb, so there's no risk of >> overflow (yet). But you've got George's and Andrew's ack, so no >> need to revise this... > >The last one result from the existing 1UL << in the code. We have place >where the induction variable is unsigned int but the shift unsigned long.
In which case I would have suggested to change the shift to use 1U, since ... >Similarly the code is using a mix of 1 << and 1UL <<. I moved to UL >because even if the code only support up to 1GB superpage at the moment, >it would be pain to find all the places the day we decide to use bigger one. ... I doubt this would be too hard. But in the end it's George to judge anyway. Jan _______________________________________________ Xen-devel mailing list Xen-devel@lists.xen.org https://lists.xen.org/xen-devel