Am335x SD卡刷eMMC二

犹豫前段时间一直在搞另一个项目,Am335x这个BBlack板就放置一边了。前几天把BBlack板重新拿到手,之前搞得给全忘了。SD卡烧写emmC时突然出现了错误,一直找不到原因,今天终于算是有点眉目了,就录下来省得下次又忘记了。

之前的SD卡烧写eMMC bolg:https://www.cnblogs.com/BigOBlue/p/8513067.html

之前不能分区出现的错误:log:

********************************************
Sitara Flash Fetcher is complete. Executing /home/root/debrick.sh.

****************************************************
****************************************************

Sitara Example Flashing Script - 02/11/2014

1+0 records in
1+0 records out
(standard_in) 1: parse error
No partition found. Continuing.
Partitioning the eMMC...

Usage:
sfdisk [options] <device> [...]

Options:
-s, --show-size list size of a partition
-c, --id change or print partition Id
--change-id change Id
--print-id print Id
-l, --list list partitions of each device
-d, --dump idem, but in a format suitable for later input
-i, --increment number cylinders etc. from 1 instead of from 0
-u, --unit <letter> units to be used; <letter> can be one of
S (sectors), C (cylinders), B (blocks), or M (MB)
-1, --one-only reserved option that does nothing currently
-T, --list-types list the known partition types
-D, --DOS for DOS-compatibility: waste a little space
-E, --DOS-extended DOS extended partition compatibility
-R, --re-read make the kernel reread the partition table
-N <number> change only the partition with this <number>
-n do not actually write to disk
-O <file> save the sectors that will be overwritten to <file>
-I <file> restore sectors from <file>
-V, --verify check that the listed partitions are reasonable
-v, --version display version information and exit
-h, --help display this help text and exit

Dangerous options:
-f, --force disable all consistency checking
--no-reread do not check whether the partition is in use
-q, --quiet suppress warning messages
-L, --Linux do not complain about things irrelevant for Linux
-g, --show-geometry print the kernel's idea of the geometry
-G, --show-pt-geometry print geometry guessed from the partition table
-A, --activate[=<device>] activate bootable flag
-U, --unhide[=<dev>] set partition unhidden
-x, --show-extended also list extended partitions in the output,
or expect descriptors for them in the input
--leave-last do not allocate the last cylinder
--IBM same as --leave-last
--in-order partitions are in order
--not-in-order partitions are not in order
--inside-outer all logicals inside outermost extended
--not-inside-outer not all logicals inside outermost extended
--nested every partition is disjoint from all others
--chained like nested, but extended partitions may lie outside
--onesector partitions are mutually disjoint

Override the detected geometry using:
-C, --cylinders <number> set the number of cylinders to use
-H, --heads <number> set the number of heads to use
-S, --sectors <number> set the number of sectors to use

No partition found. Continuing.
1+0 records in
1+0 records out
Formatting the eMMC into 2 partitions...
mkfs.vfat 2.11 (12 Mar 2005)
mkfs.vfat: Too few blocks for viable file system
mke2fs 1.42.1 (17-Feb-2012)
Could not stat /dev/mmcblk1p2 --- No such file or directory

The device apparently does not exist; did you specify it correctly?
Formatting done.
[ 13.826364] FAT-fs (loop0): bogus number of reserved sectors
[ 13.832343] FAT-fs (loop0): Can't find a valid FAT filesystem
mount: wrong fs type, bad option, bad superblock on /dev/loop0,
missing codepage or helper program, or other error
In some cases useful info is found in syslog - try
dmesg | tail or so

mount: special device /dev/mmcblk1p2 does not exist
Copying Files...
tar: can't open 'boot_partition.tar.gz': No such file or directory
Command exited with non-zero status 1
real 0m 0.00s
user 0m 0.00s
sys 0m 0.00s
umount: /dev/mmcblk1p1: not mounted
rm: can't remove 'boot_partition.tar.gz': No such file or directory
Boot partition done.
tar: can't open 'rootfs_partition.tar.gz': No such file or directory
Command exited with non-zero status 1
real 0m 0.00s
user 0m 0.00s
sys 0m 0.00s
umount: /dev/mmcblk1p2: not found
rm: can't remove 'rootfs_partition.tar.gz': No such file or directory
RootFS partition done.
It took 2 seconds to complete this task...

********************************************
Sitara Example Flash Script is complete.

经过多次试验依然是上面的log,最后不得已重现编译了内核用的是3.14.65,重新烧写对应的uImage。依然没有成功,错误信息:

 

