lkml.org 
[lkml]   [2008]   [Aug]   [14]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [RFC PATCH] x86 alternatives : fix LOCK_PREFIX race with preemptible kernel and CPU hotplug
* H. Peter Anvin (hpa@zytor.com) wrote:
> Jeremy Fitzhardinge wrote:
>> Ah, OK. I'd thought we started unlocked, but given that I've just been
>> disassembling the kernel and looking at the lock prefixes, that's a bit of
>> a braino on my part.
>> BTW, using the ds prefix allows us to undo the hack of dealing with locked
>> instructions with exception handlers. There was a bug where if we do
>> lock->nop, then the address of a faulting instruction changes, so we need
>> exception records for both the locked and unlocked forms. Using ds means
>> the instruction size doesn't change, so we only need one exception record.
>> I don't remember off hand where that happens.
>
> Using %ds: rather than nop really seems to solve a whole lot of problems,
> and might even be faster to boot. It really sounds like a no-brainer.
>
> -hpa

So should I wait a bit for more comments or straightforwardly submit
this as a patch rather than RFC ?

Mathieu



--
Mathieu Desnoyers
OpenPGP key fingerprint: 8CD5 52C3 8E3C 4140 715F BA06 3F25 A8FE 3BAE 9A68


\
 
 \ /
  Last update: 2008-08-14 20:57    [W:0.262 / U:0.140 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site