lkml.org 
[lkml]   [2015]   [Apr]   [22]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH 2/2] x86/asm/entry/32: Remove unnecessary optimization in stub32_clone
On Wed, Apr 22, 2015 at 11:22:02AM -0700, Linus Torvalds wrote:
> On Wed, Apr 22, 2015 at 10:10 AM, Josh Triplett <josh@joshtriplett.org> wrote:
> >
> > I do think my two-patch HAVE_COPY_THREAD_TLS series should go in fixing
> > this
>
> Ugh, I absolutely detesrt that patch.
>
> Don't make random crazy function signatures that depend on some config
> option. That's just evil. The patch is a mess of #ifdef's and should
> be shot in the head and staked with a silver stake to make sure it
> never re-appears.
>
> Either:
>
> (a) make the change for every architecture
>
> (b) have side-by-side interfaces. With different names!

...that's exactly what I did. They're called copy_thread and
copy_thread_tls; I very intentionally did not conditionally change the
signature of copy_thread, for exactly that reason. Those functions are
implemented in architecture-specific code, so the config option just
specifies which of the two functions the architecture provides.

*sys_clone* has different function signatures based on config options,
but I didn't touch that other than fixing the type of the tls argument.
That's historical baggage that we can't throw away without breaking
userspace.

- Josh Triplett


\
 
 \ /
  Last update: 2015-04-22 22:21    [W:0.036 / U:0.580 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site