U-Boot 2016.03 (Oct 19 2017 - 13:39:57 +0800)

U-Boot code: 80800000 -> 808DA324  BSS_END: -> 80926BBC
       Watchdog enabled
I2C:   ready
DRAM:  512 MiB
NAND:  0 MiB
nand_init->xxxx/drivers/mtd/nand/nand.c
MMC:   OMAP SD/MMC: 0, OMAP SD/MMC: 1
MMC->xxxx/drivers/mmc/mmc.c1
MMC->xxxx/drivers/mmc/mmc.c2
xxxx/common/env_common.c
*** Error - No Valid Environment Area found
*** Warning - bad CRC, using default environment

xxxx/common/env_common.c
Net:   xxx/board/ti/am335x/board_eth_init--->,6be7
xxx/board/ti/am335x/board_eth_init--->,5fab5ef4
<ethaddr> not set. Validating first E-fuse MAC
Here at xxx/drivers/net/cpsw.c
phy_reg---> 3000
phy_reg---> 7809
phy_reg---> 7
phy_reg---> c0f1
phy_reg---> 1e1
phy_reg---> 1
phy_reg---> 0
phy_reg---> ffff
phy_reg---> ffff
phy_reg---> ffff
phy_reg---> ffff
phy_reg---> ffff
phy_reg---> ffff
phy_reg---> ffff
phy_reg---> ffff
phy_reg---> 0
phy_reg---> 40
phy_reg---> 2
phy_reg---> e0
phy_reg---> ffff
phy_reg---> 0
phy_reg---> 0
phy_reg---> 0
phy_reg---> 0
phy_reg---> ffff
phy_reg---> ffff
phy_reg---> 0
phy_reg---> 0
phy_reg---> 0
phy_reg---> 90
phy_reg---> 0
phy_reg---> 40
End
xxx/Board/Ti/Am335x/Board.c:---->Ethernet_init
maria: ----> 40070106
maria: ----> 410000ff
maria: ----> 1
maria: ----> 0
maria: ----> 0
maria: ----> 0
maria: ----> 1
maria: ----> 0
maria: ----> 0
maria: ----> 0
maria: ----> 23e00040
maria: ----> 0
maria: ----> 0
maria: ----> 0
xxx/Board/Ti/Am335x/Board.c:---->Ethernet_init
cpsw, usb_ether
NET: -> xxxx/net/eth_legacy.c
Press SPACE to abort autoboot in 5 seconds
## Error: "envboot" not defined
 lcd reset
switch to partitions #0, OK
mmc0 is current device
Scanning mmc 0:1...
switch to partitions #0, OK
mmc0 is current device
SD/MMC found on device 0
** File not found boot.scr **
780 bytes read in 13 ms (58.6 KiB/s)
Loaded environment from uEnv.txt
Importing environment from mmc ...
Running uenvcmd ...
780 bytes read in 25 ms (30.3 KiB/s)
4624800 bytes read in 275 ms (16 MiB/s)
29703 bytes read in 34 ms (852.5 KiB/s)
## Booting kernel from Legacy Image at 82000000 ...
   Image Name:   Linux-3.14.65
   Created:      2019-09-05   7:14:29 UTC
   Image Type:   ARM Linux Kernel Image (uncompressed)
   Data Size:    4624736 Bytes = 4.4 MiB
   Load Address: 80008000
   Entry Point:  80008000
   Verifying Checksum ... OK
## Flattened Device Tree blob at 88000000
   Booting using the fdt blob at 0x88000000
   Loading Kernel Image ... OK
   Using Device Tree in place at 88000000, end 8800a406

Starting kernel ...

用重新编译的内核,发现Uboot起来了,但是不能引导内核,一直卡在Starting kernel ...这里,从网上查资料还想象设备树有关,进而重新编译设备树,但是依然没有通过还是卡在Starting kernel ...这里。重新对比了设备树发现虽然不编译了设备树,但是设备树并没有更新。进入内核找到设备树,找到am335x-boneblack.dtb,删除,重新编译,获取新的设备树。然后按之前写的SD卡烧写eMMC方式,重新制作SD卡。这次就好了。

出现卡死Starting kernel ...的原因,我猜是uImage和设备树不匹配(版本或者其他什么原因)。

启动SD卡:LOG:

U-Boot 2018.09-00002-g0b54a51eee (Sep 10 2018 - 19:41:39 -0500), Build: jenkins-github_Bootloader-Builder-65

