Re: [PATCH] x86: use dmi check in apic_is_clustered with 64bit

From: Ravikiran G Thirumalai
Date: Mon Apr 27 2009 - 19:31:07 EST


On Sun, Apr 26, 2009 at 11:39:38PM -0700, Yinghai Lu wrote:
>
>will have system with 2 and more sockets 8cores/2thread.
>do treat them as multi chassis.
>
>use dmi check instead.
>
>[ Impact: do not make unstable TSC on wrongly ]
>
>Signed-off-by: Yinghai Lu <yinghai@xxxxxxxxxx>
>

The patch looks good.
Just one minor observation -- apic_is_clustered_box()
is used only to check if tscs are synced. It is not used elsewhere. Since
the routine is not actually checking if the box uses clustered apic --
rather the routine is used to determine if tsc's are synced are not, the name
could be changed appropriately I guess?

...
>+}
>+
>+/*
>+ * apic_is_clustered_box() -- Check if we can expect good TSC
>+ *
>+ * Thus far, the major user of this is IBM's Summit2 series:
>+ * Clustered boxes may have un-synced TSC problems if they are
>+ * multi-chassis.
>+ * Use DMI to check them
>+ */
>+__cpuinit int apic_is_clustered_box(void)
>+{
>+ dmi_check_multi();
>+ if (multi)
> return 1;
>
>+ if (!is_vsmp_box())
>+ return 0;
>+
> /*
>- * If clusters > 2, then should be multi-chassis.
>- * May have to revisit this when multi-core + hyperthreaded CPUs come
>- * out, but AFAIK this will work even for them.
>+ * ScaleMP vSMPowered boxes have one cluster per board and TSCs are
>+ * not guaranteed to be synced between boards
> */
>- return (clusters > 2);
>+ if (apic_cluster_num() > 1)
>+ return 1;
>+
>+ return 0;
> }

...
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/