Re: Timer interrupt on Linux 3.0.3

2011-09-21 Thread MohanReddy koppula
I had the same issue with an MPC885 board. My kernel was 2.6.33. On
that board decrementer exception was not working. I replaced the
board, took new board (MPC885 only, just another board) and the same
kernel worked fine. I don't know how the problem was solved.

-Mohan

On 9/22/11, Scott Wood  wrote:
> On 09/21/2011 01:56 AM, Vineeth wrote:
 What was the issue?  You really should try to make this work rather than
 hack around it.
>>
>> what we found was the decrementer is not generating an exception when it
>> becomes 0. and the timebase registers are not getting incremented too.
>
> Does the decrementer actually tick until it reaches zero, or do it and
> the timebase never tick?
>
> Is the TBEN input to the CPU asserted?
>
> -Scott
>
> ___
> Linuxppc-dev mailing list
> Linuxppc-dev@lists.ozlabs.org
> https://lists.ozlabs.org/listinfo/linuxppc-dev
>
___
Linuxppc-dev mailing list
Linuxppc-dev@lists.ozlabs.org
https://lists.ozlabs.org/listinfo/linuxppc-dev


Re: [PATCH 49/57] video: irq: Remove IRQF_DISABLED

2011-09-21 Thread David Brown
On Wed, Sep 21, 2011 at 05:28:50PM +0800, Yong Zhang wrote:
> Since commit [c58543c8: genirq: Run irq handlers with interrupts disabled],
> We run all interrupt handlers with interrupts disabled
> and we even check and yell when an interrupt handler
> returns with interrupts enabled (see commit [b738a50a:
> genirq: Warn when handler enables interrupts]).
> 
> So now this flag is a NOOP and can be removed.
> 
> Signed-off-by: Yong Zhang 
> ---
>  drivers/video/msm/mddi.c  |2 +-
>  drivers/video/msm/mdp.c   |2 +-

Acked-by: David Brown 

-- 
Sent by an employee of the Qualcomm Innovation Center, Inc.
The Qualcomm Innovation Center, Inc. is a member of the Code Aurora Forum.
___
Linuxppc-dev mailing list
Linuxppc-dev@lists.ozlabs.org
https://lists.ozlabs.org/listinfo/linuxppc-dev


Re: Timer interrupt on Linux 3.0.3

2011-09-21 Thread Scott Wood
On 09/21/2011 01:56 AM, Vineeth wrote:
>>> What was the issue?  You really should try to make this work rather than
>>> hack around it.
> 
> what we found was the decrementer is not generating an exception when it
> becomes 0. and the timebase registers are not getting incremented too.

Does the decrementer actually tick until it reaches zero, or do it and
the timebase never tick?

Is the TBEN input to the CPU asserted?

-Scott

___
Linuxppc-dev mailing list
Linuxppc-dev@lists.ozlabs.org
https://lists.ozlabs.org/listinfo/linuxppc-dev


Re: [PATCH] eSDHC: Access Freescale eSDHC registers by 32-bit

2011-09-21 Thread Chris Ball
Hi Roy,

On Fri, Sep 09 2011, Roy Zang wrote:
> From: Xu lei 
>
> Freescale eSDHC registers only support 32-bit accesses,
> this patch ensures that all Freescale eSDHC register accesses
> are 32-bit.
>
> Signed-off-by: Xu lei 
> Signed-off-by: Roy Zang 
> Signed-off-by: Kumar Gala 

Pushed to mmc-next for 3.2 with Anton's ACK now, thanks.

- Chris.
-- 
Chris Ball  
One Laptop Per Child
___
Linuxppc-dev mailing list
Linuxppc-dev@lists.ozlabs.org
https://lists.ozlabs.org/listinfo/linuxppc-dev


Re: [PATCH V2 1/2] gpio: move mpc8xxx/512x gpio driver to drivers/gpio

2011-09-21 Thread Grant Likely
On Wed, Sep 21, 2011 at 12:49:20PM +0200, Wolfram Sang wrote:
> Move the driver to the place where it is expected to be nowadays. Also
> rename its CONFIG-name to match the rest and adapt the defconfigs.
> Finally, move selection of REQUIRE_GPIOLIB or WANTS_OPTIONAL_GPIOLIB to
> the platforms, because this option is per-platform and not per-driver.
> 
> Signed-off-by: Wolfram Sang 
> Cc: Anatolij Gustschin 
> Cc: Grant Likely 
> Cc: Benjamin Herrenschmidt 
> ---
> 
> I'd think this should go via ppc, so it is in sync with the defconfig update 
> of
> patch 2/2.
> 
> Changes since V1: Use -C in format-patch to show the rename.

Nit: I prefer to see the changelog before the s-o-b lines so that it
gets included in the final commit text.  Helps when trying to identify
exactly which version of a patch got merged.

> 
>  arch/powerpc/configs/85xx/p1023rds_defconfig   |2 +-
>  arch/powerpc/configs/85xx/xes_mpc85xx_defconfig|2 +-
>  arch/powerpc/configs/mpc85xx_defconfig |2 +-
>  arch/powerpc/configs/mpc85xx_smp_defconfig |2 +-
>  arch/powerpc/configs/ppc6xx_defconfig  |2 +-
>  arch/powerpc/platforms/512x/Kconfig|1 +
>  arch/powerpc/platforms/83xx/Kconfig|9 ++---
>  arch/powerpc/platforms/85xx/Kconfig|   12 
>  arch/powerpc/platforms/86xx/Kconfig|1 +
>  arch/powerpc/platforms/Kconfig |   10 --
>  arch/powerpc/sysdev/Makefile   |1 -
>  drivers/gpio/Kconfig   |8 
>  drivers/gpio/Makefile  |1 +
>  .../mpc8xxx_gpio.c => drivers/gpio/gpio-mpc8xxx.c  |0
>  14 files changed, 30 insertions(+), 23 deletions(-)
>  rename arch/powerpc/sysdev/mpc8xxx_gpio.c => drivers/gpio/gpio-mpc8xxx.c 
> (100%)

Looks good to me.  Acked-by: Grant Likely 

Yes, it probably should go via the ppc tree.  I don't foresee any conflict
issues with the gpio tree.

g.

___
Linuxppc-dev mailing list
Linuxppc-dev@lists.ozlabs.org
https://lists.ozlabs.org/listinfo/linuxppc-dev


Re: linux-next: manual merge of the tty tree with the powerpc tree

