Re: [PATCH] OMAP2: add USB platform data and initialization for Nokia N800 and N810

2009-12-29 Thread Kalle Valo
"Luke-Jr"  writes:

> On that topic, is there a reason the newer code is under a unified "N8x0" 
> config option instead of the split N800/N810 that was used for the old code, 
> or is that simply a symptom of the currently-supported features all being 
> common?

IIRC, I just used one common n8x0 file because the n810 board file was
very small and I didn't see any benefit from having it separately.

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


Re: [PATCH] OMAP2: add USB platform data and initialization for Nokia N800 and N810

2009-12-29 Thread Kalle Valo
(dropping lkml)

"Luke-Jr"  writes:

> I think 4 or 5 files with ~350 lines is more manageable than a
> single 1700- line board file, especially when considering that parts
> depend on multiple configuration options (LCD, which turns out to be
> a 128-line file, depends on 3 config options: N8x0, Blizzard, and
> MIPID).

I tend to disagree. Scattering code to small files doesn't benefit
that much, just makes it harder to find code. IMHO a 2k line file is
perfectly acceptable and usable.

But if you really want smaller files, I'm not going to object. You're
the one doing the all work here :)

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


Re: SR2: VDD autocomp is not active

2009-12-29 Thread Romit Dasgupta
tarek attia wrote:
> Thank you :) ,
> 
> I found the "omap2_clk_init_cpufreq_table" function in the kernel
> image installed on my board ,and the hanging up is not permanent
> ,sometimes occurs and some time doesn't .
> 
> So what the reason may be for this case? ..also what is the usage of
> "sr_vdd1_autocomp" ??
> 
> I know that I'm bothering you,,but thanks for your reply in advance :-)
> 
Nothing to be bothered. Always glad to reply. sr_vdd1_autocomp enables Smart
reflex voltage autocompensation for VDD1 voltage rail.
You do seem to have the low level cpufreq driver in place. May be you can try
with pm branch.
--
To unsubscribe from this list: send the line "unsubscribe linux-omap" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


RE: [PATCH 1/5] ARM: OMAP4: PM: OMAP4 essential basic initialisations.

2009-12-29 Thread Pagare, Abhijit

Tony,

> -Original Message-
> From: Tony Lindgren [mailto:t...@atomide.com]
> Sent: Tuesday, December 29, 2009 5:04 AM
> To: abhijit.pag...@india.ti.com
> Cc: linux-omap@vger.kernel.org; linux-arm-ker...@lists.infradead.org; Paul
> Walmsley; Nayak, Rajendra; Pagare, Abhijit; Cousson, Benoit
> Subject: Re: [PATCH 1/5] ARM: OMAP4: PM: OMAP4 essential basic
> initialisations.
> 
> * abhijit.pag...@india.ti.com  [091211
> 02:50]:
> > From: Abhijit Pagare 
> >
> > Some of the OMAP4 specific chip level initialisations are taken care of.
> 
> Here's yet another series of patches with "PM" in the subject
> for no obvious reason.
> 
> Please repost all with with sensible subjects.


I will re-post the patches with the necessary changes.

Best Regards,
Abhijit Pagare

> 
> Tony
> 
> 
> > Signed-off-by: Abhijit Pagare 
> > Cc: Paul Walmsley 
> > Cc: Benoit Cousson 
> > Cc: Rajendra Nayak 
> > ---
> >  arch/arm/mach-omap2/id.c  |8 +++-
> >  arch/arm/plat-omap/include/plat/cpu.h |6 +-
> >  2 files changed, 12 insertions(+), 2 deletions(-)
> >
> > diff --git a/arch/arm/mach-omap2/id.c b/arch/arm/mach-omap2/id.c
> > index 4fad192..52aca5f 100644
> > --- a/arch/arm/mach-omap2/id.c
> > +++ b/arch/arm/mach-omap2/id.c
> > @@ -336,8 +336,12 @@ void __init omap2_check_revision(void)
> > omap3_check_features();
> > omap3_cpuinfo();
> > } else if (cpu_is_omap44xx()) {
> > +   /*
> > +* omap44xx_check_revision() should
> > +* be defined above and then called
> > +* from here.
> > +*/
> > printk(KERN_INFO "FIXME: CPU revision = OMAP4430\n");
> > -   return;
> > } else {
> > pr_err("OMAP revision unknown, please fix!\n");
> > }
> > @@ -367,6 +371,8 @@ void __init omap2_check_revision(void)
> > omap_chip.oc |= CHIP_IS_OMAP3430ES3_1;
> > else if (omap_rev() == OMAP3630_REV_ES1_0)
> > omap_chip.oc |= CHIP_IS_OMAP3630ES1;
> > +   } else if (cpu_is_omap44xx()) {
> > +   omap_chip.oc |= CHIP_IS_OMAP4430;
> > } else {
> > pr_err("Uninitialized omap_chip, please fix!\n");
> > }
> > diff --git a/arch/arm/plat-omap/include/plat/cpu.h b/arch/arm/plat-
> omap/include/plat/cpu.h
> > index 2e17890..6a296b8 100644
> > --- a/arch/arm/plat-omap/include/plat/cpu.h
> > +++ b/arch/arm/plat-omap/include/plat/cpu.h
> > @@ -154,6 +154,7 @@ unsigned int omap_rev(void);
> >   * cpu_is_omap242x():  True for OMAP2420, OMAP2422, OMAP2423
> >   * cpu_is_omap243x():  True for OMAP2430
> >   * cpu_is_omap343x():  True for OMAP3430
> > + * cpu_is_omap443x():  True for OMAP4430
> >   */
> >  #define GET_OMAP_CLASS (omap_rev() & 0xff)
> >
> > @@ -284,6 +285,7 @@ IS_OMAP_SUBCLASS(363x, 0x363)
> >   * cpu_is_omap2423():  True for OMAP2423
> >   * cpu_is_omap2430():  True for OMAP2430
> >   * cpu_is_omap3430():  True for OMAP3430
> > + * cpu_is_omap4430():  True for OMAP4430
> >   * cpu_is_omap3505():  True for OMAP3505
> >   * cpu_is_omap3517():  True for OMAP3517
> >   */
> > @@ -332,6 +334,7 @@ IS_OMAP_TYPE(3517, 0x3517)
> >  #define cpu_is_omap3505()  0
> >  #define cpu_is_omap3517()  0
> >  #define cpu_is_omap3430()  0
> > +#define cpu_is_omap4430()  0
> >  #define cpu_is_omap3630()  0
> >
> >  /*
> > @@ -443,7 +446,7 @@ IS_OMAP_TYPE(3517, 0x3517)
> >  #define OMAP3505_REV(v)(OMAP35XX_CLASS | (0x3505 << 16) | (v
> << 12))
> >  #define OMAP3517_REV(v)(OMAP35XX_CLASS | (0x3517 << 16) | (v
> << 12))
> >
> > -#define OMAP443X_CLASS 0x44300034
> > +#define OMAP443X_CLASS 0x44300044
> >
> >  /*
> >   * omap_chip bits
> > @@ -467,6 +470,7 @@ IS_OMAP_TYPE(3517, 0x3517)
> >  #define CHIP_IS_OMAP3430ES3_0  (1 << 5)
> >  #define CHIP_IS_OMAP3430ES3_1  (1 << 6)
> >  #define CHIP_IS_OMAP3630ES1(1 << 7)
> > +#define CHIP_IS_OMAP4430   (1 << 8)
> >
> >  #define CHIP_IS_OMAP24XX   (CHIP_IS_OMAP2420 | CHIP_IS_OMAP2430)
> >
> > --
> > 1.5.4.7
> >
> >
> > ___
> > linux-arm-kernel mailing list
> > linux-arm-ker...@lists.infradead.org
> > http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
--
To unsubscribe from this list: send the line "unsubscribe linux-omap" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


RE: L4 interconnect memory mapping

2009-12-29 Thread Shilimkar, Santosh
> -Original Message-
> From: linux-omap-ow...@vger.kernel.org 
> [mailto:linux-omap-ow...@vger.kernel.org] On Behalf Of Felipe
> Balbi
> Sent: Wednesday, December 30, 2009 5:20 AM
> To: Tony Lindgren
> Cc: p...@pwsan.com; linux-omap@vger.kernel.org
> Subject: Re: L4 interconnect memory mapping
> 
> On Tue, 2009-12-29 at 15:46 -0800, Tony Lindgren wrote:
> > * Felipe Balbi  [091229 15:26]:
> > > Hi,
> > >
> > > On Wed, 2009-12-30 at 01:25 +0200, Felipe Balbi wrote:
> > > > Hi Tony and Paul,
> > > >
> > > > maybe a silly question, but here it goes:
> > > >
> > > > Do we have any piece of code handling the L4 interconnect memory space ?
> > > > I mean, looking at omap3 TRM pages 212 - 219, I see that e.g. for the
> > > > musb block we have:
> > > >
> > > > HS USB OTG  0x480AB000 - 0x480ABFFF 4KB Module
> > > > 0x480AC000 - 0x480ACFFF 4KB L4 interconnect
> > > >
> > > > So the first 4K is what we pass down to drivers via struct resource and
> > > > the second 4K ? What do we do with that ?
> > >
> > > no with Paul's address correct.
> >
> > Looks like you might want to update your earlier patch to just comment
> > that the 8K address space for musb is 4K + 4K for L4 interconnect :)
> 
> was thinking about that just now heh, but what do we do with the extra
> 4k ? It's the same for all other modules. Is omap_hwmod taking care of
> that ?
I don't think you need to map 8k if there is no additional register in upper 4K.
All memory spaces described as modules provide direct access to the module 
registers outside the L4 interconnect. All other accesses are internal to the 
L4 interconnect ( L4_CFG, L4_PER). 

Regards,
Santosh


RE: [PATCH 7/8] arm: omap: musb: pass board mode to usb_musb_init

2009-12-29 Thread Gupta, Ajay Kumar

Hi,
> -Original Message-
> From: linux-omap-ow...@vger.kernel.org [mailto:linux-omap-
> ow...@vger.kernel.org] On Behalf Of Felipe Balbi
> Sent: Monday, December 28, 2009 4:40 PM
> To: Tony Lindgren
> Cc: Linux OMAP Mailing List; Felipe Balbi
> Subject: [PATCH 7/8] arm: omap: musb: pass board mode to usb_musb_init
> 
> each board will have a different mode which is peculiar
> to that board.
> 
> Signed-off-by: Felipe Balbi 
> ---


> 
>  #include 
>  #include 
> @@ -203,7 +204,7 @@ static void __init omap_2430sdp_init(void)
>   platform_add_devices(sdp2430_devices, ARRAY_SIZE(sdp2430_devices));
>   omap_serial_init();
>   twl4030_mmc_init(mmc);
> - usb_musb_init(100);
> + usb_musb_init(MUSB_OTG, 100);

Similarly, we would need another parameter 'extvbus' which is required by
OMAP3EVM Rev >= E. This way the parameter list would keep increasing and
would look ugly.

So how about passing a "struct musb_board_data" structure completely ? It
Can be generic across the musb platforms or we can have it only for OMAP
platforms.

Ajay

>   board_smc91x_init();
> 
--
To unsubscribe from this list: send the line "unsubscribe linux-omap" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH] OMAP2: add USB platform data and initialization for Nokia N800 and N810

2009-12-29 Thread Luke-Jr
On Tuesday 29 December 2009 03:05:46 pm Luke-Jr wrote:
> The last-working N8x0 support (Linux-OMAP 2.6.30-rc8) required 1706 lines
>  of platform data and initialization, split up into 6 files:

Upon trying to debug my non-working keyboard, I learned that the status of 
mainlining is actually worse off than I thought, and my "last 2.6.30-rc8 
working" revision was actually already missing platform data.

It seems logical from looking at the code needed to divide the board into at 
least 5 files (line number estimates based on old code):
460 board-n8x0-common.c
175 board-n800.c(FM radio, touchscreen)
260 board-n810.c(keyboard, light sensor, LEDs, 
touchscreen)
600 board-n8x0-multimedia.c (camera, audio, DSP)
725 board-n8x0-storage.c(flash, MMC)
120 board-n8x0-lcd.c

On that topic, is there a reason the newer code is under a unified "N8x0" 
config option instead of the split N800/N810 that was used for the old code, 
or is that simply a symptom of the currently-supported features all being 
common?

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


Re: [PULL REQUEST] arm omap patches for -next merge window

2009-12-29 Thread Felipe Balbi
On Tue, 2009-12-29 at 15:50 -0800, Tony Lindgren wrote:
> * Felipe Balbi  [091229 14:59]:
> > After these, all the patches I have for you are
> > done, besides the CBUS stuff which I want to test
> > further. DSME is turning off my device right after
> > boot so I can't really test anything. If you have
> > some hint, I'd be glad to hear ;-)
> > 
> > The following changes since commit
> > bb65718ad7ed3c4231f67cf3f8b4a9a071bdfd53:
> >   Felipe Balbi (1):
> > arm: omap: perseus: kill compile warning on board-perseus2.c
> > 
> > are available in the git repository at:
> > 
> >   git://gitorious.org/usb/usb.git for-tony-next
> 
> This too should be against Linus' -rc2. Also, please
> leave out the changes to drivers/usb/musb, I don't want
> to pull those into for-next as they'll go through Greg.
> We can add any patches like that to omap-testing branch
> temporarily. That way people using linux-omap tree can
> test them.

Ok all fixed now, here's a new pull request:

The following changes since commit
6b7b284958d47b77d06745b36bc7f36dab769d9b:
  Linus Torvalds (1):
Linux 2.6.33-rc2

are available in the git repository at:

  git://gitorious.org/usb/usb.git for-tony-next

Felipe Balbi (8):
  arm: omap: musb: remove unused data
  arm: omap: musb: we can use clk framework
  arm: omap: musb: remove unused soft_con field
  arm: omap: musb: remove unused dma data
  arm: omap: musb: remove unnecessary return
  arm: omap: gpmc: avoid section definitions on headers
  arm: omap: musb: do not pass clock name to driver
  arm: omap: musb: get rid of dyn_fifo

 arch/arm/mach-omap2/usb-musb.c |   71
+---
 arch/arm/plat-omap/include/plat/gpmc.h |2 +-
 2 files changed, 2 insertions(+), 71 deletions(-)


-- 
balbi

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


Re: [PULL REQUEST] arm omap patches for next -rc

2009-12-29 Thread Felipe Balbi
On Wed, 2009-12-30 at 01:44 +0200, Felipe Balbi wrote:
> On Tue, 2009-12-29 at 15:42 -0800, Tony Lindgren wrote:
> > * Felipe Balbi  [091229 14:56]:
> > > The following changes since commit
> > > abb74381235a05f15a3b07e9e3831034942c67fb:
> > >   Tony Lindgren (1):
> > > Linux-omap rebuilt: Updated to 2.6.33-rc2, clock fixes merged
> > 
> > Looks good, except all the trees should be based against Linus' -rc2,
> > not against linux-omap or other non-mainline branches.
> 
> will rebase, will send new pull request in a sec.

And here you are:

The following changes since commit
6b7b284958d47b77d06745b36bc7f36dab769d9b:
  Linus Torvalds (1):
Linux 2.6.33-rc2

are available in the git repository at:

  git://gitorious.org/usb/usb.git for-tony

Felipe Balbi (12):
  arm: omap: musb: ioremap only what's ours
  arm: omap: musb: fix board power budget by passing it to
usb_musb_init
  arm: omap: musb: fix board mode by passing it to usb_musb_init
  arm: omap1: mailbox: kill compile warning
  arm: omap: gpmc: kill compile warning
  arm: omap: kill compile warning in irq.c
  arm: omap: remove unused variables
  arm: omap: io: kill compile warning
  arm: omap: kill compile warning on board-4430-sdp.c
  arm: omap: gpio: kill compile warning in gpio.c
  arm: omap: mailbox: kill compile warning in mailbox.c
  arm: omap: perseus: kill compile warning on board-perseus2.c

 arch/arm/mach-omap1/devices.c|2 +-
 arch/arm/mach-omap1/mailbox.c|9 +++--
 arch/arm/mach-omap2/board-2430sdp.c  |3 ++-
 arch/arm/mach-omap2/board-3430sdp.c  |3 ++-
 arch/arm/mach-omap2/board-4430sdp.c  |4 
 arch/arm/mach-omap2/board-cm-t35.c   |3 ++-
 arch/arm/mach-omap2/board-igep0020.c |3 ++-
 arch/arm/mach-omap2/board-ldp.c  |3 ++-
 arch/arm/mach-omap2/board-omap3beagle.c  |3 ++-
 arch/arm/mach-omap2/board-omap3evm.c |3 ++-
 arch/arm/mach-omap2/board-omap3pandora.c |3 ++-
 arch/arm/mach-omap2/board-omap3touchbook.c   |3 ++-
 arch/arm/mach-omap2/board-overo.c|3 ++-
 arch/arm/mach-omap2/board-rx51.c |3 ++-
 arch/arm/mach-omap2/board-zoom-peripherals.c |3 ++-
 arch/arm/mach-omap2/gpmc.c   |6 --
 arch/arm/mach-omap2/io.c |2 ++
 arch/arm/mach-omap2/irq.c|2 ++
 arch/arm/mach-omap2/mailbox.c|2 +-
 arch/arm/mach-omap2/omap_hwmod_2430.h|2 --
 arch/arm/mach-omap2/usb-musb.c   |   23
+++
 arch/arm/plat-omap/gpio.c|3 +++
 arch/arm/plat-omap/include/plat/fpga.h   |4 ++--
 arch/arm/plat-omap/include/plat/usb.h|3 ++-
 24 files changed, 55 insertions(+), 43 deletions(-)


-- 
balbi

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


Re: [patch-v2.6.33-rc2+ 01/12] arm: omap: musb: ioremap only what's ours

2009-12-29 Thread Felipe Balbi
On Wed, 2009-12-30 at 00:51 +0200, Felipe Balbi wrote:
> omap3430 TRM says the OTG address space is 4k, not 8k.

further explanation is that the address space for musb module is 4k and
the extra 4k is for L4 interconnect. I'll change the description on the
branch Tony will pull from.

-- 
balbi

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


Re: [PULL REQUEST] arm omap patches for -next merge window

2009-12-29 Thread Tony Lindgren
* Felipe Balbi  [091229 14:59]:
> After these, all the patches I have for you are
> done, besides the CBUS stuff which I want to test
> further. DSME is turning off my device right after
> boot so I can't really test anything. If you have
> some hint, I'd be glad to hear ;-)
> 
> The following changes since commit
> bb65718ad7ed3c4231f67cf3f8b4a9a071bdfd53:
>   Felipe Balbi (1):
> arm: omap: perseus: kill compile warning on board-perseus2.c
> 
> are available in the git repository at:
> 
>   git://gitorious.org/usb/usb.git for-tony-next

This too should be against Linus' -rc2. Also, please
leave out the changes to drivers/usb/musb, I don't want
to pull those into for-next as they'll go through Greg.
We can add any patches like that to omap-testing branch
temporarily. That way people using linux-omap tree can
test them.

Regards,

Tony
 
> Felipe Balbi (9):
>   arm: omap: musb: remove unused data
>   arm: omap: musb: we can use clk framework
>   arm: omap: musb: remove unused soft_con field
>   arm: omap: musb: remove unused dma data
>   arm: omap: musb: remove unnecessary return
>   arm: omap: gpmc: avoid section definitions on headers
>   usb: musb: use only clk framework for clk handling
>   arm: omap: musb: do not pass clock name to driver
>   arm: omap: musb: get rid of dyn_fifo
> 
>  arch/arm/mach-omap2/usb-musb.c |   71
> +---
>  arch/arm/plat-omap/include/plat/gpmc.h |2 +-
>  drivers/usb/musb/musb_core.c   |   48 +++--
>  drivers/usb/musb/musb_core.h   |2 -
>  drivers/usb/musb/omap2430.c|   10 +
>  drivers/usb/musb/tusb6010.c|   16 +++
>  include/linux/usb/musb.h   |4 +-
>  7 files changed, 28 insertions(+), 125 deletions(-)
> 
> -- 
> balbi
> 
--
To unsubscribe from this list: send the line "unsubscribe linux-omap" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: L4 interconnect memory mapping

2009-12-29 Thread Felipe Balbi
On Tue, 2009-12-29 at 15:46 -0800, Tony Lindgren wrote:
> * Felipe Balbi  [091229 15:26]:
> > Hi,
> > 
> > On Wed, 2009-12-30 at 01:25 +0200, Felipe Balbi wrote:
> > > Hi Tony and Paul,
> > > 
> > > maybe a silly question, but here it goes:
> > > 
> > > Do we have any piece of code handling the L4 interconnect memory space ?
> > > I mean, looking at omap3 TRM pages 212 - 219, I see that e.g. for the
> > > musb block we have:
> > > 
> > > HS USB OTG0x480AB000 - 0x480ABFFF 4KB Module
> > >   0x480AC000 - 0x480ACFFF 4KB L4 interconnect
> > > 
> > > So the first 4K is what we pass down to drivers via struct resource and
> > > the second 4K ? What do we do with that ?
> > 
> > no with Paul's address correct.
> 
> Looks like you might want to update your earlier patch to just comment
> that the 8K address space for musb is 4K + 4K for L4 interconnect :)

was thinking about that just now heh, but what do we do with the extra
4k ? It's the same for all other modules. Is omap_hwmod taking care of
that ?

-- 
balbi

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


Re: L4 interconnect memory mapping

2009-12-29 Thread Tony Lindgren
* Felipe Balbi  [091229 15:26]:
> Hi,
> 
> On Wed, 2009-12-30 at 01:25 +0200, Felipe Balbi wrote:
> > Hi Tony and Paul,
> > 
> > maybe a silly question, but here it goes:
> > 
> > Do we have any piece of code handling the L4 interconnect memory space ?
> > I mean, looking at omap3 TRM pages 212 - 219, I see that e.g. for the
> > musb block we have:
> > 
> > HS USB OTG  0x480AB000 - 0x480ABFFF 4KB Module
> > 0x480AC000 - 0x480ACFFF 4KB L4 interconnect
> > 
> > So the first 4K is what we pass down to drivers via struct resource and
> > the second 4K ? What do we do with that ?
> 
> no with Paul's address correct.

Looks like you might want to update your earlier patch to just comment
that the 8K address space for musb is 4K + 4K for L4 interconnect :)

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


Re: [PULL REQUEST] arm omap patches for next -rc

2009-12-29 Thread Felipe Balbi
On Tue, 2009-12-29 at 15:42 -0800, Tony Lindgren wrote:
> * Felipe Balbi  [091229 14:56]:
> > The following changes since commit
> > abb74381235a05f15a3b07e9e3831034942c67fb:
> >   Tony Lindgren (1):
> > Linux-omap rebuilt: Updated to 2.6.33-rc2, clock fixes merged
> 
> Looks good, except all the trees should be based against Linus' -rc2,
> not against linux-omap or other non-mainline branches.

will rebase, will send new pull request in a sec.

-- 
balbi

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


Re: [PULL REQUEST] arm omap patches for next -rc

2009-12-29 Thread Tony Lindgren
* Felipe Balbi  [091229 14:56]:
> The following changes since commit
> abb74381235a05f15a3b07e9e3831034942c67fb:
>   Tony Lindgren (1):
> Linux-omap rebuilt: Updated to 2.6.33-rc2, clock fixes merged

Looks good, except all the trees should be based against Linus' -rc2,
not against linux-omap or other non-mainline branches.

Regards,

Tony
 
> are available in the git repository at:
> 
>   git://gitorious.org/usb/usb.git for-tony
> 
> Felipe Balbi (12):
>   arm: omap: musb: ioremap only what's ours
>   arm: omap: musb: fix board power budget by passing it to
> usb_musb_init
>   arm: omap: musb: fix board mode by passing it to usb_musb_init
>   arm: omap1: mailbox: kill compile warning
>   arm: omap: gpmc: kill compile warning
>   arm: omap: kill compile warning in irq.c
>   arm: omap: remove unused variables
>   arm: omap: io: kill compile warning
>   arm: omap: kill compile warning on board-4430-sdp.c
>   arm: omap: gpio: kill compile warning in gpio.c
>   arm: omap: mailbox: kill compile warning in mailbox.c
>   arm: omap: perseus: kill compile warning on board-perseus2.c
> 
>  arch/arm/mach-omap1/devices.c|2 +-
>  arch/arm/mach-omap1/mailbox.c|9 +++--
>  arch/arm/mach-omap2/board-2430sdp.c  |3 ++-
>  arch/arm/mach-omap2/board-3430sdp.c  |3 ++-
>  arch/arm/mach-omap2/board-4430sdp.c  |4 
>  arch/arm/mach-omap2/board-cm-t35.c   |3 ++-
>  arch/arm/mach-omap2/board-igep0020.c |3 ++-
>  arch/arm/mach-omap2/board-ldp.c  |3 ++-
>  arch/arm/mach-omap2/board-omap3beagle.c  |3 ++-
>  arch/arm/mach-omap2/board-omap3evm.c |3 ++-
>  arch/arm/mach-omap2/board-omap3pandora.c |3 ++-
>  arch/arm/mach-omap2/board-omap3touchbook.c   |3 ++-
>  arch/arm/mach-omap2/board-overo.c|3 ++-
>  arch/arm/mach-omap2/board-rx51.c |3 ++-
>  arch/arm/mach-omap2/board-zoom-peripherals.c |3 ++-
>  arch/arm/mach-omap2/gpmc.c   |6 --
>  arch/arm/mach-omap2/io.c |2 ++
>  arch/arm/mach-omap2/irq.c|2 ++
>  arch/arm/mach-omap2/mailbox.c|2 +-
>  arch/arm/mach-omap2/omap_hwmod_2430.h|2 --
>  arch/arm/mach-omap2/usb-musb.c   |   23
> +++
>  arch/arm/plat-omap/gpio.c|3 +++
>  arch/arm/plat-omap/include/plat/fpga.h   |4 ++--
>  arch/arm/plat-omap/include/plat/usb.h|3 ++-
>  24 files changed, 55 insertions(+), 43 deletions(-)
> 
> -- 
> balbi
> 
--
To unsubscribe from this list: send the line "unsubscribe linux-omap" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: L4 interconnect memory mapping

2009-12-29 Thread Felipe Balbi
Hi,

On Wed, 2009-12-30 at 01:25 +0200, Felipe Balbi wrote:
> Hi Tony and Paul,
> 
> maybe a silly question, but here it goes:
> 
> Do we have any piece of code handling the L4 interconnect memory space ?
> I mean, looking at omap3 TRM pages 212 - 219, I see that e.g. for the
> musb block we have:
> 
> HS USB OTG0x480AB000 - 0x480ABFFF 4KB Module
>   0x480AC000 - 0x480ACFFF 4KB L4 interconnect
> 
> So the first 4K is what we pass down to drivers via struct resource and
> the second 4K ? What do we do with that ?

no with Paul's address correct.

-- 
balbi

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


L4 interconnect memory mapping

2009-12-29 Thread Felipe Balbi
Hi Tony and Paul,

maybe a silly question, but here it goes:

Do we have any piece of code handling the L4 interconnect memory space ?
I mean, looking at omap3 TRM pages 212 - 219, I see that e.g. for the
musb block we have:

HS USB OTG  0x480AB000 - 0x480ABFFF 4KB Module
0x480AC000 - 0x480ACFFF 4KB L4 interconnect

So the first 4K is what we pass down to drivers via struct resource and
the second 4K ? What do we do with that ?

-- 
balbi

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


[patch-v2.6.33-rc2+ 11/12] arm: omap: mailbox: kill compile warning in mailbox.c

2009-12-29 Thread Felipe Balbi
Change %d to %ld to avoid the compile warning.

Signed-off-by: Felipe Balbi 
---
 arch/arm/mach-omap2/mailbox.c |2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/arch/arm/mach-omap2/mailbox.c b/arch/arm/mach-omap2/mailbox.c
index 281ab63..2c9fd1c 100644
--- a/arch/arm/mach-omap2/mailbox.c
+++ b/arch/arm/mach-omap2/mailbox.c
@@ -93,7 +93,7 @@ static int omap2_mbox_startup(struct omap_mbox *mbox)
 
mbox_ick_handle = clk_get(NULL, "mailboxes_ick");
if (IS_ERR(mbox_ick_handle)) {
-   printk(KERN_ERR "Could not get mailboxes_ick: %d\n",
+   printk(KERN_ERR "Could not get mailboxes_ick: %ld\n",
PTR_ERR(mbox_ick_handle));
return PTR_ERR(mbox_ick_handle);
}
-- 
1.6.6.35.g1d85d

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


[patch-v2.6.33-rc2+ 12/12] arm: omap: perseus: kill compile warning on board-perseus2.c

2009-12-29 Thread Felipe Balbi
that address is used by struct map_desc, which expects
an unsigned long instead of a void __iomem *. Fix it.

Signed-off-by: Felipe Balbi 
---
 arch/arm/plat-omap/include/plat/fpga.h |4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/arch/arm/plat-omap/include/plat/fpga.h 
b/arch/arm/plat-omap/include/plat/fpga.h
index f1864a6..023b3eb 100644
--- a/arch/arm/plat-omap/include/plat/fpga.h
+++ b/arch/arm/plat-omap/include/plat/fpga.h
@@ -34,9 +34,9 @@ extern void omap1510_fpga_init_irq(void);
  * ---
  */
 /* maps in the FPGA registers and the ETHR registers */
