Closed Bug 818131 Opened 8 years ago Closed 8 years ago

Volume Manager should create fake volumes

Categories

(Firefox OS Graveyard :: General, defect, P1)

x86_64
Linux
defect

Tracking

(blocking-basecamp:+, firefox18 fixed, firefox19 fixed, firefox20 fixed)

RESOLVED FIXED
B2G C2 (20nov-10dec)
blocking-basecamp +
Tracking Status
firefox18 --- fixed
firefox19 --- fixed
firefox20 --- fixed

People

(Reporter: dhylands, Assigned: dhylands)

References

Details

Attachments

(1 file, 1 obsolete file)

For devices which have no sdcard partition (like the Nexus S), apps like gallery don't work properly.

Since there is no sdcard partition, there is no sdcard volume, but /sdcard still exists (this implies that UMS won't work - but that's what MTP is for).

So I think that DeviceStorage GetSDCardStatus function should just assume that the sdcard is "available" if there is no sdcard volume.
I actually have a workaround for this.

I'm planning on making nsIVolumeService.getVolumeByPath create a dummy volume if the path exists. This will allow DeviceStorage to query its size.

This particular solution will also be needed for work I'm doing with updates as well (bug 785124)

Noming since this blocks a blocker.
Blocks: 785124
blocking-basecamp: --- → ?
QA Contact: dhylands
Assignee: nobody → dhylands
QA Contact: dhylands
Patches vold to check if sdcard volume is mounted using FUSE file system. If mounted, volume-list is updated and upper layer can see the volume in response to "list volume" command.
Attachment #688673 - Flags: review?
Attachment #688673 - Flags: feedback?
blocking-basecamp: ? → +
I've changed the description since the problem isn't in device storage.
Summary: DeviceStorage doesn't work when there is no sdcard volume → Volume Manager should create fake volumes
Comment on attachment 688673 [details] [diff] [review]
Fix for sdcard detection on Pandaboard to solve the error from music, gallery and video apps

Review of attachment 688673 [details] [diff] [review]:
-----------------------------------------------------------------

I've minused this for a few reasons:
1 - It changes vold, which is not something we control (i.e. if you want to change vold you need to get this into the upstream trees)
2 - Even if we could change vold, this doesn't address the problem properly. The FUSE mounted volumes still can't be shared via UMS, and the AutoMounter will try to UMS share the volumes reported by vold.
3 - I'll post my patch for this later today which should address the problem in a more suitable manner (and which will allow DeviceStorage and the Updater to work better as well)
Attachment #688673 - Flags: review?
Attachment #688673 - Flags: review-
Attachment #688673 - Flags: feedback?
Attachment #688673 - Flags: feedback-
This causes the GetVolumeByPath function to return a "fake" volume.

For volumes which don't exist in vold (like sdcard which is not a partition, or /data/local) this will allow VolumeService users like DeviceStorage and Updater to query the amount of space available/used on the partitions used to store the path in question.

This is, in fact, the only useful operation that can be performed with volumes anyway.

This, in turn, should allow the media based apps (Gallery, Music, Camera) to work again.
Attachment #688884 - Flags: review?(doug.turner)
Attachment #688673 - Attachment is obsolete: true
Can we get a priority and target milestone for this>
Attachment #688884 - Flags: review?(doug.turner) → review+
done.
Priority: -- → P1
Target Milestone: --- → B2G C2 (20nov-10dec)
Let's get this checked in ASAP, please.  Sorry to press, but need to be acting as quickly as possible as we are in the endgame to reach 1/15. :)
Thanks, Dave.  :)
https://hg.mozilla.org/mozilla-central/rev/1a6a1c0d8a67
Status: NEW → RESOLVED
Closed: 8 years ago
Resolution: --- → FIXED
Blocks: 821357
You need to log in before you can comment on or make changes to this bug.