Commit graph

2008 commits

Author SHA1 Message Date
David 'Digit' Turner
eeeca4dd45 rootdir: goldfish: Fix network route during emulation.
The net.eth0.gw system property is used by the ConnectivityService
to set the default route when it detects that 3G connectivity is
established. Because the property was undefined, the route was
unset which broke networking.

+ Format / document init.goldfish.sh

Change-Id: I1133cf6c093609300315cd0ea363c9e139b42521
2011-01-18 23:38:00 +01:00
David 'Digit' Turner
a42f152b4a Merge "rootdir: Fix system emulation startup." into honeycomb 2011-01-18 11:08:04 -08:00
Mike Lockwood
96e32dfe6c Merge "sdcard: Fix lower case squashing for case insensitivity support." into honeycomb 2011-01-18 09:42:12 -08:00
Mike Lockwood
b94d320b1e sdcard: Fix lower case squashing for case insensitivity support.
The fuse layer in the kernel does not support case insensitive file systems.
But the sdcard daemon's fuse_lookup was returning the same file object for
different file names, which caused problems in the kernel fuse layer's dcache,
resulting in EBUSY errors if the same directory was opened twice under different
names differing only by case.

To fix this, the sdcard daemon will return different file objects for files or directories
that differ only by case. Now the squashing occurs only in the interaction between
the sdcard daemon and the underlying file system in /data/media, and sdcard maintains
the illusion for the kernel fuse layer that there are two separate files.

Example:  Suppose both /mnt/sdcard/foo.txt and /mnt/sdcard/FOO.TXT are opened.
Previously, the sdcard would squash this to a single node, and return the same
node to the kernel fuse implementation twice, and would open the underlying file
/data/media/foo.txt only once.   Now sdcard will create two separate nodes will open
/data/media/foo.txt twice, once for mnt/sdcard/foo.txt and again for /mnt/sdcard/FOO.TXT.

Change-Id: I70e36b7822142750d3eeeb75edd6464ec7c79f2a
Signed-off-by: Mike Lockwood <lockwood@android.com>
2011-01-17 21:06:26 -08:00
Ken Sumrall
e434915787 Add a new trigger to support a progress bar UI for encrypt in place.
Change-Id: I6a14eb43462505cb7fecfee9fd1ecdea50065963
2011-01-17 14:26:34 -08:00
David 'Digit' Turner
95df887ac0 rootdir: Fix system emulation startup.
This fixes the goldfish-specific config scripts used by init and ueventd
to properly setup the system under emulation. This fixes a lot of broken-ess
introduced by recent permission changes in the system.

Note that there are still several problems after this patch is applied, but
at least it becomes possible to get an adb connection to the emulated system,

Change-Id: Iff47bbf0fe5cb759fa93089284bb0f71e32405a2
2011-01-15 03:15:47 +01:00
Ken Sumrall
4e84d3bcf9 Set a read-only property to indicate if the device is running encrypted.
The UI needs to know if the device is running with an encrypted
filesystem or now.  So set a read-only property at boot to let it know.

Change-Id: I753de2d606c975bcbe9946d10fd47558cf357dac
2011-01-14 12:44:09 -08:00
Ken Sumrall
63990cf56f Merge "Move rild to the core class." into honeycomb 2011-01-13 13:42:17 -08:00
Ken Sumrall
a02714bd3e Move rild to the core class.
Changes in init.stingray.rc now prevent rild from making sockets
or named pipes on /data.  Now that rild no longer prevents /data
from being unmounted, we can put it in the core class, which doesn't
restart when we enable encryption.  This speeds up the boot by 20+
seconds.

Change-Id: I737baf804e089f4ddbd664eaa1e675a7bd62e699
2011-01-13 13:41:06 -08:00
Mike Lockwood
1bedb73f9f sdcard: Have the -f option fix user/group permissions as well as file name case
Change-Id: I280ded6ce79fb11752c89ebafa663d7ee29edebc
Signed-off-by: Mike Lockwood <lockwood@android.com>
2011-01-13 13:38:42 -05:00
Mike Lockwood
4f35e623a2 sdcard: Add command line options for lowercase file name squashing:
-l   squash all file names to lower case when creating new files
-f   rename existing files to make them lower case