-#define H2P2_DBG_FPGA_BASE IOMEM(0xE800)   /* VA */
+#define H2P2_DBG_FPGA_BASE 0xE800  /* VA */
 #define H2P2_DBG_FPGA_SIZE SZ_4K   /* SIZE */
-#define H2P2_DBG_FPGA_START0x0400  /* PA */
+#define H2P2_DBG_FPGA_STARTIOMEM(0x0400)   /* PA */
 
 #define H2P2_DBG_FPGA_ETHR_START   (H2P2_DBG_FPGA_START + 0x300)
 #define H2P2_DBG_FPGA_FPGA_REV (H2P2_DBG_FPGA_BASE + 0x10) /* FPGA 
Revision */
-- 
1.6.6.35.g1d85d

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


[PULL REQUEST] arm omap patches for -next merge window

2009-12-29 Thread Felipe Balbi
After these, all the patches I have for you are
done, besides the CBUS stuff which I want to test
further. DSME is turning off my device right after
boot so I can't really test anything. If you have
some hint, I'd be glad to hear ;-)

The following changes since commit
bb65718ad7ed3c4231f67cf3f8b4a9a071bdfd53:
  Felipe Balbi (1):
arm: omap: perseus: kill compile warning on board-perseus2.c

are available in the git repository at:

  git://gitorious.org/usb/usb.git for-tony-next

Felipe Balbi (9):
  arm: omap: musb: remove unused data
  arm: omap: musb: we can use clk framework
  arm: omap: musb: remove unused soft_con field
  arm: omap: musb: remove unused dma data
  arm: omap: musb: remove unnecessary return
  arm: omap: gpmc: avoid section definitions on headers
  usb: musb: use only clk framework for clk handling
  arm: omap: musb: do not pass clock name to driver
  arm: omap: musb: get rid of dyn_fifo

 arch/arm/mach-omap2/usb-musb.c |   71
+---
 arch/arm/plat-omap/include/plat/gpmc.h |2 +-
 drivers/usb/musb/musb_core.c   |   48 +++--
 drivers/usb/musb/musb_core.h   |2 -
 drivers/usb/musb/omap2430.c|   10 +
 drivers/usb/musb/tusb6010.c|   16 +++
 include/linux/usb/musb.h   |4 +-
 7 files changed, 28 insertions(+), 125 deletions(-)

-- 
balbi

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


[patch-v2.6.33-rc2+ 10/12] arm: omap: gpio: kill compile warning in gpio.c

2009-12-29 Thread Felipe Balbi
when building linux-omap for omap1510, there will
be a compile warning about the unused flags variable
which is only used on 16xx and onwards.

Signed-off-by: Felipe Balbi 
---
 arch/arm/plat-omap/gpio.c |3 +++
 1 files changed, 3 insertions(+), 0 deletions(-)

