Date: Thu, 28 Feb 2013 18:12:56 +0000 (UTC) From: John Baldwin <jhb@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org Subject: svn commit: r247480 - stable/9/usr.sbin/acpi/acpidump Message-ID: <201302281812.r1SICuFs094994@svn.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: jhb Date: Thu Feb 28 18:12:56 2013 New Revision: 247480 URL: http://svnweb.freebsd.org/changeset/base/247480 Log: MFC 241198: Display the matrix of inter-domain distances in the SLIT table. This is used to complement the SRAT table on NUMA machines. Modified: stable/9/usr.sbin/acpi/acpidump/acpi.c Directory Properties: stable/9/usr.sbin/acpi/acpidump/ (props changed) Modified: stable/9/usr.sbin/acpi/acpidump/acpi.c ============================================================================== --- stable/9/usr.sbin/acpi/acpidump/acpi.c Thu Feb 28 18:10:35 2013 (r247479) +++ stable/9/usr.sbin/acpi/acpidump/acpi.c Thu Feb 28 18:12:56 2013 (r247480) @@ -63,6 +63,7 @@ static void acpi_handle_madt(ACPI_TABLE_ static void acpi_handle_ecdt(ACPI_TABLE_HEADER *sdp); static void acpi_handle_hpet(ACPI_TABLE_HEADER *sdp); static void acpi_handle_mcfg(ACPI_TABLE_HEADER *sdp); +static void acpi_handle_slit(ACPI_TABLE_HEADER *sdp); static void acpi_print_srat_cpu(uint32_t apic_id, uint32_t proximity_domain, uint32_t flags); static void acpi_print_srat_memory(ACPI_SRAT_MEM_AFFINITY *mp); @@ -519,6 +520,33 @@ acpi_handle_mcfg(ACPI_TABLE_HEADER *sdp) } static void +acpi_handle_slit(ACPI_TABLE_HEADER *sdp) +{ + ACPI_TABLE_SLIT *slit; + UINT64 i, j; + + printf(BEGIN_COMMENT); + acpi_print_sdt(sdp); + slit = (ACPI_TABLE_SLIT *)sdp; + printf("\tLocality Count=%jd\n", slit->LocalityCount); + printf("\n\t "); + for (i = 0; i < slit->LocalityCount; i++) + printf(" %3jd", i); + printf("\n\t +"); + for (i = 0; i < slit->LocalityCount; i++) + printf("----"); + printf("\n"); + for (i = 0; i < slit->LocalityCount; i++) { + printf("\t %3jd |", i); + for (j = 0; j < slit->LocalityCount; j++) + printf(" %3d", + slit->Entry[i * slit->LocalityCount + j]); + printf("\n"); + } + printf(END_COMMENT); +} + +static void acpi_print_srat_cpu(uint32_t apic_id, uint32_t proximity_domain, uint32_t flags) { @@ -1084,6 +1112,8 @@ acpi_handle_rsdt(ACPI_TABLE_HEADER *rsdp acpi_handle_ecdt(sdp); else if (!memcmp(sdp->Signature, ACPI_SIG_MCFG, 4)) acpi_handle_mcfg(sdp); + else if (!memcmp(sdp->Signature, ACPI_SIG_SLIT, 4)) + acpi_handle_slit(sdp); else if (!memcmp(sdp->Signature, ACPI_SIG_SRAT, 4)) acpi_handle_srat(sdp); else if (!memcmp(sdp->Signature, ACPI_SIG_TCPA, 4))
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201302281812.r1SICuFs094994>