Re: [PATCH] MUSB: Populate the VBUS GPIO with the correct GPIO number.

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hello.

Swaminathan S wrote:

Signed-off-by: Swaminathan S <swami.iyer@xxxxxx>

Does fix MUSB for me in the linux-davinci tree. Linus' tree crashes this way:

<6>usbcore: registered new interface driver usbfs
<6>usbcore: registered new interface driver hub
<6>usbcore: registered new device driver usb
<6>pcf857x 1-0038: gpios 104..111 on a pcf8574
<6>pcf857x 1-0039: gpios 112..119 on a pcf8574
<6>pcf857x 1-003a: gpios 120..127 on a pcf8574
<7>Switched to high resolution mode on CPU 0
<6>musb_hdrc: version 6.0, pio, host, debug=0
<1>Unable to handle kernel NULL pointer dereference at virtual address 0000002c
<1>pgd = c0004000
<1>[0000002c] *pgd=00000000
Internal error: Oops: 5 [#1] PREEMPT
<d>Modules linked in:
CPU: 0    Not tainted  (2.6.31-rc8-00015-gadda766-dirty #9)
PC is at gpio_set_value_cansleep+0x20/0x40
LR is at davinci_source_power+0x4c/0x7c
pc : [<c0149c60>]    lr : [<c01941c4>]    psr: 20000013
sp : cf823e18  ip : 00000090  fp : 00000000
r10: c02e6ca0  r9 : c02e6c78  r8 : c02f7f58
r7 : 00147900  r6 : fec64000  r5 : cf8488d8  r4 : 00000000
r3 : 00000000  r2 : 00000001  r1 : 00000001  r0 : 000006c0
Flags: nzCv  IRQs on  FIQs on  Mode SVC_32  ISA ARM  Segment kernel
Control: 0005317f  Table: 80004000  DAC: 00000017
Process swapper (pid: 1, stack limit = 0xcf822270)
Stack: (0xcf823e18 to 0xcf824000)
3e00:                                                       fec64000 c01941c4
3e20: cf8488d8 c00191a0 c02f8d8c c02e6d50 cf8488d8 00000000 00000000 c001883c
3e40: cf822000 00000000 cf856320 00000002 cf822000 c0314a5c c02e6c98 0000000c
3e60: fec64000 00000000 000000d0 cf806850 00000000 c013d528 cf823ecc cf802780
3e80: 00000000 c02289f0 00000000 00000000 00000000 c00d3b68 00000000 cf823eb0
3ea0: cf823eb4 c00d33b8 cf8616c0 cf865a50 cf823ee0 c00d37cc cf865a50 00000000
3ec0: cf865a50 cf823ee0 cf8616c0 00000001 00000001 00000000 00000000 c00d48c4
3ee0: cf8616c0 00000000 00000000 c02e6ca0 c02e6cd4 c02f8d8c c02f8d8c c02f7f58
3f00: 00000001 00000000 00000000 c0178154 c02f8d8c c0177258 00000000 c02e6ca0
3f20: c02e6cd4 c02f8d8c c02f8d8c c0177370 00000000 cf823f40 c0177310 c017672c
3f40: cf8045b8 cf8633f0 c02f8d8c c001e910 c02f8d8c cf894b40 00000000 c0176cdc
3f60: c023c1a8 00000000 00000000 c001e910 c02f8d8c 00000000 00000000 c02fe8a0
3f80: c001847c c0177740 00000000 c001e910 c02f8d70 00000000 00000000 c02fe8a0
3fa0: c001847c c0178388 c001e910 c001eac4 00000000 c0025314 00000000 00000000
3fc0: 00000000 000000a8 c001e910 c001eac4 00000000 00000000 00000000 00000000
3fe0: 00000000 c0008890 00000000 00000000 00000000 c002680c ffffffff ffffffff
[<c0149c60>] (gpio_set_value_cansleep+0x20/0x40) from [<c01941c4>] (davinci_source_power+0x4c/0x7c) [<c01941c4>] (davinci_source_power+0x4c/0x7c) from [<c00191a0>] (musb_platform_init+0x7c/0x154) [<c00191a0>] (musb_platform_init+0x7c/0x154) from [<c001883c>] (musb_probe+0x208/0xaf0) [<c001883c>] (musb_probe+0x208/0xaf0) from [<c0178154>] (platform_drv_probe+0x1c/0x24) [<c0178154>] (platform_drv_probe+0x1c/0x24) from [<c0177258>] (driver_probe_device+0xac/0x164) [<c0177258>] (driver_probe_device+0xac/0x164) from [<c0177370>] (__driver_attach+0x60/0x84) [<c0177370>] (__driver_attach+0x60/0x84) from [<c017672c>] (bus_for_each_dev+0x4c/0x80) [<c017672c>] (bus_for_each_dev+0x4c/0x80) from [<c0176cdc>] (bus_add_driver+0x9c/0x220) [<c0176cdc>] (bus_add_driver+0x9c/0x220) from [<c0177740>] (driver_register+0xac/0x13c) [<c0177740>] (driver_register+0xac/0x13c) from [<c0178388>] (platform_driver_probe+0x10/0x8c) [<c0178388>] (platform_driver_probe+0x10/0x8c) from [<c0025314>] (do_one_initcall+0x54/0x194) [<c0025314>] (do_one_initcall+0x54/0x194) from [<c0008890>] (kernel_init+0x94/0x10c) [<c0008890>] (kernel_init+0x94/0x10c) from [<c002680c>] (kernel_thread_exit+0x0/0x8)
Code: e59f3024 e1a02001 e7903003 e24dd004 (e593102c)
<4>---[ end trace 1b75b31a2719ed1c ]---
<0>Kernel panic - not syncing: Attempted to kill init!
[<c002a5f8>] (unwind_backtrace+0x0/0xdc) from [<c00391ac>] (panic+0x4c/0x11c)
[<c00391ac>] (panic+0x4c/0x11c) from [<c003bf84>] (do_exit+0x5c/0x620)
[<c003bf84>] (do_exit+0x5c/0x620) from [<c00294bc>] (die+0x158/0x178)
[<c00294bc>] (die+0x158/0x178) from [<c002b58c>] (__do_kernel_fault+0x68/0x80)
[<c002b58c>] (__do_kernel_fault+0x68/0x80) from [<c002b7c0>] (do_page_fault+0x21c/0x23c) [<c002b7c0>] (do_page_fault+0x21c/0x23c) from [<c0025258>] (do_DataAbort+0x34/0x98)
[<c0025258>] (do_DataAbort+0x34/0x98) from [<c00259cc>] (__dabt_svc+0x4c/0x60)
Exception stack(0xcf823dd0 to 0xcf823e18)
3dc0:                                     000006c0 00000001 00000001 00000000
3de0: 00000000 cf8488d8 fec64000 00147900 c02f7f58 c02e6c78 c02e6ca0 00000000
3e00: 00000090 cf823e18 c01941c4 c0149c60 20000013 ffffffff
[<c00259cc>] (__dabt_svc+0x4c/0x60) from [<c0149c60>] (gpio_set_value_cansleep+0x20/0x40) [<c0149c60>] (gpio_set_value_cansleep+0x20/0x40) from [<c01941c4>] (davinci_source_power+0x4c/0x7c) [<c01941c4>] (davinci_source_power+0x4c/0x7c) from [<c00191a0>] (musb_platform_init+0x7c/0x154) [<c00191a0>] (musb_platform_init+0x7c/0x154) from [<c001883c>] (musb_probe+0x208/0xaf0) [<c001883c>] (musb_probe+0x208/0xaf0) from [<c0178154>] (platform_drv_probe+0x1c/0x24) [<c0178154>] (platform_drv_probe+0x1c/0x24) from [<c0177258>] (driver_probe_device+0xac/0x164) [<c0177258>] (driver_probe_device+0xac/0x164) from [<c0177370>] (__driver_attach+0x60/0x84) [<c0177370>] (__driver_attach+0x60/0x84) from [<c017672c>] (bus_for_each_dev+0x4c/0x80) [<c017672c>] (bus_for_each_dev+0x4c/0x80) from [<c0176cdc>] (bus_add_driver+0x9c/0x220) [<c0176cdc>] (bus_add_driver+0x9c/0x220) from [<c0177740>] (driver_register+0xac/0x13c) [<c0177740>] (driver_register+0xac/0x13c) from [<c0178388>] (platform_driver_probe+0x10/0x8c) [<c0178388>] (platform_driver_probe+0x10/0x8c) from [<c0025314>] (do_one_initcall+0x54/0x194) [<c0025314>] (do_one_initcall+0x54/0x194) from [<c0008890>] (kernel_init+0x94/0x10c) [<c0008890>] (kernel_init+0x94/0x10c) from [<c002680c>] (kernel_thread_exit+0x0/0x8)

diff --git a/drivers/usb/musb/davinci.c b/drivers/usb/musb/davinci.c
index e16ff60..6691381 100644
--- a/drivers/usb/musb/davinci.c
+++ b/drivers/usb/musb/davinci.c
@@ -42,7 +42,7 @@
 #include "musb_core.h"
#ifdef CONFIG_MACH_DAVINCI_EVM
-#define GPIO_nVBUS_DRV		144
+#define GPIO_nVBUS_DRV		160

Note that the last GPIO for PCF8574 expander is 127 in the trace above. So, does this really apply to the mainline tree? It seems that even 144 doesn't...

 #endif
#include "davinci.h"

WBR, Sergei

--
To unsubscribe from this list: send the line "unsubscribe linux-usb" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Media]     [Linux Input]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Old Linux USB Devel Archive]

  Powered by Linux