Change-Id: I3245deb690228cf577bdc9bd4b0fcf0306ea3e16
Signed-off-by: Mike Lockwood <lockwood@android.com>
2011-01-12 17:29:02 -05:00
Mike Lockwood
51b3a2d77a sdcard: Force file names to lower case in order to provide case insensitivity
Change-Id: I2cdb12c7e296e1c28b66e32c7037dce060eecd67
Signed-off-by: Mike Lockwood <lockwood@android.com>
2011-01-12 12:55:05 -05:00
Kenny Root
98af303d44 Merge "Use pread64/pwrite64 instead of pread/pwrite" into honeycomb 2011-01-11 20:34:47 -08:00
Kenny Root
90749774ed Use pread64/pwrite64 instead of pread/pwrite
>2GB files were failing strangely when pread was used instead of
pread64. Also writing to files should use pwrite64 in case they grow
over 2GB.

Bug: 3205336
Change-Id: I0c9619de35680093d7777ca132ce488eae502216
2011-01-11 16:05:10 -08:00
Gloria Wang
a44aca6580 Temporarily disable the drm service. do not merge
Change-Id: I5cb04a9c2cc5b95443c6c0ea77132a4102ca47fc
2011-01-10 17:33:25 -08:00
Jean-Baptiste Queru
d66aa91623 Merge changes Ife2dd406,I1ac481a2 into honeycomb
* changes:
  Assembly coded android_memset16 and android_memset32
  init: Fix parser line numbering
2011-01-10 09:40:14 -08:00
Mike Lockwood
af7bdc6460 Add separate permission and group for access to MTP USB driver
Since the "usb" group and ACCESS_USB permission will be used by regular apps
to access USB devices in host mode, we need a separate permission for the
device side MTP driver.

Change-Id: Ibb546b8726d61e041fc7c273f71929624ad1575b
Signed-off-by: Mike Lockwood <lockwood@android.com>
2011-01-10 08:22:30 -05:00
Mike Lockwood
b596608f09 adb: Increase device descriptor buffer size in Linux host USB support
256 bytes wasn't big enough for some complicated USB configurations

Change-Id: I31f7841953d73b06958f44040f58166b159faff4
Signed-off-by: Mike Lockwood <lockwood@android.com>
2011-01-07 23:18:14 -05:00
Lu, Hongjiu
bb12ac9b85 Assembly coded android_memset16 and android_memset32
Change-Id: Ife2dd406e1dcb962e5e97788c515ac96f5c52e44
2011-01-07 11:26:34 -08:00
Bruce Beare
1be6968d9d init: Fix parser line numbering
Change-Id: I1ac481a2cef749b26c73bc9e6a212e6ace7a0ae2
2011-01-07 11:19:04 -08:00
Mike Lockwood
be1def8d43 libusbhost: Tweak comments.
Change-Id: I45fdba7a94438f7c15fbca5dd65f07df9b522fb3
Signed-off-by: Mike Lockwood <lockwood@android.com>
2011-01-07 11:31:58 -05:00
Mike Lockwood
e533c5f100 libusbhost: Support for multiple pending requests on a single endpoint
Add new usb_request struct to replace usb_endpoint, which is no longer needed.

Change-Id: Ia3637b3431a3597caced41bfec677ef0b044a453
Signed-off-by: Mike Lockwood <lockwood@android.com>
2011-01-06 09:21:13 -05:00
Colin Cross
90d07ae2b1 Merge "uptime: Use clock_gettime to get monotonic time" 2011-01-05 17:16:59 -08:00
Colin Cross
9d6d030f83 uptime: Use clock_gettime to get monotonic time
The first field in /proc/uptime is bootbased time, not monotonic
time.  If the kernel tracks bootbased time correctly, it counts
elapsed run time as well as sleep time, which is the same as the
elapsed time in the android alarm driver, and sleep time is
always returned as 0.

