Fix a regression in r321608.
On i386 with CPUID but without SSE2, set lfence_works to LMB_NONE instead of looping. Reported and tested by: Andre Albsmeier <andre@fbsd.e4m.org> Sponsored by: The FreeBSD Foundation MFC after: 3 days
This commit is contained in:
parent
413bf7b083
commit
b1cbddaf5d
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=322456
@ -101,6 +101,7 @@ init_fence(void)
|
||||
#if defined(__i386__)
|
||||
u_int cpuid_supported, p[4];
|
||||
|
||||
lfence_works = LMB_NONE;
|
||||
__asm __volatile(
|
||||
" pushfl\n"
|
||||
" popl %%eax\n"
|
||||
@ -121,8 +122,7 @@ init_fence(void)
|
||||
cpuidp(0x1, p);
|
||||
if ((p[3] & CPUID_SSE2) != 0)
|
||||
lfence_works = select_lmb();
|
||||
} else
|
||||
lfence_works = LMB_NONE;
|
||||
}
|
||||
#elif defined(__amd64__)
|
||||
lfence_works = select_lmb();
|
||||
#else
|
||||
|
Loading…
Reference in New Issue
Block a user