diff --git a/arch/arm/plat-omap/gpio.c b/arch/arm/plat-omap/gpio.c
index 0484681..8c34b81 100644
--- a/arch/arm/plat-omap/gpio.c
+++ b/arch/arm/plat-omap/gpio.c
@@ -1072,7 +1072,10 @@ static inline void _set_gpio_irqenable(struct gpio_bank 
*bank, int gpio, int ena
  */
 static int _set_gpio_wakeup(struct gpio_bank *bank, int gpio, int enable)
 {
+#if defined(CONFIG_ARCH_OMAP16XX) || defined(CONFIG_ARCH_OMAP24XX) || \
+   defined(CONFIG_ARCH_OMAP34XX) || defined(CONFIG_ARCH_OMAP4)
unsigned long flags;
+#endif
 
switch (bank->method) {
 #ifdef CONFIG_ARCH_OMAP16XX
-- 
1.6.6.35.g1d85d

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


[patch-v2.6.34 9/9] arm: omap: musb: get rid of dyn_fifo

2009-12-29 Thread Felipe Balbi
that's deprecated as we can check dyn_fifo from
CONFIGDATA register.

Cc: linux-...@vger.kernel.org
Signed-off-by: Felipe Balbi 
---
 arch/arm/mach-omap2/usb-musb.c |1 -
 1 files changed, 0 insertions(+), 1 deletions(-)

diff --git a/arch/arm/mach-omap2/usb-musb.c b/arch/arm/mach-omap2/usb-musb.c
index f102d5a..57debb2 100644
--- a/arch/arm/mach-omap2/usb-musb.c
+++ b/arch/arm/mach-omap2/usb-musb.c
@@ -49,7 +49,6 @@ static struct resource musb_resources[] = {
 
 static struct musb_hdrc_config musb_config = {
.multipoint = 1,
-   .dyn_fifo   = 1,
.num_eps= 16,
.ram_bits   = 12,
 };
-- 
1.6.6.35.g1d85d

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


[patch-v2.6.34 8/9] arm: omap: musb: do not pass clock name to driver

2009-12-29 Thread Felipe Balbi
we are using clkdev and the driver can use whatever
name it wants.

Cc: linux-...@vger.kernel.org
Signed-off-by: Felipe Balbi 
---
 arch/arm/mach-omap2/usb-musb.c |6 --
 1 files changed, 0 insertions(+), 6 deletions(-)

diff --git a/arch/arm/mach-omap2/usb-musb.c b/arch/arm/mach-omap2/usb-musb.c
index ec8869a..f102d5a 100644
--- a/arch/arm/mach-omap2/usb-musb.c
+++ b/arch/arm/mach-omap2/usb-musb.c
@@ -55,7 +55,6 @@ static struct musb_hdrc_config musb_config = {
 };
 
 static struct musb_hdrc_platform_data musb_plat = {
-   /* .clock is set dynamically */
.config = &musb_config,
/* .power   = DYNAMIC, */
/* .mode= DYNAMIC, */
@@ -83,11 +82,6 @@ void __init usb_musb_init(enum musb_mode mode, unsigned 
power)
musb_resources[0].start = OMAP34XX_HSUSB_OTG_BASE;
musb_resources[0].end = musb_resources[0].start + SZ_4K - 1;
 
-   /*
-* REVISIT: This line can be removed once all the platforms using
-* musb_core.c have been converted to use use clkdev.
-*/
-   musb_plat.clock = "ick";
musb_plat.power = power >> 1;
musb_plat.mode = mode;
 
-- 
1.6.6.35.g1d85d

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


[patch-v2.6.34 7/9] usb: musb: use only clk framework for clk handling

2009-12-29 Thread Felipe Balbi
get rid of the set_clock hackery.

Cc: linux-...@vger.kernel.org
Signed-off-by: Felipe Balbi 
---

Greg, I'll send this patch to you shortly, it's
only here so that Tony can have it in linux-omap-2.6
to avoid breaking any of his boards.

 drivers/usb/musb/musb_core.c |   48 ++
 drivers/usb/musb/musb_core.h |2 -
 drivers/usb/musb/omap2430.c  |   10 +---
 drivers/usb/musb/tusb6010.c  |   16 +
 include/linux/usb/musb.h |4 +-
 5 files changed, 26 insertions(+), 54 deletions(-)

diff --git a/drivers/usb/musb/musb_core.c b/drivers/usb/musb/musb_core.c
index 5eb9318..37ca87d 100644
--- a/drivers/usb/musb/musb_core.c
+++ b/drivers/usb/musb/musb_core.c
@@ -977,10 +977,8 @@ static void musb_shutdown(struct platform_device *pdev)
spin_lock_irqsave(&musb->lock, flags);
musb_platform_disable(musb);
musb_generic_disable(musb);
-   if (musb->clock) {
-   clk_put(musb->clock);
-   musb->clock = NULL;
-   }
+   clk_put(musb->clock);
+   musb->clock = NULL;
spin_unlock_irqrestore(&musb->lock, flags);
 
/* FIXME power down */
@@ -1864,10 +1862,8 @@ static void musb_free(struct musb *musb)
musb_platform_exit(musb);
musb_writeb(musb->mregs, MUSB_DEVCTL, 0);
 
-   if (musb->clock) {
-   clk_disable(musb->clock);
-   clk_put(musb->clock);
-   }
+   clk_disable(musb->clock);
+   clk_put(musb->clock);
 
 #ifdef CONFIG_USB_MUSB_HDRC_HCD
usb_put_hcd(musb_to_hcd(musb));
@@ -1930,7 +1926,6 @@ bad_config:
spin_lock_init(&musb->lock);
musb->board_mode = plat->mode;
musb->board_set_power = plat->set_power;
-   musb->set_clock = plat->set_clock;
musb->min_power = plat->min_power;
 
/* Clock usage is chip-specific ... functional clock (DaVinci,
@@ -1938,15 +1933,17 @@ bad_config:
 * code does is make sure a clock handle is available; platform
 * code manages it during start/stop and suspend/resume.
 */
-   if (plat->clock) {
-   musb->clock = clk_get(dev, plat->clock);
-   if (IS_ERR(musb->clock)) {
-   status = PTR_ERR(musb->clock);
-   musb->clock = NULL;
-   goto fail;
-   }
+   musb->clock = clk_get(dev, "ick");
+   if (IS_ERR(musb->clock)) {
+   status = PTR_ERR(musb->clock);
+   musb->clock = NULL;
+   goto fail;
}
 
+   status = clk_enable(musb->clock);
+   if (status < 0)
+   goto fail;
+
/* The musb_platform_init() call:
 *   - adjusts musb->mregs and musb->isr if needed,
 *   - may initialize an integrated tranceiver
@@ -2104,8 +2101,7 @@ fail:
dev_err(musb->controller,
"musb_init_controller failed with status %d\n", status);
 
-   if (musb->clock)
-   clk_put(musb->clock);
+   clk_put(musb->clock);
device_init_wakeup(dev, 0);
musb_free(musb);
 
@@ -2179,9 +2175,6 @@ static int musb_suspend(struct device *dev)
unsigned long   flags;
struct musb *musb = dev_to_musb(&pdev->dev);
 
-   if (!musb->clock)
-   return 0;
-
spin_lock_irqsave(&musb->lock, flags);
 
if (is_peripheral_active(musb)) {
@@ -2194,10 +2187,7 @@ static int musb_suspend(struct device *dev)
 */
}
 
-   if (musb->set_clock)
-   musb->set_clock(musb->clock, 0);
-   else
-   clk_disable(musb->clock);
+   clk_disable(musb->clock);
spin_unlock_irqrestore(&musb->lock, flags);
return 0;
 }
@@ -2207,13 +2197,7 @@ static int musb_resume_noirq(struct device *dev)
struct platform_device *pdev = to_platform_device(dev);
struct musb *musb = dev_to_musb(&pdev->dev);
 
-   if (!musb->clock)
-   return 0;
-
-   if (musb->set_clock)
-   musb->set_clock(musb->clock, 1);
-   else
-   clk_enable(musb->clock);
+   clk_enable(musb->clock);
 
/* for static cmos like DaVinci, register values were preserved
 * unless for some reason the whole soc powered down or the USB
diff --git a/drivers/usb/musb/musb_core.h b/drivers/usb/musb/musb_core.h
index 03d5090..3816d79 100644
--- a/drivers/usb/musb/musb_core.h
+++ b/drivers/usb/musb/musb_core.h
@@ -394,8 +394,6 @@ struct musb {
u8 board_mode;  /* enum musb_mode */
int (*board_set_power)(int state);
 
-   int (*set_clock)(struct clk *clk, int is_active);
-
u8  min_power;  /* vbus for periph, in mA/2 */
 
boolis_host;
diff --git a/drivers/usb/musb/omap2430.c b/drivers/usb/musb/omap2430.c
index 83beeac..b8e2451 100644
--- a/drivers/usb/musb/omap2430.c
+++ b/drivers/usb/musb/omap2430.c

[patch-v2.6.34 6/9] arm: omap: gpmc: avoid section definitions on headers

2009-12-29 Thread Felipe Balbi
trivial patch, no functional changes.

Signed-off-by: Felipe Balbi 
---
 arch/arm/plat-omap/include/plat/gpmc.h |2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/arch/arm/plat-omap/include/plat/gpmc.h 
b/arch/arm/plat-omap/include/plat/gpmc.h
index e081338..3f3609a 100644
--- a/arch/arm/plat-omap/include/plat/gpmc.h
+++ b/arch/arm/plat-omap/include/plat/gpmc.h
@@ -110,6 +110,6 @@ extern void gpmc_prefetch_reset(void);
 extern int gpmc_prefetch_status(void);
 extern void omap3_gpmc_save_context(void);
 extern void omap3_gpmc_restore_context(void);
-extern void __init gpmc_init(void);
+extern void gpmc_init(void);
 
 #endif
-- 
1.6.6.35.g1d85d

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


[patch-v2.6.34 5/9] arm: omap: musb: remove unnecessary return

2009-12-29 Thread Felipe Balbi
trivial patch, no functional changes.

Cc: linux-...@vger.kernel.org
Signed-off-by: Felipe Balbi 
---
 arch/arm/mach-omap2/usb-musb.c |4 +---
 1 files changed, 1 insertions(+), 3 deletions(-)

diff --git a/arch/arm/mach-omap2/usb-musb.c b/arch/arm/mach-omap2/usb-musb.c
index e0050c5..ec8869a 100644
--- a/arch/arm/mach-omap2/usb-musb.c
+++ b/arch/arm/mach-omap2/usb-musb.c
@@ -91,10 +91,8 @@ void __init usb_musb_init(enum musb_mode mode, unsigned 
power)
musb_plat.power = power >> 1;
musb_plat.mode = mode;
 
-   if (platform_device_register(&musb_device) < 0) {
+   if (platform_device_register(&musb_device) < 0)
printk(KERN_ERR "Unable to register HS-USB (MUSB) device\n");
-   return;
-   }
 }
 
 #else
-- 
1.6.6.35.g1d85d

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


[patch-v2.6.34 3/9] arm: omap: musb: remove unused soft_con field

2009-12-29 Thread Felipe Balbi
remove unused data.

Cc: linux-...@vger.kernel.org
Signed-off-by: Felipe Balbi 
---
 arch/arm/mach-omap2/usb-musb.c |1 -
 1 files changed, 0 insertions(+), 1 deletions(-)

diff --git a/arch/arm/mach-omap2/usb-musb.c b/arch/arm/mach-omap2/usb-musb.c
index 4fbb7bc..600286f 100644
--- a/arch/arm/mach-omap2/usb-musb.c
+++ b/arch/arm/mach-omap2/usb-musb.c
@@ -50,7 +50,6 @@ static struct resource musb_resources[] = {
 static struct musb_hdrc_config musb_config = {
.multipoint = 1,
.dyn_fifo   = 1,
-   .soft_con   = 1,
.dma= 1,
.num_eps= 16,
.dma_channels   = 7,
-- 
1.6.6.35.g1d85d

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


[patch-v2.6.34 4/9] arm: omap: musb: remove unused dma data

2009-12-29 Thread Felipe Balbi
we don't use those anywhere on musb driver, so
let's remove those old stuff.

Cc: linux-...@vger.kernel.org
Signed-off-by: Felipe Balbi 
---
 arch/arm/mach-omap2/usb-musb.c |3 ---
 1 files changed, 0 insertions(+), 3 deletions(-)

diff --git a/arch/arm/mach-omap2/usb-musb.c b/arch/arm/mach-omap2/usb-musb.c
index 600286f..e0050c5 100644
--- a/arch/arm/mach-omap2/usb-musb.c
+++ b/arch/arm/mach-omap2/usb-musb.c
@@ -50,10 +50,7 @@ static struct resource musb_resources[] = {
 static struct musb_hdrc_config musb_config = {
.multipoint = 1,
.dyn_fifo   = 1,
-   .dma= 1,
.num_eps= 16,
-   .dma_channels   = 7,
-   .dma_req_chan   = (1 << 0) | (1 << 1) | (1 << 2) | (1 << 3),
.ram_bits   = 12,
 };
 
-- 
1.6.6.35.g1d85d

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


[patch-v2.6.34 2/9] arm: omap: musb: we can use clk framework

2009-12-29 Thread Felipe Balbi
... in order to handle musb's clock. Let's start
removing the old musb-only set_clock function.

Cc: linux-...@vger.kernel.org
Signed-off-by: Felipe Balbi 
---
 arch/arm/mach-omap2/usb-musb.c |   22 --
 1 files changed, 0 insertions(+), 22 deletions(-)

diff --git a/arch/arm/mach-omap2/usb-musb.c b/arch/arm/mach-omap2/usb-musb.c
index 57589ff..4fbb7bc 100644
--- a/arch/arm/mach-omap2/usb-musb.c
+++ b/arch/arm/mach-omap2/usb-musb.c
@@ -47,27 +47,6 @@ static struct resource musb_resources[] = {
},
 };
 
-static int clk_on;
-
-static int musb_set_clock(struct clk *clk, int state)
-{
-   if (state) {
-   if (clk_on > 0)
-   return -ENODEV;
-
-   clk_enable(clk);
-   clk_on = 1;
-   } else {
-   if (clk_on == 0)
-   return -ENODEV;
-
-   clk_disable(clk);
-   clk_on = 0;
-   }
-
-   return 0;
-}
-
 static struct musb_hdrc_config musb_config = {
.multipoint = 1,
.dyn_fifo   = 1,
@@ -81,7 +60,6 @@ static struct musb_hdrc_config musb_config = {
 
 static struct musb_hdrc_platform_data musb_plat = {
/* .clock is set dynamically */
-   .set_clock  = musb_set_clock,
.config = &musb_config,
/* .power   = DYNAMIC, */
/* .mode= DYNAMIC, */
-- 
1.6.6.35.g1d85d

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


[patch-v2.6.34 1/9] arm: omap: musb: remove unused data

2009-12-29 Thread Felipe Balbi
eps_bits wasn't being used anywhere, let's
remove it.

Cc: linux-...@vger.kernel.org
Signed-off-by: Felipe Balbi 
---
 arch/arm/mach-omap2/usb-musb.c |   34 --
 1 files changed, 0 insertions(+), 34 deletions(-)

diff --git a/arch/arm/mach-omap2/usb-musb.c b/arch/arm/mach-omap2/usb-musb.c
index 884336f..57589ff 100644
--- a/arch/arm/mach-omap2/usb-musb.c
+++ b/arch/arm/mach-omap2/usb-musb.c
@@ -68,39 +68,6 @@ static int musb_set_clock(struct clk *clk, int state)
return 0;
 }
 
-static struct musb_hdrc_eps_bits musb_eps[] = {
-   {   "ep1_tx", 10,   },
-   {   "ep1_rx", 10,   },
-   {   "ep2_tx", 9,},
-   {   "ep2_rx", 9,},
-   {   "ep3_tx", 3,},
-   {   "ep3_rx", 3,},
-   {   "ep4_tx", 3,},
-   {   "ep4_rx", 3,},
-   {   "ep5_tx", 3,},
-   {   "ep5_rx", 3,},
-   {   "ep6_tx", 3,},
-   {   "ep6_rx", 3,},
-   {   "ep7_tx", 3,},
-   {   "ep7_rx", 3,},
-   {   "ep8_tx", 2,},
-   {   "ep8_rx", 2,},
-   {   "ep9_tx", 2,},
-   {   "ep9_rx", 2,},
-   {   "ep10_tx", 2,   },
-   {   "ep10_rx", 2,   },
-   {   "ep11_tx", 2,   },
-   {   "ep11_rx", 2,   },
-   {   "ep12_tx", 2,   },
-   {   "ep12_rx", 2,   },
-   {   "ep13_tx", 2,   },
-   {   "ep13_rx", 2,   },
-   {   "ep14_tx", 2,   },
-   {   "ep14_rx", 2,   },
-   {   "ep15_tx", 2,   },
-   {   "ep15_rx", 2,   },
-};
-
 static struct musb_hdrc_config musb_config = {
.multipoint = 1,
.dyn_fifo   = 1,
@@ -110,7 +77,6 @@ static struct musb_hdrc_config musb_config = {
.dma_channels   = 7,
.dma_req_chan   = (1 << 0) | (1 << 1) | (1 << 2) | (1 << 3),
.ram_bits   = 12,
-   .eps_bits   = musb_eps,
 };
 
 static struct musb_hdrc_platform_data musb_plat = {
-- 
1.6.6.35.g1d85d

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


[patch-v2.6.34 0/9] arm omap patches for -next merge window

2009-12-29 Thread Felipe Balbi
Hi Tony,

here are the patches I have prepared for you for
the next merge window.

There's one patch on musb which is a dependency for
for not passing the clk name down to the driver.

The same patch will be going through Greg so you don't
need to queue that patch on your tree.

Felipe Balbi (9):
  arm: omap: musb: remove unused data
  arm: omap: musb: we can use clk framework
  arm: omap: musb: remove unused soft_con field
  arm: omap: musb: remove unused dma data
  arm: omap: musb: remove unnecessary return
  arm: omap: gpmc: avoid section definitions on headers
  usb: musb: use only clk framework for clk handling
  arm: omap: musb: do not pass clock name to driver
  arm: omap: musb: get rid of dyn_fifo

 arch/arm/mach-omap2/usb-musb.c |   71 +---
 arch/arm/plat-omap/include/plat/gpmc.h |2 +-
 drivers/usb/musb/musb_core.c   |   48 +++--
 drivers/usb/musb/musb_core.h   |2 -
 drivers/usb/musb/omap2430.c|   10 +
 drivers/usb/musb/tusb6010.c|   16 +++
 include/linux/usb/musb.h   |4 +-
 7 files changed, 28 insertions(+), 125 deletions(-)

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


[PULL REQUEST] arm omap patches for next -rc

2009-12-29 Thread Felipe Balbi
The following changes since commit
abb74381235a05f15a3b07e9e3831034942c67fb:
  Tony Lindgren (1):
Linux-omap rebuilt: Updated to 2.6.33-rc2, clock fixes merged

are available in the git repository at:

  git://gitorious.org/usb/usb.git for-tony

Felipe Balbi (12):
  arm: omap: musb: ioremap only what's ours
  arm: omap: musb: fix board power budget by passing it to
usb_musb_init
  arm: omap: musb: fix board mode by passing it to usb_musb_init
  arm: omap1: mailbox: kill compile warning
  arm: omap: gpmc: kill compile warning
  arm: omap: kill compile warning in irq.c
  arm: omap: remove unused variables
  arm: omap: io: kill compile warning
  arm: omap: kill compile warning on board-4430-sdp.c
  arm: omap: gpio: kill compile warning in gpio.c
  arm: omap: mailbox: kill compile warning in mailbox.c
  arm: omap: perseus: kill compile warning on board-perseus2.c

 arch/arm/mach-omap1/devices.c|2 +-
 arch/arm/mach-omap1/mailbox.c|9 +++--
 arch/arm/mach-omap2/board-2430sdp.c  |3 ++-
 arch/arm/mach-omap2/board-3430sdp.c  |3 ++-
 arch/arm/mach-omap2/board-4430sdp.c  |4 
 arch/arm/mach-omap2/board-cm-t35.c   |3 ++-
 arch/arm/mach-omap2/board-igep0020.c |3 ++-
 arch/arm/mach-omap2/board-ldp.c  |3 ++-
 arch/arm/mach-omap2/board-omap3beagle.c  |3 ++-
 arch/arm/mach-omap2/board-omap3evm.c |3 ++-
 arch/arm/mach-omap2/board-omap3pandora.c |3 ++-
 arch/arm/mach-omap2/board-omap3touchbook.c   |3 ++-
 arch/arm/mach-omap2/board-overo.c|3 ++-
 arch/arm/mach-omap2/board-rx51.c |3 ++-
 arch/arm/mach-omap2/board-zoom-peripherals.c |3 ++-
 arch/arm/mach-omap2/gpmc.c   |6 --
 arch/arm/mach-omap2/io.c |2 ++
 arch/arm/mach-omap2/irq.c|2 ++
 arch/arm/mach-omap2/mailbox.c|2 +-
 arch/arm/mach-omap2/omap_hwmod_2430.h|2 --
 arch/arm/mach-omap2/usb-musb.c   |   23
+++
 arch/arm/plat-omap/gpio.c|3 +++
 arch/arm/plat-omap/include/plat/fpga.h   |4 ++--
 arch/arm/plat-omap/include/plat/usb.h|3 ++-
 24 files changed, 55 insertions(+), 43 deletions(-)

-- 
balbi

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


[patch-v2.6.33-rc2+ 06/12] arm: omap: kill compile warning in irq.c

2009-12-29 Thread Felipe Balbi
intc_context is only used when omap3 is to be built,
so also put it under ifdef CONFIG_ARM_OMAP3 to avoid
the compile warning.

Signed-off-by: Felipe Balbi 
---
 arch/arm/mach-omap2/irq.c |2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)

diff --git a/arch/arm/mach-omap2/irq.c b/arch/arm/mach-omap2/irq.c
index e9bc782..d370052 100644
--- a/arch/arm/mach-omap2/irq.c
+++ b/arch/arm/mach-omap2/irq.c
@@ -62,7 +62,9 @@ struct omap3_intc_regs {
u32 mir[INTCPS_NR_MIR_REGS];
 };
 
+#ifdef CONFIG_ARCH_OMAP3
 static struct omap3_intc_regs intc_context[ARRAY_SIZE(irq_banks)];
+#endif
 
 /* INTC bank register get/set */
 
-- 
1.6.6.35.g1d85d

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


[patch-v2.6.33-rc2+ 04/12] arm: omap1: mailbox: kill compile warning

2009-12-29 Thread Felipe Balbi
use ioremap and remove unused variable to get rid
of compile warnings.

Signed-off-by: Felipe Balbi 
---
 arch/arm/mach-omap1/devices.c |2 +-
 arch/arm/mach-omap1/mailbox.c |9 +++--
 2 files changed, 8 insertions(+), 3 deletions(-)

diff --git a/arch/arm/mach-omap1/devices.c b/arch/arm/mach-omap1/devices.c
index 23ded2d..9caf51b 100644
--- a/arch/arm/mach-omap1/devices.c
+++ b/arch/arm/mach-omap1/devices.c
@@ -71,7 +71,7 @@ static inline void omap_init_rtc(void) {}
 #  define INT_DSP_MAILBOX1 INT_1610_DSP_MAILBOX1
 #endif
 
-#define OMAP1_MBOX_BASEOMAP1_IO_ADDRESS(OMAP16XX_MAILBOX_BASE)
+#define OMAP1_MBOX_BASEOMAP16XX_MAILBOX_BASE
 
 static struct resource mbox_resources[] = {
{
diff --git a/arch/arm/mach-omap1/mailbox.c b/arch/arm/mach-omap1/mailbox.c
index caf889a..4f5b3da 100644
--- a/arch/arm/mach-omap1/mailbox.c
+++ b/arch/arm/mach-omap1/mailbox.c
@@ -146,7 +146,6 @@ EXPORT_SYMBOL(mbox_dsp_info);
 static int __devinit omap1_mbox_probe(struct platform_device *pdev)
 {
struct resource *res;
-   int ret = 0;
 
if (pdev->num_resources != 2) {
dev_err(&pdev->dev, "invalid number of resources: %d\n",
@@ -160,12 +159,18 @@ static int __devinit omap1_mbox_probe(struct 
platform_device *pdev)
dev_err(&pdev->dev, "invalid mem resource\n");
return -ENODEV;
}
-   mbox_base = res->start;
+
+   mbox_base = ioremap(res->start, resource_size(res));
+   if (!mbox_base) {
+   dev_err(&pdev->dev, "ioremap failed\n");
+   return -ENODEV;
+   }
 
/* DSP IRQ */
res = platform_get_resource(pdev, IORESOURCE_IRQ, 0);
if (unlikely(!res)) {
dev_err(&pdev->dev, "invalid irq resource\n");
+   iounmap(mbox_base);
return -ENODEV;
}
mbox_dsp_info.irq = res->start;
-- 
1.6.6.35.g1d85d

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


[patch-v2.6.33-rc2+ 09/12] arm: omap: kill compile warning on board-4430-sdp.c

2009-12-29 Thread Felipe Balbi
sdp4430_uart_config isn't used anywhere, so remove it.

Signed-off-by: Felipe Balbi 
---
 arch/arm/mach-omap2/board-4430sdp.c |4 
 1 files changed, 0 insertions(+), 4 deletions(-)

diff --git a/arch/arm/mach-omap2/board-4430sdp.c 
b/arch/arm/mach-omap2/board-4430sdp.c
index 0c6be6b..a7788b4 100644
--- a/arch/arm/mach-omap2/board-4430sdp.c
+++ b/arch/arm/mach-omap2/board-4430sdp.c
@@ -38,10 +38,6 @@ static struct platform_device *sdp4430_devices[] __initdata 
= {
&sdp4430_lcd_device,
 };
 
-static struct omap_uart_config sdp4430_uart_config __initdata = {
-   .enabled_uarts  = (1 << 0) | (1 << 1) | (1 << 2) | (1 << 3),
-};
-
 static struct omap_lcd_config sdp4430_lcd_config __initdata = {
.ctrl_name  = "internal",
 };
-- 
1.6.6.35.g1d85d

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


[patch-v2.6.33-rc2+ 07/12] arm: omap: remove unused variables

2009-12-29 Thread Felipe Balbi
those are never used, remove it until we need to
actually use them to avoid the compile warning.

Signed-off-by: Felipe Balbi 
---
 arch/arm/mach-omap2/omap_hwmod_2430.h |2 --
 1 files changed, 0 insertions(+), 2 deletions(-)

diff --git a/arch/arm/mach-omap2/omap_hwmod_2430.h 
b/arch/arm/mach-omap2/omap_hwmod_2430.h
index 59a208b..49139ad 100644
--- a/arch/arm/mach-omap2/omap_hwmod_2430.h
+++ b/arch/arm/mach-omap2/omap_hwmod_2430.h
@@ -62,8 +62,6 @@ static struct omap_hwmod omap2430_l3_hwmod = {
 };
 
 static struct omap_hwmod omap2430_l4_wkup_hwmod;
-static struct omap_hwmod omap2430_mmc1_hwmod;
-static struct omap_hwmod omap2430_mmc2_hwmod;
 
 /* L4_CORE -> L4_WKUP interface */
 static struct omap_hwmod_ocp_if omap2430_l4_core__l4_wkup = {
-- 
1.6.6.35.g1d85d

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


[patch-v2.6.33-rc2+ 08/12] arm: omap: io: kill compile warning

2009-12-29 Thread Felipe Balbi
when building omap4 defconfigs, io.c will warn about unused
_omap2_init_reprogram_sdrc, that's because that functio is
only used ifndef CONFIG_ARCH_OMAP4, so add the missing
ifndef CONFIG_ARCH_OMAP4 to _omap2_init_reprogram_sdrc
definition.

Signed-off-by: Felipe Balbi 
---
 arch/arm/mach-omap2/io.c |2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)

diff --git a/arch/arm/mach-omap2/io.c b/arch/arm/mach-omap2/io.c
index 5a79964..9e868fa 100644
--- a/arch/arm/mach-omap2/io.c
+++ b/arch/arm/mach-omap2/io.c
@@ -276,6 +276,7 @@ void __init omap2_map_common_io(void)
  * -EINVAL if the dpll3_m2_ck cannot be found, 0 if called on OMAP2,
  * or passes along the return value of clk_set_rate().
  */
+#ifndef CONFIG_ARCH_OMAP4
 static int __init _omap2_init_reprogram_sdrc(void)
 {
struct clk *dpll3_m2_ck;
@@ -299,6 +300,7 @@ static int __init _omap2_init_reprogram_sdrc(void)
 
return v;
 }
+#endif
 
 void __init omap2_init_common_hw(struct omap_sdrc_params *sdrc_cs0,
 struct omap_sdrc_params *sdrc_cs1)
-- 
1.6.6.35.g1d85d

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


[patch-v2.6.33-rc2+ 05/12] arm: omap: gpmc: kill compile warning

2009-12-29 Thread Felipe Balbi
Get rid of the following warnings:

arch/arm/mach-omap2/gpmc.c:550:30: warning: non-ANSI
function declaration of function 'omap3_gpmc_save_context'

arch/arm/mach-omap2/gpmc.c:581:33: warning: non-ANSI
function declaration of function 'omap3_gpmc_restore_context'

Signed-off-by: Felipe Balbi 
---
 arch/arm/mach-omap2/gpmc.c |6 --
 1 files changed, 4 insertions(+), 2 deletions(-)

diff --git a/arch/arm/mach-omap2/gpmc.c b/arch/arm/mach-omap2/gpmc.c
index bd8cb59..32f2c51 100644
--- a/arch/arm/mach-omap2/gpmc.c
+++ b/arch/arm/mach-omap2/gpmc.c
@@ -547,9 +547,10 @@ void __init gpmc_init(void)
 #ifdef CONFIG_ARCH_OMAP3
 static struct omap3_gpmc_regs gpmc_context;
 
-void omap3_gpmc_save_context()
+void omap3_gpmc_save_context(void)
 {
int i;
+
gpmc_context.sysconfig = gpmc_read_reg(GPMC_SYSCONFIG);
gpmc_context.irqenable = gpmc_read_reg(GPMC_IRQENABLE);
gpmc_context.timeout_ctrl = gpmc_read_reg(GPMC_TIMEOUT_CONTROL);
@@ -578,9 +579,10 @@ void omap3_gpmc_save_context()
}
 }
 
-void omap3_gpmc_restore_context()
+void omap3_gpmc_restore_context(void)
 {
int i;
+
gpmc_write_reg(GPMC_SYSCONFIG, gpmc_context.sysconfig);
gpmc_write_reg(GPMC_IRQENABLE, gpmc_context.irqenable);
gpmc_write_reg(GPMC_TIMEOUT_CONTROL, gpmc_context.timeout_ctrl);
-- 
1.6.6.35.g1d85d

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


[patch-v2.6.33-rc2+ 01/12] arm: omap: musb: ioremap only what's ours

2009-12-29 Thread Felipe Balbi
omap3430 TRM says the OTG address space is 4k, not 8k.

Cc: linux-...@vger.kernel.org
Signed-off-by: Felipe Balbi 
---
 arch/arm/mach-omap2/usb-musb.c |2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/arch/arm/mach-omap2/usb-musb.c b/arch/arm/mach-omap2/usb-musb.c
index a80441d..ba71f76 100644
--- a/arch/arm/mach-omap2/usb-musb.c
+++ b/arch/arm/mach-omap2/usb-musb.c
@@ -152,7 +152,7 @@ void __init usb_musb_init(void)
musb_resources[0].start = OMAP243X_HS_BASE;
else
musb_resources[0].start = OMAP34XX_HSUSB_OTG_BASE;
-   musb_resources[0].end = musb_resources[0].start + SZ_8K - 1;
+   musb_resources[0].end = musb_resources[0].start + SZ_4K - 1;
 
/*
 * REVISIT: This line can be removed once all the platforms using
-- 
1.6.6.35.g1d85d

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


[patch-v2.6.33-rc2+ 03/12] arm: omap: musb: fix board mode by passing it to usb_musb_init

2009-12-29 Thread Felipe Balbi
each board will have a different mode which is peculiar
to that board.

Cc: linux-...@vger.kernel.org
Signed-off-by: Felipe Balbi 
---
 arch/arm/mach-omap2/board-2430sdp.c  |3 ++-
 arch/arm/mach-omap2/board-3430sdp.c  |3 ++-
 arch/arm/mach-omap2/board-cm-t35.c   |3 ++-
 arch/arm/mach-omap2/board-igep0020.c |3 ++-
 arch/arm/mach-omap2/board-ldp.c  |3 ++-
 arch/arm/mach-omap2/board-omap3beagle.c  |3 ++-
 arch/arm/mach-omap2/board-omap3evm.c |3 ++-
 arch/arm/mach-omap2/board-omap3pandora.c |3 ++-
 arch/arm/mach-omap2/board-omap3touchbook.c   |3 ++-
 arch/arm/mach-omap2/board-overo.c|3 ++-
 arch/arm/mach-omap2/board-rx51.c |3 ++-
 arch/arm/mach-omap2/board-zoom-peripherals.c |3 ++-
 arch/arm/mach-omap2/usb-musb.c   |   13 -
 arch/arm/plat-omap/include/plat/usb.h|3 ++-
 14 files changed, 30 insertions(+), 22 deletions(-)

diff --git a/arch/arm/mach-omap2/board-2430sdp.c 
b/arch/arm/mach-omap2/board-2430sdp.c
index d3857d6..45d3197 100644
--- a/arch/arm/mach-omap2/board-2430sdp.c
+++ b/arch/arm/mach-omap2/board-2430sdp.c
@@ -23,6 +23,7 @@
 #include 
 #include 
 #include 
+#include 
 
 #include 
 #include 
@@ -203,7 +204,7 @@ static void __init omap_2430sdp_init(void)
platform_add_devices(sdp2430_devices, ARRAY_SIZE(sdp2430_devices));
omap_serial_init();
twl4030_mmc_init(mmc);
-   usb_musb_init(100);
+   usb_musb_init(MUSB_OTG, 100);
board_smc91x_init();
 
/* Turn off secondary LCD backlight */
diff --git a/arch/arm/mach-omap2/board-3430sdp.c 
b/arch/arm/mach-omap2/board-3430sdp.c
index 1d52fd1..37e7328 100644
--- a/arch/arm/mach-omap2/board-3430sdp.c
+++ b/arch/arm/mach-omap2/board-3430sdp.c
@@ -24,6 +24,7 @@
 #include 
 #include 
 #include 
+#include 
 
 #include 
 #include 
@@ -664,7 +665,7 @@ static void __init omap_3430sdp_init(void)
ARRAY_SIZE(sdp3430_spi_board_info));
ads7846_dev_init();
omap_serial_init();
-   usb_musb_init(100);
+   usb_musb_init(MUSB_OTG, 100);
board_smc91x_init();
sdp3430_display_init();
enable_board_wakeup_source();
diff --git a/arch/arm/mach-omap2/board-cm-t35.c 
b/arch/arm/mach-omap2/board-cm-t35.c
index 56922f4..9d5db6b 100644
--- a/arch/arm/mach-omap2/board-cm-t35.c
+++ b/arch/arm/mach-omap2/board-cm-t35.c
@@ -27,6 +27,7 @@
 #include 
 #include 
 #include 
+#include 
 
 #include 
 #include 
@@ -585,7 +586,7 @@ static void __init cm_t35_init(void)
cm_t35_init_ethernet();
cm_t35_init_led();
 
-   usb_musb_init(100);
+   usb_musb_init(MUSB_OTG, 100);
 }
 
 MACHINE_START(CM_T35, "Compulab CM-T35")
diff --git a/arch/arm/mach-omap2/board-igep0020.c 
b/arch/arm/mach-omap2/board-igep0020.c
index 16be1d5..6fc0608 100644
--- a/arch/arm/mach-omap2/board-igep0020.c
+++ b/arch/arm/mach-omap2/board-igep0020.c
@@ -17,6 +17,7 @@
 #include 
 #include 
 #include 
+#include 
 
 #include 
 #include 
@@ -216,7 +217,7 @@ static void __init igep2_init(void)
omap3_mux_init(board_mux, OMAP_PACKAGE_CBB);
igep2_i2c_init();
omap_serial_init();
-   usb_musb_init(100);
+   usb_musb_init(MUSB_OTG, 100);
 
igep2_init_smsc911x();
 
diff --git a/arch/arm/mach-omap2/board-ldp.c b/arch/arm/mach-omap2/board-ldp.c
index ca2acd2..7e8c8a8 100644
--- a/arch/arm/mach-omap2/board-ldp.c
+++ b/arch/arm/mach-omap2/board-ldp.c
@@ -27,6 +27,7 @@
 #include 
 #include 
 #include 
+#include 
 
 #include 
 #include 
@@ -394,7 +395,7 @@ static void __init omap_ldp_init(void)
ARRAY_SIZE(ldp_spi_board_info));
ads7846_dev_init();
omap_serial_init();
-   usb_musb_init(100);
+   usb_musb_init(MUSB_OTG, 100);
 
twl4030_mmc_init(mmc);
/* link regulators to MMC adapters */
diff --git a/arch/arm/mach-omap2/board-omap3beagle.c 
b/arch/arm/mach-omap2/board-omap3beagle.c
index 52f65e6..17f6381 100644
--- a/arch/arm/mach-omap2/board-omap3beagle.c
+++ b/arch/arm/mach-omap2/board-omap3beagle.c
@@ -23,6 +23,7 @@
 #include 
 #include 
 #include 
+#include 
 
 #include 
 #include 
@@ -443,7 +444,7 @@ static void __init omap3_beagle_init(void)
/* REVISIT leave DVI powered down until it's needed ... */
gpio_direction_output(170, true);
 
-   usb_musb_init(100);
+   usb_musb_init(MUSB_OTG, 100);
usb_ehci_init(&ehci_pdata);
omap3beagle_flash_init();
 
diff --git a/arch/arm/mach-omap2/board-omap3evm.c 
b/arch/arm/mach-omap2/board-omap3evm.c
index c5fd85d..1160004 100644
--- a/arch/arm/mach-omap2/board-omap3evm.c
+++ b/arch/arm/mach-omap2/board-omap3evm.c
@@ -23,6 +23,7 @@
 #include 
 #include 
 #include 
+#include 
 
 #include 
 #include 
@@ -469,7 +470,7 @@ static void __init omap3_evm_init(void)
omap_mux_init_gpio(135, OMAP_PIN_OUTPUT);
ehci_pdata.reset_gpio_

[patch-v2.6.33-rc2+ 02/12] arm: omap: musb: fix board power budget by passing it to usb_musb_init

2009-12-29 Thread Felipe Balbi
each board might have a different charge pump and
thus able to source more or less current on vbus
so let power be easily configurable.

Cc: linux-...@vger.kernel.org
Signed-off-by: Felipe Balbi 
---
 arch/arm/mach-omap2/board-2430sdp.c  |2 +-
 arch/arm/mach-omap2/board-3430sdp.c  |2 +-
 arch/arm/mach-omap2/board-cm-t35.c   |2 +-
 arch/arm/mach-omap2/board-igep0020.c |2 +-
 arch/arm/mach-omap2/board-ldp.c  |2 +-
 arch/arm/mach-omap2/board-omap3beagle.c  |2 +-
 arch/arm/mach-omap2/board-omap3evm.c |2 +-
 arch/arm/mach-omap2/board-omap3pandora.c |2 +-
 arch/arm/mach-omap2/board-omap3touchbook.c   |2 +-
 arch/arm/mach-omap2/board-overo.c|2 +-
 arch/arm/mach-omap2/board-rx51.c |2 +-
 arch/arm/mach-omap2/board-zoom-peripherals.c |2 +-
 arch/arm/mach-omap2/usb-musb.c   |   12 
 arch/arm/plat-omap/include/plat/usb.h|2 +-
 14 files changed, 17 insertions(+), 21 deletions(-)

diff --git a/arch/arm/mach-omap2/board-2430sdp.c 
b/arch/arm/mach-omap2/board-2430sdp.c
index e508904..d3857d6 100644
--- a/arch/arm/mach-omap2/board-2430sdp.c
+++ b/arch/arm/mach-omap2/board-2430sdp.c
@@ -203,7 +203,7 @@ static void __init omap_2430sdp_init(void)
platform_add_devices(sdp2430_devices, ARRAY_SIZE(sdp2430_devices));
omap_serial_init();
twl4030_mmc_init(mmc);
-   usb_musb_init();
+   usb_musb_init(100);
board_smc91x_init();
 
/* Turn off secondary LCD backlight */
diff --git a/arch/arm/mach-omap2/board-3430sdp.c 
b/arch/arm/mach-omap2/board-3430sdp.c
index c90b0d0..1d52fd1 100644
--- a/arch/arm/mach-omap2/board-3430sdp.c
+++ b/arch/arm/mach-omap2/board-3430sdp.c
@@ -664,7 +664,7 @@ static void __init omap_3430sdp_init(void)
ARRAY_SIZE(sdp3430_spi_board_info));
ads7846_dev_init();
omap_serial_init();
-   usb_musb_init();
+   usb_musb_init(100);
board_smc91x_init();
sdp3430_display_init();
enable_board_wakeup_source();
diff --git a/arch/arm/mach-omap2/board-cm-t35.c 
b/arch/arm/mach-omap2/board-cm-t35.c
index 2626a9f..56922f4 100644
--- a/arch/arm/mach-omap2/board-cm-t35.c
+++ b/arch/arm/mach-omap2/board-cm-t35.c
@@ -585,7 +585,7 @@ static void __init cm_t35_init(void)
cm_t35_init_ethernet();
cm_t35_init_led();
 
-   usb_musb_init();
+   usb_musb_init(100);
 }
 
 MACHINE_START(CM_T35, "Compulab CM-T35")
diff --git a/arch/arm/mach-omap2/board-igep0020.c 
b/arch/arm/mach-omap2/board-igep0020.c
index 117b8fd..16be1d5 100644
--- a/arch/arm/mach-omap2/board-igep0020.c
+++ b/arch/arm/mach-omap2/board-igep0020.c
@@ -216,7 +216,7 @@ static void __init igep2_init(void)
omap3_mux_init(board_mux, OMAP_PACKAGE_CBB);
igep2_i2c_init();
omap_serial_init();
-   usb_musb_init();
+   usb_musb_init(100);
 
igep2_init_smsc911x();
 
diff --git a/arch/arm/mach-omap2/board-ldp.c b/arch/arm/mach-omap2/board-ldp.c
index 995d4a2..ca2acd2 100644
--- a/arch/arm/mach-omap2/board-ldp.c
+++ b/arch/arm/mach-omap2/board-ldp.c
@@ -394,7 +394,7 @@ static void __init omap_ldp_init(void)
ARRAY_SIZE(ldp_spi_board_info));
ads7846_dev_init();
omap_serial_init();
-   usb_musb_init();
+   usb_musb_init(100);
 
twl4030_mmc_init(mmc);
/* link regulators to MMC adapters */
diff --git a/arch/arm/mach-omap2/board-omap3beagle.c 
b/arch/arm/mach-omap2/board-omap3beagle.c
index 231cb4e..52f65e6 100644
--- a/arch/arm/mach-omap2/board-omap3beagle.c
+++ b/arch/arm/mach-omap2/board-omap3beagle.c
@@ -443,7 +443,7 @@ static void __init omap3_beagle_init(void)
/* REVISIT leave DVI powered down until it's needed ... */
gpio_direction_output(170, true);
 
-   usb_musb_init();
+   usb_musb_init(100);
usb_ehci_init(&ehci_pdata);
omap3beagle_flash_init();
 
diff --git a/arch/arm/mach-omap2/board-omap3evm.c 
b/arch/arm/mach-omap2/board-omap3evm.c
index 34de178..c5fd85d 100644
--- a/arch/arm/mach-omap2/board-omap3evm.c
+++ b/arch/arm/mach-omap2/board-omap3evm.c
@@ -469,7 +469,7 @@ static void __init omap3_evm_init(void)
omap_mux_init_gpio(135, OMAP_PIN_OUTPUT);
ehci_pdata.reset_gpio_port[1] = 135;
}
-   usb_musb_init();
+   usb_musb_init(100);
usb_ehci_init(&ehci_pdata);
ads7846_dev_init();
omap3evm_init_smsc911x();
diff --git a/arch/arm/mach-omap2/board-omap3pandora.c 
b/arch/arm/mach-omap2/board-omap3pandora.c
index ef17cf1..b0cdf77 100644
--- a/arch/arm/mach-omap2/board-omap3pandora.c
+++ b/arch/arm/mach-omap2/board-omap3pandora.c
@@ -413,7 +413,7 @@ static void __init omap3pandora_init(void)
omap3pandora_ads7846_init();
usb_ehci_init(&ehci_pdata);
pandora_keys_gpio_init();
-   usb_musb_init();
+   usb_musb_init(100);
 
  

[patch-v2.6.33-rc2+ 00/12] arm omap patches for next -rc

2009-12-29 Thread Felipe Balbi
Hi Tony,

there are the patches I have for you for the next -rc

as per your request, they are now being sent to LAKML
and linux-usb.

Felipe Balbi (12):
  arm: omap: musb: ioremap only what's ours
  arm: omap: musb: fix board power budget by passing it to
usb_musb_init
  arm: omap: musb: fix board mode by passing it to usb_musb_init
  arm: omap1: mailbox: kill compile warning
  arm: omap: gpmc: kill compile warning
  arm: omap: kill compile warning in irq.c
  arm: omap: remove unused variables
  arm: omap: io: kill compile warning
  arm: omap: kill compile warning on board-4430-sdp.c
  arm: omap: gpio: kill compile warning in gpio.c
  arm: omap: mailbox: kill compile warning in mailbox.c
  arm: omap: perseus: kill compile warning on board-perseus2.c

 arch/arm/mach-omap1/devices.c|2 +-
 arch/arm/mach-omap1/mailbox.c|9 +++--
 arch/arm/mach-omap2/board-2430sdp.c  |3 ++-
 arch/arm/mach-omap2/board-3430sdp.c  |3 ++-
 arch/arm/mach-omap2/board-4430sdp.c  |4 
 arch/arm/mach-omap2/board-cm-t35.c   |3 ++-
 arch/arm/mach-omap2/board-igep0020.c |3 ++-
 arch/arm/mach-omap2/board-ldp.c  |3 ++-
 arch/arm/mach-omap2/board-omap3beagle.c  |3 ++-
 arch/arm/mach-omap2/board-omap3evm.c |3 ++-
 arch/arm/mach-omap2/board-omap3pandora.c |3 ++-
 arch/arm/mach-omap2/board-omap3touchbook.c   |3 ++-
 arch/arm/mach-omap2/board-overo.c|3 ++-
 arch/arm/mach-omap2/board-rx51.c |3 ++-
 arch/arm/mach-omap2/board-zoom-peripherals.c |3 ++-
 arch/arm/mach-omap2/gpmc.c   |6 --
 arch/arm/mach-omap2/io.c |2 ++
 arch/arm/mach-omap2/irq.c|2 ++
 arch/arm/mach-omap2/mailbox.c|2 +-
 arch/arm/mach-omap2/omap_hwmod_2430.h|2 --
 arch/arm/mach-omap2/usb-musb.c   |   23 +++
 arch/arm/plat-omap/gpio.c|3 +++
 arch/arm/plat-omap/include/plat/fpga.h   |4 ++--
 arch/arm/plat-omap/include/plat/usb.h|3 ++-
 24 files changed, 55 insertions(+), 43 deletions(-)

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


Re: [PATCH 0/5] V7/Cortex/omap34xx fixes for 2.6.33-rc1: DCC, kexec, atags

2009-12-29 Thread Tony Lindgren
Hi,

* Magnus Damm  [091227 21:54]:
> Hi Tony,
> 
> On Sat, Dec 19, 2009 at 12:45 PM, Tony Lindgren  wrote:
> > Here are some v7 fixes, mostly to make kexec work.
> >
> > Using 2.6.33-rc1, these fixes, and kexec from kexec-tools
> > git repo, I can reboot my n900 in a loop reliably.
> 
> Thanks for your work on this. I previously tested kexec on ARM V6 and
> V7 and noticed that V7 didn't work. I revisited my V7 test after
> becoming aware of your patches. The single patch below unbreaks V7 on
> my target system.
> 
> > Ā  Ā  Ā arm: Fix cpu_proc_fin() for proc-v7.S and make kexec work

Cool. Thank you for fixing the kexec source :)

Are you seeing the occasional crc errors when uncompressing the
new kernel on your v7?

I'm seeing those maybe 1 out of 10 times on omap3430 boards unless if
I do an extra (and wrong) flush_cache_all after local_flush_tlb_all
at the end of setup_mm_for_reboot.

If you're not seeing the crc errors, do you have L2 cache on?

Also, what's the Cortex version on your v7? It's rev r2p3 on
omap3430.

Regards,

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


Re: Issue in oamp nand driver with 32-bit reads in prefetch mode

2009-12-29 Thread Steve Sakoman
On Tue, Dec 29, 2009 at 12:38 PM, Steve Sakoman  wrote:

> I can confirm that this issue exists on Overo too.  Sadly, switching
> to 16 bit reads does not fix the issue for me.  I'll start digging to
> see if I can find what's broken.

I can also confirm that there are days when I am not even capable of
applying a patch properly :-(

Switching to 16 bit read accesses does indeed fix the ECC issue on Overo too.

Which still leaves us needing to find the root cause of the breakage . . .

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


Re: [PATCH] OMAP2: add USB platform data and initialization for Nokia N800 and N810

2009-12-29 Thread Luke-Jr
On Tuesday 29 December 2009 02:55:46 am Kalle Valo wrote:
> Having lots of small files is difficult IMHO.

The last-working N8x0 support (Linux-OMAP 2.6.30-rc8) required 1706 lines of 
platform data and initialization, split up into 6 files:
590 N800 + i2c + FM + keyboard + light sensor + LED + LCD + temp + 
SPI + WiFi
 + touchscreen + OneNAND
47  N810
175 USB
362 MMC
156 DSP
376 camera

The largest OMAP2 single-board file is merely 689 lines (3430sdp).
N900/RX-51, totalling 863 lines itself, is split over 2 files.

I think 4 or 5 files with ~350 lines is more manageable than a single 1700-
line board file, especially when considering that parts depend on multiple 
configuration options (LCD, which turns out to be a 128-line file, depends on 
3 config options: N8x0, Blizzard, and MIPID).

Thoughts?

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


Re: [PATCH 6/8] arm: omap: musb: pass power to usb_musb_init

2009-12-29 Thread Tony Lindgren
* Tony Lindgren  [091229 12:00]:
> * Felipe Balbi  [091229 11:54]:
> > On Tue, 2009-12-29 at 21:53 +0200, Felipe Balbi wrote:
> > > On Tue, 2009-12-29 at 11:51 -0800, Tony Lindgren wrote:
> > > > * Felipe Balbi  [091228 03:10]:
> > > > > each board might have a different charge pump and
> > > > > thus able to source more or less current on vbus
> > > > > so let power be easily configurable.
> > > > 
> > > > In order to justify merging this as a fix, can you please update
> > > > the subject and description to describe that this fixes the
> > > > the power value ?
> > > 
> > > for sure, doing it right now.
> > 
> > How about now ? (did the same to the board mode)
> > 
> > commit 860a17d3dc78cc8c640a83ade83dd0ec4f1217f1
> > Author: Felipe Balbi 
> > Date:   Mon Dec 28 00:46:19 2009 +0200
> > 
> > arm: omap: musb: fix board mode by passing it to usb_musb_init
> > 
> > each board will have a different mode which is peculiar
> > to that board.
> > 
> > Signed-off-by: Felipe Balbi 
> > 
> > commit 86b92c438109a95c20fad62804b4b8040f3676b7
> > Author: Felipe Balbi 
> > Date:   Mon Dec 28 00:30:42 2009 +0200
> > 
> > arm: omap: musb: fix board power budget by passing it to
> > usb_musb_init
> > 
> > each board might have a different charge pump and
> > thus able to source more or less current on vbus
> > so let power be easily configurable.
> > 
> > Signed-off-by: Felipe Balbi 
> 
> Sounds good to me.

Oh one more thing: Can you please repost the series one more
time with LAKML Cc'd? We should have all the arch/arm/*omap*/
patches reviewed there too. Maybe Cc linux-usb too?

Regards,

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


Re: Issue in oamp nand driver with 32-bit reads in prefetch mode

2009-12-29 Thread Steve Sakoman
On Wed, Dec 23, 2009 at 9:44 AM, Tony Lindgren  wrote:
> * Vimal Singh  [091223 01:32]:
>> In omap nand driver we used to do 32-bit reads (in function
>> omap_read_buf_pref, using 'ioread32_rep' i.e.: __raw_readsl), and it
>> was working fine till some time back. But now, somehow, this has got
>> some problem. Reads are not being done successfully, and driver gives
>> lots for error reprot like below:
>>
>> td->read(0x604 bytes from 0x1fc) returned ECC error
>> uncorrectable error :
>> uncorrectable error :
>> uncorrectable error :
>> uncorrectable error :
>> uncorrectable error :
>> uncorrectable error :
>> mtd->read(0x520 bytes from 0x2e0) returned ECC error
>>
>> While if we change 32-bit reads to 16-bit reads (using 'ioread16_rep'
>> i.e.: __raw_readwl) makes it working fine. (A patch to do this is
>> listed below at the bottom of this mail.)
>>
>> I have not seen any change in routine '__raw_readsl'.
>> So, could someone help me find out the root cause the issue?
>>
>> Thanks for any input.
>
> Maybe an issue with the GPMC timings?

I can confirm that this issue exists on Overo too.  Sadly, switching
to 16 bit reads does not fix the issue for me.  I'll start digging to
see if I can find what's broken.

Steve


> Regards,
>
> Tony
>
>>
>> --
>> Regards,
>> Vimal Singh
>>
>> diff --git a/drivers/mtd/nand/omap2.c b/drivers/mtd/nand/omap2.c
>> index aaef170..dc493f5 100644
>> --- a/drivers/mtd/nand/omap2.c
>> +++ b/drivers/mtd/nand/omap2.c
>> @@ -288,14 +288,14 @@ static void omap_read_buf_pref(struct mtd_info
>> Ā  Ā  Ā  Ā  Ā  Ā  Ā  Ā  Ā  Ā  Ā  Ā  Ā  Ā  Ā  Ā  Ā  Ā  Ā  Ā  Ā  Ā  Ā  struct omap_nand_info, mtd);
>> Ā  Ā  Ā  uint32_t pfpw_status = 0, r_count = 0;
>> Ā  Ā  Ā  int ret = 0;
>> - Ā  Ā  u32 *p = (u32 *)buf;
>> + Ā  Ā  u16 *p = (u16 *)buf;
>>
>> Ā  Ā  Ā  /* take care of subpage reads */
>> - Ā  Ā  for (; len % 4 != 0; ) {
>> + Ā  Ā  for (; len % 2 != 0; ) {
>> Ā  Ā  Ā  Ā  Ā  Ā  Ā  *buf++ = __raw_readb(info->nand.IO_ADDR_R);
>> Ā  Ā  Ā  Ā  Ā  Ā  Ā  len--;
>> Ā  Ā  Ā  }
>> - Ā  Ā  p = (u32 *) buf;
>> + Ā  Ā  p = (u16 *) buf;
>>
>> Ā  Ā  Ā  /* configure and start prefetch transfer */
>> Ā  Ā  Ā  ret = gpmc_prefetch_enable(info->gpmc_cs, 0x0, len, 0x0);
>> @@ -308,10 +308,10 @@ static void omap_read_buf_pref(struct mtd_info
>> *mtd, u_char *buf, int len)
>> Ā  Ā  Ā  } else {
>> Ā  Ā  Ā  Ā  Ā  Ā  Ā  do {
>> Ā  Ā  Ā  Ā  Ā  Ā  Ā  Ā  Ā  Ā  Ā  pfpw_status = gpmc_prefetch_status();
>> - Ā  Ā  Ā  Ā  Ā  Ā  Ā  Ā  Ā  Ā  r_count = ((pfpw_status >> 24) & 0x7F) >> 2;
>> - Ā  Ā  Ā  Ā  Ā  Ā  Ā  Ā  Ā  Ā  ioread32_rep(info->nand_pref_fifo_add, p, r_count);
>> + Ā  Ā  Ā  Ā  Ā  Ā  Ā  Ā  Ā  Ā  r_count = ((pfpw_status >> 24) & 0x7F) >> 1;
>> + Ā  Ā  Ā  Ā  Ā  Ā  Ā  Ā  Ā  Ā  ioread16_rep(info->nand_pref_fifo_add, p, r_count);
>> Ā  Ā  Ā  Ā  Ā  Ā  Ā  Ā  Ā  Ā  Ā  p += r_count;
>> - Ā  Ā  Ā  Ā  Ā  Ā  Ā  Ā  Ā  Ā  len -= r_count << 2;
>> + Ā  Ā  Ā  Ā  Ā  Ā  Ā  Ā  Ā  Ā  len -= r_count << 1;
>> Ā  Ā  Ā  Ā  Ā  Ā  Ā  } while (len);
>>
>> Ā  Ā  Ā  Ā  Ā  Ā  Ā  /* disable and stop the PFPW engine */
>> --
>> To unsubscribe from this list: send the line "unsubscribe linux-omap" in
>> the body of a message to majord...@vger.kernel.org
>> More majordomo info at Ā http://vger.kernel.org/majordomo-info.html
> --
> To unsubscribe from this list: send the line "unsubscribe linux-omap" in
> the body of a message to majord...@vger.kernel.org
> More majordomo info at Ā http://vger.kernel.org/majordomo-info.html
>
--
To unsubscribe from this list: send the line "unsubscribe linux-omap" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH] OMAP2: add USB platform data and initialization for Nokia N800 and N810

2009-12-29 Thread Felipe Balbi
On Tue, 2009-12-29 at 14:28 -0600, Luke-Jr wrote:
> Quick followup... I haven't had the chance to make those clock changes or 
> move 
> it into the main board file yet, but just discovered my recent boot problems 
> were "fixed" by disabling USB support, so apparently there's something else 
> broken with my patch. :(
> 
> Unfortunately, without a trackback, I'm totally lost:
> 
> Unable to handle kernel NULL pointer dereference at virtual address 0031
> pgd = c0004000
> [0031] *pgd=0
> Internal error: Oops: 17 [#1] PREEMPT

can you post the entire trace ?

I need the function call trace that BUG() prints

-- 
balbi

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


wl1251: crash in /sys/module/wl1251_spi/notes

2009-12-29 Thread Kalle Valo
Hello,

I noticed that wl1251_spi was crashing while rmmoding it with 2.6.33
kernels (from wireless-testing) on a nokia n900 (rx51_defconfig plus
some changes). [1] 

I did some investigation and I think kernel/module.c is adding sysfs
file with a null string as the name and that causes the crash during
rmmod while the sysfs file is removed. For example, I can crash the
kernel just by executing this command: [2]

ls -a /sys/module/wl1251_spi/notes

This happens everytime with wl1251_spi, but not with other modules.
For example wl1251 seems to work fine:

Nokia-N900-42-9:~# ls -a /sys/module/wl1251/notes/
.   ..  .note.gnu.build-id
Nokia-N900-42-9:~# 

The toolchain I'm using:

gcc version 4.4.1 (Sourcery G++ Lite 2009q3-67) 

Any ideas how to debug this further? Anyone seen, or heard, about
similar problems? I didn't notice this problem on 2.6.32 with the same
setup.

[1] crash log from rmmod wl1251_spi:

[ 3856.875579] wl1251: unloaded
[ 3856.878784] Unable to handle kernel NULL pointer dereference at
virtual address 
[ 3856.887084] pgd = cd02c000
[ 3856.889892] [] *pgd=8d78d031, *pte=, *ppte=
[ 3856.896270] Internal error: Oops: 17 [#1]
[ 3856.900329] last sysfs file: /sys/class/net/wlan0/flags
[ 3856.905609] Modules linked in: wl1251 mac80211 cfg80211 [last
unloaded: wl1251_spi]
[ 3856.913421] CPU: 0Not tainted  (2.6.33-rc2-wl-47089-g7bfbe2a
#449)
[ 3856.920013] PC is at strcmp+0x4/0x34
[ 3856.923645] LR is at sysfs_find_dirent+0x18/0x38
[ 3856.928344] pc : []lr : []psr: a013
[ 3856.928344] sp : cd073f00  ip :   fp : bea5767c
[ 3856.939941] r10:   r9 : cd072000  r8 : c002bae4
[ 3856.945220] r7 : bea54de8  r6 :   r5 :   r4 :
cd031458
[ 3856.951812] r3 :   r2 : ffd0  r1 :   r0 :

[ 3856.958404] Flags: NzCv  IRQs on  FIQs on  Mode SVC_32  ISA ARM
Segment user
[ 3856.965637] Control: 10c5387d  Table: 8d02c019  DAC: 0015
[ 3856.971435] Process rmmod (pid: 4930, stack limit = 0xcd0722e8)
[ 3856.977416] Stack: (0xcd073f00 to 0xcd074000)
[ 3856.981842] 3f00:  cd031488 cd073f10 c00f4c94 cd031488
 cfa4df00 
[ 3856.990112] 3f20: cd073f44 c007c3ac bf08875c  cd073f44
c007c748 bf08875c c007ca54
[ 3856.998382] 3f40: cf11d108 32316c77 735f3135 cf006970 c009db38
cf374100 0001 cf374100
[ 3857.006652] 3f60: c025e6c0 4001e000 cf11d0c0 c0072d44 0001
cf374100 c002ba54 00a54e10
[ 3857.014953] 3f80: bf08875c 0880 cd073f8c  bea54e10
 bea54de8 bea54e10
[ 3857.023223] 3fa0: 0081 c002b940  bea54de8 bea54de8
0880 40151028 
[ 3857.031494] 3fc0:  bea54de8 bea54e10 0081 0880
  bea5767c
[ 3857.039764] 3fe0: 0003 bea54de0 8b38 400f0efc 6010
bea54de8 4e15 1f02
[ 3857.048034] [] (strcmp+0x4/0x34) from []
(sysfs_find_dirent+0x18/0x38)
[ 3857.056427] [] (sysfs_find_dirent+0x18/0x38) from
[] (sysfs_hash_and_remove+0x2c/0x5c)
[ 3857.066192] [] (sysfs_hash_and_remove+0x2c/0x5c) from
[] (free_notes_attrs+0x28/0x4c)
[ 3857.075866] [] (free_notes_attrs+0x28/0x4c) from
[] (free_module+0x34/0xe4)
[ 3857.084686] [] (free_module+0x34/0xe4) from []
(sys_delete_module+0x224/0x260)
[ 3857.093750] [] (sys_delete_module+0x224/0x260) from
[] (ret_fast_syscall+0x0/0x38)
[ 3857.103179] Code: e28cc001 1af3 e8bd8030 e3a03000 (e7d02003) 
[ 3857.109405] ---[ end trace e201521161943231 ]---
[ 3857.114074] Kernel panic - not syncing: Fatal exception

[2] crash log from ls:

Nokia-N900-42-9:~# ls -a /sys/module/wl1251_spi/notes
[ 3823.873168] Unable to handle kernel NULL pointer dereference at
virtual address 
[ 3823.881530] pgd = cccfc000
[ 3823.884277] [] *pgd=8f08b031, *pte=, *ppte=
[ 3823.890747] Internal error: Oops: 17 [#1]
[ 3823.894805] last sysfs file: /sys/class/net/wlan0/flags
[ 3823.900085] Modules linked in: wl1251_spi wl1251 mac80211 cfg80211
[ 3823.906402] CPU: 0Not tainted
(2.6.33-rc2-wl-47089-g7bfbe2a-dirty #1)
[ 3823.913360] PC is at strlen+0xc/0x20
[ 3823.916992] LR is at sysfs_readdir+0x15c/0x1e0
[ 3823.921508] pc : []lr : []psr: a013
[ 3823.921508] sp : cd1a1f28  ip :   fp : bef3760c
[ 3823.933105] r10: cd1a1f80  r9 :   r8 : 
[ 3823.938385] r7 : c00b9598  r6 : cd1a1f80  r5 : cd1d8458  r4 :
cf398d80
[ 3823.944976] r3 :   r2 : 0002  r1 :   r0 :

[ 3823.951599] Flags: NzCv  IRQs on  FIQs on  Mode SVC_32  ISA ARM
Segment user
[ 3823.958801] Control: 10c5387d  Table: 8ccfc019  DAC: 0015
[ 3823.964599] Process ls (pid: 1143, stack limit = 0xcd1a02e8)
[ 3823.970336] Stack: (0xcd1a1f28 to 0xcd1a2000)
[ 3823.974731] 1f20:   0001  0e16
 0004 
[ 3823.983032] 1f40: cf398d80 cf398d80 cf7a834c c00b9598 
cf7a82b8 cd1a c00b9884
[ 3823.991302] 1f60: 0001  1000 000690d0 cf398d80
c002bae4  c00b99

Re: [PATCH] OMAP2: add USB platform data and initialization for Nokia N800 and N810

2009-12-29 Thread Luke-Jr
Quick followup... I haven't had the chance to make those clock changes or move 
it into the main board file yet, but just discovered my recent boot problems 
were "fixed" by disabling USB support, so apparently there's something else 
broken with my patch. :(

Unfortunately, without a trackback, I'm totally lost:

Unable to handle kernel NULL pointer dereference at virtual address 0031
pgd = c0004000
[0031] *pgd=0
Internal error: Oops: 17 [#1] PREEMPT
--
To unsubscribe from this list: send the line "unsubscribe linux-omap" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH 6/8] arm: omap: musb: pass power to usb_musb_init

2009-12-29 Thread Tony Lindgren
* Felipe Balbi  [091229 11:54]:
> On Tue, 2009-12-29 at 21:53 +0200, Felipe Balbi wrote:
> > On Tue, 2009-12-29 at 11:51 -0800, Tony Lindgren wrote:
> > > * Felipe Balbi  [091228 03:10]:
> > > > each board might have a different charge pump and
> > > > thus able to source more or less current on vbus
> > > > so let power be easily configurable.
> > > 
> > > In order to justify merging this as a fix, can you please update
> > > the subject and description to describe that this fixes the
> > > the power value ?
> > 
> > for sure, doing it right now.
> 
> How about now ? (did the same to the board mode)
> 
> commit 860a17d3dc78cc8c640a83ade83dd0ec4f1217f1
> Author: Felipe Balbi 
> Date:   Mon Dec 28 00:46:19 2009 +0200
> 
> arm: omap: musb: fix board mode by passing it to usb_musb_init
> 
> each board will have a different mode which is peculiar
> to that board.
> 
> Signed-off-by: Felipe Balbi 
> 
> commit 86b92c438109a95c20fad62804b4b8040f3676b7
> Author: Felipe Balbi 
> Date:   Mon Dec 28 00:30:42 2009 +0200
> 
> arm: omap: musb: fix board power budget by passing it to
> usb_musb_init
> 
> each board might have a different charge pump and
> thus able to source more or less current on vbus
> so let power be easily configurable.
> 
> Signed-off-by: Felipe Balbi 

Sounds good to me.

Thanks,

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


Re: [PATCH] OMAP2: add USB platform data and initialization for Nokia N800 and N810

2009-12-29 Thread Felipe Balbi
Hi,

On Tue, 2009-12-29 at 11:53 -0800, Tony Lindgren wrote:
> Sounds good. Please keep two separate queues: Fixes for the -rc cycle,
> and new code for next merge window.

will do.

-- 
balbi

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


Re: [PATCH 6/8] arm: omap: musb: pass power to usb_musb_init

2009-12-29 Thread Felipe Balbi
On Tue, 2009-12-29 at 21:53 +0200, Felipe Balbi wrote:
> On Tue, 2009-12-29 at 11:51 -0800, Tony Lindgren wrote:
> > * Felipe Balbi  [091228 03:10]:
> > > each board might have a different charge pump and
> > > thus able to source more or less current on vbus
> > > so let power be easily configurable.
> > 
> > In order to justify merging this as a fix, can you please update
> > the subject and description to describe that this fixes the
> > the power value ?
> 
> for sure, doing it right now.

How about now ? (did the same to the board mode)

commit 860a17d3dc78cc8c640a83ade83dd0ec4f1217f1
Author: Felipe Balbi 
Date:   Mon Dec 28 00:46:19 2009 +0200

arm: omap: musb: fix board mode by passing it to usb_musb_init

each board will have a different mode which is peculiar
to that board.

Signed-off-by: Felipe Balbi 

commit 86b92c438109a95c20fad62804b4b8040f3676b7
Author: Felipe Balbi 
Date:   Mon Dec 28 00:30:42 2009 +0200

arm: omap: musb: fix board power budget by passing it to
usb_musb_init

each board might have a different charge pump and
thus able to source more or less current on vbus
so let power be easily configurable.

Signed-off-by: Felipe Balbi 

-- 
balbi

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


Re: [PATCH] OMAP2: add USB platform data and initialization for Nokia N800 and N810

2009-12-29 Thread Tony Lindgren
* Felipe Balbi  [091229 11:48]:
> Hi,
> 
> On Tue, 2009-12-29 at 11:42 -0800, Tony Lindgren wrote:
> > That would be great!
> 
> Ok good. So I'll mark all my pending patches as Superseeded or something
> better on patchwork then by tomorrow I'll resend all of them, plus the
> pull request.

Sounds good. Please keep two separate queues: Fixes for the -rc cycle,
and new code for next merge window.
 
> > > Sames goes to Kevin regarding davinci tree. I just have to subscribe in
> > > order to be able to send the patches there.
> > 
> > FYI, I think Kevin is on vacation right now.
> 
> good to know. The patch going to Greg right now only marks the fields as
> __deprecated so it shouldn't be a big problem to wait a bit.

OK

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


Re: [PATCH 6/8] arm: omap: musb: pass power to usb_musb_init

2009-12-29 Thread Felipe Balbi
On Tue, 2009-12-29 at 11:51 -0800, Tony Lindgren wrote:
> * Felipe Balbi  [091228 03:10]:
> > each board might have a different charge pump and
> > thus able to source more or less current on vbus
> > so let power be easily configurable.
> 
> In order to justify merging this as a fix, can you please update
> the subject and description to describe that this fixes the
> the power value ?

for sure, doing it right now.

-- 
balbi

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


Re: [PATCH 7/8] arm: omap: musb: pass board mode to usb_musb_init

2009-12-29 Thread Tony Lindgren
* Felipe Balbi  [091228 03:10]:
> each board will have a different mode which is peculiar
> to that board.

The subject and description for this too should be updated
to say it fixes the mode.

Regards,

Tony
 
> Signed-off-by: Felipe Balbi 
> ---
>  arch/arm/mach-omap2/board-2430sdp.c  |3 ++-
>  arch/arm/mach-omap2/board-3430sdp.c  |3 ++-
>  arch/arm/mach-omap2/board-cm-t35.c   |3 ++-
>  arch/arm/mach-omap2/board-igep0020.c |3 ++-
>  arch/arm/mach-omap2/board-ldp.c  |3 ++-
>  arch/arm/mach-omap2/board-omap3beagle.c  |3 ++-
>  arch/arm/mach-omap2/board-omap3evm.c |3 ++-
>  arch/arm/mach-omap2/board-omap3pandora.c |3 ++-
>  arch/arm/mach-omap2/board-omap3touchbook.c   |3 ++-
>  arch/arm/mach-omap2/board-overo.c|3 ++-
>  arch/arm/mach-omap2/board-rx51.c |3 ++-
>  arch/arm/mach-omap2/board-zoom-peripherals.c |3 ++-
>  arch/arm/mach-omap2/usb-musb.c   |   13 -
>  arch/arm/plat-omap/include/plat/usb.h|3 ++-
>  14 files changed, 30 insertions(+), 22 deletions(-)
> 
> diff --git a/arch/arm/mach-omap2/board-2430sdp.c 
> b/arch/arm/mach-omap2/board-2430sdp.c
> index d3857d6..45d3197 100644
> --- a/arch/arm/mach-omap2/board-2430sdp.c
> +++ b/arch/arm/mach-omap2/board-2430sdp.c
> @@ -23,6 +23,7 @@
>  #include 
>  #include 
>  #include 
> +#include 
>  
>  #include 
>  #include 
> @@ -203,7 +204,7 @@ static void __init omap_2430sdp_init(void)
>   platform_add_devices(sdp2430_devices, ARRAY_SIZE(sdp2430_devices));
>   omap_serial_init();
>   twl4030_mmc_init(mmc);
> - usb_musb_init(100);
> + usb_musb_init(MUSB_OTG, 100);
>   board_smc91x_init();
>  
>   /* Turn off secondary LCD backlight */
> diff --git a/arch/arm/mach-omap2/board-3430sdp.c 
> b/arch/arm/mach-omap2/board-3430sdp.c
> index 1d52fd1..37e7328 100644
> --- a/arch/arm/mach-omap2/board-3430sdp.c
> +++ b/arch/arm/mach-omap2/board-3430sdp.c
> @@ -24,6 +24,7 @@
>  #include 
>  #include 
>  #include 
> +#include 
>  
>  #include 
>  #include 
> @@ -664,7 +665,7 @@ static void __init omap_3430sdp_init(void)
>   ARRAY_SIZE(sdp3430_spi_board_info));
>   ads7846_dev_init();
>   omap_serial_init();
> - usb_musb_init(100);
> + usb_musb_init(MUSB_OTG, 100);
>   board_smc91x_init();
>   sdp3430_display_init();
>   enable_board_wakeup_source();
> diff --git a/arch/arm/mach-omap2/board-cm-t35.c 
> b/arch/arm/mach-omap2/board-cm-t35.c
> index 56922f4..9d5db6b 100644
> --- a/arch/arm/mach-omap2/board-cm-t35.c
> +++ b/arch/arm/mach-omap2/board-cm-t35.c
> @@ -27,6 +27,7 @@
>  #include 
>  #include 
>  #include 
> +#include 
>  
>  #include 
>  #include 
> @@ -585,7 +586,7 @@ static void __init cm_t35_init(void)
>   cm_t35_init_ethernet();
>   cm_t35_init_led();
>  
> - usb_musb_init(100);
> + usb_musb_init(MUSB_OTG, 100);
>  }
>  
>  MACHINE_START(CM_T35, "Compulab CM-T35")
> diff --git a/arch/arm/mach-omap2/board-igep0020.c 
> b/arch/arm/mach-omap2/board-igep0020.c
> index 16be1d5..6fc0608 100644
> --- a/arch/arm/mach-omap2/board-igep0020.c
> +++ b/arch/arm/mach-omap2/board-igep0020.c
> @@ -17,6 +17,7 @@
>  #include 
>  #include 
>  #include 
> +#include 
>  
>  #include 
>  #include 
> @@ -216,7 +217,7 @@ static void __init igep2_init(void)
>   omap3_mux_init(board_mux, OMAP_PACKAGE_CBB);
>   igep2_i2c_init();
>   omap_serial_init();
> - usb_musb_init(100);
> + usb_musb_init(MUSB_OTG, 100);
>  
>   igep2_init_smsc911x();
>  
> diff --git a/arch/arm/mach-omap2/board-ldp.c b/arch/arm/mach-omap2/board-ldp.c
> index ca2acd2..7e8c8a8 100644
> --- a/arch/arm/mach-omap2/board-ldp.c
> +++ b/arch/arm/mach-omap2/board-ldp.c
> @@ -27,6 +27,7 @@
>  #include 
>  #include 
>  #include 
> +#include 
>  
>  #include 
>  #include 
> @@ -394,7 +395,7 @@ static void __init omap_ldp_init(void)
>   ARRAY_SIZE(ldp_spi_board_info));
>   ads7846_dev_init();
>   omap_serial_init();
> - usb_musb_init(100);
> + usb_musb_init(MUSB_OTG, 100);
>  
>   twl4030_mmc_init(mmc);
>   /* link regulators to MMC adapters */
> diff --git a/arch/arm/mach-omap2/board-omap3beagle.c 
> b/arch/arm/mach-omap2/board-omap3beagle.c
> index 52f65e6..17f6381 100644
> --- a/arch/arm/mach-omap2/board-omap3beagle.c
> +++ b/arch/arm/mach-omap2/board-omap3beagle.c
> @@ -23,6 +23,7 @@
>  #include 
>  #include 
>  #include 
> +#include 
>  
>  #include 
>  #include 
> @@ -443,7 +444,7 @@ static void __init omap3_beagle_init(void)
>   /* REVISIT leave DVI powered down until it's needed ... */
>   gpio_direction_output(170, true);
>  
> - usb_musb_init(100);
> + usb_musb_init(MUSB_OTG, 100);
>   usb_ehci_init(&ehci_pdata);
>   omap3beagle_flash_init();
>  
> diff --git a/arch/arm/mach-omap2/board-omap3evm.c 
> b/arch/arm/mach-omap2/board-omap3evm.c
> index c5fd85d..116000

Re: [PATCH 6/8] arm: omap: musb: pass power to usb_musb_init

2009-12-29 Thread Tony Lindgren
* Felipe Balbi  [091228 03:10]:
> each board might have a different charge pump and
> thus able to source more or less current on vbus
> so let power be easily configurable.

In order to justify merging this as a fix, can you please update
the subject and description to describe that this fixes the
the power value?

Regards,

Tony
 
> Signed-off-by: Felipe Balbi 
> ---
>  arch/arm/mach-omap2/board-2430sdp.c  |2 +-
>  arch/arm/mach-omap2/board-3430sdp.c  |2 +-
>  arch/arm/mach-omap2/board-cm-t35.c   |2 +-
>  arch/arm/mach-omap2/board-igep0020.c |2 +-
>  arch/arm/mach-omap2/board-ldp.c  |2 +-
>  arch/arm/mach-omap2/board-omap3beagle.c  |2 +-
>  arch/arm/mach-omap2/board-omap3evm.c |2 +-
>  arch/arm/mach-omap2/board-omap3pandora.c |2 +-
>  arch/arm/mach-omap2/board-omap3touchbook.c   |2 +-
>  arch/arm/mach-omap2/board-overo.c|2 +-
>  arch/arm/mach-omap2/board-rx51.c |2 +-
>  arch/arm/mach-omap2/board-zoom-peripherals.c |2 +-
>  arch/arm/mach-omap2/usb-musb.c   |   12 
>  arch/arm/plat-omap/include/plat/usb.h|2 +-
>  14 files changed, 17 insertions(+), 21 deletions(-)
> 
> diff --git a/arch/arm/mach-omap2/board-2430sdp.c 
> b/arch/arm/mach-omap2/board-2430sdp.c
> index e508904..d3857d6 100644
> --- a/arch/arm/mach-omap2/board-2430sdp.c
> +++ b/arch/arm/mach-omap2/board-2430sdp.c
> @@ -203,7 +203,7 @@ static void __init omap_2430sdp_init(void)
>   platform_add_devices(sdp2430_devices, ARRAY_SIZE(sdp2430_devices));
>   omap_serial_init();
>   twl4030_mmc_init(mmc);
> - usb_musb_init();
> + usb_musb_init(100);
>   board_smc91x_init();
>  
>   /* Turn off secondary LCD backlight */
> diff --git a/arch/arm/mach-omap2/board-3430sdp.c 
> b/arch/arm/mach-omap2/board-3430sdp.c
> index c90b0d0..1d52fd1 100644
> --- a/arch/arm/mach-omap2/board-3430sdp.c
> +++ b/arch/arm/mach-omap2/board-3430sdp.c
> @@ -664,7 +664,7 @@ static void __init omap_3430sdp_init(void)
>   ARRAY_SIZE(sdp3430_spi_board_info));
>   ads7846_dev_init();
>   omap_serial_init();
> - usb_musb_init();
> + usb_musb_init(100);
>   board_smc91x_init();
>   sdp3430_display_init();
>   enable_board_wakeup_source();
> diff --git a/arch/arm/mach-omap2/board-cm-t35.c 
> b/arch/arm/mach-omap2/board-cm-t35.c
> index 2626a9f..56922f4 100644
> --- a/arch/arm/mach-omap2/board-cm-t35.c
> +++ b/arch/arm/mach-omap2/board-cm-t35.c
> @@ -585,7 +585,7 @@ static void __init cm_t35_init(void)
>   cm_t35_init_ethernet();
>   cm_t35_init_led();
>  
> - usb_musb_init();
> + usb_musb_init(100);
>  }
>  
>  MACHINE_START(CM_T35, "Compulab CM-T35")
> diff --git a/arch/arm/mach-omap2/board-igep0020.c 
> b/arch/arm/mach-omap2/board-igep0020.c
> index 117b8fd..16be1d5 100644
> --- a/arch/arm/mach-omap2/board-igep0020.c
> +++ b/arch/arm/mach-omap2/board-igep0020.c
> @@ -216,7 +216,7 @@ static void __init igep2_init(void)
>   omap3_mux_init(board_mux, OMAP_PACKAGE_CBB);
>   igep2_i2c_init();
>   omap_serial_init();
> - usb_musb_init();
> + usb_musb_init(100);
>  
>   igep2_init_smsc911x();
>  
> diff --git a/arch/arm/mach-omap2/board-ldp.c b/arch/arm/mach-omap2/board-ldp.c
> index 995d4a2..ca2acd2 100644
> --- a/arch/arm/mach-omap2/board-ldp.c
> +++ b/arch/arm/mach-omap2/board-ldp.c
> @@ -394,7 +394,7 @@ static void __init omap_ldp_init(void)
>   ARRAY_SIZE(ldp_spi_board_info));
>   ads7846_dev_init();
>   omap_serial_init();
> - usb_musb_init();
> + usb_musb_init(100);
>  
>   twl4030_mmc_init(mmc);
>   /* link regulators to MMC adapters */
> diff --git a/arch/arm/mach-omap2/board-omap3beagle.c 
> b/arch/arm/mach-omap2/board-omap3beagle.c
> index 231cb4e..52f65e6 100644
> --- a/arch/arm/mach-omap2/board-omap3beagle.c
> +++ b/arch/arm/mach-omap2/board-omap3beagle.c
> @@ -443,7 +443,7 @@ static void __init omap3_beagle_init(void)
>   /* REVISIT leave DVI powered down until it's needed ... */
>   gpio_direction_output(170, true);
>  
> - usb_musb_init();
> + usb_musb_init(100);
>   usb_ehci_init(&ehci_pdata);
>   omap3beagle_flash_init();
>  
> diff --git a/arch/arm/mach-omap2/board-omap3evm.c 
> b/arch/arm/mach-omap2/board-omap3evm.c
> index 34de178..c5fd85d 100644
> --- a/arch/arm/mach-omap2/board-omap3evm.c
> +++ b/arch/arm/mach-omap2/board-omap3evm.c
> @@ -469,7 +469,7 @@ static void __init omap3_evm_init(void)
>   omap_mux_init_gpio(135, OMAP_PIN_OUTPUT);
>   ehci_pdata.reset_gpio_port[1] = 135;
>   }
> - usb_musb_init();
> + usb_musb_init(100);
>   usb_ehci_init(&ehci_pdata);
>   ads7846_dev_init();
>   omap3evm_init_smsc911x();
> diff --git a/arch/arm/mach-omap2/board-omap3pandora.c 
> b/arch/arm/mach-omap2/board-omap3pandora.c
> index ef17cf1..b0cdf77 100644
> --- a/arch/

Re: [PATCH] OMAP2: add USB platform data and initialization for Nokia N800 and N810

2009-12-29 Thread Felipe Balbi
Hi,

On Tue, 2009-12-29 at 11:42 -0800, Tony Lindgren wrote:
> That would be great!

Ok good. So I'll mark all my pending patches as Superseeded or something
better on patchwork then by tomorrow I'll resend all of them, plus the
pull request.

> > Sames goes to Kevin regarding davinci tree. I just have to subscribe in
> > order to be able to send the patches there.
> 
> FYI, I think Kevin is on vacation right now.

good to know. The patch going to Greg right now only marks the fields as
__deprecated so it shouldn't be a big problem to wait a bit.


-- 
balbi

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


Re: [PATCH] omap: Remove set_clock for usb-musb.c

2009-12-29 Thread Tony Lindgren
* Felipe Balbi  [091229 11:35]:
> On Tue, 2009-12-29 at 11:31 -0800, Tony Lindgren wrote:
> > Felipe, can you take a look at this patch? To me it seems
> > like it should be now OK to get rid of set_clock.
> 
> I did that yesterday. Take a look at my git tree if you will:
> 
> http://gitorious.org/usb/usb/commits/for-tony

Hehe yeah :)

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


Re: [PATCH] OMAP2: add USB platform data and initialization for Nokia N800 and N810

2009-12-29 Thread Tony Lindgren
* Felipe Balbi  [091229 11:34]:
> Hi,
> 
> On Tue, 2009-12-29 at 11:24 -0800, Tony Lindgren wrote:
> > Great. The comment from Russell earlier was that we should be now using
> > clkdev to do things like this and get rid of the _set_clock functions.
> > In musb_core.c are already using the clk directly if set_clock is NULL.
> > 
> > Can you try the patch below? If it works, just merge it into your
> > patch.
> 
> Yes, let's do like Tony suggested. I'm removing the old set_clock stuff
> completely, patches are available at my git tree, here are the links:
> 
> http://gitorious.org/usb/usb/commit/ca415cf06a4843e93041fe73f7f1867e066b48a3
> http://gitorious.org/usb/usb/commit/013f8457a1ba0dd3f36811f647b0fe904128292e
> http://gitorious.org/usb/usb/commit/e2ecae4c5b01415dbbf714c7217178c31a9a5dd1
> http://gitorious.org/usb/usb/commit/874afb373ea75ff0a3a360802a53357affa27df0
> http://gitorious.org/usb/usb/commit/6d47fc9858c17faea8a454e147839c878737a0f1
> http://gitorious.org/usb/usb/commit/62b8d94df7739cb60bae0369b8265e588f518841
> http://gitorious.org/usb/usb/commit/e06629acd44936fe87d34d188c8dfb54abd7915c
> 
> Tony, if you want I can send you a pull request will all the patches I
> have prepared on top of your tree. There's only one dependence which I
> can ship in the same pull request.

That would be great!
 
> Sames goes to Kevin regarding davinci tree. I just have to subscribe in
> order to be able to send the patches there.

FYI, I think Kevin is on vacation right now.

Regards,

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


Re: [PATCH] omap: Remove set_clock for usb-musb.c

2009-12-29 Thread Felipe Balbi
On Tue, 2009-12-29 at 11:31 -0800, Tony Lindgren wrote:
> Felipe, can you take a look at this patch? To me it seems
> like it should be now OK to get rid of set_clock.

I did that yesterday. Take a look at my git tree if you will:

http://gitorious.org/usb/usb/commits/for-tony

-- 
balbi

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


Re: [PATCH] OMAP2: add USB platform data and initialization for Nokia N800 and N810

2009-12-29 Thread Felipe Balbi
Hi,

On Tue, 2009-12-29 at 11:24 -0800, Tony Lindgren wrote:
> Great. The comment from Russell earlier was that we should be now using
> clkdev to do things like this and get rid of the _set_clock functions.
> In musb_core.c are already using the clk directly if set_clock is NULL.
> 
> Can you try the patch below? If it works, just merge it into your
> patch.

Yes, let's do like Tony suggested. I'm removing the old set_clock stuff
completely, patches are available at my git tree, here are the links:

http://gitorious.org/usb/usb/commit/ca415cf06a4843e93041fe73f7f1867e066b48a3
http://gitorious.org/usb/usb/commit/013f8457a1ba0dd3f36811f647b0fe904128292e
http://gitorious.org/usb/usb/commit/e2ecae4c5b01415dbbf714c7217178c31a9a5dd1
http://gitorious.org/usb/usb/commit/874afb373ea75ff0a3a360802a53357affa27df0
http://gitorious.org/usb/usb/commit/6d47fc9858c17faea8a454e147839c878737a0f1
http://gitorious.org/usb/usb/commit/62b8d94df7739cb60bae0369b8265e588f518841
http://gitorious.org/usb/usb/commit/e06629acd44936fe87d34d188c8dfb54abd7915c

Tony, if you want I can send you a pull request will all the patches I
have prepared on top of your tree. There's only one dependence which I
can ship in the same pull request.

Sames goes to Kevin regarding davinci tree. I just have to subscribe in
order to be able to send the patches there.

-- 
balbi

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


Re: [PATCH] omap: Remove set_clock for usb-musb.c

2009-12-29 Thread Tony Lindgren
* Tony Lindgren  [091229 11:29]:
> Felipe, can you take a look at this patch? To me it seems
> like it should be now OK to get rid of set_clock.

Heh, never mind, looks like you already did the same patch earlier :)

Tony
 

> From 58c67fd38d9aa65cf35550f7b0e8c279d86afefe Mon Sep 17 00:00:00 2001
> From: Tony Lindgren 
> Date: Tue, 29 Dec 2009 11:26:45 -0800
> Subject: [PATCH] omap: Remove set_clock for usb-musb.c
> 
> This is no longer needed because of clkdev. We are
> already using clk_enable/disable directly in musb_core.c
> if set_clock is NULL.
> 
> Signed-off-by: Tony Lindgren 
> 
> diff --git a/arch/arm/mach-omap2/usb-musb.c b/arch/arm/mach-omap2/usb-musb.c
> index a80441d..74c40ab 100644
> --- a/arch/arm/mach-omap2/usb-musb.c
> +++ b/arch/arm/mach-omap2/usb-musb.c
> @@ -47,27 +47,6 @@ static struct resource musb_resources[] = {
>   },
>  };
>  
> -static int clk_on;
> -
> -static int musb_set_clock(struct clk *clk, int state)
> -{
> - if (state) {
> - if (clk_on > 0)
> - return -ENODEV;
> -
> - clk_enable(clk);
> - clk_on = 1;
> - } else {
> - if (clk_on == 0)
> - return -ENODEV;
> -
> - clk_disable(clk);
> - clk_on = 0;
> - }
> -
> - return 0;
> -}
> -
>  static struct musb_hdrc_eps_bits musb_eps[] = {
>   {   "ep1_tx", 10,   },
>   {   "ep1_rx", 10,   },
> @@ -121,8 +100,6 @@ static struct musb_hdrc_platform_data musb_plat = {
>  #elif defined(CONFIG_USB_GADGET_MUSB_HDRC)
>   .mode   = MUSB_PERIPHERAL,
>  #endif
> - /* .clock is set dynamically */
> - .set_clock  = musb_set_clock,
>   .config = &musb_config,
>  
>   /* REVISIT charge pump on TWL4030 can supply up to

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


[PATCH] omap: Remove set_clock for usb-musb.c

2009-12-29 Thread Tony Lindgren
Felipe, can you take a look at this patch? To me it seems
like it should be now OK to get rid of set_clock.

Regards,

Tony
>From 58c67fd38d9aa65cf35550f7b0e8c279d86afefe Mon Sep 17 00:00:00 2001
From: Tony Lindgren 
Date: Tue, 29 Dec 2009 11:26:45 -0800
Subject: [PATCH] omap: Remove set_clock for usb-musb.c

This is no longer needed because of clkdev. We are
already using clk_enable/disable directly in musb_core.c
if set_clock is NULL.

Signed-off-by: Tony Lindgren 

diff --git a/arch/arm/mach-omap2/usb-musb.c b/arch/arm/mach-omap2/usb-musb.c
index a80441d..74c40ab 100644
--- a/arch/arm/mach-omap2/usb-musb.c
+++ b/arch/arm/mach-omap2/usb-musb.c
@@ -47,27 +47,6 @@ static struct resource musb_resources[] = {
 	},
 };
 
-static int clk_on;
-
-static int musb_set_clock(struct clk *clk, int state)
-{
-	if (state) {
-		if (clk_on > 0)
-			return -ENODEV;
-
-		clk_enable(clk);
-		clk_on = 1;
-	} else {
-		if (clk_on == 0)
-			return -ENODEV;
-
-		clk_disable(clk);
-		clk_on = 0;
-	}
-
-	return 0;
-}
-
 static struct musb_hdrc_eps_bits musb_eps[] = {
 	{	"ep1_tx", 10,	},
 	{	"ep1_rx", 10,	},
@@ -121,8 +100,6 @@ static struct musb_hdrc_platform_data musb_plat = {
 #elif defined(CONFIG_USB_GADGET_MUSB_HDRC)
 	.mode		= MUSB_PERIPHERAL,
 #endif
-	/* .clock is set dynamically */
-	.set_clock	= musb_set_clock,
 	.config		= &musb_config,
 
 	/* REVISIT charge pump on TWL4030 can supply up to


Re: [PATCH] OMAP2: add USB platform data and initialization for Nokia N800 and N810

2009-12-29 Thread Tony Lindgren
Hi,

* Luke-Jr  [091228 23:51]:
> Add platform data and initialization for USB on Nokia N800 and N810 devices
> via the TUSB6010 chipset.
> 
> Tested on Nokia N810 in Linux-OMAP tree. Mainline is not bootable yet.
> 
> Signed-off-by: Luke Dashjr 
> ---
>  arch/arm/mach-omap2/Kconfig  |5 +
>  arch/arm/mach-omap2/Makefile |1 +
>  arch/arm/mach-omap2/board-n8x0-usb.c |  173 
> ++
>  arch/arm/mach-omap2/board-n8x0.c |8 ++
>  4 files changed, 187 insertions(+), 0 deletions(-)
>  create mode 100644 arch/arm/mach-omap2/board-n8x0-usb.c
> 



> diff --git a/arch/arm/mach-omap2/board-n8x0-usb.c 
> b/arch/arm/mach-omap2/board-n8x0-usb.c
> new file mode 100644
> index 000..2254ebd
> --- /dev/null
> +++ b/arch/arm/mach-omap2/board-n8x0-usb.c



> +static int   osc_ck_on;
> +
> +static int tusb_set_clock(struct clk *osc_ck, int state)
> +{
> + if (state) {
> + if (osc_ck_on > 0)
> + return -ENODEV;
> +
> + clk_enable(osc_ck);
> + osc_ck_on = 1;
> + } else {
> + if (osc_ck_on == 0)
> + return -ENODEV;
> +
> + clk_disable(osc_ck);
> + osc_ck_on = 0;
> + }
> +
> + return 0;
> +}

Great. The comment from Russell earlier was that we should be now using
clkdev to do things like this and get rid of the _set_clock functions.
In musb_core.c are already using the clk directly if set_clock is NULL.

Can you try the patch below? If it works, just merge it into your
patch.

Regards,

Tony

>From e84994dccb71c1e01ca0b9f256d9b7496492a4e2 Mon Sep 17 00:00:00 2001
From: Tony Lindgren 
Date: Tue, 29 Dec 2009 11:04:58 -0800
Subject: [PATCH] tusb6010: Use clkdev to initialize the clock

Note that in this case the clock is fck, not ick
like for musb.

Signed-off-by: Tony Lindgren 

diff --git a/arch/arm/mach-omap2/board-n8x0-usb.c b/arch/arm/mach-omap2/board-n8x0-usb.c
index 2254ebd..e67eabf 100644
--- a/arch/arm/mach-omap2/board-n8x0-usb.c
+++ b/arch/arm/mach-omap2/board-n8x0-usb.c
@@ -25,7 +25,6 @@
 #define GPIO_TUSB_ENABLE	0
 
 static int tusb_set_power(int state);
-static int tusb_set_clock(struct clk *osc_ck, int state);
 
 #if	defined(CONFIG_USB_MUSB_OTG)
 #	define BOARD_MODE	MUSB_OTG
@@ -82,10 +81,8 @@ static struct musb_hdrc_config musb_config = {
 static struct musb_hdrc_platform_data tusb_data = {
 	.mode		= BOARD_MODE,
 	.set_power	= tusb_set_power,
-	.set_clock	= tusb_set_clock,
 	.min_power	= 25,	/* x2 = 50 mA drawn from VBUS as peripheral */
 	.power		= 100,	/* Max 100 mA VBUS for host mode */
-	.clock		= "osc_ck",
 	.config		= &musb_config,
 };
 
@@ -121,27 +118,6 @@ static int tusb_set_power(int state)
 	return retval;
 }
 
-static int		osc_ck_on;
-
-static int tusb_set_clock(struct clk *osc_ck, int state)
-{
-	if (state) {
-		if (osc_ck_on > 0)
-			return -ENODEV;
-
-		clk_enable(osc_ck);
-		osc_ck_on = 1;
-	} else {
-		if (osc_ck_on == 0)
-			return -ENODEV;
-
-		clk_disable(osc_ck);
-		osc_ck_on = 0;
-	}
-
-	return 0;
-}
-
 void __init n8x0_usb_init(void)
 {
 	int ret = 0;
@@ -156,6 +132,12 @@ void __init n8x0_usb_init(void)
 	}
 	gpio_direction_output(GPIO_TUSB_ENABLE, 0);
 
+	/*
+	 * REVISIT: This line can be removed once all the platforms using
+	 * musb_core.c have been converted to use use clkdev.
+	 */
+	tusb_data.clock = "fck";
+
 	tusb_set_power(0);
 
 	ret = tusb6010_setup_interface(&tusb_data, TUSB6010_REFCLK_19, 2,
diff --git a/arch/arm/mach-omap2/clock2xxx_data.c b/arch/arm/mach-omap2/clock2xxx_data.c
index 97dc7cf..e9c8f09 100644
--- a/arch/arm/mach-omap2/clock2xxx_data.c
+++ b/arch/arm/mach-omap2/clock2xxx_data.c
@@ -,6 +,7 @@ static struct omap_clk omap24xx_clks[] = {
 	CLK(NULL,	"aes_ick",	&aes_ick,	CK_243X | CK_242X),
 	CLK(NULL,	"pka_ick",	&pka_ick,	CK_243X | CK_242X),
 	CLK(NULL,	"usb_fck",	&usb_fck,	CK_243X | CK_242X),
+	CLK("musb_hdrc",	"fck",	&osc_ck,	CK_242X),
 	CLK("musb_hdrc",	"ick",	&usbhs_ick,	CK_243X),
 	CLK("mmci-omap-hs.0", "ick",	&mmchs1_ick,	CK_243X),
 	CLK("mmci-omap-hs.0", "fck",	&mmchs1_fck,	CK_243X),


Re: Query on new mux usage

2009-12-29 Thread Tony Lindgren
* Premi, Sanjeev  [091229 05:41]:
> Hi,
>  
> I am trying to define the mux settings for keypad on the omap3evm.
> I had a few queries on the same.
>  
> 1) Is it enough to me this change:
>  
>  static struct omap_board_mux board_mux[] __initdata = {
> +
> +   /* SYS_NIRQ */
> +   OMAP3_MUX(SYS_NIRQ, OMAP_MUX_MODE0 | OMAP_PIN_INPUT_PULLUP |
> + OMAP_PIN_OFF_INPUT_PULLUP),
> +
>   { .reg_offset = OMAP_MUX_TERMINATOR },

This will do the trick for board specific things. If you want, you can
dump the whole mux table set by the bootloader via debugfs if you cat
/sys/kernel/debug/omap_mux. Then you can check and edit the table as
needed.
 
> 2) Or should I follow with this (in the evm init code):
>  
> + omap_mux_init_signal("af26", OMAP_PIN_INPUT_PULLUP |
> + OMAP_PIN_OFF_INPUT_PULLUP);

This can be used too if you prefer. The mux_init_gpio and mux_init_signal
functions are mostly intended for platform init functions for common
hardware, like MMC, USB etc. For board specific pins, I'd go with
#1 abobve.

> 3) OR is this a better(or worse)
> 
>  static struct omap_board_mux board_mux[] __initdata = {
> +
> +   /* SYS_NIRQ */
> +   OMAP3_MUX(SYS_NIRQ, OMAP_MUX_MODE0),
> +
>   { .reg_offset = OMAP_MUX_TERMINATOR },
> 
> ..and later
>  
> + omap_mux_init_signal("af26", OMAP_PIN_INPUT_PULLUP |
> + OMAP_PIN_OFF_INPUT_PULLUP);
> 

Then you're doing it twice, which is not needed.

Eventually we should have common init functions using hwmod for all
the omap internal devices and do the muxing there too. But some
board specific muxing will always be still needed.

Regards,

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


[PATCH ] DSPBRIDGE:Remove conditional check from the InputMsg function

2009-12-29 Thread Hebbar, Shivananda
>From 03b5f57849eda16fb659c4288ae2dc9a2d1582a9 Mon Sep 17 00:00:00 2001
From: Shivananda Hebbar 
Date: Thu, 17 Dec 2009 17:00:22 -0600
Subject: [PATCH] DSPBRIDGE: Remove conditional check from the InputMsg function

This patch removes the conditional check which can result in
message skip.

Discovered-by: Bhavin Shah   
Signed-off-by: Shivananda Hebbar 
---
 drivers/dsp/bridge/wmd/io_sm.c |   13 ++---
 1 files changed, 6 insertions(+), 7 deletions(-)

diff --git a/drivers/dsp/bridge/wmd/io_sm.c b/drivers/dsp/bridge/wmd/io_sm.c
index a6c8e31..5b7b004 100644
--- a/drivers/dsp/bridge/wmd/io_sm.c
+++ b/drivers/dsp/bridge/wmd/io_sm.c
@@ -1308,7 +1308,7 @@ static void InputMsg(struct IO_MGR *pIOMgr, struct 
MSG_MGR *hMsgMgr)
fInputEmpty = IO_GetValue(pIOMgr->hWmdContext, struct MSG, pCtrl,
 bufEmpty);
uMsgs = IO_GetValue(pIOMgr->hWmdContext, struct MSG, pCtrl, size);
-   if (fInputEmpty || uMsgs >= hMsgMgr->uMaxMsgs)
+   if (fInputEmpty)
goto func_end;
 
pMsgInput = pIOMgr->pMsgInput;
@@ -1331,12 +1331,11 @@ static void InputMsg(struct IO_MGR *pIOMgr, struct 
MSG_MGR *hMsgMgr)
DBG_Trace(DBG_LEVEL7, "InputMsg RECVD: dwCmd=0x%x dwArg1=0x%x "
 "dwArg2=0x%x dwId=0x%x \n", msg.msg.dwCmd,
 msg.msg.dwArg1, msg.msg.dwArg2, msg.dwId);
-/*  Interrupt may occur before shared memory and message
-*  input locations have been set up. If all nodes were
-*  cleaned up, hMsgMgr->uMaxMsgs should be 0.  */
-   if (hMsgQueue && uMsgs > hMsgMgr->uMaxMsgs)
-   goto func_end;
-
+   /*
+* Interrupt may occur before shared memory and message
+* input locations have been set up. If all nodes were
+* cleaned up, hMsgMgr->uMaxMsgs should be 0.
+*/
while (hMsgQueue != NULL) {
if (msg.dwId == hMsgQueue->dwId) {
/* Found it */
-- 
1.6.0.4
--
To unsubscribe from this list: send the line "unsubscribe linux-omap" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: SR2: VDD autocomp is not active

2009-12-29 Thread tarek attia
Thank you :) ,

I found the "omap2_clk_init_cpufreq_table" function in the kernel
image installed on my board ,and the hanging up is not permanent
,sometimes occurs and some time doesn't .

So what the reason may be for this case? ..also what is the usage of
"sr_vdd1_autocomp" ??

I know that I'm bothering you,,but thanks for your reply in advance :-)

Regards,

On Tue, Dec 29, 2009 at 4:00 PM, Romit Dasgupta  wrote:
> tarek attia wrote:
>> Basically I'm working on beagleboard rev B5 .
>> I'm not using the pm branch of kevin ,,however I'm using source files
>> from the rowboat project (Android) ,just I enabled the cpufreq and
>> smartreflex in the kernel configuration while I'm building the linux
>> kernel of Android .
>>
>
> Do you have this function in your code?
> 'omap2_clk_init_cpufreq_table' If not please use pm branch.
>



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


Re: SR2: VDD autocomp is not active

2009-12-29 Thread Romit Dasgupta
tarek attia wrote:
> Basically I'm working on beagleboard rev B5 .
> I'm not using the pm branch of kevin ,,however I'm using source files
> from the rowboat project (Android) ,just I enabled the cpufreq and
> smartreflex in the kernel configuration while I'm building the linux
> kernel of Android .
> 

Do you have this function in your code?
'omap2_clk_init_cpufreq_table' If not please use pm branch.
--
To unsubscribe from this list: send the line "unsubscribe linux-omap" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Query on new mux usage

2009-12-29 Thread Premi, Sanjeev
Hi,
 
I am trying to define the mux settings for keypad on the omap3evm.
I had a few queries on the same.
 
1) Is it enough to me this change:
 
 static struct omap_board_mux board_mux[] __initdata = {
+
+   /* SYS_NIRQ */
+   OMAP3_MUX(SYS_NIRQ, OMAP_MUX_MODE0 | OMAP_PIN_INPUT_PULLUP |
+   OMAP_PIN_OFF_INPUT_PULLUP),
+
{ .reg_offset = OMAP_MUX_TERMINATOR },

2) Or should I follow with this (in the evm init code):
 
+   omap_mux_init_signal("af26", OMAP_PIN_INPUT_PULLUP |
+   OMAP_PIN_OFF_INPUT_PULLUP);

3) OR is this a better(or worse)

 static struct omap_board_mux board_mux[] __initdata = {
+
+   /* SYS_NIRQ */
+   OMAP3_MUX(SYS_NIRQ, OMAP_MUX_MODE0),
+
{ .reg_offset = OMAP_MUX_TERMINATOR },

..and later
 
+   omap_mux_init_signal("af26", OMAP_PIN_INPUT_PULLUP |
+   OMAP_PIN_OFF_INPUT_PULLUP);

Best regards,
Sanjeev
--
To unsubscribe from this list: send the line "unsubscribe linux-omap" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: SR2: VDD autocomp is not active

2009-12-29 Thread tarek attia
Basically I'm working on beagleboard rev B5 .
I'm not using the pm branch of kevin ,,however I'm using source files
from the rowboat project (Android) ,just IĀ enabled the cpufreq and
smartreflex in the kernel configuration while I'm building the linux
kernel of Android .

Any Idea :-) ??

On Tue, Dec 29, 2009 at 2:30 PM, Romit Dasgupta  wrote:
>
> >>> Each time I enable the ondemand governor ,it works fine for a while
> >>> ,but each time the frequency is changed this messages appears :-
> >>>
> >>> SR1: VDD autocomp is not active
> >>>
> >>> then it works again ,but after small amount of time this messages
> >>> appears followed by hang up for the overall system
> >>>
> >>> SR2: VDD autocomp is not active
> >>>
> >>>
> >> try this:
> >> echo 1 > /sys/power/sr_vdd1_autocomp; echo 1 > /sys/power/sr_vdd2_autocomp
> What platform are you using? Also what is your git HEAD?
> I can smell 3630... ;-) please confirm.



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


[PATCH] arm: omap1: mailbox: kill compile warning

2009-12-29 Thread Felipe Balbi
use ioremap and remove unused variable to get rid
of compile warnings.

Signed-off-by: Felipe Balbi 
---
 arch/arm/mach-omap1/devices.c |2 +-
 arch/arm/mach-omap1/mailbox.c |9 +++--
 2 files changed, 8 insertions(+), 3 deletions(-)

diff --git a/arch/arm/mach-omap1/devices.c b/arch/arm/mach-omap1/devices.c
index 23ded2d..9caf51b 100644
--- a/arch/arm/mach-omap1/devices.c
+++ b/arch/arm/mach-omap1/devices.c
@@ -71,7 +71,7 @@ static inline void omap_init_rtc(void) {}
 #  define INT_DSP_MAILBOX1 INT_1610_DSP_MAILBOX1
 #endif
 
-#define OMAP1_MBOX_BASEOMAP1_IO_ADDRESS(OMAP16XX_MAILBOX_BASE)
+#define OMAP1_MBOX_BASEOMAP16XX_MAILBOX_BASE
 
 static struct resource mbox_resources[] = {
{
diff --git a/arch/arm/mach-omap1/mailbox.c b/arch/arm/mach-omap1/mailbox.c
index caf889a..4f5b3da 100644
--- a/arch/arm/mach-omap1/mailbox.c
+++ b/arch/arm/mach-omap1/mailbox.c
@@ -146,7 +146,6 @@ EXPORT_SYMBOL(mbox_dsp_info);
 static int __devinit omap1_mbox_probe(struct platform_device *pdev)
 {
struct resource *res;
-   int ret = 0;
 
if (pdev->num_resources != 2) {
dev_err(&pdev->dev, "invalid number of resources: %d\n",
@@ -160,12 +159,18 @@ static int __devinit omap1_mbox_probe(struct 
platform_device *pdev)
dev_err(&pdev->dev, "invalid mem resource\n");
return -ENODEV;
}
-   mbox_base = res->start;
+
+   mbox_base = ioremap(res->start, resource_size(res));
+   if (!mbox_base) {
+   dev_err(&pdev->dev, "ioremap failed\n");
+   return -ENODEV;
+   }
 
/* DSP IRQ */
res = platform_get_resource(pdev, IORESOURCE_IRQ, 0);
if (unlikely(!res)) {
dev_err(&pdev->dev, "invalid irq resource\n");
+   iounmap(mbox_base);
return -ENODEV;
}
mbox_dsp_info.irq = res->start;
-- 
1.6.6.rc0

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


Re: [PATCH v2] arm: omap1: mailbox: kill compile warning

2009-12-29 Thread Felipe Balbi

On Tue, Dec 29, 2009 at 01:59:12AM +0100, Balbi Felipe (Nokia-D/Helsinki) wrote:

remove unused variable and kill compile warning.

Signed-off-by: Felipe Balbi 
---

Changes from previous version:
- Removed OMAP1_IO_ADDRESS() from OMAP1_MBOX_BASE define


forget this one.

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


Re: [PATCH] OMAP2: add USB platform data and initialization for Nokia N800 and N810

2009-12-29 Thread Felipe Balbi

Hi,

On Tue, Dec 29, 2009 at 09:55:46AM +0100, ext Kalle Valo wrote:

Oh that. I have only used serial console with mainline. Luckily Felipe
did some cbus patches, I haven't checked them yet though.


nothing for mainline yet though, cbus needs lots of work.

anyone with free time, please help :-p

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


Re: [PATCH] ehci: fix missing kfree in remove path also

2009-12-29 Thread Felipe Balbi

On Tue, Dec 29, 2009 at 12:42:18AM +0100, ext Tony Lindgren wrote:

* Ajay Kumar Gupta  [091216 05:35]:

Added missing kfree() in ehci_hcd_omap_remove().


This should get merged via linux-usb list.


it was sent to Greg already, thanks

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


Re: Problems using DSS2 on OMAP3 EVM / Angstrom with rotation

2009-12-29 Thread Koen Kooi

Op 28 dec 2009, om 06:58 heeft Eino-Ville Talvala het volgende geschreven:

> On 12/2/2009 1:59 PM, Eino-Ville Talvala wrote:
> 
 
 Thanks for all the suggestions, but nothing seems to have worked so far.
 
 It looks like X picks up all sorts of configuration settings
 automatically, since xorg.conf is essentially full of 'default internal
 device' options.  What I can't figure out is how it decides on the
 requested resolution.
 
 The defaults, with omapfb.rotate=1 in bootargs, result in omapfb
 selecting a virtual resolution of 640x480, but Xorg on boot still tries,
 based on dmesg, to get a 480x640 overlay somehow (at least that's what
 my interpretation of the situation is).  I've tried adding a screen
 subsection to xorg.confg, with virtual 640 480 - no effect.  I've tried
 adding in a modeline for 640x480, no effect.  I tried rebuilding
 Angstrom with a few extra lines in /conf/machine/omap3evm.conf
 (MACHINE_DISPLAY_WIDTH_PIXELS=640, etc), with no effect.
 
 Does anyone know exactly how Xorg autoconfigures the default panel in
 this sort of a situation?  My current guess is that it's getting 480x640
 from some panel driver somewhere, but I haven't been able to find the
 source.
 
 For compleness, I've attached the Xorg log, xorg.conf, and the kernel
 log when I try to boot up Xorg (just Xorg, no gpe anything).
 
 
>>> check the settings for fb0, fb1 and fb2 with fbset.
>>> 
>>> regards,
>>> 
>>> Koen
>>> 
>>> 
>> r...@omap3evm:~# fbset -fb /dev/fb0
>> 
>> mode "640x480-59"
>># D: 19.200 MHz, H: 28.614 kHz, V: 59.243 Hz
>>geometry 640 480 640 480 16
>>timings 52083 1 28 1 1 2 1
>>accel false
>>rgba 5/11,6/5,5/0,0/0
>> endmode
>> 
>> r...@omap3evm:~# fbset -fb /dev/fb1
>> 
>> mode "640x480-59"
>># D: 19.200 MHz, H: 28.614 kHz, V: 59.243 Hz
>>geometry 640 480 640 480 16
>>timings 52083 1 28 1 1 2 1
>>accel false
>>rgba 5/11,6/5,5/0,0/0
>> endmode
>> 
>> r...@omap3evm:~# fbset -fb /dev/fb2
>> 
>> mode "0x0-0"
>># D: 0.000 MHz, H: 0.000 kHz, V: 0.000 Hz
>>geometry 0 0 0 0 0
>>timings 0 0 0 0 0 0 0
>>accel false
>>rgba 0/0,0/0,0/0,0/0
>> endmode
>> 
>> FB2 is suspicious, since that's what Xorg uses, I believe.  Attempting
>> to set it to something like fb0 and fb1 with:
>>fbset -fb /dev/fb2 -g 640 480 640 480 16 -t 52083 1 28 1 1 2 1
>> made no difference to Xorg, however.  I tried upping the amount of
>> memory allocated to fb2 (I'd forgotten to give it any on the bootargs),
>> with no luck.  So fb0 and fb1 are getting defaults from somewhere, but
>> fb2 isn't.
>> 
>> Bootargs currently:
>>mem=128M console=ttyS0,115200n8 noinitrd rw root=/dev/mmcblk0p2
>> rootfstype=ext2 rootwait omapfb.rotate=1 omapfb.vrfb=y omapfb.debug=y
>> omapdss.debug=y vram=32M omapfb.vram=0:8M,1:8M,2:8M
>> 
>> Thanks for the suggestion!
>> 
> 
> Just in case it would be of use to others later, I did finally find a
> resolution to this problem.  The short story is that the current
> xf86-video-omafb driver can't handle VRFB rotation, even if it's defined
> on the kernel command line, because the driver assumes that the output
> framebuffer is contiguous, which is very much not true with VRFB. 
> There's also a problem with the order in which it reads and writes
> framebuffer parameters, because with the omapfb driver, the frame buffer
> fixed info will have to be reread after changing rotation settings or
> pixel type, as the stride can change. 
> 
> I've hacked up enough of the xf86-video-omapfb driver to get X running
> in the proper orientation with VRFB and rotation defined on the kernel
> command line, on the OMAP3 EVM (so X runs at 640x480 on the built-in
> 480x640 LCD).  I haven't gotten the XV extension part of the driver
> working right yet.  If anyone wants the ugly results, I'm happy to
> share, but I doubt I'll have time to clean them up anytime soon.

I'm certainly interested in your patches. Hacky vrfb support is better than no 
vrfb support :)

regards,

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


Re: SR2: VDD autocomp is not active

2009-12-29 Thread Romit Dasgupta
>>> Each time I enable the ondemand governor ,it works fine for a while
>>> ,but each time the frequency is changed this messages appears :-
>>>
>>> SR1: VDD autocomp is not active
>>>
>>> then it works again ,but after small amount of time this messages
>>> appears followed by hang up for the overall system
>>>
>>> SR2: VDD autocomp is not active
>>>
>>>
>> try this:
>> echo 1 > /sys/power/sr_vdd1_autocomp; echo 1 > /sys/power/sr_vdd2_autocomp
What platform are you using? Also what is your git HEAD?
I can smell 3630... ;-) please confirm.
--
To unsubscribe from this list: send the line "unsubscribe linux-omap" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: SR2: VDD autocomp is not active

2009-12-29 Thread tarek attia
Thank you for your reply ,

But another thing appears and also the system hangs up after
activation the ondemand governor

OPP4 doesn't support SmartReflex
SR1: VDD autocomp not activated

P.S:- I did as you told me by echo 1>sys/power/,,,etc


Regards,

On Mon, Dec 28, 2009 at 9:48 AM, Romit Dasgupta  wrote:
>
> tarek attia wrote:
> > Hi all,
> >
> > Each time I enable the ondemand governor ,it works fine for a while
> > ,but each time the frequency is changed this messages appears :-
> >
> > SR1: VDD autocomp is not active
> >
> > then it works again ,but after small amount of time this messages
> > appears followed by hang up for the overall system
> >
> > SR2: VDD autocomp is not active
> >
> >
>
> try this:
> echo 1 > /sys/power/sr_vdd1_autocomp; echo 1 > /sys/power/sr_vdd2_autocomp
>



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


[PATCH] omap2/3: mtd: fix compile warning

2009-12-29 Thread Sanjeev Premi
This patch fixes following compile warning:

drivers/mtd/nand/omap2.c:508: warning: passing argumen
t 2 of 'omap_nand_dma_transfer' discards qualifiers fr
om pointer target type

Signed-off-by: Sanjeev Premi 
---
 drivers/mtd/nand/omap2.c |2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/drivers/mtd/nand/omap2.c b/drivers/mtd/nand/omap2.c
index 1bb799f..08c193c 100644
--- a/drivers/mtd/nand/omap2.c
+++ b/drivers/mtd/nand/omap2.c
@@ -505,7 +505,7 @@ static void omap_write_buf_dma_pref(struct mtd_info *mtd,
omap_write_buf_pref(mtd, buf, len);
else
/* start transfer in DMA mode */
-   omap_nand_dma_transfer(mtd, buf, len, 0x1);
+   omap_nand_dma_transfer(mtd, (void *)buf, len, 0x1);
 }
 
 /**
-- 
1.6.2.2

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


Re: [PATCH] OMAP2: add USB platform data and initialization for Nokia N800 and N810

2009-12-29 Thread Kalle Valo
"Luke-Jr"  writes:

> On Tuesday 29 December 2009 02:29:22 am Kalle Valo wrote:
>> "Luke-Jr"  writes:
>> > Tested on Nokia N810 in Linux-OMAP tree. Mainline is not bootable yet.
>> 
>> What's the problem in mainline? I haven't tested n8x0 for months :(
>
> Lack of platform support, as far as I know. Until we have cbus,
> there's no way to get the LCD powered...

Oh that. I have only used serial console with mainline. Luckily Felipe
did some cbus patches, I haven't checked them yet though.

>> I think a separate file is not needed, it's not that much code. I
>> recommend to just adding it directly to board-n8x0.c. It's simple and
>> easier for everyone.
>
> Seemed simpler to manage in a separate file

Having lots of small files is difficult IMHO.

> though not as necessary as the LCD stuff (which I also have a patch
> against mainline for, but it needs tahvo...)

Nice.

>> CONFIG_MACH_NOKIA_N8X0_LCD does not look right here.
>
> Heh, looks like my isolate-and-merge-to-mainline got messed up there.
> Of course it should be CONFIG_MACH_NOKIA_N8X0_USB :)

Yeah, maybe eating too much ham caused it ;)

> Also, scripts/checkpatch.pl gave me a warning about the extern in a .c file, 
> but I couldn't figure out where else it could reasonably go. Any ideas? :/

Yes, just put everything into one file :) No need for externs then.

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


Re: [PATCH] OMAP2: add USB platform data and initialization for Nokia N800 and N810

2009-12-29 Thread Luke-Jr
On Tuesday 29 December 2009 02:29:22 am Kalle Valo wrote:
> "Luke-Jr"  writes:
> > Tested on Nokia N810 in Linux-OMAP tree. Mainline is not bootable yet.
> 
> What's the problem in mainline? I haven't tested n8x0 for months :(

Lack of platform support, as far as I know.
Until we have cbus, there's no way to get the LCD powered...

> > --- a/arch/arm/mach-omap2/Kconfig
> > +++ b/arch/arm/mach-omap2/Kconfig
> > @@ -117,6 +117,11 @@ config MACH_NOKIA_N8X0
> > select MACH_NOKIA_N810
> > select MACH_NOKIA_N810_WIMAX
> >
> > +config MACH_NOKIA_N8X0_USB
> > +   bool
> > +   depends on MACH_NOKIA_N8X0 && MACH_OMAP2_TUSB6010
> > +   default y
> > +
> 
> Is is really needed to add new kconfig variable? Can't we just use
> MACH_OMAP2_TUSB6010 in code?
> 
> I think a separate file is not needed, it's not that much code. I
> recommend to just adding it directly to board-n8x0.c. It's simple and
> easier for everyone.

Seemed simpler to manage in a separate file, though not as necessary as the 
LCD stuff (which I also have a patch against mainline for, but it needs 
tahvo...)

> > --- a/arch/arm/mach-omap2/board-n8x0.c
> > +++ b/arch/arm/mach-omap2/board-n8x0.c
> > @@ -109,8 +109,16 @@ static void __init n8x0_init_irq(void)
> > omap_gpio_init();
> >  }
> >
> > +#ifdef CONFIG_MACH_NOKIA_N8X0_LCD
> > +extern void n8x0_usb_init(void);
> > +#else
> > +static inline void n8x0_usb_init (void) {}
> > +#endif
> 
> CONFIG_MACH_NOKIA_N8X0_LCD does not look right here.

Heh, looks like my isolate-and-merge-to-mainline got messed up there.
Of course it should be CONFIG_MACH_NOKIA_N8X0_USB :)

Also, scripts/checkpatch.pl gave me a warning about the extern in a .c file, 
but I couldn't figure out where else it could reasonably go. Any ideas? :/

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


Re: [PATCH] OMAP2: add USB platform data and initialization for Nokia N800 and N810

2009-12-29 Thread Kalle Valo
"Luke-Jr"  writes:

> Add platform data and initialization for USB on Nokia N800 and N810 devices
> via the TUSB6010 chipset.

Excellent, thank you for doing this.

> Tested on Nokia N810 in Linux-OMAP tree. Mainline is not bootable yet.

What's the problem in mainline? I haven't tested n8x0 for months :(

> --- a/arch/arm/mach-omap2/Kconfig
> +++ b/arch/arm/mach-omap2/Kconfig
> @@ -117,6 +117,11 @@ config MACH_NOKIA_N8X0
>   select MACH_NOKIA_N810
>   select MACH_NOKIA_N810_WIMAX
>  
> +config MACH_NOKIA_N8X0_USB
> + bool
> + depends on MACH_NOKIA_N8X0 && MACH_OMAP2_TUSB6010
> + default y
> +

Is is really needed to add new kconfig variable? Can't we just use
MACH_OMAP2_TUSB6010 in code?

> --- /dev/null
> +++ b/arch/arm/mach-omap2/board-n8x0-usb.c

I think a separate file is not needed, it's not that much code. I
recommend to just adding it directly to board-n8x0.c. It's simple and
easier for everyone.

> --- a/arch/arm/mach-omap2/board-n8x0.c
> +++ b/arch/arm/mach-omap2/board-n8x0.c
> @@ -109,8 +109,16 @@ static void __init n8x0_init_irq(void)
>   omap_gpio_init();
>  }
>  
> +#ifdef CONFIG_MACH_NOKIA_N8X0_LCD
> +extern void n8x0_usb_init(void);
> +#else
> +static inline void n8x0_usb_init (void) {}
> +#endif

CONFIG_MACH_NOKIA_N8X0_LCD does not look right here.

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