History log of /bionic/libc/kernel/tools/defaults.py
Revision Date Author Comments
a69eaec4d48e978751356b2e8fd989d5e23a34db 19-Jun-2014 Duane Sand <duane.sand@imgtec.com> [MIPS64] Adjust kernel/tools for mips32,mips64 headers

Define CONFIG_32BIT as _ABIO32 rather than as 1;
it needs to be undefined for calls from mips64.
We need defined(CONFIG_32BIT) == !defined(CONFIG_64BIT),
and get that via defined(_ABIO32) == !defined(__LP64__).

Define CONFIG_CPU_LITTLE_ENDIAN to get correctly-placed
struct msqid64_ds fillers on ipc calls from mips32.
Without this, big-endian fillers were erroneously used.
This bug exists in prior mips32 Android releases.

Define __SANE_USERSPACE_TYPES__ to use int_ll64.h
rather than int_ll64.h on mips64.
This depends on external/kernel-headers patch
https://android-review.googlesource.com/#/c/98915/
http://patchwork.linux-mips.org/patch/6890/

Change-Id: If65fa80746533723cdf46eebe95733bea7ce24ba
8ed7a23309cd6f1a73c19a23ade2e11ab31fcb2f 15-May-2014 Elliott Hughes <enh@google.com> Scrub uapi headers slightly harder.

There's no point having always-false tests. It just makes the headers
harder to read.

Bug: 11560081
Change-Id: I6187755e1514ca9ff5642b3c1b0489f22edddaf5
0990d4fda898ada86e557f872f5cb7d16b138e3c 30-Apr-2014 Elliott Hughes <enh@google.com> Make SIGRTMIN hide the real-time signals we use internally.

__SIGRTMIN will continue to tell the truth. This matches glibc's
behavior (as evidenced by the fact that we don't need a special case
in the strsignal test now).

Change-Id: I1abe1681d516577afa8cd39c837ef12467f68dd2
9195a258ee96d6cf31b2fc7db9da16f92f5e7f65 08-Apr-2014 Elliott Hughes <enh@google.com> Fix kernel header scrubbing for LP64.

Change-Id: I4caf44d41edd1b03a20d4c565e169c2b7a2f3686
199346a2abd8b6ba282e1fe291cc3766fa921f40 12-Feb-2014 Elliott Hughes <enh@google.com> Fix NSIG.

Our sigset_t definition hasn't been tied to our NSIG definition since we
switched to uapi headers, so we can now fix it without breaking the LP32 ABI.
The kernel uapi headers define and use _NSIG, so we need to have our scripts
rename the kernel's definitions out of the way, then we can define _NSIG
and NSIG in terms of the kernel's off-by-one value.

Bug: 12938442
Change-Id: Ic7c86fd5be5ad1d822f7b2b1d88c8a0d70a1ac0f
d1973ca51325393f304e82a4d79874f33e54ac16 22-Jan-2014 Colin Cross <ccross@android.com> bionic: rename aarch64 target to arm64

Rename aarch64 build targets to arm64. The gcc toolchain is still
aarch64.

Change-Id: Ia92d8a50824e5329cf00fd6f4f92eae112b7f3a3
460fa7033b17c49e3e6fdaee49eb6d7d666e16d9 23-Oct-2013 Ben Cheng <bccheng@google.com> Add __EXPORTED_HEADERS__ as predefined macro.

To weed out stuff like this in uapi/linux/types.h

ifndef __EXPORTED_HEADERS__
warning "Attempt to use kernel headers from user space, see
http://kernelnewbies.org/KernelHeaders"
endif /* __EXPORTED_HEADERS__ */

Change-Id: I6506cea6248f7a3b44a839b98e91bdd0d3a6c4cd
8bea2b6faca554a145bdafc6f3afafec1f3120b6 17-Oct-2013 Ben Cheng <bccheng@google.com> Tweaked the cleanup scripts to handle uapi and aarch64 headers.

The processed uapi directory is now placed at libc/kernel/uapi as
opposed to libc/kernel/common/uapi as it contains
architectural-dependent headers now.

Change-Id: I53f814704a4d231b452fde398cd94257a0fb2eea
d3e64a3f403918abf2cc3f9f0f9a2204a420ec96 01-Oct-2013 Elliott Hughes <enh@google.com> Add x86_64 to the bionic headers.

Manual changes:

cpp.py: cope with macros that refer to other macros.

defaults.py: x86 no longer always implies __i386__; use __i386__ to replace
the kernel CONFIG_X86_32 flag.

asm/page.h: the upstream page.h isn't a uapi header and no longer includes
the stuff we were using it for. Let's just have our own static file, since
it's the same for all our architectures (both 32- and 64-bit).

sys/select.h: we used to use the various FD_SET-related macros from the
kernel header files, but they've gone. Adjust by adding trivial equivalent
definitions.

Automated changes:

libc/kernel/arch-x86, libc/kernel/common: regenerated from
external/kernel-headers.

Change-Id: I84fc0ed52dc742e043b4ae300fd3b58ee99b7fcd
a864c2c23486e4ab7235829d8c9574426794298a 17-Jan-2013 Raghu Gandham <raghu@mips.com> Add functionlity to the scripts to replace tokens in kernel headers
based on architecture.
0e772872090ea703a24e3afbfa1eb5abcace7f32 26-Sep-2012 Raghu Gandham <raghu@mips.com> Replace __unused in kernel headers with __linux_unused to avoid
conflicts with __unused macro in sys/cdefs.h

Change-Id: Ice664397e0b7c7a90795012f30be5e43a9675525
988ff8ff9fb8bb3394d5571ce088b23dc828edb5 22-Sep-2012 Raghu Gandham <raghu@mips.com> [MIPS] Add CONFIG_32BIT to kernel_default_arch_macros for MIPS.
Some of the required structure definitons are defined under this macro.

Change-Id: I7a9a986e371381697dcb56bd8ea362856ffa7509
82fa43febc9d679ae6276f6bf992b9b345bb5815 27-Mar-2012 Raghu Gandham <raghu@mips.com> [MIPS] Clean Kernel headers are generated by running
libc/kernel/tools/update_all.py script. This patch ignores
any changes to libc/kernel directory not related to MIPS
architecture.

Change-Id: I2c9e461dccb7c33eb4420be2db1a562f45137c8d
Signed-off-by: Raghu Gandham <raghu@mips.com>
Signed-off-by: Chris Dearman <chris@mips.com>
126601dd3f5303b50033dcb88945d928aa764aa4 23-Mar-2012 Andrew Hsieh <andrewhsieh@google.com> Fixed to #include correct 32-bit headers; Refreshed libc/kernel headers

This patch fixes an issue where 64-bit hreaders are incorrectly included
in kernel headers. For example, file "libc/kernel/arch-x86/asm/io.h"
incorreclty includes "io_64.h" (missing, BTW) instead of "io_32.h".

The reason is because CONFIG_X86_32 isn't considered pre-defined in
"kernel_default_arch_macros" for x86, and clean_header.py doesn't
look at it at all anyway (ie. __i386__ is also ignored, but it's
okay since x86 cross compiler defines it back)

Fixed 2 tools/*py, README.TXT, and refreshed libc/kernel headers

Change-Id: Iac834cc8b3548f055d3f2a214af36072dd679fe8
70b1668a76d3b719ae690903ea790fda964a5458 30-Jan-2012 David 'Digit' Turner <digit@google.com> remove obsolete SuperH support

We don't have a toolchain anymore, we don't have working original
kernel headers, and nobody is maintaining this so there is really
no point in keeping this here. Details of the patch:

- removed code paths from Android.mk files related to the SuperH
architecture ("sh")

- removed libc/arch-sh, linker/arch-sh, libc/kernel/arch-sh

- simplified libc/SYSCALLS.TXT

- simplified the scripts in libc/tools/ and libc/kernel/tools

Change-Id: I26b0e1422bdc347489e4573e2fbec0e402f75560

Signed-off-by: David 'Digit' Turner <digit@android.com>
669c823f05880e4193286e3786a18658de0156a5 01-Jun-2011 David 'Digit' Turner <digit@android.com> libc: fix typo in kernel helper script

Change-Id: I3b75b1323cf7a48cb839dede1552f24711847335
fc2693110ee8a2ba22a445ad9855fbe9e118d439 11-Oct-2010 David 'Digit' Turner <digit@google.com> libc: Update auto-gen scripts

Make the scripts use external/kernel-headers/original by default.

clean_header.py: Document -k<path>, add -d<path>
find_headers.py: Make kernel config files optional
update_all.py: Allow setting the path to kernel headers on the command-line
update_all.py: Better formatting of output on ttys
update_all.py: Automatically perform "git add/rm" on affected files.
SYSCALLS.TXT: Fix typo in __socketcall definition.
checksyscalls.py: Add support for superH architecture in the checks.
gensyscalls.py: Automatically perform "git add/rm" on affected files.
cpp.py: Fixed a bug that prevented certain type definitions to
be kept in the generated clean header (e.g.
struct ethtool_drvinfo in <linux/ethtool.h>)

All scripts will use the content of external/kernel-headers/original by default now.

The generated code removes all empty lines and trailing whitespace. This is useful
to ensure a unified output even if we change the parser again in the future.

The top-level disclaimer has been edited with update instructions to regenerate
the headers when needed.

Also, a warning is now inserted every 8th line in the final output:

/* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */

