Adding CuTest Framework

Change-Id: Iae6b72c81a5d60e26e0935da3bc1433f7ded0764
Test file for libcutils str.h

Change-Id: I9516a90046b5f71dd9d43976ee2709e63338523f
fix for missing return value

Change-Id: I6988d10402e1f001f8a47e47600247ded306261f
Add testing makefile

Change-Id: I30d845f16e445a50d93c0d91eb8cef380ebd2df0
adb: Add USB vendor ID for EMERGING Technology (Holdings) Ltd.

Change-Id: Ic7f7c984db19050d2ce4da8ae87683ce42dc9094
Signed-off-by: DanielMo <DanielMo@fih-foxconn.com>

Conflicts:
	adb/usb_vendors.c
ADB Logcat colored output.

This patch adds a new '-C' option to logcat so that the output is
colored with colors similar to the ones in DDMS.
Simply type "adb logcat -C" to use it.
Works well with bash in gnome-terminal.

Change-Id: I8f6da4cf20e6d42094280672b0ab41a97b7ca797
Signed-off-by: Chirayu Desai <cdesai@cyanogenmod.org>
[AOSP] Pass uevent pointer as parameter when handling device

BZ: 125728

Replace parameters of 'handle_device' and 'make_device' functions
by uevent pointer. This allows to access all uevent info when
creating a device (eg: Modalias). For instance, to rename a device
according to its vendor ID.

Category: feature differentiation
Domain: AOSP.Connectivity-CCF
Origin: Internal
Upstream-Candidate: yes

Change-Id: I7447131dcd71e8a0f8a59e909e134a8557650e93
Signed-off-by: David Bagnol <david.bagnol@intel.com>
Signed-off-by: Guillaume Ranquet <guillaumex.ranquet@intel.com>
[AOSP] Create new commands for ueventd to rename network interfaces and devices.

BZ: 139938

Implements a solution to set dedicated names to enumerated devices or network
interfaces. This would allow components to use a specific node/interface name
(eg: tty) instead of using the default one given by a device driver.
It is obviously better to have unique node/interface names used by each framework
component in order to avoid accidental use conflict with other programs.

Ueventd configuration files (ueventd.rc) only support a subset of what udev is
capable of. Ueventd configuration file only permits to set owner/modes of nodes
in /dev, while udev permits to write complex rules that enable
(amongst other things) choosing the name of the node in /dev or rename a network
interface.

This patch defines 2 new commands:
inet:[xx:xx:xx:xx:xx:xx;*]/<if_name>        <new_if_name>
=> Rename network interface with address xx:xx:xx:xx:xx:xx or wildcard '*' and
with default name <if_name>, onto the new name <new_if_name>.

dev:[<vendor_id>;*]/[<product_id>;*]/<dev_name>       /dev/<new_dev_name>
=> Rename device node <dev_name> with <vendor_id> or '*' and <product_id> or '*'
onto new name <new_dev_name>.

The wildcard character '*' indicates that any value is supported.

This implementation updates the uevent.rc parsing functions to handle the
2 new cmd rules.
It also updates the handling of device and network uevents raised by kernel.

Category: feature differentiation
Domain: AOSP.Connectivity-CCF
Origin: Internal
Upstream-Candidate: yes

Change-Id: Ide70553adafaeb334d25e917f3e1475c91c1a235
Signed-off-by: David Bagnol <david.bagnol@intel.com>
Signed-off-by: Guillaume Ranquet <guillaumex.ranquet@intel.com>
init: remove obsolete rle logo

Obsolete RLE 565 logo is used nowhere,
because 565 framebuffer isn't used for years.

It's not necessary to keep this thing alive anymore.

Change-Id: Ie61e168790f791230530cd3eb1c68b1f7344c9a7
Wait for device to disappear after reboot-bootloader.

(Linux only for now) With fastboot reading serial numbers from sysfs, it had
become possible for a fastboot command issued immediately after rebooting
the bootloader to fail, because sysfs still thought the device was online.
To prevent this, after reboot-bootloader we wait for the device to disconnect.

Also made usb_read and usb_write fail immediately if the descriptor has been
closed; this prevents an incorrect error message ("Bad file descriptor")
when errors from fb_getvar are ignored (e.g., by fb_format_supported).

Also removed unused fd param from filter_usb_device, and simplified logic
in usb_write by using do/while instead of a special case for len == 0.

Change-Id: I799b857eab411fd8ad25f5777fc61c685152ea86

Conflicts:
	fastboot/usb_linux.c
Use %zd for size_t.

Change-Id: I0139243c309e85236eb00bb471736bdd99eeec84