Use clock_gettime(CLOCK_MONOTONIC) instead, which will return
elapsed run time not counting sleep time on all platforms.

Change-Id: I28a22e8c93d78f62666ee8c877c7c6718a2b640a
2011-01-05 15:22:09 -08:00
Paul Eastham
6b8caf0bb0 Merge "Fix refcounting in the rename case." 2011-01-05 00:04:00 -08:00
Paul Eastham
77085c570e Fix refcounting in the rename case.
Change-Id: I59dbac8c92bda450e6d89f7f180241fd4b5bbae6
2011-01-04 21:06:03 -08:00
Colin Cross
8bc6fb3433 am bf10797e: am f7ca6040: Fix infinite loop in init when debugging is turned off
* commit 'bf10797e538f9fa252d72710bd5ecf0ef1f6f3e0':
  Fix infinite loop in init when debugging is turned off
2011-01-04 18:50:51 -08:00
Colin Cross
bf10797e53 am f7ca6040: Fix infinite loop in init when debugging is turned off
* commit 'f7ca6040616f672a6f0039d55e39c610b7c1cf91':
  Fix infinite loop in init when debugging is turned off
2011-01-04 18:49:07 -08:00
Colin Cross
f7ca604061 Fix infinite loop in init when debugging is turned off
If a keychord is pressed when debugging is turned off, the main
event poll in init will return an event on the keychord fd,
but handle_keychord never reads the data.  Once this happens,
the poll will always return immediately, and init enters an
infinite loop.  Fix it by always reading from the keychord fd,
but only handling the returned keychord if debugging is
enabled.

Change-Id: Ie4efa98247d3cc978d275dc8a4516b32aa710278
2011-01-04 18:21:22 -08:00
Jean-Baptiste Queru
512405a421 am f1c2a735: Merge "fastboot: Add help message for continue command"
* commit 'f1c2a7352f19cf729f91bf2559fc93ef12c74dca':
  fastboot: Add help message for continue command
2010-12-29 16:01:55 -08:00
Jean-Baptiste Queru
f1c2a7352f Merge "fastboot: Add help message for continue command" 2010-12-29 13:12:10 -08:00
Bruce Beare
24ce4bc8d7 fastboot: Add help message for continue command
Change-Id: I578b1b7c2d74d09d44ce9100bfe582aaa25c31b1
Signed-off-by: Bruce Beare <bruce.j.beare@intel.com>
2010-12-29 13:11:53 -08:00
Mike Lockwood
7d700f8bdc libusbhost: Add usb_device_get_name_from_unique_id()
This allows converting from unique IDs to USB device names

Change-Id: I8e3b300790c01383aed8e3d4f547b54bcb7c2cd4
Signed-off-by: Mike Lockwood <lockwood@android.com>
2010-12-29 09:27:16 -05:00
Mike Lockwood
123538954b Change libusbhost from static to shared library
Change-Id: I0c16cc4536c4ab700c33433c8a6323ade7cfc95d
Signed-off-by: Mike Lockwood <lockwood@android.com>
2010-12-29 08:33:24 -05:00
Irfan Sheriff
bdd483830d Merge "Reduce polling interval to 200ms" 2010-12-21 11:44:41 -08:00
Irfan Sheriff
b1723b6892 Reduce polling interval to 200ms
DHCP success can take up to 2 seconds to
be reported to the statemachine. Move wait
time after check and reduce it to 200ms

Change-Id: I6b2546f80435a84ee6f44f4d91f348bacfdc8433
2010-12-21 11:15:28 -08:00
Ken Sumrall
752923c168 Changes to init to support encrypted filesystems.
These are the changes to init and init.rc necessary to
support booting with and encrypted /data filesystem.
A corresponding change to init.<device>.rc goes along
with this change.

