| From d1d4caf3c5d8860f45688965664d8a985a645e57 Mon Sep 17 00:00:00 2001 |
| From: Pierre-Hugues Husson <phh@phh.me> |
| Date: Tue, 28 Nov 2017 18:28:04 +0100 |
| Subject: [PATCH 02/24] Relax requirement for visible flag to sdcards |
| |
| The vast majority of sdcard readers are stable enough to be declared by |
| the API. (I see no counter-example) |
| FBE broke adoptable storage with SDCard, hence this need. |
| |
| Change-Id: Ia616671c03562d1eadaff5531a5c708a62d7ad3a |
| --- |
| .../core/java/com/android/server/StorageManagerService.java | 3 ++- |
| 1 file changed, 2 insertions(+), 1 deletion(-) |
| |
| diff --git a/services/core/java/com/android/server/StorageManagerService.java b/services/core/java/com/android/server/StorageManagerService.java |
| index a35357f2864..14ca559c306 100644 |
| --- a/services/core/java/com/android/server/StorageManagerService.java |
| +++ b/services/core/java/com/android/server/StorageManagerService.java |
| @@ -1178,7 +1178,8 @@ class StorageManagerService extends IStorageManager.Stub |
| |
| // Adoptable public disks are visible to apps, since they meet |
| // public API requirement of being in a stable location. |
| - if (vol.disk.isAdoptable()) { |
| + // Assume all SDs match this as well |
| + if (vol.disk.isAdoptable() || vol.disk.isSd()) { |
| vol.mountFlags |= VolumeInfo.MOUNT_FLAG_VISIBLE; |
| } |
| |
| -- |
| 2.17.1 |
| |