lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <486807D6.9060407@zytor.com>
Date:	Sun, 29 Jun 2008 15:08:22 -0700
From:	"H. Peter Anvin" <hpa@...or.com>
To:	Andi Kleen <andi@...stfloor.org>
CC:	Avi Kivity <avi@...ranet.com>, Agner Fog <agner@...er.org>,
	Arjan van de Ven <arjan@...radead.org>,
	linux-kernel@...r.kernel.org
Subject: Re: ABI change for device drivers using future AVX instruction set

Andi Kleen wrote:
>>>   
>> If you use xsave, I don't see how this is different to the user fpu save
>> area.
> 
> For once there's no clear error handling path for allocation failures
> on the (arbitarily sized) xsave state. On user code that can be barely
> tolerated, but for the kernel it would be deadly.
> 

Well, that's relatively easily dealt with... you'd have to allocate that 
state save area explicitly in kernel_fpu_begin(), and it would be up to 
the callers of that function to handle the resulting sleep and/or 
allocation failure -- we could even make kernel_fpu_begin() take a GFP_* 
flag.

Now, there are a few possibilities what to do with said state area.  One 
is to make it associated with the task; if used for something as RAID, 
this would mean pretty soon *all* (or nearly all) tasks have such a 
state area, and we might as well go back to allocating them preemptively 
on thread creation.  The other, of course, is to destroy it in 
kernel_fpu_end().  This may cause quite a bit of allocation/deallocation 
overhead, but perhaps this would be a decent use of a quicklist.

	-hpa


--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