Commit graph

4890 commits

Author SHA1 Message Date
Johan Redestig
93ca79b445 Allow more characters in partition name links
We have several partitions with underscores in their names
which would not be properly linked in:
/dev/block/platform/msm_sdcc.1/by-name/

With this change more characters (_-.) are allowed in
partition name links. Also, any other character is
replaced with '_' so the resulting link names have the
same length as the partition name.

Change-Id: I746566c03db98b10326c755692362d2c10e528ae
2013-07-18 10:06:01 +02:00
Elliott Hughes
596ee9ea8a Merge "Improve the crasher stack-overflow command." 2013-07-16 17:19:58 +00:00
Elliott Hughes
b1be27e29b Improve the crasher stack-overflow command.
Runs a lot quicker, with no intermediate noise.

Change-Id: Icd911ff305da2e0889029dc78d5c2b39f32111c5
2013-07-15 17:19:02 -07:00
Nick Kralevich
fb1c9cf6fa Merge "use ext4 instead of yaffs" 2013-07-12 18:16:48 +00:00
Ken Sumrall
42031e0ed7 Merge "fs_mgr_priv: Extend fs wait timeout to 20 seconds" 2013-07-10 22:42:37 +00:00
Nick Kralevich
f4c1512db8 use ext4 instead of yaffs
This is needed to allow the emulator to use ext4 images.

Bug: https://code.google.com/p/android/issues/detail?id=38561
Change-Id: I02fde6382ad67cf7f4f3b695396841f70bb9301d
2013-07-09 18:06:11 -07:00
Colin Cross
fafcabd0dd Merge "Added net.dns1 prop for emulator, as Android emulator ignores it by default." 2013-07-03 22:35:42 +00:00
Colin Cross
b6c6028594 Merge changes Ieb94caab,I762da21e
* changes:
  init: move initial property area allocation into bionic
  property_service: make /dev/__properties__ readable
2013-06-25 00:07:54 +00:00
Colin Cross
83ada447ae Merge changes Ib54f39fd,I7e36edd8
* changes:
  init: Retain traditional restart behavior for critical and oneshot services.
  init: Safely restart services to avoid race conditions.
2013-06-24 22:23:32 +00:00
Greg Hackmann
2baad52520 init: move initial property area allocation into bionic
bionic's __system_property_add() now expands the property area as needed
by mapping in more pages.  Rather than duplicate the mapping code, move
it inside bionic and have bionic's __system_property_area_init() set up
the first page.

Signed-off-by: Greg Hackmann <ghackmann@google.com>

(cherry picked from commit f14eef0c3c)

Change-Id: Ieb94caab1527c71f2155efe3795490b0ea215a29
2013-06-19 12:26:31 -07:00
Nick Kralevich
26f2d2f519 property_service: make /dev/__properties__ readable
Currently, system properties are passed via the environment
variable ANDROID_PROPERTY_WORKSPACE and a file descriptor passed
from parent to child. This is insecure for setuid executables,
as the environment variable can be changed by the caller.

Make the /dev/__properties__ file accessible, so an app can
get properties directly from the file, rather than relying on
environment variables.

Preserve the environment variable for compatibility with pre-existing
apps.

Bug: 8045561

(cherry picked from commit 7ece0a862c)

Change-Id: I762da21ef4075f288745efed0ec7d16c2b71303c
2013-06-19 12:26:28 -07:00
Colin Cross
e755dfd438 Merge changes I1db3137b,I0f66144e
* changes:
  toolbox: reimplement watchprops using __system_property_foreach()
  libcutils: reimplement property_list() using __system_property_foreach()
2013-06-19 17:32:06 +00:00
Greg Hackmann
68e9b6bc94 toolbox: reimplement watchprops using __system_property_foreach()
Internally, replace the watchlist array with a hashmap since the array
assumes properties are enumerated in a consistent order and foreach()
probably won't.  (find_nth() never guaranteed this either but it usually
worked in practice.)

Signed-off-by: Greg Hackmann <ghackmann@google.com>

(cherry picked from commit 389e358017)

Change-Id: I1db3137b130474f4bb205f01f0bdcf37cf974764
2013-06-18 19:26:28 -07:00
Greg Hackmann
6967935eb3 libcutils: reimplement property_list() using __system_property_foreach()
Signed-off-by: Greg Hackmann <ghackmann@google.com>

(cherry picked from commit e7bb159d16)

Change-Id: I0f66144eb8a4a48e04e4fcd125ad37f19ad94b8e
2013-06-18 19:26:27 -07:00
Elliott Hughes
d92e35eb7b Merge "Add Qisda usb config" 2013-06-18 18:30:39 +00:00
esther
001fe87e02 Add Qisda usb config
add Qisda usb config
Signed-off-by: esther <esther530@gmail.com>

