Die U-Boot Patch Serie muss um den folgenden Patch erweitert werden.

Debug output U-Boot TQMa28

debug-outputs.patch
debug outputs
 
From: Michael Krummsdorf <michael.krummsdorf@tq-group.com>
 
Signed-off-by: Michael Krummsdorf <michael.krummsdorf@tq-group.com>
---
 arch/arm/Makefile                  |    2 +-
 configs/tqma28_mba28_mmc_defconfig |    1 -
 include/common.h                   |    2 ++
 include/configs/mxs.h              |    1 +
 include/configs/tqma28.h           |    1 +
 5 files changed, 5 insertions(+), 2 deletions(-)
 
diff --git a/arch/arm/Makefile b/arch/arm/Makefile
index 6f30098..a4fd026 100644
--- a/arch/arm/Makefile
+++ b/arch/arm/Makefile
@@ -78,7 +78,7 @@ libs-y += arch/arm/cpu/
 libs-y += arch/arm/lib/
 
 ifeq ($(CONFIG_SPL_BUILD),y)
-ifneq (,$(CONFIG_MX23)$(CONFIG_MX35)$(filter $(SOC), mx25 mx27 mx5 mx6 mx31 mx35))
+ifneq (,$(CONFIG_MX23)$(CONFIG_MX35)$(filter $(SOC), mx25 mx27 mx5 mx6 mx31 mx35 mxs))
 libs-y += arch/arm/imx-common/
 endif
 else
diff --git a/configs/tqma28_mba28_mmc_defconfig b/configs/tqma28_mba28_mmc_defconfig
index 9ad43e5..e4f4612 100644
--- a/configs/tqma28_mba28_mmc_defconfig
+++ b/configs/tqma28_mba28_mmc_defconfig
@@ -3,6 +3,5 @@ CONFIG_TARGET_TQMA28=y
 CONFIG_TQMA28_128MB=y
 CONFIG_TQMA28_MBA28=y
 CONFIG_SPL=y
-CONFIG_SYS_EXTRA_OPTIONS="MXS_AUART,MXS_AUART_BASE=MXS_UARTAPP3_BASE"
 # CONFIG_CMD_IMLS is not set
 CONFIG_SPI_FLASH=y
diff --git a/include/common.h b/include/common.h
index 8f4b2ec..aef176c 100644
--- a/include/common.h
+++ b/include/common.h
@@ -88,6 +88,8 @@ typedef volatile unsigned char	vu_char;
 #define CONFIG_SYS_SUPPORT_64BIT_DATA
 #endif
 
+#define DEBUG
+
 #ifdef DEBUG
 #define _DEBUG	1
 #else
diff --git a/include/configs/mxs.h b/include/configs/mxs.h
index 38b1e93..96ff522 100644
--- a/include/configs/mxs.h
+++ b/include/configs/mxs.h
@@ -56,6 +56,7 @@
 #define CONFIG_SPL_LIBCOMMON_SUPPORT
 #define CONFIG_SPL_LIBGENERIC_SUPPORT
 #define CONFIG_SPL_GPIO_SUPPORT
+#define CONFIG_SPL_SERIAL_SUPPORT
 
 /* Memory sizes */
 #define CONFIG_SYS_MALLOC_LEN		0x00400000	/* 4 MB for malloc */
diff --git a/include/configs/tqma28.h b/include/configs/tqma28.h
index e723cb0..a165500 100644
--- a/include/configs/tqma28.h
+++ b/include/configs/tqma28.h
@@ -111,6 +111,7 @@ extern unsigned tqma28_get_env_dev(void);
 
 /* Serial Driver */
 #define CONFIG_SYS_LINUX_CONSOLE	ttyAPP3
+#define CONFIG_SPL_SERIAL_SUPPORT
 
 /* FEC Ethernet on SoC */
 #ifdef	CONFIG_CMD_NET

Wenn oben genannte Patch angewendet wird, erfolgen die Ausgaben nur über die Debug UART


Falls man eine SD Karte ohne PTXdist erstellen möchte muss man darauf achten das U-Boot nicht mittels dd auf die SD Karte gespielt werden kann. Es muss das Tool sdimage verwendet werden das Teil der mxs-utils ist.
http://www.pengutronix.de/software/mxs-utils/download/mxs-utils-2011.08.0.tar.bz2

  1. mxs-utils downloaden und entpacken
  2. Console öffnen und in mxs-utils Ordner wechseln
  3. ./configure ausführen
  4. make ausführen
  5. die ausführbare Datei ist dann im mxs-utils Ordner unter /bin verfügbar
  6. die SD Karte mit fdisk wie folgt partitionieren :
  • p
  • d
  • 4
  • d
  • 3
  • d
  • 2
  • d
  • 1
  • n
  • p
  • 1
  • 16384
  • 32767
  • n
  • p
  • 2
  • 32768
  • 49151
  • n
  • p
  • 3
  • 49152
  • 180223
  • t
  • 1
  • 53
  • a
  • 1
  • p
  • w

7. der U-Boot kann nun mit dem Tool wie folgt aufgespielt werden

 <code>./sdimage -f u-boot_elcore.sb -d /dev/sdd</code>

1. print boot_ssp
2. mmc read $fdtaddr 3000 1000
3. fdt addr $fdtaddr
4. fdt list /


  • mii info

probt alle möglichen PHY-Adressen (0-31) durch und meldet zurück auf welcher Adresse welcher PHY (OUI, Model, etc.) geantwortet hat

  • ping (bzw. alle „Netzwerk-Befehle“)

die Zuordnung FECx ⇔ PHY (bzw. PHY-Adresse) ist über die Aufrufparameter der Funktion fecmxc_initialize_multi im jeweiligen Boardfile abgebildet/definiert

board/tqc/tqma28/tqma28.c:

/* Reset FEC PHYs */
	gpio_direction_output(MX28_PAD_ENET0_RX_CLK__GPIO_4_13, 1);
	udelay(50);
	gpio_set_value(MX28_PAD_ENET0_RX_CLK__GPIO_4_13, 0);
	udelay(200);
	gpio_set_value(MX28_PAD_ENET0_RX_CLK__GPIO_4_13, 1);

	ret = fecmxc_initialize_multi(bis, 1, 0, MXS_ENET0_BASE);
	if (ret) {
		puts("FEC MXS: Unable to init FEC0\n");
		return ret;
	}

	ret = fecmxc_initialize_multi(bis, 0, 3, MXS_ENET1_BASE);
	if (ret) {
		puts("FEC MXS: Unable to init FEC1\n");
		return ret;
	}

Die erste Zahl ist das Interface an dem der PHY angeschlossen ist, die markierte Zahl ist die PHY-Adresse.

1. i2c dev 1 2. TQMa28 U-Boot > i2c md 0x50 0.2 0x100

i2c mw 0x50 0.2 0xff

Disclaimer
TQ-Systems GmbH provides the Board Support Packages (BSP) free of charge. The software included in the shipment has been configured individually for the starter kits. The software is only intended to evaluate the module. The use of the Board Support Packages (BSP) is only allowed within the scope of functionality described by TQ-Systems GmbH. TQ-Systems GmbH does not accept any liability for all further changes of the Board Support Package and for any damage resulting from its use.