* error: array type has incomplete element type
From: WEHBI Rami @ 2008-01-17 17:05 UTC (permalink / raw)
To: linuxppc-embedded
[-- Attachment #1: Type: text/plain, Size: 2331 bytes --]
Hi all,
I am trying to compile a kernel for the ppc405 embedded on the virtex 4 and I am obtaining the compiling errors listed below(at the end of this mail).
my compiler is the crosstool latest one.
I tried to compile each the following kernel versions :
2.6.23.8
2.6.17
with the following versions of gcc and glibc of the crosscompiler
gcc-4.0.2-glibc-2.3.5
gcc-4.1.0-glibc-2.3.6
gcc-4.1.1-glibc-2.3.6
the result is always the same (array type has incomplete element type)
moreover I searched all the files and I replaced
(struct ocp_def core_ocp[]) with (struct ocp_def core_ocp[2])
because my architectur contains only one UART, the result is always the same (same error).
any help is appreciated,
arch/ppc/syslib/virtex_devices.c:23: error: array type has incomplete element type
arch/ppc/syslib/virtex_devices.c:25: error: field name not in record or union initializer
arch/ppc/syslib/virtex_devices.c:25: error: (near initialization for 'core_ocp')
arch/ppc/syslib/virtex_devices.c:26: error: field name not in record or union initializer
arch/ppc/syslib/virtex_devices.c:26: error: (near initialization for 'core_ocp')
arch/ppc/syslib/virtex_devices.c:27: error: field name not in record or union initializer
arch/ppc/syslib/virtex_devices.c:27: error: (near initialization for 'core_ocp')
arch/ppc/syslib/virtex_devices.c:28: error: field name not in record or union initializer
arch/ppc/syslib/virtex_devices.c:28: error: (near initialization for 'core_ocp')
arch/ppc/syslib/virtex_devices.c:29: error: field name not in record or union initializer
arch/ppc/syslib/virtex_devices.c:29: error: (near initialization for 'core_ocp')
arch/ppc/syslib/virtex_devices.c:30: error: field name not in record or union initializer
arch/ppc/syslib/virtex_devices.c:30: error: (near initialization for 'core_ocp')
arch/ppc/syslib/virtex_devices.c:30: error: 'OCP_CPM_NA' undeclared here (not in a function)
arch/ppc/syslib/virtex_devices.c:63: error: field name not in record or union initializer
arch/ppc/syslib/virtex_devices.c:63: error: (near initialization for 'core_ocp')
Rami
---------------------------------
Ne gardez plus qu'une seule adresse mail ! Copiez vos mails vers Yahoo! Mail
[-- Attachment #2: Type: text/html, Size: 4588 bytes --]
^ permalink raw reply
* Re: [PATCH] [POWERPC] Update TQM5200, CM5200 and Motion-PRO _defconfig and .dts files
From: Grant Likely @ 2008-01-17 16:05 UTC (permalink / raw)
To: Marian Balakowicz; +Cc: linuxppc-dev
In-Reply-To: <20080117143024.15372.95923.stgit@hekate.izotz.org>
On 1/17/08, Marian Balakowicz <m8@semihalf.com> wrote:
> Updates include:
> - set soc node compatible property to "fsl,mpc5200-immr"
On these three boards; which have the original mpc5200 and which have
the mpc5200b?
I'm not going to pick up this patch immediately, I've got an invasive
set of mpc5200 device tree cleanups which need to go in first. After
that I'll revisit your changes here.
> - update i2c device tree nodes
> - add mdio node
> - add lpb bus node and flash device (without partitions defined)
> - add second mscan node for Motio-PRO
> - add rtc i2c nodes and enable RTC in _defconfigs
> - use SLUB insteand of SLAB
> - enable printk timestamp
Can you split the defconfig changes into a separate patch... That
being said, how do you feel about merging all the 5200 defconfigs into
a single defconfig? They are all multiplatform after all and it would
make maintenance easier.
Cheers,
g.
--
Grant Likely, B.Sc., P.Eng.
Secret Lab Technologies Ltd.
^ permalink raw reply
* Re: Patches added to master/for-2.6.25 branch of powerpc.git
From: Grant Likely @ 2008-01-17 15:52 UTC (permalink / raw)
To: Paul Mackerras; +Cc: linuxppc-dev
In-Reply-To: <18318.56299.476711.644917@cargo.ozlabs.ibm.com>
Paul, can you also please pull the following 52xx changes?
Thanks,
g.
The following changes since commit 52920df4aa9dd25836b8ed4dc0b177ea14c09e53:
Paul Mackerras (1):
Merge branch 'for-2.6.25' of
master.kernel.org:/.../olof/pasemi into for-2.6.25
are available in the git repository at:
git://git.secretlab.ca/git/linux-2.6-mpc52xx.git for-2.6.25
Grant Likely (1):
[POWERPC] mpc5200: eliminate mpc52xx_*_map_*() functions.
Marian Balakowicz (9):
Add 'fsl, lpb' bus type for MPC5200 LocalPlus Bus
Add common mpc52xx_setup_pci() routine
TQM5200 DTS
TQM5200 defconfig
CM5200 DTS
CM5200 defconfig
Promess Motion-PRO DTS
Promess Motion-PRO defconfig
Add generic support for simple MPC5200 based boards
arch/powerpc/boot/dts/cm5200.dts | 236 +++++
arch/powerpc/boot/dts/lite5200.dts | 2 +-
arch/powerpc/boot/dts/lite5200b.dts | 2 +-
arch/powerpc/boot/dts/motionpro.dts | 309 ++++++
arch/powerpc/boot/dts/tqm5200.dts | 184 ++++
arch/powerpc/configs/cm5200_defconfig | 1031 ++++++++++++++++++++
arch/powerpc/configs/motionpro_defconfig | 989 +++++++++++++++++++
arch/powerpc/configs/tqm5200_defconfig | 1306 ++++++++++++++++++++++++++
arch/powerpc/platforms/52xx/Kconfig | 22 +-
arch/powerpc/platforms/52xx/Makefile | 1 +
arch/powerpc/platforms/52xx/lite5200.c | 22 +-
arch/powerpc/platforms/52xx/lite5200_pm.c | 6 +-
arch/powerpc/platforms/52xx/mpc5200_simple.c | 85 ++
arch/powerpc/platforms/52xx/mpc52xx_common.c | 63 +-
arch/powerpc/platforms/52xx/mpc52xx_pci.c | 14 +
arch/powerpc/platforms/52xx/mpc52xx_pic.c | 8 +-
arch/powerpc/platforms/52xx/mpc52xx_pm.c | 8 +-
drivers/spi/mpc52xx_psc_spi.c | 9 +-
include/asm-powerpc/mpc52xx.h | 7 +-
19 files changed, 4234 insertions(+), 70 deletions(-)
create mode 100644 arch/powerpc/boot/dts/cm5200.dts
create mode 100644 arch/powerpc/boot/dts/motionpro.dts
create mode 100644 arch/powerpc/boot/dts/tqm5200.dts
create mode 100644 arch/powerpc/configs/cm5200_defconfig
create mode 100644 arch/powerpc/configs/motionpro_defconfig
create mode 100644 arch/powerpc/configs/tqm5200_defconfig
create mode 100644 arch/powerpc/platforms/52xx/mpc5200_simple.c
--
Grant Likely, B.Sc., P.Eng.
Secret Lab Technologies Ltd.
^ permalink raw reply
* Re: Patches added to master/for-2.6.25 branch of powerpc.git
From: Anton Vorontsov @ 2008-01-17 15:34 UTC (permalink / raw)
To: Kumar Gala; +Cc: linuxppc-dev list, Paul Mackerras
In-Reply-To: <A1DA2145-E5AE-4A7D-83D4-D86F05A9F6DF@kernel.crashing.org>
On Thu, Jan 17, 2008 at 09:11:00AM -0600, Kumar Gala wrote:
>
> On Jan 17, 2008, at 8:59 AM, Anton Vorontsov wrote:
>
> >Hello Paul, Kumar,
> >
> >On Thu, Jan 17, 2008 at 03:39:07PM +1100, Paul Mackerras wrote:
> >>Includes commits pulled from Josh Boyer's tree.
> >
> >Um.. Probably I'm being importunate.. if so, just command me to sit
> >silent and wait. ;-) But how about these down here? Ones that touches
> >drivers/net/ are having "Acked-by: Jeff Garzik <jeff@garzik.org>"
> >thus meant to go through one of powerpc tree. Not sure through which
> >one exactly.
> >
> >http://ozlabs.org/pipermail/linuxppc-dev/2007-December/047777.html
> >http://ozlabs.org/pipermail/linuxppc-dev/2007-December/047778.html
> >http://ozlabs.org/pipermail/linuxppc-dev/2007-December/047779.html
> >
> >^^ are mandatory to make MPC8349E-mITX's ENET1-ENET5 actually work.
> >Plus, as you may notice all of them having "777" in the message id,
> >they ought to be lucky, despite that today they're applying with
> >fuzz. :-)
>
> I've got these in my queue to apply.
Great, good to know. Thanks.
> If I have issues I'll ping you for a respin.
Sure thing.
> >http://ozlabs.org/pipermail/linuxppc-dev/2007-December/048473.html
> >
> >^^ fixed phy support for fs_enet. Needed for some other boards, I
> >presume.
>
> Hmm, its vitaly picking this one up? if not I can.
Ah, right. I just forgot that Vitaly resumed his tree.
Thanks,
--
Anton Vorontsov
email: cbou@mail.ru
backup email: ya-cbou@yandex.ru
irc://irc.freenode.net/bd2
^ permalink raw reply
* Re: [PATCH/RFCv2] wdt: Add support for PowerQUICC watchdog
From: Kumar Gala @ 2008-01-17 15:11 UTC (permalink / raw)
To: Jochen Friedrich; +Cc: Scott Wood, linuxppc-dev, wim, linux-kernel
In-Reply-To: <478F6C5F.4010505@scram.de>
On Jan 17, 2008, at 8:55 AM, Jochen Friedrich wrote:
> Hi Kumar,
>
>> Why are you commenting on mpc83xx_wdt with respect to pq1_wdt?
>> Also, is this driver just for PQ1 platforms or PQ1 & PQ2? If its
>> just pq1 we should probably call it pq1_wdt*
>
> It should be for pq1, pq2 and pq2pro. However, i only have the
> possibility
> to test this on pq1.
>
>>> arch/powerpc/platforms/8xx/mpc86xads_setup.c | 5 +
>>> arch/powerpc/platforms/8xx/mpc885ads_setup.c | 5 +
>>> arch/powerpc/sysdev/Makefile | 3 +
>>> arch/powerpc/sysdev/pq_wdt.c | 203 +++++++++++++++
>>> ++++++++
>>> arch/powerpc/sysdev/pq_wdt.h | 28 ++++
>>> drivers/watchdog/Kconfig | 13 ++-
>>> drivers/watchdog/Makefile | 1 +
>>> drivers/watchdog/pq_wdt.c | 225 +++++++++++++++
>>> +++++++++++
>>> 8 files changed, 482 insertions(+), 1 deletions(-)
>>> create mode 100644 arch/powerpc/sysdev/pq_wdt.c
>>> create mode 100644 arch/powerpc/sysdev/pq_wdt.h
>>> create mode 100644 drivers/watchdog/pq_wdt.c
>> What are the bits in sysdev/pq_wdt.{c,h}. Why aren't these just in
>> drivers/watchdog?
>
> These are the parts needed to boot a device with activated watchdog.
> If a bootloader like u-boot activates the watchdog, it can't be
> deactivated again
> and needs to be reset at regular intervals. This is done using a
> kernel timer.
> The driver in drivers/watchdog disables the timer as soon as the wdt
> device
> is opened.
Ok, but is there a need for these bits to be in sysdev vs just being
in the driver and calling into it.
- k
^ permalink raw reply
* Re: Patches added to master/for-2.6.25 branch of powerpc.git
From: Kumar Gala @ 2008-01-17 15:11 UTC (permalink / raw)
To: avorontsov; +Cc: linuxppc-dev list, Paul Mackerras
In-Reply-To: <20080117145903.GA4535@localhost.localdomain>
On Jan 17, 2008, at 8:59 AM, Anton Vorontsov wrote:
> Hello Paul, Kumar,
>
> On Thu, Jan 17, 2008 at 03:39:07PM +1100, Paul Mackerras wrote:
>> Includes commits pulled from Josh Boyer's tree.
>
> Um.. Probably I'm being importunate.. if so, just command me to sit
> silent and wait. ;-) But how about these down here? Ones that touches
> drivers/net/ are having "Acked-by: Jeff Garzik <jeff@garzik.org>"
> thus meant to go through one of powerpc tree. Not sure through which
> one exactly.
>
> http://ozlabs.org/pipermail/linuxppc-dev/2007-December/047777.html
> http://ozlabs.org/pipermail/linuxppc-dev/2007-December/047778.html
> http://ozlabs.org/pipermail/linuxppc-dev/2007-December/047779.html
>
> ^^ are mandatory to make MPC8349E-mITX's ENET1-ENET5 actually work.
> Plus, as you may notice all of them having "777" in the message id,
> they ought to be lucky, despite that today they're applying with
> fuzz. :-)
I've got these in my queue to apply. If I have issues I'll ping you
for a respin.
> http://ozlabs.org/pipermail/linuxppc-dev/2007-December/048473.html
>
> ^^ fixed phy support for fs_enet. Needed for some other boards, I
> presume.
Hmm, its vitaly picking this one up? if not I can.
- k
^ permalink raw reply
* Re: Endian problem when accessing internel regs on 8347
From: Ben Warren @ 2008-01-17 15:01 UTC (permalink / raw)
To: Bruce_Leonard; +Cc: linuxppc-embedded
In-Reply-To: <OF03A8BF8B.4AC46CCD-ON882573D3.00216F5B-882573D3.00236B8D@selinc.com>
[-- Attachment #1: Type: text/plain, Size: 2065 bytes --]
Hi Bruce,
Bruce_Leonard@selinc.com wrote:
> Hi,
>
> I've got an MPC8347 running the 2.6.24-rc5 kernel and I'm trying to access
> the GPIO registers. I already have a driver that's doing related work
> (tho across PCI) and I just want to remap the internal CPU address to a
> kernal address and be able to read/write the register using an IOCTL call
> from user space. My problem is, every accessor I try does an endian
> conversion before giving me my data. So here's some code snipits of what
> I'm doing:
>
> request_mem_region(0xe0000c00, 24, "my driver"); // 0xe0000c00 is the
> memory mapped location of the GPIO regs
> data_ptr2 = ioremap(0xe0000c00, 24);
>
> Then in the IOCTL function I try to read from the register. First I
> tried:
>
> ioread32(data_ptr2);
>
> I know that the mapping is working okay because I got the data from the
> GPIO direction register, but it's been byte swapped. The contents of the
> register are 0xFFFFFFE7, but what my user space app gets back is
> 0xE7FFFFFF. I've tried all the varients I can find, readl(), inl(),
> in_be32(), in_le32(), even __raw_readl(). They all give me back byte
> swapped data. I'm very confused. Especially since I've looked at
> in_be32() and in_le32(), they're both inline assembly, and they use
> different instructions. They can't be giving me the same results. I'm
> sure I'm not the first person to want to access PowerPC internal registers
> through a driver. Can anyone give me a hint what I'm doing wrong?
>
> As an additional question related to PowerPC inline assembly, can anyone
> tell me what "%U1%X1" means in the following:
>
> __asm__ __volatile__("lwz%U1%X1 %0,%1; twi 0,%0,0; isync" : "=r" (ret) :
> "m" (*addr));
>
> Thanks.
>
> See 'ya!
>
> Bruce
> _______________________________________________
>
I've attached a poorly-written-yet-functional GPIO driver that I wrote a
while ago for the MPC8349 (same as what you have for all intents and
purposes). It uses in_be32() and out_be32().
Let me know if you have any questions.
regards,
Ben
[-- Attachment #2: mpc83xx_gpio.c --]
[-- Type: text/x-csrc, Size: 6289 bytes --]
/******************************************************************************
*
* gpio_driver.c
* Copyright Qstreams Networks 2006
*
* This file contains a simple Linux device driver for accessing GPIO ports
* It is originally targeted for the MPC8349 PowerQUICC II Pro processor,
* although with simple modifications it should work with lots of CPUs. Note
* that all CPU accesses are big-endian.
*
* History:
* 04/11/2006 BAW Initial Creation
*
*****************************************************************************/
#include <linux/init.h>
#include <linux/module.h>
#include <linux/ioport.h>
#include <linux/fs.h>
#include <linux/cdev.h>
#include <asm/io.h>
#include <asm/uaccess.h>
#include "gpio.h"
struct gpio_dev {
struct gpio_reg *regs;
struct cdev cdev;
};
MODULE_AUTHOR("Ben Warren");
MODULE_LICENSE("GPL");
static int gpio_major_num;
static struct gpio_dev *gpio_devices;
static spinlock_t gpioLock[GPIO_NUM_BANKS];
extern phys_addr_t get_immrbase(void);
static u32 readGpioReg(u8 bank, u32 * addr)
{
u32 value;
spin_lock(&gpioLock[bank]);
value = in_be32(addr);
spin_unlock(&gpioLock[bank]);
return value;
}
static void writeGpioReg(u8 bank, u32 * addr, u32 val, u32 mask)
{
spin_lock(&gpioLock[bank]);
out_be32(addr, (in_be32(addr) & ~mask) | val);
spin_unlock(&gpioLock[bank]);
}
/*****
* Kernel-mode GPIO access functions.
* DO NOT CALL FROM USERSPACE
*****/
int kgpio_set_dir(u8 bank, u8 bit, u8 isOutput)
{
u32 value = GPIO_BIT(bit);
if ((bank >= GPIO_NUM_BANKS) || !gpio_devices) {
return -ENODEV;
}
writeGpioReg(bank, &gpio_devices[bank].regs->gpxdir,
isOutput ? value : 0, value);
return 0;
}
EXPORT_SYMBOL(kgpio_set_dir);
int kgpio_get_dir(u8 bank, u8 bit)
{
u32 value;
if ((bank >= GPIO_NUM_BANKS) || !gpio_devices) {
return -ENODEV;
}
value = readGpioReg(bank, &gpio_devices[bank].regs->gpxdir);
return (value & GPIO_BIT(bit) ? 1 : 0);
}
EXPORT_SYMBOL(kgpio_get_dir);
int kgpio_set_data(u8 bank, u8 bit, u8 isHigh)
{
u32 value = GPIO_BIT(bit);
if ((bank >= GPIO_NUM_BANKS) || !gpio_devices) {
return -ENODEV;
}
writeGpioReg(bank, &gpio_devices[bank].regs->gpxdat,
isHigh ? value : 0, value);
return 0;
}
EXPORT_SYMBOL(kgpio_set_data);
int kgpio_get_data(u8 bank, u8 bit)
{
u32 value;
if ((bank >= GPIO_NUM_BANKS) || !gpio_devices) {
return -ENODEV;
}
value = readGpioReg(bank, &gpio_devices[bank].regs->gpxdat);
return (value & GPIO_BIT(bit) ? 1 : 0);
}
EXPORT_SYMBOL(kgpio_get_data);
int gpio_open(struct inode *inode, struct file *filp)
{
struct gpio_dev *dev;
/* Set things up so other methods can access private data */
dev = container_of(inode->i_cdev, struct gpio_dev, cdev);
filp->private_data = dev;
return 0;
}
int gpio_ioctl(struct inode *inode, struct file *filp,
unsigned int cmd, unsigned long arg)
{
int rc = 0;
gpioDataAccess gpioData = { 0, 0 };
struct gpio_dev *dev;
u8 bank;
/* Check that the caller really wanted GPIO */
if (_IOC_TYPE(cmd) != GPIO_IOC_MAGIC)
return -ENOTTY;
if (_IOC_NR(cmd) > GPIO_IOC_MAXNR)
return -ENOTTY;
/* Check access controls */
if (_IOC_DIR(cmd) & _IOC_READ)
rc = !access_ok(VERIFY_WRITE, (void __user *)arg,
_IOC_SIZE(cmd));
else if (_IOC_DIR(cmd) & _IOC_WRITE)
rc = !access_ok(VERIFY_READ, (void __user *)arg,
_IOC_SIZE(cmd));
if (rc)
return -EFAULT;
bank = (u8) iminor(inode);
dev = filp->private_data;
switch (cmd) {
/* Direction Register access */
case GPIO_IOC_GET_DIR:
return readGpioReg(bank, &dev->regs->gpxdir);
case GPIO_IOC_SET_DIR:
if (copy_from_user(&gpioData,
(const void __user *)arg,
sizeof(gpioDataAccess))) {
printk(KERN_ERR "copy_from_user failed\n");
return -EFAULT;
}
writeGpioReg(bank, &dev->regs->gpxdir,
gpioData.value, gpioData.mask);
break;
/* Data Register access */
case GPIO_IOC_GET_DATA:
return readGpioReg(bank, &dev->regs->gpxdat);
case GPIO_IOC_SET_DATA:
if (copy_from_user(&gpioData,
(const void __user *)arg,
sizeof(gpioDataAccess))) {
printk(KERN_ERR "copy_from_user failed\n");
return -EFAULT;
}
writeGpioReg(bank, &dev->regs->gpxdat,
gpioData.value, gpioData.mask);
break;
default:
return -ENOTTY;
}
return rc;
}
/* File operations structure. Pretty limited on this device */
struct file_operations gpio_fops = {
.owner = THIS_MODULE,
.open = gpio_open,
.ioctl = gpio_ioctl,
};
static void gpio_cleanup(void)
{
int i;
u32 addr;
dev_t devno = MKDEV(gpio_major_num, 0);
if (gpio_devices) {
for (i = 0; i < GPIO_NUM_BANKS; i++) {
cdev_del(&gpio_devices[i].cdev);
}
iounmap(gpio_devices);
}
addr = get_immrbase() + GPIO1_IO_OFFSET;
release_mem_region(addr, sizeof(struct gpio_reg));
addr = get_immrbase() + GPIO2_IO_OFFSET;
release_mem_region(addr, sizeof(struct gpio_reg));
unregister_chrdev_region(devno, GPIO_NUM_BANKS);
}
static void gpio_setup_cdev(struct gpio_dev *dev, int index)
{
int rc, devno = MKDEV(gpio_major_num, index);
cdev_init(&dev->cdev, &gpio_fops);
dev->cdev.owner = THIS_MODULE;
dev->cdev.ops = &gpio_fops;
if ((rc = cdev_add(&dev->cdev, devno, 1)))
printk(KERN_CRIT "Error %d adding gpio%d", rc, index);
}
static int gpio_init(void)
{
int i, rc;
dev_t dev = 0;
u32 addr;
/* Grab a dynamic major number and GPIO_NUM_BANKS minors */
rc = alloc_chrdev_region(&dev, 0, GPIO_NUM_BANKS, "gpio");
gpio_major_num = MAJOR(dev);
if (rc < 0) {
printk(KERN_CRIT "GPIO: couldn't get major number\n");
return rc;
}
if (!(gpio_devices = kmalloc(GPIO_NUM_BANKS * sizeof(struct gpio_dev),
GFP_KERNEL))) {
gpio_cleanup();
return -ENOMEM;
}
for (i = 0; i < GPIO_NUM_BANKS; i++) {
spin_lock_init(&gpioLock[i]);
gpio_setup_cdev(&gpio_devices[i], i);
addr =
get_immrbase() + (i ==
0 ? GPIO1_IO_OFFSET : GPIO2_IO_OFFSET);
if (!request_mem_region(addr,
sizeof(struct gpio_reg), "gpio")) {
printk(KERN_CRIT "gpio: I/O memory request failed\n");
return -ENODEV;
}
gpio_devices[i].regs = (struct gpio_reg *)ioremap_nocache(addr,
sizeof (struct gpio_reg));
if (!gpio_devices[i].regs) {
printk(KERN_CRIT "gpio: can't remap I/O memory\n");
return -ENODEV;
}
}
return 0;
}
module_init(gpio_init);
module_exit(gpio_cleanup);
[-- Attachment #3: gpio.h --]
[-- Type: text/x-chdr, Size: 829 bytes --]
#ifndef GPIO_INCLUDE_H
#define GPIO_INCLUDE_H
#include <asm/ioctl.h>
#define GPIO1_IO_OFFSET 0x00000c00
#define GPIO2_IO_OFFSET 0x00000d00
typedef struct _gpioDatAccess
{
unsigned int value;
unsigned int mask;
} gpioDataAccess;
#define GPIO_IOC_MAGIC 0xaa
#define GPIO_IOC_GET_DIR _IO(GPIO_IOC_MAGIC, 1)
#define GPIO_IOC_SET_DIR _IOW(GPIO_IOC_MAGIC, 2, gpioDataAccess)
#define GPIO_IOC_GET_DATA _IO(GPIO_IOC_MAGIC, 3)
#define GPIO_IOC_SET_DATA _IOW(GPIO_IOC_MAGIC, 4, gpioDataAccess)
#define GPIO_IOC_MAXNR 5
#define GPIO_NUM_BANKS 2
struct gpio_reg
{
unsigned int gpxdir;
unsigned int gpxdr;
unsigned int gpxdat;
unsigned int gpxier;
unsigned int gpximr;
unsigned int gpxicr;
};
/* On our CPU, bit 0 is the MS bit, so go from the left */
#define GPIO_BIT(x) (0x80000000 >> (x))
#endif /* GPIO_INCLUDE_H */
^ permalink raw reply
* Re: Patches added to master/for-2.6.25 branch of powerpc.git
From: Marian Balakowicz @ 2008-01-17 15:01 UTC (permalink / raw)
To: Paul Mackerras; +Cc: linuxppc-dev
In-Reply-To: <18318.56299.476711.644917@cargo.ozlabs.ibm.com>
Hi,
Paul Mackerras wrote:
> Includes commits pulled from Josh Boyer's tree.
>
Will you be willing to pick up this one? It's a generic powerpc patch,
so I'm not sure where else to direct it.
[POWERPC] Add 'model: ...' line to common show_cpuinfo()
http://patchwork.ozlabs.org/linuxppc/patch?id=14661
Thanks,
m.
^ permalink raw reply
* Re: [PATCH/RFCv2] wdt: Add support for PowerQUICC watchdog
From: Jochen Friedrich @ 2008-01-17 14:55 UTC (permalink / raw)
To: Kumar Gala; +Cc: Scott Wood, linuxppc-dev, wim, linux-kernel
In-Reply-To: <A00FB5AE-903B-461A-B234-4BA817B3C5CB@kernel.crashing.org>
Hi Kumar,
> Why are you commenting on mpc83xx_wdt with respect to pq1_wdt?
>
> Also, is this driver just for PQ1 platforms or PQ1 & PQ2? If its just
> pq1 we should probably call it pq1_wdt*
It should be for pq1, pq2 and pq2pro. However, i only have the possibility
to test this on pq1.
>> arch/powerpc/platforms/8xx/mpc86xads_setup.c | 5 +
>> arch/powerpc/platforms/8xx/mpc885ads_setup.c | 5 +
>> arch/powerpc/sysdev/Makefile | 3 +
>> arch/powerpc/sysdev/pq_wdt.c | 203
>> +++++++++++++++++++++++
>> arch/powerpc/sysdev/pq_wdt.h | 28 ++++
>> drivers/watchdog/Kconfig | 13 ++-
>> drivers/watchdog/Makefile | 1 +
>> drivers/watchdog/pq_wdt.c | 225
>> ++++++++++++++++++++++++++
>> 8 files changed, 482 insertions(+), 1 deletions(-)
>> create mode 100644 arch/powerpc/sysdev/pq_wdt.c
>> create mode 100644 arch/powerpc/sysdev/pq_wdt.h
>> create mode 100644 drivers/watchdog/pq_wdt.c
>
> What are the bits in sysdev/pq_wdt.{c,h}. Why aren't these just in
> drivers/watchdog?
These are the parts needed to boot a device with activated watchdog. If a
bootloader like u-boot activates the watchdog, it can't be deactivated again
and needs to be reset at regular intervals. This is done using a kernel timer.
The driver in drivers/watchdog disables the timer as soon as the wdt device
is opened.
Thanks,
Jochen
^ permalink raw reply
* Re: Patches added to master/for-2.6.25 branch of powerpc.git
From: Anton Vorontsov @ 2008-01-17 14:59 UTC (permalink / raw)
To: Paul Mackerras; +Cc: linuxppc-dev
In-Reply-To: <18318.56299.476711.644917@cargo.ozlabs.ibm.com>
Hello Paul, Kumar,
On Thu, Jan 17, 2008 at 03:39:07PM +1100, Paul Mackerras wrote:
> Includes commits pulled from Josh Boyer's tree.
Um.. Probably I'm being importunate.. if so, just command me to sit
silent and wait. ;-) But how about these down here? Ones that touches
drivers/net/ are having "Acked-by: Jeff Garzik <jeff@garzik.org>"
thus meant to go through one of powerpc tree. Not sure through which
one exactly.
http://ozlabs.org/pipermail/linuxppc-dev/2007-December/047777.html
http://ozlabs.org/pipermail/linuxppc-dev/2007-December/047778.html
http://ozlabs.org/pipermail/linuxppc-dev/2007-December/047779.html
^^ are mandatory to make MPC8349E-mITX's ENET1-ENET5 actually work.
Plus, as you may notice all of them having "777" in the message id,
they ought to be lucky, despite that today they're applying with
fuzz. :-)
http://ozlabs.org/pipermail/linuxppc-dev/2007-December/048473.html
^^ fixed phy support for fs_enet. Needed for some other boards, I
presume.
Thanks!
--
Anton Vorontsov
email: cbou@mail.ru
backup email: ya-cbou@yandex.ru
irc://irc.freenode.net/bd2
^ permalink raw reply
* Re: [patch 06/18] PS3: Fix kexec storage probe
From: Geert Uytterhoeven @ 2008-01-17 14:44 UTC (permalink / raw)
To: Geoff Levand; +Cc: linuxppc-dev, paulus
In-Reply-To: <20080116235154.946247739@am.sony.com>
[-- Attachment #1: Type: TEXT/PLAIN, Size: 1275 bytes --]
On Wed, 16 Jan 2008, geoffrey.levand@am.sony.com wrote:
> From: Geert Uytterhoeven <Geert.Uytterhoeven@sonycom.com>
>
> The PS3 storage probe thread left the storage notification device open on
> shutdown, so the device open would fail with LV1_BUSY when the second stage
> kexec kernel tried to open the device.
>
> To fix this:
> - Replace the call to wait_for_completion_interruptible() by a call to
> wait_event_interruptible() that also checks kthread_should_stop(),
> - Install a reboot notifier that stops the storage probe thread on shutdown.
Actually I had planned to fold this into `[patch 05/18] PS3: Use the HVs
storage device notification mechanism properly'.
With kind regards,
Geert Uytterhoeven
Software Architect
Sony Network and Software Technology Center Europe
The Corporate Village · Da Vincilaan 7-D1 · B-1935 Zaventem · Belgium
Phone: +32 (0)2 700 8453
Fax: +32 (0)2 700 8622
E-mail: Geert.Uytterhoeven@sonycom.com
Internet: http://www.sony-europe.com/
Sony Network and Software Technology Center Europe
A division of Sony Service Centre (Europe) N.V.
Registered office: Technologielaan 7 · B-1840 Londerzeel · Belgium
VAT BE 0413.825.160 · RPR Brussels
Fortis Bank Zaventem · Swift GEBABEBB08A · IBAN BE39001382358619
^ permalink raw reply
* Re: [PATCH/RFC] [POWERPC] CPM1: implement GPIO LIB API
From: Jochen Friedrich @ 2008-01-17 14:42 UTC (permalink / raw)
To: Grant Likely; +Cc: Arnd Bergmann, linuxppc-dev, David Gibson
In-Reply-To: <fa686aa40801170547q8c758dxef5aa301396f7f38@mail.gmail.com>
Hi Grant,
>> arch/powerpc/platforms/8xx/Kconfig | 2 +
>> arch/powerpc/sysdev/commproc.c | 162 +++++++++++++++++++++++++++++++++++-
>
> Is this 8xx only? Can it live in arch/powerpc/platforms/8xx?
According to the freescale docs, the GPIO ports are part of the CPM1. So I've put the
support into commproc.c (which maybe should be renamed to cpm1_common.c to match cpm2_common.c).
AFAIK, CPM1 is specific to 8xx.
Thanks,
Jochen
^ permalink raw reply
* Re: [PATCH/RFCv2] wdt: Add support for PowerQUICC watchdog
From: Kumar Gala @ 2008-01-17 14:31 UTC (permalink / raw)
To: Jochen Friedrich; +Cc: Scott Wood, linuxppc-dev, wim, linux-kernel
In-Reply-To: <478F4E4A.4060907@scram.de>
On Jan 17, 2008, at 6:47 AM, Jochen Friedrich wrote:
> The PowerQUICC series has a watchdog which can be activated by the
> boot
> loader and then needs to be reset in regular intervals. Once the
> watchdog is enabled, it can't be disabled anymore. This patch adds
> support for this kind of watchdog. An early init function is
> provided to
> manually reset the watchdog in early board setup. Later, a kernel
> timer
> is used to reset the watchdog until the watchdog driver is opened from
> user space. This replaces mpc8xx_wdt.c (only usable for ARCH=ppc) and
> mpc83xx_wdt.c (untested on this platform).
Why are you commenting on mpc83xx_wdt with respect to pq1_wdt?
Also, is this driver just for PQ1 platforms or PQ1 & PQ2? If its just
pq1 we should probably call it pq1_wdt*
> Signed-off-by: Jochen Friedrich <jochen@scram.de>
> ---
> arch/powerpc/platforms/8xx/mpc86xads_setup.c | 5 +
> arch/powerpc/platforms/8xx/mpc885ads_setup.c | 5 +
> arch/powerpc/sysdev/Makefile | 3 +
> arch/powerpc/sysdev/pq_wdt.c | 203 +++++++++++++++++
> ++++++
> arch/powerpc/sysdev/pq_wdt.h | 28 ++++
> drivers/watchdog/Kconfig | 13 ++-
> drivers/watchdog/Makefile | 1 +
> drivers/watchdog/pq_wdt.c | 225 +++++++++++++++++
> +++++++++
> 8 files changed, 482 insertions(+), 1 deletions(-)
> create mode 100644 arch/powerpc/sysdev/pq_wdt.c
> create mode 100644 arch/powerpc/sysdev/pq_wdt.h
> create mode 100644 drivers/watchdog/pq_wdt.c
What are the bits in sysdev/pq_wdt.{c,h}. Why aren't these just in
drivers/watchdog?
- k
^ permalink raw reply
* Re: crash in kmem_cache_init
From: Christoph Lameter @ 2008-01-17 14:30 UTC (permalink / raw)
To: Pekka Enberg; +Cc: linuxppc-dev, Olaf Hering, linux-kernel, Linux MM
In-Reply-To: <84144f020801170414q7d408a74uf47a84b777c36a4a@mail.gmail.com>
On Thu, 17 Jan 2008, Pekka Enberg wrote:
> Looks similar to the one discussed on linux-mm ("[BUG] at
> mm/slab.c:3320" thread). Christoph?
Right. Try the latest version of the patch to fix it:
Index: linux-2.6/mm/slab.c
===================================================================
--- linux-2.6.orig/mm/slab.c 2008-01-03 12:26:42.000000000 -0800
+++ linux-2.6/mm/slab.c 2008-01-09 15:59:49.000000000 -0800
@@ -2977,7 +2977,10 @@ retry:
}
l3 = cachep->nodelists[node];
- BUG_ON(ac->avail > 0 || !l3);
+ if (!l3)
+ return NULL;
+
+ BUG_ON(ac->avail > 0);
spin_lock(&l3->list_lock);
/* See if we can refill from the shared array */
@@ -3224,7 +3227,7 @@ static void *alternate_node_alloc(struct
nid_alloc = cpuset_mem_spread_node();
else if (current->mempolicy)
nid_alloc = slab_node(current->mempolicy);
- if (nid_alloc != nid_here)
+ if (nid_alloc != nid_here && node_state(nid_alloc, N_NORMAL_MEMORY))
return ____cache_alloc_node(cachep, flags, nid_alloc);
return NULL;
}
@@ -3439,8 +3442,14 @@ __do_cache_alloc(struct kmem_cache *cach
* We may just have run out of memory on the local node.
* ____cache_alloc_node() knows how to locate memory on other nodes
*/
- if (!objp)
- objp = ____cache_alloc_node(cache, flags, numa_node_id());
+ if (!objp) {
+ int node_id = numa_node_id();
+ if (likely(cache->nodelists[node_id])) /* fast path */
+ objp = ____cache_alloc_node(cache, flags, node_id);
+ else /* this function can do good fallback */
+ objp = __cache_alloc_node(cache, flags, node_id,
+ __builtin_return_address(0));
+ }
out:
return objp;
^ permalink raw reply
* [PATCH] [POWERPC] Update TQM5200, CM5200 and Motion-PRO _defconfig and .dts files
From: Marian Balakowicz @ 2008-01-17 14:31 UTC (permalink / raw)
To: linuxppc-dev
Updates include:
- set soc node compatible property to "fsl,mpc5200-immr"
- update i2c device tree nodes
- add mdio node
- add lpb bus node and flash device (without partitions defined)
- add second mscan node for Motio-PRO
- add rtc i2c nodes and enable RTC in _defconfigs
- use SLUB insteand of SLAB
- enable printk timestamp
Signed-off-by: Marian Balakowicz <m8@semihalf.com>
---
This patch was applied and tested against:
git://git.secretlab.ca/git/linux-2.6-mpc52xx.git#for-2.6.25
arch/powerpc/boot/dts/cm5200.dts | 40 +++++++
arch/powerpc/boot/dts/motionpro.dts | 49 ++++++++-
arch/powerpc/boot/dts/tqm5200.dts | 45 ++++++++
arch/powerpc/configs/cm5200_defconfig | 53 ++++------
arch/powerpc/configs/motionpro_defconfig | 161 ++++++++++++++----------------
arch/powerpc/configs/tqm5200_defconfig | 91 ++++++++---------
6 files changed, 263 insertions(+), 176 deletions(-)
diff --git a/arch/powerpc/boot/dts/cm5200.dts b/arch/powerpc/boot/dts/cm5200.dts
index 9295083..ff01478 100644
--- a/arch/powerpc/boot/dts/cm5200.dts
+++ b/arch/powerpc/boot/dts/cm5200.dts
@@ -46,7 +46,7 @@
soc5200@f0000000 {
model = "fsl,mpc5200b";
- compatible = "fsl,mpc5200b";
+ compatible = "fsl,mpc5200-immr";
revision = ""; // from bootloader
device_type = "soc";
ranges = <0 f0000000 0000c000>;
@@ -214,13 +214,31 @@
ethernet@3000 {
device_type = "network";
compatible = "mpc5200b-fec","mpc5200-fec";
- reg = <3000 800>;
+ reg = <3000 400>;
local-mac-address = [ 00 00 00 00 00 00 ]; /* Filled in by U-Boot */
interrupts = <2 5 0>;
interrupt-parent = <&mpc5200_pic>;
+ phy-handle = <&phy0>;
+ };
+
+ mdio@3000 {
+ #address-cells = <1>;
+ #size-cells = <0>;
+ device_type = "mdio";
+ compatible = "mpc5200b-fec-phy";
+ reg = <3000 400>; // fec range, since we need to setup fec interrupts
+ interrupts = <2 5 0>; // these are for "mii command finished", not link changes & co.
+ interrupt-parent = <&mpc5200_pic>;
+
+ phy0:ethernet-phy@0 {
+ device_type = "ethernet-phy";
+ reg = <0>;
+ };
};
i2c@3d40 {
+ #address-cells = <1>;
+ #size-cells = <0>;
compatible = "mpc5200b-i2c","mpc5200-i2c","fsl-i2c";
reg = <3d40 40>;
interrupts = <2 10 0>;
@@ -233,4 +251,22 @@
reg = <8000 4000>;
};
};
+
+ lpb {
+ model = "fsl,lpb";
+ compatible = "fsl,lpb";
+ #address-cells = <2>;
+ #size-cells = <1>;
+ ranges = <0 0 fc000000 2000000>;
+
+ // 16-bit flash device at LocalPlus Bus CS0
+ flash@0,0 {
+ compatible = "cfi-flash";
+ reg = <0 0 2000000>;
+ bank-width = <2>;
+ device-width = <2>;
+ #size-cells = <1>;
+ #address-cells = <1>;
+ };
+ };
};
diff --git a/arch/powerpc/boot/dts/motionpro.dts b/arch/powerpc/boot/dts/motionpro.dts
index d8c316a..1a046aa 100644
--- a/arch/powerpc/boot/dts/motionpro.dts
+++ b/arch/powerpc/boot/dts/motionpro.dts
@@ -46,7 +46,7 @@
soc5200@f0000000 {
model = "fsl,mpc5200b";
- compatible = "fsl,mpc5200b";
+ compatible = "fsl,mpc5200-immr";
revision = ""; // from bootloader
device_type = "soc";
ranges = <0 f0000000 0000c000>;
@@ -134,6 +134,13 @@
interrupt-parent = <&mpc5200_pic>;
};
+ mscan@900 {
+ compatible = "mpc5200b-mscan\0mpc5200-mscan";
+ interrupts = <2 11 0>;
+ interrupt-parent = <&mpc5200_pic>;
+ reg = <900 80>;
+ };
+
mscan@980 {
compatible = "mpc5200b-mscan","mpc5200-mscan";
interrupts = <2 12 0>;
@@ -155,7 +162,6 @@
interrupt-parent = <&mpc5200_pic>;
};
-
spi@f00 {
compatible = "mpc5200b-spi","mpc5200-spi";
reg = <f00 20>;
@@ -216,10 +222,26 @@
ethernet@3000 {
device_type = "network";
compatible = "mpc5200b-fec","mpc5200-fec";
- reg = <3000 800>;
+ reg = <3000 400>;
local-mac-address = [ 00 00 00 00 00 00 ]; /* Filled in by U-Boot */
interrupts = <2 5 0>;
interrupt-parent = <&mpc5200_pic>;
+ phy-handle = <&phy0>;
+ };
+
+ mdio@3000 {
+ #address-cells = <1>;
+ #size-cells = <0>;
+ device_type = "mdio";
+ compatible = "mpc5200b-fec-phy";
+ reg = <3000 400>; // fec range, since we need to setup fec interrupts
+ interrupts = <2 5 0>; // these are for "mii command finished", not link changes & co.
+ interrupt-parent = <&mpc5200_pic>;
+
+ phy0:ethernet-phy@0 {
+ device_type = "ethernet-phy";
+ reg = <0>;
+ };
};
ata@3a00 {
@@ -230,11 +252,19 @@
};
i2c@3d40 {
+ #address-cells = <1>;
+ #size-cells = <0>;
compatible = "mpc5200b-i2c","mpc5200-i2c","fsl-i2c";
reg = <3d40 40>;
interrupts = <2 10 0>;
interrupt-parent = <&mpc5200_pic>;
fsl5200-clocking;
+
+ rtc@68 {
+ device_type = "rtc";
+ compatible = "dallas,ds1339";
+ reg = <68>;
+ };
};
sram@8000 {
@@ -248,7 +278,8 @@
compatible = "fsl,lpb";
#address-cells = <2>;
#size-cells = <1>;
- ranges = <1 0 50000000 00010000
+ ranges = <0 0 ff000000 01000000
+ 1 0 50000000 00010000
2 0 50010000 00010000
3 0 50020000 00010000>;
@@ -279,6 +310,16 @@
compatible = "promess,pro_module_dio";
reg = <3 800 2>;
};
+
+ // 16-bit flash device at LocalPlus Bus CS0
+ flash@0,0 {
+ compatible = "cfi-flash";
+ reg = <0 0 01000000>;
+ bank-width = <2>;
+ device-width = <2>;
+ #size-cells = <1>;
+ #address-cells = <1>;
+ };
};
pci@f0000d00 {
diff --git a/arch/powerpc/boot/dts/tqm5200.dts b/arch/powerpc/boot/dts/tqm5200.dts
index 5017cec..54fb2a2 100644
--- a/arch/powerpc/boot/dts/tqm5200.dts
+++ b/arch/powerpc/boot/dts/tqm5200.dts
@@ -46,7 +46,7 @@
soc5200@f0000000 {
model = "fsl,mpc5200";
- compatible = "fsl,mpc5200";
+ compatible = "fsl,mpc5200-immr";
revision = ""; // from bootloader
device_type = "soc";
ranges = <0 f0000000 0000c000>;
@@ -134,10 +134,26 @@
ethernet@3000 {
device_type = "network";
compatible = "mpc5200-fec";
- reg = <3000 800>;
+ reg = <3000 400>;
local-mac-address = [ 00 00 00 00 00 00 ]; /* Filled in by U-Boot */
interrupts = <2 5 0>;
interrupt-parent = <&mpc5200_pic>;
+ phy-handle = <&phy0>;
+ };
+
+ mdio@3000 {
+ #address-cells = <1>;
+ #size-cells = <0>;
+ device_type = "mdio";
+ compatible = "mpc5200b-fec-phy";
+ reg = <3000 400>; // fec range, since we need to setup fec interrupts
+ interrupts = <2 5 0>; // these are for "mii command finished", not link changes & co.
+ interrupt-parent = <&mpc5200_pic>;
+
+ phy0:ethernet-phy@0 {
+ device_type = "ethernet-phy";
+ reg = <0>;
+ };
};
ata@3a00 {
@@ -148,11 +164,19 @@
};
i2c@3d40 {
+ #address-cells = <1>;
+ #size-cells = <0>;
compatible = "mpc5200-i2c","fsl-i2c";
reg = <3d40 40>;
interrupts = <2 10 0>;
interrupt-parent = <&mpc5200_pic>;
fsl5200-clocking;
+
+ rtc@68 {
+ device_type = "rtc";
+ compatible = "dallas,ds1307";
+ reg = <68>;
+ };
};
sram@8000 {
@@ -161,6 +185,23 @@
};
};
+ lpb {
+ model = "fsl,lpb";
+ compatible = "fsl,lpb";
+ #address-cells = <2>;
+ #size-cells = <1>;
+ ranges = <0 0 fc000000 02000000>;
+
+ flash@0,0 {
+ compatible = "cfi-flash";
+ reg = <0 0 02000000>;
+ bank-width = <4>;
+ device-width = <2>;
+ #size-cells = <1>;
+ #address-cells = <1>;
+ };
+ };
+
pci@f0000d00 {
#interrupt-cells = <1>;
#size-cells = <2>;
diff --git a/arch/powerpc/configs/cm5200_defconfig b/arch/powerpc/configs/cm5200_defconfig
index a17d966..4fcedcd 100644
--- a/arch/powerpc/configs/cm5200_defconfig
+++ b/arch/powerpc/configs/cm5200_defconfig
@@ -1,7 +1,7 @@
#
# Automatically generated make config: don't edit
-# Linux kernel version: 2.6.23
-# Mon Oct 29 14:06:34 2007
+# Linux kernel version: 2.6.24-rc6
+# Tue Jan 15 16:03:14 2008
#
# CONFIG_PPC64 is not set
@@ -67,11 +67,14 @@ CONFIG_SYSVIPC_SYSCTL=y
# CONFIG_BSD_PROCESS_ACCT is not set
# CONFIG_TASKSTATS is not set
# CONFIG_USER_NS is not set
+# CONFIG_PID_NS is not set
# CONFIG_AUDIT is not set
# CONFIG_IKCONFIG is not set
CONFIG_LOG_BUF_SHIFT=14
+# CONFIG_CGROUPS is not set
CONFIG_FAIR_GROUP_SCHED=y
CONFIG_FAIR_USER_SCHED=y
+# CONFIG_FAIR_CGROUP_SCHED is not set
CONFIG_SYSFS_DEPRECATED=y
# CONFIG_RELAY is not set
CONFIG_BLK_DEV_INITRD=y
@@ -93,18 +96,14 @@ CONFIG_SIGNALFD=y
CONFIG_EVENTFD=y
CONFIG_SHMEM=y
CONFIG_VM_EVENT_COUNTERS=y
-CONFIG_SLAB=y
-# CONFIG_SLUB is not set
+CONFIG_SLUB_DEBUG=y
+# CONFIG_SLAB is not set
+CONFIG_SLUB=y
# CONFIG_SLOB is not set
CONFIG_RT_MUTEXES=y
# CONFIG_TINY_SHMEM is not set
CONFIG_BASE_SMALL=0
-CONFIG_MODULES=y
-CONFIG_MODULE_UNLOAD=y
-# CONFIG_MODULE_FORCE_UNLOAD is not set
-# CONFIG_MODVERSIONS is not set
-# CONFIG_MODULE_SRCVERSION_ALL is not set
-# CONFIG_KMOD is not set
+# CONFIG_MODULES is not set
CONFIG_BLOCK=y
# CONFIG_LBD is not set
# CONFIG_BLK_DEV_IO_TRACE is not set
@@ -246,7 +245,7 @@ CONFIG_PACKET=y
# CONFIG_PACKET_MMAP is not set
CONFIG_UNIX=y
CONFIG_XFRM=y
-CONFIG_XFRM_USER=m
+CONFIG_XFRM_USER=y
# CONFIG_XFRM_SUB_POLICY is not set
# CONFIG_XFRM_MIGRATE is not set
# CONFIG_NET_KEY is not set
@@ -297,10 +296,6 @@ CONFIG_DEFAULT_TCP_CONG="cubic"
# CONFIG_LAPB is not set
# CONFIG_ECONET is not set
# CONFIG_WAN_ROUTER is not set
-
-#
-# QoS and/or fair queueing
-#
# CONFIG_NET_SCHED is not set
#
@@ -457,7 +452,6 @@ CONFIG_CHR_DEV_SG=y
# CONFIG_SCSI_CONSTANTS is not set
# CONFIG_SCSI_LOGGING is not set
# CONFIG_SCSI_SCAN_ASYNC is not set
-CONFIG_SCSI_WAIT_SCAN=m
#
# SCSI Transports
@@ -496,7 +490,6 @@ CONFIG_NETDEVICES=y
# CONFIG_USB_KAWETH is not set
# CONFIG_USB_PEGASUS is not set
# CONFIG_USB_RTL8150 is not set
-# CONFIG_USB_USBNET_MII is not set
# CONFIG_USB_USBNET is not set
# CONFIG_WAN is not set
# CONFIG_PPP is not set
@@ -543,7 +536,6 @@ CONFIG_UNIX98_PTYS=y
CONFIG_LEGACY_PTYS=y
CONFIG_LEGACY_PTY_COUNT=256
# CONFIG_IPMI_HANDLER is not set
-# CONFIG_WATCHDOG is not set
# CONFIG_HW_RANDOM is not set
# CONFIG_NVRAM is not set
# CONFIG_GEN_RTC is not set
@@ -569,7 +561,6 @@ CONFIG_I2C_MPC=y
# CONFIG_I2C_PARPORT_LIGHT is not set
# CONFIG_I2C_SIMTEC is not set
# CONFIG_I2C_TAOS_EVM is not set
-# CONFIG_I2C_STUB is not set
# CONFIG_I2C_TINY_USB is not set
#
@@ -598,6 +589,7 @@ CONFIG_I2C_MPC=y
# CONFIG_W1 is not set
# CONFIG_POWER_SUPPLY is not set
# CONFIG_HWMON is not set
+# CONFIG_WATCHDOG is not set
#
# Sonics Silicon Backplane
@@ -621,7 +613,7 @@ CONFIG_SSB_POSSIBLE=y
# Graphics support
#
# CONFIG_VGASTATE is not set
-CONFIG_VIDEO_OUTPUT_CONTROL=m
+CONFIG_VIDEO_OUTPUT_CONTROL=y
# CONFIG_FB is not set
# CONFIG_BACKLIGHT_LCD_SUPPORT is not set
@@ -683,6 +675,7 @@ CONFIG_USB_STORAGE=y
# CONFIG_USB_STORAGE_DEBUG is not set
# CONFIG_USB_STORAGE_DATAFAB is not set
# CONFIG_USB_STORAGE_FREECOM is not set
+# CONFIG_USB_STORAGE_ISD200 is not set
# CONFIG_USB_STORAGE_DPCM is not set
# CONFIG_USB_STORAGE_USBAT is not set
# CONFIG_USB_STORAGE_SDDR09 is not set
@@ -761,7 +754,6 @@ CONFIG_EXT3_FS_XATTR=y
# CONFIG_EXT3_FS_SECURITY is not set
# CONFIG_EXT4DEV_FS is not set
CONFIG_JBD=y
-# CONFIG_JBD_DEBUG is not set
CONFIG_FS_MBCACHE=y
# CONFIG_REISERFS_FS is not set
# CONFIG_JFS_FS is not set
@@ -936,16 +928,13 @@ CONFIG_PLIST=y
CONFIG_HAS_IOMEM=y
CONFIG_HAS_IOPORT=y
CONFIG_HAS_DMA=y
-
-#
-# Instrumentation Support
-#
-# CONFIG_PROFILING is not set
+# CONFIG_INSTRUMENTATION is not set
#
# Kernel hacking
#
-# CONFIG_PRINTK_TIME is not set
+CONFIG_PRINTK_TIME=y
+CONFIG_ENABLE_WARN_DEPRECATED=y
CONFIG_ENABLE_MUST_CHECK=y
# CONFIG_MAGIC_SYSRQ is not set
# CONFIG_UNUSED_SYMBOLS is not set
@@ -957,7 +946,7 @@ CONFIG_DETECT_SOFTLOCKUP=y
CONFIG_SCHED_DEBUG=y
# CONFIG_SCHEDSTATS is not set
# CONFIG_TIMER_STATS is not set
-# CONFIG_DEBUG_SLAB is not set
+# CONFIG_SLUB_DEBUG_ON is not set
# CONFIG_DEBUG_RT_MUTEXES is not set
# CONFIG_RT_MUTEX_TESTER is not set
# CONFIG_DEBUG_SPINLOCK is not set
@@ -969,10 +958,11 @@ CONFIG_SCHED_DEBUG=y
# CONFIG_DEBUG_INFO is not set
# CONFIG_DEBUG_VM is not set
# CONFIG_DEBUG_LIST is not set
+# CONFIG_DEBUG_SG is not set
CONFIG_FORCED_INLINING=y
# CONFIG_BOOT_PRINTK_DELAY is not set
-# CONFIG_RCU_TORTURE_TEST is not set
# CONFIG_FAULT_INJECTION is not set
+# CONFIG_SAMPLES is not set
# CONFIG_DEBUG_STACKOVERFLOW is not set
# CONFIG_DEBUG_STACK_USAGE is not set
# CONFIG_DEBUG_PAGEALLOC is not set
@@ -1002,9 +992,9 @@ CONFIG_CRYPTO_MD5=y
# CONFIG_CRYPTO_WP512 is not set
# CONFIG_CRYPTO_TGR192 is not set
# CONFIG_CRYPTO_GF128MUL is not set
-CONFIG_CRYPTO_ECB=m
+CONFIG_CRYPTO_ECB=y
CONFIG_CRYPTO_CBC=y
-CONFIG_CRYPTO_PCBC=m
+CONFIG_CRYPTO_PCBC=y
# CONFIG_CRYPTO_LRW is not set
# CONFIG_CRYPTO_XTS is not set
# CONFIG_CRYPTO_CRYPTD is not set
@@ -1025,7 +1015,6 @@ CONFIG_CRYPTO_DES=y
# CONFIG_CRYPTO_MICHAEL_MIC is not set
# CONFIG_CRYPTO_CRC32C is not set
# CONFIG_CRYPTO_CAMELLIA is not set
-# CONFIG_CRYPTO_TEST is not set
# CONFIG_CRYPTO_AUTHENC is not set
CONFIG_CRYPTO_HW=y
CONFIG_PPC_CLOCK=y
diff --git a/arch/powerpc/configs/motionpro_defconfig b/arch/powerpc/configs/motionpro_defconfig
index fd7a327..510ac66 100644
--- a/arch/powerpc/configs/motionpro_defconfig
+++ b/arch/powerpc/configs/motionpro_defconfig
@@ -1,7 +1,7 @@
#
# Automatically generated make config: don't edit
-# Linux kernel version: 2.6.23
-# Mon Oct 29 14:11:27 2007
+# Linux kernel version: 2.6.24-rc6
+# Thu Jan 17 12:40:29 2008
#
# CONFIG_PPC64 is not set
@@ -67,11 +67,14 @@ CONFIG_SYSVIPC_SYSCTL=y
# CONFIG_BSD_PROCESS_ACCT is not set
# CONFIG_TASKSTATS is not set
# CONFIG_USER_NS is not set
+# CONFIG_PID_NS is not set
# CONFIG_AUDIT is not set
# CONFIG_IKCONFIG is not set
CONFIG_LOG_BUF_SHIFT=14
+# CONFIG_CGROUPS is not set
CONFIG_FAIR_GROUP_SCHED=y
CONFIG_FAIR_USER_SCHED=y
+# CONFIG_FAIR_CGROUP_SCHED is not set
CONFIG_SYSFS_DEPRECATED=y
# CONFIG_RELAY is not set
CONFIG_BLK_DEV_INITRD=y
@@ -93,18 +96,14 @@ CONFIG_SIGNALFD=y
CONFIG_EVENTFD=y
CONFIG_SHMEM=y
CONFIG_VM_EVENT_COUNTERS=y
-CONFIG_SLAB=y
-# CONFIG_SLUB is not set
+CONFIG_SLUB_DEBUG=y
+# CONFIG_SLAB is not set
+CONFIG_SLUB=y
# CONFIG_SLOB is not set
CONFIG_RT_MUTEXES=y
# CONFIG_TINY_SHMEM is not set
CONFIG_BASE_SMALL=0
-CONFIG_MODULES=y
-CONFIG_MODULE_UNLOAD=y
-# CONFIG_MODULE_FORCE_UNLOAD is not set
-# CONFIG_MODVERSIONS is not set
-# CONFIG_MODULE_SRCVERSION_ALL is not set
-# CONFIG_KMOD is not set
+# CONFIG_MODULES is not set
CONFIG_BLOCK=y
# CONFIG_LBD is not set
# CONFIG_BLK_DEV_IO_TRACE is not set
@@ -246,7 +245,7 @@ CONFIG_PACKET=y
# CONFIG_PACKET_MMAP is not set
CONFIG_UNIX=y
CONFIG_XFRM=y
-CONFIG_XFRM_USER=m
+CONFIG_XFRM_USER=y
# CONFIG_XFRM_SUB_POLICY is not set
# CONFIG_XFRM_MIGRATE is not set
# CONFIG_NET_KEY is not set
@@ -297,10 +296,6 @@ CONFIG_DEFAULT_TCP_CONG="cubic"
# CONFIG_LAPB is not set
# CONFIG_ECONET is not set
# CONFIG_WAN_ROUTER is not set
-
-#
-# QoS and/or fair queueing
-#
# CONFIG_NET_SCHED is not set
#
@@ -456,7 +451,6 @@ CONFIG_CHR_DEV_SG=y
# CONFIG_SCSI_CONSTANTS is not set
# CONFIG_SCSI_LOGGING is not set
# CONFIG_SCSI_SCAN_ASYNC is not set
-CONFIG_SCSI_WAIT_SCAN=m
#
# SCSI Transports
@@ -472,7 +466,7 @@ CONFIG_SCSI_LOWLEVEL=y
CONFIG_ATA=y
# CONFIG_ATA_NONSTANDARD is not set
CONFIG_PATA_MPC52xx=y
-CONFIG_PATA_PLATFORM=y
+# CONFIG_PATA_PLATFORM is not set
# CONFIG_MD is not set
# CONFIG_MACINTOSH_DRIVERS is not set
CONFIG_NETDEVICES=y
@@ -485,15 +479,14 @@ CONFIG_NETDEVICES=y
# CONFIG_VETH is not set
# CONFIG_PHYLIB is not set
CONFIG_NET_ETHERNET=y
-CONFIG_MII=y
+# CONFIG_MII is not set
# CONFIG_IBM_NEW_EMAC_ZMII is not set
# CONFIG_IBM_NEW_EMAC_RGMII is not set
# CONFIG_IBM_NEW_EMAC_TAH is not set
# CONFIG_IBM_NEW_EMAC_EMAC4 is not set
# CONFIG_B44 is not set
-CONFIG_NETDEV_1000=y
-# CONFIG_MV643XX_ETH is not set
-CONFIG_NETDEV_10000=y
+# CONFIG_NETDEV_1000 is not set
+# CONFIG_NETDEV_10000 is not set
#
# Wireless LAN
@@ -545,7 +538,6 @@ CONFIG_UNIX98_PTYS=y
CONFIG_LEGACY_PTYS=y
CONFIG_LEGACY_PTY_COUNT=256
# CONFIG_IPMI_HANDLER is not set
-# CONFIG_WATCHDOG is not set
# CONFIG_HW_RANDOM is not set
# CONFIG_NVRAM is not set
# CONFIG_GEN_RTC is not set
@@ -571,7 +563,6 @@ CONFIG_I2C_MPC=y
# CONFIG_I2C_PARPORT_LIGHT is not set
# CONFIG_I2C_SIMTEC is not set
# CONFIG_I2C_TAOS_EVM is not set
-# CONFIG_I2C_STUB is not set
#
# Miscellaneous I2C Chip support
@@ -598,53 +589,8 @@ CONFIG_SENSORS_EEPROM=y
# CONFIG_SPI_MASTER is not set
# CONFIG_W1 is not set
# CONFIG_POWER_SUPPLY is not set
-CONFIG_HWMON=y
-# CONFIG_HWMON_VID is not set
-# CONFIG_SENSORS_AD7418 is not set
-# CONFIG_SENSORS_ADM1021 is not set
-# CONFIG_SENSORS_ADM1025 is not set
-# CONFIG_SENSORS_ADM1026 is not set
-# CONFIG_SENSORS_ADM1029 is not set
-# CONFIG_SENSORS_ADM1031 is not set
-# CONFIG_SENSORS_ADM9240 is not set
-# CONFIG_SENSORS_ADT7470 is not set
-# CONFIG_SENSORS_ATXP1 is not set
-# CONFIG_SENSORS_DS1621 is not set
-# CONFIG_SENSORS_F71805F is not set
-# CONFIG_SENSORS_F71882FG is not set
-# CONFIG_SENSORS_F75375S is not set
-# CONFIG_SENSORS_GL518SM is not set
-# CONFIG_SENSORS_GL520SM is not set
-# CONFIG_SENSORS_IT87 is not set
-# CONFIG_SENSORS_LM63 is not set
-# CONFIG_SENSORS_LM75 is not set
-# CONFIG_SENSORS_LM77 is not set
-# CONFIG_SENSORS_LM78 is not set
-# CONFIG_SENSORS_LM80 is not set
-# CONFIG_SENSORS_LM83 is not set
-# CONFIG_SENSORS_LM85 is not set
-# CONFIG_SENSORS_LM87 is not set
-# CONFIG_SENSORS_LM90 is not set
-# CONFIG_SENSORS_LM92 is not set
-# CONFIG_SENSORS_LM93 is not set
-# CONFIG_SENSORS_MAX1619 is not set
-# CONFIG_SENSORS_MAX6650 is not set
-# CONFIG_SENSORS_PC87360 is not set
-# CONFIG_SENSORS_PC87427 is not set
-# CONFIG_SENSORS_DME1737 is not set
-# CONFIG_SENSORS_SMSC47M1 is not set
-# CONFIG_SENSORS_SMSC47M192 is not set
-# CONFIG_SENSORS_SMSC47B397 is not set
-# CONFIG_SENSORS_THMC50 is not set
-# CONFIG_SENSORS_VT1211 is not set
-# CONFIG_SENSORS_W83781D is not set
-# CONFIG_SENSORS_W83791D is not set
-# CONFIG_SENSORS_W83792D is not set
-# CONFIG_SENSORS_W83793 is not set
-# CONFIG_SENSORS_W83L785TS is not set
-# CONFIG_SENSORS_W83627HF is not set
-# CONFIG_SENSORS_W83627EHF is not set
-# CONFIG_HWMON_DEBUG_CHIP is not set
+# CONFIG_HWMON is not set
+# CONFIG_WATCHDOG is not set
#
# Sonics Silicon Backplane
@@ -668,7 +614,7 @@ CONFIG_DAB=y
# Graphics support
#
# CONFIG_VGASTATE is not set
-CONFIG_VIDEO_OUTPUT_CONTROL=m
+CONFIG_VIDEO_OUTPUT_CONTROL=y
# CONFIG_FB is not set
# CONFIG_BACKLIGHT_LCD_SUPPORT is not set
@@ -711,7 +657,53 @@ CONFIG_LEDS_TRIGGERS=y
CONFIG_LEDS_TRIGGER_TIMER=y
# CONFIG_LEDS_TRIGGER_HEARTBEAT is not set
# CONFIG_EDAC is not set
-# CONFIG_RTC_CLASS is not set
+CONFIG_RTC_LIB=y
+CONFIG_RTC_CLASS=y
+CONFIG_RTC_HCTOSYS=y
+CONFIG_RTC_HCTOSYS_DEVICE="rtc0"
+# CONFIG_RTC_DEBUG is not set
+
+#
+# RTC interfaces
+#
+CONFIG_RTC_INTF_SYSFS=y
+CONFIG_RTC_INTF_PROC=y
+CONFIG_RTC_INTF_DEV=y
+# CONFIG_RTC_INTF_DEV_UIE_EMUL is not set
+# CONFIG_RTC_DRV_TEST is not set
+
+#
+# I2C RTC drivers
+#
+CONFIG_RTC_DRV_DS1307=y
+# CONFIG_RTC_DRV_DS1374 is not set
+# CONFIG_RTC_DRV_DS1672 is not set
+# CONFIG_RTC_DRV_MAX6900 is not set
+# CONFIG_RTC_DRV_RS5C372 is not set
+# CONFIG_RTC_DRV_ISL1208 is not set
+# CONFIG_RTC_DRV_X1205 is not set
+# CONFIG_RTC_DRV_PCF8563 is not set
+# CONFIG_RTC_DRV_PCF8583 is not set
+# CONFIG_RTC_DRV_M41T80 is not set
+
+#
+# SPI RTC drivers
+#
+
+#
+# Platform RTC drivers
+#
+# CONFIG_RTC_DRV_CMOS is not set
+# CONFIG_RTC_DRV_DS1553 is not set
+# CONFIG_RTC_DRV_STK17TA8 is not set
+# CONFIG_RTC_DRV_DS1742 is not set
+# CONFIG_RTC_DRV_M48T86 is not set
+# CONFIG_RTC_DRV_M48T59 is not set
+# CONFIG_RTC_DRV_V3020 is not set
+
+#
+# on-CPU RTC drivers
+#
#
# Userspace I/O
@@ -730,7 +722,6 @@ CONFIG_EXT3_FS_XATTR=y
# CONFIG_EXT3_FS_SECURITY is not set
# CONFIG_EXT4DEV_FS is not set
CONFIG_JBD=y
-# CONFIG_JBD_DEBUG is not set
CONFIG_FS_MBCACHE=y
# CONFIG_REISERFS_FS is not set
# CONFIG_JFS_FS is not set
@@ -797,7 +788,7 @@ CONFIG_NETWORK_FILESYSTEMS=y
CONFIG_NFS_FS=y
CONFIG_NFS_V3=y
# CONFIG_NFS_V3_ACL is not set
-CONFIG_NFS_V4=y
+# CONFIG_NFS_V4 is not set
# CONFIG_NFS_DIRECTIO is not set
# CONFIG_NFSD is not set
CONFIG_ROOT_NFS=y
@@ -805,9 +796,8 @@ CONFIG_LOCKD=y
CONFIG_LOCKD_V4=y
CONFIG_NFS_COMMON=y
CONFIG_SUNRPC=y
-CONFIG_SUNRPC_GSS=y
# CONFIG_SUNRPC_BIND34 is not set
-CONFIG_RPCSEC_GSS_KRB5=y
+# CONFIG_RPCSEC_GSS_KRB5 is not set
# CONFIG_RPCSEC_GSS_SPKM3 is not set
# CONFIG_SMB_FS is not set
# CONFIG_CIFS is not set
@@ -894,16 +884,13 @@ CONFIG_PLIST=y
CONFIG_HAS_IOMEM=y
CONFIG_HAS_IOPORT=y
CONFIG_HAS_DMA=y
-
-#
-# Instrumentation Support
-#
-# CONFIG_PROFILING is not set
+# CONFIG_INSTRUMENTATION is not set
#
# Kernel hacking
#
-# CONFIG_PRINTK_TIME is not set
+CONFIG_PRINTK_TIME=y
+CONFIG_ENABLE_WARN_DEPRECATED=y
CONFIG_ENABLE_MUST_CHECK=y
# CONFIG_MAGIC_SYSRQ is not set
# CONFIG_UNUSED_SYMBOLS is not set
@@ -915,7 +902,7 @@ CONFIG_DETECT_SOFTLOCKUP=y
CONFIG_SCHED_DEBUG=y
# CONFIG_SCHEDSTATS is not set
# CONFIG_TIMER_STATS is not set
-# CONFIG_DEBUG_SLAB is not set
+# CONFIG_SLUB_DEBUG_ON is not set
# CONFIG_DEBUG_RT_MUTEXES is not set
# CONFIG_RT_MUTEX_TESTER is not set
# CONFIG_DEBUG_SPINLOCK is not set
@@ -927,10 +914,11 @@ CONFIG_SCHED_DEBUG=y
CONFIG_DEBUG_INFO=y
# CONFIG_DEBUG_VM is not set
# CONFIG_DEBUG_LIST is not set
+# CONFIG_DEBUG_SG is not set
CONFIG_FORCED_INLINING=y
# CONFIG_BOOT_PRINTK_DELAY is not set
-# CONFIG_RCU_TORTURE_TEST is not set
# CONFIG_FAULT_INJECTION is not set
+# CONFIG_SAMPLES is not set
# CONFIG_DEBUG_STACKOVERFLOW is not set
# CONFIG_DEBUG_STACK_USAGE is not set
# CONFIG_DEBUG_PAGEALLOC is not set
@@ -960,9 +948,9 @@ CONFIG_CRYPTO_MD5=y
# CONFIG_CRYPTO_WP512 is not set
# CONFIG_CRYPTO_TGR192 is not set
# CONFIG_CRYPTO_GF128MUL is not set
-CONFIG_CRYPTO_ECB=m
+CONFIG_CRYPTO_ECB=y
CONFIG_CRYPTO_CBC=y
-CONFIG_CRYPTO_PCBC=m
+CONFIG_CRYPTO_PCBC=y
# CONFIG_CRYPTO_LRW is not set
# CONFIG_CRYPTO_XTS is not set
# CONFIG_CRYPTO_CRYPTD is not set
@@ -983,7 +971,6 @@ CONFIG_CRYPTO_DES=y
# CONFIG_CRYPTO_MICHAEL_MIC is not set
# CONFIG_CRYPTO_CRC32C is not set
# CONFIG_CRYPTO_CAMELLIA is not set
-# CONFIG_CRYPTO_TEST is not set
# CONFIG_CRYPTO_AUTHENC is not set
CONFIG_CRYPTO_HW=y
CONFIG_PPC_CLOCK=y
diff --git a/arch/powerpc/configs/tqm5200_defconfig b/arch/powerpc/configs/tqm5200_defconfig
index 53fa968..ed4951b 100644
--- a/arch/powerpc/configs/tqm5200_defconfig
+++ b/arch/powerpc/configs/tqm5200_defconfig
@@ -1,7 +1,7 @@
#
# Automatically generated make config: don't edit
-# Linux kernel version: 2.6.23
-# Mon Oct 29 14:01:58 2007
+# Linux kernel version: 2.6.24-rc6
+# Thu Jan 17 11:12:51 2008
#
# CONFIG_PPC64 is not set
@@ -67,11 +67,14 @@ CONFIG_SYSVIPC_SYSCTL=y
# CONFIG_BSD_PROCESS_ACCT is not set
# CONFIG_TASKSTATS is not set
# CONFIG_USER_NS is not set
+# CONFIG_PID_NS is not set
# CONFIG_AUDIT is not set
# CONFIG_IKCONFIG is not set
CONFIG_LOG_BUF_SHIFT=14
+# CONFIG_CGROUPS is not set
CONFIG_FAIR_GROUP_SCHED=y
CONFIG_FAIR_USER_SCHED=y
+# CONFIG_FAIR_CGROUP_SCHED is not set
CONFIG_SYSFS_DEPRECATED=y
# CONFIG_RELAY is not set
CONFIG_BLK_DEV_INITRD=y
@@ -93,18 +96,14 @@ CONFIG_SIGNALFD=y
CONFIG_EVENTFD=y
CONFIG_SHMEM=y
CONFIG_VM_EVENT_COUNTERS=y
-CONFIG_SLAB=y
-# CONFIG_SLUB is not set
+CONFIG_SLUB_DEBUG=y
+# CONFIG_SLAB is not set
+CONFIG_SLUB=y
# CONFIG_SLOB is not set
CONFIG_RT_MUTEXES=y
# CONFIG_TINY_SHMEM is not set
CONFIG_BASE_SMALL=0
-CONFIG_MODULES=y
-CONFIG_MODULE_UNLOAD=y
-# CONFIG_MODULE_FORCE_UNLOAD is not set
-# CONFIG_MODVERSIONS is not set
-# CONFIG_MODULE_SRCVERSION_ALL is not set
-# CONFIG_KMOD is not set
+# CONFIG_MODULES is not set
CONFIG_BLOCK=y
# CONFIG_LBD is not set
# CONFIG_BLK_DEV_IO_TRACE is not set
@@ -221,6 +220,7 @@ CONFIG_PCI_SYSCALL=y
# CONFIG_PCIEPORTBUS is not set
CONFIG_ARCH_SUPPORTS_MSI=y
# CONFIG_PCI_MSI is not set
+CONFIG_PCI_LEGACY=y
# CONFIG_PCI_DEBUG is not set
# CONFIG_PCCARD is not set
# CONFIG_HOTPLUG_PCI is not set
@@ -251,7 +251,7 @@ CONFIG_PACKET=y
# CONFIG_PACKET_MMAP is not set
CONFIG_UNIX=y
CONFIG_XFRM=y
-CONFIG_XFRM_USER=m
+CONFIG_XFRM_USER=y
# CONFIG_XFRM_SUB_POLICY is not set
# CONFIG_XFRM_MIGRATE is not set
# CONFIG_NET_KEY is not set
@@ -302,10 +302,6 @@ CONFIG_DEFAULT_TCP_CONG="cubic"
# CONFIG_LAPB is not set
# CONFIG_ECONET is not set
# CONFIG_WAN_ROUTER is not set
-
-#
-# QoS and/or fair queueing
-#
# CONFIG_NET_SCHED is not set
#
@@ -472,7 +468,6 @@ CONFIG_CHR_DEV_SG=y
# CONFIG_SCSI_CONSTANTS is not set
# CONFIG_SCSI_LOGGING is not set
# CONFIG_SCSI_SCAN_ASYNC is not set
-CONFIG_SCSI_WAIT_SCAN=m
#
# SCSI Transports
@@ -628,7 +623,6 @@ CONFIG_NET_ETHERNET=y
# CONFIG_USB_KAWETH is not set
# CONFIG_USB_PEGASUS is not set
# CONFIG_USB_RTL8150 is not set
-# CONFIG_USB_USBNET_MII is not set
# CONFIG_USB_USBNET is not set
# CONFIG_WAN is not set
# CONFIG_FDDI is not set
@@ -679,25 +673,6 @@ CONFIG_UNIX98_PTYS=y
CONFIG_LEGACY_PTYS=y
CONFIG_LEGACY_PTY_COUNT=256
# CONFIG_IPMI_HANDLER is not set
-CONFIG_WATCHDOG=y
-# CONFIG_WATCHDOG_NOWAYOUT is not set
-
-#
-# Watchdog Device Drivers
-#
-# CONFIG_SOFT_WATCHDOG is not set
-# CONFIG_MPC5200_WDT is not set
-
-#
-# PCI-based Watchdog Cards
-#
-# CONFIG_PCIPCWATCHDOG is not set
-# CONFIG_WDTPCI is not set
-
-#
-# USB-based Watchdog Cards
-#
-# CONFIG_USBPCWATCHDOG is not set
# CONFIG_HW_RANDOM is not set
# CONFIG_NVRAM is not set
CONFIG_GEN_RTC=y
@@ -740,7 +715,6 @@ CONFIG_I2C_MPC=y
# CONFIG_I2C_SIS630 is not set
# CONFIG_I2C_SIS96X is not set
# CONFIG_I2C_TAOS_EVM is not set
-# CONFIG_I2C_STUB is not set
# CONFIG_I2C_TINY_USB is not set
# CONFIG_I2C_VIA is not set
# CONFIG_I2C_VIAPRO is not set
@@ -783,6 +757,7 @@ CONFIG_HWMON=y
# CONFIG_SENSORS_ADT7470 is not set
# CONFIG_SENSORS_ATXP1 is not set
# CONFIG_SENSORS_DS1621 is not set
+# CONFIG_SENSORS_I5K_AMB is not set
# CONFIG_SENSORS_F71805F is not set
# CONFIG_SENSORS_F71882FG is not set
# CONFIG_SENSORS_F75375S is not set
@@ -821,6 +796,25 @@ CONFIG_HWMON=y
# CONFIG_SENSORS_W83627HF is not set
# CONFIG_SENSORS_W83627EHF is not set
# CONFIG_HWMON_DEBUG_CHIP is not set
+CONFIG_WATCHDOG=y
+# CONFIG_WATCHDOG_NOWAYOUT is not set
+
+#
+# Watchdog Device Drivers
+#
+# CONFIG_SOFT_WATCHDOG is not set
+# CONFIG_MPC5200_WDT is not set
+
+#
+# PCI-based Watchdog Cards
+#
+# CONFIG_PCIPCWATCHDOG is not set
+# CONFIG_WDTPCI is not set
+
+#
+# USB-based Watchdog Cards
+#
+# CONFIG_USBPCWATCHDOG is not set
#
# Sonics Silicon Backplane
@@ -846,7 +840,7 @@ CONFIG_SSB_POSSIBLE=y
# CONFIG_AGP is not set
# CONFIG_DRM is not set
# CONFIG_VGASTATE is not set
-CONFIG_VIDEO_OUTPUT_CONTROL=m
+CONFIG_VIDEO_OUTPUT_CONTROL=y
# CONFIG_FB is not set
# CONFIG_BACKLIGHT_LCD_SUPPORT is not set
@@ -911,6 +905,7 @@ CONFIG_USB_STORAGE=y
# CONFIG_USB_STORAGE_DEBUG is not set
# CONFIG_USB_STORAGE_DATAFAB is not set
# CONFIG_USB_STORAGE_FREECOM is not set
+# CONFIG_USB_STORAGE_ISD200 is not set
# CONFIG_USB_STORAGE_DPCM is not set
# CONFIG_USB_STORAGE_USBAT is not set
# CONFIG_USB_STORAGE_SDDR09 is not set
@@ -1036,7 +1031,6 @@ CONFIG_EXT3_FS_XATTR=y
# CONFIG_EXT3_FS_SECURITY is not set
# CONFIG_EXT4DEV_FS is not set
CONFIG_JBD=y
-# CONFIG_JBD_DEBUG is not set
CONFIG_FS_MBCACHE=y
# CONFIG_REISERFS_FS is not set
# CONFIG_JFS_FS is not set
@@ -1211,16 +1205,15 @@ CONFIG_PLIST=y
CONFIG_HAS_IOMEM=y
CONFIG_HAS_IOPORT=y
CONFIG_HAS_DMA=y
-
-#
-# Instrumentation Support
-#
+CONFIG_INSTRUMENTATION=y
# CONFIG_PROFILING is not set
+# CONFIG_MARKERS is not set
#
# Kernel hacking
#
-# CONFIG_PRINTK_TIME is not set
+CONFIG_PRINTK_TIME=y
+CONFIG_ENABLE_WARN_DEPRECATED=y
CONFIG_ENABLE_MUST_CHECK=y
# CONFIG_MAGIC_SYSRQ is not set
# CONFIG_UNUSED_SYMBOLS is not set
@@ -1232,7 +1225,7 @@ CONFIG_DETECT_SOFTLOCKUP=y
CONFIG_SCHED_DEBUG=y
# CONFIG_SCHEDSTATS is not set
# CONFIG_TIMER_STATS is not set
-# CONFIG_DEBUG_SLAB is not set
+# CONFIG_SLUB_DEBUG_ON is not set
# CONFIG_DEBUG_RT_MUTEXES is not set
# CONFIG_RT_MUTEX_TESTER is not set
# CONFIG_DEBUG_SPINLOCK is not set
@@ -1244,10 +1237,11 @@ CONFIG_SCHED_DEBUG=y
CONFIG_DEBUG_INFO=y
# CONFIG_DEBUG_VM is not set
# CONFIG_DEBUG_LIST is not set
+# CONFIG_DEBUG_SG is not set
CONFIG_FORCED_INLINING=y
# CONFIG_BOOT_PRINTK_DELAY is not set
-# CONFIG_RCU_TORTURE_TEST is not set
# CONFIG_FAULT_INJECTION is not set
+# CONFIG_SAMPLES is not set
# CONFIG_DEBUG_STACKOVERFLOW is not set
# CONFIG_DEBUG_STACK_USAGE is not set
# CONFIG_DEBUG_PAGEALLOC is not set
@@ -1277,9 +1271,9 @@ CONFIG_CRYPTO_MD5=y
# CONFIG_CRYPTO_WP512 is not set
# CONFIG_CRYPTO_TGR192 is not set
# CONFIG_CRYPTO_GF128MUL is not set
-CONFIG_CRYPTO_ECB=m
+CONFIG_CRYPTO_ECB=y
CONFIG_CRYPTO_CBC=y
-CONFIG_CRYPTO_PCBC=m
+CONFIG_CRYPTO_PCBC=y
# CONFIG_CRYPTO_LRW is not set
# CONFIG_CRYPTO_XTS is not set
# CONFIG_CRYPTO_CRYPTD is not set
@@ -1300,7 +1294,6 @@ CONFIG_CRYPTO_DES=y
# CONFIG_CRYPTO_MICHAEL_MIC is not set
# CONFIG_CRYPTO_CRC32C is not set
# CONFIG_CRYPTO_CAMELLIA is not set
-# CONFIG_CRYPTO_TEST is not set
# CONFIG_CRYPTO_AUTHENC is not set
CONFIG_CRYPTO_HW=y
CONFIG_PPC_CLOCK=y
^ permalink raw reply related
* Re: [PATCH v4 02/13] [POWERPC] Add 'fsl, lpb' bus type for MPC5200 LocalPlus Bus
From: Marian Balakowicz @ 2008-01-17 14:30 UTC (permalink / raw)
To: Grant Likely; +Cc: linuxppc-dev
In-Reply-To: <fa686aa40801021537h58ed2deehfd85c75871973758@mail.gmail.com>
Hi Grant,
Sorry, for the late reply.
Grant Likely wrote:
> On 11/9/07, Marian Balakowicz <m8@semihalf.com> wrote:
>> Define MPC52xx specific device id list, add new
>> 'fsl,lpb' compatible id for LocalPlus Bus.
>
> I'll pick this up, but I'm going to drop the .compatible="soc" line.
> (I'd like to drop the device_type="soc" line also, but that requires a
> bit more thought first).
I finally got a chance to re-test my 5200 patches. I pulled
'for-2.6.25' branch from your tree where you already applied those
patches and adapted .dts and _defconfig files.
See '[POWERPC] Update TQM5200, CM5200 and Motion-PRO _defconfig and
.dts files' patch. It introduces necessary modification resulting from
the meantime development, so please pick this one up as well.
I got one more pending patch: '[POWERPC] Motion-PRO: Add LED support',
but that's the diver code and I am not sure who should be picking it
up, any ideas?
Thanks,
m.
^ permalink raw reply
* [PATCH 4/4] IB/ehca: Prevent RDMA-related connection failures
From: Joachim Fenkes @ 2008-01-17 14:07 UTC (permalink / raw)
To: LinuxPPC-Dev, LKML, OF-General, Roland Dreier, OF-EWG
Cc: Stefan Roscher, Christoph Raisch
In-Reply-To: <200801171502.34287.fenkes@de.ibm.com>
Some HW revisions of eHCA2 may cause an RC connection to break if they
received RDMA Reads over that connection before. This can be prevented by
assuring that, after the first RDMA Read, the QP receives a new RDMA Read
every few million link packets.
Include code into the driver that inserts an empty (size 0) RDMA Read into
the message stream every now and then if the consumer doesn't post them
frequently enough.
Signed-off-by: Joachim Fenkes <fenkes@de.ibm.com>
---
drivers/infiniband/hw/ehca/ehca_classes.h | 5 ++
drivers/infiniband/hw/ehca/ehca_qp.c | 14 +++-
drivers/infiniband/hw/ehca/ehca_reqs.c | 112 ++++++++++++++++++++--------
3 files changed, 95 insertions(+), 36 deletions(-)
diff --git a/drivers/infiniband/hw/ehca/ehca_classes.h b/drivers/infiniband/hw/ehca/ehca_classes.h
index 2502366..f281d16 100644
--- a/drivers/infiniband/hw/ehca/ehca_classes.h
+++ b/drivers/infiniband/hw/ehca/ehca_classes.h
@@ -183,6 +183,11 @@ struct ehca_qp {
u32 mm_count_squeue;
u32 mm_count_rqueue;
u32 mm_count_galpa;
+ /* unsolicited ack circumvention */
+ int unsol_ack_circ;
+ int mtu_shift;
+ u32 message_count;
+ u32 packet_count;
};
#define IS_SRQ(qp) (qp->ext_type == EQPT_SRQ)
diff --git a/drivers/infiniband/hw/ehca/ehca_qp.c b/drivers/infiniband/hw/ehca/ehca_qp.c
index bb7ccef..6c050e0 100644
--- a/drivers/infiniband/hw/ehca/ehca_qp.c
+++ b/drivers/infiniband/hw/ehca/ehca_qp.c
@@ -592,10 +592,8 @@ static struct ehca_qp *internal_create_qp(
goto create_qp_exit1;
}
- if (init_attr->sq_sig_type == IB_SIGNAL_ALL_WR)
- parms.sigtype = HCALL_SIGT_EVERY;
- else
- parms.sigtype = HCALL_SIGT_BY_WQE;
+ /* Always signal by WQE so we can hide circ. WQEs */
+ parms.sigtype = HCALL_SIGT_BY_WQE;
/* UD_AV CIRCUMVENTION */
max_send_sge = init_attr->cap.max_send_sge;
@@ -618,6 +616,10 @@ static struct ehca_qp *internal_create_qp(
parms.squeue.max_sge = max_send_sge;
parms.rqueue.max_sge = max_recv_sge;
+ /* RC QPs need one more SWQE for unsolicited ack circumvention */
+ if (qp_type == IB_QPT_RC)
+ parms.squeue.max_wr++;
+
if (EHCA_BMASK_GET(HCA_CAP_MINI_QP, shca->hca_cap)) {
if (HAS_SQ(my_qp))
ehca_determine_small_queue(
@@ -650,6 +652,8 @@ static struct ehca_qp *internal_create_qp(
parms.squeue.act_nr_sges = 1;
parms.rqueue.act_nr_sges = 1;
}
+ /* hide the extra WQE */
+ parms.squeue.act_nr_wqes--;
break;
case IB_QPT_UD:
case IB_QPT_GSI:
@@ -1295,6 +1299,8 @@ static int internal_modify_qp(struct ib_qp *ibqp,
}
if (attr_mask & IB_QP_PATH_MTU) {
+ /* store ld(MTU) */
+ my_qp->mtu_shift = attr->path_mtu + 7;
mqpcb->path_mtu = attr->path_mtu;
update_mask |= EHCA_BMASK_SET(MQPCB_MASK_PATH_MTU, 1);
}
diff --git a/drivers/infiniband/hw/ehca/ehca_reqs.c b/drivers/infiniband/hw/ehca/ehca_reqs.c
index ea91360..3aacc8c 100644
--- a/drivers/infiniband/hw/ehca/ehca_reqs.c
+++ b/drivers/infiniband/hw/ehca/ehca_reqs.c
@@ -50,6 +50,9 @@
#include "hcp_if.h"
#include "hipz_fns.h"
+/* in RC traffic, insert an empty RDMA READ every this many packets */
+#define ACK_CIRC_THRESHOLD 2000000
+
static inline int ehca_write_rwqe(struct ipz_queue *ipz_rqueue,
struct ehca_wqe *wqe_p,
struct ib_recv_wr *recv_wr)
@@ -81,7 +84,7 @@ static inline int ehca_write_rwqe(struct ipz_queue *ipz_rqueue,
if (ehca_debug_level) {
ehca_gen_dbg("RECEIVE WQE written into ipz_rqueue=%p",
ipz_rqueue);
- ehca_dmp( wqe_p, 16*(6 + wqe_p->nr_of_data_seg), "recv wqe");
+ ehca_dmp(wqe_p, 16*(6 + wqe_p->nr_of_data_seg), "recv wqe");
}
return 0;
@@ -135,7 +138,8 @@ static void trace_send_wr_ud(const struct ib_send_wr *send_wr)
static inline int ehca_write_swqe(struct ehca_qp *qp,
struct ehca_wqe *wqe_p,
- const struct ib_send_wr *send_wr)
+ const struct ib_send_wr *send_wr,
+ int hidden)
{
u32 idx;
u64 dma_length;
@@ -176,7 +180,9 @@ static inline int ehca_write_swqe(struct ehca_qp *qp,
wqe_p->wr_flag = 0;
- if (send_wr->send_flags & IB_SEND_SIGNALED)
+ if ((send_wr->send_flags & IB_SEND_SIGNALED ||
+ qp->init_attr.sq_sig_type == IB_SIGNAL_ALL_WR)
+ && !hidden)
wqe_p->wr_flag |= WQE_WRFLAG_REQ_SIGNAL_COM;
if (send_wr->opcode == IB_WR_SEND_WITH_IMM ||
@@ -199,7 +205,7 @@ static inline int ehca_write_swqe(struct ehca_qp *qp,
wqe_p->destination_qp_number = send_wr->wr.ud.remote_qpn << 8;
wqe_p->local_ee_context_qkey = remote_qkey;
- if (!send_wr->wr.ud.ah) {
+ if (unlikely(!send_wr->wr.ud.ah)) {
ehca_gen_err("wr.ud.ah is NULL. qp=%p", qp);
return -EINVAL;
}
@@ -255,6 +261,15 @@ static inline int ehca_write_swqe(struct ehca_qp *qp,
} /* eof idx */
wqe_p->u.nud.atomic_1st_op_dma_len = dma_length;
+ /* unsolicited ack circumvention */
+ if (send_wr->opcode == IB_WR_RDMA_READ) {
+ /* on RDMA read, switch on and reset counters */
+ qp->message_count = qp->packet_count = 0;
+ qp->unsol_ack_circ = 1;
+ } else
+ /* else estimate #packets */
+ qp->packet_count += (dma_length >> qp->mtu_shift) + 1;
+
break;
default:
@@ -355,13 +370,49 @@ static inline void map_ib_wc_status(u32 cqe_status,
*wc_status = IB_WC_SUCCESS;
}
+static inline int post_one_send(struct ehca_qp *my_qp,
+ struct ib_send_wr *cur_send_wr,
+ struct ib_send_wr **bad_send_wr,
+ int hidden)
+{
+ struct ehca_wqe *wqe_p;
+ int ret;
+ u64 start_offset = my_qp->ipz_squeue.current_q_offset;
+
+ /* get pointer next to free WQE */
+ wqe_p = ipz_qeit_get_inc(&my_qp->ipz_squeue);
+ if (unlikely(!wqe_p)) {
+ /* too many posted work requests: queue overflow */
+ if (bad_send_wr)
+ *bad_send_wr = cur_send_wr;
+ ehca_err(my_qp->ib_qp.device, "Too many posted WQEs "
+ "qp_num=%x", my_qp->ib_qp.qp_num);
+ return -ENOMEM;
+ }
+ /* write a SEND WQE into the QUEUE */
+ ret = ehca_write_swqe(my_qp, wqe_p, cur_send_wr, hidden);
+ /*
+ * if something failed,
+ * reset the free entry pointer to the start value
+ */
+ if (unlikely(ret)) {
+ my_qp->ipz_squeue.current_q_offset = start_offset;
+ if (bad_send_wr)
+ *bad_send_wr = cur_send_wr;
+ ehca_err(my_qp->ib_qp.device, "Could not write WQE "
+ "qp_num=%x", my_qp->ib_qp.qp_num);
+ return -EINVAL;
+ }
+
+ return 0;
+}
+
int ehca_post_send(struct ib_qp *qp,
struct ib_send_wr *send_wr,
struct ib_send_wr **bad_send_wr)
{
struct ehca_qp *my_qp = container_of(qp, struct ehca_qp, ib_qp);
struct ib_send_wr *cur_send_wr;
- struct ehca_wqe *wqe_p;
int wqe_cnt = 0;
int ret = 0;
unsigned long flags;
@@ -369,37 +420,33 @@ int ehca_post_send(struct ib_qp *qp,
/* LOCK the QUEUE */
spin_lock_irqsave(&my_qp->spinlock_s, flags);
+ /* Send an empty extra RDMA read if:
+ * 1) there has been an RDMA read on this connection before
+ * 2) no RDMA read occurred for ACK_CIRC_THRESHOLD link packets
+ * 3) we can be sure that any previous extra RDMA read has been
+ * processed so we don't overflow the SQ
+ */
+ if (unlikely(my_qp->unsol_ack_circ &&
+ my_qp->packet_count > ACK_CIRC_THRESHOLD &&
+ my_qp->message_count > my_qp->init_attr.cap.max_send_wr)) {
+ /* insert an empty RDMA READ to fix up the remote QP state */
+ struct ib_send_wr circ_wr;
+ memset(&circ_wr, 0, sizeof(circ_wr));
+ circ_wr.opcode = IB_WR_RDMA_READ;
+ post_one_send(my_qp, &circ_wr, NULL, 1); /* ignore retcode */
+ wqe_cnt++;
+ ehca_dbg(qp->device, "posted circ wr qp_num=%x", qp->qp_num);
+ my_qp->message_count = my_qp->packet_count = 0;
+ }
+
/* loop processes list of send reqs */
for (cur_send_wr = send_wr; cur_send_wr != NULL;
cur_send_wr = cur_send_wr->next) {
- u64 start_offset = my_qp->ipz_squeue.current_q_offset;
- /* get pointer next to free WQE */
- wqe_p = ipz_qeit_get_inc(&my_qp->ipz_squeue);
- if (unlikely(!wqe_p)) {
- /* too many posted work requests: queue overflow */
- if (bad_send_wr)
- *bad_send_wr = cur_send_wr;
- if (wqe_cnt == 0) {
- ret = -ENOMEM;
- ehca_err(qp->device, "Too many posted WQEs "
- "qp_num=%x", qp->qp_num);
- }
- goto post_send_exit0;
- }
- /* write a SEND WQE into the QUEUE */
- ret = ehca_write_swqe(my_qp, wqe_p, cur_send_wr);
- /*
- * if something failed,
- * reset the free entry pointer to the start value
- */
+ ret = post_one_send(my_qp, cur_send_wr, bad_send_wr, 0);
if (unlikely(ret)) {
- my_qp->ipz_squeue.current_q_offset = start_offset;
- *bad_send_wr = cur_send_wr;
- if (wqe_cnt == 0) {
- ret = -EINVAL;
- ehca_err(qp->device, "Could not write WQE "
- "qp_num=%x", qp->qp_num);
- }
+ /* if one or more WQEs were successful, don't fail */
+ if (wqe_cnt)
+ ret = 0;
goto post_send_exit0;
}
wqe_cnt++;
@@ -410,6 +457,7 @@ int ehca_post_send(struct ib_qp *qp,
post_send_exit0:
iosync(); /* serialize GAL register access */
hipz_update_sqa(my_qp, wqe_cnt);
+ my_qp->message_count += wqe_cnt;
spin_unlock_irqrestore(&my_qp->spinlock_s, flags);
return ret;
}
--
1.5.2
^ permalink raw reply related
* [PATCH 3/4] IB/ehca: Add "port connection autodetect mode"
From: Joachim Fenkes @ 2008-01-17 14:05 UTC (permalink / raw)
To: LinuxPPC-Dev, LKML, OF-General, Roland Dreier, OF-EWG
Cc: Stefan Roscher, Christoph Raisch
In-Reply-To: <200801171502.34287.fenkes@de.ibm.com>
From: Hoang-Nam Nguyen <hnguyen@de.ibm.com>
This patch enhances ehca with a capability to "autodetect" the ports being
connected physically. In order to utilize that function the module option
nr_ports must be set to -1 (default is 2 - two ports). This feature is
experimental and will made the default later.
More detail:
If the user connects only one port to the switch, current code requires
1) port one to be connected and
2) module option nr_ports=1 to be given.
If autodetect is enabled, ehca will not wait at creation of the GSI QP for
the respective port to become active. Since firmware does not accept
modify_qp() while the port is down at initialization, we need to cache all
calls to modify_qp() for the SMI/GSI QP and just return a good return code.
When a port is activated and we get a PORT_ACTIVE event, we replay the
cached modify-qp() parms and re-trigger any posted recv WRs. Only then do we
forward the PORT_ACTIVE event to registered clients.
The result of this autodetect patch is that all ports will be accessible by
the users. Depending on their respective cabling only those ports that are
connected properly will become operable. If a user tries to modify a regular
QP of a non-connected port, modify_qp() will fail. Furthermore, ibv_devinfo
should show the port state accordingly.
Note that this patch primarily improves the loading behaviour of ehca. If
the cable is removed while the driver is operating and plugged in again,
firmware will handle that properly by sending an appropriate async event.
Signed-off-by: Hoang-Nam Nguyen <hnguyen@de.ibm.com>
---
drivers/infiniband/hw/ehca/ehca_classes.h | 16 +++
drivers/infiniband/hw/ehca/ehca_irq.c | 26 ++++-
drivers/infiniband/hw/ehca/ehca_iverbs.h | 2 +
drivers/infiniband/hw/ehca/ehca_main.c | 7 +-
drivers/infiniband/hw/ehca/ehca_qp.c | 162 ++++++++++++++++++++++++++++-
drivers/infiniband/hw/ehca/ehca_sqp.c | 6 +-
6 files changed, 204 insertions(+), 15 deletions(-)
diff --git a/drivers/infiniband/hw/ehca/ehca_classes.h b/drivers/infiniband/hw/ehca/ehca_classes.h
index 936580d..2502366 100644
--- a/drivers/infiniband/hw/ehca/ehca_classes.h
+++ b/drivers/infiniband/hw/ehca/ehca_classes.h
@@ -95,6 +95,10 @@ struct ehca_sma_attr {
struct ehca_sport {
struct ib_cq *ibcq_aqp1;
struct ib_qp *ibqp_sqp[2];
+ /* lock to serialze modify_qp() calls for sqp in normal
+ * and irq path (when event PORT_ACTIVE is received first time)
+ */
+ spinlock_t mod_sqp_lock;
enum ib_port_state port_state;
struct ehca_sma_attr saved_attr;
};
@@ -141,6 +145,14 @@ enum ehca_ext_qp_type {
EQPT_SRQ = 3,
};
+/* struct to cache modify_qp()'s parms for GSI/SMI qp */
+struct ehca_mod_qp_parm {
+ int mask;
+ struct ib_qp_attr attr;
+};
+
+#define EHCA_MOD_QP_PARM_MAX 4
+
struct ehca_qp {
union {
struct ib_qp ib_qp;
@@ -164,6 +176,9 @@ struct ehca_qp {
struct ehca_cq *recv_cq;
unsigned int sqerr_purgeflag;
struct hlist_node list_entries;
+ /* array to cache modify_qp()'s parms for GSI/SMI qp */
+ struct ehca_mod_qp_parm *mod_qp_parm;
+ int mod_qp_parm_idx;
/* mmap counter for resources mapped into user space */
u32 mm_count_squeue;
u32 mm_count_rqueue;
@@ -323,6 +338,7 @@ extern int ehca_port_act_time;
extern int ehca_use_hp_mr;
extern int ehca_scaling_code;
extern int ehca_lock_hcalls;
+extern int ehca_nr_ports;
struct ipzu_queue_resp {
u32 qe_size; /* queue entry size */
diff --git a/drivers/infiniband/hw/ehca/ehca_irq.c b/drivers/infiniband/hw/ehca/ehca_irq.c
index 4c734ec..863b34f 100644
--- a/drivers/infiniband/hw/ehca/ehca_irq.c
+++ b/drivers/infiniband/hw/ehca/ehca_irq.c
@@ -356,17 +356,33 @@ static void parse_ec(struct ehca_shca *shca, u64 eqe)
u8 ec = EHCA_BMASK_GET(NEQE_EVENT_CODE, eqe);
u8 port = EHCA_BMASK_GET(NEQE_PORT_NUMBER, eqe);
u8 spec_event;
+ struct ehca_sport *sport = &shca->sport[port - 1];
+ unsigned long flags;
switch (ec) {
case 0x30: /* port availability change */
if (EHCA_BMASK_GET(NEQE_PORT_AVAILABILITY, eqe)) {
- shca->sport[port - 1].port_state = IB_PORT_ACTIVE;
+ int suppress_event;
+ /* replay modify_qp for sqps */
+ spin_lock_irqsave(&sport->mod_sqp_lock, flags);
+ suppress_event = !sport->ibqp_sqp[IB_QPT_GSI];
+ if (sport->ibqp_sqp[IB_QPT_SMI])
+ ehca_recover_sqp(sport->ibqp_sqp[IB_QPT_SMI]);
+ if (!suppress_event)
+ ehca_recover_sqp(sport->ibqp_sqp[IB_QPT_GSI]);
+ spin_unlock_irqrestore(&sport->mod_sqp_lock, flags);
+
+ /* AQP1 was destroyed, ignore this event */
+ if (suppress_event)
+ break;
+
+ sport->port_state = IB_PORT_ACTIVE;
dispatch_port_event(shca, port, IB_EVENT_PORT_ACTIVE,
"is active");
ehca_query_sma_attr(shca, port,
- &shca->sport[port - 1].saved_attr);
+ &sport->saved_attr);
} else {
- shca->sport[port - 1].port_state = IB_PORT_DOWN;
+ sport->port_state = IB_PORT_DOWN;
dispatch_port_event(shca, port, IB_EVENT_PORT_ERR,
"is inactive");
}
@@ -380,11 +396,11 @@ static void parse_ec(struct ehca_shca *shca, u64 eqe)
ehca_warn(&shca->ib_device, "disruptive port "
"%d configuration change", port);
- shca->sport[port - 1].port_state = IB_PORT_DOWN;
+ sport->port_state = IB_PORT_DOWN;
dispatch_port_event(shca, port, IB_EVENT_PORT_ERR,
"is inactive");
- shca->sport[port - 1].port_state = IB_PORT_ACTIVE;
+ sport->port_state = IB_PORT_ACTIVE;
dispatch_port_event(shca, port, IB_EVENT_PORT_ACTIVE,
"is active");
} else
diff --git a/drivers/infiniband/hw/ehca/ehca_iverbs.h b/drivers/infiniband/hw/ehca/ehca_iverbs.h
index 5485799..c469bfd 100644
--- a/drivers/infiniband/hw/ehca/ehca_iverbs.h
+++ b/drivers/infiniband/hw/ehca/ehca_iverbs.h
@@ -200,4 +200,6 @@ void ehca_free_fw_ctrlblock(void *ptr);
#define ehca_free_fw_ctrlblock(ptr) free_page((unsigned long)(ptr))
#endif
+void ehca_recover_sqp(struct ib_qp *sqp);
+
#endif
diff --git a/drivers/infiniband/hw/ehca/ehca_main.c b/drivers/infiniband/hw/ehca/ehca_main.c
index cde486c..74a4592 100644
--- a/drivers/infiniband/hw/ehca/ehca_main.c
+++ b/drivers/infiniband/hw/ehca/ehca_main.c
@@ -90,7 +90,8 @@ MODULE_PARM_DESC(hw_level,
"hardware level"
" (0: autosensing (default), 1: v. 0.20, 2: v. 0.21)");
MODULE_PARM_DESC(nr_ports,
- "number of connected ports (default: 2)");
+ "number of connected ports (-1: autodetect, 1: port one only, "
+ "2: two ports (default)");
MODULE_PARM_DESC(use_hp_mr,
"high performance MRs (0: no (default), 1: yes)");
MODULE_PARM_DESC(port_act_time,
@@ -688,7 +689,7 @@ static int __devinit ehca_probe(struct of_device *dev,
struct ehca_shca *shca;
const u64 *handle;
struct ib_pd *ibpd;
- int ret;
+ int ret, i;
handle = of_get_property(dev->node, "ibm,hca-handle", NULL);
if (!handle) {
@@ -709,6 +710,8 @@ static int __devinit ehca_probe(struct of_device *dev,
return -ENOMEM;
}
mutex_init(&shca->modify_mutex);
+ for (i = 0; i < ARRAY_SIZE(shca->sport); i++)
+ spin_lock_init(&shca->sport[i].mod_sqp_lock);
shca->ofdev = dev;
shca->ipz_hca_handle.handle = *handle;
diff --git a/drivers/infiniband/hw/ehca/ehca_qp.c b/drivers/infiniband/hw/ehca/ehca_qp.c
index 26c6a94..bb7ccef 100644
--- a/drivers/infiniband/hw/ehca/ehca_qp.c
+++ b/drivers/infiniband/hw/ehca/ehca_qp.c
@@ -729,12 +729,31 @@ static struct ehca_qp *internal_create_qp(
init_attr->cap.max_send_wr = parms.squeue.act_nr_wqes;
my_qp->init_attr = *init_attr;
+ if (qp_type == IB_QPT_SMI || qp_type == IB_QPT_GSI) {
+ shca->sport[init_attr->port_num - 1].ibqp_sqp[qp_type] =
+ &my_qp->ib_qp;
+ if (ehca_nr_ports < 0) {
+ /* alloc array to cache subsequent modify qp parms
+ * for autodetect mode
+ */
+ my_qp->mod_qp_parm =
+ kzalloc(EHCA_MOD_QP_PARM_MAX *
+ sizeof(*my_qp->mod_qp_parm),
+ GFP_KERNEL);
+ if (!my_qp->mod_qp_parm) {
+ ehca_err(pd->device,
+ "Could not alloc mod_qp_parm");
+ goto create_qp_exit4;
+ }
+ }
+ }
+
/* NOTE: define_apq0() not supported yet */
if (qp_type == IB_QPT_GSI) {
h_ret = ehca_define_sqp(shca, my_qp, init_attr);
if (h_ret != H_SUCCESS) {
ret = ehca2ib_return_code(h_ret);
- goto create_qp_exit4;
+ goto create_qp_exit5;
}
}
@@ -743,7 +762,7 @@ static struct ehca_qp *internal_create_qp(
if (ret) {
ehca_err(pd->device,
"Couldn't assign qp to send_cq ret=%i", ret);
- goto create_qp_exit4;
+ goto create_qp_exit5;
}
}
@@ -769,15 +788,19 @@ static struct ehca_qp *internal_create_qp(
if (ib_copy_to_udata(udata, &resp, sizeof resp)) {
ehca_err(pd->device, "Copy to udata failed");
ret = -EINVAL;
- goto create_qp_exit5;
+ goto create_qp_exit6;
}
}
return my_qp;
-create_qp_exit5:
+create_qp_exit6:
ehca_cq_unassign_qp(my_qp->send_cq, my_qp->real_qp_num);
+create_qp_exit5:
+ if (my_qp->mod_qp_parm)
+ kfree(my_qp->mod_qp_parm);
+
create_qp_exit4:
if (HAS_RQ(my_qp))
ipz_queue_dtor(my_pd, &my_qp->ipz_rqueue);
@@ -995,7 +1018,7 @@ static int internal_modify_qp(struct ib_qp *ibqp,
unsigned long flags = 0;
/* do query_qp to obtain current attr values */
- mqpcb = ehca_alloc_fw_ctrlblock(GFP_KERNEL);
+ mqpcb = ehca_alloc_fw_ctrlblock(GFP_ATOMIC);
if (!mqpcb) {
ehca_err(ibqp->device, "Could not get zeroed page for mqpcb "
"ehca_qp=%p qp_num=%x ", my_qp, ibqp->qp_num);
@@ -1183,6 +1206,8 @@ static int internal_modify_qp(struct ib_qp *ibqp,
update_mask |= EHCA_BMASK_SET(MQPCB_MASK_PRIM_P_KEY_IDX, 1);
}
if (attr_mask & IB_QP_PORT) {
+ struct ehca_sport *sport;
+ struct ehca_qp *aqp1;
if (attr->port_num < 1 || attr->port_num > shca->num_ports) {
ret = -EINVAL;
ehca_err(ibqp->device, "Invalid port=%x. "
@@ -1191,6 +1216,29 @@ static int internal_modify_qp(struct ib_qp *ibqp,
shca->num_ports);
goto modify_qp_exit2;
}
+ sport = &shca->sport[attr->port_num - 1];
+ if (!sport->ibqp_sqp[IB_QPT_GSI]) {
+ /* should not occur */
+ ret = -EFAULT;
+ ehca_err(ibqp->device, "AQP1 was not created for "
+ "port=%x", attr->port_num);
+ goto modify_qp_exit2;
+ }
+ aqp1 = container_of(sport->ibqp_sqp[IB_QPT_GSI],
+ struct ehca_qp, ib_qp);
+ if (ibqp->qp_type != IB_QPT_GSI &&
+ ibqp->qp_type != IB_QPT_SMI &&
+ aqp1->mod_qp_parm) {
+ /*
+ * firmware will reject this modify_qp() because
+ * port is not activated/initialized fully
+ */
+ ret = -EFAULT;
+ ehca_warn(ibqp->device, "Couldn't modify qp port=%x: "
+ "either port is being activated (try again) "
+ "or cabling issue", attr->port_num);
+ goto modify_qp_exit2;
+ }
mqpcb->prim_phys_port = attr->port_num;
update_mask |= EHCA_BMASK_SET(MQPCB_MASK_PRIM_PHYS_PORT, 1);
}
@@ -1470,6 +1518,8 @@ modify_qp_exit1:
int ehca_modify_qp(struct ib_qp *ibqp, struct ib_qp_attr *attr, int attr_mask,
struct ib_udata *udata)
{
+ struct ehca_shca *shca = container_of(ibqp->device, struct ehca_shca,
+ ib_device);
struct ehca_qp *my_qp = container_of(ibqp, struct ehca_qp, ib_qp);
struct ehca_pd *my_pd = container_of(my_qp->ib_qp.pd, struct ehca_pd,
ib_pd);
@@ -1482,9 +1532,100 @@ int ehca_modify_qp(struct ib_qp *ibqp, struct ib_qp_attr *attr, int attr_mask,
return -EINVAL;
}
+ /* The if-block below caches qp_attr to be modified for GSI and SMI
+ * qps during the initialization by ib_mad. When the respective port
+ * is activated, ie we got an event PORT_ACTIVE, we'll replay the
+ * cached modify calls sequence, see ehca_recover_sqs() below.
+ * Why that is required:
+ * 1) If one port is connected, older code requires that port one
+ * to be connected and module option nr_ports=1 to be given by
+ * user, which is very inconvenient for end user.
+ * 2) Firmware accepts modify_qp() only if respective port has become
+ * active. Older code had a wait loop of 30sec create_qp()/
+ * define_aqp1(), which is not appropriate in practice. This
+ * code now removes that wait loop, see define_aqp1(), and always
+ * reports all ports to ib_mad resp. users. Only activated ports
+ * will then usable for the users.
+ */
+ if (ibqp->qp_type == IB_QPT_GSI || ibqp->qp_type == IB_QPT_SMI) {
+ int port = my_qp->init_attr.port_num;
+ struct ehca_sport *sport = &shca->sport[port - 1];
+ unsigned long flags;
+ spin_lock_irqsave(&sport->mod_sqp_lock, flags);
+ /* cache qp_attr only during init */
+ if (my_qp->mod_qp_parm) {
+ struct ehca_mod_qp_parm *p;
+ if (my_qp->mod_qp_parm_idx >= EHCA_MOD_QP_PARM_MAX) {
+ ehca_err(&shca->ib_device,
+ "mod_qp_parm overflow state=%x port=%x"
+ " type=%x", attr->qp_state,
+ my_qp->init_attr.port_num,
+ ibqp->qp_type);
+ spin_unlock_irqrestore(&sport->mod_sqp_lock,
+ flags);
+ return -EINVAL;
+ }
+ p = &my_qp->mod_qp_parm[my_qp->mod_qp_parm_idx];
+ p->mask = attr_mask;
+ p->attr = *attr;
+ my_qp->mod_qp_parm_idx++;
+ ehca_dbg(&shca->ib_device,
+ "Saved qp_attr for state=%x port=%x type=%x",
+ attr->qp_state, my_qp->init_attr.port_num,
+ ibqp->qp_type);
+ spin_unlock_irqrestore(&sport->mod_sqp_lock, flags);
+ return 0;
+ }
+ spin_unlock_irqrestore(&sport->mod_sqp_lock, flags);
+ }
+
return internal_modify_qp(ibqp, attr, attr_mask, 0);
}
+void ehca_recover_sqp(struct ib_qp *sqp)
+{
+ struct ehca_qp *my_sqp = container_of(sqp, struct ehca_qp, ib_qp);
+ int port = my_sqp->init_attr.port_num;
+ struct ib_qp_attr attr;
+ struct ehca_mod_qp_parm *qp_parm;
+ int i, qp_parm_idx, ret;
+ unsigned long flags, wr_cnt;
+
+ if (!my_sqp->mod_qp_parm)
+ return;
+ ehca_dbg(sqp->device, "SQP port=%x qp_num=%x", port, sqp->qp_num);
+
+ qp_parm = my_sqp->mod_qp_parm;
+ qp_parm_idx = my_sqp->mod_qp_parm_idx;
+ for (i = 0; i < qp_parm_idx; i++) {
+ attr = qp_parm[i].attr;
+ ret = internal_modify_qp(sqp, &attr, qp_parm[i].mask, 0);
+ if (ret) {
+ ehca_err(sqp->device, "Could not modify SQP port=%x "
+ "qp_num=%x ret=%x", port, sqp->qp_num, ret);
+ goto free_qp_parm;
+ }
+ ehca_dbg(sqp->device, "SQP port=%x qp_num=%x in state=%x",
+ port, sqp->qp_num, attr.qp_state);
+ }
+
+ /* re-trigger posted recv wrs */
+ wr_cnt = my_sqp->ipz_rqueue.current_q_offset /
+ my_sqp->ipz_rqueue.qe_size;
+ if (wr_cnt) {
+ spin_lock_irqsave(&my_sqp->spinlock_r, flags);
+ hipz_update_rqa(my_sqp, wr_cnt);
+ spin_unlock_irqrestore(&my_sqp->spinlock_r, flags);
+ ehca_dbg(sqp->device, "doorbell port=%x qp_num=%x wr_cnt=%lx",
+ port, sqp->qp_num, wr_cnt);
+ }
+
+free_qp_parm:
+ kfree(qp_parm);
+ /* this prevents subsequent calls to modify_qp() to cache qp_attr */
+ my_sqp->mod_qp_parm = NULL;
+}
+
int ehca_query_qp(struct ib_qp *qp,
struct ib_qp_attr *qp_attr,
int qp_attr_mask, struct ib_qp_init_attr *qp_init_attr)
@@ -1772,6 +1913,7 @@ static int internal_destroy_qp(struct ib_device *dev, struct ehca_qp *my_qp,
struct ehca_shca *shca = container_of(dev, struct ehca_shca, ib_device);
struct ehca_pd *my_pd = container_of(my_qp->ib_qp.pd, struct ehca_pd,
ib_pd);
+ struct ehca_sport *sport = &shca->sport[my_qp->init_attr.port_num - 1];
u32 cur_pid = current->tgid;
u32 qp_num = my_qp->real_qp_num;
int ret;
@@ -1818,6 +1960,16 @@ static int internal_destroy_qp(struct ib_device *dev, struct ehca_qp *my_qp,
port_num = my_qp->init_attr.port_num;
qp_type = my_qp->init_attr.qp_type;
+ if (qp_type == IB_QPT_SMI || qp_type == IB_QPT_GSI) {
+ spin_lock_irqsave(&sport->mod_sqp_lock, flags);
+ if (my_qp->mod_qp_parm) {
+ kfree(my_qp->mod_qp_parm);
+ my_qp->mod_qp_parm = NULL;
+ }
+ shca->sport[port_num - 1].ibqp_sqp[qp_type] = NULL;
+ spin_unlock_irqrestore(&sport->mod_sqp_lock, flags);
+ }
+
/* no support for IB_QPT_SMI yet */
if (qp_type == IB_QPT_GSI) {
struct ib_event event;
diff --git a/drivers/infiniband/hw/ehca/ehca_sqp.c b/drivers/infiniband/hw/ehca/ehca_sqp.c
index f0792e5..79e72b2 100644
--- a/drivers/infiniband/hw/ehca/ehca_sqp.c
+++ b/drivers/infiniband/hw/ehca/ehca_sqp.c
@@ -40,11 +40,8 @@
*/
-#include <linux/module.h>
-#include <linux/err.h>
#include "ehca_classes.h"
#include "ehca_tools.h"
-#include "ehca_qes.h"
#include "ehca_iverbs.h"
#include "hcp_if.h"
@@ -93,6 +90,9 @@ u64 ehca_define_sqp(struct ehca_shca *shca,
return H_PARAMETER;
}
+ if (ehca_nr_ports < 0) /* autodetect mode */
+ return H_SUCCESS;
+
for (counter = 0;
shca->sport[port - 1].port_state != IB_PORT_ACTIVE &&
counter < ehca_port_act_time;
--
1.5.2
^ permalink raw reply related
* [PATCH 2/4] IB/ehca: Define array to store SMI/GSI QPs
From: Joachim Fenkes @ 2008-01-17 14:04 UTC (permalink / raw)
To: LinuxPPC-Dev, LKML, OF-General, Roland Dreier, OF-EWG
Cc: Stefan Roscher, Christoph Raisch
In-Reply-To: <200801171502.34287.fenkes@de.ibm.com>
From: Hoang-Nam Nguyen <hnguyen at de.ibm.com>
Signed-off-by: Hoang-Nam Nguyen <hnguyen@de.ibm.com>
---
drivers/infiniband/hw/ehca/ehca_classes.h | 2 +-
drivers/infiniband/hw/ehca/ehca_main.c | 6 +++---
2 files changed, 4 insertions(+), 4 deletions(-)
diff --git a/drivers/infiniband/hw/ehca/ehca_classes.h b/drivers/infiniband/hw/ehca/ehca_classes.h
index 74d2b72..936580d 100644
--- a/drivers/infiniband/hw/ehca/ehca_classes.h
+++ b/drivers/infiniband/hw/ehca/ehca_classes.h
@@ -94,7 +94,7 @@ struct ehca_sma_attr {
struct ehca_sport {
struct ib_cq *ibcq_aqp1;
- struct ib_qp *ibqp_aqp1;
+ struct ib_qp *ibqp_sqp[2];
enum ib_port_state port_state;
struct ehca_sma_attr saved_attr;
};
diff --git a/drivers/infiniband/hw/ehca/ehca_main.c b/drivers/infiniband/hw/ehca/ehca_main.c
index 6a56d86..cde486c 100644
--- a/drivers/infiniband/hw/ehca/ehca_main.c
+++ b/drivers/infiniband/hw/ehca/ehca_main.c
@@ -511,7 +511,7 @@ static int ehca_create_aqp1(struct ehca_shca *shca, u32 port)
}
sport->ibcq_aqp1 = ibcq;
- if (sport->ibqp_aqp1) {
+ if (sport->ibqp_sqp[IB_QPT_GSI]) {
ehca_err(&shca->ib_device, "AQP1 QP is already created.");
ret = -EPERM;
goto create_aqp1;
@@ -537,7 +537,7 @@ static int ehca_create_aqp1(struct ehca_shca *shca, u32 port)
ret = PTR_ERR(ibqp);
goto create_aqp1;
}
- sport->ibqp_aqp1 = ibqp;
+ sport->ibqp_sqp[IB_QPT_GSI] = ibqp;
return 0;
@@ -550,7 +550,7 @@ static int ehca_destroy_aqp1(struct ehca_sport *sport)
{
int ret;
- ret = ib_destroy_qp(sport->ibqp_aqp1);
+ ret = ib_destroy_qp(sport->ibqp_sqp[IB_QPT_GSI]);
if (ret) {
ehca_gen_err("Cannot destroy AQP1 QP. ret=%i", ret);
return ret;
--
1.5.2
^ permalink raw reply related
* [PATCH 1/4] IB/ehca: Remove CQ-QP-link before destroying QP in error path of create_qp()
From: Joachim Fenkes @ 2008-01-17 14:03 UTC (permalink / raw)
To: LinuxPPC-Dev, LKML, OF-General, Roland Dreier, OF-EWG
Cc: Stefan Roscher, Christoph Raisch
In-Reply-To: <200801171502.34287.fenkes@de.ibm.com>
From: Hoang-Nam Nguyen <hnguyen at de.ibm.com>
Signed-off-by: Hoang-Nam Nguyen <hnguyen@de.ibm.com>
---
drivers/infiniband/hw/ehca/ehca_qp.c | 5 ++++-
1 files changed, 4 insertions(+), 1 deletions(-)
diff --git a/drivers/infiniband/hw/ehca/ehca_qp.c b/drivers/infiniband/hw/ehca/ehca_qp.c
index f116eb7..26c6a94 100644
--- a/drivers/infiniband/hw/ehca/ehca_qp.c
+++ b/drivers/infiniband/hw/ehca/ehca_qp.c
@@ -769,12 +769,15 @@ static struct ehca_qp *internal_create_qp(
if (ib_copy_to_udata(udata, &resp, sizeof resp)) {
ehca_err(pd->device, "Copy to udata failed");
ret = -EINVAL;
- goto create_qp_exit4;
+ goto create_qp_exit5;
}
}
return my_qp;
+create_qp_exit5:
+ ehca_cq_unassign_qp(my_qp->send_cq, my_qp->real_qp_num);
+
create_qp_exit4:
if (HAS_RQ(my_qp))
ipz_queue_dtor(my_pd, &my_qp->ipz_rqueue);
--
1.5.2
^ permalink raw reply related
* [PATCH 0/4] IB/ehca: fixes, port connectivity autodetection, problem workaround
From: Joachim Fenkes @ 2008-01-17 14:02 UTC (permalink / raw)
To: LinuxPPC-Dev, LKML, OF-General, Roland Dreier, OF-EWG
Cc: Stefan Roscher, Christoph Raisch
This patchset will fix a minor issue, introduce port connectivity
autodetection and work around an RDMA-related problem in eHCA2.
[1/4] fixes an error path in destroy_qp()
[2/4] stores the SMI/GSI QPs in a per-port array
[3/4] adds port connectivity autodetection
[4/4] adds the aforementioned workaround
The patches will apply, in order, on top of Roland's for-2.6.25 branch.
Please review them and apply for 2.6.25 if you think they're okay.
Thanks and regards,
Joachim
--
Joachim Fenkes -- eHCA Linux Driver Developer and Hardware Tamer
IBM Deutschland Entwicklung GmbH -- Dept. 3627 (I/O Firmware Dev. 2)
Schoenaicher Strasse 220 -- 71032 Boeblingen -- Germany
eMail: fenkes@de.ibm.com
^ permalink raw reply
* Re: [PATCH/RFC] [POWERPC] CPM1: implement GPIO LIB API
From: Grant Likely @ 2008-01-17 13:47 UTC (permalink / raw)
To: Jochen Friedrich; +Cc: Arnd Bergmann, linuxppc-dev, David Gibson
In-Reply-To: <478F4514.7030906@scram.de>
Hi Jochen,
comments below.
On 1/17/08, Jochen Friedrich <jochen@scram.de> wrote:
> Signed-off-by: Jochen Friedrich <jochen@scram.de>
> ---
Need a more detailed change description.
> arch/powerpc/platforms/8xx/Kconfig | 2 +
> arch/powerpc/sysdev/commproc.c | 162 +++++++++++++++++++++++++++++++++++-
Is this 8xx only? Can it live in arch/powerpc/platforms/8xx?
> 2 files changed, 163 insertions(+), 1 deletions(-)
>
> +static struct of_gpio_chip cpm1_gc16 = {
> + .gpio_cells = 1,
> + .xlate = of_gpio_simple_xlate,
> +
> + .gc = {
> + .ngpio = 16,
> + .direction_input = cpm1_gpio_dir_in16,
> + .direction_output = cpm1_gpio_dir_out16,
> + .get = cpm1_gpio_get16,
> + .set = cpm1_gpio_set16,
> + },
> +};
<snip>
> +static struct of_gpio_chip cpm1_gc32 = {
> + .gpio_cells = 1,
> + .xlate = of_gpio_simple_xlate,
> +
> + .gc = {
> + .ngpio = 32,
> + .direction_input = cpm1_gpio_dir_in32,
> + .direction_output = cpm1_gpio_dir_out32,
> + .get = cpm1_gpio_get32,
> + .set = cpm1_gpio_set32,
> + },
> +};
Nit: Your naming convention seems a little backwards. It took me a
moment to figure out what your hooks lined up with. Can you make the
'16' and '32' part of the prefix instead of appended on the end?
ie. use 'cpm1_gpio16_dir_in' instead of 'cpm1_gpio_dir_in16'
> +int cpm1_gpiochip_add32(struct device_node *np)
> +{
> + return of_mm_gpiochip_add(np, &cpm1_gc32);
> +}
Can you just drop this function and roll it into cpm_init_par_io?
> +
> +static int cpm_init_par_io(void)
> +{
> + struct device_node *np;
> +
> + for_each_compatible_node(np, NULL, "fsl,cpm1-pario-bank16")
> + cpm1_gpiochip_add16(np);
> +
> + for_each_compatible_node(np, NULL, "fsl,cpm1-pario-bank32")
> + cpm1_gpiochip_add32(np);
> + return 0;
> +}
> +arch_initcall(cpm_init_par_io);
Cheers,
g.
--
Grant Likely, B.Sc., P.Eng.
Secret Lab Technologies Ltd.
^ permalink raw reply
* error: array type has incomplete element type
From: WEHBI Rami @ 2008-01-17 13:25 UTC (permalink / raw)
To: linuxppc-embedded
[-- Attachment #1: Type: text/plain, Size: 2331 bytes --]
Hi all,
I am trying to compile a kernel for the ppc405 embedded on the virtex 4 and I am obtaining the compiling errors listed below(at the end of this mail).
my compiler is the crosstool latest one.
I tried to compile each the following kernel versions :
2.6.23.8
2.6.17
with the following versions of gcc and glibc of the crosscompiler
gcc-4.0.2-glibc-2.3.5
gcc-4.1.0-glibc-2.3.6
gcc-4.1.1-glibc-2.3.6
the result is always the same (array type has incomplete element type)
moreover I searched all the files and I replaced
(struct ocp_def core_ocp[]) with (struct ocp_def core_ocp[2])
because my architectur contains only one UART, the result is always the same (same error).
any help is appreciated,
arch/ppc/syslib/virtex_devices.c:23: error: array type has incomplete element type
arch/ppc/syslib/virtex_devices.c:25: error: field name not in record or union initializer
arch/ppc/syslib/virtex_devices.c:25: error: (near initialization for 'core_ocp')
arch/ppc/syslib/virtex_devices.c:26: error: field name not in record or union initializer
arch/ppc/syslib/virtex_devices.c:26: error: (near initialization for 'core_ocp')
arch/ppc/syslib/virtex_devices.c:27: error: field name not in record or union initializer
arch/ppc/syslib/virtex_devices.c:27: error: (near initialization for 'core_ocp')
arch/ppc/syslib/virtex_devices.c:28: error: field name not in record or union initializer
arch/ppc/syslib/virtex_devices.c:28: error: (near initialization for 'core_ocp')
arch/ppc/syslib/virtex_devices.c:29: error: field name not in record or union initializer
arch/ppc/syslib/virtex_devices.c:29: error: (near initialization for 'core_ocp')
arch/ppc/syslib/virtex_devices.c:30: error: field name not in record or union initializer
arch/ppc/syslib/virtex_devices.c:30: error: (near initialization for 'core_ocp')
arch/ppc/syslib/virtex_devices.c:30: error: 'OCP_CPM_NA' undeclared here (not in a function)
arch/ppc/syslib/virtex_devices.c:63: error: field name not in record or union initializer
arch/ppc/syslib/virtex_devices.c:63: error: (near initialization for 'core_ocp')
Rami
---------------------------------
Ne gardez plus qu'une seule adresse mail ! Copiez vos mails vers Yahoo! Mail
[-- Attachment #2: Type: text/html, Size: 4601 bytes --]
^ permalink raw reply
* Re: [PATCH/RFC] [POWERPC] CPM1: implement GPIO LIB API
From: Anton Vorontsov @ 2008-01-17 13:06 UTC (permalink / raw)
To: Jochen Friedrich; +Cc: Arnd Bergmann, linuxppc-dev, David Gibson
In-Reply-To: <478F4514.7030906@scram.de>
Hi Jochen,
Thanks for the patch.
On Thu, Jan 17, 2008 at 01:07:48PM +0100, Jochen Friedrich wrote:
> Signed-off-by: Jochen Friedrich <jochen@scram.de>
> ---
> arch/powerpc/platforms/8xx/Kconfig | 2 +
> arch/powerpc/sysdev/commproc.c | 162
> +++++++++++++++++++++++++++++++++++-
> 2 files changed, 163 insertions(+), 1 deletions(-)
Something happened wrt long lines, your editor seem to wrap them. :-(
> diff --git a/arch/powerpc/platforms/8xx/Kconfig
> b/arch/powerpc/platforms/8xx/Kconfig
> index 91fbe42..08e927c 100644
> --- a/arch/powerpc/platforms/8xx/Kconfig
> +++ b/arch/powerpc/platforms/8xx/Kconfig
[...]
> diff --git a/arch/powerpc/sysdev/commproc.c b/arch/powerpc/sysdev/commproc.c
> index 621bc6c..be78e65 100644
> --- a/arch/powerpc/sysdev/commproc.c
> +++ b/arch/powerpc/sysdev/commproc.c
[...]
> +int cpm1_gpiochip_add16(struct device_node *np)
> +{
> + return of_mm_gpiochip_add(np, &cpm1_gc16);
> +}
(1)
> +int cpm1_gpiochip_add32(struct device_node *np)
> +{
> + return of_mm_gpiochip_add(np, &cpm1_gc32);
> +}
(2)
> +static int cpm_init_par_io(void)
> +{
> + struct device_node *np;
> +
> + for_each_compatible_node(np, NULL, "fsl,cpm1-pario-bank16")
> + cpm1_gpiochip_add16(np);
> +
> + for_each_compatible_node(np, NULL, "fsl,cpm1-pario-bank32")
> + cpm1_gpiochip_add32(np);
> + return 0;
> +}
> +arch_initcall(cpm_init_par_io);
I was unable to use arch_initcall() because lack of kmalloc() that
early (needed for of_mm_gpiochip_add() and GPIO LIB in general). So,
does it really work here?
Though, I tried arch_initcall() in the board file, and well... link
order matters a lot, so arch_initcall could indeed work in the
arch/powerpc/sysdev/. I should try that for QE. :-)
If it works, you'd better make (1) and (2) static, or just remove
them completely, since there are no users outside of this file.
Thanks!
--
Anton Vorontsov
email: cbou@mail.ru
backup email: ya-cbou@yandex.ru
irc://irc.freenode.net/bd2
^ permalink raw reply
* I have some problem about BDI 2000
From: Sdeven.Lee @ 2008-01-17 12:33 UTC (permalink / raw)
To: linuxppc-embedded
bGludXhwcGMtZW1iZWRkZWSjrMT6usOjoQ0KDQoJV2hlbiBJIHVzZSB0aGUgQkRJLTIwMDAsIGl0
IHJlcG9ydHM6IA0KDQoqKiogVEFSR0VUOiBwcm9jZXNzaW5nIHRhcmdldCBzdGFydHVwIGZhaWxl
ZA0KIyBQUEM6IEpUQUcgaW5zdHJ1Y3Rpb24gc3R1ZmYgb3ZlcnJ1bg0KDQoJQ2FuIGFueW9uZSB0
ZWxsIG1lIHdoeSBhbmQgaG93IHRvIHNvdmxlPyAgVGhhbmtzIGEgbG90IQ0KDQoJDQoNCqGhoaGh
oaGhoaGhoaGhoaFTZGV2ZW4uTGVlDQqhoaGhoaGhoaGhoaGhoaGhc2RldmVuLmxlZUAxNjMuY29t
DQqhoaGhoaGhoaGhoaGhoaGhoaGhoTIwMDgtMDEtMTcNCg==
^ permalink raw reply
page: next (older) | prev (newer) | latest
- recent:[subjects (threaded)|topics (new)|topics (active)]
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox