Increase the timeout for disabling an IP block to five milliseconds. This is to handle the usb_host_fs idle latency, which takes almost four milliseconds after a host controller reset. This is the second of two patches needed to resolve the following boot warning: omap_hwmod: usb_host_fs: _wait_target_disable failed Thanks to Sergei Shtylyov <sshtylyov@mvista.com> for finding an unrelated hunk in a previous version of this patch.
Unified · Split
| @@ -22,4 +22,15 @@ · 21 unmodified lines | |||
| 22 | */ | 22 | */ |
| 23 | #define MAX_MODULE_READY_TIME 2000 | 23 | #define MAX_MODULE_READY_TIME 2000 |
| 24 | 24 | ||
| 25 | /* | ||
| 26 | * MAX_MODULE_DISABLE_TIME: max duration in microseconds to wait for | ||
| 27 | * the PRCM to request that a module enter the inactive state in the | ||
| 28 | * case of OMAP2 & 3. In the case of OMAP4 this is the max duration | ||
| 29 | * in microseconds for the module to reach the inactive state from | ||
| 30 | * a functional state. | ||
| 31 | * XXX FSUSB on OMAP4430 takes ~4ms to idle after reset during | ||
| 32 | * kernel init. | ||
| 33 | */ | ||
| 34 | #define MAX_MODULE_DISABLE_TIME 5000 | ||
| 35 | |||
| 25 | #endif | 36 | #endif |
| @@ -313,9 +313,9 @@ int omap4_cminst_wait_module_idle(u8 part, u16 inst, s16 cdoffs, u16 clkctrl_off · 312 unmodified lines | |||
| 313 | 313 | ||
| 314 | omap_test_timeout((_clkctrl_idlest(part, inst, cdoffs, clkctrl_offs) == | 314 | omap_test_timeout((_clkctrl_idlest(part, inst, cdoffs, clkctrl_offs) == |
| 315 | CLKCTRL_IDLEST_DISABLED), | 315 | CLKCTRL_IDLEST_DISABLED), |
| 316 | MAX_MODULE_READY_TIME, i); | 316 | MAX_MODULE_DISABLE_TIME, i); |
| 317 | 317 | ||
| 318 | return (i < MAX_MODULE_READY_TIME) ? 0 : -EBUSY; | 318 | return (i < MAX_MODULE_DISABLE_TIME) ? 0 : -EBUSY; |
| 319 | } | 319 | } |
| 320 | 320 | ||
| 321 | /** | 321 | /** |