Changes under kernel/arch-arm and kernel/arch-x86 should correspond to whitespace
differences and additionnal struct definitions that were missed by the previous
parser implementation.

Change-Id: Icd1c056bacd766759f3e9b7bb5d63a246f3d656a

WARNING: If you run these script, do not submit the result to gerrit for now.
It seems there are discrepancies between the content of original headers
and those currently commited under bionic/libc/kernel/.

(This problem is the main motivation to insert the warning repeatedly).

Current list of issues:

- Missing SuperH headers (i.e. external/kernel-headers/original/asm-sh)
db7c59df6c43e89f688e357581a41d6a18944d8c 20-Jan-2011 Steinar H. Gunderson <sesse@google.com> Fix syntax error in defaults.py.

Change-Id: I149c46e7541af16856264b7f826981ce0d33290b
b969b5a32a3924412b3584a2ab606ff64a3c4203 11-Jan-2011 David 'Digit' Turner <digit@google.com> libc: fix kernel cleanup script typo.

Change-Id: I5fc119be535ed47dadc780234665335efa6b9ac5
c9205dba43c45dc5a185aa26e1160c3f62e9b471 08-Dec-2010 Martin Storsjo <martin@martin.st> Replace all occurrances of asm with __asm__ in the output headers

asm() conflicts with userland code compiled with -std=c99, the userland
libc should only use __asm__() instead. Therefore, this transformation
has to be applied to all exported headers.

This only changes arch-arm/asm/byteorder.h.

Change-Id: I1cf88c37201c3a91668d387293a18885c316d53c
c1a534ba0bc58c74bf06e7735c6fb0ffb27a6652 28-Jun-2010 Vilmos Nebehaj <v.nebehaj@gmail.com> Regenerate linux/netfilter_ipv6/ip6_tables.h.

Add ip6t_get_target() to kernel_known_generic_statics in
libc/kernel/tools/defaults.py to be able to build ip6tables.

Change-Id: Iadb885db3faa85b2d0070dc2e0ac493af6e62bb6
37429fff4101f8f75db795048226169ede9e7413 01-Jul-2009 Shin-ichiro KAWASAKI <shinichiro.kawasaki.mg@hitachi.com> modified kernel headers re-generate tools to support SuperH architecture
1dc9e472e19acfe6dc7f41e429236e7eef7ceda1 04-Mar-2009 The Android Open Source Project <initial-contribution@android.com> auto import from //depot/cupcake/@135843
1767f908af327fa388b1c66883760ad851267013 04-Mar-2009 The Android Open Source Project <initial-contribution@android.com> auto import from //depot/cupcake/@135843
6d6c82c7a0a6b9a89f61b61c66f9b90d9c7177dc 10-Jan-2009 The Android Open Source Project <initial-contribution@android.com> auto import from //branches/cupcake/...@125939
4e468ed2eb86a2406e14f1eca82072ee501d05fd 18-Dec-2008 The Android Open Source Project <initial-contribution@android.com> Code drop from //branches/cupcake/...@124589
a27d2baa0c1a2ec70f47ea9199b1dd6762c8a349 21-Oct-2008 The Android Open Source Project <initial-contribution@android.com> Initial Contribution