Change-Id: I0c7e2cc39568358014a82e317735c0eae14dd683
2010-12-18 19:03:54 -08:00
Stan Chesnutt
36f93f0120 fix undefined behavior with certain left-shift count values
Change-Id: I1b71de28312a56a3b1d27fcfaf0a7b71d5777e6c
2010-12-16 10:59:48 -08:00
Mike Lockwood
e88a1b9e3d Merge "libusbhost: Fix breakage due to not storing dev_name in struct usb_device" 2010-12-15 12:59:08 -08:00
Mike Lockwood
93aff72d9b libusbhost: Fix breakage due to not storing dev_name in struct usb_device
Change-Id: Iefac9b31f900edb2dbd594f9eff9113b2038757d
Signed-off-by: Mike Lockwood <lockwood@android.com>
2010-12-15 12:58:04 -08:00
Nick Kralevich
333f24bfbd don't run services with gid=0
Ensure that we drop privileges for servicemanager
and drmioserver.  These should not be running with
gid=0.

Bug: 3275526
Testing: Applied change and successfully rebooted
the device.  No obvious bugs.

Change-Id: I782fbda812cb88e0a365788b45b3b32894623177
2010-12-15 11:09:21 -08:00
Mike Lockwood
ee878753f9 adb: Don't report negative number of bytes after pushing file > 2 gigabytes
BUG: 3198322

Change-Id: I6067857b9490984a21b597f6ee338446a9decaf5
Signed-off-by: Mike Lockwood <lockwood@android.com>
2010-12-14 23:08:43 -08:00
Paul Eastham
3227b5c25f Prevent rollover when dumping data around PC, SP, etc.
Change-Id: Ifc5f0e8eb5fed191c39f0878869e04b4d4f3b9ca
2010-12-14 16:07:58 -08:00
Jean-Baptiste Queru
4387ed1356 am 660c8b71: am cbb9257a: Merge "Fix debuggerd (native crash dump)."
* commit '660c8b71952c4067fd9d9ae1d6def3d2a3127ddc':
  Fix debuggerd (native crash dump).
2010-12-14 13:41:04 -08:00
Jean-Baptiste Queru
660c8b7195 am cbb9257a: Merge "Fix debuggerd (native crash dump)."
* commit 'cbb9257a872a0f35b0aa1018410ca6025e628c36':
  Fix debuggerd (native crash dump).
2010-12-14 13:32:45 -08:00
Jean-Baptiste Queru
cbb9257a87 Merge "Fix debuggerd (native crash dump)." 2010-12-14 13:21:11 -08:00
Mike Dodd
0b4836f2cd Fix debuggerd (native crash dump).
Change 44659e90f (6cc4923087 in AOSP) introduced walking
both the symbol table and dynamic symbol table. The problem
is that it was dereferencing values whether or not the two tables
were both present, which could wind up reading from invalid memory.
The read from a bad address would cause debuggerd itself to crash,
which isn't handled.

Change-Id: Ie936f660018b1980dee5b6ed669588db861f1a79
2010-12-14 13:15:47 -08:00
Mike Dodd
584b8e30bc Fix debuggerd (native crash dump).
Change 44659e90f (6cc4923087 in AOSP) introduced walking
both the symbol table and dynamic symbol table. The problem
is that it was dereferencing values whether or not the two tables
were both present, which could wind up reading from invalid memory.
The read from a bad address would cause debuggerd itself to crash,
which isn't handled.

Change-Id: Ie936f660018b1980dee5b6ed669588db861f1a79
2010-12-14 12:16:23 -08:00
Mike Lockwood
ec34ef5880 Merge "libusbhost: Add accessor for the USB device descriptor" 2010-12-13 19:09:28 -08:00
Mike Lockwood
11549b08a3 Merge "libusbhost: Add support for creating a usb_device struct from an existing fd" 2010-12-13 19:09:18 -08:00