On Fri, 1 Nov 2019 07:12:23 -0700 (PDT), in
gmane.comp.hardware.beagleboard.user Michael B
<mike-NEI+xi/[email protected]> wrote:
>Here is the output when:
>- SD inserted
>- Boot/User button pressed (It looks like it is being ignored)
>
Run a difference utility on the two captures -- you'll see the
effect... (My comments will be within -=-=-=- markers)
*** NoSDboot.txt 2019-11-01T12:53:31.659110-04:00
--- SDboot.txt 2019-11-01T12:53:14.644068-04:00
***************
*** 35,41 ****
Press SPACE to abort autoboot in 2 seconds
! Card did not respond to voltage select!
-=-=-=-
Newer u-Boot is configuted to test for an SD card without needing the
boot-select held -- "newer" being anything later than early Debian Wheezy
releases).
No card, so no response
-=-=-=-
gpio: pin 56 (gpio 56) value is 0
--- 33,43 ----
Press SPACE to abort autoboot in 2 seconds
! switch to partitions #0, OK
!
! mmc0 is current device
!
! Scanning mmc 0:1...
gpio: pin 56 (gpio 56) value is 0
***************
*** 45,53 ****
gpio: pin 53 (gpio 53) value is 1
! Card did not respond to voltage select!
!
! Card did not respond to voltage select!
switch to partitions #0, OK
--- 47,77 ----
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 ...
!
! Checking for: /boot.scr ...
!
! Checking for: /boot/boot.scr ...
!
! Checking for: /boot/uEnv.txt ...
-=-=-=-
Card was found, scan for boot scripts
Not sure where the additional partitions are being found
-=-=-=-
!
! ** Invalid partition 2 **
!
! ** Invalid partition 3 **
!
! ** Invalid partition 4 **
!
! ** Invalid partition 5 **
!
! ** Invalid partition 6 **
!
! ** Invalid partition 7 **
switch to partitions #0, OK
-=-=-=-
Somehow I get the feeling the SD card file system isn't matching what
is expected since the next line for both boots is:
mmc1(part 0) is current device
and that is the eMMC -- SD card should be mmc0
debian@beaglebone:~$ sudo fdisk -l
Disk /dev/mmcblk0: 7.4 GiB, 7948206080 bytes, 15523840 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disklabel type: dos
Disk identifier: 0xff75101f
Device Boot Start End Sectors Size Id Type
/dev/mmcblk0p1 * 8192 15523839 15515648 7.4G 83 Linux
***** note that there is only one partition on the SD card
Disk /dev/mmcblk1: 3.7 GiB, 3925868544 bytes, 7667712 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disklabel type: dos
Disk identifier: 0xcbee9899
Device Boot Start End Sectors Size Id Type
/dev/mmcblk1p1 * 8192 7667711 7659520 3.7G 83 Linux
Disk /dev/mmcblk1boot1: 1 MiB, 1048576 bytes, 2048 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk /dev/mmcblk1boot0: 1 MiB, 1048576 bytes, 2048 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
debian@beaglebone:~$
-=-=-=-
***************
*** 171,422 ****
[ 0.000000] IRQ: Found an INTC at 0xfa200000 (revision 5.0) with 128
interrupts
[ 0.000000] OMAP clockevent source: timer2 at 24000000 Hz
-=-=-=-
Unfortunately, the time stamps result in all of these being flagged as
different. I'll have to view a side-by-side diff to see actual changes and
flags (*** and ---) won't have line number ranges.
-=-=-=-
<SNIP>
***
! [ 3.052014] omap_hsmmc 48060000.mmc: Got CD GPIO
! [ 3.151034] hidraw: raw HID events driver (C) Jiri Kosina
---
! [ 3.051685] omap_hsmmc 48060000.mmc: Got CD GPIO
! [ 3.137721] mmc0: host does not support reading read-only switch,
! assuming write-enable
! [ 3.148850] mmc0: new high speed SDHC card at address 8fe4
! [ 3.155834] hidraw: raw HID events driver (C) Jiri Kosina
-=-=-=-
SD card boot knows there is an SD card inserted
-=-=-=-
***
! [ 3.201874] mmc1: new high speed MMC card at address 0001
! [ 3.209229] NET: Registered protocol family 10
! [ 3.214623] mmcblk0: mmc1:0001 Q2J54A 3.64 GiB
-=-=-=-
This is confusing... It looks like the NoSD card boot is mapping eMMC
(mmc1) to the mmcblk0 device, which is normally the SD card.
I have vague memories that there was period of time when the boot
sequence tried to map the boot device as mmc0 and the other device as mmc1;
perhaps your u-Boot is from that period.
-=-=-=-
---
! [ 3.162420] mmcblk0: mmc0:8fe4 SU08G 7.40 GiB
***
! [ 3.220572] mip6: Mobile IPv6
! [ 3.223991] NET: Registered protocol family 17
! [ 3.228536] mmcblk0boot0: mmc1:0001 Q2J54A partition 1 2.00 MiB
! [ 3.234764] Key type dns_resolver registered
! [ 3.239394] mmcblk0boot1: mmc1:0001 Q2J54A partition 2 2.00 MiB
-=-=-=-
Along with mapping the eMMC boot partitions as mmcblk0 devices
-=-=-=-
---
! [ 3.298266] mmc1: new high speed MMC card at address 0001
! [ 3.309703] mmcblk1: mmc1:0001 Q2J54A 3.64 GiB
! [ 3.318379] Key type encrypted registered
! [ 3.322659] mmcblk1boot0: mmc1:0001 Q2J54A partition 1 2.00 MiB
! [ 3.331473] input: tps65217_pwr_but as
! /devices/platform/ocp/44e0b000.i2c/i2c-0/0-0024/input/input0
! [ 3.341141] mmcblk1boot1: mmc1:0001 Q2J54A partition 2 2.00 MiB
***************
*** 439,483 ****
Checking for Valid bbgw-eeprom header
Valid bbgw-eeprom header found [335]
-----------------------------
! copying: [/dev/mmcblk0] -> [/dev/mmcblk1]
lsblk:
NAME MAJ:MIN RM SIZE RO TYPE MOUNTPOINT
! mmcblk0boot0 179:8 0 2M 1 disk
! mmcblk0boot1 179:16 0 2M 1 disk
! mmcblk0 179:0 0 3.7G 0 disk
! `-mmcblk0p1 179:1 0 3.7G 0 part /
-----------------------------
df -h | grep rootfs:
-----------------------------
! Error: [/dev/mmcblk1] does not exist
! writing to [/dev/mmcblk1] failed...
-=-=-=-
Given that it earlier assigned mmc1 to mmcblk0, and has no mmcblk1
device, no surprise the noSD version now is doing something weird...
-=-=-=-
---
Checking for Valid bbgw-eeprom header
Valid bbgw-eeprom header found [335]
-----------------------------
! copying: [/dev/mmcblk1] -> [/dev/mmcblk0]
lsblk:
NAME MAJ:MIN RM SIZE RO TYPE MOUNTPOINT
! mmcblk1boot0 179:16 0 2M 1 disk
! mmcblk1boot1 179:24 0 2M 1 disk
! mmcblk0 179:0 0 7.4G 0 disk
! `-mmcblk0p1 179:1 0 7.4G 0 part
! mmcblk1 179:8 0 3.7G 0 disk
! `-mmcblk1p1 179:9 0 3.7G 0 part /
-=-=-=-
SD card is properly assigned as mmcblk0, eMMC is mmcblk1 -- BUT THE
COPY is going in the wrong direction!
-=-=-=-
df -h | grep rootfs:
-----------------------------
! Erasing: /dev/mmcblk0
! 108+0 records in
! 108+0 records out
! 113246208 bytes (113 MB) copied, 9.71981 s, 11.7 MB/s
! [ 20.645095] random: nonblocking pool is initialized
! 108+0 records in
! 108+0 records out
! 113246208 bytes (113 MB) copied, 5.45552 s, 20.8 MB/s
! Erasing: /dev/mmcblk0 complete
! -----------------------------
! Writing bootloader to [/dev/mmcblk0]
! dd if=/opt/backup/uboot/MLO of=/dev/mmcblk0 count=1 seek=1 conv=notrunc
! bs=128k
! -----------------------------
! 0+1 records in
! 0+1 records out
! 65764 bytes (66 kB) copied, 0.0113357 s, 5.8 MB/s
! -----------------------------
! dd if=/opt/backup/uboot/u-boot.img of=/dev/mmcblk0 count=2 seek=1
! conv=notrunc bs=384k
! -----------------------------
! 0+1 records in
! 0+1 records out
! 350196 bytes (350 kB) copied, 0.0682698 s, 5.1 MB/s
! -----------------------------
! Formatting: /dev/mmcblk0
! sfdisk: [sfdisk from util-linux 2.25.2]
! sfdisk: [sfdisk --force --Linux --in-order --unit M /dev/mmcblk0]
! sfdisk: [1,,L,*]
! sfdisk: Checking that no-one is using this disk right now ...
! sfdisk: OK
!
! Disk /dev/mmcblk0: 242560 cylinders, 4 heads, 16 sectors/track
! sfdisk: /dev/mmcblk0: unrecognized partition tabl[ 26.238302] mmcblk0:
! p1
! e type
! Old situation:
! sfdisk: No partitions found
! New situation:
! Units: 1MiB = 1024*1024 bytes, blocks of 1024 bytes, counting from 0
!
! Device Boot Start End MiB #blocks Id System
! /dev/mmcblk0p1 * 1 7579 7579 7760896 83 Linux
! /dev/mmcblk0p2 0 - 0 0 0 Empty
! /dev/mmcblk0p3 0 - 0 0 0 Empty
! /dev/mmcblk0p4 0 - 0 0 0 Empty
! Successfully wrote the new partition table
!
! Re-reading the partition table ...
!
! sfdisk: 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).)
! mkfs.ext4 /dev/mmcblk0p1 -L BOOT
! -----------------------------
! mke2fs 1.43 (17-May-2016)
! Discarding device blocks: 4096/1940224
! 528384/1940224 1052672/1940224 1576960/1940224
! done
! Creating filesystem with 1940224 4k blocks and 485760 inodes
! Filesystem UUID: d5999751-931a-416f-9aaa-7f507927b188
! Superblock backups stored on blocks:
! 32768, 98304, 163840, 229376, 294912, 819200, 884736, 1605632
!
! Allocating group tables: 0/60 done !
! Writing inode tables: 0/60 done ! Creating journal (32768
blocks): done
! Writing superblocks and filesystem accounting information: 0/60 !
done
!
! -----------------------------
! Formatting: /dev/mmcblk0 complete
! -----------------------------
! Copying: /dev/mmcblk1p1 -> /dev/mmcblk0p1
! [ 53.013428] EXT4-fs (mmcblk0p1): mounted filesystem with ordered data
! mode. Opts: (null)
! rsync: / -> /tmp/rootfs/
! Copying: Kernel modules
! rsync: /lib/modules/4.4.9-ti-r25/ ->
/tmp/rootfs/lib/modules/4.4.9-ti-r25/
! Copying: /dev/mmcblk1p1 -> /dev/mmcblk0p1 complete
! -----------------------------
! Final System Tweaks:
! UUID=d5999751-931a-416f-9aaa-7f507927b188
! Generating: /etc/fstab
! # /etc/fstab: static file system information.
! #
! UUID=d5999751-931a-416f-9aaa-7f507927b188 / ext4
! noatime,errors=remount-ro 0 1
! debugfs /sys/kernel/debug debugfs defaults 0 0
! /boot/uEnv.txt: disabling eMMC flasher script
-=-=-=-
And here it has copied the eMMC to the SD card, and turned off the
flasher line in the copy.
Somehow I think you'll have to study u-Boot command line mode to wipe
out the eMMC contents so that there is no eMMC u-Boot around to do games
with device 0 vs 1, or at the least, somehow copy a non-flasher
/boot/uEnv.txt to the eMMC.
--
Dennis L Bieber
--
For more options, visit http://beagleboard.org/discuss
---
You received this message because you are subscribed to the Google Groups
"BeagleBoard" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/beagleboard/esoore985j29tbgqk32aksnk3svqmusolo%404ax.com.