您尚未登录。

楼主 #1 2018-09-11 19:19:57

pqfeng
会员
注册时间: 2018-08-18
已发帖子: 129
积分: 129

请教一下,如何配置MTD ?

目前我自己配置的Linux,始终无法生成MTD。以下是正确的打印数据
[    0.758828] 4 cmdlinepart partitions found on MTD device spi32766.0
[    0.765091] Creating 4 MTD partitions on "spi32766.0":
[    0.770261] 0x000000000000-0x000000100000 : "uboot"
[    0.776598] 0x000000100000-0x000000110000 : "dtb"
[    0.782687] 0x000000110000-0x000000710000 : "kernel"
[    0.789051] 0x000000710000-0x000001000000 : "rootfs"
[    0.795907] libphy: Fixed MDIO Bus: probed
[    0.800710] dwmac-sun8i 1c30000.ethernet: PTP uses main clock

可以我的内核却无论如何也生成不出来。。。。。
我做了如何工作:
1 在uboot中添加了分区命令行。
#define CONFIG_BOOTCOMMAND   "sf probe 0; "                           \
                             "sf read 0x41800000 0x100000 0x10000; "  \
                             "sf read 0x41000000 0x110000 0x600000; " \
                             "bootz 0x41000000 - 0x41800000"

#define CONFIG_BOOTARGS      "console=ttyS0,115200 earlyprintk panic=5 rootwait " \
                             "mtdparts=spi32766.0:1M(uboot)ro,64k(dtb)ro,6M(kernel)ro,-(rootfs) root=/dev/mtdblock3 rw rootfstype=jffs2"
2. 在arch/arm/boot/dts/sun8i-v3s-lichee-zero.dts中添加了以下内容:
&spi0 {
        status ="okay";

        w25q128bv:w25q128bv@0 {
                compatible = "jedec,spi-nor";
                reg = <0x0>;
                spi-max-frequency = <50000000>;
                #address-cells = <1>;
                #size-cells = <1>;
        };
};
3. 在内核中device drive->mtd support->Command line partition table parsing 选中
    在内核中device drive->SPI support  进行了选中。

我按Zero的官方文档上的做了添加,却依然无法读到MTD相关参数。我不知道哪里出了错,希望有经验的朋友指教一二。多谢。

离线

#2 2018-09-11 19:32:42

晕哥
管理员
注册时间: 2017-09-06
已发帖子: 9,342
积分: 9202

Re: 请教一下,如何配置MTD ?

把后面的log也贴上来看看,
看下具体是什么情况
现在已经比前面好很多了





离线

楼主 #3 2018-09-11 19:51:29

pqfeng
会员
注册时间: 2018-08-18
已发帖子: 129
积分: 129

Re: 请教一下,如何配置MTD ?

以下是正确的内容,是用32M的Jffs2的ZImge

Setting up a 800x480 lcd console (overscan 0x0)
dotclock: 33000kHz = 33000kHz: (1 * 3MHz * 66) / 6
In:    serial@01c28000
Out:   serial@01c28000
Err:   serial@01c28000
Net:   No ethernet found.
starting USB...
No controllers found
Hit any key to stop autoboot:  0
SF: Detected w25q128bv with page size 256 Bytes, erase size 4 KiB, total 16 MiB
device 0 offset 0x100000, size 0x10000
SF: 65536 bytes @ 0x100000 Read: OK
device 0 offset 0x110000, size 0x600000
SF: 6291456 bytes @ 0x110000 Read: OK
## Flattened Device Tree blob at 41800000
   Booting using the fdt blob at 0x41800000
   Loading Device Tree to 42dfa000, end 42dffd8e ... OK

Starting kernel ...

