Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 4 May 2014 07:22:51 +0000 (UTC)
From:      Konstantin Belousov <kib@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org
Subject:   svn commit: r265312 - stable/10/sys/amd64/amd64
Message-ID:  <201405040722.s447Mp6s037375@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: kib
Date: Sun May  4 07:22:51 2014
New Revision: 265312
URL: http://svnweb.freebsd.org/changeset/base/265312

Log:
  MFC r265004:
  Same as it was done in r263878 for invlrng_handler(), fix order of
  checks for special pcid values in invlpg_pcid_handler().

Modified:
  stable/10/sys/amd64/amd64/mp_machdep.c
Directory Properties:
  stable/10/   (props changed)

Modified: stable/10/sys/amd64/amd64/mp_machdep.c
==============================================================================
--- stable/10/sys/amd64/amd64/mp_machdep.c	Sun May  4 07:19:37 2014	(r265311)
+++ stable/10/sys/amd64/amd64/mp_machdep.c	Sun May  4 07:22:51 2014	(r265312)
@@ -1567,6 +1567,7 @@ invlpg_handler(void)
 void
 invlpg_pcid_handler(void)
 {
+	uint64_t cr3;
 #ifdef COUNT_XINVLTLB_HITS
 	xhits_pg[PCPU_GET(cpuid)]++;
 #endif /* COUNT_XINVLTLB_HITS */
@@ -1574,15 +1575,13 @@ invlpg_pcid_handler(void)
 	(*ipi_invlpg_counts[PCPU_GET(cpuid)])++;
 #endif /* COUNT_IPIS */
 
-	if (invpcid_works) {
-		invpcid(&smp_tlb_invpcid, INVPCID_ADDR);
+	if (smp_tlb_invpcid.pcid == (uint64_t)-1) {
+		invltlb_globpcid();
 	} else if (smp_tlb_invpcid.pcid == 0) {
 		invlpg(smp_tlb_invpcid.addr);
-	} else if (smp_tlb_invpcid.pcid == (uint64_t)-1) {
-		invltlb_globpcid();
+	} else if (invpcid_works) {
+		invpcid(&smp_tlb_invpcid, INVPCID_ADDR);
 	} else {
-		uint64_t cr3;
-
 		/*
 		 * PCID supported, but INVPCID is not.
 		 * Temporarily switch to the target address



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201405040722.s447Mp6s037375>