Re: [PATCH v2 0/9] DMA engine cookie handling cleanups

2012-03-07 Thread Linus Walleij
On Tue, Mar 6, 2012 at 11:33 PM, Russell King - ARM Linux
 wrote:

> This patch series cleans up the handling of cookies in DMA engine drivers.
> This is done by providing a set of inline library functions for common
> tasks:

I just applied the latest patches right off and tested with some stressy
MMC operations on the U300 and Ux500. (I had some minor hell
since patch 8/9 and 9/9 were uuencoded but managed to fix it...)

It works like a charm!

The patches look good too.

Tested-by: Linus Walleij 
Reviewed-by: Linus Walleij 

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


RE: [PATCH 1/9] pci_ids: Add device ID for IBM PCI-X bridge

2012-03-07 Thread Zhao Chenhui-B35336
> On Mar 6, 2012, at 3:05 AM, Zhao Chenhui wrote:
> 
> > Signed-off-by: Zhao Chenhui 
> > ---
> > include/linux/pci_ids.h |1 +
> > 1 files changed, 1 insertions(+), 0 deletions(-)
> 
> Just merge this with the 2nd patch that actually uses the ID.
> 
> - k

Ok. I put it in the file mpc85xx_cds.c.

-Chenhui

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


Re: [PATCH v2 0/9] DMA engine cookie handling cleanups

2012-03-07 Thread Russell King - ARM Linux
On Wed, Mar 07, 2012 at 09:33:49AM +0100, Linus Walleij wrote:
> On Tue, Mar 6, 2012 at 11:33 PM, Russell King - ARM Linux
>  wrote:
> 
> > This patch series cleans up the handling of cookies in DMA engine drivers.
> > This is done by providing a set of inline library functions for common
> > tasks:
> 
> I just applied the latest patches right off and tested with some stressy
> MMC operations on the U300 and Ux500. (I had some minor hell
> since patch 8/9 and 9/9 were uuencoded but managed to fix it...)

That'll be some MTA deciding to change the encoding, probably because some
MTA spotted UTF-8 characters in the description and decided to convert to
base64.
___
Linuxppc-dev mailing list
Linuxppc-dev@lists.ozlabs.org
https://lists.ozlabs.org/listinfo/linuxppc-dev


RE: [PATCH 2/9] powerpc/mpc85xxcds: Fix PCI I/O space resource of PCI bridge

2012-03-07 Thread Zhao Chenhui-B35336
> > diff --git a/arch/powerpc/platforms/85xx/mpc85xx_cds.c 
> > b/arch/powerpc/platforms/85xx/mpc85xx_cds.c
> > index 40f03da..c009c5b 100644
> > --- a/arch/powerpc/platforms/85xx/mpc85xx_cds.c
> > +++ b/arch/powerpc/platforms/85xx/mpc85xx_cds.c
> > @@ -3,7 +3,7 @@
> >  *
> >  * Maintained by Kumar Gala (see MAINTAINERS for contact information)
> >  *
> > - * Copyright 2005 Freescale Semiconductor Inc.
> > + * Copyright 2005, 2011-2012 Freescale Semiconductor Inc.
> >  *
> >  * This program is free software; you can redistribute  it and/or modify it
> >  * under  the terms of  the GNU General  Public License as published by the
> > @@ -158,6 +158,31 @@ DECLARE_PCI_FIXUP_EARLY(0x1957, 0x3fff, 
> > skip_fake_bridge);
> > DECLARE_PCI_FIXUP_EARLY(0x3fff, 0x1957, skip_fake_bridge);
> > DECLARE_PCI_FIXUP_EARLY(0xff3f, 0x5719, skip_fake_bridge);
> >
> > +/*
> > + * Fix Tsi310 PCI-X bridge resource.
> > + * Force the bridge to open a window from 0x-0x1fff in PCI I/O space.
> > + * This allows legacy I/O(i8259, etc) on the VIA southbridge to be 
> > accessed.
> > + */
> 
> This comment and the code don't make sense.  Why is the bridge described as 
> Tsi310 in comments but the
> vendor ID is IBM ?

This chip is from IBM originally, and bought by IDT.
The vendor ID is IBM, but the part number is Tsi310(IDT).

-Chenhui

> 
> > +void mpc85xx_cds_fixup_bus(struct pci_bus *bus)
> > +{
> > +   struct pci_dev *dev = bus->self;
> > +   struct resource *res = bus->resource[0];
> > +
> > +   if (dev != NULL &&
> > +   dev->vendor == PCI_VENDOR_ID_IBM &&
> > +   dev->device == PCI_DEVICE_ID_IBM_PCIX_BRIDGE) {
> > +   if (res) {
> > +   res->start = 0;
> > +   res->end   = 0x1fff;
> > +   res->flags = IORESOURCE_IO;
> > +   pr_info("mpc85xx_cds: PCI bridge resource fixup 
> > applied\n");
> > +   pr_info("mpc85xx_cds: %pR\n", res);
> > +   }
> > +   }
> > +
> > +   fsl_pcibios_fixup_bus(bus);
> > +}

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


Re: [PATCH 2/9] powerpc/mpc85xxcds: Fix PCI I/O space resource of PCI bridge

2012-03-07 Thread Kumar Gala

On Mar 7, 2012, at 3:31 AM, Zhao Chenhui-B35336 wrote:

>>> diff --git a/arch/powerpc/platforms/85xx/mpc85xx_cds.c 
>>> b/arch/powerpc/platforms/85xx/mpc85xx_cds.c
>>> index 40f03da..c009c5b 100644
>>> --- a/arch/powerpc/platforms/85xx/mpc85xx_cds.c
>>> +++ b/arch/powerpc/platforms/85xx/mpc85xx_cds.c
>>> @@ -3,7 +3,7 @@
>>> *
>>> * Maintained by Kumar Gala (see MAINTAINERS for contact information)
>>> *
>>> - * Copyright 2005 Freescale Semiconductor Inc.
>>> + * Copyright 2005, 2011-2012 Freescale Semiconductor Inc.
>>> *
>>> * This program is free software; you can redistribute  it and/or modify it
>>> * under  the terms of  the GNU General  Public License as published by the
>>> @@ -158,6 +158,31 @@ DECLARE_PCI_FIXUP_EARLY(0x1957, 0x3fff, 
>>> skip_fake_bridge);
>>> DECLARE_PCI_FIXUP_EARLY(0x3fff, 0x1957, skip_fake_bridge);
>>> DECLARE_PCI_FIXUP_EARLY(0xff3f, 0x5719, skip_fake_bridge);
>>> 
>>> +/*
>>> + * Fix Tsi310 PCI-X bridge resource.
>>> + * Force the bridge to open a window from 0x-0x1fff in PCI I/O space.
>>> + * This allows legacy I/O(i8259, etc) on the VIA southbridge to be 
>>> accessed.
>>> + */
>> 
>> This comment and the code don't make sense.  Why is the bridge described as 
>> Tsi310 in comments but the
>> vendor ID is IBM ?
> 
> This chip is from IBM originally, and bought by IDT.
> The vendor ID is IBM, but the part number is Tsi310(IDT).
> 

Ok, we should probably call it PCI_DEVICE_ID_..._TSI310

- k

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


Re: [PATCH] spufs raises two exceptions

2012-03-07 Thread Arnd Bergmann
On Wednesday 07 March 2012, Benjamin Herrenschmidt wrote:
> On Wed, 2012-03-07 at 14:49 +1100, Benjamin Herrenschmidt wrote:
> > On Tue, 2012-03-06 at 10:26 +0100, masterzorag wrote:
> > > I'm running my test program, it uses all available spus to compute via 
> > > OpenCL
> > > kernel 3.2.5 on a ps3
> > > even on testing spu directly, it crashes
> > 
> > I think the patch is not 100% right yet. Looking at the code, we
> > have a real mess of who gets to clean what up here. This is an
> > attempt at sorting things by having the mutex and dentry dropped
> > in spufs_create() always. Can you give it a spin (untested):
> > 
> > Al, I'm not familiar with the vfs, can you take a quick look ?
> 
> Better with the actual patch :-)
> 
> powerpc/cell: Fix locking in spufs_create()
> 
> The error path in spufs_create() could cause double unlocks
> among other horrors. Clean it up.
> 
> Signed-off-by: Benjamin Herrenschmidt 
> Reported-by: masterzo...@gmail.com
> 
> diff --git a/arch/powerpc/platforms/cell/spufs/inode.c 
> b/arch/powerpc/platforms/cell/spufs/inode.c
> index d4a094c..63b4e43 100644
> --- a/arch/powerpc/platforms/cell/spufs/inode.c
> +++ b/arch/powerpc/platforms/cell/spufs/inode.c
> @@ -454,19 +454,16 @@ spufs_create_context(struct inode *inode, struct dentry 
> *dentry,
>   struct spu_gang *gang;
>   struct spu_context *neighbor;
>  
> - ret = -EPERM;
>   if ((flags & SPU_CREATE_NOSCHED) &&
> - !capable(CAP_SYS_NICE))
> - goto out_unlock;
> + !capable(CAP_SYa_NICE))

^typo

> + return -EPERM;
>  
> - ret = -EINVAL;
>   if ((flags & (SPU_CREATE_NOSCHED | SPU_CREATE_ISOLATE))
>   == SPU_CREATE_ISOLATE)
> - goto out_unlock;
> + return -EINVAL;
>  
> - ret = -ENODEV;
>   if ((flags & SPU_CREATE_ISOLATE) && !isolated_loader)
> - goto out_unlock;
> + return -ENODEV;
>  
>   gang = NULL;
>   neighbor = NULL;

This mostly changes coding style, pointlessly.

> @@ -512,10 +509,6 @@ spufs_create_context(struct inode *inode, struct dentry 
> *dentry,
>  out_aff_unlock:
>   if (affinity)
>   mutex_unlock(&gang->aff_mutex);
> -out_unlock:
> - mutex_unlock(&inode->i_mutex);
> -out:
> - dput(dentry);
>   return ret;
>  }

The original intention of this was to always unlock in the error case. It
seems that Al changed this in 1ba10681 "switch do_spufs_create() to
user_path_create(), fix double-unlock" to never unlock early but always
unlock in do_spu_create, fixing a different bug, but it looks like
he forgot this one in the process.

The reason why we originally had the unlock in the leaf functions is to
avoid a problem with spu_forget(), which had to be called without
the i_mutex held to avoid deadlocks.

> @@ -600,10 +591,6 @@ static int spufs_create_gang(struct inode *inode,
>   int err = simple_rmdir(inode, dentry);
>   WARN_ON(err);
>   }
> -
> -out:
> - mutex_unlock(&inode->i_mutex);
> - dput(dentry);
>   return ret;
>  }

Right, this obviously goes together with the one above,