CPU  : AM335X-GP rev 2.1
I2C:   ready
DRAM:  512 MiB
No match for driver 'omap_hsmmc'
No match for driver 'omap_hsmmc'
Some drivers were not found
Reset Source: Power-on reset has occurred.
RTC 32KCLK Source: External.
MMC:   OMAP SD/MMC: 0, OMAP SD/MMC: 1
Loading Environment from EXT4... ** File not found /boot/uboot.env **

** Unable to read "/boot/uboot.env" from mmc0:1 **
Board: BeagleBone Black
<ethaddr> not set. Validating first E-fuse MAC
BeagleBone Black:
Model: Element14 BeagleBone Black Industrial:
BeagleBone: cape eeprom: i2c_probe: 0x54:
BeagleBone: cape eeprom: i2c_probe: 0x55:
BeagleBone: cape eeprom: i2c_probe: 0x56:
BeagleBone: cape eeprom: i2c_probe: 0x57:
Net:   eth0: MII MODE
cpsw, usb_ether
Press SPACE to abort autoboot in 2 seconds
board_name=[A335BNLT] ...
board_rev=[EIA0] ...
switch to partitions #0, OK
mmc0 is current device
SD/MMC found on device 0
switch to partitions #0, OK
mmc0 is current device
Scanning mmc 0:1...
gpio: pin 56 (gpio 56) value is 0
gpio: pin 55 (gpio 55) value is 0
gpio: pin 54 (gpio 54) value is 0
gpio: pin 53 (gpio 53) value is 1
switch to partitions #0, OK
mmc0 is current device
gpio: pin 54 (gpio 54) value is 1
Checking for: /uEnv.txt ...
780 bytes read in 9 ms (84 KiB/s)
gpio: pin 55 (gpio 55) value is 1
Loaded environment from /uEnv.txt
Importing environment from mmc ...
Checking if uenvcmd is set ...
gpio: pin 56 (gpio 56) value is 1
Running uenvcmd ...
780 bytes read in 16 ms (46.9 KiB/s)
4624800 bytes read in 306 ms (14.4 MiB/s)
29703 bytes read in 24 ms (1.2 MiB/s)
## Booting kernel from Legacy Image at 82000000 ...
   Image Name:   Linux-3.14.65
   Created:      2019-09-05   7:14:29 UTC
   Image Type:   ARM Linux Kernel Image (uncompressed)
   Data Size:    4624736 Bytes = 4.4 MiB
   Load Address: 80008000
   Entry Point:  80008000
   Verifying Checksum ... OK
## Flattened Device Tree blob at 88000000
   Booting using the fdt blob at 0x88000000
   Loading Kernel Image ... OK
   Using Device Tree in place at 88000000, end 8800a406

Starting kernel ...