Change-Id: I5b8a0e5bd2218ecdf417de357c9a7d9307c91932

Conflicts:
	adb/usb_vendors.c
2013-06-18 11:28:08 -07:00
Colin Cross
95a41f6b20 Merge changes Ia7b337e1,I7a2d8aa5,Iacc2b42b,Idf6100d1,If3fba2cc
* changes:
  init: fix copying boot properties
  toolbox: hide property implementation from watchprops
  init: verify size of property buffers passed to property_get
  init: move the system property writer implementation
  init: switch property_get to use __system_property_get
2013-06-18 01:11:59 +00:00
Colin Cross
5e484e9c43 init: fix copying boot properties
The previous patch "init: verify size of property buffers passed
to property_get" incorrectly modified one of the callers,
resulting in ro.serialno, ro.bootmode, ro.baseband, and
ro.bootloader always being set to their default values.

Bug: 9469860

(cherry picked from commit 67e3663fc9)

Change-Id: Ia7b337e1fab6e334729f47ee1269e6c736615177
2013-06-17 16:58:14 -07:00
Colin Cross
8196316411 toolbox: hide property implementation from watchprops
(cherry picked from commit 91779634de)

Change-Id: I7a2d8aa507ac61cedc5f67c563531a7d4ec8e4c2
2013-06-17 16:58:09 -07:00
Colin Cross
a5a860ef20 init: verify size of property buffers passed to property_get
Verify that the buffer passed as the value parameter to property_get
is always big enough.

(cherry picked from commit 88ac54a4e8)

Change-Id: Iacc2b42bfe4069e0bfcbb1c48474f30126a93139
2013-06-17 16:58:02 -07:00
Colin Cross
993b6ceeb0 init: move the system property writer implementation
Move the system property writer implementation into bionic to keep
it next to the reader implementation and allow for better testing.

(cherry picked from commit 9f5af63501)

Change-Id: Idf6100d1d0170751acd5163a22597912bff480f0
2013-06-17 16:57:49 -07:00
Colin Cross
1a6f4c3bf2 init: switch property_get to use __system_property_get
(cherry picked from commit 2deedfe0b1)

Change-Id: If3fba2cc1dd5c167b0924ddfe42dbe2e6387208a
2013-06-17 16:57:32 -07:00
Elliott Hughes
865bb05dd0 Merge "adb: fix reported transfer size for transfer over 4 GiB" 2013-06-17 20:49:25 +00:00
Elliott Hughes
5f8d9c012c Merge "adb: add vendor ID's for Nook, Haier, Hisense, and MTK" 2013-06-17 20:47:18 +00:00
Jeff Smith
71150ce4ef adb: add vendor ID's for Nook, Haier, Hisense, and MTK
Change-Id: I156ff750ef9ae66113d1e0e3ceffea047abc03b9
Signed-off-by: Jeff Smith <whydoubt@gmail.com>
2013-06-17 13:21:04 -05:00
Jeff Smith
d9a1430ff2 adb: fix reported transfer size for transfer over 4 GiB
When transferring files over 4 GiB with adb, the size of the transfer
is misreported.

Change-Id: Ia3d4cae1e9f82b4f7432341820b101ea9a44f85b
Signed-off-by: Jeff Smith <whydoubt@gmail.com>
2013-06-15 16:03:54 -05:00
Colin Cross
c620f095fe Merge "init: prevent action being added to the action_queue twice" 2013-06-14 00:44:18 +00:00
Elliott Hughes
6ef0dfecca Merge "Add a new test to crasher to upset dlmalloc." 2013-06-12 21:21:38 +00:00
Elliott Hughes
6f40cafd9f Add a new test to crasher to upset dlmalloc.
We should also add a test for heap corruption, but I failed to come up
with a kind of corruption that dlmalloc actually detects (rather than
just crashing accidentally).

Change-Id: I7457e732729635b171ffc44517c3de71f55608e6
2013-06-12 14:04:34 -07:00
Colin Cross
c0df50afdb Merge "fix bad return value in dhcp_do_request_*" 2013-06-10 21:57:21 +00:00
Colin Cross
e9ab162f30 init: prevent action being added to the action_queue twice
Property triggers may cause an action to be queued twice, resulting
in a loop in the action queue.  Keep actions that are not on the queue
in the list_empty state (act->qlist->next == act->qlist), and only
add them to the list if they are in that state.

Bug: 8335133
Change-Id: I3a3ec18176cf19cbaa3a45220a03c7560eacfe79
2013-06-10 14:16:00 -07:00
Michael Wu
897df50f4c fix bad return value in dhcp_do_request_*
1. bad return status make it return uninitialized prefixLength with a magic
number in android_net_utils_runDhcpCommon()
2. it will make DhcpInfoInternal.makeLinkAddress() to throw
IllegalArgumentException when try to connect a Wifi AP
3. the exception will make system reboot, of cource it random.