[    0.000000] Booting Linux on physical CPU 0x0
[    0.000000] Linux version 4.13.0-licheepi-zero+ (hexing@ubuntu) (gcc version 4.8.4 (Ubuntu/Linaro 4.8.4-2ubuntu1~14.04.1)) #13 SMP Thu Nov 9 10:19:17 CST 2017
[    0.000000] CPU: ARMv7 Processor [410fc075] revision 5 (ARMv7), cr=10c5387d
[    0.000000] CPU: div instructions available: patching division code
[    0.000000] CPU: PIPT / VIPT nonaliasing data cache, VIPT aliasing instruction cache
[    0.000000] OF: fdt: Machine model: Lichee Pi Zero with Dock
[    0.000000] Memory policy: Data cache writealloc
[    0.000000] percpu: Embedded 16 pages/cpu @c3de6000 s33920 r8192 d23424 u65536
[    0.000000] Built 1 zonelists in Zone order, mobility grouping on.  Total pages: 15883
[    0.000000] Kernel command line: console=ttyS0,115200 earlyprintk panic=5 rootwait mtdparts=spi32766.0:1M(uboot)ro,64k(dtb)ro,6M(kernel)ro,-(rootfs) root=/dev/mtdblock3 rw rootfstype=jffs2
[    0.000000] PID hash table entries: 256 (order: -2, 1024 bytes)
[    0.000000] Dentry cache hash table entries: 8192 (order: 3, 32768 bytes)
[    0.000000] Inode-cache hash table entries: 4096 (order: 2, 16384 bytes)
[    0.000000] Memory: 53584K/64036K available (6144K kernel code, 218K rwdata, 1456K rodata, 1024K init, 264K bss, 10452K reserved, 0K cma-reserved, 0K highmem)
[    0.000000] Virtual kernel memory layout:
[    0.000000]     vector  : 0xffff0000 - 0xffff1000   (   4 kB)
[    0.000000]     fixmap  : 0xffc00000 - 0xfff00000   (3072 kB)
[    0.000000]     vmalloc : 0xc4000000 - 0xff800000   ( 952 MB)
[    0.000000]     lowmem  : 0xc0000000 - 0xc3e89000   (  62 MB)
[    0.000000]     pkmap   : 0xbfe00000 - 0xc0000000   (   2 MB)
[    0.000000]     modules : 0xbf000000 - 0xbfe00000   (  14 MB)
[    0.000000]       .text : 0xc0008000 - 0xc0700000   (7136 kB)
[    0.000000]       .init : 0xc0900000 - 0xc0a00000   (1024 kB)
[    0.000000]       .data : 0xc0a00000 - 0xc0a36a00   ( 219 kB)
[    0.000000]        .bss : 0xc0a3db20 - 0xc0a7fdfc   ( 265 kB)
[    0.000000] SLUB: HWalign=64, Order=0-3, MinObjects=0, CPUs=1, Nodes=1
[    0.000000] Hierarchical RCU implementation.
[    0.000000]  RCU event tracing is enabled.
[    0.000000]  RCU restricting CPUs from NR_CPUS=8 to nr_cpu_ids=1.
[    0.000000] RCU: Adjusting geometry for rcu_fanout_leaf=16, nr_cpu_ids=1
[    0.000000] NR_IRQS: 16, nr_irqs: 16, preallocated irqs: 16
[    0.000000] arch_timer: cp15 timer(s) running at 24.00MHz (virt).
[    0.000000] clocksource: arch_sys_counter: mask: 0xffffffffffffff max_cycles: 0x588fe9dc0, max_idle_ns: 440795202592 ns
[    0.000007] sched_clock: 56 bits at 24MHz, resolution 41ns, wraps every 4398046511097ns
[    0.000018] Switching to timer-based delay loop, resolution 41ns
[    0.000189] clocksource: timer: mask: 0xffffffff max_cycles: 0xffffffff, max_idle_ns: 79635851949 ns
[    0.000430] Console: colour dummy device 80x30
[    0.000469] Calibrating delay loop (skipped), value calculated using timer frequency.. 48.00 BogoMIPS (lpj=240000)
[    0.000485] pid_max: default: 32768 minimum: 301
[    0.000611] Mount-cache hash table entries: 1024 (order: 0, 4096 bytes)
[    0.000626] Mountpoint-cache hash table entries: 1024 (order: 0, 4096 bytes)
[    0.001242] CPU: Testing write buffer coherency: ok
[    0.001622] /cpus/cpu@0 missing clock-frequency property
[    0.001647] CPU0: thread -1, cpu 0, socket 0, mpidr 80000000
[    0.002102] Setting up static identity map for 0x40100000 - 0x40100060
[    0.002279] Hierarchical SRCU implementation.
[    0.002771] smp: Bringing up secondary CPUs ...
[    0.002784] smp: Brought up 1 node, 1 CPU
[    0.002794] SMP: Total of 1 processors activated (48.00 BogoMIPS).
[    0.002801] CPU: All CPU(s) started in SVC mode.
[    0.003577] devtmpfs: initialized
[    0.006823] VFP support v0.3: implementor 41 architecture 2 part 30 variant 7 rev 5
[    0.007126] clocksource: jiffies: mask: 0xffffffff max_cycles: 0xffffffff, max_idle_ns: 19112604462750000 ns
[    0.007153] futex hash table entries: 256 (order: 2, 16384 bytes)
[    0.007323] pinctrl core: initialized pinctrl subsystem
[    0.008173] random: get_random_u32 called from bucket_table_alloc+0xf0/0x250 with crng_init=0
[    0.008327] NET: Registered protocol family 16
[    0.008812] DMA: preallocated 256 KiB pool for atomic coherent allocations
[    0.010028] hw-breakpoint: found 5 (+1 reserved) breakpoint and 4 watchpoint registers.
[    0.010047] hw-breakpoint: maximum watchpoint size is 8 bytes.
[    0.023853] SCSI subsystem initialized
[    0.024156] usbcore: registered new interface driver usbfs
[    0.024229] usbcore: registered new interface driver hub
[    0.024325] usbcore: registered new device driver usb
[    0.024577] pps_core: LinuxPPS API ver. 1 registered
[    0.024589] pps_core: Software ver. 5.3.6 - Copyright 2005-2007 Rodolfo Giometti <giometti@linux.it>
[    0.024611] PTP clock support registered
[    0.024843] Advanced Linux Sound Architecture Driver Initialized.
[    0.026717] clocksource: Switched to clocksource arch_sys_counter
[    0.037901] NET: Registered protocol family 2
[    0.038500] TCP established hash table entries: 1024 (order: 0, 4096 bytes)
[    0.038536] TCP bind hash table entries: 1024 (order: 1, 8192 bytes)
[    0.038560] TCP: Hash tables configured (established 1024 bind 1024)
[    0.038684] UDP hash table entries: 256 (order: 1, 8192 bytes)
[    0.038731] UDP-Lite hash table entries: 256 (order: 1, 8192 bytes)
[    0.038950] NET: Registered protocol family 1
[    0.039526] RPC: Registered named UNIX socket transport module.
[    0.039545] RPC: Registered udp transport module.
[    0.039551] RPC: Registered tcp transport module.
[    0.039557] RPC: Registered tcp NFSv4.1 backchannel transport module.
[    0.041493] workingset: timestamp_bits=30 max_order=14 bucket_order=0
[    0.050655] NFS: Registering the id_resolver key type
[    0.050704] Key type id_resolver registered
[    0.050711] Key type id_legacy registered
[    0.050759] jffs2: version 2.2. (NAND) © 2001-2006 Red Hat, Inc.
[    0.052215] random: fast init done
[    0.054970] Block layer SCSI generic (bsg) driver version 0.4 loaded (major 249)
[    0.054990] io scheduler noop registered
[    0.054997] io scheduler deadline registered
[    0.055278] io scheduler cfq registered (default)
[    0.055291] io scheduler mq-deadline registered
[    0.055297] io scheduler kyber registered
[    0.059794] sun8i-v3s-pinctrl 1c20800.pinctrl: initialized sunXi PIO driver
[    0.131589] Serial: 8250/16550 driver, 8 ports, IRQ sharing disabled
[    0.134954] console [ttyS0] disabled
[    0.155234] 1c28000.serial: ttyS0 at MMIO 0x1c28000 (irq = 36, base_baud = 1500000) is a U6_16550A
[    0.745430] console [ttyS0] enabled
[    0.753525] m25p80 spi32766.0: w25q128 (16384 Kbytes)
[    0.758694] 4 cmdlinepart partitions found on MTD device spi32766.0
[    0.764954] Creating 4 MTD partitions on "spi32766.0":
[    0.770121] 0x000000000000-0x000000100000 : "uboot"
[    0.776465] 0x000000100000-0x000000110000 : "dtb"
[    0.782573] 0x000000110000-0x000000710000 : "kernel"
[    0.788925] 0x000000710000-0x000001000000 : "rootfs"
[    0.795793] libphy: Fixed MDIO Bus: probed
[    0.800591] dwmac-sun8i 1c30000.ethernet: PTP uses main clock
[    0.806386] dwmac-sun8i 1c30000.ethernet: No regulator found
[    0.812172] dwmac-sun8i 1c30000.ethernet: Will use internal PHY
[    0.818367] dwmac-sun8i 1c30000.ethernet: Chain mode enabled
[    0.824029] dwmac-sun8i 1c30000.ethernet: No HW DMA feature register supported
[    0.831275] dwmac-sun8i 1c30000.ethernet: Normal descriptors
[    0.836943] dwmac-sun8i 1c30000.ethernet: RX Checksum Offload Engine supported
[    0.844156] dwmac-sun8i 1c30000.ethernet: COE Type 2
[    0.849128] dwmac-sun8i 1c30000.ethernet: TX Checksum insertion supported
[    0.856123] libphy: stmmac: probed
[    0.861390] ehci_hcd: USB 2.0 'Enhanced' Host Controller (EHCI) Driver
[    0.868053] ehci-platform: EHCI generic platform driver
[    0.873564] ehci-platform 1c1a000.usb: EHCI Host Controller
[    0.879255] ehci-platform 1c1a000.usb: new USB bus registered, assigned bus number 1
[    0.887210] ehci-platform 1c1a000.usb: irq 26, io mem 0x01c1a000
[    0.916737] ehci-platform 1c1a000.usb: USB 2.0 started, EHCI 1.00
[    0.923916] hub 1-0:1.0: USB hub found
[    0.927869] hub 1-0:1.0: 1 port detected
[    0.932388] ohci_hcd: USB 1.1 'Open' Host Controller (OHCI) Driver
[    0.938691] ohci-platform: OHCI generic platform driver
[    0.944237] ohci-platform 1c1a400.usb: Generic Platform OHCI controller
[    0.950964] ohci-platform 1c1a400.usb: new USB bus registered, assigned bus number 2
[    0.958896] ohci-platform 1c1a400.usb: irq 27, io mem 0x01c1a400
[    1.031791] hub 2-0:1.0: USB hub found
[    1.035615] hub 2-0:1.0: 1 port detected
[    1.043219] udc-core: couldn't find an available UDC - added [g_cdc] to list of pending drivers
[    1.052820] input: 1c22800.lradc as /devices/platform/soc/1c22800.lradc/input/input0
[    1.061793] sun6i-rtc 1c20400.rtc: rtc core: registered rtc-sun6i as rtc0
[    1.068697] sun6i-rtc 1c20400.rtc: RTC enabled
[    1.073242] i2c /dev entries driver
[    1.078211] input: ns2009_ts as /devices/platform/soc/1c2ac00.i2c/i2c-0/0-0048/input/input1
[    1.087716] sunxi-wdt 1c20ca0.watchdog: Watchdog enabled (timeout=16 sec, nowayout=0)
[    1.156767] sunxi-mmc 1c0f000.mmc: base:0xc407b000 irq:23
[    1.216746] sunxi-mmc 1c10000.mmc: base:0xc423b000 irq:24
[    1.223206] usbcore: registered new interface driver usbhid
[    1.228853] usbhid: USB HID core driver
[    1.234330] sun4i-codec 1c22c00.codec: ASoC: /soc/codec-analog@01c23000 not registered
[    1.242378] sun4i-codec 1c22c00.codec: Failed to register our card
[    1.249900] NET: Registered protocol family 17
[    1.254466] Key type dns_resolver registered
[    1.258999] Registering SWP/SWPB emulation handler
[    1.271584] simple-framebuffer 43e89000.framebuffer: framebuffer at 0x43e89000, 0x177000 bytes, mapped to 0xc4400000
[    1.282305] simple-framebuffer 43e89000.framebuffer: format=x8r8g8b8, mode=800x480x32, linelength=3200
[    1.298670] Console: switching to colour frame buffer device 100x30
[    1.311095] simple-framebuffer 43e89000.framebuffer: fb0: simplefb registered!
[    1.319734] usb_phy_generic usb_phy_generic.0.auto: usb_phy_generic.0.auto supply vcc not found, using dummy regulator
[    1.331183] musb-hdrc musb-hdrc.1.auto: MUSB HDRC host driver
[    1.337031] musb-hdrc musb-hdrc.1.auto: new USB bus registered, assigned bus number 3
[    1.346191] hub 3-0:1.0: USB hub found
[    1.350190] hub 3-0:1.0: 1 port detected
[    1.355331] using random self ethernet address
[    1.359907] using random host ethernet address
[    1.365358] usb0: HOST MAC d6:82:c6:43:78:f9
[    1.369830] usb0: MAC ba:57:f1:a3:b6:e0
[    1.373743] g_cdc gadget: CDC Composite Gadget, version: King Kamehameha Day 2008
[    1.381275] g_cdc gadget: g_cdc ready
[    1.387730] sun4i-codec 1c22c00.codec: Codec <-> 1c22c00.codec mapping ok
[    1.397267] sun6i-rtc 1c20400.rtc: setting system clock to 1970-01-01 00:00:07 UTC (7)
[    1.405412] vcc3v3: disabling
[    1.408458] vcc5v0: disabling
[    1.411427] ALSA device list:
[    1.414390]   #0: V3s Audio Codec
[    1.420069] jffs2: Node at 0x00000fe0 with length 0x000000cd would run over the end of the erase block
[    1.429482] jffs2: Perhaps the file system was created with the wrong erase size?
[    1.437014] jffs2: jffs2_scan_eraseblock(): Magic bitmask 0x1985 not found at 0x00000fe4: 0x00cd instead
[    1.446483] jffs2: jffs2_scan_eraseblock(): Magic bitmask 0x1985 not found at 0x00000fe8: 0x02ac instead
[    1.455995] jffs2: jffs2_scan_eraseblock(): Magic bitmask 0x1985 not found at 0x00000fec: 0x0014 instead
[    1.465677] jffs2: jffs2_scan_eraseblock(): Magic bitmask 0x1985 not found at 0x00000ff0: 0x000b instead
[    1.475190] jffs2: jffs2_scan_eraseblock(): Magic bitmask 0x1985 not found at 0x00000ff4: 0x81ed instead
[    1.484898] jffs2: jffs2_scan_eraseblock(): Magic bitmask 0x1985 not found at 0x00001000: 0x22bf instead