> @@ -613,22 +600,21 @@ static struct file_system_type spufs_type;
>  long spufs_create(struct path *path, struct dentry *dentry,
>   unsigned int flags, umode_t mode, struct file *filp)
>  {
> - int ret;
> + int ret = -EINVAL;
>  
> - ret = -EINVAL;
>   /* check if we are on spufs */
>   if (path->dentry->d_sb->s_type != &spufs_type)
> - goto out;
> + goto fail;
>  
>   /* don't accept undefined flags */
>   if (flags & (~SPU_CREATE_FLAG_ALL))
> - goto out;
> + goto fail;
>  
>   /* only threads can be underneath a gang */
>   if (path->dentry != path->dentry->d_sb->s_root) {
>   if ((flags & SPU_CREATE_GANG) ||
>   !SPUFS_I(path->dentry->d_inode)->i_gang)
> - goto out;
> + goto fail;
>   }
>  
>   mode &= ~current_umask();

These just change coding style, and not in a helpful way.

> @@ -640,12 +626,17 @@ long spufs_create(struct path *path, struct dentry 
> *dentry,
>   ret = spufs_create_context(path->dentry->d_inode,
>   dentry, path->mnt, flags, mode,
>   filp);
> - if (ret >= 0)
> + if (ret >= 0) {
> + /* We drop these before fsnotify */
> + mutex_unlock(&inode->i_mutex);
> + dput(dentry);
>   fsnotify_mkdir(path->dentry->d_inode, dentry);
> - return ret;
>  
> -out:
> - mutex_unlock(&path->dentry->d_inode->i_mutex);
> + return ret;
> + }
> + fail:
> + mutex_unlock(&inode->i_mutex);
> + dput(dentry);
>   return ret;
>  }
>  
> diff --git a/arch/powerpc/platforms/cell/spufs/syscalls.c 
> b/arch/powerpc/platforms/cell/spufs/syscalls.c
> index 8591bb6..1a65ef2 100644
> ---

Re: [PATCH] powerpc/srio: Fix the compile errors when building with 64bit

2012-03-07 Thread Liu Gang
Hi, Kumar,

On Tue, 2012-03-06 at 11:46 -0600, Kumar Gala wrote:
> How about a struct instead:
> 
> struct rmu_dmsg {
>   u16 dummy;
>   u16 tid;
>   u16 sid;
>   u16 info;
> };
> 
>   struct rmu_dmsg *dmsg = fsl_dbell->dbell_ring.virt + 
> (in_be32(&fsl_dbell->dbell_regs->dqdpar) & 0xfff);
> 
> Than you can git rid of the DBELL_* macros.

Yes, this can really git rid of the DBELL_* macros and some other code.
I'll update the patch based on your comments.
Thanks a lot.

Liu Gang


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


[PATCH v2] powerpc/srio: Fix the compile errors when building with 64bit

2012-03-07 Thread Liu Gang
For the file "arch/powerpc/sysdev/fsl_rmu.c", there will be some compile
errors while using the corenet64_smp_defconfig:

.../fsl_rmu.c:315: error: cast from pointer to integer of different size
.../fsl_rmu.c:320: error: cast to pointer from integer of different size
.../fsl_rmu.c:320: error: cast to pointer from integer of different size
.../fsl_rmu.c:320: error: cast to pointer from integer of different size
.../fsl_rmu.c:330: error: cast to pointer from integer of different size
.../fsl_rmu.c:332: error: cast to pointer from integer of different size
.../fsl_rmu.c:339: error: cast to pointer from integer of different size
.../fsl_rmu.c:340: error: cast to pointer from integer of different size
.../fsl_rmu.c:341: error: cast to pointer from integer of different size
.../fsl_rmu.c:348: error: cast to pointer from integer of different size
.../fsl_rmu.c:348: error: cast to pointer from integer of different size
.../fsl_rmu.c:348: error: cast to pointer from integer of different size
.../fsl_rmu.c:659: error: cast from pointer to integer of different size
.../fsl_rmu.c:659: error: format '%8.8x' expects type 'unsigned int',
   but argument 5 has type 'size_t'
.../fsl_rmu.c:985: error: cast from pointer to integer of different size
.../fsl_rmu.c:997: error: cast to pointer from integer of different size

Rewrote the corresponding code with the support of 64bit building.

Signed-off-by: Liu Gang 
Signed-off-by: Shaohui Xie 
Reported-by: Paul Gortmaker 
---
Changes in v2:
 - Add the struct "rio_dbell_msg" to instead of some DBELL_* macros.
 - Change the "virt_buf" to be "void *" type.
 - Change "Signed-off-by" to "Reported-by" for Paul.

 arch/powerpc/sysdev/fsl_rmu.c |   43 +---
 1 files changed, 23 insertions(+), 20 deletions(-)

diff --git a/arch/powerpc/sysdev/fsl_rmu.c b/arch/powerpc/sysdev/fsl_rmu.c
index 1548578..1bba6d1 100644
--- a/arch/powerpc/sysdev/fsl_rmu.c
+++ b/arch/powerpc/sysdev/fsl_rmu.c
@@ -100,14 +100,8 @@
 #define DOORBELL_DSR_TE0x0080
 #define DOORBELL_DSR_QFI   0x0010
 #define DOORBELL_DSR_DIQI  0x0001
-#define DOORBELL_TID_OFFSET0x02
-#define DOORBELL_SID_OFFSET0x04
-#define DOORBELL_INFO_OFFSET   0x06
 
 #define DOORBELL_MESSAGE_SIZE  0x08
-#define DBELL_SID(x)   (*(u16 *)(x + DOORBELL_SID_OFFSET))
-#define DBELL_TID(x)   (*(u16 *)(x + DOORBELL_TID_OFFSET))
-#define DBELL_INF(x)   (*(u16 *)(x + DOORBELL_INFO_OFFSET))
 
 struct rio_msg_regs {
u32 omr;
@@ -193,6 +187,13 @@ struct fsl_rmu {
int rxirq;
 };
 
+struct rio_dbell_msg {
+   u16 pad1;
+   u16 tid;
+   u16 sid;
+   u16 info;
+};
+
 /**
  * fsl_rio_tx_handler - MPC85xx outbound message interrupt handler
  * @irq: Linux interrupt number
@@ -311,8 +312,8 @@ fsl_rio_dbell_handler(int irq, void *dev_instance)
 
/* XXX Need to check/dispatch until queue empty */
if (dsr & DOORBELL_DSR_DIQI) {
-   u32 dmsg =
-   (u32) fsl_dbell->dbell_ring.virt +
+   struct rio_dbell_msg *dmsg =
+   fsl_dbell->dbell_ring.virt +
(in_be32(&fsl_dbell->dbell_regs->dqdpar) & 0xfff);
struct rio_dbell *dbell;
int found = 0;
@@ -320,25 +321,25 @@ fsl_rio_dbell_handler(int irq, void *dev_instance)
pr_debug
("RIO: processing doorbell,"
" sid %2.2x tid %2.2x info %4.4x\n",
-   DBELL_SID(dmsg), DBELL_TID(dmsg), DBELL_INF(dmsg));
+   dmsg->sid, dmsg->tid, dmsg->info);
 
for (i = 0; i < MAX_PORT_NUM; i++) {
if (fsl_dbell->mport[i]) {
list_for_each_entry(dbell,
&fsl_dbell->mport[i]->dbells, node) {
if ((dbell->res->start
-   <= DBELL_INF(dmsg))
+   <= dmsg->info)
&& (dbell->res->end
-   >= DBELL_INF(dmsg))) {
+   >= dmsg->info)) {
found = 1;
break;
}
}
if (found && dbell->dinb) {
dbell->dinb(fsl_dbell->mport[i],
-   dbell->dev_id, DBELL_SID(dmsg),
-   DBELL_TID(dmsg),
-   DBELL_INF(dmsg));
+   dbell->dev_id, dmsg->sid,
+   dmsg->tid,
+ 

RE: [PATCH v2] powerpc/srio: Fix the compile errors when building with 64bit

2012-03-07 Thread David Laight
> diff --git a/arch/powerpc/sysdev/fsl_rmu.c
b/arch/powerpc/sysdev/fsl_rmu.c
> index 1548578..1bba6d1 100644
> --- a/arch/powerpc/sysdev/fsl_rmu.c
> +++ b/arch/powerpc/sysdev/fsl_rmu.c

> @@ -657,7 +658,8 @@ fsl_add_outb_message(struct rio_mport 
> *mport, struct rio_dev *rdev, int mbox,
>   int ret = 0;
>  
>   pr_debug("RIO: fsl_add_outb_message(): destid %4.4x mbox %d
buffer " \
> -  "%8.8x len %8.8x\n", rdev->destid, mbox, (int)buffer,
len);
> +  "%8.8lx len %8.8zx\n", rdev->destid, mbox,
> + (unsigned long)buffer, len);

Should 'buffer' be printed with %p ??

David


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


Re: [PATCH 1/2] powerpc/e500: make load_up_spe a normal fuction

2012-03-07 Thread Alexander Graf

On 02/28/2012 08:09 AM, Yin Olivia-R63875 wrote:

Hi Scott,

This had been reviewed before and accepted by internal tree.
http://linux.freescale.net/patchwork/patch/11100/
http://git.am.freescale.net/gitolite/gitweb.cgi/sdk/kvm.git/commit/?h=for-sdk1.2&id=c5088844dc665dbdae4fa51b8d58dc203bacc17e

I didn't change anything except the line.
I just commit to external kvm-ppc mailing list. Should I add my own 
Signed-off-by?


Yes, if you just take a patch from someone else and direct it to another 
tree, you keep the From: line (git cherry-pick or git am should do that 
automatically for you) and add your own SOB-line (git am -s can do that 
for example).


Since you're also supposed to change the description, please note that 
between Yu's SOB line and your SOB line with something like


Signed-off-by: Liu Yu
[olivia: change description]
Signed-off-by: Olivia Yin



Alex

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


Re: [PATCH v2 1/2] powerpc/e500: make load_up_spe a normal fuction

2012-03-07 Thread Alexander Graf

On 03/01/2012 02:20 AM, Olivia Yin wrote:

From: Liu Yu

So that we can call it when improving SPE switch like book3e did for fp switch.


Timur / Scott, can you please (n)ack this one?

Alex


Signed-off-by: Liu Yu
Signed-off-by: Olivia Yin
---
v2: add Signed-off-by

  arch/powerpc/kernel/head_fsl_booke.S |   23 ++-
  1 files changed, 6 insertions(+), 17 deletions(-)

diff --git a/arch/powerpc/kernel/head_fsl_booke.S 
b/arch/powerpc/kernel/head_fsl_booke.S
index d5d78c4..c96e025 100644
--- a/arch/powerpc/kernel/head_fsl_booke.S
+++ b/arch/powerpc/kernel/head_fsl_booke.S
@@ -539,8 +539,10 @@ interrupt_base:
/* SPE Unavailable */
START_EXCEPTION(SPEUnavailable)
NORMAL_EXCEPTION_PROLOG
-   bne load_up_spe
-   addir3,r1,STACK_FRAME_OVERHEAD
+   beq 1f
+   bl  load_up_spe
+   b   fast_exception_return
+1: addir3,r1,STACK_FRAME_OVERHEAD
EXC_XFER_EE_LITE(0x2010, KernelSPE)
  #else
EXCEPTION(0x2020, SPEUnavailable, unknown_exception, EXC_XFER_EE)
@@ -743,7 +745,7 @@ tlb_write_entry:
  /* Note that the SPE support is closely modeled after the AltiVec
   * support.  Changes to one are likely to be applicable to the
   * other!  */
-load_up_spe:
+_GLOBAL(load_up_spe)
  /*
   * Disable SPE for the task which had SPE previously,
   * and save its SPE registers in its thread_struct.
@@ -791,20 +793,7 @@ load_up_spe:
subir4,r5,THREAD
stw r4,last_task_used_spe@l(r3)
  #endif /* !CONFIG_SMP */
-   /* restore registers and return */
-2: REST_4GPRS(3, r11)
-   lwz r10,_CCR(r11)
-   REST_GPR(1, r11)
-   mtcrr10
-   lwz r10,_LINK(r11)
-   mtlrr10
-   REST_GPR(10, r11)
-   mtspr   SPRN_SRR1,r9
-   mtspr   SPRN_SRR0,r12
-   REST_GPR(9, r11)
-   REST_GPR(12, r11)
-   lwz r11,GPR11(r11)
-   rfi
+   blr

  /*
   * SPE unavailable trap from kernel - print a message, but let


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


Re: [PATCH v2 0/9] DMA engine cookie handling cleanups

2012-03-07 Thread Vinod Koul
On Tue, 2012-03-06 at 22:33 +, Russell King - ARM Linux wrote:
> [v2 - more or less same description.  Including lakml in cc for the full
> set]
> 
> This patch series cleans up the handling of cookies in DMA engine drivers.
> This is done by providing a set of inline library functions for common
> tasks:
> 
> - moving the 'last completed cookie' into struct dma_chan - everyone
>   has this in their driver private channel data structure
> 
> - consolidate allocation of cookies to DMA descriptors
> 
> - common way to update 'last completed cookie' value
> 
> - standard way to implement tx_status callback and update the residue
> 
> - consolidate initialization of cookies
> 
> - update implementations differing from the majority of DMA engine drivers
>   to behave the same as the majority implementation in respect of cookies
> 
> What this means is that we get to the point where all DMA engine drivers
> will hand out cookie value '2' as the first, and incrementing cookie
> values up to INT_MAX, returning to cookie '1' as the next cookie.
> 
> Think of this patch series as round 1...  I am hoping over time that more
> code can be consolidated between the DMA engine drivers and end up with a
> consistent way to handle various common themes in DMA engine hardware
> (like physical channel<->peripheral request signal selection.)
Thanks Russell,

I have tested this on atom today, and as expected works flawlessly :)
After all acks, I can merge or these can go thru your tree with my Ack.
Either way is okay.

I applied the v2 on a branch and also rebased on top of slave-dma.next.
There were few conflicts in imx-dma.c. Sacha, Javier, pls see that merge
is right.

This branch (rmk_cookie_fixes2_rebased) is not yet pushed, as I am not
able to connect to infradead.org, should be done when server is back.



-- 
~Vinod

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


Re: [PATCH v2] powerpc/dts: fix the compatible string of sec 4.0

2012-03-07 Thread Haiying Wang
On Wed, 2012-03-07 at 13:20 +0800, Shengzhou Liu wrote:
> From: Liu Shuo 
> 
> Fix the compatible string of sec 4.0 to match with CAMM driver according
%s/CAMM/CAAM.

Haiying


> to Documentation/devicetree/bindings/crypto/fsl-sec4.txt
> 
> Signed-off-by: Liu Shuo 
> Signed-off-by: Shengzhou Liu 
> ---
> v2: refine description.
> 
>  arch/powerpc/boot/dts/fsl/pq3-sec4.4-0.dtsi |   10 +-
>  1 files changed, 5 insertions(+), 5 deletions(-)
> 
> diff --git a/arch/powerpc/boot/dts/fsl/pq3-sec4.4-0.dtsi 
> b/arch/powerpc/boot/dts/fsl/pq3-sec4.4-0.dtsi
> index bf957a7..d4c9d5d 100644
> --- a/arch/powerpc/boot/dts/fsl/pq3-sec4.4-0.dtsi
> +++ b/arch/powerpc/boot/dts/fsl/pq3-sec4.4-0.dtsi
> @@ -33,32 +33,32 @@
>   */
>  
>  crypto@3 {
> - compatible = "fsl,sec4.4", "fsl,sec4.0";
> + compatible = "fsl,sec-v4.4", "fsl,sec-v4.0";
>   #address-cells = <1>;
>   #size-cells = <1>;
>   reg  = <0x3 0x1>;
>   interrupts   = <58 2 0 0>;
>  
>   sec_jr0: jr@1000 {
> - compatible = "fsl,sec4.4-job-ring", "fsl,sec4.0-job-ring";
> + compatible = "fsl,sec-v4.4-job-ring", "fsl,sec-v4.0-job-ring";
>   reg= <0x1000 0x1000>;
>   interrupts   = <45 2 0 0>;
>   };
>  
>   sec_jr1: jr@2000 {
> - compatible = "fsl,sec4.4-job-ring", "fsl,sec4.0-job-ring";
> + compatible = "fsl,sec-v4.4-job-ring", "fsl,sec-v4.0-job-ring";
>   reg= <0x2000 0x1000>;
>   interrupts   = <45 2 0 0>;
>   };
>  
>   sec_jr2: jr@3000 {
> - compatible = "fsl,sec4.4-job-ring", "fsl,sec4.0-job-ring";
> + compatible = "fsl,sec-v4.4-job-ring", "fsl,sec-v4.0-job-ring";
>   reg= <0x3000 0x1000>;
>   interrupts   = <45 2 0 0>;
>   };
>  
>   sec_jr3: jr@4000 {
> - compatible = "fsl,sec4.4-job-ring", "fsl,sec4.0-job-ring";
> + compatible = "fsl,sec-v4.4-job-ring", "fsl,sec-v4.0-job-ring";
>   reg= <0x4000 0x1000>;
>   interrupts   = <45 2 0 0>;
>   };



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


Re: [PATCH 6/9] powerpc/mpc8548cds: Add FPGA node to dts

2012-03-07 Thread Tabi Timur-B04825
On Tue, Mar 6, 2012 at 3:06 AM, Zhao Chenhui  wrote:
> From: chenhui zhao 
>
> Remove FPGA(CADMUS) macros in code. Move it to dts.
>
> Signed-off-by: Zhao Chenhui 
> Signed-off-by: Li Yang 
> ---

Acked-by: Timur Tabi 


-- 
Timur Tabi
Linux kernel developer at Freescale
___
Linuxppc-dev mailing list
Linuxppc-dev@lists.ozlabs.org
https://lists.ozlabs.org/listinfo/linuxppc-dev


Re: [PATCH 6/9] powerpc/mpc8548cds: Add FPGA node to dts

2012-03-07 Thread Timur Tabi
On Tue, Mar 6, 2012 at 3:06 AM, Zhao Chenhui 
wrote:
> From: chenhui zhao 
>
> Remove FPGA(CADMUS) macros in code. Move it to dts.
>
> Signed-off-by: Zhao Chenhui 
> Signed-off-by: Li Yang 
> ---

Acked-by: Timur Tabi 


-- 
Timur Tabi
Linux kernel developer at Freescale

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


Re: [PATCH v2 1/2] powerpc/e500: make load_up_spe a normal fuction

2012-03-07 Thread Scott Wood
On 03/07/2012 07:56 AM, Alexander Graf wrote:
> On 03/01/2012 02:20 AM, Olivia Yin wrote:
>> From: Liu Yu
>>
>> So that we can call it when improving SPE switch like book3e did for
>> fp switch.
> 
> Timur / Scott, can you please (n)ack this one?

ACK, though as it touches non-KVM code it'd be nice to get an ack from
Kumar.

-Scott

> 
> Alex
> 
>> Signed-off-by: Liu Yu
>> Signed-off-by: Olivia Yin
>> ---
>> v2: add Signed-off-by
>>
>>   arch/powerpc/kernel/head_fsl_booke.S |   23 ++-
>>   1 files changed, 6 insertions(+), 17 deletions(-)
>>
>> diff --git a/arch/powerpc/kernel/head_fsl_booke.S
>> b/arch/powerpc/kernel/head_fsl_booke.S
>> index d5d78c4..c96e025 100644
>> --- a/arch/powerpc/kernel/head_fsl_booke.S
>> +++ b/arch/powerpc/kernel/head_fsl_booke.S
>> @@ -539,8 +539,10 @@ interrupt_base:
>>   /* SPE Unavailable */
>>   START_EXCEPTION(SPEUnavailable)
>>   NORMAL_EXCEPTION_PROLOG
>> -bneload_up_spe
>> -addir3,r1,STACK_FRAME_OVERHEAD
>> +beq1f
>> +blload_up_spe
>> +bfast_exception_return
>> +1:addir3,r1,STACK_FRAME_OVERHEAD
>>   EXC_XFER_EE_LITE(0x2010, KernelSPE)
>>   #else
>>   EXCEPTION(0x2020, SPEUnavailable, unknown_exception, EXC_XFER_EE)
>> @@ -743,7 +745,7 @@ tlb_write_entry:
>>   /* Note that the SPE support is closely modeled after the AltiVec
>>* support.  Changes to one are likely to be applicable to the
>>* other!  */
>> -load_up_spe:
>> +_GLOBAL(load_up_spe)
>>   /*
>>* Disable SPE for the task which had SPE previously,
>>* and save its SPE registers in its thread_struct.
>> @@ -791,20 +793,7 @@ load_up_spe:
>>   subir4,r5,THREAD
>>   stwr4,last_task_used_spe@l(r3)
>>   #endif /* !CONFIG_SMP */
>> -/* restore registers and return */
>> -2:REST_4GPRS(3, r11)
>> -lwzr10,_CCR(r11)
>> -REST_GPR(1, r11)
>> -mtcrr10
>> -lwzr10,_LINK(r11)
>> -mtlrr10
>> -REST_GPR(10, r11)
>> -mtsprSPRN_SRR1,r9
>> -mtsprSPRN_SRR0,r12
>> -REST_GPR(9, r11)
>> -REST_GPR(12, r11)
>> -lwzr11,GPR11(r11)
>> -rfi
>> +blr
>>
>>   /*
>>* SPE unavailable trap from kernel - print a message, but let
> 
> -- 
> To unsubscribe from this list: send the line "unsubscribe kvm-ppc" in
> the body of a message to majord...@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html
> 


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


Re: [PATCH v2 0/9] DMA engine cookie handling cleanups

2012-03-07 Thread Jassi Brar
On Wed, Mar 7, 2012 at 4:03 AM, Russell King - ARM Linux
 wrote:
> [v2 - more or less same description.  Including lakml in cc for the full
> set]
>
> This patch series cleans up the handling of cookies in DMA engine drivers.
> This is done by providing a set of inline library functions for common
> tasks:
>
> - moving the 'last completed cookie' into struct dma_chan - everyone
>  has this in their driver private channel data structure
>
> - consolidate allocation of cookies to DMA descriptors
>
> - common way to update 'last completed cookie' value
>
> - standard way to implement tx_status callback and update the residue
>
> - consolidate initialization of cookies
>
> - update implementations differing from the majority of DMA engine drivers
>  to behave the same as the majority implementation in respect of cookies
>
> What this means is that we get to the point where all DMA engine drivers
> will hand out cookie value '2' as the first, and incrementing cookie
> values up to INT_MAX, returning to cookie '1' as the next cookie.
>
> Think of this patch series as round 1...  I am hoping over time that more
> code can be consolidated between the DMA engine drivers and end up with a
> consistent way to handle various common themes in DMA engine hardware
> (like physical channel<->peripheral request signal selection.)
>
Compilation is broken without the following minor fix.
After that you may add
   Acked-by: Jassi Brar 

diff --git a/drivers/dma/pl330.c b/drivers/dma/pl330.c
index 49c123f..abf35a3 100644
--- a/drivers/dma/pl330.c
+++ b/drivers/dma/pl330.c
@@ -339,7 +339,6 @@ static int pl330_control(struct dma_chan *chan,
enum dma_ctrl_cmd cmd, unsigned
/* Mark all desc done */
list_for_each_entry_safe(desc, _dt, &pch->work_list , node) {
desc->status = DONE;
-   pch->completed = desc->txd.cookie;
list_move_tail(&desc->node, &list);
}


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

Re: [PATCH v2 0/9] DMA engine cookie handling cleanups

2012-03-07 Thread Russell King - ARM Linux
On Wed, Mar 07, 2012 at 11:39:25PM +0530, Jassi Brar wrote:
> Compilation is broken without the following minor fix.
> After that you may add
>Acked-by: Jassi Brar 
> 
> diff --git a/drivers/dma/pl330.c b/drivers/dma/pl330.c
> index 49c123f..abf35a3 100644
> --- a/drivers/dma/pl330.c
> +++ b/drivers/dma/pl330.c
> @@ -339,7 +339,6 @@ static int pl330_control(struct dma_chan *chan,
> enum dma_ctrl_cmd cmd, unsigned
>   /* Mark all desc done */
>   list_for_each_entry_safe(desc, _dt, &pch->work_list , node) {
>   desc->status = DONE;
> - pch->completed = desc->txd.cookie;

I'm not sure just removing this is sufficient.  Presumably it's
there for some reason - maybe it needs replacing with a call to
dma_cookie_complete() to preserve existing behaviour?
___
Linuxppc-dev mailing list
Linuxppc-dev@lists.ozlabs.org
https://lists.ozlabs.org/listinfo/linuxppc-dev


Re: [PATCH v2 0/9] DMA engine cookie handling cleanups

2012-03-07 Thread Jassi Brar
On Wed, Mar 7, 2012 at 11:51 PM, Russell King - ARM Linux
 wrote:
> On Wed, Mar 07, 2012 at 11:39:25PM +0530, Jassi Brar wrote:
>> Compilation is broken without the following minor fix.
>> After that you may add
>>        Acked-by: Jassi Brar 
>>
>> diff --git a/drivers/dma/pl330.c b/drivers/dma/pl330.c
>> index 49c123f..abf35a3 100644
>> --- a/drivers/dma/pl330.c
>> +++ b/drivers/dma/pl330.c
>> @@ -339,7 +339,6 @@ static int pl330_control(struct dma_chan *chan,
>> enum dma_ctrl_cmd cmd, unsigned
>>               /* Mark all desc done */
>>               list_for_each_entry_safe(desc, _dt, &pch->work_list , node) {
>>                       desc->status = DONE;
>> -                     pch->completed = desc->txd.cookie;
>
> I'm not sure just removing this is sufficient.  Presumably it's
> there for some reason - maybe it needs replacing with a call to
> dma_cookie_complete() to preserve existing behaviour?
>
That was anyway a redundant save in DMA_TERMINATE_ALL, so it should be ok.
___
Linuxppc-dev mailing list
Linuxppc-dev@lists.ozlabs.org
https://lists.ozlabs.org/listinfo/linuxppc-dev

Re: [PATCH] spufs raises two exceptions

2012-03-07 Thread Benjamin Herrenschmidt

> > diff --git a/arch/powerpc/platforms/cell/spufs/inode.c 
> > b/arch/powerpc/platforms/cell/spufs/inode.c
> > index d4a094c..63b4e43 100644
> > --- a/arch/powerpc/platforms/cell/spufs/inode.c
> > +++ b/arch/powerpc/platforms/cell/spufs/inode.c
> > @@ -454,19 +454,16 @@ spufs_create_context(struct inode *inode, struct 
> > dentry *dentry,
> > struct spu_gang *gang;
> > struct spu_context *neighbor;
> >  
> > -   ret = -EPERM;
> > if ((flags & SPU_CREATE_NOSCHED) &&
> > -   !capable(CAP_SYS_NICE))
> > -   goto out_unlock;
> > +   !capable(CAP_SYa_NICE))
> 
> ^typo

Odd, probably an emacs fart

> > +   return -EPERM;
> >  
> > -   ret = -EINVAL;
> > if ((flags & (SPU_CREATE_NOSCHED | SPU_CREATE_ISOLATE))
> > == SPU_CREATE_ISOLATE)
> > -   goto out_unlock;
> > +   return -EINVAL;
> >  
> > -   ret = -ENODEV;
> > if ((flags & SPU_CREATE_ISOLATE) && !isolated_loader)
> > -   goto out_unlock;
> > +   return -ENODEV;
> >  
> > gang = NULL;
> > neighbor = NULL;
> 
> This mostly changes coding style, pointlessly.

How so ? it's no longer necessary to store ret and goto out since there
is no cleanup at all, which makes things smaller/simpler. I wouldn't
call that 'pointlessly'.

I tend to dislike the use of "goto " when the xxx: label does no
cleanup whatsoever.

> > @@ -512,10 +509,6 @@ spufs_create_context(struct inode *inode, struct 
> > dentry *dentry,
> >  out_aff_unlock:
> > if (affinity)
> > mutex_unlock(&gang->aff_mutex);
> > -out_unlock:
> > -   mutex_unlock(&inode->i_mutex);
> > -out:
> > -   dput(dentry);
> > return ret;
> >  }
> 
> The original intention of this was to always unlock in the error case. It
> seems that Al changed this in 1ba10681 "switch do_spufs_create() to
> user_path_create(), fix double-unlock" to never unlock early but always
> unlock in do_spu_create, fixing a different bug, but it looks like
> he forgot this one in the process.
> 
> The reason why we originally had the unlock in the leaf functions is to
> avoid a problem with spu_forget(), which had to be called without
> the i_mutex held to avoid deadlocks.

Ok. I assumed it was fnotify that was the problem...

> > @@ -600,10 +591,6 @@ static int spufs_create_gang(struct inode *inode,
> > int err = simple_rmdir(inode, dentry);
> > WARN_ON(err);
> > }
> > -
> > -out:
> > -   mutex_unlock(&inode->i_mutex);
> > -   dput(dentry);
> > return ret;
> >  }
> 
> Right, this obviously goes together with the one above,

Yes, whatever they do they should do the same thing.

> > @@ -613,22 +600,21 @@ static struct file_system_type spufs_type;
> >  long spufs_create(struct path *path, struct dentry *dentry
> > unsigned int flags, umode_t mode, struct file *filp)
> >  {
> > -   int ret;
> > +   int ret = -EINVAL;
> >  
> > -   ret = -EINVAL;
> > /* check if we are on spufs */
> > if (path->dentry->d_sb->s_type != &spufs_type)
> > -   goto out;
> > +   goto fail;
> >  
> > /* don't accept undefined flags */
> > if (flags & (~SPU_CREATE_FLAG_ALL))
> > -   goto out;
> > +   goto fail;
> >  
> > /* only threads can be underneath a gang */
> > if (path->dentry != path->dentry->d_sb->s_root) {
> > if ((flags & SPU_CREATE_GANG) ||
> > !SPUFS_I(path->dentry->d_inode)->i_gang)
> > -   goto out;
> > +   goto fail;
> > }
> >  
> > mode &= ~current_umask();
> 
> These just change coding style, and not in a helpful way.

Oh I just renamed the label, it's helpful because the label is
specifically only for the fail case, not the general exit path, hence
"fail" is a better naming than "out". It's about code clarity.

> > @@ -640,12 +626,17 @@ long spufs_create(struct path *path, struct dentry 
> > *dentry,
> > ret = spufs_create_context(path->dentry->d_inode,
> > dentry, path->mnt, flags, mode,
> > filp);
> > -   if (ret >= 0)
> > +   if (ret >= 0) {
> > +   /* We drop these before fsnotify */
> > +   mutex_unlock(&inode->i_mutex);
> > +   dput(dentry);
> > fsnotify_mkdir(path->dentry->d_inode, dentry);
> > -   return ret;
> >  
> > -out:
> > -   mutex_unlock(&path->dentry->d_inode->i_mutex);
> > +   return ret;
> > +   }
> > + fail:
> > +   mutex_unlock(&inode->i_mutex);
> > +   dput(dentry);
> > return ret;
> >  }
> >  
> > diff --git a/arch/powerpc/platforms/cell/spufs/syscalls.c 
> > b/arch/powerpc/platforms/cell/spufs/syscalls.c
> > index 8591bb6..1a65ef2 100644
> > --- a/arch/powerpc/platforms/cell/spufs/syscalls.c
> > +++ b/arch/powerpc/platforms/cell/spufs/syscalls.c
> > @@ -70,11 +70,8 @@ static long do_spu_create(const char __user *pathname, 
> > unsigned int flags,
> > ret = PTR_ERR(dentry);
> > if (!IS_ERR(dentry

Re: tlb flushing on Power

2012-03-07 Thread Seth Jennings
On 03/06/2012 11:28 PM, Michael Neuling wrote:
> Seth,
> 
>> Thanks for the help!  I was wondering if you could take a look at something
>> for me.
>>
>> I've been working on this staging driver (zsmalloc memory allocator)
>> that does virtual mapping of two pages.
>>
>> I have a github repo with the driver and the unsubmitted changes.  I'm
>> trying to make to get the pte/tlb stuff working in a portable way:
>>
>> git://github.com/spartacus06/linux.git (portable branch)
>>
>> The experimental commits are the top 5 and the branch is based on
>> Greg's staging-next + frontswap-v11 patches.
>>
>> Could you take a look at the zs_map_object() and zs_unmap_object()
>> in drivers/staging/zsmalloc/zsmalloc-main.c and see if they should
>> work for PPC64?
> 
> I suggest you post the code directly to the list in reviewable chucks.
> People are much more likely to review it if they don't have to download
> some random git tree, checkout some branch, find the changes, etc etc.

It's hard to summarize out of context, but I'll try.

So zsmalloc is designed to store compressed memory pages.  In order
to do that efficiently in memory restricted environments where
memory allocations from the buddy allocator greater than order 0 are
very likely to fail, we have to be able to store compressed memory pages
across non-contiguous page boundaries.

zsmalloc uses virtual memory mapping to do this.  There is a per-cpu
struct vm_struct *vm.  This vm is initialized like this:
===
pte_t *vm_ptes[2];
vm = alloc_vm_area(2 * PAGE_SIZE, vm_ptes);
===

When the allocation needs to be accessed, we map the memory like this
(with preemption disabled):

set_pte_at(&init_mm, 0, vm_ptes[0], mk_pte(page1, PAGE_KERNEL));
set_pte_at(&init_mm, 0, vm_ptes[1], mk_pte(page2, PAGE_KERNEL));

Preemption remains disabled while the user manipulates the allocation.

When the user is done, we unmap by doing:

ptep_get_and_clear(&init_mm, vm->addr, vm_ptes[0]);
ptep_get_and_clear(&init_mm, vm->addr + PAGE_SIZE, vm_ptes[1]);

local_flush_tlb_kernel_page(vm->addr);
local_flush_tlb_kernel_page(vm->addr + PAGE_SIZE);


In my patch, I've defined local_flush_tlb_kernel_page as:

#define local_flush_tlb_kernel_page(kaddr) local_flush_tlb_page(NULL, kaddr)

in arch/powerpc/include/asm/tlbflush.h

For PPC64 (the platform I'm testing on) local_flush_tlb_page() is a no-op
because of the hashing tlb in that architecture; however, it isn't a no-op
on other archs and the whole point of this change is portability.

My understanding is that the tlb flush on PPC64 happens as a result of
the pte_update() eventually called from ptep_get_and_clear().

The problem is that this doesn't always seem to work.  I get corruption
in the mapped memory from time to time.  

I've isolated the issue to this mapping code.

Does anyone see anything glaringly wrong with this approach?

Should ptep_get_and_clear() also flush the tlb entry (asynchronously I think)?

For comparison, this code is stable on x86 where local_flush_tlb_kernel_page()
is defined to __flush_tlb_one().

> If it's work in progress, mark it as an RFC patch and note what issues
> you think still exist.  
> 
> Mikey

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


Re: [PATCH] spufs raises two exceptions

2012-03-07 Thread Al Viro

> No it's not, it all goes together. spufs_create_context() always
> unlocked & dropped the dentry before returning, so I assumed the
> lock had to be dropped before fsnotify.
> 
> Note that if the problem is that the lock has to be dropped before
> spu_forget(), then we should indeed move it back into the leaf functions
> and just remove all the unlock path from the top ones. It's a bit nasty
> how we drop the mutex first, then do spu_forget, then drop the dentry
> but we could go back to doing that.
> 
> What I want is consistent semantics. It's just silly to have 3 different
> stacking levels which all 3 may or may not be responsible to dropping
> the lock & dentry depending on circumstances.

Why not leave unlock/dput to the caller?  Details of deadlocks caused
by that approach, please...
___
Linuxppc-dev mailing list
Linuxppc-dev@lists.ozlabs.org
https://lists.ozlabs.org/listinfo/linuxppc-dev


Re: [PATCH] powerpc/85xx: don't call of_platform_bus_probe() twice

2012-03-07 Thread Timur Tabi
Timur Tabi wrote:
> Commit 46d026ac ("powerpc/85xx: consolidate of_platform_bus_probe calls")
> replaced platform-specific of_device_id tables with a single function
> that probes the most of the busses in 85xx device trees.  If a specific
> platform needed additional busses probed, then it could call
> of_platform_bus_probe() again.  Typically, the additional platform-specific
> busses are children of existing busses that have already been probed.
> of_platform_bus_probe() does not handle those child busses automatically.
> 
> Unfortunately, this doesn't actually work.  The second (platform-specific)
> call to of_platform_bus_probe() never finds any of the busses it's asked
> to find.
> 
> To remedy this, the platform-specific of_device_id tables are eliminated,
> and their entries are merged into mpc85xx_common_ids[], so that all busses
> are probed at once.
> 
> Signed-off-by: Timur Tabi 
> ---

Kumar, without this patch, audio is broken on the P1022DS in your 'merge'
branch.  I posted it back in November, six days after you applied the
patch that broke the P1022DS.

Is there any chance of getting this into 3.3?  This is a real bug fix, and
I would hate for audio to be broken in 3.3.

-- 
Timur Tabi
Linux kernel developer at Freescale

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


[PATCH v3 10/34] powerpc/PCI: allow reallocation on PA Semi

2012-03-07 Thread Bjorn Helgaas
We believe there's no reason to prevent reallocation on PA Semi, so
revert to the default of "allow reallocation if necessary."

CC: Olof Johansson 
CC: Benjamin Herrenschmidt 
CC: linuxppc-dev@lists.ozlabs.org
Signed-off-by: Bjorn Helgaas 
---
 arch/powerpc/platforms/pasemi/pci.c |3 ---
 1 files changed, 0 insertions(+), 3 deletions(-)

diff --git a/arch/powerpc/platforms/pasemi/pci.c 
b/arch/powerpc/platforms/pasemi/pci.c
index b6a0ec4..aa86271 100644
--- a/arch/powerpc/platforms/pasemi/pci.c
+++ b/arch/powerpc/platforms/pasemi/pci.c
@@ -229,9 +229,6 @@ void __init pas_pci_init(void)
 
/* Setup the linkage between OF nodes and PHBs */
pci_devs_phb_init();
-
-   /* Use the common resource allocation mechanism */
-   pci_probe_only = 1;
 }
 
 void __iomem *pasemi_pci_getcfgaddr(struct pci_dev *dev, int offset)

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


[PATCH v3 11/34] powerpc/PCI: replace pci_probe_only with pci_flags

2012-03-07 Thread Bjorn Helgaas
We already use pci_flags, so this just sets pci_flags directly and removes
the intermediate step of figuring out pci_probe_only, then using it to set
pci_flags.

The PCI core provides a pci_flags definition (currently __weak), so drop
the powerpc definitions in favor of that.

Acked-by: Benjamin Herrenschmidt 
CC: linuxppc-dev@lists.ozlabs.org
Signed-off-by: Bjorn Helgaas 
---
 arch/powerpc/include/asm/ppc-pci.h|2 --
 arch/powerpc/kernel/pci-common.c  |3 ---
 arch/powerpc/kernel/pci_64.c  |5 -
 arch/powerpc/kernel/rtas_pci.c|   10 +++---
 arch/powerpc/platforms/iseries/pci.c  |2 +-
 arch/powerpc/platforms/maple/pci.c|2 +-
 arch/powerpc/platforms/powernv/pci-ioda.c |5 ++---
 arch/powerpc/platforms/powernv/pci.c  |2 +-
 arch/powerpc/platforms/pseries/setup.c|4 ++--
 9 files changed, 14 insertions(+), 21 deletions(-)

diff --git a/arch/powerpc/include/asm/ppc-pci.h 
b/arch/powerpc/include/asm/ppc-pci.h
index 43268f1..f4f7ad8 100644
--- a/arch/powerpc/include/asm/ppc-pci.h
+++ b/arch/powerpc/include/asm/ppc-pci.h
@@ -45,8 +45,6 @@ extern void init_pci_config_tokens (void);
 extern unsigned long get_phb_buid (struct device_node *);
 extern int rtas_setup_phb(struct pci_controller *phb);
 
-extern unsigned long pci_probe_only;
-
 /*  EEH internal-use-only related routines  */
 #ifdef CONFIG_EEH
 
diff --git a/arch/powerpc/kernel/pci-common.c b/arch/powerpc/kernel/pci-common.c
index cce98d7..6d03da4 100644
--- a/arch/powerpc/kernel/pci-common.c
+++ b/arch/powerpc/kernel/pci-common.c
@@ -50,9 +50,6 @@ static int global_phb_number; /* Global phb counter */
 /* ISA Memory physical address */
 resource_size_t isa_mem_base;
 
-/* Default PCI flags is 0 on ppc32, modified at boot on ppc64 */
-unsigned int pci_flags = 0;
-
 
 static struct dma_map_ops *pci_dma_ops = &dma_direct_ops;
 
diff --git a/arch/powerpc/kernel/pci_64.c b/arch/powerpc/kernel/pci_64.c
index f627eb7..75417fd 100644
--- a/arch/powerpc/kernel/pci_64.c
+++ b/arch/powerpc/kernel/pci_64.c
@@ -33,8 +33,6 @@
 #include 
 #include 
 
-unsigned long pci_probe_only = 0;
-
 /* pci_io_base -- the base address from which io bars are offsets.
  * This is the lowest I/O base address (so bar values are always positive),
  * and it *must* be the start of ISA space if an ISA bus exists because
@@ -55,9 +53,6 @@ static int __init pcibios_init(void)
 */
ppc_md.phys_mem_access_prot = pci_phys_mem_access_prot;
 
-   if (pci_probe_only)
-   pci_add_flags(PCI_PROBE_ONLY);
-
/* On ppc64, we always enable PCI domains and we keep domain 0
 * backward compatible in /proc for video cards
 */
diff --git a/arch/powerpc/kernel/rtas_pci.c b/arch/powerpc/kernel/rtas_pci.c
index 6cd8f01..140735c 100644
--- a/arch/powerpc/kernel/rtas_pci.c
+++ b/arch/powerpc/kernel/rtas_pci.c
@@ -276,7 +276,7 @@ void __init find_and_init_phbs(void)
pci_devs_phb_init();
 
/*
-* pci_probe_only and pci_assign_all_buses can be set via properties
+* PCI_PROBE_ONLY and PCI_REASSIGN_ALL_BUS can be set via properties
 * in chosen.
 */
if (of_chosen) {
@@ -284,8 +284,12 @@ void __init find_and_init_phbs(void)
 
prop = of_get_property(of_chosen,
"linux,pci-probe-only", NULL);
-   if (prop)
-   pci_probe_only = *prop;
+   if (prop) {
+   if (*prop)
+   pci_add_flags(PCI_PROBE_ONLY);
+   else
+   pci_clear_flags(PCI_PROBE_ONLY);
+   }
 
 #ifdef CONFIG_PPC32 /* Will be made generic soon */
prop = of_get_property(of_chosen,
diff --git a/arch/powerpc/platforms/iseries/pci.c 
b/arch/powerpc/platforms/iseries/pci.c
index c754128..171b2f3 100644
--- a/arch/powerpc/platforms/iseries/pci.c
+++ b/arch/powerpc/platforms/iseries/pci.c
@@ -868,7 +868,7 @@ void __init iSeries_pcibios_init(void)
/* Install IO hooks */
ppc_pci_io = iseries_pci_io;
 
-   pci_probe_only = 1;
+   pci_add_flags(PCI_PROBE_ONLY);
 
/* iSeries has no IO space in the common sense, it needs to set
 * the IO base to 0
diff --git a/arch/powerpc/platforms/maple/pci.c 
b/arch/powerpc/platforms/maple/pci.c
index 401e3f3..465ee8f 100644
--- a/arch/powerpc/platforms/maple/pci.c
+++ b/arch/powerpc/platforms/maple/pci.c
@@ -620,7 +620,7 @@ void __init maple_pci_init(void)
}
 
/* Tell pci.c to not change any resource allocations.  */
-   pci_probe_only = 1;
+   pci_add_flags(PCI_PROBE_ONLY);
 }
 
 int maple_pci_get_legacy_ide_irq(struct pci_dev *pdev, int channel)
diff --git a/arch/powerpc/platforms/powernv/pci-ioda.c 
b/arch/powerpc/platforms/powernv/pci-ioda.c
index 5e155df..fbdd74d 100644
--- a/arch/powerpc/platforms/powernv/pci-ioda.c
+++ b/arch/powerpc/platform

[PATCH v3 27/34] powerpc/PCI: get rid of device resource fixups

2012-03-07 Thread Bjorn Helgaas
Tell the PCI core about host bridge address translation so it can take
care of bus-to-resource conversion for us.

Previously, powerpc used a HEADER quirk to perform this address fixup
in the following path:

pci_device_add()
  pci_fixup_device(pci_fixup_header, dev)
pcibios_fixup_resources()
  fixup_resource()

This happened for both generic (via pci_scan_child_bus()) and
OF device tree enumeration (via of_scan_bus()).

This patch removes fixup_resource(), so the HEADER quirk no longer does
address fixup.  The generic path now does the fixup in __pci_read_base()
using the offsets supplied with pci_add_resource_offset().  The OF path
now does the fixup with new pcibios_bus_to_resource() calls in
of_pci_parse_addrs() and of_scan_pci_bridge().

Acked-by: Benjamin Herrenschmidt 
CC: linuxppc-dev@lists.ozlabs.org
Signed-off-by: Bjorn Helgaas 
---
 arch/powerpc/include/asm/pci.h|9 +---
 arch/powerpc/kernel/pci-common.c  |   83 -
 arch/powerpc/kernel/pci_32.c  |6 +--
 arch/powerpc/kernel/pci_64.c  |2 -
 arch/powerpc/kernel/pci_of_scan.c |   12 -
 5 files changed, 23 insertions(+), 89 deletions(-)

diff --git a/arch/powerpc/include/asm/pci.h b/arch/powerpc/include/asm/pci.h
index f54b3d2..21fbeeb 100644
--- a/arch/powerpc/include/asm/pci.h
+++ b/arch/powerpc/include/asm/pci.h
@@ -154,13 +154,7 @@ extern int pci_mmap_legacy_page_range(struct pci_bus *bus,
 
 #endif /* CONFIG_PPC64 */
 
-extern void pcibios_resource_to_bus(struct pci_dev *dev,
-   struct pci_bus_region *region,
-   struct resource *res);
-
-extern void pcibios_bus_to_resource(struct pci_dev *dev,
-   struct resource *res,
-   struct pci_bus_region *region);
+#define ARCH_HAS_GENERIC_PCI_OFFSETS
 
 extern void pcibios_claim_one_bus(struct pci_bus *b);
 
@@ -190,6 +184,7 @@ extern void pci_resource_to_user(const struct pci_dev *dev, 
int bar,
 const struct resource *rsrc,
 resource_size_t *start, resource_size_t *end);
 
+extern resource_size_t pcibios_io_space_offset(struct pci_controller *hose);
 extern void pcibios_setup_bus_devices(struct pci_bus *bus);
 extern void pcibios_setup_bus_self(struct pci_bus *bus);
 extern void pcibios_setup_phb_io_space(struct pci_controller *hose);
diff --git a/arch/powerpc/kernel/pci-common.c b/arch/powerpc/kernel/pci-common.c
index 6d03da4..2efd52d 100644
--- a/arch/powerpc/kernel/pci-common.c
+++ b/arch/powerpc/kernel/pci-common.c
@@ -846,60 +846,6 @@ int pci_proc_domain(struct pci_bus *bus)
return 1;
 }
 
-void pcibios_resource_to_bus(struct pci_dev *dev, struct pci_bus_region 
*region,
-struct resource *res)
-{
-   resource_size_t offset = 0, mask = (resource_size_t)-1;
-   struct pci_controller *hose = pci_bus_to_host(dev->bus);
-
-   if (!hose)
-   return;
-   if (res->flags & IORESOURCE_IO) {
-   offset = (unsigned long)hose->io_base_virt - _IO_BASE;
-   mask = 0xu;
-   } else if (res->flags & IORESOURCE_MEM)
-   offset = hose->pci_mem_offset;
-
-   region->start = (res->start - offset) & mask;
-   region->end = (res->end - offset) & mask;
-}
-EXPORT_SYMBOL(pcibios_resource_to_bus);
-
-void pcibios_bus_to_resource(struct pci_dev *dev, struct resource *res,
-struct pci_bus_region *region)
-{
-   resource_size_t offset = 0, mask = (resource_size_t)-1;
-   struct pci_controller *hose = pci_bus_to_host(dev->bus);
-
-   if (!hose)
-   return;
-   if (res->flags & IORESOURCE_IO) {
-   offset = (unsigned long)hose->io_base_virt - _IO_BASE;
-   mask = 0xu;
-   } else if (res->flags & IORESOURCE_MEM)
-   offset = hose->pci_mem_offset;
-   res->start = (region->start + offset) & mask;
-   res->end = (region->end + offset) & mask;
-}
-EXPORT_SYMBOL(pcibios_bus_to_resource);
-
-/* Fixup a bus resource into a linux resource */
-static void __devinit fixup_resource(struct resource *res, struct pci_dev *dev)
-{
-   struct pci_controller *hose = pci_bus_to_host(dev->bus);
-   resource_size_t offset = 0, mask = (resource_size_t)-1;
-
-   if (res->flags & IORESOURCE_IO) {
-   offset = (unsigned long)hose->io_base_virt - _IO_BASE;
-   mask = 0xu;
-   } else if (res->flags & IORESOURCE_MEM)
-   offset = hose->pci_mem_offset;
-
-   res->start = (res->start + offset) & mask;
-   res->end = (res->end + offset) & mask;
-}
-
-
 /* This header fixup will do the resource fixup for all devices as they are
  * probed, but not for bridge ranges
  */
@@ -939,18 +885,11 @@ static void __devinit pcibios_fixup_resources(struct 
pci_dev *dev)
continue;
}
 
-   pr_debug(

Re: [PATCH v3 10/34] powerpc/PCI: allow reallocation on PA Semi

2012-03-07 Thread Olof Johansson
On Wed, Mar 7, 2012 at 2:32 PM, Bjorn Helgaas  wrote:
> We believe there's no reason to prevent reallocation on PA Semi, so
> revert to the default of "allow reallocation if necessary."
>
> CC: Olof Johansson 
> CC: Benjamin Herrenschmidt 
> CC: linuxppc-dev@lists.ozlabs.org
> Signed-off-by: Bjorn Helgaas 

Tested-by: Olof Johansson 
Acked-by: Olof Johansson 
___
Linuxppc-dev mailing list
Linuxppc-dev@lists.ozlabs.org
https://lists.ozlabs.org/listinfo/linuxppc-dev


Re: [PATCH] spufs raises two exceptions

2012-03-07 Thread Arnd Bergmann
On Wednesday 07 March 2012, Al Viro wrote:
> > No it's not, it all goes together. spufs_create_context() always
> > unlocked & dropped the dentry before returning, so I assumed the
> > lock had to be dropped before fsnotify.
> > 
> > Note that if the problem is that the lock has to be dropped before
> > spu_forget(), then we should indeed move it back into the leaf functions
> > and just remove all the unlock path from the top ones. It's a bit nasty
> > how we drop the mutex first, then do spu_forget, then drop the dentry
> > but we could go back to doing that.
> > 
> > What I want is consistent semantics. It's just silly to have 3 different
> > stacking levels which all 3 may or may not be responsible to dropping
> > the lock & dentry depending on circumstances.
> 
> Why not leave unlock/dput to the caller?  Details of deadlocks caused
> by that approach, please...

If only I could remember that part exactly. I think I was remembering
0309f02d8 "spufs: fix deadlock in spu_create error path", which had a
double lock problem in this path. Please bear with me here because it's
been six years since I debugged that particular problem.

A lot of the nastyness of spu_forget() is about the problem of having
to give up a reference on current->mm that is held by an spu context,
while the mm contains a vma that maps this context and holds a refence
on the inode, in particular in case of calling exit().

However, I don't see now how either of these two issues requires that
we call spu_forget without the i_mutex held during a context creation
failure.

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


Re: [PATCH v2] powerpc/dts: fix the compatible string of sec 4.0

2012-03-07 Thread Kim Phillips
On Wed, 7 Mar 2012 13:20:06 +0800
Shengzhou Liu  wrote:

> From: Liu Shuo 
> 
> Fix the compatible string of sec 4.0 to match with CAMM driver according
> to Documentation/devicetree/bindings/crypto/fsl-sec4.txt
> 
> Signed-off-by: Liu Shuo 
> Signed-off-by: Shengzhou Liu 
> ---
> v2: refine description.

can we patch the caam driver to still work with "fsl-sec4.0"?

Thanks,

Kim

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


linux-next: manual merge of the powerpc tree with the arm tree

2012-03-07 Thread Stephen Rothwell
Hi all,

Today's linux-next merge of the powerpc tree got a conflict in
arch/powerpc/Kconfig between commit 2ed86b16eabe ("irq: make SPARSE_IRQ
an optionally hidden option") from the arm tree and commit ad5b7f1350c2
("powerpc: Make SPARSE_IRQ required") from the powerpc tree.

I fixed it up (see below) and can carry the fix as necessary.
-- 
Cheers,
Stephen Rothwells...@canb.auug.org.au

diff --cc arch/powerpc/Kconfig
index bf7dbc2,4eecaaa..000
--- a/arch/powerpc/Kconfig
+++ b/arch/powerpc/Kconfig
@@@ -133,7 -133,8 +133,8 @@@ config PP
select HAVE_REGS_AND_STACK_ACCESS_API
select HAVE_HW_BREAKPOINT if PERF_EVENTS && PPC_BOOK3S_64
select HAVE_GENERIC_HARDIRQS
 -  select HAVE_SPARSE_IRQ
 +  select MAY_HAVE_SPARSE_IRQ
+   select SPARSE_IRQ
select IRQ_PER_CPU
select GENERIC_IRQ_SHOW
select GENERIC_IRQ_SHOW_LEVEL


pgpePVp6jGQtI.pgp
Description: PGP signature
___
Linuxppc-dev mailing list
Linuxppc-dev@lists.ozlabs.org
https://lists.ozlabs.org/listinfo/linuxppc-dev

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

2012-03-07 Thread Michael Neuling
> Today's linux-next merge of the powerpc tree got a conflict in
> arch/powerpc/Kconfig between commit 2ed86b16eabe ("irq: make SPARSE_IRQ
> an optionally hidden option") from the arm tree and commit ad5b7f1350c2
> ("powerpc: Make SPARSE_IRQ required") from the powerpc tree.
> 
> I fixed it up (see below) and can carry the fix as necessary.
> --=20
> Cheers,
> Stephen Rothwells...@canb.auug.org.au
> 
> diff --cc arch/powerpc/Kconfig
> index bf7dbc2,4eecaaa..000
> --- a/arch/powerpc/Kconfig
> +++ b/arch/powerpc/Kconfig
> @@@ -133,7 -133,8 +133,8 @@@ config PP
>   select HAVE_REGS_AND_STACK_ACCESS_API
>   select HAVE_HW_BREAKPOINT if PERF_EVENTS && PPC_BOOK3S_64
>   select HAVE_GENERIC_HARDIRQS
>  -select HAVE_SPARSE_IRQ
>  +select MAY_HAVE_SPARSE_IRQ
> + select SPARSE_IRQ

Surely we only need SPARSE_IRQ now and not MAY_HAVE_SPARSE_IRQ.  

In fact, keeping MAY_HAVE_SPARSE_IRQ seems to make SPARSE_IRQ user
selectable, which we don't want anymore since ad5b7f1350c2.

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


RE: [PATCH v2] powerpc/dts: fix the compatible string of sec 4.0

2012-03-07 Thread Liu Shengzhou-B36685


> -Original Message-
> From: Phillips Kim-R1AAHA
> Sent: Thursday, March 08, 2012 7:26 AM
> To: Liu Shengzhou-B36685
> Cc: linuxppc-dev@lists.ozlabs.org; sta...@kernel.org; Liu Shuo-B35362
> Subject: Re: [PATCH v2] powerpc/dts: fix the compatible string of sec
> 4.0
> 
> On Wed, 7 Mar 2012 13:20:06 +0800
> Shengzhou Liu  wrote:
> 
> > From: Liu Shuo 
> >
> > Fix the compatible string of sec 4.0 to match with CAMM driver
> > according to Documentation/devicetree/bindings/crypto/fsl-sec4.txt
> >
> > Signed-off-by: Liu Shuo 
> > Signed-off-by: Shengzhou Liu 
> > ---
> > v2: refine description.
> 
> can we patch the caam driver to still work with "fsl-sec4.0"?
> 
> Thanks,
> 
> Kim
[Shengzhou] ok, I will post another patch for it. Thanks.

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


[PATCH] powerpc: Remove the main legacy iSerie platform code

2012-03-07 Thread Stephen Rothwell

Signed-off-by: Stephen Rothwell 
---
 arch/powerpc/platforms/Makefile   |1 -
 arch/powerpc/platforms/iseries/Makefile   |9 -
 arch/powerpc/platforms/iseries/call_hpt.h |  102 --
 arch/powerpc/platforms/iseries/call_pci.h |  309 -
 arch/powerpc/platforms/iseries/call_sm.h  |   37 -
 arch/powerpc/platforms/iseries/dt.c   |  643 ---
 arch/powerpc/platforms/iseries/exception.S|  311 -
 arch/powerpc/platforms/iseries/exception.h|   58 -
 arch/powerpc/platforms/iseries/htab.c |  257 -
 arch/powerpc/platforms/iseries/hvcall.S   |   94 --
 arch/powerpc/platforms/iseries/hvlog.c|   35 -
 arch/powerpc/platforms/iseries/hvlpconfig.c   |   39 -
 arch/powerpc/platforms/iseries/iommu.c|  260 -
 arch/powerpc/platforms/iseries/ipl_parms.h|   68 --
 arch/powerpc/platforms/iseries/irq.c  |  400 ---
 arch/powerpc/platforms/iseries/irq.h  |   13 -
 arch/powerpc/platforms/iseries/it_exp_vpd_panel.h |   51 -
 arch/powerpc/platforms/iseries/it_lp_naca.h   |   80 --
 arch/powerpc/platforms/iseries/ksyms.c|   21 -
 arch/powerpc/platforms/iseries/lpardata.c |  318 -
 arch/powerpc/platforms/iseries/lpevents.c |  341 --
 arch/powerpc/platforms/iseries/main_store.h   |  165 ---
 arch/powerpc/platforms/iseries/mf.c   | 1275 -
 arch/powerpc/platforms/iseries/misc.S |   26 -
 arch/powerpc/platforms/iseries/naca.h |   24 -
 arch/powerpc/platforms/iseries/pci.c  |  919 ---
 arch/powerpc/platforms/iseries/pci.h  |   58 -
 arch/powerpc/platforms/iseries/proc.c |  120 --
 arch/powerpc/platforms/iseries/processor_vpd.h|   85 --
 arch/powerpc/platforms/iseries/release_data.h |   63 -
 arch/powerpc/platforms/iseries/setup.c|  722 
 arch/powerpc/platforms/iseries/setup.h|   27 -
 arch/powerpc/platforms/iseries/smp.c  |   88 --
 arch/powerpc/platforms/iseries/spcomm_area.h  |   34 -
 arch/powerpc/platforms/iseries/vio.c  |  556 -
 arch/powerpc/platforms/iseries/viopath.c  |  677 ---
 arch/powerpc/platforms/iseries/vpd_areas.h|   88 --
 37 files changed, 0 insertions(+), 8374 deletions(-)
 delete mode 100644 arch/powerpc/platforms/iseries/Makefile
 delete mode 100644 arch/powerpc/platforms/iseries/call_hpt.h
 delete mode 100644 arch/powerpc/platforms/iseries/call_pci.h
 delete mode 100644 arch/powerpc/platforms/iseries/call_sm.h
 delete mode 100644 arch/powerpc/platforms/iseries/dt.c
 delete mode 100644 arch/powerpc/platforms/iseries/exception.S
 delete mode 100644 arch/powerpc/platforms/iseries/exception.h
 delete mode 100644 arch/powerpc/platforms/iseries/htab.c
 delete mode 100644 arch/powerpc/platforms/iseries/hvcall.S
 delete mode 100644 arch/powerpc/platforms/iseries/hvlog.c
 delete mode 100644 arch/powerpc/platforms/iseries/hvlpconfig.c
 delete mode 100644 arch/powerpc/platforms/iseries/iommu.c
 delete mode 100644 arch/powerpc/platforms/iseries/ipl_parms.h
 delete mode 100644 arch/powerpc/platforms/iseries/irq.c
 delete mode 100644 arch/powerpc/platforms/iseries/irq.h
 delete mode 100644 arch/powerpc/platforms/iseries/it_exp_vpd_panel.h
 delete mode 100644 arch/powerpc/platforms/iseries/it_lp_naca.h
 delete mode 100644 arch/powerpc/platforms/iseries/ksyms.c
 delete mode 100644 arch/powerpc/platforms/iseries/lpardata.c
 delete mode 100644 arch/powerpc/platforms/iseries/lpevents.c
 delete mode 100644 arch/powerpc/platforms/iseries/main_store.h
 delete mode 100644 arch/powerpc/platforms/iseries/mf.c
 delete mode 100644 arch/powerpc/platforms/iseries/misc.S
 delete mode 100644 arch/powerpc/platforms/iseries/naca.h
 delete mode 100644 arch/powerpc/platforms/iseries/pci.c
 delete mode 100644 arch/powerpc/platforms/iseries/pci.h
 delete mode 100644 arch/powerpc/platforms/iseries/proc.c
 delete mode 100644 arch/powerpc/platforms/iseries/processor_vpd.h
 delete mode 100644 arch/powerpc/platforms/iseries/release_data.h
 delete mode 100644 arch/powerpc/platforms/iseries/setup.c
 delete mode 100644 arch/powerpc/platforms/iseries/setup.h
 delete mode 100644 arch/powerpc/platforms/iseries/smp.c
 delete mode 100644 arch/powerpc/platforms/iseries/spcomm_area.h
 delete mode 100644 arch/powerpc/platforms/iseries/vio.c
 delete mode 100644 arch/powerpc/platforms/iseries/viopath.c
 delete mode 100644 arch/powerpc/platforms/iseries/vpd_areas.h

This is a git style diff (so does not contain the old contents of the
deleted files).

diff --git a/arch/powerpc/platforms/Makefile b/arch/powerpc/platforms/Makefile
index 2635a22..879b4a4 100644
--- a/arch/powerpc/platforms/Makefile
+++ b/arch/powerpc/platforms/Makefile
@@ -16,7 +16,6 @@ obj-$(CONFIG_FSL_SOC_BOOKE)   += 85xx/
 obj-$(CONFIG_PPC_86xx) += 86xx/
 obj-$(CONFIG_PPC_P

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

2012-03-07 Thread Stephen Rothwell
Hi Mikey,

On Thu, 08 Mar 2012 13:33:56 +1100 Michael Neuling  wrote:
>
> Surely we only need SPARSE_IRQ now and not MAY_HAVE_SPARSE_IRQ.  
> 
> In fact, keeping MAY_HAVE_SPARSE_IRQ seems to make SPARSE_IRQ user
> selectable, which we don't want anymore since ad5b7f1350c2.

Yes, indeed. I will fix up the merge resolution for tomorrow.

-- 
Cheers,
Stephen Rothwells...@canb.auug.org.au


pgp5zWZbCEzQx.pgp
Description: PGP signature
___
Linuxppc-dev mailing list
Linuxppc-dev@lists.ozlabs.org
https://lists.ozlabs.org/listinfo/linuxppc-dev

[PATCH 0/7] powerpc: remove the legacy iSeries platform specific drivers

2012-03-07 Thread Stephen Rothwell
Hi all,

This series of patches removes all the legacy iSeries platform specific
drivers (and the iSeries specific part of one).  The legacy iSeries
platform main code has already bee removed along with CONFIG_PPC_ISERIES,
so none of this code is selectable or needed any more.

It would probably be easiest if all these patches were merged via the
powerpc tree to eliminate any dependencies between them.  Their impact on
generic code is very small.

-- 
Cheers,
Stephen Rothwells...@canb.auug.org.au

 arch/powerpc/include/asm/iseries/hv_call_event.h |  201 ---
 arch/powerpc/include/asm/iseries/hv_lp_event.h   |  162 --
 arch/powerpc/include/asm/iseries/iommu.h |   37 -
 arch/powerpc/include/asm/iseries/vio.h   |  265 
 arch/powerpc/kernel/vio.c|   18 +-
 drivers/base/driver.c|   30 -
 drivers/block/viodasd.c  |  809 --
 drivers/cdrom/viocd.c|  739 --
 drivers/char/viotape.c   | 1041 -
 drivers/net/ethernet/ibm/Kconfig |4 -
 drivers/net/ethernet/ibm/Makefile|1 -
 drivers/net/ethernet/ibm/iseries_veth.c  | 1710 --
 drivers/scsi/Kconfig |3 +-
 drivers/scsi/ibmvscsi/Makefile   |1 -
 drivers/scsi/ibmvscsi/ibmvscsi.c |   12 +-
 drivers/scsi/ibmvscsi/ibmvscsi.h |1 -
 drivers/scsi/ibmvscsi/iseries_vscsi.c|  173 ---
 drivers/tty/hvc/Kconfig  |   10 -
 drivers/tty/hvc/Makefile |1 -
 drivers/tty/hvc/hvc_iseries.c|  599 
 drivers/tty/serial/Kconfig   |2 +-
 include/linux/device.h   |4 -
 22 files changed, 5 insertions(+), 5818 deletions(-)


pgpQJwec4SGwr.pgp
Description: PGP signature
___
Linuxppc-dev mailing list
Linuxppc-dev@lists.ozlabs.org
https://lists.ozlabs.org/listinfo/linuxppc-dev

[PATCH 1/7] powerpc: Remove some of the legacy iSeries specifi device drivers

2012-03-07 Thread Stephen Rothwell
These drivers are specific to the PowerPC legacy iSeries platform and
their Kconfig is specified in arch/powerpc.  Legacy iSeries is being
removed, so these drivers can no longer be selected.

Cc: Jens Axboe 
Signed-off-by: Stephen Rothwell 
---
 drivers/block/viodasd.c |  809 
 drivers/cdrom/viocd.c   |  739 -
 drivers/char/viotape.c  | 1041 ---
 3 files changed, 0 insertions(+), 2589 deletions(-)
 delete mode 100644 drivers/block/viodasd.c
 delete mode 100644 drivers/cdrom/viocd.c
 delete mode 100644 drivers/char/viotape.c

diff --git a/drivers/block/viodasd.c b/drivers/block/viodasd.c
deleted file mode 100644
index 9a5b2a2..000
diff --git a/drivers/cdrom/viocd.c b/drivers/cdrom/viocd.c
deleted file mode 100644
index 7878da8..000
diff --git a/drivers/char/viotape.c b/drivers/char/viotape.c
deleted file mode 100644
index ad6e64a..000
-- 
1.7.9.1

-- 
Cheers,
Stephen Rothwells...@canb.auug.org.au


pgp1wqAso7po5.pgp
Description: PGP signature
___
Linuxppc-dev mailing list
Linuxppc-dev@lists.ozlabs.org
https://lists.ozlabs.org/listinfo/linuxppc-dev

[PATCH 2/7] net: powerpc: remove the legacy iSeries ethernet driver

2012-03-07 Thread Stephen Rothwell
This driver is specific to the PowerPC legcay iSeries platform which is
being removed.

Cc: David Miller 
Cc: 
Signed-off-by: Stephen Rothwell 
---
 drivers/net/ethernet/ibm/Kconfig|4 -
 drivers/net/ethernet/ibm/Makefile   |1 -
 drivers/net/ethernet/ibm/iseries_veth.c | 1710 ---
 3 files changed, 0 insertions(+), 1715 deletions(-)
 delete mode 100644 drivers/net/ethernet/ibm/iseries_veth.c

diff --git a/drivers/net/ethernet/ibm/Kconfig b/drivers/net/ethernet/ibm/Kconfig
index 9e16f3f..b9773d2 100644
--- a/drivers/net/ethernet/ibm/Kconfig
+++ b/drivers/net/ethernet/ibm/Kconfig
@@ -29,10 +29,6 @@ config IBMVETH
  To compile this driver as a module, choose M here. The module will
  be called ibmveth.
 
-config ISERIES_VETH
-   tristate "iSeries Virtual Ethernet driver support"
-   depends on PPC_ISERIES
-
 source "drivers/net/ethernet/ibm/emac/Kconfig"
 
 config EHEA
diff --git a/drivers/net/ethernet/ibm/Makefile 
b/drivers/net/ethernet/ibm/Makefile
index 5a7d4e9..2f04e71 100644
--- a/drivers/net/ethernet/ibm/Makefile
+++ b/drivers/net/ethernet/ibm/Makefile
@@ -3,6 +3,5 @@
 #
 
 obj-$(CONFIG_IBMVETH) += ibmveth.o
-obj-$(CONFIG_ISERIES_VETH) += iseries_veth.o
 obj-$(CONFIG_IBM_EMAC) += emac/
 obj-$(CONFIG_EHEA) += ehea/
diff --git a/drivers/net/ethernet/ibm/iseries_veth.c 
b/drivers/net/ethernet/ibm/iseries_veth.c
deleted file mode 100644
index acc31af..000
-- 
1.7.9.1

-- 
Cheers,
Stephen Rothwells...@canb.auug.org.au


pgpUAkXF1y5ag.pgp
Description: PGP signature
___
Linuxppc-dev mailing list
Linuxppc-dev@lists.ozlabs.org
https://lists.ozlabs.org/listinfo/linuxppc-dev

[PATCH 3/7] [SCSI] powerpc: remove the legacy iSeries part of ibmvscsi

2012-03-07 Thread Stephen Rothwell
The PowerPC legacy iSeries platform is being removed and this code is
no longer selectable.  There is more clean up that can be done, but this
just gets the old code out of the way.

Cc: "James E.J. Bottomley" 
Cc: Brian King 
Cc: linux-s...@vger.kernel.org
Signed-off-by: Stephen Rothwell 
---
 drivers/scsi/Kconfig  |3 +-
 drivers/scsi/ibmvscsi/Makefile|1 -
 drivers/scsi/ibmvscsi/ibmvscsi.c  |   12 +--
 drivers/scsi/ibmvscsi/ibmvscsi.h  |1 -
 drivers/scsi/ibmvscsi/iseries_vscsi.c |  173 -
 5 files changed, 3 insertions(+), 187 deletions(-)
 delete mode 100644 drivers/scsi/ibmvscsi/iseries_vscsi.c

diff --git a/drivers/scsi/Kconfig b/drivers/scsi/Kconfig
index 16570aa..e38d843 100644
--- a/drivers/scsi/Kconfig
+++ b/drivers/scsi/Kconfig
@@ -967,9 +967,8 @@ config SCSI_IPS
 
 config SCSI_IBMVSCSI
tristate "IBM Virtual SCSI support"
-   depends on PPC_PSERIES || PPC_ISERIES
+   depends on PPC_PSERIES
select SCSI_SRP_ATTRS
-   select VIOPATH if PPC_ISERIES
help
  This is the IBM POWER Virtual SCSI Client
 
diff --git a/drivers/scsi/ibmvscsi/Makefile b/drivers/scsi/ibmvscsi/Makefile
index a423d96..ff5b5c5 100644
--- a/drivers/scsi/ibmvscsi/Makefile
+++ b/drivers/scsi/ibmvscsi/Makefile
@@ -1,7 +1,6 @@
 obj-$(CONFIG_SCSI_IBMVSCSI)+= ibmvscsic.o
 
 ibmvscsic-y+= ibmvscsi.o
-ibmvscsic-$(CONFIG_PPC_ISERIES)+= iseries_vscsi.o 
 ibmvscsic-$(CONFIG_PPC_PSERIES)+= rpa_vscsi.o 
 
 obj-$(CONFIG_SCSI_IBMVSCSIS)   += ibmvstgt.o
diff --git a/drivers/scsi/ibmvscsi/ibmvscsi.c b/drivers/scsi/ibmvscsi/ibmvscsi.c
index 3d391dc..e984951 100644
--- a/drivers/scsi/ibmvscsi/ibmvscsi.c
+++ b/drivers/scsi/ibmvscsi/ibmvscsi.c
@@ -55,13 +55,7 @@
  * and sends a CRQ message back to inform the client that the request has
  * completed.
  *
- * Note that some of the underlying infrastructure is different between
- * machines conforming to the "RS/6000 Platform Architecture" (RPA) and
- * the older iSeries hypervisor models.  To support both, some low level
- * routines have been broken out into rpa_vscsi.c and iseries_vscsi.c.
- * The Makefile should pick one, not two, not zero, of these.
- *
- * TODO: This is currently pretty tied to the IBM i/pSeries hypervisor
+ * TODO: This is currently pretty tied to the IBM pSeries hypervisor
  * interfaces.  It would be really nice to abstract this above an RDMA
  * layer.
  */
@@ -2085,9 +2079,7 @@ int __init ibmvscsi_module_init(void)
driver_template.can_queue = max_requests;
max_events = max_requests + 2;
 
-   if (firmware_has_feature(FW_FEATURE_ISERIES))
-   ibmvscsi_ops = &iseriesvscsi_ops;
-   else if (firmware_has_feature(FW_FEATURE_VIO))
+   if (firmware_has_feature(FW_FEATURE_VIO))
ibmvscsi_ops = &rpavscsi_ops;
else
return -ENODEV;
diff --git a/drivers/scsi/ibmvscsi/ibmvscsi.h b/drivers/scsi/ibmvscsi/ibmvscsi.h
index 02197a2..c503e17 100644
--- a/drivers/scsi/ibmvscsi/ibmvscsi.h
+++ b/drivers/scsi/ibmvscsi/ibmvscsi.h
@@ -127,7 +127,6 @@ struct ibmvscsi_ops {
int (*resume) (struct ibmvscsi_host_data *hostdata);
 };
 
-extern struct ibmvscsi_ops iseriesvscsi_ops;
 extern struct ibmvscsi_ops rpavscsi_ops;
 
 #endif /* IBMVSCSI_H */
diff --git a/drivers/scsi/ibmvscsi/iseries_vscsi.c 
b/drivers/scsi/ibmvscsi/iseries_vscsi.c
deleted file mode 100644
index f477645..000
-- 
1.7.9.1

-- 
Cheers,
Stephen Rothwells...@canb.auug.org.au


pgphEnjQgkJJA.pgp
Description: PGP signature
___
Linuxppc-dev mailing list
Linuxppc-dev@lists.ozlabs.org
https://lists.ozlabs.org/listinfo/linuxppc-dev

[PATCH 4/7] tty: powerpc: remove hvc_iseries

2012-03-07 Thread Stephen Rothwell
The PowerPC legacy iSeries platform is being removed, so this code is no
longer needed.

Cc: Greg Kroah-Hartman 
Signed-off-by: Stephen Rothwell 
---
 drivers/tty/hvc/Kconfig   |   10 -
 drivers/tty/hvc/Makefile  |1 -
 drivers/tty/hvc/hvc_iseries.c |  599 -
 3 files changed, 0 insertions(+), 610 deletions(-)
 delete mode 100644 drivers/tty/hvc/hvc_iseries.c

diff --git a/drivers/tty/hvc/Kconfig b/drivers/tty/hvc/Kconfig
index 4222035..8ea7f07 100644
--- a/drivers/tty/hvc/Kconfig
+++ b/drivers/tty/hvc/Kconfig
@@ -24,16 +24,6 @@ config HVC_OLD_HVSI
depends on HVC_CONSOLE
default n
 
-config HVC_ISERIES
-   bool "iSeries Hypervisor Virtual Console support"
-   depends on PPC_ISERIES
-   default y
-   select HVC_DRIVER
-   select HVC_IRQ
-   select VIOPATH
-   help
- iSeries machines support a hypervisor virtual console.
-
 config HVC_OPAL
bool "OPAL Console support"
depends on PPC_POWERNV
diff --git a/drivers/tty/hvc/Makefile b/drivers/tty/hvc/Makefile
index 89abf40b..4ca3723 100644
--- a/drivers/tty/hvc/Makefile
+++ b/drivers/tty/hvc/Makefile
@@ -1,7 +1,6 @@
 obj-$(CONFIG_HVC_CONSOLE)  += hvc_vio.o hvsi_lib.o
 obj-$(CONFIG_HVC_OPAL) += hvc_opal.o hvsi_lib.o
 obj-$(CONFIG_HVC_OLD_HVSI) += hvsi.o
-obj-$(CONFIG_HVC_ISERIES)  += hvc_iseries.o
 obj-$(CONFIG_HVC_RTAS) += hvc_rtas.o
 obj-$(CONFIG_HVC_TILE) += hvc_tile.o
 obj-$(CONFIG_HVC_DCC)  += hvc_dcc.o
diff --git a/drivers/tty/hvc/hvc_iseries.c b/drivers/tty/hvc/hvc_iseries.c
deleted file mode 100644
index 3f4a897..000
-- 
1.7.9.1

-- 
Cheers,
Stephen Rothwells...@canb.auug.org.au


pgpXqGYNP375a.pgp
Description: PGP signature
___
Linuxppc-dev mailing list
Linuxppc-dev@lists.ozlabs.org
https://lists.ozlabs.org/listinfo/linuxppc-dev

[PATCH 5/7] tty: powerpc: remove SERIAL_ICOM dependency on PPC_ISERIES

2012-03-07 Thread Stephen Rothwell
The PowerPC legacy iSeries platform is being removed so this is no
longer selectable.

Cc: Alan Cox 
Cc: Greg Kroah-Hartman 
Cc: linux-ser...@vger.kernel.org
Signed-off-by: Stephen Rothwell 
---
 drivers/tty/serial/Kconfig |2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/drivers/tty/serial/Kconfig b/drivers/tty/serial/Kconfig
index 2de9924..59e7983 100644
--- a/drivers/tty/serial/Kconfig
+++ b/drivers/tty/serial/Kconfig
@@ -853,7 +853,7 @@ config SERIAL_MPC52xx_CONSOLE_BAUD
 
 config SERIAL_ICOM
tristate "IBM Multiport Serial Adapter"
-   depends on PCI && (PPC_ISERIES || PPC_PSERIES)
+   depends on PCI && PPC_PSERIES
select SERIAL_CORE
select FW_LOADER
help
-- 
1.7.9.1

-- 
Cheers,
Stephen Rothwells...@canb.auug.org.au


pgpqRpy6QdxwG.pgp
Description: PGP signature
___
Linuxppc-dev mailing list
Linuxppc-dev@lists.ozlabs.org
https://lists.ozlabs.org/listinfo/linuxppc-dev

[PATCH 6/7] driver-core: remove legacy iSeries hack

2012-03-07 Thread Stephen Rothwell
The PowerPC legacy iSeries plateform is being removed along with the
"one looney iseries driver", so this code can now be removed as well.

cc: Greg Kroah-Hartman 
Signed-off-by: Stephen Rothwell 
---
 drivers/base/driver.c  |   30 --
 include/linux/device.h |4 
 2 files changed, 0 insertions(+), 34 deletions(-)

diff --git a/drivers/base/driver.c b/drivers/base/driver.c
index b631f7c..db4f54c 100644
--- a/drivers/base/driver.c
+++ b/drivers/base/driver.c
@@ -124,36 +124,6 @@ void driver_remove_file(struct device_driver *drv,
 EXPORT_SYMBOL_GPL(driver_remove_file);
 
 /**
- * driver_add_kobj - add a kobject below the specified driver
- * @drv: requesting device driver
- * @kobj: kobject to add below this driver
- * @fmt: format string that names the kobject
- *
- * You really don't want to do this, this is only here due to one looney
- * iseries driver, go poke those developers if you are annoyed about
- * this...
- */
-int driver_add_kobj(struct device_driver *drv, struct kobject *kobj,
-   const char *fmt, ...)
-{
-   va_list args;
-   char *name;
-   int ret;
-
-   va_start(args, fmt);
-   name = kvasprintf(GFP_KERNEL, fmt, args);
-   va_end(args);
-
-   if (!name)
-   return -ENOMEM;
-
-   ret = kobject_add(kobj, &drv->p->kobj, "%s", name);
-   kfree(name);
-   return ret;
-}
-EXPORT_SYMBOL_GPL(driver_add_kobj);
-
-/**
  * get_driver - increment driver reference count.
  * @drv: driver.
  */
diff --git a/include/linux/device.h b/include/linux/device.h
index b63fb39..46baa1f 100644
--- a/include/linux/device.h
+++ b/include/linux/device.h
@@ -264,10 +264,6 @@ extern int __must_check driver_create_file(struct 
device_driver *driver,
 extern void driver_remove_file(struct device_driver *driver,
   const struct driver_attribute *attr);
 
-extern int __must_check driver_add_kobj(struct device_driver *drv,
-   struct kobject *kobj,
-   const char *fmt, ...);
-
 extern int __must_check driver_for_each_device(struct device_driver *drv,
   struct device *start,
   void *data,
-- 
1.7.9.1

-- 
Cheers,
Stephen Rothwells...@canb.auug.org.au


pgpS8t2gR8vrH.pgp
Description: PGP signature
___
Linuxppc-dev mailing list
Linuxppc-dev@lists.ozlabs.org
https://lists.ozlabs.org/listinfo/linuxppc-dev

[PATCH 7/7] powerpc: clean up vio.c

2012-03-07 Thread Stephen Rothwell
This cleans up vio.c after the removal of the legacy iSeries platform.
It also removes some no longer referenced include files.

Signed-off-by: Stephen Rothwell 
---
 arch/powerpc/include/asm/iseries/hv_call_event.h |  201 
 arch/powerpc/include/asm/iseries/hv_lp_event.h   |  162 -
 arch/powerpc/include/asm/iseries/iommu.h |   37 ---
 arch/powerpc/include/asm/iseries/vio.h   |  265 --
 arch/powerpc/kernel/vio.c|   18 +--
 5 files changed, 1 insertions(+), 682 deletions(-)
 delete mode 100644 arch/powerpc/include/asm/iseries/hv_call_event.h
 delete mode 100644 arch/powerpc/include/asm/iseries/hv_lp_event.h
 delete mode 100644 arch/powerpc/include/asm/iseries/iommu.h
 delete mode 100644 arch/powerpc/include/asm/iseries/vio.h

diff --git a/arch/powerpc/include/asm/iseries/hv_call_event.h 
b/arch/powerpc/include/asm/iseries/hv_call_event.h
deleted file mode 100644
index cc029d3..000
diff --git a/arch/powerpc/include/asm/iseries/hv_lp_event.h 
b/arch/powerpc/include/asm/iseries/hv_lp_event.h
deleted file mode 100644
index 8f5da7d..000
diff --git a/arch/powerpc/include/asm/iseries/iommu.h 
b/arch/powerpc/include/asm/iseries/iommu.h
deleted file mode 100644
index 1b9692c..000
diff --git a/arch/powerpc/include/asm/iseries/vio.h 
b/arch/powerpc/include/asm/iseries/vio.h
deleted file mode 100644
index f9ac0d0..000
diff --git a/arch/powerpc/kernel/vio.c b/arch/powerpc/kernel/vio.c
index 8b08629..bca3fc4 100644
--- a/arch/powerpc/kernel/vio.c
+++ b/arch/powerpc/kernel/vio.c
@@ -34,11 +34,6 @@
 #include 
 #include 
 #include 
-#include 
-#include 
-#include 
-#include 
-#include 
 
 static struct bus_type vio_bus_type;
 
@@ -1042,7 +1037,6 @@ static void vio_cmo_sysfs_init(void)
vio_bus_type.bus_attrs = vio_cmo_bus_attrs;
 }
 #else /* CONFIG_PPC_SMLPAR */
-/* Dummy functions for iSeries platform */
 int vio_cmo_entitlement_update(size_t new_entitlement) { return 0; }
 void vio_cmo_set_dev_desired(struct vio_dev *viodev, size_t desired) {}
 static int vio_cmo_bus_probe(struct vio_dev *viodev) { return 0; }
@@ -1060,9 +1054,6 @@ static struct iommu_table *vio_build_iommu_table(struct 
vio_dev *dev)
struct iommu_table *tbl;
unsigned long offset, size;
 
-   if (firmware_has_feature(FW_FEATURE_ISERIES))
-   return vio_build_iommu_table_iseries(dev);
-
dma_window = of_get_property(dev->dev.of_node,
  "ibm,my-dma-window", NULL);
if (!dma_window)
@@ -1195,8 +1186,7 @@ static void __devinit vio_dev_release(struct device *dev)
 {
struct iommu_table *tbl = get_iommu_table_base(dev);
 
-   /* iSeries uses a common table for all vio devices */
-   if (!firmware_has_feature(FW_FEATURE_ISERIES) && tbl)
+   if (tbl)
iommu_free_table(tbl, dev->of_node ?
dev->of_node->full_name : dev_name(dev));
of_node_put(dev->of_node);
@@ -1244,12 +1234,6 @@ struct vio_dev *vio_register_device_node(struct 
device_node *of_node)
viodev->name = of_node->name;
viodev->type = of_node->type;
viodev->unit_address = *unit_address;
-   if (firmware_has_feature(FW_FEATURE_ISERIES)) {
-   unit_address = of_get_property(of_node,
-   "linux,unit_address", NULL);
-   if (unit_address != NULL)
-   viodev->unit_address = *unit_address;
-   }
viodev->dev.of_node = of_node_get(of_node);
 
if (firmware_has_feature(FW_FEATURE_CMO))
-- 
1.7.9.1

-- 
Cheers,
Stephen Rothwells...@canb.auug.org.au


pgpfhuYCPCGAT.pgp
Description: PGP signature
___
Linuxppc-dev mailing list
Linuxppc-dev@lists.ozlabs.org
https://lists.ozlabs.org/listinfo/linuxppc-dev

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

2012-03-07 Thread Benjamin Herrenschmidt
On Thu, 2012-03-08 at 14:51 +1100, Stephen Rothwell wrote:
> Hi Mikey,
> 
> On Thu, 08 Mar 2012 13:33:56 +1100 Michael Neuling  wrote:
> >
> > Surely we only need SPARSE_IRQ now and not MAY_HAVE_SPARSE_IRQ.  
> > 
> > In fact, keeping MAY_HAVE_SPARSE_IRQ seems to make SPARSE_IRQ user
> > selectable, which we don't want anymore since ad5b7f1350c2.
> 
> Yes, indeed. I will fix up the merge resolution for tomorrow.

This is my fault. Grant's patch had a collision and I manually fixed it
up. While doing that, I put back MAY_HAVE_SPARSE_IRQ which the patch
originally took out.

Cheers,
Ben.


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


RE: [PATCH v2] powerpc/srio: Fix the compile errors when building with 64bit

2012-03-07 Thread Liu Gang
Hi, David,

On Wed, 2012-03-07 at 13:18 +, David Laight wrote:  
> > pr_debug("RIO: fsl_add_outb_message(): destid %4.4x mbox %d
> buffer " \
> > -"%8.8x len %8.8x\n", rdev->destid, mbox, (int)buffer,
> len);
> > +"%8.8lx len %8.8zx\n", rdev->destid, mbox,
> > +   (unsigned long)buffer, len);
> 
> Should 'buffer' be printed with %p ??

Yes, printing with "%p" can get rid of the cast, although they have the
same print results.

Thanks a lot.

Liu Gang


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


Re: [PATCH 2/7] net: powerpc: remove the legacy iSeries ethernet driver

2012-03-07 Thread David Miller
From: Stephen Rothwell 
Date: Thu, 8 Mar 2012 15:33:53 +1100

> This driver is specific to the PowerPC legcay iSeries platform which is
> being removed.
> 
> Cc: David Miller 
> Cc: 
> Signed-off-by: Stephen Rothwell 

Acked-by: David S. Miller 
___
Linuxppc-dev mailing list
Linuxppc-dev@lists.ozlabs.org
https://lists.ozlabs.org/listinfo/linuxppc-dev


Re: [PATCH 0/7] powerpc: remove the legacy iSeries platform specific drivers

2012-03-07 Thread David Miller
From: Stephen Rothwell 
Date: Thu, 8 Mar 2012 15:28:53 +1100

> It would probably be easiest if all these patches were merged via the
> powerpc tree to eliminate any dependencies between them.  Their impact on
> generic code is very small.

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


RE: [PATCH 1/9] pci_ids: Add device ID for IBM PCI-X bridge

2012-03-07 Thread Zang Roy-R61911


> -Original Message-
> From: linuxppc-dev-bounces+tie-fei.zang=freescale@lists.ozlabs.org
> [mailto:linuxppc-dev-bounces+tie-fei.zang=freescale@lists.ozlabs.org]
> On Behalf Of Kumar Gala
> Sent: Tuesday, March 06, 2012 20:14 PM
> To: Zhao Chenhui-B35336
> Cc: linux-...@vger.kernel.org; linuxppc-dev@lists.ozlabs.org
> Subject: Re: [PATCH 1/9] pci_ids: Add device ID for IBM PCI-X bridge
> 
> 
> On Mar 6, 2012, at 3:05 AM, Zhao Chenhui wrote:
> 
> > Signed-off-by: Zhao Chenhui 
> > ---
> > include/linux/pci_ids.h |1 +
> > 1 files changed, 1 insertions(+), 0 deletions(-)
> 
> Just merge this with the 2nd patch that actually uses the ID.
Why does this necessary?
I'd prefer using a separate patch for the PCI ID.
Roy

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