Commit graph

2254 commits

Author SHA1 Message Date
Sudheer Shanka
112c9cc2f8 Merge "Check isolated_storage is enabled before cleaning up sandboxes." 2018-10-09 19:07:40 +00:00
Sudheer Shanka
9acc6d4398 Check isolated_storage is enabled before cleaning up sandboxes.
Also, clear packages state stored for the user being stopped.

Bug: 117329171
Bug: 111890351
Test: manual
Change-Id: Ida48fcec851830dbb756e329c20c322c631ad264
2018-10-06 19:03:02 -07:00
Daniel Rosenberg
c5aca90465 Merge "Add checkpointing support for A/B updates" am: ba1752008d am: 0b875d7630
am: 9e9f7cb820

Change-Id: I76999218377271621d14502f9315739dd1b894a5
2018-10-04 19:14:50 -07:00
Daniel Rosenberg
9e9f7cb820 Merge "Add checkpointing support for A/B updates" am: ba1752008d
am: 0b875d7630

Change-Id: I04e3fedecf97c0dc4e2cf7b6b3f099ce6a81d633
2018-10-04 18:57:12 -07:00
Daniel Rosenberg
0b875d7630 Merge "Add checkpointing support for A/B updates"
am: ba1752008d

Change-Id: I62cb1c6dce6c9eca1c3651b05d23cb893559d370
2018-10-04 18:48:04 -07:00
Daniel Rosenberg
ba1752008d Merge "Add checkpointing support for A/B updates" 2018-10-05 01:31:18 +00:00
Paul Lawrence
cba5a411d1 Merge "Use unique points for fstab" am: 1e1893812c am: 1c6d73bfcc
am: 704da32b50

Change-Id: I13c215dc504a3745402327aaead9d7f6d36bc695
2018-10-03 18:07:22 -07:00
Paul Lawrence
704da32b50 Merge "Use unique points for fstab" am: 1e1893812c
am: 1c6d73bfcc

Change-Id: I17f2815216ebea678c4844818ec6f3007b557fe2
2018-10-03 17:52:04 -07:00
Paul Lawrence
1c6d73bfcc Merge "Use unique points for fstab"
am: 1e1893812c

Change-Id: I64ce90c05417b8b96ddc1e96cd505ca2aff86082
2018-10-03 17:28:34 -07:00
Treehugger Robot
1e1893812c Merge "Use unique points for fstab" 2018-10-03 23:57:39 +00:00
Daniel Rosenberg
d399249855 Add checkpointing support for A/B updates
This adds implicit rollback support during A/B style updates.
If you explicitly start a checkpoint with -1, needsRollback will
trigger if the update fails, and should be used if any additional
cleanup is needed that is not covered by A/B itself.

Test: All Checkpoint tests pass
Bug: 111020314
Change-Id: I88b4a1098c6bac4dc1438a54c8a8f59577a6c17b
2018-10-03 15:39:25 -07:00
Paul Lawrence
2040089ab0 Use unique points for fstab
Test: Checkpoint test script runs and passes
Change-Id: I13005da22aef5fda3d1e0941949db02ff0ff0870
2018-10-03 14:19:31 -07:00
Paul Lawrence
6f0bed1bbe Merge "Make checkpointing work on ext4" am: ac244261c8 am: 61c3eaf068
am: f6c099af3a

Change-Id: Ic3703ad2d1d8c1b5b63be338d6725b582374dba6
2018-10-03 14:01:37 -07:00
Paul Lawrence
f6c099af3a Merge "Make checkpointing work on ext4" am: ac244261c8
am: 61c3eaf068

Change-Id: I22a1b7c3c35aa164b00d4e4d176bcdf63df53353
2018-10-03 13:46:27 -07:00
Paul Lawrence
61c3eaf068 Merge "Make checkpointing work on ext4"
am: ac244261c8

Change-Id: I78da54f117c9c2710d2d1fbe4ec7e902bf944d5d
2018-10-03 13:31:25 -07:00
Treehugger Robot
ac244261c8 Merge "Make checkpointing work on ext4" 2018-10-03 20:15:48 +00:00
Paul Lawrence
1abb2fe278 Make checkpointing work on ext4
Test: All tests pass
Change-Id: I2a6cdf1edfe752f4633e1931e75d18659653938c
2018-10-03 09:15:27 -07:00
Mark Salyzyn
dc87830ff2 [automerger skipped] Merge "Protect /mnt/scratch from stale umount on userdebug" am: b39e6f2887 am: 74a6c69e57
am: 52ea568e2a  -s ours

Change-Id: I9bcbfb155a4f8953134ca3fbffab410ff5658bde
2018-10-02 17:37:55 -07:00
Mark Salyzyn
52ea568e2a Merge "Protect /mnt/scratch from stale umount on userdebug" am: b39e6f2887
am: 74a6c69e57

