Re: [PATCH v4 03/14] ARM: Factor out cpuid implementor and part number

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

 



On Thu, Nov 29, 2012 at 09:38:46PM +0000, Christoffer Dall wrote:
> On Mon, Nov 19, 2012 at 9:21 AM, Will Deacon <will.deacon@xxxxxxx> wrote:
> > On Sat, Nov 10, 2012 at 03:42:31PM +0000, Christoffer Dall wrote:
> >> Decoding the implementor and part number of the CPU id in the CPU ID
> >> register is needed by KVM, so we factor it out to share the code.
> >>
> >> Reviewed-by: Marcelo Tosatti <mtosatti@xxxxxxxxxx>
> >> Signed-off-by: Christoffer Dall <c.dall@xxxxxxxxxxxxxxxxxxxxxx>

[...]

> >> +static inline unsigned int __attribute_const__ read_cpuid_implementor(void)
> >> +{
> >> +     return (read_cpuid_id() & 0xFF000000) >> 24;
> >> +}
> >> +
> >> +static inline unsigned int __attribute_const__ read_cpuid_part_number(void)
> >> +{
> >> +     return (read_cpuid_id() & 0xFFF0);
> >> +}
> >
> > Perhaps this should take the implementor as an argument, given that the
> > part number is described differently between implementors. The xscale
> > stuff can then move in here (we'll need to check the xscale docs in case
> > perf is using a subfield -- I can't remember off-hand).

[...]

> > If you stick this one in a separate patch, I can take it via the perf
> > tree (along with the CPUID rework above).
> >
> thanks,
> I sent a separate patch.

Looks like we still have the ugly xscale cpuid parsing inline. Could you
move it as I suggested, please?

Will
--
To unsubscribe from this list: send the line "unsubscribe kvm" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [KVM ARM]     [KVM ia64]     [KVM ppc]     [Virtualization Tools]     [Spice Development]     [Libvirt]     [Libvirt Users]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite Questions]     [Linux Kernel]     [Linux SCSI]     [XFree86]
  Powered by Linux