Open main menu

DAVE Developer's Wiki β

Physical devices mapping (BELK/BXELK)

Revision as of 10:39, 20 December 2016 by U0004 (talk | contribs) (Created page with "{{InfoBoxTop}} {{Applies To BoraX}} {{InfoBoxBottom}} This article details how physical devices are handled by the Linux kernel in the context of the BoraX_Embedded_Linux_Ki...")

(diff) ← Older revision | Approved revision (diff) | Latest revision (diff) | Newer revision → (diff)
Info Box
BORA Xpress.png Applies to BORA Xpress

This article details how physical devices are handled by the Linux kernel in the context of the BXELK kit.

Contents

Console UARTEdit

Physical device Processor's resource Connector Type Linux device file Notes
Boot Console UART1 J17 2-wire RS232 UART /dev/ttyPS0

EthernetEdit

Ethernet port is associated to eth0 interface. It can be managed with standard Linux commands. See for example http://www.tecmint.com/ifconfig-command-examples/.

microSD cardEdit

microSD card, if present, will be associated by the Linux kernel to the mmcblk0 device:

[   24.100643] mmc0: new high speed SDHC card at address 1234
[   24.106544] mmcblk0: mmc0:1234 SA16G 14.6 GiB
[   24.113268]  mmcblk0: p1 p2

Once detected, it can be mounted and accessed via usual Linux commands:

root@bora:~# mount /dev/mmcblk0p1 /mnt/mmcblk0p1/
root@bora:~# time cp LibreOffice_4.1.1_Win_x86.msi /mnt/mmcblk0p1/

real    0m39.971s
user    0m0.080s
sys     0m4.120s
root@bora:~# ls -la /mnt/mmcblk0p1/LibreOffice_4.1.1_Win_x86.msi
-rwxr-xr-x    1 root     root     215056384 Nov 15 15:57 /mnt/mmcblk0p1/LibreOffice_4.1.1_Win_x86.msi
root@bora:~# umount /mnt/mmcblk0p1/
root@bora:~#

NOR and NAND flashEdit

TBD (NOR cannot be used in Linux)

NOR and NAND flashes are managed as MTD devices.

Generally speaking, NAND flash memory is partitons are defined in the devitetree:

	partition@nand-partition-table {
		label = "nand-SPL";
		reg = <0x0 0x80000>;
	};
	partition@nand-uboot {
		label = "nand-uboot";
		reg = <0x80000 0x80000>;
	};
	partition@nand-uboot-env1 {
		label = "nand-uboot-env1";
		reg = <0x100000 0x40000>;
	};
	partition@nand-uboot-env2 {
		label = "nand-uboot-env2";
		reg = <0x140000 0x40000>;
	};
	partition@nand-bitstream {
		label = "nand-bitstream";
		reg = <0x180000 0x440000>;
	};
	partition@nand-device-tree {
		label = "nand-device-tree";
		reg = <0x5C0000 0x40000>;
	};
	partition@nand-linux {
		label = "nand-linux";
		reg = <0x600000 0x400000>;
	};
	partition@nand-rootfs {
		label = "nand-rootfs";
		reg = <0xA00000 0x1F600000>;
	};

defines these partitions:

root@bora:~# cat /proc/mtd
dev:    size   erasesize  name
mtd0: 00080000 00020000 "nand-SPL"
mtd1: 00080000 00020000 "nand-uboot"
mtd2: 00040000 00020000 "nand-uboot-env1"
mtd3: 00040000 00020000 "nand-uboot-env2"
mtd4: 00440000 00020000 "nand-bitstream"
mtd5: 00040000 00020000 "nand-device-tree"
mtd6: 00400000 00020000 "nand-linux"
mtd7: 1f600000 00020000 "nand-rootfs"