Change-Id: I016328c6059f63fb73c628b746ab12fdfe57d6a4
2018-10-02 16:32:40 -07:00
Mark Salyzyn
74a6c69e57 Merge "Protect /mnt/scratch from stale umount on userdebug"
am: b39e6f2887

Change-Id: I2505bc0cf4fe31123c47bd10619830298c3a033a
2018-10-02 15:24:57 -07:00
Treehugger Robot
b39e6f2887 Merge "Protect /mnt/scratch from stale umount on userdebug" 2018-10-02 21:31:12 +00:00
Mark Salyzyn
c4405e9c17 Protect /mnt/scratch from stale umount on userdebug
On userdebug protect /mnt/scratch. On user builds ensure that
/mnt/scratch is considered a stale mount so it can not be used.
vold runs before ro.debuggable is set, so this must be a compile
time decision.

Minor technical debt cleanup associated with using android::base.

Test: compile
Bug: 109821005
Change-Id: I8efdbedfe850dd24daecf03a37aea61de47edc7d
Merged-In: I8efdbedfe850dd24daecf03a37aea61de47edc7d
2018-10-02 18:00:49 +00:00
Mark Salyzyn
86e81e7183 Protect /mnt/scratch from stale umount on userdebug
On userdebug protect /mnt/scratch. On user builds ensure that
/mnt/scratch is considered a stale mount so it can not be used.
vold runs before ro.debuggable is set, so this must be a compile
time decision.

Minor technical debt cleanup associated with using android::base.

Test: compile
Bug: 109821005
Change-Id: I8efdbedfe850dd24daecf03a37aea61de47edc7d
2018-10-01 10:49:23 -07:00
Sudheer Shanka
1fa13825fc Merge "Remove unmount_tree in VolumeManager." am: 9931db7e59 am: 96707825f2
am: 65eac7fc1a

Change-Id: I40174a2504b376ebce6962f23ce1e06b7d2c1666
2018-09-28 20:13:09 -07:00
Sudheer Shanka
65eac7fc1a Merge "Remove unmount_tree in VolumeManager." am: 9931db7e59
am: 96707825f2

Change-Id: Ie4995f2ee69811f7b3053708ab0784fc33743218
2018-09-28 18:29:16 -07:00
Sudheer Shanka
96707825f2 Merge "Remove unmount_tree in VolumeManager."
am: 9931db7e59

Change-Id: Ib02f999eb66c5685752abf99c0c77ba49dd60d74
2018-09-28 17:33:19 -07:00
Sudheer Shanka
9931db7e59 Merge "Remove unmount_tree in VolumeManager." 2018-09-28 23:49:51 +00:00
Sudheer Shanka
99d304ac60 Remove unmount_tree in VolumeManager.
This is not needed anymore since everything else is updated
to use android::vold::UnmountTree.

Bug: 111890351
Test: manual
Change-Id: Idb574469763fa3438fbfc40d6da786d87ac63c38
2018-09-28 13:38:39 -07:00
Sudheer Shanka
40ab6742a7 Bind mount pkg specific dirs in the zygote child namespaces.
- Also update vold to create sandboxes for secondary storage devices.
- Since bind mounts are created in the process specific namespaces, we
  don't need /mnt/storage anymore which we were using it to prevent
  some bind mounts from propagating onto /mnt/runtime/write.
- Create bind mounts for {media,obb} dirs similar to data dir in
  per process namespace.
- Also fix a bug where we are not passing correct packages to vold when
  a new user starts.

Bug: 111890351
Test: manual
Change-Id: I7849efc4fbf3c654606fa30de7ab2de0236d766f
2018-09-27 15:50:26 -07:00
Sudheer Shanka
144e7cc25a Merge "Add unmountTree to utils." am: a64572431e am: f5b24f1015
am: e9c88c4c6c

Change-Id: Iae8f7c972272807f87b2ce9c4ba536cf6458d3cb
2018-09-27 13:35:28 -07:00
Sudheer Shanka
e9c88c4c6c Merge "Add unmountTree to utils." am: a64572431e
am: f5b24f1015

Change-Id: I4e0a8b784b541013cf1028fbe1ed54dfd31d2782
2018-09-27 13:21:59 -07:00
Sudheer Shanka
f5b24f1015 Merge "Add unmountTree to utils."
am: a64572431e