离线

楼主 #4 2018-09-11 19:53:06

pqfeng
会员
注册时间: 2018-08-18
已发帖子: 129
积分: 129

Re: 请教一下,如何配置MTD ?

以下是错误的Log。我自己生成的。

No controllers found
Hit any key to stop autoboot:  0
SF: Detected w25q128bv with page size 256 Bytes, erase size 4 KiB, total 16 MiB
device 0 offset 0x100000, size 0x10000
SF: 65536 bytes @ 0x100000 Read: OK
device 0 offset 0x110000, size 0x600000
SF: 6291456 bytes @ 0x110000 Read: OK
## Flattened Device Tree blob at 41800000
   Booting using the fdt blob at 0x41800000
   Loading Device Tree to 42dfa000, end 42dffd8e ... OK

Starting kernel ...

[    0.000000] Booting Linux on physical CPU 0x0
[    0.000000] Linux version 4.10.15-licheepi-zero+ (pqfeng@ubuntu) (gcc version 4.9.2 20140904 (prerelease) (crosstool-NG linaro-1.13.1-4.9-2014.09 - Linaro GCC 4.9-2014.09) ) #5 SMP Tue Sep 11 03:12:16 PDT 2018
[    0.000000] CPU: ARMv7 Processor [410fc075] revision 5 (ARMv7), cr=10c5387d
[    0.000000] CPU: div instructions available: patching division code
[    0.000000] CPU: PIPT / VIPT nonaliasing data cache, VIPT aliasing instruction cache
[    0.000000] OF: fdt:Machine model: Lichee Pi Zero with Dock
[    0.000000] Memory policy: Data cache writealloc
[    0.000000] percpu: Embedded 14 pages/cpu @c3de8000 s24768 r8192 d24384 u57344
[    0.000000] Built 1 zonelists in Zone order, mobility grouping on.  Total pages: 15883
[    0.000000] Kernel command line: console=ttyS0,115200 earlyprintk panic=5 rootwait mtdparts=spi32766.0:1M(uboot)ro,64k(dtb)ro,6M(kernel)ro,-(rootfs) root=/dev/mtdblock3 rw rootfstype=jffs2
[    0.000000] PID hash table entries: 256 (order: -2, 1024 bytes)
[    0.000000] Dentry cache hash table entries: 8192 (order: 3, 32768 bytes)
[    0.000000] Inode-cache hash table entries: 4096 (order: 2, 16384 bytes)
[    0.000000] Memory: 53600K/64036K available (6144K kernel code, 200K rwdata, 1416K rodata, 1024K init, 294K bss, 10436K reserved, 0K cma-reserved, 0K highmem)
[    0.000000] Virtual kernel memory layout:
[    0.000000]     vector  : 0xffff0000 - 0xffff1000   (   4 kB)
[    0.000000]     fixmap  : 0xffc00000 - 0xfff00000   (3072 kB)
[    0.000000]     vmalloc : 0xc4000000 - 0xff800000   ( 952 MB)
[    0.000000]     lowmem  : 0xc0000000 - 0xc3e89000   (  62 MB)
[    0.000000]     pkmap   : 0xbfe00000 - 0xc0000000   (   2 MB)
[    0.000000]     modules : 0xbf000000 - 0xbfe00000   (  14 MB)
[    0.000000]       .text : 0xc0008000 - 0xc0700000   (7136 kB)
[    0.000000]       .init : 0xc0900000 - 0xc0a00000   (1024 kB)
[    0.000000]       .data : 0xc0a00000 - 0xc0a32040   ( 201 kB)
[    0.000000]        .bss : 0xc0a34000 - 0xc0a7da5c   ( 295 kB)
[    0.000000] SLUB: HWalign=64, Order=0-3, MinObjects=0, CPUs=1, Nodes=1
[    0.000000] Hierarchical RCU implementation.
[    0.000000]  Build-time adjustment of leaf fanout to 32.
[    0.000000]  RCU restricting CPUs from NR_CPUS=8 to nr_cpu_ids=1.
[    0.000000] RCU: Adjusting geometry for rcu_fanout_leaf=32, nr_cpu_ids=1
[    0.000000] NR_IRQS:16 nr_irqs:16 16
[    0.000000] arm_arch_timer: Architected cp15 timer(s) running at 24.00MHz (virt).
[    0.000000] clocksource: arch_sys_counter: mask: 0xffffffffffffff max_cycles: 0x588fe9dc0, max_idle_ns: 440795202592 ns
[    0.000007] sched_clock: 56 bits at 24MHz, resolution 41ns, wraps every 4398046511097ns
[    0.000019] Switching to timer-based delay loop, resolution 41ns
[    0.000154] clocksource: timer: mask: 0xffffffff max_cycles: 0xffffffff, max_idle_ns: 79635851949 ns
[    0.000381] Console: colour dummy device 80x30
[    0.000419] Calibrating delay loop (skipped), value calculated using timer frequency.. 48.00 BogoMIPS (lpj=240000)
[    0.000436] pid_max: default: 32768 minimum: 301
[    0.000570] Mount-cache hash table entries: 1024 (order: 0, 4096 bytes)
[    0.000581] Mountpoint-cache hash table entries: 1024 (order: 0, 4096 bytes)
[    0.001293] CPU: Testing write buffer coherency: ok
[    0.001705] /cpus/cpu@0 missing clock-frequency property
[    0.001730] CPU0: thread -1, cpu 0, socket 0, mpidr 80000000
[    0.002105] Setting up static identity map for 0x40100000 - 0x40100058
[    0.002856] smp: Bringing up secondary CPUs ...
[    0.002874] smp: Brought up 1 node, 1 CPU
[    0.002882] SMP: Total of 1 processors activated (48.00 BogoMIPS).
[    0.002890] CPU: All CPU(s) started in SVC mode.
[    0.003686] devtmpfs: initialized
[    0.007177] VFP support v0.3: implementor 41 architecture 2 part 30 variant 7 rev 5
[    0.007487] clocksource: jiffies: mask: 0xffffffff max_cycles: 0xffffffff, max_idle_ns: 19112604462750000 ns
[    0.007513] futex hash table entries: 256 (order: 2, 16384 bytes)
[    0.007680] pinctrl core: initialized pinctrl subsystem
[    0.008663] NET: Registered protocol family 16
[    0.009134] DMA: preallocated 256 KiB pool for atomic coherent allocations
[    0.010523] hw-breakpoint: found 5 (+1 reserved) breakpoint and 4 watchpoint registers.
[    0.010541] hw-breakpoint: maximum watchpoint size is 8 bytes.
[    0.023831] SCSI subsystem initialized
[    0.024119] usbcore: registered new interface driver usbfs
[    0.024181] usbcore: registered new interface driver hub
[    0.024281] usbcore: registered new device driver usb
[    0.024526] pps_core: LinuxPPS API ver. 1 registered
[    0.024535] pps_core: Software ver. 5.3.6 - Copyright 2005-2007 Rodolfo Giometti <giometti@linux.it>
[    0.024573] PTP clock support registered
[    0.024799] Advanced Linux Sound Architecture Driver Initialized.
[    0.026682] clocksource: Switched to clocksource arch_sys_counter
[    0.037631] NET: Registered protocol family 2
[    0.038256] TCP established hash table entries: 1024 (order: 0, 4096 bytes)
[    0.038289] TCP bind hash table entries: 1024 (order: 1, 8192 bytes)
[    0.038313] TCP: Hash tables configured (established 1024 bind 1024)
[    0.038400] UDP hash table entries: 256 (order: 1, 8192 bytes)
[    0.038446] UDP-Lite hash table entries: 256 (order: 1, 8192 bytes)
[    0.038671] NET: Registered protocol family 1
[    0.039316] RPC: Registered named UNIX socket transport module.
[    0.039337] RPC: Registered udp transport module.
[    0.039343] RPC: Registered tcp transport module.
[    0.039348] RPC: Registered tcp NFSv4.1 backchannel transport module.
[    0.041646] workingset: timestamp_bits=30 max_order=14 bucket_order=0
[    0.051135] NFS: Registering the id_resolver key type
[    0.051188] Key type id_resolver registered
[    0.051195] Key type id_legacy registered
[    0.051247] jffs2: version 2.2. (NAND) (SUMMARY)  © 2001-2006 Red Hat, Inc.
[    0.055843] Block layer SCSI generic (bsg) driver version 0.4 loaded (major 249)
[    0.055867] io scheduler noop registered
[    0.055873] io scheduler deadline registered
[    0.056060] io scheduler cfq registered (default)
[    0.060709] sun8i-v3s-pinctrl 1c20800.pinctrl: initialized sunXi PIO driver
[    0.130490] Serial: 8250/16550 driver, 8 ports, IRQ sharing disabled
[    0.133872] console [ttyS0] disabled
[    0.154164] 1c28000.serial: ttyS0 at MMIO 0x1c28000 (irq = 36, base_baud = 1500000) is a U6_16550A
[    0.725517] console [ttyS0] enabled
[    0.729802] [drm] Initialized
[    0.736191] libphy: Fixed MDIO Bus: probed
[    0.740721] ehci_hcd: USB 2.0 'Enhanced' Host Controller (EHCI) Driver
[    0.747306] ehci-platform: EHCI generic platform driver
[    0.752783] ehci-platform 1c1a000.usb: EHCI Host Controller
[    0.758469] ehci-platform 1c1a000.usb: new USB bus registered, assigned bus number 1
[    0.766380] ehci-platform 1c1a000.usb: irq 26, io mem 0x01c1a000
[    0.796723] ehci-platform 1c1a000.usb: USB 2.0 started, EHCI 1.00
[    0.803987] hub 1-0:1.0: USB hub found
[    0.807946] hub 1-0:1.0: 1 port detected
[    0.812484] ohci_hcd: USB 1.1 'Open' Host Controller (OHCI) Driver
[    0.818800] ohci-platform: OHCI generic platform driver
[    0.824319] ohci-platform 1c1a400.usb: Generic Platform OHCI controller
[    0.831049] ohci-platform 1c1a400.usb: new USB bus registered, assigned bus number 2
[    0.839003] ohci-platform 1c1a400.usb: irq 27, io mem 0x01c1a400
[    0.911816] hub 2-0:1.0: USB hub found
[    0.915652] hub 2-0:1.0: 1 port detected
[    0.923260] udc-core: couldn't find an available UDC - added [g_cdc] to list of pending drivers
[    0.932824] input: 1c22800.lradc as /devices/platform/soc/1c22800.lradc/input/input0
[    0.941882] sun6i-rtc 1c20400.rtc: rtc core: registered rtc-sun6i as rtc0
[    0.948806] sun6i-rtc 1c20400.rtc: RTC enabled
[    0.953358] i2c /dev entries driver
[    0.958321] input: ns2009_ts as /devices/platform/soc/1c2ac00.i2c/i2c-0/0-0048/input/input1
[    0.967929] sunxi-wdt 1c20ca0.watchdog: Watchdog enabled (timeout=16 sec, nowayout=0)
[    1.036731] sunxi-mmc 1c0f000.mmc: base:0xc4241000 irq:23
[    1.096704] sunxi-mmc 1c10000.mmc: base:0xc4245000 irq:24
[    1.103123] usbcore: registered new interface driver usbhid
[    1.108789] usbhid: USB HID core driver
[    1.114280] sun4i-codec 1c22c00.codec: ASoC: /soc/codec-analog@01c23000 not registered
[    1.122341] sun4i-codec 1c22c00.codec: Failed to register our card
[    1.129864] NET: Registered protocol family 17
[    1.134458] Key type dns_resolver registered
[    1.139003] Registering SWP/SWPB emulation handler
[    1.152689] usb_phy_generic.0.auto supply vcc not found, using dummy regulator
[    1.160687] musb-hdrc musb-hdrc.1.auto: MUSB HDRC host driver
[    1.166450] musb-hdrc musb-hdrc.1.auto: new USB bus registered, assigned bus number 3
[    1.175714] hub 3-0:1.0: USB hub found
[    1.179715] hub 3-0:1.0: 1 port detected
[    1.184430] using random self ethernet address
[    1.189008] using random host ethernet address
[    1.194539] usb0: HOST MAC 82:01:3e:66:d1:5b
[    1.198979] usb0: MAC 6e:ad:4e:f7:14:81
[    1.202883] g_cdc gadget: CDC Composite Gadget, version: King Kamehameha Day 2008
[    1.210409] g_cdc gadget: g_cdc ready
[    1.216792] sun4i-codec 1c22c00.codec: Codec <-> 1c22c00.codec mapping ok
[    1.226424] sun6i-rtc 1c20400.rtc: setting system clock to 1970-01-01 00:01:56 UTC (116)
[    1.234847] vcc5v0: disabling
[    1.237883] ALSA device list:
[    1.240853]   #0: V3s Audio Codec
[    1.246056] Waiting for root device /dev/mtdblock3...
[    5.675782] random: fast init done