[    0.000000] Booting Linux on physical CPU 0x0
[    0.000000] Linux version 3.14.65 (zyr@ubuntu) (gcc version 4.6.3 (Ubuntu/Linaro 4.6.3-1ubuntu5) ) #30 SMP Mon Jul 16 18:44:46 CST 2018
[    0.000000] CPU: ARMv7 Processor [413fc082] revision 2 (ARMv7), cr=10c5387d
[    0.000000] CPU: PIPT / VIPT nonaliasing data cache, VIPT aliasing instruction cache
[    0.000000] Machine model: TI AM335x BeagleBone
[    0.000000] cma: CMA: reserved 16 MiB at 9e800000
[    0.000000] Memory policy: Data cache writeback
[    0.000000] CPU: All CPU(s) started in SVC mode.
[    0.000000] AM335X ES2.1 (sgx neon )
[    0.000000] PERCPU: Embedded 9 pages/cpu @dfad5000 s13184 r8192 d15488 u36864
[    0.000000] Built 1 zonelists in Zone order, mobility grouping on.  Total pages: 129792
[    0.000000] Kernel command line: console=ttyO0 console=ttyO0,115200n8 root=/dev/mmcblk0p1 rootfstype=ext4 rootwait
[    0.000000] PID hash table entries: 2048 (order: 1, 8192 bytes)
[    0.000000] Dentry cache hash table entries: 65536 (order: 6, 262144 bytes)
[    0.000000] Inode-cache hash table entries: 32768 (order: 5, 131072 bytes)
[    0.000000] Memory: 487168K/523264K available (6092K kernel code, 674K rwdata, 2324K rodata, 380K init, 5529K bss, 36096K reserved, 0K highmem)
[    0.000000] Virtual kernel memory layout:
[    0.000000]     vector  : 0xffff0000 - 0xffff1000   (   4 kB)
[    0.000000]     fixmap  : 0xfff00000 - 0xfffe0000   ( 896 kB)
[    0.000000]     vmalloc : 0xe0800000 - 0xff000000   ( 488 MB)
[    0.000000]     lowmem  : 0xc0000000 - 0xe0000000   ( 512 MB)
[    0.000000]     pkmap   : 0xbfe00000 - 0xc0000000   (   2 MB)
[    0.000000]     modules : 0xbf000000 - 0xbfe00000   (  14 MB)
[    0.000000]       .text : 0xc0008000 - 0xc0840224   (8417 kB)
[    0.000000]       .init : 0xc0841000 - 0xc08a0380   ( 381 kB)
[    0.000000]       .data : 0xc08a2000 - 0xc094a990   ( 675 kB)
[    0.000000]        .bss : 0xc094a990 - 0xc0eb0e60   (5530 kB)
[    0.000000] Hierarchical RCU implementation.
[    0.000000]  RCU restricting CPUs from NR_CPUS=2 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 16
[    0.000000] IRQ: Found an INTC at 0xfa200000 (revision 5.0) with 128 interrupts
[    0.000000] Total of 128 interrupts on 1 active controller
[    0.000000] OMAP clockevent source: timer2 at 24000000 Hz
[    0.000012] sched_clock: 32 bits at 24MHz, resolution 41ns, wraps every 178956969942ns
[    0.000054] OMAP clocksource: timer1 at 24000000 Hz
[    0.000811] Console: colour dummy device 80x30
[    0.000860] Lock dependency validator: Copyright (c) 2006 Red Hat, Inc., Ingo Molnar
[    0.000869] ... MAX_LOCKDEP_SUBCLASSES:  8
[    0.000876] ... MAX_LOCK_DEPTH:          48
[    0.000884] ... MAX_LOCKDEP_KEYS:        8191
[    0.000891] ... CLASSHASH_SIZE:          4096
[    0.000898] ... MAX_LOCKDEP_ENTRIES:     16384
[    0.000905] ... MAX_LOCKDEP_CHAINS:      32768
[    0.000912] ... CHAINHASH_SIZE:          16384
[    0.000919]  memory used by lock dependency info: 3695 kB
[    0.000927]  per task-struct memory footprint: 1152 bytes
[    0.000970] Calibrating delay loop... 996.14 BogoMIPS (lpj=4980736)
[    0.079201] pid_max: default: 32768 minimum: 301
[    0.079550] Security Framework initialized
[    0.079664] Mount-cache hash table entries: 1024 (order: 0, 4096 bytes)
[    0.079676] Mountpoint-cache hash table entries: 1024 (order: 0, 4096 bytes)
[    0.097506] CPU: Testing write buffer coherency: ok
[    0.098742] CPU0: thread -1, cpu 0, socket -1, mpidr 0
[    0.098809] Setting up static identity map for 0x805c6ce8 - 0x805c6d58
[    0.101917] Brought up 1 CPUs
[    0.101939] SMP: Total of 1 processors activated (996.14 BogoMIPS).
[    0.101948] CPU: All CPU(s) started in SVC mode.
[    0.104599] devtmpfs: initialized
[    0.114290] VFP support v0.3: implementor 41 architecture 3 part 30 variant c rev 3
[    0.147784] omap_hwmod: tptc0 using broken dt data from edma
[    0.148139] omap_hwmod: tptc1 using broken dt data from edma
[    0.148480] omap_hwmod: tptc2 using broken dt data from edma
[    0.156006] omap_hwmod: debugss: _wait_target_disable failed
[    0.202486] pinctrl core: initialized pinctrl subsystem
[    0.206481] regulator-dummy: no parameters
[    0.209872] NET: Registered protocol family 16
[    0.214993] DMA: preallocated 256 KiB pool for atomic coherent allocations
[    0.232740] platform 49000000.edma: alias fck already exists
[    0.232779] platform 49000000.edma: alias fck already exists
[    0.232797] platform 49000000.edma: alias fck already exists
[    0.236959] OMAP GPIO hardware version 0.1
[    0.251971] platform 481cc000.d_can: alias fck already exists
[    0.264149] No ATAGs?
[    0.264174] hw-breakpoint: debug architecture 0x4 unsupported.
[    0.333074] bio: create slab <bio-0> at 0
[    0.372852] edma-dma-engine edma-dma-engine.0: TI EDMA DMA engine driver
[    0.374867] vmmcsd_fixed: 3300 mV
[    0.381914] SCSI subsystem initialized
[    0.384196] usbcore: registered new interface driver usbfs
[    0.384629] usbcore: registered new interface driver hub
[    0.385350] usbcore: registered new device driver usb
[    0.388143] omap_i2c 44e0b000.i2c: could not find pctldev for node /pinmux@44e10800/pinmux_i2c0_pins, deferring probe
[    0.388190] platform 44e0b000.i2c: Driver omap_i2c requests probe deferral
[    0.396914] Switched to clocksource timer1
[    0.553831] NET: Registered protocol family 2
[    0.555834] TCP established hash table entries: 4096 (order: 2, 16384 bytes)
[    0.556016] TCP bind hash table entries: 4096 (order: 5, 147456 bytes)
[    0.557522] TCP: Hash tables configured (established 4096 bind 4096)
[    0.557699] TCP: reno registered
[    0.557727] UDP hash table entries: 256 (order: 2, 20480 bytes)
[    0.557916] UDP-Lite hash table entries: 256 (order: 2, 20480 bytes)
[    0.558897] NET: Registered protocol family 1
[    0.560293] RPC: Registered named UNIX socket transport module.
[    0.560315] RPC: Registered udp transport module.
[    0.560325] RPC: Registered tcp transport module.
[    0.560334] RPC: Registered tcp NFSv4.1 backchannel transport module.
[    0.562840] hw perfevents: enabled with ARMv7 Cortex-A8 PMU driver, 5 counters available
[    0.570965] futex hash table entries: 256 (order: 2, 16384 bytes)
[    0.722175] VFS: Disk quotas dquot_6.5.2
[    0.722375] Dquot-cache hash table entries: 1024 (order 0, 4096 bytes)
[    0.724437] NFS: Registering the id_resolver key type
[    0.724814] Key type id_resolver registered
[    0.724833] Key type id_legacy registered
[    0.724940] jffs2: version 2.2. (NAND) (SUMMARY)  © 2001-2006 Red Hat, Inc.
[    0.725335] msgmni has been set to 983
[    0.728468] io scheduler noop registered
[    0.728493] io scheduler deadline registered
[    0.728553] io scheduler cfq registered (default)
[    0.731469] pinctrl-single 44e10800.pinmux: 142 pins at pa f9e10800 size 568
[    0.739111] Serial: 8250/16550 driver, 4 ports, IRQ sharing enabled
[    0.746647] omap_uart 44e09000.serial: no wakeirq for uart0
[    0.748029] 44e09000.serial: ttyO0 at MMIO 0x44e09000 (irq = 88, base_baud = 3000000) is a OMAP UART0
[    1.414291] console [ttyO0] enabled
[    1.423135] omap_rng 48310000.rng: OMAP Random Number Generator ver. 20
[    1.432487] [drm] Initialized drm 1.1.0 20060810
[    1.467419] brd: module loaded
[    1.488998] loop: module loaded
[    1.498325] mtdoops: mtd device (mtddev=name/number) must be supplied
[    1.520354] vcan: Virtual CAN interface driver
[    1.525024] CAN device driver interface
[    1.533187] c_can_platform 481cc000.d_can: c_can_platform device registered (regs=fa1cc000, irq=68)
[    1.546708] usbcore: registered new interface driver rtl8150
[    1.553539] usbcore: registered new interface driver r8152
[    1.559843] usbcore: registered new interface driver asix
[    1.565868] usbcore: registered new interface driver ax88179_178a
[    1.572993] usbcore: registered new interface driver cdc_ether
[    1.579634] usbcore: registered new interface driver smsc95xx
[    1.586021] usbcore: registered new interface driver net1080
[    1.592538] usbcore: registered new interface driver cdc_subset
[    1.599203] usbcore: registered new interface driver zaurus
[    1.605489] usbcore: registered new interface driver cdc_ncm
[    1.613713] ehci_hcd: USB 2.0 'Enhanced' Host Controller (EHCI) Driver
[    1.620664] ehci-platform: EHCI generic platform driver
[    1.627028] ehci-omap: OMAP-EHCI Host Controller driver
[    1.633116] ohci_hcd: USB 1.1 'Open' Host Controller (OHCI) Driver
[    1.639740] ohci-platform: OHCI generic platform driver
[    1.645788] ohci-omap3: OHCI OMAP3 driver
[    1.651047] usbcore: registered new interface driver cdc_wdm
[    1.657566] usbcore: registered new interface driver usb-storage
[    1.664683] usbcore: registered new interface driver usbserial
[    1.671376] usbcore: registered new interface driver usbtest
[    1.682771] 47401300.usb-phy supply vcc not found, using dummy regulator
[    1.695498] musb-hdrc musb-hdrc.0.auto: Failed to request rx1.
[    1.702034] musb-hdrc musb-hdrc.0.auto: musb_init_controller failed with status -517
[    1.710276] platform musb-hdrc.0.auto: Driver musb-hdrc requests probe deferral
[    1.719588] 47401b00.usb-phy supply vcc not found, using dummy regulator
[    1.730892] musb-hdrc musb-hdrc.1.auto: Failed to request rx1.
[    1.737142] musb-hdrc musb-hdrc.1.auto: musb_init_controller failed with status -517
[    1.745310] platform musb-hdrc.1.auto: Driver musb-hdrc requests probe deferral
[    1.793405] mousedev: PS/2 mouse device common for all mice
[    1.805136] omap_rtc 44e3e000.rtc: rtc core: registered 44e3e000.rtc as rtc0
[    1.814772] i2c /dev entries driver
[    1.818987] Driver for 1-wire Dallas network protocol.
[    1.829864] omap_wdt: OMAP Watchdog Timer Rev 0x01: initial timeout 60 sec
[    1.841233] 48060000.mmc supply vmmc_aux not found, using dummy regulator
[    1.887886] 481d8000.mmc supply vmmc_aux not found, using dummy regulator
[    1.934922] mmc0: host does not support reading read-only switch. assuming write-enable.
[    1.947405] mmc0: new high speed SDHC card at address 1234
[    1.957402] mmcblk0: mmc0:1234 SA04G 3.63 GiB
[    1.969429]  mmcblk0: p1
[    1.977881] usbcore: registered new interface driver usbhid
[    1.983716] usbhid: USB HID core driver
[    1.993960] oprofile: using arm/armv7
[    1.998782] TCP: cubic registered
[    2.002257] Initializing XFRM netlink socket
[    2.006926] NET: Registered protocol family 17
[    2.011647] NET: Registered protocol family 15
[    2.016289] can: controller area network core (rev 20120528 abi 9)
[    2.022923] NET: Registered protocol family 29
[    2.027672] can: raw protocol (rev 20120528)
[    2.032220] can: broadcast manager protocol (rev 20120528 t)
[    2.038208] can: netlink gateway (rev 20130117) max_hops=1
[    2.044275] Key type dns_resolver registered
[    2.051942] ThumbEE CPU extension supported.
[    2.056460] Registering SWP/SWPB emulation handler
[    2.065636] regulator-dummy: disabling
[    2.071102] slave hdmi.6: could not get i2c
[    2.075620] platform hdmi.6: Driver slave requests probe deferral
[    2.100281] DCDC1: at 1500 mV
[    2.105669] vdd_mpu: 925 <--> 1325 mV at 1325 mV
[    2.112939] vdd_core: 925 <--> 1150 mV at 1100 mV
[    2.120463] LDO1: at 1800 mV
[    2.125679] LDO2: at 3300 mV
[    2.131583] LDO3: 1800 mV
[    2.136387] LDO4: at 3300 mV
[    2.139767] mmc1: BKOPS_EN bit is not set
[    2.146339] tps65217 0-0024: TPS65217 ID 0xe version 1.2
[    2.152172] omap_i2c 44e0b000.i2c: bus 0 rev0.11 at 400 kHz
[    2.172481] musb-hdrc musb-hdrc.1.auto: MUSB HDRC host driver
[    2.181944] musb-hdrc musb-hdrc.1.auto: new USB bus registered, assigned bus number 1
[    2.191917] usb usb1: New USB device found, idVendor=1d6b, idProduct=0002
[    2.199104] usb usb1: New USB device strings: Mfr=3, Product=2, SerialNumber=1
[    2.206647] usb usb1: Product: MUSB HDRC host driver
[    2.211861] usb usb1: Manufacturer: Linux 3.14.65 musb-hcd
[    2.217618] usb usb1: SerialNumber: musb-hdrc.1.auto
[    2.228386] hub 1-0:1.0: USB hub found
[    2.232915] hub 1-0:1.0: 1 port detected
[    2.259531] mmc1: new high speed MMC card at address 0001
[    2.267182] mmcblk1: mmc1:0001 P1XXXX 3.60 GiB
[    2.272381] mmcblk1boot0: mmc1:0001 P1XXXX partition 1 16.0 MiB
[    2.279715] mmcblk1boot1: mmc1:0001 P1XXXX partition 2 16.0 MiB
[    2.288486]  mmcblk1: p1
[    2.296296]  mmcblk1boot1: unknown partition table
[    2.305524]  mmcblk1boot0: unknown partition table
[    2.326947] davinci_mdio 4a101000.mdio: davinci mdio revision 1.6
[    2.333324] davinci_mdio 4a101000.mdio: detected phy mask fffffffe
[    2.345069] libphy: 4a101000.mdio: probed
[    2.349479] davinci_mdio 4a101000.mdio: phy[0]: device 4a101000.mdio:00, driver SMSC LAN8710/LAN8720
[    2.360749] Detected MACID = 60:64:05:6f:11:d3
[    2.370009] omap_rtc 44e3e000.rtc: setting system clock to 2000-01-01 00:00:00 UTC (946684800)
[    2.405603] EXT4-fs (mmcblk0p1): INFO: recovery required on readonly filesystem
[    2.413681] EXT4-fs (mmcblk0p1): write access will be enabled during recovery
[    4.779651] EXT4-fs (mmcblk0p1): recovery complete
[    4.872610] EXT4-fs (mmcblk0p1): mounted filesystem with ordered data mode. Opts: (null)
[    4.881290] VFS: Mounted root (ext4 filesystem) readonly on device 179:1.
[    4.889334] devtmpfs: mounted
[    4.893004] Freeing unused kernel memory: 380K (c0841000 - c08a0000)
INIT: version 2.88 booting
Starting udev
[    5.544882] udev[816]: starting version 164
[    9.753448] random: nonblocking pool is initialized
[   11.589554] EXT4-fs (mmcblk1p1): recovery complete
[   11.596411] EXT4-fs (mmcblk1p1): mounted filesystem with ordered data mode. Opts: (null)
Starting Bootlog daemon: bootlogd: cannot allocate pseudo tty: No such file or directory
bootlogd.
[   11.805793] EXT4-fs (mmcblk0p1): re-mounted. Opts: (null)
Configuring network interfaces... [   12.657083] net eth0: initializing cpsw version 1.12 (0)
[   12.737670] net eth0: phy found : id is : 0x7c0f1
[   12.742745] libphy: PHY 4a101000.mdio:01 not found
[   12.747800] net eth0: phy 4a101000.mdio:01 not found on slave 1
udhcpc (v1.20.2) started
Sending discover...
Sending discover...
Sending discover...
No lease, failing
done.
Mon Feb 17 19:03:00 UTC 2014
INIT: Entering runlevel: 5
Starting syslogd/klogd: done
****************************************************
****************************************************

