Android Flash分割槽大小檢視
阿新 • • 發佈:2018-10-31
正常的8G Flash有多少可以用的
這樣算吧:
硬碟和U盤廠家的演算法:8GB*1000=8000MB*1000=8000000KB*1000=8000000000B
電腦系統的演算法:8000000000B/1024=7812500KB/1024=7629.4MB/1024=7.45GB
所以U盤在7.4G左右是正常的,是電腦系統演算法和廠家演算法的區別而已,所有硬碟和儲存裝置都是這樣算的。
一種是1:1000的演算法 一種是1:1024的演算法
從日誌上看分割槽大小
從日誌上看 Flash 檔案系統計算出來的大小是 7.28CB
[ 1.932780] inv_mpu_iio: inv_mpu: reset chip failed, err = -6 [ 1.965906] mmc1: MAN_BKOPS_EN bit is not set [ 1.978246] mmc1: new HS400 Enhanced strobe MMC card at address 0001 [ 1.979106] mmcblk1: mmc1:0001 8GME4R 7.28 GiB [ 1.979611] mmcblk1boot0: mmc1:0001 8GME4R partition 1 4.00 MiB [ 1.983828] mmcblk1boot1: mmc1:0001 8GME4R partition 2 4.00 MiB [ 1.984383] mmcblk1rpmb: mmc1:0001 8GME4R partition 3 512 KiB [ 1.984837] uboot: 0x000400000 -- 0x000800000 (4 MB) [ 1.984852] trust: 0x000800000 -- 0x000c00000 (4 MB) [ 1.984865] misc: 0x000c00000 -- 0x001000000 (4 MB) [ 1.984877] resource: 0x001000000 -- 0x002000000 (16 MB) [ 1.984889] kernel: 0x002000000 -- 0x003800000 (24 MB) [ 1.984902] boot: 0x003800000 -- 0x005800000 (32 MB) [ 1.984914] recovery: 0x005800000 -- 0x009800000 (64 MB) [ 1.984927] backup: 0x009800000 -- 0x010800000 (112 MB) [ 1.984939] cache: 0x010800000 -- 0x038800000 (640 MB) [ 1.985226] system: 0x038800000 -- 0x098800000 (1536 MB) [ 1.985241] metadata: 0x098800000 -- 0x099800000 (16 MB) [ 1.985253] verity_mode: 0x099800000 -- 0x099808000 (0 MB) [ 1.985266] baseparamer: 0x099808000 -- 0x099c08000 (4 MB) [ 1.985278] frp: 0x099c08000 -- 0x099c88000 (0 MB) [ 1.985291] userdata: 0x099c88000 -- 0x1d1c00000 (4991 MB) [ 1.985417] mmcblk1: p1 p2 p3 p4 p5 p6 p7 p8 p9 p10 p11 p12 p13 p14 p15 [ 2.035459] inv_mpu_iio: inv_mpu: reset chip failed, err = -6 [ 2.138786] inv_mpu_iio: inv_mpu: reset chip failed, err = -6 [ 2.242241] inv_mpu_iio: inv_mpu: reset chip failed, err = -6 [ 2.345572] inv_mpu_iio: inv_mpu: reset chip failed, err = -6 [ 2.449042] inv_mpu_iio: inv_mpu: reset chip failed, err = -6 [ 2.552228] inv_mpu_iio: inv_mpu: reset chip failed, err = -6
程式碼設定Flash分割槽大小位置
[email protected]:~/repoRk3399_yan4_dev/device/rockchip/rk3399/rk3399_mid$ cat parameter.txt
FIRMWARE_VER: 0.8.0
MACHINE_MODEL: RK3399
MACHINE_ID: 007
MANUFACTURER: RK3399
MAGIC: 0x5041524B
ATAG: 0x00200800
MACHINE: 3399
CHECK_MASK: 0x80
PWR_HLD: 0,0,A,0,1
#KERNEL_IMG: 0x00280000
#FDT_NAME: rk-kernel.dtb
#RECOVER_KEY: 1,1,0,20,0
#in section; per section 512(0x200) bytes
CMDLINE: androidboot.baseband=N/A androidboot.selinux=enforcing androidboot.hardware=rk30board androidboot.console=ttyFIQ0 init=/init mtdparts=rk29xxnand: [email protected](uboot),[email protected](trust),[email protected](misc),[email protected](resource),[email protected](kernel),[email protected](boot),[email protected](recovery),[email protected](backup),[email protected](cache),[email protected](system),[email protected] (metadata),[email protected](verity_mode),[email protected](baseparamer),[email protected](frp),[email protected](userdata)
[email protected]:~/repoRk3399_yan4_dev/device/rockchip/rk3399/rk3399_mid$
解釋
0x00002000@0x00002000(uboot)
@後面指的是起始地址,前面指的是分割槽的大小,0x00002000+0x00002000 等於下一個分割槽的起始地址0x00004000