离线

楼主 #5 2018-09-11 19:54:33

pqfeng
会员
注册时间: 2018-08-18
已发帖子: 129
积分: 129

Re: 请教一下,如何配置MTD ?

补充说明:这两个zImage用相同的dtb.我没修改DTB

离线

#6 2018-09-11 19:55:39

晕哥
管理员
注册时间: 2017-09-06
已发帖子: 9,342
积分: 9202

Re: 请教一下,如何配置MTD ?

你的 jffs2 文件系统有没有烧到 flash?





离线

楼主 #7 2018-09-11 19:58:40

pqfeng
会员
注册时间: 2018-08-18
已发帖子: 129
积分: 129

Re: 请教一下,如何配置MTD ?

有的。现在的问题主要是MTD的分区表。只要能读到分区表,我就不用Jff2,直接用tar就OK了。

离线

#8 2018-09-11 20:04:12

晕哥
管理员
注册时间: 2017-09-06
已发帖子: 9,342
积分: 9202

Re: 请教一下,如何配置MTD ?

没有 tar 这种文件系统

简单一点,用ramdisk启动,然后去格式化 /dev/mtd3

然后再挂 /dev/mtdblock3 为 jffs2 文件系统。

再把根文件拷到 mtdblock3去,

然后再用 mtdblock3 作为根文件系统启动系统。





离线

页脚

工信部备案:粤ICP备20025096号 Powered by FluxBB

感谢为中文互联网持续输出优质内容的各位老铁们。 QQ: 516333132, 微信(wechat): whycan_cn (哇酷网/挖坑网/填坑网) service@whycan.cn