Closed
Bug 994563
Opened 11 years ago
Closed 10 years ago
[tarako]support internal sdcard
Categories
(Firefox OS Graveyard :: Vendcom, defect)
Tracking
(blocking-b2g:1.3T+, b2g-v1.3T fixed)
People
(Reporter: james.zhang, Assigned: lianxiang.zhou)
Details
(Whiteboard: [POVB][sprd301827][sprd fixed wait for linux flashtool])
Attachments
(2 files, 1 obsolete file)
2.01 KB,
patch
|
Details | Diff | Splinter Review | |
2.05 KB,
patch
|
Details | Diff | Splinter Review |
support internal sdcard, then we can use camera when if no sdcard.
Reporter | ||
Updated•11 years ago
|
blocking-b2g: --- → 1.3T?
Flags: needinfo?(ttsai)
Flags: needinfo?(styang)
Flags: needinfo?(kli)
Comment 1•11 years ago
|
||
Hi Alan,
Sorry, I don't the related bugs indicate this, could you point out to James? Thanks.
Flags: needinfo?(styang) → needinfo?(ahuang)
Comment 2•11 years ago
|
||
Hi James,
Do you plan to use ext4/vFAT, or FUSE? If you wanna use FUSE, then it is an special case.
Once you've done with the ext4 of fat partition, you can reference bug 932018 to see how to add vold.fstab in tarako's ramdisk.
Flags: needinfo?(ahuang)
Comment 3•11 years ago
|
||
Hi Steven,
Just a heads up. Mozilla don't have action (I mean code modifications) here as I remember. This can be simply done by the modification in boot image.
Flags: needinfo?(styang)
Comment 4•11 years ago
|
||
Alan, is it also necessary to add an volume.cfg for it?
Flags: needinfo?(kli)
Comment 5•11 years ago
|
||
(In reply to Kai-Zhen Li from comment #4)
> Alan, is it also necessary to add an volume.cfg for it?
No, if there's no fake volume using FUSE :)
Based on comment 3, it sounds like a boot.img configuration and this is vendor related.
Component: GonkIntegration → Vendcom
Whiteboard: [POVB]
Comment 7•11 years ago
|
||
Hi James, how much storage are you planning to allocate to internal SD Card? thanks
Flags: needinfo?(james.zhang)
Reporter | ||
Comment 8•11 years ago
|
||
About 30~60MB, is this value OK?
(In reply to Alan Huang [:ahuang] from comment #2)
> Hi James,
> Do you plan to use ext4/vFAT, or FUSE? If you wanna use FUSE, then it is an
> special case.
> Once you've done with the ext4 of fat partition, you can reference bug
> 932018 to see how to add vold.fstab in tarako's ramdisk.
Lianxiang, please follow bug 932018 to configure internal sdcard.
Flags: needinfo?(james.zhang)
Comment 9•11 years ago
|
||
it might be too big isn't it? this will make userdata very small
Steven, can you please discuss with James
Reporter | ||
Comment 10•11 years ago
|
||
(In reply to Joe Cheng [:jcheng] from comment #9)
> it might be too big isn't it? this will make userdata very small
> Steven, can you please discuss with James
I'll check this value with our PM. I think 20~30MB is OK.
Lianxiang, please implement it on my side.
Assignee: nobody → lianxiang.zhou
Comment 11•11 years ago
|
||
Steven will follow up with James on this one
Assignee | ||
Comment 12•10 years ago
|
||
Our plan:
1 make a 20m partition from u-boot
2 mount partition to yaffs2
3 use sdcard service(use fuse)
4 need volumn.cfg?(Comment 5)
Assignee | ||
Comment 13•10 years ago
|
||
1 In u-boot/include/configs/sp6821a.h, add a "media" partition.
#define MTDPARTS_DEFAULT "mtdparts=sprd-nand:...,20m(media),..."
2 In init.rc, mount the partition
mkdir /media 0774 system system
mount yaffs2 mtd@media /media nosuid nodev
3 In init.sp8810.rc, add a service
service sdcard /system/bin/sdcard /media 1023 1023
class main
4 Add volume.cfg file and add to PRODUCT_COPY_FILES
$ cat sp6821a_gonk/volume.cfg
create internal-storage /media
5 All work well, but in settings, there is a bit of trouble. The "Internal Storage" and "Sd Card Storage" exchanged their position. The 20m internal storage display at the site of "Sd Card Storage".
6 What can I do to correct it?
Comment 14•10 years ago
|
||
(In reply to Zhou Lianxiang from comment #13)
> 1 In u-boot/include/configs/sp6821a.h, add a "media" partition.
> #define MTDPARTS_DEFAULT "mtdparts=sprd-nand:...,20m(media),..."
>
> 2 In init.rc, mount the partition
> mkdir /media 0774 system system
> mount yaffs2 mtd@media /media nosuid nodev
>
> 3 In init.sp8810.rc, add a service
> service sdcard /system/bin/sdcard /media 1023 1023
> class main
>
> 4 Add volume.cfg file and add to PRODUCT_COPY_FILES
> $ cat sp6821a_gonk/volume.cfg
> create internal-storage /media
>
> 5 All work well, but in settings, there is a bit of trouble. The "Internal
> Storage" and "Sd Card Storage" exchanged their position. The 20m internal
> storage display at the site of "Sd Card Storage".
>
> 6 What can I do to correct it?
What about the result of "adb shell vdc volume list" ? Could you post it?
Assignee | ||
Comment 15•10 years ago
|
||
(In reply to Alan Huang [:ahuang] from comment #14)
> What about the result of "adb shell vdc volume list" ? Could you post it?
$ adb shell vdc volume list
110 sdcard /mnt/external 4
200 Volumes listed.
Comment 16•10 years ago
|
||
(In reply to Zhou Lianxiang from comment #15)
> (In reply to Alan Huang [:ahuang] from comment #14)
> > What about the result of "adb shell vdc volume list" ? Could you post it?
>
> $ adb shell vdc volume list
> 110 sdcard /mnt/external 4
> 200 Volumes listed.
Oh, I see. According to comment 14, you wrote volume.cfg. So neither vold or b2g will recognize this as a real volume. They treat it as a fake one.
I would suggest you to write your volume in /etc/vold, like your sdcard partition. Also, make the first one the internal storage.
Take Fireweb as an example:
$ adb shell cat etc/vold.fstab
dev_mount sdcard /mnt/sdcard auto /devices/platform/msm_sdcc.3/mmc_host
dev_mount extsdcard /mnt/extsdcard auto /devices/platform/msm_sdcc.1/mmc_host
$ adb shell vdc volume list
110 sdcard /mnt/sdcard 4
110 extsdcard /mnt/extsdcard 0
200 Volumes listed.
Assignee | ||
Comment 17•10 years ago
|
||
(In reply to Alan Huang [:ahuang] from comment #16)
> (In reply to Zhou Lianxiang from comment #15)
> > (In reply to Alan Huang [:ahuang] from comment #14)
> > > What about the result of "adb shell vdc volume list" ? Could you post it?
> >
> > $ adb shell vdc volume list
> > 110 sdcard /mnt/external 4
> > 200 Volumes listed.
>
> Oh, I see. According to comment 14, you wrote volume.cfg. So neither vold or
> b2g will recognize this as a real volume. They treat it as a fake one.
>
> I would suggest you to write your volume in /etc/vold, like your sdcard
> partition. Also, make the first one the internal storage.
>
> Take Fireweb as an example:
>
> $ adb shell cat etc/vold.fstab
> dev_mount sdcard /mnt/sdcard auto /devices/platform/msm_sdcc.3/mmc_host
> dev_mount extsdcard /mnt/extsdcard auto /devices/platform/msm_sdcc.1/mmc_host
>
> $ adb shell vdc volume list
> 110 sdcard /mnt/sdcard 4
> 110 extsdcard /mnt/extsdcard 0
> 200 Volumes listed.
D/VoldCmdListener( 80): volume mount sdcard
I/Vold ( 80): /dev/block/vold/31:13 being considered for volume sdcard
D/Vold ( 80): Volume sdcard state changing 1 (Idle-Unmounted) -> 3 (Checking)
W/Vold ( 80): Skipping fs checks
E/Vold ( 80): /dev/block/vold/31:13 failed to mount via VFAT (Invalid argument)
E/Vold ( 80): Volume sdcard found no suitable devices for mounting :(
D/Vold ( 80): Volume sdcard state changing 3 (Checking) -> 1 (Idle-Unmounted)
W/Vold ( 80): Returning OperationFailed - no handler for errno 22
On out device, can mount via yaffs2, but not vfat
root@android:/dev/block # mount -t vfat /dev/block/mtdblock13 /mnt/sdcard
mount: Invalid argument
255|root@android:/dev/block # mount -t yaffs2 /dev/block/mtdblock13 /mnt/sdcar>
root@android:/dev/block #
What's wrong?
Assignee | ||
Comment 18•10 years ago
|
||
We can not mount mtd partition via vfat,so we can not write out volume in vold.fstab. In vold.fstab, it always mount device via vfat, no option.
Comment 19•10 years ago
|
||
Update the boot loader and boot.img for internal sdcard
Comment 21•10 years ago
|
||
Danny and I still cannot boot up my device with partner provided boot and bootloader. Still waiting for available images ...
Updated•10 years ago
|
Flags: needinfo?(styang)
Comment 22•10 years ago
|
||
Oh Okay, I think I get it.
Please see comment 16 and bug 936018. Please name your physical sdcard to "extsdcard", and the internal partition to "sdcard" :)
Comment 23•10 years ago
|
||
(In reply to Alan Huang [:ahuang] from comment #22)
> Oh Okay, I think I get it.
>
> Please see comment 16 and bug 936018. Please name your physical sdcard to
> "extsdcard", and the internal partition to "sdcard" :)
Sorry, it is bug 932018.
Assignee | ||
Comment 24•10 years ago
|
||
(In reply to Alan Huang [:ahuang] from comment #23)
> (In reply to Alan Huang [:ahuang] from comment #22)
> > Oh Okay, I think I get it.
> >
> > Please see comment 16 and bug 936018. Please name your physical sdcard to
> > "extsdcard", and the internal partition to "sdcard" :)
>
> Sorry, it is bug 932018.
What about this one...
Assignee | ||
Comment 25•10 years ago
|
||
(In reply to Alan Huang [:ahuang] from comment #22)
> Oh Okay, I think I get it.
>
> Please see comment 16 and bug 936018. Please name your physical sdcard to
> "extsdcard", and the internal partition to "sdcard" :)
It's OK!But why? Gaia recognze the volume by name?
Reporter | ||
Comment 26•10 years ago
|
||
Lianxiang has provided patch on my side, but I can't merge it because it changes uboot.
I'll wait mozilla finish download tool development.
Steven, is it ok?
Flags: needinfo?(styang)
Comment 28•10 years ago
|
||
patch for u-boot
Updated•10 years ago
|
Flags: needinfo?(styang)
Reporter | ||
Updated•10 years ago
|
Whiteboard: [POVB] → [POVB][sprd301827]
Comment 29•10 years ago
|
||
I verify the function by wip and it works, so let's wait for linux pac tool for all developers to update the device.
Flags: needinfo?(ttsai)
Reporter | ||
Comment 30•10 years ago
|
||
(In reply to thomas tsai from comment #29)
> I verify the function by wip and it works, so let's wait for linux pac tool
> for all developers to update the device.
OK, I'll land it with WIP patch on my side.
Please ask me to land it when mozilla pac tool is ok.
Status: NEW → ASSIGNED
Comment 31•10 years ago
|
||
may i know have we lockdown the spec for this? 20MB?
Flags: needinfo?(james.zhang)
Reporter | ||
Comment 32•10 years ago
|
||
(In reply to Marvin Khoo [:Marvin_Khoo] from comment #31)
> may i know have we lockdown the spec for this? 20MB?
Yes, but our customer can modify this partition size in u-boot git repo.
And is there any limitation on mozilla side? Please comment here.
Flags: needinfo?(james.zhang)
Comment 33•10 years ago
|
||
The only consideration is how much space is left for userdata which impacts the installed apps from market and meta-data upperbound used by apps in runtime.
Comment 34•10 years ago
|
||
hi James, we need reserved at least 55MB ~ 60MB space here for things that Thomas Tsai mentioned. thus, 20MB for this specific partition is max from my perspective.
Updated•10 years ago
|
Whiteboard: [POVB][sprd301827] → [POVB][sprd301827][sprd fixed wait for linux flashtool]
Reporter | ||
Comment 35•10 years ago
|
||
(In reply to Marvin Khoo [:Marvin_Khoo] from comment #34)
> hi James, we need reserved at least 55MB ~ 60MB space here for things that
> Thomas Tsai mentioned. thus, 20MB for this specific partition is max from my
> perspective.
OK
Reporter | ||
Comment 36•10 years ago
|
||
We have fixed on my side.
device/sprd
commit bac372a291100abc019c4c24b8f3f79c034e2517
Author: lianxiang.zhou <lianxiang.zhou@spreadtrum.com>
Date: Wed Apr 16 15:03:13 2014 +0800
Bug #301827 support internal sdcard
[bug number ] 301827
[root cause ] new feature
[changes ] u-boot, volume.cfg
[side effects] none
[self test ] work well
[reviewers ] james.zhang
Change-Id: If7ad323f60e2ae6658a752b5a7dff2c9c10b814c
u-boot
commit 37c1ba6741cdad6b5712eb8608c894ff6629a73c
Author: lianxiang.zhou <lianxiang.zhou@spreadtrum.com>
Date: Wed Apr 16 15:07:20 2014 +0800
Bug #301827 support internal sdcard
[bug number ] 301827
[root cause ] new feature
[changes ] u-boot, volume.cfg
[side effects] none
[self test ] work well
[reviewers ] james.zhang
Change-Id: I47c3ee9ae5a92061ec92f864fa13b2af87b6bb4a
Status: ASSIGNED → RESOLVED
Closed: 10 years ago
Resolution: --- → FIXED
Updated•10 years ago
|
status-b2g-v1.3T:
--- → affected
Reporter | ||
Comment 37•10 years ago
|
||
I have fixed this issue, but bring a new issue, bug 1003045.
You need to log in
before you can comment on or make changes to this bug.
Description
•