mail archive of the barebox mailing list
 help / color / mirror / Atom feed
From: Anand Gadiyar <gadiyar@ti.com>
To: barebox@lists.infradead.org
Cc: Anand Gadiyar <gadiyar@ti.com>
Subject: [PATCH 1/4] panda: fix crash when not using barebox as second stage
Date: Mon, 21 May 2012 16:00:10 +0530	[thread overview]
Message-ID: <1337596213-15239-2-git-send-email-gadiyar@ti.com> (raw)
In-Reply-To: <1337596213-15239-1-git-send-email-gadiyar@ti.com>

If barebox is not used as the MLO, then it crashes during boot
with the below error message:

Board: Texas Instrument's Panda
PandaBoard Revision: 003
omap-hsmmc@mci0: registered as mci0
unable to handle paging request at address 0x4a064010
pc : [<8f01e820>]    lr : [<8f0049a0>]
sp : 8cffff80  ip : 00000016  fp : 00100103
r10: 00000000  r9 : 00000ae7  r8 : 4030b76c
r7 : 40300200  r6 : e28f8028  r5 : 0000003e  r4 : 00000000
r3 : 4a064000  r2 : 00000014  r1 : 00000001  r0 : 00000001
Flags: nzCv  IRQs off  FIQs off  Mode SVC_32
[<8f01e820>] (panda_devices_init+0x17c/0x1e0) from [<8f006300>] (start_barebox+0x18/0x10c)
[<8f006300>] (start_barebox+0x18/0x10c) from [<8200006c>] (0x8200006c)

[<8f021248>] (unwind_backtrace+0x0/0x98) from [<8f011a00>] (panic+0x28/0x3c)
[<8f011a00>] (panic+0x28/0x3c) from [<8f02171c>] (do_exception+0x10/0x14)
[<8f02171c>] (do_exception+0x10/0x14) from [<8f021784>] (do_data_abort+0x2c/0x38)
[<8f021784>] (do_data_abort+0x2c/0x38) from [<8f021470>] (data_abort+0x50/0x60)

This is because the USBHOST module is not enabled. The module enable
is is normally done in mach-omap/xload.c which never gets called.

Since we're configuring the USBHOST CLKCTRL register in the board file
anyway, we might as well explicitly enable the module in the same place.

Signed-off-by: Anand Gadiyar <gadiyar@ti.com>
---
Steps to reproduce:
Download and build usbboot from here:
git://git.omapzoom.org/repo/omapboot.git

Check out and build the p-master branch.
  make ARCH=omap4 BOARD=panda

Then you can do a USB boot using
usbboot barebox.bin

 arch/arm/boards/panda/board.c |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)

diff --git a/arch/arm/boards/panda/board.c b/arch/arm/boards/panda/board.c
index 628d3f1..26d365c 100644
--- a/arch/arm/boards/panda/board.c
+++ b/arch/arm/boards/panda/board.c
@@ -78,6 +78,7 @@ static void panda_ehci_init(void)
 	gpio_set_value(hub_nreset, 1);
 	val = readl(0x4a009358);
 	val |= (1 << 24);
+	val |= 0x2;
 	writel(val, 0x4a009358);
 	writel(0x7, 0x4a008180);
 	mdelay(10);
-- 
1.7.1


_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox

  reply	other threads:[~2012-05-21 10:30 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-05-21 10:30 [PATCH 0/4] panda: misc patches Anand Gadiyar
2012-05-21 10:30 ` Anand Gadiyar [this message]
2012-05-21 10:30 ` [PATCH 2/4] panda: add i2c and twlcore to panda Anand Gadiyar
2012-05-21 10:30 ` [PATCH 3/4] panda: add LED support Anand Gadiyar
2012-05-21 10:30 ` [PATCH 4/4] panda: update defconfig for i2c and led support Anand Gadiyar
2012-05-21 19:42 ` [PATCH 0/4] panda: misc patches Sascha Hauer

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1337596213-15239-2-git-send-email-gadiyar@ti.com \
    --to=gadiyar@ti.com \
    --cc=barebox@lists.infradead.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox