No description
Find a file
Nick Pelly 92a7541bce Helper to perform abortable blocking operations on a socket:
asocket_connect()
   asocket_accept()
   asocket_read()
   asocket_write()
 These calls are similar to the regular syscalls, but can be aborted with:
   asocket_abort()

Calling close() on a regular POSIX socket does not abort blocked syscalls on
that socket in other threads.

After calling asocket_abort() the socket cannot be reused.

Call asocket_destory() *after* all threads have finished with the socket to
finish closing the socket and free the asocket structure.

The helper is implemented by setting the socket non-blocking to initiate
syscalls connect(), accept(), read(), write(), then using a blocking poll()
on both the primary socket and a local pipe. This makes the poll() abortable
by writing a byte to the local pipe in asocket_abort().

asocket_create() sets the fd to non-blocking mode. It must not be changed to
blocking mode.

Using asocket will triple the number of file descriptors required per
socket, due to the local pipe. It may be possible to use a global pipe per
process rather than per socket, but we have not been able to come up with a
race-free implementation yet.

All functions except asocket_init() and asocket_destroy() are thread safe.
2009-05-20 15:20:30 -07:00
adb am 1b154930: Merge change 1867 into donut 2009-05-19 02:53:38 -07:00
cpio auto import from //depot/cupcake/@135843 2009-03-03 19:32:55 -08:00
debuggerd auto import from //depot/cupcake/@135843 2009-03-03 19:32:55 -08:00
fastboot fastboot: Update the help message with -b argument 2009-04-30 15:03:05 -07:00
include Helper to perform abortable blocking operations on a socket: 2009-05-20 15:20:30 -07:00
init am d4cdd13f: init: Clean up dynamic argument handling for services 2009-05-20 11:49:50 -07:00
libacc Fix x64 int / pointer warnings. 2009-05-20 12:12:06 -07:00
libctest Automated import from //branches/master/...@140824,140824 2009-03-24 18:36:50 -07:00
libcutils Helper to perform abortable blocking operations on a socket: 2009-05-20 15:20:30 -07:00
liblog Merge branch 'readonly-p4-master' 2009-04-02 11:02:19 -07:00
libmincrypt Automated import from //branches/master/...@140824,140824 2009-03-24 18:36:50 -07:00
libnetutils Automated import from //branches/master/...@140824,140824 2009-03-24 18:36:50 -07:00
libpixelflinger Merge commit 'remotes/korg/cupcake' into merge 2009-03-18 09:29:29 -07:00
libsysutils libsysutils: Introduce 'ServiceManager', for starting/stopping init services 2009-05-15 10:40:23 -07:00
libzipfile auto import from //depot/cupcake/@135843 2009-03-03 19:32:55 -08:00
logcat new cdma event log tags 2009-05-19 15:26:18 +08:00
logwrapper Automated import from //branches/master/...@140824,140824 2009-03-24 18:36:50 -07:00
mkbootimg fastboot, mkbootimg: support alternate base addresses 2009-04-28 16:05:07 -07:00
netcfg auto import from //depot/cupcake/@135843 2009-03-03 19:32:55 -08:00
nexus nexus: Flesh out VPN support a bit more, cleanup service handling 2009-05-15 10:40:29 -07:00
rootdir init.rc: Add Nexus to services (disabled for now) 2009-05-06 15:20:22 -07:00
sh auto import from //depot/cupcake/@135843 2009-03-03 19:32:55 -08:00
toolbox am c83cd879: init: Fix heap corruption for services with arguments 2009-05-14 15:12:43 -07:00
vold am b76a63b7: vold: Change VFAT mount options to enable sdcard write restrictions 2009-05-18 13:44:42 -07:00
Android.mk libsysutils: New C++ system convenience library 2009-05-06 15:12:02 -07:00
README auto import from //depot/cupcake/@135843 2009-03-03 19:32:55 -08:00

The system/ directory is intended for pieces of the world that are the
core of the embedded linux platform at the heart of Android.  These
essential bits are required for basic booting, operation, and debugging.

They should not depend on libraries outside of system/... (some of them
do currently -- they need to be updated or changed) and they should not
be required for the simulator build.

The license for all these pieces should be clean (Apache2, BSD, or MIT).

Currently system/bluetooth/... and system/extra/... have some pieces
with GPL/LGPL licensed code.

Assorted Issues:

- pppd depends on libutils for logging
- pppd depends on libcrypt/libcrypto
- init, linker, debuggerd, toolbox, usbd depend on libcutils
- should probably rename bionic to libc