Sitara Flash Fetcher Script - 07/28/2014


********************************************
Sitara Flash Fetcher is complete. Executing /home/root/debrick.sh.

Calling Script=/home/root/debrick.sh with SERVER_IP=
****************************************************
****************************************************

Sitara Example Flashing Script - 02/11/2014

1+0 records in
1+0 records out
DISK SIZe - 3867148288 bytes
eMMC 的 柱数 为 470
Found mounted partition(s) on  /dev/mmcblk1:  /media/mmcblk1p1
4k erase on /dev/mmcblk1p1
1+0 records in
1+0 records out
Partitioning the eMMC...
Checking that no-one is using this disk right now ...
[   23.073555]  mmcblk1: unknown partition table
OK

Disk /dev/mmcblk1: 470 cylinders, 255 heads, 63 sectors/track

sfdisk: ERROR: sector 0 does not have an msdos signature
sfdisk:  /dev/mmcblk1: unrecognized partition table type

Old situation:
sfdisk: No partitions found

New situation:
Units = cylinders of 8225280 bytes, blocks of 1024 bytes, counting from 0

   Device Boot Start     End   #cyls    #blocks   Id  System
/dev/mmcblk1p1   *      0+      8       9-     72261    c  W95 FAT32 (LBA)
/dev/mmcblk1p2         10     469     460    3694950   83  Linux
/dev/mmcblk1p3          0       -[   23.133758]  mmcblk1: p1 p2
       0          0    0  Empty