Change-Id: Iabc0cd5b69c1316f4eeae0aa1b8a91444dca4562
Signed-off-by: Michael Wu <michaelstay@gmail.com>
2013-06-05 08:42:22 +08:00
Brian Carlstrom
59fa7e107d Merge "Fixed reversed output in netstat Recv-Q Send-Q columns" 2013-06-04 17:26:25 +00:00
Brian Carlstrom
3c412f6260 Fixed reversed output in netstat Recv-Q Send-Q columns
Change-Id: I2bc7ac6c886808910212432497f05e34596f5e85
2013-06-03 19:24:44 -07:00
Colin Cross
51a2e4d5d4 Merge "libsysutils: fix null pointer and memory leak issue" 2013-05-21 21:13:51 +00:00
Colin Cross
9246f8d6de Merge "init.rc: remove duplicated led-related nodes" 2013-05-20 21:06:59 +00:00
Hong-Mei Li
544a7f7a36 libsysutils: fix null pointer and memory leak issue
In SocketClient::quoteArg function
1. Fix potential null pointer accessing issue
2. Fix potential memory leak introduced by realloc fail

Change-Id: I1ca0f9089290d43452e9a71428244545f4ed866b
Signed-off-by: Hong-Mei Li <a21834@motorola.com>
2013-05-20 17:30:11 +08:00
Sungmin Choi
a8d392da91 init.rc: remove duplicated led-related nodes
Change-Id: Ibee7ef9137594fc4c30d3ab6ee7bdf3515836c62
2013-05-19 21:56:36 -07:00
Ron Munitz
b1b45b9bd4 Added net.dns1 prop for emulator, as Android emulator ignores it by default.
This commit sets up the system property which is actually used by the
Connectivity Service
(frameworks/base/services/java/com/android/server/ConnectivityService.java).
It fixes an (obsolete?) convention where the dns was affected directly by
the interface (i.e. "net.eth0.dns1=10.0.2.3"), which causes the Android
Emulator (goldfish) to ignore this value, and effectively have no DNS
resolving at all.

An immediate fix can be either add reference to net.eth%s.dns%s in the
ConnectivityService and possibly on the dhcp code as well which would be
bloated, or just stick to the apparant new convention.

I chose the latter as a one line fix which gets the job done.

Change-Id: Id4364129e9a82c1f48403068a837aca54de07944
2013-05-17 17:58:02 +00:00
Brian Carlstrom
de1dadb739 Merge "Disable darwin build" 2013-05-15 16:33:45 +00:00
Brian Carlstrom
b0df2f1525 Disable darwin build
Change-Id: Ie72bbaab8604cdc14082859b735458a2f73c3074
2013-05-15 09:13:04 -07:00
Brian Carlstrom
07db297045 Merge changes I5578fe06,I197b06c4
* changes:
  Add flush_my_map_info_list() and fix a bug in the Mac load_map_info_list().
  Add basic Darwin support to libcorkscrew.
2013-05-15 04:30:58 +00:00
Elliott Hughes
89054056a7 Add flush_my_map_info_list() and fix a bug in the Mac load_map_info_list().
(If you fclose(3) rather than pclose(3) a FILE* you got from popen(3),
future popen(3)s fail obscurely, at least on Mac OS.)

(cherry picked from commit 2bf76e143da933184d1392fb9bea3a3896c37e76)

Change-Id: I5578fe06753061b0dbc5ee951ebf31eb2bab0389
2013-05-14 19:49:30 -07:00
Elliott Hughes
bfec3a3150 Add basic Darwin support to libcorkscrew.
This might not seem like much, but it's already better than Mac OS'
backtrace(3).

(cherry picked from commit 2a46f6293f19b9d6100187fbd53088088e671b88)

Change-Id: I197b06c4c19f728ad6f194b2f473bd9dcd99b8a6
2013-05-14 19:49:22 -07:00
Ying Wang
7382459eca Merge "Host builds: add fastboot and adb" 2013-05-02 16:52:45 +00:00
Kenny Root
928116ceef Host builds: add fastboot and adb
Add fastboot and adb host utilities to debug builds for debugging
and development purposes.

Change-Id: If77699a27497b8641998930f14d4ee418b856080
2013-05-02 09:51:53 -07:00
Colin Cross
8794b2eeb2 Merge "Fix perms on /data/security" 2013-05-01 03:49:47 +00:00
Colin Cross
f69cc564f4 Merge "Update ueventd set the SELinux context on sysfs" 2013-05-01 03:48:41 +00:00
Colin Cross
032be7a4c5 Merge "Log an error if property pool is exhausted" 2013-05-01 03:47:19 +00:00
Kenny Root
a69af5af3d Merge "Track change to JSSE provider" 2013-04-30 04:01:39 +00:00