Change-Id: Ifdbdc90e22b4a681dcf0766919807109cf78ffca
2018-09-27 13:14:30 -07:00
Sudheer Shanka
a64572431e Merge "Add unmountTree to utils." 2018-09-27 19:54:23 +00:00
Sudheer Shanka
89ddf99119 Add unmountTree to utils.
Bug: 111890351
Test: builds without any errors
Change-Id: I62a94c9e8d101756b686b402774f08a1d71cf875
2018-09-27 10:29:02 -07:00
Daniel Rosenberg
2acacdb667 [automerger skipped] Merge "Add support for checkpointing" am: a3381ffc3f am: 7e84915c17
am: 51ff91abda  -s ours

Change-Id: Ice08fc079b1cb8101ba375f65ad1afe81ca81a61
2018-09-25 16:05:26 -07:00
Daniel Rosenberg
51ff91abda Merge "Add support for checkpointing" am: a3381ffc3f
am: 7e84915c17

Change-Id: I25333406617a7fcf2109aaa0448e6cc216bf5670
2018-09-25 15:18:26 -07:00
Daniel Rosenberg
7e84915c17 Merge "Add support for checkpointing"
am: a3381ffc3f

Change-Id: I52e70b0f886281280bb050751060b975e103376d
2018-09-25 15:10:22 -07:00
Treehugger Robot
a3381ffc3f Merge "Add support for checkpointing" 2018-09-25 21:52:19 +00:00
TreeHugger Robot
e958124ae2 Merge "Add support for checkpointing" 2018-09-24 20:02:01 +00:00
Oleksiy Avramchenko
39f8497c52 Merge changes from topic "exfat-update" am: a2a227e382 am: 1fe4696cdd
am: b5b7a6f8c6

Change-Id: Iebcf9249acf4607ff6e24cc68d739e533024b267
2018-09-24 12:24:17 -07:00
Oleksiy Avramchenko
b5b7a6f8c6 Merge changes from topic "exfat-update" am: a2a227e382
am: 1fe4696cdd

Change-Id: I9cb8a26f769309ad16cf780c9a40d64af175a2c9
2018-09-24 12:07:36 -07:00
Oleksiy Avramchenko
1fe4696cdd Merge changes from topic "exfat-update"
am: a2a227e382

Change-Id: I13daa826be04c72ab18175d3ceee6212b7304731
2018-09-24 12:01:36 -07:00
Treehugger Robot
a2a227e382 Merge changes from topic "exfat-update"
* changes:
  Use exFAT for SDXC cards
  Add GetBlockDevSize, GetBlockDevSectors helpers
2018-09-24 18:52:56 +00:00
Jeff Sharkey
dac54dce51 Merge "Update vold to log only debug or higher level messages." am: 9bd07d8760 am: 92c182e4c7
am: 3c5f603158

Change-Id: I2209a3208a26ae649b4d5dc1aa18d30b6a61afcb
2018-09-24 10:34:26 -07:00
Jeff Sharkey
3c5f603158 Merge "Update vold to log only debug or higher level messages." am: 9bd07d8760
am: 92c182e4c7

Change-Id: I62e7a0c1b2a3cc365e1a693599c15e47e2dffacf
2018-09-24 10:29:23 -07:00
Jeff Sharkey
92c182e4c7 Merge "Update vold to log only debug or higher level messages."
am: 9bd07d8760

Change-Id: Idd8482fc0287d51d962ead0dd4c1f8f8e514d9de
2018-09-24 10:25:07 -07:00
Jeff Sharkey
9bd07d8760 Merge "Update vold to log only debug or higher level messages." 2018-09-24 17:06:25 +00:00
Oleksiy Avramchenko
4cff06d45f Use exFAT for SDXC cards
When both VFAT and exFAT are supported VFAT will only be used to
format card. Use exFAT for cards larger than 32GB per SDXC standard.

Test: build, manual, mount exFAT volume
Bug: 80202067
Change-Id: If504f9685256a669c5801a69d69d5a214ad27455
2018-09-24 14:28:24 +02:00
Oleksiy Avramchenko
625dc787c6 Add GetBlockDevSize, GetBlockDevSectors helpers
Helpers to get a block device size in bytes or 512 byte sectors,
using BLKGETSIZE64 and returning value of uint64_t type.

This also removes get_blkdev_size().

Test: build, manual, mount exFAT volume
Bug: 80202067
Change-Id: Ib07e8ac6ef7ff49de0ed570d1fa202e8b558b80c
2018-09-24 14:25:24 +02:00
Daniel Rosenberg
65f99c9e8b Add support for checkpointing
Checkpointing uses a combination of files on the meta partition
and the checkpoint= fs_mgr flag. Checkpointed partitions will
revert to their starting state on reboot unless checkpoint commit
is called.

Test: Run vdc commands, check file on metadata
Merged-In: Icba16578608a6cbf922472e9d4ae5b8cf5f016c6
Change-Id: Icba16578608a6cbf922472e9d4ae5b8cf5f016c6
2018-09-21 21:54:11 +00:00