/dev/mmcblk1p4          0       -       0          0    0  Empty
Successfully wrote the new partition table

Re-reading the partition table ...

If you created or changed a DOS partition, /dev/foo7, say, then use dd(1)
to zero the first 512 bytes:  dd if=/dev/zero of=/dev/foo7 bs=512 count=1
(See fdisk(8).)
[   24.474768] EXT4-fs (mmcblk1p1): VFS: Can't find ext4 filesystem
[   24.487231] EXT3-fs (mmcblk1p1): error: can't find ext3 filesystem on dev mmcblk1p1.
[   24.495634] EXT4-fs (mmcblk1p2): VFS: Can't find ext4 filesystem
[   24.505576] EXT2-fs (mmcblk1p1): error: can't find an ext2 filesystem on dev mmcblk1p1.
[   24.516611] EXT3-fs (mmcblk1p2): error: can't find ext3 filesystem on dev mmcblk1p2.
[   24.528162] FAT-fs (mmcblk1p1): bogus number of reserved sectors
[   24.534459] FAT-fs (mmcblk1p1): Can't find a valid FAT filesystem
[   24.542972] EXT2-fs (mmcblk1p2): error: can't find an ext2 filesystem on dev mmcblk1p2.
[   24.558440] FAT-fs (mmcblk1p2): bogus number of reserved sectors
[   24.564736] FAT-fs (mmcblk1p2): Can't find a valid FAT filesystem
[   24.606737] cramfs: wrong magic
[   24.619648] FAT-fs (mmcblk1p1): bogus number of reserved sectors
[   24.625948] FAT-fs (mmcblk1p1): Can't find a valid FAT filesystem
[   24.646475] cramfs: wrong magic
[   24.651854] FAT-fs (mmcblk1p2): bogus number of reserved sectors
[   24.658326] FAT-fs (mmcblk1p2): Can't find a valid FAT filesystem
No partition found. Continuing.
1+0 records in
1+0 records out
Formatting the eMMC into 2 partitions...
mkfs.vfat 2.11 (12 Mar 2005)
mke2fs 1.42.1 (17-Feb-2012)
Discarding device blocks: done
Filesystem label=rootfs
OS type: Linux
Block size=4096 (log=2)
Fragment size=4096 (log=2)
Stride=0 blocks, Stripe width=0 blocks
231072 inodes, 923737 blocks
46186 blocks (5.00%) reserved for the super user
First data block=0
Maximum filesystem blocks=947912704
29 block groups
32768 blocks per group, 32768 fragments per group
7968 inodes per group
Superblock backups stored on blocks:
        32768, 98304, 163840, 229376, 294912, 819200, 884736

