Re: [PATCH] MIPS: Changed current_thread_info() to an equivalent supported by both clang and GCC

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Ralf Baechle <ralf@xxxxxxxxxxxxxx> writes:

> On Sat, Jan 10, 2015 at 12:53:22PM +0000, Daniel Sanders wrote:
>
>> The main reason I renamed it is that identifiers starting with '__'
>> are reserved. It's pretty unlikely but it's possible that the name
>> will conflict with a C implementation in the future.
>
> The whole kernel is using identifiers starting with a double underscore
> left and right.  The risk should be acceptable though - also because the
> kernel isn't linked against external libraries.

The reserved namespace applies to applications built against a standard
library so as to avoid name clashes with library internals.  The kernel
doesn't use the standard library, so it can use any identifiers.  This
should be clear from the fact that the reserved identifiers are listed
in the "Library" chapter of the C standard.

-- 
Måns Rullgård
mans@xxxxxxxxx




[Index of Archives]     [Linux MIPS Home]     [LKML Archive]     [Linux ARM Kernel]     [Linux ARM]     [Linux]     [Git]     [Yosemite News]     [Linux SCSI]     [Linux Hams]

  Powered by Linux