Author: sobomax
Date: Mon Jul 18 03:59:03 2016
New Revision: 302978
URL: https://svnweb.freebsd.org/changeset/base/302978

Log:
  Don't print same value twice, one in decimal once in hex. This makes
  output more cryptic than it needs to be and wastes cpu cycles and
  console bandwidth.

Modified:
  head/sys/x86/x86/mp_x86.c

Modified: head/sys/x86/x86/mp_x86.c
==============================================================================
--- head/sys/x86/x86/mp_x86.c   Mon Jul 18 02:13:57 2016        (r302977)
+++ head/sys/x86/x86/mp_x86.c   Mon Jul 18 03:59:03 2016        (r302978)
@@ -649,12 +649,10 @@ cpu_mp_announce(void)
        TOPO_FOREACH(node, &topo_root) {
                switch (node->type) {
                case TOPO_TYPE_PKG:
-                       printf("Package HW ID = %u (%#x)\n",
-                           node->hwid, node->hwid);
+                       printf("Package HW ID = %u\n", node->hwid);
                        break;
                case TOPO_TYPE_CORE:
-                       printf("\tCore HW ID = %u (%#x)\n",
-                           node->hwid, node->hwid);
+                       printf("\tCore HW ID = %u\n", node->hwid);
                        break;
                case TOPO_TYPE_PU:
                        if (cpu_info[node->hwid].cpu_hyperthread)
@@ -663,16 +661,14 @@ cpu_mp_announce(void)
                                hyperthread = "";
 
                        if (node->subtype == 0)
-                               printf("\t\tCPU (AP%s): APIC ID: %u (%#x)"
-                                   "(disabled)\n", hyperthread, node->hwid,
-                                   node->hwid);
+                               printf("\t\tCPU (AP%s): APIC ID: %u"
+                                   "(disabled)\n", hyperthread, node->hwid);
                        else if (node->id == 0)
-                               printf("\t\tCPU0 (BSP): APIC ID: %u (%#x)\n",
-                                   node->hwid, node->hwid);
-                       else
-                               printf("\t\tCPU%u (AP%s): APIC ID: %u (%#x)\n",
-                                   node->id, hyperthread, node->hwid,
+                               printf("\t\tCPU0 (BSP): APIC ID: %u\n",
                                    node->hwid);
+                       else
+                               printf("\t\tCPU%u (AP%s): APIC ID: %u\n",
+                                   node->id, hyperthread, node->hwid);
                        break;
                default:
                        /* ignored */
_______________________________________________
svn-src-all@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"

Reply via email to