diff --git a/services/java/com/android/server/MountService.java b/services/java/com/android/server/MountService.java index ca813fe96fe9f..a100f1f34dd8f 100644 --- a/services/java/com/android/server/MountService.java +++ b/services/java/com/android/server/MountService.java @@ -487,6 +487,13 @@ class MountService extends IMountService.Stub implements INativeDaemonConnectorC } } + /* notify external storage has mounted to trigger media scanner */ + if (mEmulateExternalStorage) { + notifyVolumeStateChange(null, + Environment.getExternalStorageDirectory().getPath(), + VolumeState.NoMedia, VolumeState.Mounted); + } + /* * If UMS was connected on boot, send the connected event * now that we're up.