2011-09-21 Thread Greg KH
On Wed, Sep 21, 2011 at 03:01:21PM +1000, Stephen Rothwell wrote:
> Hi Greg,
> 
> Today's linux-next merge of the tty tree got conflicts in
> arch/powerpc/include/asm/udbg.h and arch/powerpc/kernel/udbg.c between
> commit c26afe9e8591 ("powerpc/ps3: Add gelic udbg driver") from the
> powerpc tree and commit dcd83aaff1c8 ("tty/powerpc: introduce the ePAPR
> embedded hypervisor byte channel driver") from the tty tree.
> 
> Just context changes.  I fixed it up (see below) and can carry the fix as
> necessary.

Thanks, that looks fine to me.

greg k-h
___
Linuxppc-dev mailing list
Linuxppc-dev@lists.ozlabs.org
https://lists.ozlabs.org/listinfo/linuxppc-dev


Re: Timer interrupt on Linux 3.0.3

2011-09-21 Thread Vineeth
>> What was the issue?  You really should try to make this work rather than
>> hack around it.

what we found was the decrementer is not generating an exception when it
becomes 0. and the timebase registers are not getting incremented too. The
exceptions are enabled in MSR registers.

we are using embedded60x port of linux3.0.3; we've written the dts file with
proper clock-frequency/timebase-frequency values.

Do you think we might've missed some configuration in the timer perspective
?


On Fri, Sep 16, 2011 at 10:33 PM, Scott Wood wrote:

> On 09/16/2011 06:43 AM, Vineeth wrote:
> > Hi,
> >
> > We are porting Linux on MPC7410 based board. As there was some issue
> > with the processor DECrementer and timebase registers,
>
> What was the issue?  You really should try to make this work rather than
> hack around it.
>
> > lately we moved to Linux 3.0.3. What we found was even without a proper
> > timer, the kernel with initramfs worked (except the calls like
> > sleep,delay ofcourse); Is there any major difference in the scheduler ?
> > or the way context switch happens ? is it not depended on the timer
> > interrupt or the timer ??
>
> If your timer is broken then you won't get timeslice expiration, but
> basic scheduling should still work.  Most scheduling (depending on type
> of load, of course) will be triggered by processes blocking or being
> woken up by I/O, not timeslice expiration.
>
> -Scott
>
>
___
Linuxppc-dev mailing list
Linuxppc-dev@lists.ozlabs.org
https://lists.ozlabs.org/listinfo/linuxppc-dev

[PATCH v2] powerpc: reserve iommu page 0

2011-09-21 Thread Thadeu Lima de Souza Cascardo
Some devices have a dma-window that starts at the address 0. This allows
DMA addresses to be mapped to this address and returned to drivers as a
valid DMA address. Some drivers may not behave well in this case, since
the address 0 is considered an error or not allocated.

The solution to avoid this kind of error from happening is reserve the
page addressed as 0 so it cannot be allocated for a DMA mapping.

Ben Herrenschmidt deserves the credit for this patch. He pointed out the
solution and what code would do the job.

v2:
Add a comment in the code.

Signed-off-by: Thadeu Lima de Souza Cascardo 
Cc: Benjamin Herrenschmidt 
Cc: Paul Mackerras 
Cc: linuxppc-dev@lists.ozlabs.org
---

Resending, since it was recommended to add a comment about this
particular code.

---
 arch/powerpc/kernel/iommu.c |8 
 1 files changed, 8 insertions(+), 0 deletions(-)

diff --git a/arch/powerpc/kernel/iommu.c b/arch/powerpc/kernel/iommu.c
index 961bb03..8395301 100644
--- a/arch/powerpc/kernel/iommu.c
+++ b/arch/powerpc/kernel/iommu.c
@@ -501,6 +501,14 @@ struct iommu_table *iommu_init_table(struct iommu_table 
*tbl, int nid)
tbl->it_map = page_address(page);
memset(tbl->it_map, 0, sz);
 
+   /*
+* Reserve page 0 so it will not be used for any mappings.
+* This avoids buggy drivers that consider page 0 to be invalid
+* to crash the machine or even lose data.
+   */
+   if (tbl->it_offset == 0)
+   set_bit(0, tbl->it_map);
+   
tbl->it_hint = 0;
tbl->it_largehint = tbl->it_halfpoint;
spin_lock_init(&tbl->it_lock);
-- 
1.7.4.4

___
Linuxppc-dev mailing list
Linuxppc-dev@lists.ozlabs.org
https://lists.ozlabs.org/listinfo/linuxppc-dev


Re: [PATCH 53/57] sound: irq: Remove IRQF_DISABLED

2011-09-21 Thread Yong Zhang
On Wed, Sep 21, 2011 at 11:55:36AM +0200, Thomas Gleixner wrote:
> On Wed, 21 Sep 2011, Takashi Iwai wrote:
> 
> > At Wed, 21 Sep 2011 17:28:54 +0800,
> > Yong Zhang wrote:
> > > 
> > > Since commit [c58543c8: genirq: Run irq handlers with interrupts 
> > > disabled],
> > 
> > Hm, this id hits a different commit:
> > commit c58543c869606532c2382f027d6466f4672ea756
> > Author: David S. Miller 
> > Date:   Tue Oct 13 00:49:09 2009 -0700
> > 
> > sparc64: Set IRQF_DISABLED on LDC channel IRQs.
> > 
> > You mean commit e58aa3d2d0cc01ad8d6f7f640a0670433f794922?
> 
> Yeah.
>  
> > > We run all interrupt handlers with interrupts disabled
> > > and we even check and yell when an interrupt handler
> > > returns with interrupts enabled (see commit [b738a50a:
> > > genirq: Warn when handler enables interrupts]).
> > > 
> > > So now this flag is a NOOP and can be removed.
> > > 
> > > Signed-off-by: Yong Zhang 
> > > Acked-by: Mark Brown 
> > 
> > Do you want to merge by yourself or shall I take it to sound git tree?
> > Since IRQF_DISABLED isn't used, it can be applied safely in 3.1-based
> > tree, right?
> 
> Yes, please go ahead. I'll pick up the leftovers.

Takashi, if you take it, could you please modify that commit id to the
right one?

Otherwise I could change it when I refresh this patchset.

Thanks,
Yong
___
Linuxppc-dev mailing list
Linuxppc-dev@lists.ozlabs.org
https://lists.ozlabs.org/listinfo/linuxppc-dev


Re: [PATCH 53/57] sound: irq: Remove IRQF_DISABLED

2011-09-21 Thread Yong Zhang
On Wed, Sep 21, 2011 at 11:52:00AM +0200, Takashi Iwai wrote:
> At Wed, 21 Sep 2011 17:28:54 +0800,
> Yong Zhang wrote:
> > 
> > Since commit [c58543c8: genirq: Run irq handlers with interrupts disabled],
> 
> Hm, this id hits a different commit:
> commit c58543c869606532c2382f027d6466f4672ea756
> Author: David S. Miller 
> Date:   Tue Oct 13 00:49:09 2009 -0700
> 
> sparc64: Set IRQF_DISABLED on LDC channel IRQs.
> 
> You mean commit e58aa3d2d0cc01ad8d6f7f640a0670433f794922?

Oh, yes. No idea how I made it wrong :(

Thanks,
Yong

> 
> > We run all interrupt handlers with interrupts disabled
> > and we even check and yell when an interrupt handler
> > returns with interrupts enabled (see commit [b738a50a:
> > genirq: Warn when handler enables interrupts]).
> > 
> > So now this flag is a NOOP and can be removed.
> > 
> > Signed-off-by: Yong Zhang 
> > Acked-by: Mark Brown 
> 
> Do you want to merge by yourself or shall I take it to sound git tree?
> Since IRQF_DISABLED isn't used, it can be applied safely in 3.1-based
> tree, right?
> 
> Anyway, if needed, take my ack:
>   Acked-by: Takashi Iwai 
> 
> 
> thanks,
> 
> Takashi
> 
> > ---
> >  include/sound/initval.h|2 +-
> >  sound/arm/aaci.c   |2 +-
> >  sound/arm/pxa2xx-ac97-lib.c|2 +-
> >  sound/drivers/ml403-ac97cr.c   |4 ++--
> >  sound/drivers/mpu401/mpu401_uart.c |2 +-
> >  sound/drivers/mtpav.c  |2 +-
> >  sound/drivers/serial-u16550.c  |2 +-
> >  sound/isa/ad1816a/ad1816a_lib.c|2 +-
> >  sound/isa/es1688/es1688_lib.c  |2 +-
> >  sound/isa/es18xx.c |2 +-
> >  sound/isa/gus/gus_main.c   |2 +-
> >  sound/isa/gus/gusmax.c |2 +-
> >  sound/isa/gus/interwave.c  |2 +-
> >  sound/isa/opl3sa2.c|2 +-
> >  sound/isa/opti9xx/opti92x-ad1848.c |2 +-
> >  sound/isa/sb/sb_common.c   |2 +-
> >  sound/isa/wavefront/wavefront.c|2 +-
> >  sound/isa/wss/wss_lib.c|2 +-
> >  sound/mips/au1x00.c|4 ++--
> >  sound/pci/sis7019.c|4 ++--
> >  sound/ppc/snd_ps3.c|2 +-
> >  sound/soc/au1x/dma.c   |2 +-
> >  sound/soc/codecs/tlv320dac33.c |2 +-
> >  sound/soc/nuc900/nuc900-pcm.c  |2 +-
> >  sound/soc/samsung/ac97.c   |2 +-
> >  sound/soc/sh/fsi.c |2 +-
> >  sound/soc/txx9/txx9aclc-ac97.c |2 +-
> >  sound/sparc/amd7930.c  |2 +-
> >  28 files changed, 31 insertions(+), 31 deletions(-)
> > 
> > diff --git a/include/sound/initval.h b/include/sound/initval.h
> > index 1daa6df..f99a0d2 100644
> > --- a/include/sound/initval.h
> > +++ b/include/sound/initval.h
> > @@ -62,7 +62,7 @@ static int snd_legacy_find_free_irq(int *irq_table)
> >  {
> > while (*irq_table != -1) {
> > if (!request_irq(*irq_table, snd_legacy_empty_irq_handler,
> > -IRQF_DISABLED | IRQF_PROBE_SHARED, "ALSA Test 
> > IRQ",
> > +IRQF_PROBE_SHARED, "ALSA Test IRQ",
> >  (void *) irq_table)) {
> > free_irq(*irq_table, (void *) irq_table);
> > return *irq_table;
> > diff --git a/sound/arm/aaci.c b/sound/arm/aaci.c
> > index d0cead3..e518d38 100644
> > --- a/sound/arm/aaci.c
> > +++ b/sound/arm/aaci.c
> > @@ -443,7 +443,7 @@ static int aaci_pcm_open(struct snd_pcm_substream 
> > *substream)
> > mutex_lock(&aaci->irq_lock);
> > if (!aaci->users++) {
> > ret = request_irq(aaci->dev->irq[0], aaci_irq,
> > -  IRQF_SHARED | IRQF_DISABLED, DRIVER_NAME, aaci);
> > +  IRQF_SHARED, DRIVER_NAME, aaci);
> > if (ret != 0)
> > aaci->users--;
> > }
> > diff --git a/sound/arm/pxa2xx-ac97-lib.c b/sound/arm/pxa2xx-ac97-lib.c
> > index 88eec38..8ad6535 100644
> > --- a/sound/arm/pxa2xx-ac97-lib.c
> > +++ b/sound/arm/pxa2xx-ac97-lib.c
> > @@ -359,7 +359,7 @@ int __devinit pxa2xx_ac97_hw_probe(struct 
> > platform_device *dev)
> > if (ret)
> > goto err_clk2;
> >  
> > -   ret = request_irq(IRQ_AC97, pxa2xx_ac97_irq, IRQF_DISABLED, "AC97", 
> > NULL);
> > +   ret = request_irq(IRQ_AC97, pxa2xx_ac97_irq, 0, "AC97", NULL);
> > if (ret < 0)
> > goto err_irq;
> >  
> > diff --git a/sound/drivers/ml403-ac97cr.c b/sound/drivers/ml403-ac97cr.c
> > index 5cfcb90..2c7a763 100644
> > --- a/sound/drivers/ml403-ac97cr.c
> > +++ b/sound/drivers/ml403-ac97cr.c
> > @@ -1153,7 +1153,7 @@ snd_ml403_ac97cr_create(struct snd_card *card, struct 
> > platform_device *pfdev,
> >"0x%x done\n", (unsigned int)ml403_ac97cr->port);
> > /* get irq */
> > irq = platform_get_irq(pfdev, 0);
> > -   if (request_irq(irq, snd_ml403_ac97cr_irq, IRQF_DISABLED,
> > +   if (request_irq(irq, snd_ml403_ac97cr_irq, 0

[PATCH V2 1/2] gpio: move mpc8xxx/512x gpio driver to drivers/gpio

2011-09-21 Thread Wolfram Sang
Move the driver to the place where it is expected to be nowadays. Also
rename its CONFIG-name to match the rest and adapt the defconfigs.
Finally, move selection of REQUIRE_GPIOLIB or WANTS_OPTIONAL_GPIOLIB to
the platforms, because this option is per-platform and not per-driver.

Signed-off-by: Wolfram Sang 
Cc: Anatolij Gustschin 
Cc: Grant Likely 
Cc: Benjamin Herrenschmidt 
---

I'd think this should go via ppc, so it is in sync with the defconfig update of
patch 2/2.

Changes since V1: Use -C in format-patch to show the rename.

 arch/powerpc/configs/85xx/p1023rds_defconfig   |2 +-
 arch/powerpc/configs/85xx/xes_mpc85xx_defconfig|2 +-
 arch/powerpc/configs/mpc85xx_defconfig |2 +-
 arch/powerpc/configs/mpc85xx_smp_defconfig |2 +-
 arch/powerpc/configs/ppc6xx_defconfig  |2 +-
 arch/powerpc/platforms/512x/Kconfig|1 +
 arch/powerpc/platforms/83xx/Kconfig|9 ++---
 arch/powerpc/platforms/85xx/Kconfig|   12 
 arch/powerpc/platforms/86xx/Kconfig|1 +
 arch/powerpc/platforms/Kconfig |   10 --
 arch/powerpc/sysdev/Makefile   |1 -
 drivers/gpio/Kconfig   |8 
 drivers/gpio/Makefile  |1 +
 .../mpc8xxx_gpio.c => drivers/gpio/gpio-mpc8xxx.c  |0
 14 files changed, 30 insertions(+), 23 deletions(-)
 rename arch/powerpc/sysdev/mpc8xxx_gpio.c => drivers/gpio/gpio-mpc8xxx.c (100%)

diff --git a/arch/powerpc/configs/85xx/p1023rds_defconfig 
b/arch/powerpc/configs/85xx/p1023rds_defconfig
index 3ff5a81..c091aaf 100644
--- a/arch/powerpc/configs/85xx/p1023rds_defconfig
+++ b/arch/powerpc/configs/85xx/p1023rds_defconfig
@@ -24,7 +24,7 @@ CONFIG_P1023_RDS=y
 CONFIG_QUICC_ENGINE=y
 CONFIG_QE_GPIO=y
 CONFIG_CPM2=y
-CONFIG_MPC8xxx_GPIO=y
+CONFIG_GPIO_MPC8XXX=y
 CONFIG_HIGHMEM=y
 CONFIG_NO_HZ=y
 CONFIG_HIGH_RES_TIMERS=y
diff --git a/arch/powerpc/configs/85xx/xes_mpc85xx_defconfig 
b/arch/powerpc/configs/85xx/xes_mpc85xx_defconfig
index 5ea3124..1cd6fcb 100644
--- a/arch/powerpc/configs/85xx/xes_mpc85xx_defconfig
+++ b/arch/powerpc/configs/85xx/xes_mpc85xx_defconfig
@@ -20,7 +20,7 @@ CONFIG_MODULE_FORCE_UNLOAD=y
 CONFIG_MODVERSIONS=y
 # CONFIG_BLK_DEV_BSG is not set
 CONFIG_XES_MPC85xx=y
-CONFIG_MPC8xxx_GPIO=y
+CONFIG_GPIO_MPC8XXX=y
 CONFIG_HIGHMEM=y
 CONFIG_MATH_EMULATION=y
 CONFIG_SPARSE_IRQ=y
diff --git a/arch/powerpc/configs/mpc85xx_defconfig 
b/arch/powerpc/configs/mpc85xx_defconfig
index a3467bf..2500912 100644
--- a/arch/powerpc/configs/mpc85xx_defconfig
+++ b/arch/powerpc/configs/mpc85xx_defconfig
@@ -41,7 +41,7 @@ CONFIG_TQM8560=y
 CONFIG_SBC8548=y
 CONFIG_QUICC_ENGINE=y
 CONFIG_QE_GPIO=y
-CONFIG_MPC8xxx_GPIO=y
+CONFIG_GPIO_MPC8XXX=y
 CONFIG_HIGHMEM=y
 CONFIG_NO_HZ=y
 CONFIG_HIGH_RES_TIMERS=y
diff --git a/arch/powerpc/configs/mpc85xx_smp_defconfig 
b/arch/powerpc/configs/mpc85xx_smp_defconfig
index 9693f6e..a4ba13b 100644
--- a/arch/powerpc/configs/mpc85xx_smp_defconfig
+++ b/arch/powerpc/configs/mpc85xx_smp_defconfig
@@ -42,7 +42,7 @@ CONFIG_TQM8560=y
 CONFIG_SBC8548=y
 CONFIG_QUICC_ENGINE=y
 CONFIG_QE_GPIO=y
-CONFIG_MPC8xxx_GPIO=y
+CONFIG_GPIO_MPC8XXX=y
 CONFIG_HIGHMEM=y
 CONFIG_NO_HZ=y
 CONFIG_HIGH_RES_TIMERS=y
diff --git a/arch/powerpc/configs/ppc6xx_defconfig 
b/arch/powerpc/configs/ppc6xx_defconfig
index 04360f9..c47f2be 100644
--- a/arch/powerpc/configs/ppc6xx_defconfig
+++ b/arch/powerpc/configs/ppc6xx_defconfig
@@ -70,7 +70,7 @@ CONFIG_TAU_AVERAGE=y
 CONFIG_QUICC_ENGINE=y
 CONFIG_QE_GPIO=y
 CONFIG_PPC_BESTCOMM=y
-CONFIG_MPC8xxx_GPIO=y
+CONFIG_GPIO_MPC8XXX=y
 CONFIG_MCU_MPC8349EMITX=m
 CONFIG_HIGHMEM=y
 CONFIG_NO_HZ=y
diff --git a/arch/powerpc/platforms/512x/Kconfig 
b/arch/powerpc/platforms/512x/Kconfig
index 27b0651..b3ebce1 100644
--- a/arch/powerpc/platforms/512x/Kconfig
+++ b/arch/powerpc/platforms/512x/Kconfig
@@ -6,6 +6,7 @@ config PPC_MPC512x
select PPC_CLOCK
select PPC_PCI_CHOICE
select FSL_PCI if PCI
+   select ARCH_WANT_OPTIONAL_GPIOLIB
 
 config MPC5121_ADS
bool "Freescale MPC5121E ADS"
diff --git a/arch/powerpc/platforms/83xx/Kconfig 
b/arch/powerpc/platforms/83xx/Kconfig
index 73f4135..670a033 100644
--- a/arch/powerpc/platforms/83xx/Kconfig
+++ b/arch/powerpc/platforms/83xx/Kconfig
@@ -114,18 +114,21 @@ config KMETER1
 
 endif
 
-# used for usb
+# used for usb & gpio
 config PPC_MPC831x
bool
+   select ARCH_WANT_OPTIONAL_GPIOLIB
 
 # used for math-emu
 config PPC_MPC832x
bool
 
-# used for usb
+# used for usb & gpio
 config PPC_MPC834x
bool
+   select ARCH_WANT_OPTIONAL_GPIOLIB
 
-# used for usb
+# used for usb & gpio
 config PPC_MPC837x
bool
+   select ARCH_WANT_OPTIONAL_GPIOLIB
diff --git a/arch/powerpc/platforms/85xx/Kconfig 
b/arch/powerpc/platforms/85xx/Kconfig
index 498534c..1b393f4 100644
--- a/arch/powerpc/platforms/85xx/Kconfig
+++ b/arch/

[PATCH V2 2/2] powerpc: update 512x-defconfig

2011-09-21 Thread Wolfram Sang
Activate all MPC512x related boards. Also enable GPIO-driver, SPI driver
and at25 to test SPI. Enable DEVTMPFS. Bump to 3.1-rc6.

Signed-off-by: Wolfram Sang 
Cc: Anatolij Gustschin 
Cc: Benjamin Herrenschmidt 
---
 arch/powerpc/configs/mpc512x_defconfig |   19 +++
 1 files changed, 11 insertions(+), 8 deletions(-)

diff --git a/arch/powerpc/configs/mpc512x_defconfig 
b/arch/powerpc/configs/mpc512x_defconfig
index c02bbb2..211fcc9 100644
--- a/arch/powerpc/configs/mpc512x_defconfig
+++ b/arch/powerpc/configs/mpc512x_defconfig
@@ -1,9 +1,9 @@
 CONFIG_EXPERIMENTAL=y
 # CONFIG_SWAP is not set
 CONFIG_SYSVIPC=y
+CONFIG_SPARSE_IRQ=y
 CONFIG_LOG_BUF_SHIFT=16
 CONFIG_BLK_DEV_INITRD=y
-# CONFIG_CC_OPTIMIZE_FOR_SIZE is not set
 # CONFIG_COMPAT_BRK is not set
 CONFIG_SLAB=y
 CONFIG_MODULES=y
@@ -13,10 +13,11 @@ CONFIG_MODULE_UNLOAD=y
 # CONFIG_PPC_CHRP is not set
 CONFIG_PPC_MPC512x=y
 CONFIG_MPC5121_ADS=y
+CONFIG_MPC5121_GENERIC=y
+CONFIG_PDM360NG=y
 # CONFIG_PPC_PMAC is not set
 CONFIG_NO_HZ=y
 CONFIG_HZ_1000=y
-CONFIG_SPARSE_IRQ=y
 # CONFIG_MIGRATION is not set
 # CONFIG_SECCOMP is not set
 # CONFIG_PCI is not set
@@ -35,18 +36,16 @@ CONFIG_CAN=y
 CONFIG_CAN_RAW=y
 CONFIG_CAN_BCM=y
 CONFIG_CAN_VCAN=y
-CONFIG_CAN_DEV=y
 CONFIG_CAN_MSCAN=y
 CONFIG_CAN_DEBUG_DEVICES=y
 # CONFIG_WIRELESS is not set
 CONFIG_UEVENT_HELPER_PATH="/sbin/hotplug"
+CONFIG_DEVTMPFS=y
+CONFIG_DEVTMPFS_MOUNT=y
 # CONFIG_PREVENT_FIRMWARE_BUILD is not set
 # CONFIG_FIRMWARE_IN_KERNEL is not set
 CONFIG_MTD=y
-CONFIG_MTD_CONCAT=y
-CONFIG_MTD_PARTITIONS=y
 CONFIG_MTD_CMDLINE_PARTS=y
-CONFIG_MTD_OF_PARTS=y
 CONFIG_MTD_CHAR=y
 CONFIG_MTD_BLOCK=y
 CONFIG_MTD_CFI=y
@@ -63,6 +62,7 @@ CONFIG_BLK_DEV_RAM_SIZE=8192
 CONFIG_BLK_DEV_XIP=y
 CONFIG_MISC_DEVICES=y
 CONFIG_EEPROM_AT24=y
+CONFIG_EEPROM_AT25=y
 CONFIG_SCSI=y
 # CONFIG_SCSI_PROC_FS is not set
 CONFIG_BLK_DEV_SD=y
@@ -99,10 +99,14 @@ CONFIG_SERIAL_MPC52xx_CONSOLE_BAUD=115200
 CONFIG_I2C=y
 CONFIG_I2C_CHARDEV=y
 CONFIG_I2C_MPC=y
+CONFIG_SPI=y
+CONFIG_SPI_MPC512x_PSC=y
+CONFIG_GPIOLIB=y
+CONFIG_GPIO_SYSFS=y
+CONFIG_GPIO_MPC8XXX=y
 # CONFIG_HWMON is not set
 CONFIG_MEDIA_SUPPORT=y
 CONFIG_VIDEO_DEV=y
-# CONFIG_VIDEO_ALLOW_V4L1 is not set
 CONFIG_VIDEO_ADV_DEBUG=y
 # CONFIG_VIDEO_HELPER_CHIPS_AUTO is not set
 CONFIG_VIDEO_SAA711X=y
@@ -132,6 +136,5 @@ CONFIG_NLS_CODEPAGE_437=y
 CONFIG_NLS_ISO8859_1=y
 # CONFIG_ENABLE_WARN_DEPRECATED is not set
 # CONFIG_ENABLE_MUST_CHECK is not set
-# CONFIG_RCU_CPU_STALL_DETECTOR is not set
 # CONFIG_CRYPTO_ANSI_CPRNG is not set
 # CONFIG_CRYPTO_HW is not set
-- 
1.7.5.4

___
Linuxppc-dev mailing list
Linuxppc-dev@lists.ozlabs.org
https://lists.ozlabs.org/listinfo/linuxppc-dev


[PATCH] PSeries: Cancel RTAS event scan before firmware flash

2011-09-21 Thread Ravi K Nittala
The RTAS firmware flash update is conducted using an RTAS call that is
serialized by lock_rtas() which uses spin_lock. While the flash is in
progress, rtasd performs scan for any RTAS events that are generated by
the system. rtasd keeps scanning for the RTAS events generated on the
machine. This is performed via workqueue mechanism. The rtas_event_scan()
also uses an RTAS call to scan the events, eventually trying to acquire
the spin_lock before issuing the request.

The flash update takes a while to complete and during this time, any other
RTAS call has to wait. In this case, rtas_event_scan() waits for a long time
on the spin_lock resulting in a soft lockup.

Fix: Just before the flash update is performed, the queued rtas_event_scan()
work item is cancelled from the work queue so that there is no other RTAS
call issued while the flash is in progress. After the flash completes, the
system reboots and the rtas_event_scan() is rescheduled.

Signed-off-by: Suzuki Poulose 
Signed-off-by: Ravi Nittala 

---

 arch/powerpc/include/asm/rtas.h  |4 
 arch/powerpc/kernel/rtas_flash.c |8 
 arch/powerpc/kernel/rtasd.c  |6 ++
 3 files changed, 18 insertions(+), 0 deletions(-)

diff --git a/arch/powerpc/include/asm/rtas.h b/arch/powerpc/include/asm/rtas.h
index 58625d1..b5cbd9f 100644
--- a/arch/powerpc/include/asm/rtas.h
+++ b/arch/powerpc/include/asm/rtas.h
@@ -245,6 +245,10 @@ extern int early_init_dt_scan_rtas(unsigned long node,
 
 extern void pSeries_log_error(char *buf, unsigned int err_type, int fatal);
 
+#ifdef CONFIG_PPC_RTAS_DAEMON
+extern bool rtas_cancel_event_scan(void);
+#endif
+
 /* Error types logged.  */
 #define ERR_FLAG_ALREADY_LOGGED0x0
 #define ERR_FLAG_BOOT  0x1 /* log was pulled from NVRAM on boot */
diff --git a/arch/powerpc/kernel/rtas_flash.c b/arch/powerpc/kernel/rtas_flash.c
index e037c74..a9cceff 100644
--- a/arch/powerpc/kernel/rtas_flash.c
+++ b/arch/powerpc/kernel/rtas_flash.c
@@ -567,6 +567,14 @@ static void rtas_flash_firmware(int reboot_type)
return;
}
 
+#ifdef CONFIG_PPC_RTAS_DAEMON
+   /*
+* Just before starting the firmware flash, cancel the event scan work
+* to avoid any soft lockup issues.
+*/
+   rtas_cancel_event_scan();
+#endif
+
/*
 * NOTE: the "first" block must be under 4GB, so we create
 * an entry with no data blocks in the reserved buffer in
diff --git a/arch/powerpc/kernel/rtasd.c b/arch/powerpc/kernel/rtasd.c
index 481ef06..e8f03fa 100644
--- a/arch/powerpc/kernel/rtasd.c
+++ b/arch/powerpc/kernel/rtasd.c
@@ -472,6 +472,12 @@ static void start_event_scan(void)
 &event_scan_work, event_scan_delay);
 }
 
+/* Cancel the rtas event scan work */
+bool rtas_cancel_event_scan(void)
+{
+   return cancel_delayed_work_sync(&event_scan_work);
+}
+
 static int __init rtas_init(void)
 {
struct proc_dir_entry *entry;

___
Linuxppc-dev mailing list
Linuxppc-dev@lists.ozlabs.org
https://lists.ozlabs.org/listinfo/linuxppc-dev


Re: [PATCH 53/57] sound: irq: Remove IRQF_DISABLED

2011-09-21 Thread Ujfalusi, Peter
On Wed, Sep 21, 2011 at 12:28 PM, Yong Zhang  wrote:
> Since commit [c58543c8: genirq: Run irq handlers with interrupts disabled],
> We run all interrupt handlers with interrupts disabled
> and we even check and yell when an interrupt handler
> returns with interrupts enabled (see commit [b738a50a:
> genirq: Warn when handler enables interrupts]).
>
> So now this flag is a NOOP and can be removed.
>
> Signed-off-by: Yong Zhang 
> Acked-by: Mark Brown 

Acked-by: Peter Ujfalusi 
___
Linuxppc-dev mailing list
Linuxppc-dev@lists.ozlabs.org
https://lists.ozlabs.org/listinfo/linuxppc-dev


Re: [PATCH 53/57] sound: irq: Remove IRQF_DISABLED

2011-09-21 Thread Thomas Gleixner
On Wed, 21 Sep 2011, Takashi Iwai wrote:

> At Wed, 21 Sep 2011 17:28:54 +0800,
> Yong Zhang wrote:
> > 
> > Since commit [c58543c8: genirq: Run irq handlers with interrupts disabled],
> 
> Hm, this id hits a different commit:
> commit c58543c869606532c2382f027d6466f4672ea756
> Author: David S. Miller 
> Date:   Tue Oct 13 00:49:09 2009 -0700
> 
> sparc64: Set IRQF_DISABLED on LDC channel IRQs.
> 
> You mean commit e58aa3d2d0cc01ad8d6f7f640a0670433f794922?

Yeah.
 
> > We run all interrupt handlers with interrupts disabled
> > and we even check and yell when an interrupt handler
> > returns with interrupts enabled (see commit [b738a50a:
> > genirq: Warn when handler enables interrupts]).
> > 
> > So now this flag is a NOOP and can be removed.
> > 
> > Signed-off-by: Yong Zhang 
> > Acked-by: Mark Brown 
> 
> Do you want to merge by yourself or shall I take it to sound git tree?
> Since IRQF_DISABLED isn't used, it can be applied safely in 3.1-based
> tree, right?

Yes, please go ahead. I'll pick up the leftovers.

Thanks,

tglx
___
Linuxppc-dev mailing list
Linuxppc-dev@lists.ozlabs.org
https://lists.ozlabs.org/listinfo/linuxppc-dev


Re: [PATCH 53/57] sound: irq: Remove IRQF_DISABLED

2011-09-21 Thread Takashi Iwai
At Wed, 21 Sep 2011 17:28:54 +0800,
Yong Zhang wrote:
> 
> Since commit [c58543c8: genirq: Run irq handlers with interrupts disabled],

Hm, this id hits a different commit:
commit c58543c869606532c2382f027d6466f4672ea756
Author: David S. Miller 
Date:   Tue Oct 13 00:49:09 2009 -0700

sparc64: Set IRQF_DISABLED on LDC channel IRQs.

You mean commit e58aa3d2d0cc01ad8d6f7f640a0670433f794922?

> We run all interrupt handlers with interrupts disabled
> and we even check and yell when an interrupt handler
> returns with interrupts enabled (see commit [b738a50a:
> genirq: Warn when handler enables interrupts]).
> 
> So now this flag is a NOOP and can be removed.
> 
> Signed-off-by: Yong Zhang 
> Acked-by: Mark Brown 

Do you want to merge by yourself or shall I take it to sound git tree?
Since IRQF_DISABLED isn't used, it can be applied safely in 3.1-based
tree, right?

Anyway, if needed, take my ack:
Acked-by: Takashi Iwai 


thanks,

Takashi

> ---
>  include/sound/initval.h|2 +-
>  sound/arm/aaci.c   |2 +-
>  sound/arm/pxa2xx-ac97-lib.c|2 +-
>  sound/drivers/ml403-ac97cr.c   |4 ++--
>  sound/drivers/mpu401/mpu401_uart.c |2 +-
>  sound/drivers/mtpav.c  |2 +-
>  sound/drivers/serial-u16550.c  |2 +-
>  sound/isa/ad1816a/ad1816a_lib.c|2 +-
>  sound/isa/es1688/es1688_lib.c  |2 +-
>  sound/isa/es18xx.c |2 +-
>  sound/isa/gus/gus_main.c   |2 +-
>  sound/isa/gus/gusmax.c |2 +-
>  sound/isa/gus/interwave.c  |2 +-
>  sound/isa/opl3sa2.c|2 +-
>  sound/isa/opti9xx/opti92x-ad1848.c |2 +-
>  sound/isa/sb/sb_common.c   |2 +-
>  sound/isa/wavefront/wavefront.c|2 +-
>  sound/isa/wss/wss_lib.c|2 +-
>  sound/mips/au1x00.c|4 ++--
>  sound/pci/sis7019.c|4 ++--
>  sound/ppc/snd_ps3.c|2 +-
>  sound/soc/au1x/dma.c   |2 +-
>  sound/soc/codecs/tlv320dac33.c |2 +-
>  sound/soc/nuc900/nuc900-pcm.c  |2 +-
>  sound/soc/samsung/ac97.c   |2 +-
>  sound/soc/sh/fsi.c |2 +-
>  sound/soc/txx9/txx9aclc-ac97.c |2 +-
>  sound/sparc/amd7930.c  |2 +-
>  28 files changed, 31 insertions(+), 31 deletions(-)
> 
> diff --git a/include/sound/initval.h b/include/sound/initval.h
> index 1daa6df..f99a0d2 100644
> --- a/include/sound/initval.h
> +++ b/include/sound/initval.h
> @@ -62,7 +62,7 @@ static int snd_legacy_find_free_irq(int *irq_table)
>  {
>   while (*irq_table != -1) {
>   if (!request_irq(*irq_table, snd_legacy_empty_irq_handler,
> -  IRQF_DISABLED | IRQF_PROBE_SHARED, "ALSA Test 
> IRQ",
> +  IRQF_PROBE_SHARED, "ALSA Test IRQ",
>(void *) irq_table)) {
>   free_irq(*irq_table, (void *) irq_table);
>   return *irq_table;
> diff --git a/sound/arm/aaci.c b/sound/arm/aaci.c
> index d0cead3..e518d38 100644
> --- a/sound/arm/aaci.c
> +++ b/sound/arm/aaci.c
> @@ -443,7 +443,7 @@ static int aaci_pcm_open(struct snd_pcm_substream 
> *substream)
>   mutex_lock(&aaci->irq_lock);
>   if (!aaci->users++) {
>   ret = request_irq(aaci->dev->irq[0], aaci_irq,
> -IRQF_SHARED | IRQF_DISABLED, DRIVER_NAME, aaci);
> +IRQF_SHARED, DRIVER_NAME, aaci);
>   if (ret != 0)
>   aaci->users--;
>   }
> diff --git a/sound/arm/pxa2xx-ac97-lib.c b/sound/arm/pxa2xx-ac97-lib.c
> index 88eec38..8ad6535 100644
> --- a/sound/arm/pxa2xx-ac97-lib.c
> +++ b/sound/arm/pxa2xx-ac97-lib.c
> @@ -359,7 +359,7 @@ int __devinit pxa2xx_ac97_hw_probe(struct platform_device 
> *dev)
>   if (ret)
>   goto err_clk2;
>  
> - ret = request_irq(IRQ_AC97, pxa2xx_ac97_irq, IRQF_DISABLED, "AC97", 
> NULL);
> + ret = request_irq(IRQ_AC97, pxa2xx_ac97_irq, 0, "AC97", NULL);
>   if (ret < 0)
>   goto err_irq;
>  
> diff --git a/sound/drivers/ml403-ac97cr.c b/sound/drivers/ml403-ac97cr.c
> index 5cfcb90..2c7a763 100644
> --- a/sound/drivers/ml403-ac97cr.c
> +++ b/sound/drivers/ml403-ac97cr.c
> @@ -1153,7 +1153,7 @@ snd_ml403_ac97cr_create(struct snd_card *card, struct 
> platform_device *pfdev,
>  "0x%x done\n", (unsigned int)ml403_ac97cr->port);
>   /* get irq */
>   irq = platform_get_irq(pfdev, 0);
> - if (request_irq(irq, snd_ml403_ac97cr_irq, IRQF_DISABLED,
> + if (request_irq(irq, snd_ml403_ac97cr_irq, 0,
>   dev_name(&pfdev->dev), (void *)ml403_ac97cr)) {
>   snd_printk(KERN_ERR SND_ML403_AC97CR_DRIVER ": "
>  "unable to grab IRQ %d\n",
> @@ -1166,7 +1166,7 @@ snd_ml403_ac97cr_create(struct snd_card *card, struct 
> platform_device *pfdev,
>   

[PATCH 53/57] sound: irq: Remove IRQF_DISABLED

2011-09-21 Thread Yong Zhang
Since commit [c58543c8: genirq: Run irq handlers with interrupts disabled],
We run all interrupt handlers with interrupts disabled
and we even check and yell when an interrupt handler
returns with interrupts enabled (see commit [b738a50a:
genirq: Warn when handler enables interrupts]).

So now this flag is a NOOP and can be removed.

Signed-off-by: Yong Zhang 
Acked-by: Mark Brown 
---
 include/sound/initval.h|2 +-
 sound/arm/aaci.c   |2 +-
 sound/arm/pxa2xx-ac97-lib.c|2 +-
 sound/drivers/ml403-ac97cr.c   |4 ++--
 sound/drivers/mpu401/mpu401_uart.c |2 +-
 sound/drivers/mtpav.c  |2 +-
 sound/drivers/serial-u16550.c  |2 +-
 sound/isa/ad1816a/ad1816a_lib.c|2 +-
 sound/isa/es1688/es1688_lib.c  |2 +-
 sound/isa/es18xx.c |2 +-
 sound/isa/gus/gus_main.c   |2 +-
 sound/isa/gus/gusmax.c |2 +-
 sound/isa/gus/interwave.c  |2 +-
 sound/isa/opl3sa2.c|2 +-
 sound/isa/opti9xx/opti92x-ad1848.c |2 +-
 sound/isa/sb/sb_common.c   |2 +-
 sound/isa/wavefront/wavefront.c|2 +-
 sound/isa/wss/wss_lib.c|2 +-
 sound/mips/au1x00.c|4 ++--
 sound/pci/sis7019.c|4 ++--
 sound/ppc/snd_ps3.c|2 +-
 sound/soc/au1x/dma.c   |2 +-
 sound/soc/codecs/tlv320dac33.c |2 +-
 sound/soc/nuc900/nuc900-pcm.c  |2 +-
 sound/soc/samsung/ac97.c   |2 +-
 sound/soc/sh/fsi.c |2 +-
 sound/soc/txx9/txx9aclc-ac97.c |2 +-
 sound/sparc/amd7930.c  |2 +-
 28 files changed, 31 insertions(+), 31 deletions(-)

diff --git a/include/sound/initval.h b/include/sound/initval.h
index 1daa6df..f99a0d2 100644
--- a/include/sound/initval.h
+++ b/include/sound/initval.h
@@ -62,7 +62,7 @@ static int snd_legacy_find_free_irq(int *irq_table)
 {
while (*irq_table != -1) {
if (!request_irq(*irq_table, snd_legacy_empty_irq_handler,
-IRQF_DISABLED | IRQF_PROBE_SHARED, "ALSA Test 
IRQ",
+IRQF_PROBE_SHARED, "ALSA Test IRQ",
 (void *) irq_table)) {
free_irq(*irq_table, (void *) irq_table);
return *irq_table;
diff --git a/sound/arm/aaci.c b/sound/arm/aaci.c
index d0cead3..e518d38 100644
--- a/sound/arm/aaci.c
+++ b/sound/arm/aaci.c
@@ -443,7 +443,7 @@ static int aaci_pcm_open(struct snd_pcm_substream 
*substream)
mutex_lock(&aaci->irq_lock);
if (!aaci->users++) {
ret = request_irq(aaci->dev->irq[0], aaci_irq,
-  IRQF_SHARED | IRQF_DISABLED, DRIVER_NAME, aaci);
+  IRQF_SHARED, DRIVER_NAME, aaci);
if (ret != 0)
aaci->users--;
}
diff --git a/sound/arm/pxa2xx-ac97-lib.c b/sound/arm/pxa2xx-ac97-lib.c
index 88eec38..8ad6535 100644
--- a/sound/arm/pxa2xx-ac97-lib.c
+++ b/sound/arm/pxa2xx-ac97-lib.c
@@ -359,7 +359,7 @@ int __devinit pxa2xx_ac97_hw_probe(struct platform_device 
*dev)
if (ret)
goto err_clk2;
 
-   ret = request_irq(IRQ_AC97, pxa2xx_ac97_irq, IRQF_DISABLED, "AC97", 
NULL);
+   ret = request_irq(IRQ_AC97, pxa2xx_ac97_irq, 0, "AC97", NULL);
if (ret < 0)
goto err_irq;
 
diff --git a/sound/drivers/ml403-ac97cr.c b/sound/drivers/ml403-ac97cr.c
index 5cfcb90..2c7a763 100644
--- a/sound/drivers/ml403-ac97cr.c
+++ b/sound/drivers/ml403-ac97cr.c
@@ -1153,7 +1153,7 @@ snd_ml403_ac97cr_create(struct snd_card *card, struct 
platform_device *pfdev,
   "0x%x done\n", (unsigned int)ml403_ac97cr->port);
/* get irq */
irq = platform_get_irq(pfdev, 0);
-   if (request_irq(irq, snd_ml403_ac97cr_irq, IRQF_DISABLED,
+   if (request_irq(irq, snd_ml403_ac97cr_irq, 0,
dev_name(&pfdev->dev), (void *)ml403_ac97cr)) {
snd_printk(KERN_ERR SND_ML403_AC97CR_DRIVER ": "
   "unable to grab IRQ %d\n",
@@ -1166,7 +1166,7 @@ snd_ml403_ac97cr_create(struct snd_card *card, struct 
platform_device *pfdev,
   "request (playback) irq %d done\n",
   ml403_ac97cr->irq);
irq = platform_get_irq(pfdev, 1);
-   if (request_irq(irq, snd_ml403_ac97cr_irq, IRQF_DISABLED,
+   if (request_irq(irq, snd_ml403_ac97cr_irq, 0,
dev_name(&pfdev->dev), (void *)ml403_ac97cr)) {
snd_printk(KERN_ERR SND_ML403_AC97CR_DRIVER ": "
   "unable to grab IRQ %d\n",
diff --git a/sound/drivers/mpu401/mpu401_uart.c 
b/sound/drivers/mpu401/mpu401_uart.c
index 34df505..1cff331 100644
--- a/sound/drivers/mpu401/mpu401_uart.c
+++ b/sound/drivers/mpu401/mpu401_uart.c
@@ -578,7 +578,7 @@ int snd_mpu401_uart_new(struct snd_card *card, int device

[PATCH 49/57] video: irq: Remove IRQF_DISABLED

2011-09-21 Thread Yong Zhang
Since commit [c58543c8: genirq: Run irq handlers with interrupts disabled],
We run all interrupt handlers with interrupts disabled
and we even check and yell when an interrupt handler
returns with interrupts enabled (see commit [b738a50a:
genirq: Warn when handler enables interrupts]).

So now this flag is a NOOP and can be removed.

Signed-off-by: Yong Zhang 
---
 drivers/video/au1200fb.c  |2 +-
 drivers/video/bf54x-lq043fb.c |2 +-
 drivers/video/bfin-lq035q1-fb.c   |2 +-
 drivers/video/bfin-t350mcqb-fb.c  |2 +-
 drivers/video/bfin_adv7393fb.c|2 +-
 drivers/video/mb862xx/mb862xxfbdrv.c  |4 ++--
 drivers/video/msm/mddi.c  |2 +-
 drivers/video/msm/mdp.c   |2 +-
 drivers/video/nuc900fb.c  |2 +-
 drivers/video/omap2/displays/panel-taal.c |2 +-
 drivers/video/ps3fb.c |2 +-
 drivers/video/pxa3xx-gcu.c|2 +-
 drivers/video/pxafb.c |2 +-
 drivers/video/s3c2410fb.c |2 +-
 drivers/video/sa1100fb.c  |3 +--
 drivers/video/sh_mobile_lcdcfb.c  |2 +-
 drivers/video/tmiofb.c|2 +-
 drivers/video/vt8500lcdfb.c   |2 +-
 18 files changed, 19 insertions(+), 20 deletions(-)

diff --git a/drivers/video/au1200fb.c b/drivers/video/au1200fb.c
index a19a40e..7200559 100644
--- a/drivers/video/au1200fb.c
+++ b/drivers/video/au1200fb.c
@@ -1673,7 +1673,7 @@ static int __devinit au1200fb_drv_probe(struct 
platform_device *dev)
/* Now hook interrupt too */
irq = platform_get_irq(dev, 0);
ret = request_irq(irq, au1200fb_handle_irq,
- IRQF_DISABLED | IRQF_SHARED, "lcd", (void *)dev);
+ IRQF_SHARED, "lcd", (void *)dev);
if (ret) {
print_err("fail to request interrupt line %d (err: %d)",
  irq, ret);
diff --git a/drivers/video/bf54x-lq043fb.c b/drivers/video/bf54x-lq043fb.c
index 2464b91..56720fb 100644
--- a/drivers/video/bf54x-lq043fb.c
+++ b/drivers/video/bf54x-lq043fb.c
@@ -633,7 +633,7 @@ static int __devinit bfin_bf54x_probe(struct 
platform_device *pdev)
goto out7;
}
 
-   if (request_irq(info->irq, bfin_bf54x_irq_error, IRQF_DISABLED,
+   if (request_irq(info->irq, bfin_bf54x_irq_error, 0,
"PPI ERROR", info) < 0) {
printk(KERN_ERR DRIVER_NAME
   ": unable to request PPI ERROR IRQ\n");
diff --git a/drivers/video/bfin-lq035q1-fb.c b/drivers/video/bfin-lq035q1-fb.c
index 23b6c4b..c633068 100644
--- a/drivers/video/bfin-lq035q1-fb.c
+++ b/drivers/video/bfin-lq035q1-fb.c
@@ -695,7 +695,7 @@ static int __devinit bfin_lq035q1_probe(struct 
platform_device *pdev)
goto out7;
}
 
-   ret = request_irq(info->irq, bfin_lq035q1_irq_error, IRQF_DISABLED,
+   ret = request_irq(info->irq, bfin_lq035q1_irq_error, 0,
DRIVER_NAME" PPI ERROR", info);
if (ret < 0) {
dev_err(&pdev->dev, "unable to request PPI ERROR IRQ\n");
diff --git a/drivers/video/bfin-t350mcqb-fb.c b/drivers/video/bfin-t350mcqb-fb.c
index d8de29f..d5e1267 100644
--- a/drivers/video/bfin-t350mcqb-fb.c
+++ b/drivers/video/bfin-t350mcqb-fb.c
@@ -529,7 +529,7 @@ static int __devinit bfin_t350mcqb_probe(struct 
platform_device *pdev)
goto out7;
}
 
-   ret = request_irq(info->irq, bfin_t350mcqb_irq_error, IRQF_DISABLED,
+   ret = request_irq(info->irq, bfin_t350mcqb_irq_error, 0,
"PPI ERROR", info);
if (ret < 0) {
printk(KERN_ERR DRIVER_NAME
diff --git a/drivers/video/bfin_adv7393fb.c b/drivers/video/bfin_adv7393fb.c
index 8486f54..811dd7f 100644
--- a/drivers/video/bfin_adv7393fb.c
+++ b/drivers/video/bfin_adv7393fb.c
@@ -481,7 +481,7 @@ static int __devinit bfin_adv7393_fb_probe(struct 
i2c_client *client,
goto out_4;
}
 
-   if (request_irq(IRQ_PPI_ERROR, ppi_irq_error, IRQF_DISABLED,
+   if (request_irq(IRQ_PPI_ERROR, ppi_irq_error, 0,
"PPI ERROR", fbdev) < 0) {
dev_err(&client->dev, "unable to request PPI ERROR IRQ\n");
ret = -EFAULT;
diff --git a/drivers/video/mb862xx/mb862xxfbdrv.c 
b/drivers/video/mb862xx/mb862xxfbdrv.c
index 12a634a..11a7a33 100644
--- a/drivers/video/mb862xx/mb862xxfbdrv.c
+++ b/drivers/video/mb862xx/mb862xxfbdrv.c
@@ -738,7 +738,7 @@ static int __devinit of_platform_mb862xx_probe(struct 
platform_device *ofdev)
if (mb862xx_gdc_init(par))
goto io_unmap;
 
-   if (request_irq(par->irq, mb862xx_intr, IRQF_DISABLED,
+   if (request_irq(par->irq, mb862xx_intr, 0,
DRV_NAME, (void *)par)) {
dev_err(dev, "Cannot request irq\n");

[PATCH 48/57] TTY: irq: Remove IRQF_DISABLED

2011-09-21 Thread Yong Zhang
Since commit [c58543c8: genirq: Run irq handlers with interrupts disabled],
We run all interrupt handlers with interrupts disabled
and we even check and yell when an interrupt handler
returns with interrupts enabled (see commit [b738a50a:
genirq: Warn when handler enables interrupts]).

So now this flag is a NOOP and can be removed.

Signed-off-by: Yong Zhang 
Acked-by: Tobias Klauser 
---
 drivers/tty/amiserial.c  |2 +-
 drivers/tty/cyclades.c   |2 +-
 drivers/tty/hvc/hvc_irq.c|2 +-
 drivers/tty/hvc/hvcs.c   |2 +-
 drivers/tty/hvc/hvsi.c   |2 +-
 drivers/tty/isicom.c |2 +-
 drivers/tty/serial/68328serial.c |2 +-
 drivers/tty/serial/altera_jtaguart.c |2 +-
 drivers/tty/serial/altera_uart.c |2 +-
 drivers/tty/serial/bfin_sport_uart.c |2 +-
 drivers/tty/serial/bfin_uart.c   |8 
 drivers/tty/serial/crisv10.c |   18 +-
 drivers/tty/serial/icom.c|2 +-
 drivers/tty/serial/lantiq.c  |6 +++---
 drivers/tty/serial/mcf.c |2 +-
 drivers/tty/serial/mpc52xx_uart.c|2 +-
 drivers/tty/serial/serial_ks8695.c   |8 
 drivers/tty/serial/sh-sci.c  |2 +-
 drivers/tty/serial/sn_console.c  |2 +-
 19 files changed, 35 insertions(+), 35 deletions(-)

diff --git a/drivers/tty/amiserial.c b/drivers/tty/amiserial.c
index 6d43f55..b84c834 100644
--- a/drivers/tty/amiserial.c
+++ b/drivers/tty/amiserial.c
@@ -2017,7 +2017,7 @@ static int __init amiga_serial_probe(struct 
platform_device *pdev)
if (error)
goto fail_unregister;
 
-   error = request_irq(IRQ_AMIGA_RBF, ser_rx_int, IRQF_DISABLED,
+   error = request_irq(IRQ_AMIGA_RBF, ser_rx_int, 0,
"serial RX", state);
if (error)
goto fail_free_irq;
diff --git a/drivers/tty/cyclades.c b/drivers/tty/cyclades.c
index 5beef49..c9bf779 100644
--- a/drivers/tty/cyclades.c
+++ b/drivers/tty/cyclades.c
@@ -3367,7 +3367,7 @@ static int __init cy_detect_isa(void)
 
/* allocate IRQ */
if (request_irq(cy_isa_irq, cyy_interrupt,
-   IRQF_DISABLED, "Cyclom-Y", &cy_card[j])) {
+   0, "Cyclom-Y", &cy_card[j])) {
printk(KERN_ERR "Cyclom-Y/ISA found at 0x%lx, but "
"could not allocate IRQ#%d.\n",
(unsigned long)cy_isa_address, cy_isa_irq);
diff --git a/drivers/tty/hvc/hvc_irq.c b/drivers/tty/hvc/hvc_irq.c
index 2623e17..c9adb05 100644
--- a/drivers/tty/hvc/hvc_irq.c
+++ b/drivers/tty/hvc/hvc_irq.c
@@ -28,7 +28,7 @@ int notifier_add_irq(struct hvc_struct *hp, int irq)
hp->irq_requested = 0;
return 0;
}
-   rc = request_irq(irq, hvc_handle_interrupt, IRQF_DISABLED,
+   rc = request_irq(irq, hvc_handle_interrupt, 0,
   "hvc_console", hp);
if (!rc)
hp->irq_requested = 1;
diff --git a/drivers/tty/hvc/hvcs.c b/drivers/tty/hvc/hvcs.c
index e523773..55882b5 100644
--- a/drivers/tty/hvc/hvcs.c
+++ b/drivers/tty/hvc/hvcs.c
@@ -1057,7 +1057,7 @@ static int hvcs_enable_device(struct hvcs_struct *hvcsd, 
uint32_t unit_address,
 * the conn was registered and now.
 */
if (!(rc = request_irq(irq, &hvcs_handle_interrupt,
-   IRQF_DISABLED, "ibmhvcs", hvcsd))) {
+   0, "ibmhvcs", hvcsd))) {
/*
 * It is possible the vty-server was removed after the irq was
 * requested but before we have time to enable interrupts.
diff --git a/drivers/tty/hvc/hvsi.c b/drivers/tty/hvc/hvsi.c
index c94e2f5..cdfa3e0 100644
--- a/drivers/tty/hvc/hvsi.c
+++ b/drivers/tty/hvc/hvsi.c
@@ -1105,7 +1105,7 @@ static int __init hvsi_init(void)
struct hvsi_struct *hp = &hvsi_ports[i];
int ret = 1;
 
-   ret = request_irq(hp->virq, hvsi_interrupt, IRQF_DISABLED, 
"hvsi", hp);
+   ret = request_irq(hp->virq, hvsi_interrupt, 0, "hvsi", hp);
if (ret)
printk(KERN_ERR "HVSI: couldn't reserve irq 0x%x (error 
%i)\n",
hp->virq, ret);
diff --git a/drivers/tty/isicom.c b/drivers/tty/isicom.c
index db1cf9c..e5c295a 100644
--- a/drivers/tty/isicom.c
+++ b/drivers/tty/isicom.c
@@ -1598,7 +1598,7 @@ static int __devinit isicom_probe(struct pci_dev *pdev,
}
 
retval = request_irq(board->irq, isicom_interrupt,
-   IRQF_SHARED | IRQF_DISABLED, ISICOM_NAME, board);
+   IRQF_SHARED, ISICOM_NAME, board);
if (retval < 0) {
dev_err(&pdev->dev, "Could not install handler at Irq %d. "
"Card%d will be disabled.\n", board->irq, index 

[PATCH 45/57] powerpc/ps3: irq: Remove IRQF_DISABLED

2011-09-21 Thread Yong Zhang
Since commit [c58543c8: genirq: Run irq handlers with interrupts disabled],
We run all interrupt handlers with interrupts disabled
and we even check and yell when an interrupt handler
returns with interrupts enabled (see commit [b738a50a:
genirq: Warn when handler enables interrupts]).

So now this flag is a NOOP and can be removed.

Signed-off-by: Yong Zhang 
Acked-by: Geoff Levand 
---
 drivers/ps3/ps3-vuart.c   |2 +-
 drivers/ps3/ps3stor_lib.c |2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/ps3/ps3-vuart.c b/drivers/ps3/ps3-vuart.c
index d9fb729..fb73008 100644
--- a/drivers/ps3/ps3-vuart.c
+++ b/drivers/ps3/ps3-vuart.c
@@ -952,7 +952,7 @@ static int ps3_vuart_bus_interrupt_get(void)
}
 
result = request_irq(vuart_bus_priv.virq, ps3_vuart_irq_handler,
-   IRQF_DISABLED, "vuart", &vuart_bus_priv);
+   0, "vuart", &vuart_bus_priv);
 
if (result) {
pr_debug("%s:%d: request_irq failed (%d)\n",
diff --git a/drivers/ps3/ps3stor_lib.c b/drivers/ps3/ps3stor_lib.c
index cc328de..8c3f5ad 100644
--- a/drivers/ps3/ps3stor_lib.c
+++ b/drivers/ps3/ps3stor_lib.c
@@ -167,7 +167,7 @@ int ps3stor_setup(struct ps3_storage_device *dev, 
irq_handler_t handler)
goto fail_close_device;
}
 
-   error = request_irq(dev->irq, handler, IRQF_DISABLED,
+   error = request_irq(dev->irq, handler, 0,
dev->sbd.core.driver->name, dev);
if (error) {
dev_err(&dev->sbd.core, "%s:%u: request_irq failed %d\n",
-- 
1.7.4.1

___
Linuxppc-dev mailing list
Linuxppc-dev@lists.ozlabs.org
https://lists.ozlabs.org/listinfo/linuxppc-dev


[PATCH 15/57] powerpc: irq: Remove IRQF_DISABLED

2011-09-21 Thread Yong Zhang
Since commit [c58543c8: genirq: Run irq handlers with interrupts disabled],
We run all interrupt handlers with interrupts disabled
and we even check and yell when an interrupt handler
returns with interrupts enabled (see commit [b738a50a:
genirq: Warn when handler enables interrupts]).

So now this flag is a NOOP and can be removed.

Signed-off-by: Yong Zhang 
Acked-by: Arnd Bergmann 
---
 arch/powerpc/include/asm/floppy.h  |4 ++--
 arch/powerpc/include/asm/xics.h|4 ++--
 arch/powerpc/kernel/smp.c  |2 +-
 arch/powerpc/platforms/cell/beat.c |2 +-
 arch/powerpc/platforms/cell/celleb_scc_pciex.c |2 +-
 arch/powerpc/platforms/cell/iommu.c|3 +--
 arch/powerpc/platforms/cell/pmu.c  |2 +-
 arch/powerpc/platforms/cell/spu_base.c |9 +++--
 arch/powerpc/platforms/powermac/pic.c  |1 -
 arch/powerpc/platforms/powermac/smp.c  |4 ++--
 arch/powerpc/platforms/ps3/device-init.c   |2 +-
 arch/powerpc/sysdev/mpic.c |2 --
 arch/powerpc/sysdev/ppc4xx_soc.c   |2 +-
 arch/powerpc/sysdev/xics/xics-common.c |5 ++---
 14 files changed, 18 insertions(+), 26 deletions(-)

diff --git a/arch/powerpc/include/asm/floppy.h 
b/arch/powerpc/include/asm/floppy.h
index 24bd34c..936a904 100644
--- a/arch/powerpc/include/asm/floppy.h
+++ b/arch/powerpc/include/asm/floppy.h
@@ -108,10 +108,10 @@ static int fd_request_irq(void)
 {
if (can_use_virtual_dma)
return request_irq(FLOPPY_IRQ, floppy_hardint,
-  IRQF_DISABLED, "floppy", NULL);
+  0, "floppy", NULL);
else
return request_irq(FLOPPY_IRQ, floppy_interrupt,
-  IRQF_DISABLED, "floppy", NULL);
+  0, "floppy", NULL);
 }
 
 static int vdma_dma_setup(char *addr, unsigned long size, int mode, int io)
diff --git a/arch/powerpc/include/asm/xics.h b/arch/powerpc/include/asm/xics.h
index b183a40..c78e58a 100644
--- a/arch/powerpc/include/asm/xics.h
+++ b/arch/powerpc/include/asm/xics.h
@@ -15,8 +15,8 @@
 #defineDEFAULT_PRIORITY5
 
 /*
- * Mark IPIs as higher priority so we can take them inside interrupts that
- * arent marked IRQF_DISABLED
+ * Mark IPIs as higher priority so we can take them inside interrupts
+ * FIXME: still true now?
  */
 #define IPI_PRIORITY   4
 
diff --git a/arch/powerpc/kernel/smp.c b/arch/powerpc/kernel/smp.c
index 37f4c98..e1195a2 100644
--- a/arch/powerpc/kernel/smp.c
+++ b/arch/powerpc/kernel/smp.c
@@ -170,7 +170,7 @@ int smp_request_message_ipi(int virq, int msg)
return 1;
}
 #endif
-   err = request_irq(virq, smp_ipi_action[msg], IRQF_DISABLED|IRQF_PERCPU,
+   err = request_irq(virq, smp_ipi_action[msg], IRQF_PERCPU,
  smp_ipi_name[msg], 0);
WARN(err < 0, "unable to request_irq %d for %s (rc %d)\n",
virq, smp_ipi_name[msg], err);
diff --git a/arch/powerpc/platforms/cell/beat.c 
b/arch/powerpc/platforms/cell/beat.c
index 232fc38..852592b 100644
--- a/arch/powerpc/platforms/cell/beat.c
+++ b/arch/powerpc/platforms/cell/beat.c
@@ -230,7 +230,7 @@ static int __init beat_register_event(void)
}
ev->virq = virq;
 
-   rc = request_irq(virq, ev->handler, IRQF_DISABLED,
+   rc = request_irq(virq, ev->handler, 0,
  ev->typecode, NULL);
if (rc != 0) {
printk(KERN_ERR "Beat: failed to request virtual IRQ"
diff --git a/arch/powerpc/platforms/cell/celleb_scc_pciex.c 
b/arch/powerpc/platforms/cell/celleb_scc_pciex.c
index ae790ac..14be2bd 100644
--- a/arch/powerpc/platforms/cell/celleb_scc_pciex.c
+++ b/arch/powerpc/platforms/cell/celleb_scc_pciex.c
@@ -514,7 +514,7 @@ static __init int celleb_setup_pciex(struct device_node 
*node,
virq = irq_create_of_mapping(oirq.controller, oirq.specifier,
 oirq.size);
if (request_irq(virq, pciex_handle_internal_irq,
-   IRQF_DISABLED, "pciex", (void *)phb)) {
+   0, "pciex", (void *)phb)) {
pr_err("PCIEXC:Failed to request irq\n");
goto error;
}
diff --git a/arch/powerpc/platforms/cell/iommu.c 
b/arch/powerpc/platforms/cell/iommu.c
index 26a0671..afdcd5b 100644
--- a/arch/powerpc/platforms/cell/iommu.c
+++ b/arch/powerpc/platforms/cell/iommu.c
@@ -412,8 +412,7 @@ static void cell_iommu_enable_hardware(struct cbe_iommu 
*iommu)
IIC_IRQ_IOEX_ATI | (iommu->nid << IIC_IRQ_NODE_SHIFT));
BUG_ON(virq == NO_IRQ);
 
-   ret = request_irq(virq, ioc_interrupt, IRQF_DISABLED,
-   iommu->name, iommu);
+   ret = request_irq(virq, ioc_interrupt, 0, iommu->name, io

Re: [PATCH] fsl-diu-fb: remove the ioctl interface

2011-09-21 Thread Anatolij Gustschin
On Wed, 21 Sep 2011 02:10:42 +
Tabi Timur-B04825  wrote:
...
> The definitions of MFB_SET_PIXFMT and MFB_GET_PIXFMT are wrong:
> 
> #define MFB_SET_PIXFMT  0x80014d08
> #define MFB_GET_PIXFMT  0x40014d08
> 
> The "01" is the size.  However, these ioctls take a __u32 as a parameter.
> 
> This means that I have to fix the definitions to this:
> 
> #define MFB_SET_PIXFMT  _IOW('M', 8, __u32)
> #define MFB_GET_PIXFMT  _IOR('M', 8, __u32)
> 
> This will change the values and break binary compatibility with your
> applications.  Are you okay with that?

yes. the app will be fixed for updated kernel.

> > Other ioctls can be removed. I'm not sure if someone
> > uses FBIOGET_GWINFO. If there are no objections from
> > other people, it can also be dropped.
> 
> I'm going to remove FBIOGET_GWINFO because no one is using it, and the
> ioctl value is malformed (it doesn't define a direction or size).

okay. 

Thanks,
Anatolij
___
Linuxppc-dev mailing list
Linuxppc-dev@lists.ozlabs.org
https://lists.ozlabs.org/listinfo/linuxppc-dev