Allocating group tables: done
Writing inode tables: done
Creating journal (16384 blocks): done
Writing superblocks and filesystem accounting information: done

Formatting done.
mkdir: can't create directory 'tmp_boot': File exists
mkdir: can't create directory 'tmp_rootfs': File exists
[   38.648936] kjournald starting.  Commit interval 5 seconds
[   38.657899] EXT3-fs (mmcblk1p2): using internal journal
[   38.663377] EXT3-fs (mmcblk1p2): mounted filesystem with ordered data mode
Copying Files...
real    0m 0.88s
user    0m 0.40s
sys     0m 0.41s
Boot partition done.
real    0m 2.14s
user    0m 1.01s
sys     0m 1.03s
RootFS partition done.
It took 22 seconds to complete this task...

********************************************
Sitara Example Flash Script is complete.

Stopping Bootlog daemon: bootlogd.

 _____                    _____           _         _
|  _  |___ ___ ___ ___   |  _  |___ ___  |_|___ ___| |_
|     |  _| .'| . | . |  |   __|  _| . | | | -_|  _|  _|
|__|__|_| |__,|_  |___|  |__|  |_| |___|_| |___|___|_|
              |___|                    |___|

Arago Project http://arago-project.org am335x-evm ttyO0

Arago 2013.05 am335x-evm ttyO0

am335x-evm login: root
root@am335x-evm:~#

找到原因之后才想起来之前有一次将ti提供的SDk里的uImage,和设备树替换了我之前编译的uImage和设备树。导致了SD卡不能烧写eMMC,和卡死在Starting kernel ...的问题。

至于为什么用Ti的SDK里的内核编译的uImage和dtb怎么不行,后续在研究研究,估计内核有什么没有配置。

 

 

 

续昨天的  “”“用Ti的SDK里的内核编译的uImage和dtb怎么不行”

今天找到了为什么用Ti SDk的编译的内核和Dtb怎么不行了。

之前估计要用到EMMC的引脚与其他的功能冲突了,所以我把Ti_SDK里的Dtb(am335x-bone-common.dtsi)里边关于emmc的引脚配置给注释掉了,所以导致用Ti——SDK的内核编译的DTB没有支持eMMC,所以利用TiSDK编译的内核和设备树就不能识别eMMC了。最终SD卡里的脚本也不会对eMMC分区了。

posted @ 2019-09-05 16:36  竹主  阅读(1803)  评论(0编辑  收藏  举报