* Re: [PATCH 1/2] Make setjmp/longjmp code generic
From: Michael Neuling @ 2007-12-12 11:09 UTC (permalink / raw)
To: benh; +Cc: Stephen Rothwell, THEMANN, linuxppc-dev, RAISCH, Paul Mackerras
In-Reply-To: <1197452676.8385.116.camel@pasglop>
> On Wed, 2007-12-12 at 20:37 +1100, Stephen Rothwell wrote:
> > On Wed, 12 Dec 2007 19:06:54 +1100 Benjamin Herrenschmidt <benh@kernel.cras
hing.org> wrote:
> > >
> > > Time to introduce a merged misc.S ? :-)
> >
> > We already have one ...
>
> Hah ! I should have looked :-)
Me too! :-)
Sorry Kumar, I'll fix.
Mikey
^ permalink raw reply
* Re: [ewg] Re: [PATCH] IB/ehca: Serialize HCA-related hCalls on POWER5
From: Or Gerlitz @ 2007-12-12 12:14 UTC (permalink / raw)
To: Joachim Fenkes
Cc: Arnd Bergmann, Roland Dreier, LKML, linuxppc-dev,
Christoph Raisch, OF-General, Stefan Roscher
In-Reply-To: <OFD9564F75.44193623-ONC12573AE.002EA542-C12573AE.002F5FBC@de.ibm.com>
Joachim Fenkes wrote:
> Roland Dreier <rdreier@cisco.com> wrote on 10.12.2007 22:47:37:
>> It's an optional device feature, so this should be OK
>> (although the iSER driver currently seems to depend on a device
>> supporting FMRs, which is probably going to be a problem with iWARP
>> support in the future anyway).
> I don't feel very well with removing code from the driver that iSER seems
> to depend on. Are there plans to fix this in iSER?
What is the fix you suggest, to add a device query that tells you for
which verbs the documentation does not apply? or enhance the code of the
map_phys_fmr verb within the ehca driver to return error if called
from non-sleepable context?
Or.
^ permalink raw reply
* Re: [PATCH RFC 0/7] "NAND on UPM" and related patches
From: Anton Vorontsov @ 2007-12-12 12:47 UTC (permalink / raw)
To: linuxppc-dev
In-Reply-To: <20071211003647.GB12363@localhost.localdomain>
On Tue, Dec 11, 2007 at 11:36:47AM +1100, David Gibson wrote:
[...]
> > > > OF device tree GPIOs bindings are similar to IRQs:
> > > >
> > > > node {
> > > > gpios = <bank pin bank pin bank pin>;
> > > > gpio-parent = <&par_io_controller>;
> > > > };
> > > >
> > > > "bank pin" scheme is controller specific, so controllers that want
> > > > to implement flat mappings or any other could do so.
> > >
> > > It might be safest to do as is done for interrupts, and not define the
> > > internal format at all.
> >
> > This is how it is done already. Take a look into second and third patches:
> >
> > +static int par_io_xlate(struct device_node *np, int index)
> > +{
> > + return __of_parse_gpio_bank_pin(np, index, 32, num_par_io_ports);
> > +}
> > +
> > +static struct of_gpio_chip of_gpio_chip = {
> > + .xlate = par_io_xlate,
> > +};
> >
> > __of_parse_gpio_bank_pin() is helper function, I just factored
> > it out, because both QE and CPM2 using same format.
> >
> > But generally, controllers are encouraged to do their own xlates.
> >
> > Or am I missing the point?
>
> Right, but you are assuming a fixed size (2 cells?)
Nope, of_get_gpio() doesn't assume that, but per-controller's .xlate()
is free to assume (and check) that, right.
> for the bank/pin
> information, arent' you - I didn't see any #gpio-cells or similar
> looking property.
Well, per-controller .xlate() is checking for correct cell count
(just reminding -- __of_parse_gpio_bank_pin is helper function,
controllers are free to implement their own):
int __of_parse_gpio_bank_pin(struct device_node *np, int index,
int bank_width, int max_bank)
{
...
gpios = of_get_property(np, "gpios", &len);
len /= sizeof(u32);
if (len < 2 || len % 2 || index > len / 2 - 1)
return -EINVAL;
...
}
On the other hand, I might indeed introduce #gpio-cells, and move
that check into generic of_get_gpio(), which will use #gpio-cells.
I think this is good idea anyway, so I'll just do it. ;-)
> I'm wondering if some gpio controllers might want
> less (only one bank) or more (bank, pin, polarity/flags perhaps).
Yup, they might. With #gpio-cells or without. The matter of where
to place sanity checks.
Much thanks,
--
Anton Vorontsov
email: cbou@mail.ru
backup email: ya-cbou@yandex.ru
irc://irc.freenode.net/bd2
^ permalink raw reply
* Re: Lnux 2.6.24-rc5
From: Josh Boyer @ 2007-12-12 12:54 UTC (permalink / raw)
To: subrata; +Cc: Linuxppc-dev
In-Reply-To: <1197453301.4710.71.camel@subratamodak.linux.ibm.com>
On Wed, 12 Dec 2007 15:25:01 +0530
Subrata Modak <subrata@linux.vnet.ibm.com> wrote:
> On Mon, 2007-12-10 at 21:40 -0800, Linus Torvalds wrote:
> > It's been a week, and I promised to be a good boy and try to follow my
> > release rules, so here is the next -rc.
> >
> > Things _have_ slowed down, although I'd obviously be lying if I said we've
> > got all the regressions handled and under control. They are being worked
> > on, and the list is shrinking, but at a guess, we're definitely not going
> > to have a final 2.6.24 out before xmas unless santa puts some more elves
> > to work on those regressions..
> >
> > So any elves out there - please keep working.
> >
> > I'm including the shortlog since it's small enough, and quite frankly,
> > gives about as readable explanation of the changes as can be imagined.
> > Nothing hugely exciting here.
> >
> > I'd post the diffstat too, but it's not really all that interesting, and
> > it only highlights a textually big PA-RISC revert, and the powerpc
> > defconfig updates. And the Blackfin SPI driver. The rest is largely random
> > noise in various subsystems (drivers/net, xfs filesystem, and arch updates
> > are some of the areas that show more changes).
> >
> > Linus
> >
> > ---
> >
> > Benjamin Herrenschmidt (6):
> > ibm_newemac: Fix ZMII refcounting bug
> > ibm_newemac: Workaround reset timeout when no link
> > ibm_newemac: Cleanup/Fix RGMII MDIO support detection
> > ibm_newemac: Cleanup/fix support for STACR register variants
> > ibm_newemac: Update file headers copyright notices
> > powerpc: Fix IDE legacy vs. native fixups
> >
>
> Dear Benjamin,
>
> Since you are working on Device drivers, do you want to see whether your
> Device drivers testcases can fit in here in LTP:
> http://ltp.cvs.sourceforge.net/ltp/ltp/testcases/kernel/device-drivers/,
There are no testcases for the EMAC drivers per se. Also, I don't see
any testcases for any network driver in there at all. Is that not
something LTP is testing yet?
josh
^ permalink raw reply
* Re: Lnux 2.6.24-rc5
From: Subrata Modak @ 2007-12-12 12:59 UTC (permalink / raw)
To: Josh Boyer; +Cc: Linuxppc-dev
In-Reply-To: <20071212065437.73e708ef@weaponx>
On Wed, 2007-12-12 at 06:54 -0600, Josh Boyer wrote:
> On Wed, 12 Dec 2007 15:25:01 +0530
> Subrata Modak <subrata@linux.vnet.ibm.com> wrote:
>
> > On Mon, 2007-12-10 at 21:40 -0800, Linus Torvalds wrote:
> > > It's been a week, and I promised to be a good boy and try to follow my
> > > release rules, so here is the next -rc.
> > >
> > > Things _have_ slowed down, although I'd obviously be lying if I said we've
> > > got all the regressions handled and under control. They are being worked
> > > on, and the list is shrinking, but at a guess, we're definitely not going
> > > to have a final 2.6.24 out before xmas unless santa puts some more elves
> > > to work on those regressions..
> > >
> > > So any elves out there - please keep working.
> > >
> > > I'm including the shortlog since it's small enough, and quite frankly,
> > > gives about as readable explanation of the changes as can be imagined.
> > > Nothing hugely exciting here.
> > >
> > > I'd post the diffstat too, but it's not really all that interesting, and
> > > it only highlights a textually big PA-RISC revert, and the powerpc
> > > defconfig updates. And the Blackfin SPI driver. The rest is largely random
> > > noise in various subsystems (drivers/net, xfs filesystem, and arch updates
> > > are some of the areas that show more changes).
> > >
> > > Linus
> > >
> > > ---
> > >
> > > Benjamin Herrenschmidt (6):
> > > ibm_newemac: Fix ZMII refcounting bug
> > > ibm_newemac: Workaround reset timeout when no link
> > > ibm_newemac: Cleanup/Fix RGMII MDIO support detection
> > > ibm_newemac: Cleanup/fix support for STACR register variants
> > > ibm_newemac: Update file headers copyright notices
> > > powerpc: Fix IDE legacy vs. native fixups
> > >
> >
> > Dear Benjamin,
> >
> > Since you are working on Device drivers, do you want to see whether your
> > Device drivers testcases can fit in here in LTP:
> > http://ltp.cvs.sourceforge.net/ltp/ltp/testcases/kernel/device-drivers/,
>
> There are no testcases for the EMAC drivers per se. Also, I don't see
> any testcases for any network driver in there at all. Is that not
> something LTP is testing yet?
Nope. LTP is not doing that. Like lkml it is also dependent on community
for contributions. Our Device Driver Test cases needs to be
re-rejuvenated as they are pretty old. I am of the idea of maintaining
Architecture specific device drivers testcases inside LTP as well
provided you guys give me the required test cases.
--Subrata
>
> josh
^ permalink raw reply
* Re: [PATCH] Fix rounding bug in emulation for double floatoperating
From: Kumar Gala @ 2007-12-12 13:36 UTC (permalink / raw)
To: Zang Roy-r61911; +Cc: linuxppc-dev list, Liu Yu, David Gibson
In-Reply-To: <1197448223.29372.12.camel@localhost.localdomain>
>> When I run this on a G5 (w/HW FP) I get:
>>
>> dmul 3fe0000000000000 * 1 = 0 expected 0 (PASS)
>> dmul bfe0000000000000 * 1 = 8000000000000000 expected 0 (PASS)
>> dmul 8000000000000001 * bfe0000000000000 = 0 expected 0 (PASS)
>>
>> ddiv 1 / 4000000000000000 = 0 expected 0 (PASS)
>>
>> and on the 85xx w/FP emu:
>>
>> dmul 3fe0000000000000 * 1 = 0 expected 0 (PASS)
>> dmul bfe0000000000000 * 1 = 8000000000000000 expected 0 (PASS)
>> dmul 8000000000000001 * bfe0000000000000 = 0 expected 0 (PASS)
>>
>> ddiv 1 / 4000000000000000 = 0 expected 0 (PASS)
>>
>> Maybe I'm missing where the error is.
> I am missing ...
> It is supposed to run based on previous IEEE 754 patch.
> http://ozlabs.org/pipermail/linuxppc-dev/2007-February/031351.html
Ok, but the test case should care if we are doing full "classic"
emulation or fixup of e500 FP.
- k
^ permalink raw reply
* Re: [PATCH v5] qe: add ability to upload QE firmware
From: Timur Tabi @ 2007-12-12 15:17 UTC (permalink / raw)
To: galak; +Cc: linuxppc-dev
In-Reply-To: <11970422334145-git-send-email-timur@freescale.com>
Timur Tabi wrote:
> Define the layout of a binary blob that contains a QE firmware and instructions
> on how to upload it. Add function qe_upload_firmware() to parse the blob
> and perform the actual upload. Fully define 'struct rsp' in immap_qe.h to
> include the actual RISC Special Registers. Added description of a new
> QE firmware node to booting-without-of.txt.
If there are no objections, I'd like this patch to be pulled into for-2.6.25.
Thanks.
--
Timur Tabi
Linux kernel developer at Freescale
^ permalink raw reply
* Re: [PATCH 1/2] qe: add function qe_clock_source()
From: Timur Tabi @ 2007-12-12 15:19 UTC (permalink / raw)
To: galak; +Cc: netdev, linuxppc-dev
In-Reply-To: <1196716680381-git-send-email-timur@freescale.com>
Timur Tabi wrote:
> Add function qe_clock_source() which takes a string containing the name of a
> QE clock source (as is typically found in device trees) and returns the
> matching enum qe_clock value.
>
> Update booting-without-of.txt to indicate that the UCC properties rx-clock
> and tx-clock are deprecated and replaced with rx-clock-name and tx-clock-name,
> which use strings instead of numbers to indicate QE clock sources.
>
> Signed-off-by: Timur Tabi <timur@freescale.com>
If there are no objections, I'd like this patch to be pulled into 2.6.25. Thanks.
--
Timur Tabi
Linux kernel developer at Freescale
^ permalink raw reply
* Re: [PATCH 2/2] ucc_geth: use rx-clock-name and tx-clock-name device tree properties
From: Timur Tabi @ 2007-12-12 15:19 UTC (permalink / raw)
To: galak; +Cc: netdev, linuxppc-dev
In-Reply-To: <1196716685975-git-send-email-timur@freescale.com>
Timur Tabi wrote:
> Updates the ucc_geth device driver to check the new rx-clock-name and
> tx-clock-name properties first. If present, it uses the new function
> qe_clock_source() to obtain the clock source. Otherwise, it checks the
> deprecated rx-clock and tx-clock properties.
>
> Update the device trees for 832x, 836x, and 8568 to contain the new property
> names only.
>
> Signed-off-by: Timur Tabi <timur@freescale.com>
If there are no objections, I'd like this patch to be pulled into 2.6.25. Thanks.
--
Timur Tabi
Linux kernel developer at Freescale
^ permalink raw reply
* RE: USB configuration
From: Pedro Luis D. L. @ 2007-12-12 15:23 UTC (permalink / raw)
To: linuxppc-embedded
In-Reply-To: <14206951.post@talk.nabble.com>
> From: misbah_khan@engineer.com
> To: linuxppc-embedded@ozlabs.org
> Subject: RE: USB configuration
>=20
>=20
> I have inserted a USB card reader, and the following dmesg it shows .....
>=20
> -------------------------------------------------------------------------=
------
> mpc8272ads: Init
> PCI: Probing PCI hardware
> PCI: Cannot allocate resource region 0 of device 0000:00:00.0
> PCI: Cannot allocate resource region 1 of device 0000:00:00.0
> SCSI subsystem initialized
> Linux Kernel Card Services
> options: [pci] [cardbus]
> usbcore: registered new driver usbfs
> usbcore: registered new driver hub
> Serial: CPM driver $Revision: 0.01 $
> ttyCPM0 at MMIO 0xf0011a00 (irq =3D 40) is a CPM UART
> ttyCPM1 at MMIO 0xf0011a60 (irq =3D 43) is a CPM UART
> io scheduler noop registered
> io scheduler anticipatory registered
> io scheduler deadline registered
> io scheduler cfq registered
> loop: loaded (max 8 devices)
> fs_enet.c:v1.0 (Aug 8, 2005)
> fs_enet: eth0 Phy @ 0x0, type DM9161 (0x0181b881)
> fs_enet: eth1 Phy @ 0x3, type DM9161 (0x0181b881)
> Uniform Multi-Platform E-IDE driver Revision: 7.00alpha2
> ide: Assuming 33MHz system bus speed for PIO modes; override with idebus=
=3Dxx
> st: Version 20041025, fixed bufsize 32768, s/g segs 256
> osst :I: Tape driver with OnStream support version 0.99.1
> osst :I: $Id: osst.c,v 1.70 2003/12/23 14:22:12 wriede Exp $
> ohci_hcd: 2004 Nov 08 USB 1.1 'Open' Host Controller (OHCI) Driver (PCI)
> ohci_hcd: block sizes: ed 64 td 64
> drivers/usb/serial/usb-serial.c: USB Serial support registered for Generi=
c
> usbcore: registered new driver usbserial_generic
> usbcore: registered new driver usbserial
> drivers/usb/serial/usb-serial.c: USB Serial Driver core v2.0
> NET: Registered protocol family 2
> IP: routing cache hash table of 512 buckets, 4Kbytes
> TCP: Hash tables configured (established 4096 bind 8192)
> NET: Registered protocol family 1
> NET: Registered protocol family 17
> IP-Config: Complete:
> device=3Deth1, addr=3D192.168.33.136, mask=3D255.255.248.0,
> gw=3D192.168.32.47,
> host=3Dcashel, domain=3D, nis-domain=3D(none),
> bootserver=3D192.168.33.96, rootserver=3D192.168.33.96, rootpath=3D
> Looking up port of RPC 100003/2 on 192.168.33.96
> Looking up port of RPC 100005/1 on 192.168.33.96
> VFS: Mounted root (nfs filesystem).
> Freeing unused kernel memory: 104k init
> -------------------------------------------------------------------------=
-------------
>=20
It looks like it is well configured, because the usbfs and hub are loaded. =
You could check in your kernel configuration that you enabled USB Mass stor=
age driver and attached a pen drive as I suggested before.
Another possibility is to insert a card in the USB card reader. Then you sh=
ould be able to see with dmesg if it is recognized.
Pedro.
> This doesent gives me the clear explaination of whether USB is working
> properly....
>=20
> I would appreciate if you could share with me the basic steps to be follo=
wed
> to confirm that the USB support that i had configured is being tested in =
all
> aspects.
>=20
> Misbah
>=20
> Pedro Luis D. L. wrote:
>>=20
>>=20
>>=20
>>> Date: Thu, 6 Dec 2007 05:27:14 -0800
>>> From: misbah_khan@engineer.com
>>> To: linuxppc-embedded@ozlabs.org
>>> Subject: USB configuration
>>>=20
>>>=20
>>> HI all ...
>>=20
>> Hi,
>>=20
>>> I have configured the Montavista Kernel for USB support and for
>>> PPC8272-ADS
>>> board I need to know that how could i test that my USB is working ????
>>>=20
>>=20
>> Try to attach an USB device, like a pendrive, to an USB port. Then type=
:=20
>> dmesg | tail
>>=20
>> If the USB support is working properly, you should see some output sayin=
g
>> which device have you attached and where is it mapped.
>> If you plug a memory stick, you can try to mount it and check that the
>> filesystem is correct.
>>=20
>> Pedro.
>>=20
>>> Its creating the directory :- /proc/bus/usb/ but doesent contain any fi=
le
>>> under it ????
>>>=20
>>>=20
>>> its also creating the directory :- /sys/bus/usb/ but doesent contain
>>> any
>>> file under it ????
>>>=20
>>>=20
>>> Please let me know the procedure to test whether my USB configuration i=
s
>>> all
>>> right ????
>>>=20
>>> Thank u=20
>>> Misbah <><
>>> --=20
>>> View this message in context:
>>> http://www.nabble.com/USB-configuration-tf4956061.html#a14192347
>>> Sent from the linuxppc-embedded mailing list archive at Nabble.com.
>>>=20
>>> _______________________________________________
>>> Linuxppc-embedded mailing list
>>> Linuxppc-embedded@ozlabs.org
>>> https://ozlabs.org/mailman/listinfo/linuxppc-embedded
>>=20
>> _________________________________________________________________
>> Tecnolog=EDa, moda, motor, viajes,=85suscr=EDbete a nuestros boletines p=
ara
>> estar a la =FAltima
>> http://newsletters.msn.com/hm/maintenanceeses.asp?L=3DES&C=3DES&P=3DWCMa=
intenance&Brand=3DWL&RU=3Dhttp%3a%2f%2fmail.live.com
>> _______________________________________________
>> Linuxppc-embedded mailing list
>> Linuxppc-embedded@ozlabs.org
>> https://ozlabs.org/mailman/listinfo/linuxppc-embedded
>>=20
>>=20
>=20
> --=20
> View this message in context: http://www.nabble.com/USB-configuration-tf4=
956061.html#a14206951
> Sent from the linuxppc-embedded mailing list archive at Nabble.com.
>=20
> _______________________________________________
> Linuxppc-embedded mailing list
> Linuxppc-embedded@ozlabs.org
> https://ozlabs.org/mailman/listinfo/linuxppc-embedded
_________________________________________________________________
MSN Video.=20
http://video.msn.com/?mkt=3Des-es=
^ permalink raw reply
* Re: [PATCH RFC 3/7] [POWERPC] CPM2: implement GPIO API
From: Jochen Friedrich @ 2007-12-12 15:49 UTC (permalink / raw)
To: Anton Vorontsov; +Cc: linuxppc-dev
In-Reply-To: <20071210204845.GC32278@localhost.localdomain>
Hi Anton,
> +int gpio_direction_input(unsigned int gpio)
> +{
> + unsigned long flags;
> + int port = gpio / 32;
> + int pin = gpio % 32;
> +
> + spin_lock_irqsave(&cpm2_port_locks[port], flags);
> +
> + cpm2_set_pin(port, pin, CPM_PIN_INPUT | CPM_PIN_GPIO);
> +int gpio_direction_output(unsigned int gpio, int value)
> +{
> + struct cpm2_ioports __iomem *iop =
> + (struct cpm2_ioports __iomem *)&cpm2_immr->im_ioport;
> + int port = gpio / 32;
> + int pin = gpio % 32;
> + unsigned long flags;
> +
> + pin = 1 << (31 - pin);
> +
> + spin_lock_irqsave(&cpm2_port_locks[port], flags);
> +
> + cpm2_set_pin(port, pin, CPM_PIN_OUTPUT | CPM_PIN_GPIO);
You seem to do the pin -> bitmask conversation twice in gpio_direction_output().
cpm2_set_pin() must be executed before pin = 1 << (31 - pin);
Thanks,
Jochen
^ permalink raw reply
* Re: [ewg] Re: [PATCH] IB/ehca: Serialize HCA-related hCalls on POWER5
From: Christoph Raisch @ 2007-12-12 16:02 UTC (permalink / raw)
To: Or Gerlitz
Cc: Arnd Bergmann, Roland Dreier, Joachim Fenkes, LKML, linuxppc-dev,
OF-General, Stefan Roscher
In-Reply-To: <475FD0A1.3090304@voltaire.com>
Or Gerlitz <ogerlitz@voltaire.com> wrote on 12.12.2007 13:14:25:
> Joachim Fenkes wrote:
> > Roland Dreier <rdreier@cisco.com> wrote on 10.12.2007 22:47:37:
>
> >> It's an optional device feature, so this should be OK
> >> (although the iSER driver currently seems to depend on a device
> >> supporting FMRs, which is probably going to be a problem with iWARP
> >> support in the future anyway).
>
> > I don't feel very well with removing code from the driver that iSER
seems
> > to depend on. Are there plans to fix this in iSER?
>
> What is the fix you suggest, to add a device query that tells you for
> which verbs the documentation does not apply? or enhance the code of the
> map_phys_fmr verb within the ehca driver to return error if called
> from non-sleepable context?
Roland,
what is your suggestion here?
We could implement both versions Or is proposing, but having both
at the same time sound like overkill.
Christoph R.
^ permalink raw reply
* Re: [PATCH RFC 3/7] [POWERPC] CPM2: implement GPIO API
From: Anton Vorontsov @ 2007-12-12 16:03 UTC (permalink / raw)
To: Jochen Friedrich; +Cc: linuxppc-dev
In-Reply-To: <4760031A.6020005@scram.de>
On Wed, Dec 12, 2007 at 04:49:46PM +0100, Jochen Friedrich wrote:
> Hi Anton,
>
> > +int gpio_direction_input(unsigned int gpio)
> > +{
> > + unsigned long flags;
> > + int port = gpio / 32;
> > + int pin = gpio % 32;
> > +
> > + spin_lock_irqsave(&cpm2_port_locks[port], flags);
> > +
> > + cpm2_set_pin(port, pin, CPM_PIN_INPUT | CPM_PIN_GPIO);
>
> > +int gpio_direction_output(unsigned int gpio, int value)
> > +{
> > + struct cpm2_ioports __iomem *iop =
> > + (struct cpm2_ioports __iomem *)&cpm2_immr->im_ioport;
> > + int port = gpio / 32;
> > + int pin = gpio % 32;
> > + unsigned long flags;
> > +
> > + pin = 1 << (31 - pin);
> > +
> > + spin_lock_irqsave(&cpm2_port_locks[port], flags);
> > +
> > + cpm2_set_pin(port, pin, CPM_PIN_OUTPUT | CPM_PIN_GPIO);
>
> You seem to do the pin -> bitmask conversation twice in gpio_direction_output().
>
> cpm2_set_pin() must be executed before pin = 1 << (31 - pin);
Yup, found this just after posting. ;-) I've tried to move as much as
possible out of spinlocked section, but done it obviously wrong.
Will fix.
Anyhow, much thanks for looking into this.
--
Anton Vorontsov
email: cbou@mail.ru
backup email: ya-cbou@yandex.ru
irc://irc.freenode.net/bd2
^ permalink raw reply
* Re: [PATCH v5] qe: add ability to upload QE firmware
From: Kumar Gala @ 2007-12-12 16:01 UTC (permalink / raw)
To: Timur Tabi; +Cc: linuxppc-dev
In-Reply-To: <475FFBA3.9080607@freescale.com>
On Dec 12, 2007, at 9:17 AM, Timur Tabi wrote:
> Timur Tabi wrote:
>> Define the layout of a binary blob that contains a QE firmware and
>> instructions
>> on how to upload it. Add function qe_upload_firmware() to parse
>> the blob
>> and perform the actual upload. Fully define 'struct rsp' in
>> immap_qe.h to
>> include the actual RISC Special Registers. Added description of a
>> new
>> QE firmware node to booting-without-of.txt.
>
> If there are no objections, I'd like this patch to be pulled into
> for-2.6.25. Thanks.
I'm just waiting for you to hit v99 :)
- k
^ permalink raw reply
* Kernel 2.6.23 on ML-403 hangs with uncompression on bootup
From: ramkumarj Ramkumar @ 2007-12-12 16:10 UTC (permalink / raw)
To: linuxppc-embedded
[-- Attachment #1.1: Type: text/plain, Size: 11044 bytes --]
Hi All,
I m using Linux 2.6.23-rc2 from Grant's git with gcc 4.1.0 on ML-403. When I
load the zImage from the XMD, I only get the messages printed from the
arch/ppc/boot and soon after the kernel is decompressed the console appears
frozen. So I assume the console is ok with image loader but on linux kernel,
it doesnt seem working. I edited the code in arch/ppc/boot/simple so as to
forcefully refer the right embed_config() function.
Following is the console logs,
loaded at: 00400000 004D71A0
board data at: 004D5124 004D51A0
relocated to: 00404048 004040C4
zimage at: 00404F11 004D4DFC
avail ram: 004D8000 02000000
Linux/PPC load: console=ttyS0,9600
Uncompressing Linux...done.
Now booting the kernel
com_port is 40401003
id mach(): done
MMU:enter
MMU:hw init
MMU:mapin
MMU:setio
MMU:exit
When I dumped the __log_buffer, I only find the linux_banner being
displayed, the others remain zero. Periodically I stopped the ppc to find
the PC using XMD. Eachtime I stopped it was different either with address
0xCxxx_xxxx or 0x0xxx_xxxx. So I suspect this could be a console problem as
kernel appears running.
It would be helpful if someone could let me know, whether anything
more needs to be done to bring the console. In xparameters_ml403.h the PLB
speed is 100000000 and I havent edited any other file. Also, I have
configured the command line parameters to kernel as
CONFIG_CMDLINE="console=ttyS0,9600".
Whether there are any conflicts between the compiler being used and linux
version despite the changes to correctly refer the embed_config(). Also,
please let me know whether printk keeps dumping on __log_buffer even after
the console is initialized and are there anyway to keep printk dumping to
__log_buffer irrespective of the console being initialzed or not.
Any suggestions and ideas would be very helpful.
Thanks and Regards,
Ram
PS: Attached is config file and below is xparameters file
xparameters_ml403.h
------------------------------------------------------
/* Definitions for driver UARTNS550 */
#define XPAR_XUARTNS550_NUM_INSTANCES 1
#define XPAR_XUARTNS550_CLOCK_HZ 100000000
/* Definitions for peripheral RS232_UART */
#define XPAR_RS232_UART_BASEADDR 0x40400000
#define XPAR_RS232_UART_HIGHADDR 0x4040FFFF
#define XPAR_RS232_UART_DEVICE_ID 0
/******************************************************************/
/* Definitions for driver IIC */
#define XPAR_XIIC_NUM_INSTANCES 1
/* Definitions for peripheral IIC_EEPROM */
#define XPAR_IIC_EEPROM_BASEADDR 0x40800000
#define XPAR_IIC_EEPROM_HIGHADDR 0x4080FFFF
#define XPAR_IIC_EEPROM_DEVICE_ID 0
#define XPAR_IIC_EEPROM_TEN_BIT_ADR 0
#define XPAR_IIC_EEPROM_GPO_WIDTH 1
/******************************************************************/
#define XPAR_XSYSACE_MEM_WIDTH 16
/* Definitions for driver SYSACE */
#define XPAR_XSYSACE_NUM_INSTANCES 1
/* Definitions for peripheral SYSACE_COMPACTFLASH */
#define XPAR_SYSACE_COMPACTFLASH_BASEADDR 0x41800000
#define XPAR_SYSACE_COMPACTFLASH_HIGHADDR 0x4180FFFF
#define XPAR_SYSACE_COMPACTFLASH_DEVICE_ID 0
#define XPAR_SYSACE_COMPACTFLASH_MEM_WIDTH 16
/******************************************************************/
/* Definitions for peripheral SRAM_256KX32 */
#define XPAR_SRAM_256KX32_NUM_BANKS_MEM 1
/******************************************************************/
/* Definitions for peripheral SRAM_256KX32 */
#define XPAR_SRAM_256KX32_MEM0_BASEADDR 0x40500000
#define XPAR_SRAM_256KX32_MEM0_HIGHADDR 0x405FFFFF
/******************************************************************/
#define XPAR_INTC_MAX_NUM_INTR_INPUTS 4
#define XPAR_XINTC_HAS_IPR 1
#define XPAR_XINTC_USE_DCR 0
/* Definitions for driver INTC */
#define XPAR_XINTC_NUM_INSTANCES 1
/* Definitions for peripheral OPB_INTC_0 */
#define XPAR_OPB_INTC_0_BASEADDR 0x41200000
#define XPAR_OPB_INTC_0_HIGHADDR 0x4120FFFF
#define XPAR_OPB_INTC_0_DEVICE_ID 0
#define XPAR_OPB_INTC_0_KIND_OF_INTR 0x00000000
/******************************************************************/
#define XPAR_INTC_SINGLE_BASEADDR 0x41200000
#define XPAR_INTC_SINGLE_HIGHADDR 0x4120FFFF
#define XPAR_INTC_SINGLE_DEVICE_ID XPAR_OPB_INTC_0_DEVICE_ID
#define XPAR_ETHERNET_MAC_IP2INTC_IRPT_MASK 0X000001
#define XPAR_OPB_INTC_0_ETHERNET_MAC_IP2INTC_IRPT_INTR 0
#define XPAR_SYSACE_COMPACTFLASH_SYSACE_IRQ_MASK 0X000002
#define XPAR_OPB_INTC_0_SYSACE_COMPACTFLASH_SYSACE_IRQ_INTR 1
#define XPAR_IIC_EEPROM_IP2INTC_IRPT_MASK 0X000004
#define XPAR_OPB_INTC_0_IIC_EEPROM_IP2INTC_IRPT_INTR 2
#define XPAR_RS232_UART_IP2INTC_IRPT_MASK 0X000008
#define XPAR_OPB_INTC_0_RS232_UART_IP2INTC_IRPT_INTR 3
/******************************************************************/
/* Definitions for driver DDR */
#define XPAR_XDDR_NUM_INSTANCES 1
/* Definitions for peripheral DDR_SDRAM_64MX32 */
#define XPAR_DDR_SDRAM_64MX32_ECC_BASEADDR 0xFFFFFFFF
#define XPAR_DDR_SDRAM_64MX32_ECC_HIGHADDR 0x00000000
#define XPAR_DDR_SDRAM_64MX32_DEVICE_ID 0
#define XPAR_DDR_SDRAM_64MX32_INCLUDE_ECC_INTR 0
/******************************************************************/
/* Definitions for peripheral DDR_SDRAM_64MX32 */
#define XPAR_DDR_SDRAM_64MX32_MEM0_BASEADDR 0x00000000
#define XPAR_DDR_SDRAM_64MX32_MEM0_HIGHADDR 0x03FFFFFF
/******************************************************************/
/* Definitions for driver EMAC */
#define XPAR_XEMAC_NUM_INSTANCES 1
/* Definitions for peripheral ETHERNET_MAC */
#define XPAR_ETHERNET_MAC_BASEADDR 0x80400000
#define XPAR_ETHERNET_MAC_HIGHADDR 0x8040FFFF
#define XPAR_ETHERNET_MAC_DEVICE_ID 0
#define XPAR_ETHERNET_MAC_ERR_COUNT_EXIST 1
#define XPAR_ETHERNET_MAC_DMA_PRESENT 1
#define XPAR_ETHERNET_MAC_MII_EXIST 1
/* Edited by Ramkumar. Dont know whether this will be working.
*/
#define XPAR_ETHERNET_MAC_CAM_EXIST 0
#define XPAR_ETHERNET_MAC_JUMBO_EXIST 0
#define XPAR_ETHERNET_MAC_TX_DRE_TYPE 0
#define XPAR_ETHERNET_MAC_RX_DRE_TYPE 0
#define XPAR_ETHERNET_MAC_TX_INCLUDE_CSUM 0
#define XPAR_ETHERNET_MAC_RX_INCLUDE_CSUM 0
/******************************************************************/
/* Definitions for peripheral PLB_BRAM_IF_CNTLR_1 */
#define XPAR_PLB_BRAM_IF_CNTLR_1_BASEADDR 0xffff0000
#define XPAR_PLB_BRAM_IF_CNTLR_1_HIGHADDR 0xffffffff
/******************************************************************/
#define XPAR_CPU_PPC405_CORE_CLOCK_FREQ_HZ 100000000
/******************************************************************/
#define XPAR_CPU_ID 0
#define XPAR_PPC405_VIRTEX4_ID 0
#define XPAR_PPC405_VIRTEX4_CORE_CLOCK_FREQ_HZ 100000000
#define XPAR_PPC405_VIRTEX4_IDCR_BASEADDR 0x00000100
#define XPAR_PPC405_VIRTEX4_IDCR_HIGHADDR 0x0000010F
#define XPAR_PPC405_VIRTEX4_DISABLE_OPERAND_FORWARDING 1
#define XPAR_PPC405_VIRTEX4_MMU_ENABLE 1
#define XPAR_PPC405_VIRTEX4_DETERMINISTIC_MULT 0
#define XPAR_PPC405_VIRTEX4_PLBSYNCBYPASS 1
#define XPAR_PPC405_VIRTEX4_APU_CONTROL 0b1101111000000000
#define XPAR_PPC405_VIRTEX4_APU_UDI_1 0b101000011000100110000011
#define XPAR_PPC405_VIRTEX4_APU_UDI_2 0b101000111000100110000011
#define XPAR_PPC405_VIRTEX4_APU_UDI_3 0b101001011000100111000011
#define XPAR_PPC405_VIRTEX4_APU_UDI_4 0b101001111000100111000011
#define XPAR_PPC405_VIRTEX4_APU_UDI_5 0b101010011000110000000011
#define XPAR_PPC405_VIRTEX4_APU_UDI_6 0b101010111000110000000011
#define XPAR_PPC405_VIRTEX4_APU_UDI_7 0b101011011000110001000011
#define XPAR_PPC405_VIRTEX4_APU_UDI_8 0b101011111000110001000011
#define XPAR_PPC405_VIRTEX4_PVR_HIGH 0b0000
#define XPAR_PPC405_VIRTEX4_PVR_LOW 0b0000
#define XPAR_PPC405_VIRTEX4_HW_VER "1.01.a"
/******************************************************************/
/******************************************************************/
/* Linux Redefines */
/******************************************************************/
#define XPAR_UARTNS550_0_BASEADDR (XPAR_RS232_UART_BASEADDR+0x1000)
#define XPAR_UARTNS550_0_HIGHADDR XPAR_RS232_UART_HIGHADDR
#define XPAR_UARTNS550_0_CLOCK_FREQ_HZ XPAR_XUARTNS550_CLOCK_HZ
#define XPAR_UARTNS550_0_DEVICE_ID XPAR_RS232_UART_DEVICE_ID
/******************************************************************/
#define XPAR_IIC_0_BASEADDR XPAR_IIC_EEPROM_BASEADDR
#define XPAR_IIC_0_HIGHADDR XPAR_IIC_EEPROM_HIGHADDR
#define XPAR_IIC_0_TEN_BIT_ADR XPAR_IIC_EEPROM_TEN_BIT_ADR
#define XPAR_IIC_0_DEVICE_ID XPAR_IIC_EEPROM_DEVICE_ID
/******************************************************************/
#define XPAR_SYSACE_0_BASEADDR XPAR_SYSACE_COMPACTFLASH_BASEADDR
#define XPAR_SYSACE_0_HIGHADDR XPAR_SYSACE_COMPACTFLASH_HIGHADDR
#define XPAR_SYSACE_0_DEVICE_ID XPAR_SYSACE_COMPACTFLASH_DEVICE_ID
/******************************************************************/
#define XPAR_EMAC_0_BASEADDR XPAR_ETHERNET_MAC_BASEADDR
#define XPAR_EMAC_0_HIGHADDR XPAR_ETHERNET_MAC_HIGHADDR
#define XPAR_EMAC_0_DMA_PRESENT XPAR_ETHERNET_MAC_DMA_PRESENT
#define XPAR_EMAC_0_MII_EXIST XPAR_ETHERNET_MAC_MII_EXIST
#define XPAR_EMAC_0_ERR_COUNT_EXIST XPAR_ETHERNET_MAC_ERR_COUNT_EXIST
#define XPAR_EMAC_0_CAM_EXIST XPAR_ETHERNET_MAC_CAM_EXIST
#define XPAR_EMAC_0_JUMBO_EXIST XPAR_ETHERNET_MAC_JUMBO_EXIST
#define XPAR_EMAC_0_TX_DRE_TYPE XPAR_ETHERNET_MAC_TX_DRE_TYPE
#define XPAR_EMAC_0_RX_DRE_TYPE XPAR_ETHERNET_MAC_RX_DRE_TYPE
#define XPAR_EMAC_0_TX_INCLUDE_CSUM XPAR_ETHERNET_MAC_TX_INCLUDE_CSUM
#define XPAR_EMAC_0_RX_INCLUDE_CSUM XPAR_ETHERNET_MAC_RX_INCLUDE_CSUM
#define XPAR_EMAC_0_DEVICE_ID XPAR_ETHERNET_MAC_DEVICE_ID
/******************************************************************/
#define XPAR_INTC_0_BASEADDR XPAR_OPB_INTC_0_BASEADDR
#define XPAR_INTC_0_HIGHADDR XPAR_OPB_INTC_0_HIGHADDR
#define XPAR_INTC_0_KIND_OF_INTR XPAR_OPB_INTC_0_KIND_OF_INTR
#define XPAR_INTC_0_DEVICE_ID XPAR_OPB_INTC_0_DEVICE_ID
/******************************************************************/
#define XPAR_INTC_0_EMAC_0_VEC_ID
XPAR_OPB_INTC_0_ETHERNET_MAC_IP2INTC_IRPT_INTR
#define XPAR_INTC_0_SYSACE_0_VEC_ID
XPAR_OPB_INTC_0_SYSACE_COMPACTFLASH_SYSACE_IRQ_INTR
#define XPAR_INTC_0_IIC_0_VEC_ID
XPAR_OPB_INTC_0_IIC_EEPROM_IP2INTC_IRPT_INTR
#define XPAR_INTC_0_UARTNS550_0_VEC_ID
XPAR_OPB_INTC_0_RS232_UART_IP2INTC_IRPT_INTR
/******************************************************************/
#define XPAR_PLB_CLOCK_FREQ_HZ 100000000
#define XPAR_CORE_CLOCK_FREQ_HZ XPAR_CPU_PPC405_CORE_CLOCK_FREQ_HZ
#define XPAR_DDR_0_SIZE 33554432
/******************************************************************/
#define XPAR_PERSISTENT_0_IIC_0_BASEADDR 0x00000400
#define XPAR_PERSISTENT_0_IIC_0_HIGHADDR 0x000007FF
#define XPAR_PERSISTENT_0_IIC_0_EEPROMADDR 0xA0
/******************************************************************/
#define XPAR_PCI_0_CLOCK_FREQ_HZ 0
/******************************************************************/
#define XPAR_XPS2_NUM_INSTANCES 2
#define XPAR_PS2_0_DEVICE_ID 50
#define XPAR_PS2_0_BASEADDR 0xA9000000
#define XPAR_PS2_0_HIGHADDR 0xA900003F
#define XPAR_INTC_0_PS2_0_VEC_ID 27
#define XPAR_PS2_1_DEVICE_ID 51
#define XPAR_PS2_1_BASEADDR 0xA9001000
#define XPAR_INTC_0_PS2_1_VEC_ID 26
/******************************************************************/
[-- Attachment #1.2: Type: text/html, Size: 12773 bytes --]
[-- Attachment #2: config --]
[-- Type: text/plain, Size: 16785 bytes --]
#
# Automatically generated make config: don't edit
# Linux kernel version: 2.6.23-rc2
# Wed Dec 12 19:24:17 2007
#
CONFIG_MMU=y
CONFIG_GENERIC_HARDIRQS=y
CONFIG_RWSEM_XCHGADD_ALGORITHM=y
CONFIG_ARCH_HAS_ILOG2_U32=y
# CONFIG_ARCH_HAS_ILOG2_U64 is not set
CONFIG_GENERIC_HWEIGHT=y
CONFIG_GENERIC_CALIBRATE_DELAY=y
CONFIG_PPC=y
CONFIG_PPC32=y
CONFIG_GENERIC_NVRAM=y
CONFIG_GENERIC_FIND_NEXT_BIT=y
CONFIG_SCHED_NO_NO_OMIT_FRAME_POINTER=y
CONFIG_ARCH_MAY_HAVE_PC_FDC=y
CONFIG_GENERIC_BUG=y
CONFIG_DEFCONFIG_LIST="/lib/modules/$UNAME_RELEASE/.config"
#
# General setup
#
# CONFIG_EXPERIMENTAL is not set
CONFIG_BROKEN_ON_SMP=y
CONFIG_INIT_ENV_ARG_LIMIT=32
CONFIG_LOCALVERSION=""
# CONFIG_LOCALVERSION_AUTO is not set
# CONFIG_SWAP is not set
CONFIG_SYSVIPC=y
CONFIG_SYSVIPC_SYSCTL=y
# CONFIG_BSD_PROCESS_ACCT is not set
# CONFIG_TASKSTATS is not set
# CONFIG_AUDIT is not set
# CONFIG_IKCONFIG is not set
CONFIG_LOG_BUF_SHIFT=17
# CONFIG_SYSFS_DEPRECATED is not set
# CONFIG_RELAY is not set
# CONFIG_BLK_DEV_INITRD is not set
CONFIG_SYSCTL=y
# CONFIG_EMBEDDED is not set
CONFIG_SYSCTL_SYSCALL=y
CONFIG_KALLSYMS=y
# CONFIG_KALLSYMS_ALL is not set
CONFIG_KALLSYMS_EXTRA_PASS=y
CONFIG_HOTPLUG=y
CONFIG_PRINTK=y
CONFIG_BUG=y
CONFIG_ELF_CORE=y
CONFIG_BASE_FULL=y
CONFIG_FUTEX=y
CONFIG_ANON_INODES=y
CONFIG_EPOLL=y
CONFIG_SIGNALFD=y
CONFIG_TIMERFD=y
CONFIG_EVENTFD=y
CONFIG_SHMEM=y
CONFIG_VM_EVENT_COUNTERS=y
CONFIG_SLAB=y
# CONFIG_SLUB is not set
# 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_MODVERSIONS=y
CONFIG_MODULE_SRCVERSION_ALL=y
CONFIG_KMOD=y
CONFIG_BLOCK=y
# CONFIG_LBD is not set
# CONFIG_BLK_DEV_IO_TRACE is not set
# CONFIG_LSF is not set
#
# IO Schedulers
#
CONFIG_IOSCHED_NOOP=y
# CONFIG_IOSCHED_AS is not set
# CONFIG_IOSCHED_DEADLINE is not set
# CONFIG_IOSCHED_CFQ is not set
# CONFIG_DEFAULT_AS is not set
# CONFIG_DEFAULT_DEADLINE is not set
# CONFIG_DEFAULT_CFQ is not set
CONFIG_DEFAULT_NOOP=y
CONFIG_DEFAULT_IOSCHED="noop"
#
# Processor
#
# CONFIG_6xx is not set
CONFIG_40x=y
# CONFIG_44x is not set
# CONFIG_8xx is not set
# CONFIG_E200 is not set
# CONFIG_E500 is not set
CONFIG_PPC_DCR_NATIVE=y
CONFIG_PPC_DCR=y
# CONFIG_MATH_EMULATION is not set
# CONFIG_CPU_FREQ is not set
CONFIG_4xx=y
# CONFIG_WANT_EARLY_SERIAL is not set
#
# IBM 4xx options
#
# CONFIG_BUBINGA is not set
# CONFIG_CPCI405 is not set
# CONFIG_EP405 is not set
# CONFIG_REDWOOD_5 is not set
# CONFIG_REDWOOD_6 is not set
# CONFIG_SYCAMORE is not set
# CONFIG_WALNUT is not set
# CONFIG_XILINX_ML300 is not set
CONFIG_XILINX_ML403=y
CONFIG_IBM405_ERR77=y
CONFIG_IBM405_ERR51=y
CONFIG_XILINX_VIRTEX_4_FX=y
CONFIG_XILINX_VIRTEX=y
CONFIG_EMBEDDEDBOOT=y
# CONFIG_PPC4xx_DMA is not set
CONFIG_PPC_GEN550=y
CONFIG_UART0_TTYS0=y
# CONFIG_UART0_TTYS1 is not set
CONFIG_NOT_COHERENT_CACHE=y
#
# Platform options
#
# CONFIG_PC_KEYBOARD is not set
# CONFIG_HIGHMEM is not set
CONFIG_ARCH_POPULATES_NODE_MAP=y
# CONFIG_HZ_100 is not set
# CONFIG_HZ_250 is not set
# CONFIG_HZ_300 is not set
CONFIG_HZ_1000=y
CONFIG_HZ=1000
# CONFIG_PREEMPT_NONE is not set
CONFIG_PREEMPT_VOLUNTARY=y
# CONFIG_PREEMPT is not set
CONFIG_FLATMEM=y
CONFIG_FLAT_NODE_MEM_MAP=y
# CONFIG_SPARSEMEM_STATIC is not set
CONFIG_SPLIT_PTLOCK_CPUS=4
# CONFIG_RESOURCES_64BIT is not set
CONFIG_ZONE_DMA_FLAG=1
CONFIG_BOUNCE=y
CONFIG_VIRT_TO_BUS=y
# CONFIG_BINFMT_ELF is not set
# CONFIG_BINFMT_MISC is not set
CONFIG_CMDLINE_BOOL=y
CONFIG_CMDLINE="console=ttyS0,9600"
# CONFIG_PM is not set
# CONFIG_SECCOMP is not set
CONFIG_ISA_DMA_API=y
#
# Bus options
#
CONFIG_ZONE_DMA=y
# CONFIG_PPC_I8259 is not set
# CONFIG_PCI is not set
# CONFIG_PCI_DOMAINS is not set
# CONFIG_PCI_SYSCALL is not set
# CONFIG_ARCH_SUPPORTS_MSI is not set
#
# PCCARD (PCMCIA/CardBus) support
#
CONFIG_PCCARD=y
# CONFIG_PCMCIA_DEBUG is not set
CONFIG_PCMCIA=y
CONFIG_PCMCIA_IOCTL=y
#
# PC-card bridges
#
#
# Advanced setup
#
# CONFIG_ADVANCED_OPTIONS is not set
#
# Default settings for advanced configuration options are used
#
CONFIG_HIGHMEM_START=0xfe000000
CONFIG_LOWMEM_SIZE=0x30000000
CONFIG_KERNEL_START=0xc0000000
CONFIG_TASK_SIZE=0x80000000
CONFIG_CONSISTENT_START=0xff100000
CONFIG_CONSISTENT_SIZE=0x00200000
CONFIG_BOOT_LOAD=0x00400000
#
# Networking
#
CONFIG_NET=y
#
# Networking options
#
# CONFIG_PACKET is not set
# CONFIG_UNIX is not set
# CONFIG_NET_KEY is not set
# CONFIG_INET is not set
# CONFIG_NETWORK_SECMARK is not set
# CONFIG_NETFILTER is not set
# CONFIG_BRIDGE is not set
# CONFIG_VLAN_8021Q is not set
# CONFIG_DECNET is not set
# CONFIG_LLC2 is not set
# CONFIG_IPX is not set
# CONFIG_ATALK is not set
#
# QoS and/or fair queueing
#
CONFIG_NET_SCHED=y
CONFIG_NET_SCH_FIFO=y
#
# Queueing/Scheduling
#
CONFIG_NET_SCH_CBQ=m
CONFIG_NET_SCH_HTB=m
CONFIG_NET_SCH_HFSC=m
CONFIG_NET_SCH_PRIO=m
# CONFIG_NET_SCH_RR is not set
CONFIG_NET_SCH_RED=m
CONFIG_NET_SCH_SFQ=m
CONFIG_NET_SCH_TEQL=m
CONFIG_NET_SCH_TBF=m
CONFIG_NET_SCH_GRED=m
CONFIG_NET_SCH_DSMARK=m
CONFIG_NET_SCH_NETEM=m
CONFIG_NET_SCH_INGRESS=m
#
# Classification
#
CONFIG_NET_CLS=y
CONFIG_NET_CLS_BASIC=m
CONFIG_NET_CLS_TCINDEX=m
CONFIG_NET_CLS_ROUTE4=m
CONFIG_NET_CLS_ROUTE=y
CONFIG_NET_CLS_FW=m
CONFIG_NET_CLS_U32=m
CONFIG_CLS_U32_PERF=y
CONFIG_CLS_U32_MARK=y
CONFIG_NET_CLS_RSVP=m
CONFIG_NET_CLS_RSVP6=m
CONFIG_NET_EMATCH=y
CONFIG_NET_EMATCH_STACK=32
CONFIG_NET_EMATCH_CMP=m
CONFIG_NET_EMATCH_NBYTE=m
CONFIG_NET_EMATCH_U32=m
CONFIG_NET_EMATCH_META=m
CONFIG_NET_EMATCH_TEXT=m
CONFIG_NET_CLS_ACT=y
CONFIG_NET_ACT_POLICE=m
CONFIG_NET_ACT_GACT=m
CONFIG_GACT_PROB=y
CONFIG_NET_ACT_MIRRED=m
CONFIG_NET_ACT_PEDIT=m
CONFIG_NET_ACT_SIMP=m
# CONFIG_NET_CLS_POLICE is not set
CONFIG_NET_CLS_IND=y
#
# Network testing
#
# CONFIG_NET_PKTGEN is not set
# CONFIG_HAMRADIO is not set
# CONFIG_IRDA is not set
# CONFIG_BT is not set
#
# Wireless
#
# CONFIG_CFG80211 is not set
# CONFIG_WIRELESS_EXT is not set
# CONFIG_IEEE80211 is not set
# CONFIG_RFKILL is not set
#
# Device Drivers
#
#
# Generic Driver Options
#
CONFIG_STANDALONE=y
CONFIG_PREVENT_FIRMWARE_BUILD=y
CONFIG_FW_LOADER=y
# CONFIG_DEBUG_DRIVER is not set
# CONFIG_DEBUG_DEVRES is not set
# CONFIG_SYS_HYPERVISOR is not set
# CONFIG_CONNECTOR is not set
# CONFIG_MTD is not set
# CONFIG_PARPORT is not set
CONFIG_BLK_DEV=y
# CONFIG_BLK_DEV_FD is not set
# CONFIG_BLK_DEV_COW_COMMON is not set
CONFIG_BLK_DEV_LOOP=y
# CONFIG_BLK_DEV_CRYPTOLOOP is not set
# CONFIG_BLK_DEV_NBD is not set
CONFIG_BLK_DEV_RAM=y
CONFIG_BLK_DEV_RAM_COUNT=16
CONFIG_BLK_DEV_RAM_SIZE=16384
CONFIG_BLK_DEV_RAM_BLOCKSIZE=4096
# CONFIG_CDROM_PKTCDVD is not set
# CONFIG_ATA_OVER_ETH is not set
CONFIG_XILINX_SYSACE=y
# CONFIG_XILINX_SYSACE_OLD is not set
# CONFIG_MISC_DEVICES is not set
# CONFIG_IDE is not set
#
# SCSI device support
#
CONFIG_RAID_ATTRS=m
CONFIG_SCSI=m
CONFIG_SCSI_DMA=y
CONFIG_SCSI_NETLINK=y
CONFIG_SCSI_PROC_FS=y
#
# SCSI support type (disk, tape, CD-ROM)
#
CONFIG_BLK_DEV_SD=m
CONFIG_CHR_DEV_ST=m
CONFIG_CHR_DEV_OSST=m
CONFIG_BLK_DEV_SR=m
CONFIG_BLK_DEV_SR_VENDOR=y
CONFIG_CHR_DEV_SG=m
CONFIG_CHR_DEV_SCH=m
#
# Some SCSI devices (e.g. CD jukebox) support multiple LUNs
#
CONFIG_SCSI_MULTI_LUN=y
CONFIG_SCSI_CONSTANTS=y
CONFIG_SCSI_LOGGING=y
# CONFIG_SCSI_SCAN_ASYNC is not set
CONFIG_SCSI_WAIT_SCAN=m
#
# SCSI Transports
#
CONFIG_SCSI_SPI_ATTRS=m
CONFIG_SCSI_FC_ATTRS=m
CONFIG_SCSI_ISCSI_ATTRS=m
CONFIG_SCSI_SAS_ATTRS=m
CONFIG_SCSI_SAS_LIBSAS=m
# CONFIG_SCSI_SAS_LIBSAS_DEBUG is not set
CONFIG_SCSI_LOWLEVEL=y
# CONFIG_SCSI_DEBUG is not set
# CONFIG_SCSI_LOWLEVEL_PCMCIA is not set
# CONFIG_ATA is not set
# CONFIG_MD is not set
# CONFIG_MACINTOSH_DRIVERS is not set
# CONFIG_NETDEVICES is not set
# CONFIG_ISDN is not set
# CONFIG_PHONE is not set
#
# Input device support
#
CONFIG_INPUT=y
# CONFIG_INPUT_FF_MEMLESS is not set
# CONFIG_INPUT_POLLDEV is not set
#
# Userland interfaces
#
CONFIG_INPUT_MOUSEDEV=y
# CONFIG_INPUT_MOUSEDEV_PSAUX is not set
CONFIG_INPUT_MOUSEDEV_SCREEN_X=1024
CONFIG_INPUT_MOUSEDEV_SCREEN_Y=768
# CONFIG_INPUT_JOYDEV is not set
# CONFIG_INPUT_TSDEV is not set
# CONFIG_INPUT_EVDEV is not set
# CONFIG_INPUT_EVBUG is not set
#
# Input Device Drivers
#
# CONFIG_INPUT_KEYBOARD is not set
# CONFIG_INPUT_MOUSE is not set
# CONFIG_INPUT_JOYSTICK is not set
# CONFIG_INPUT_TABLET is not set
# CONFIG_INPUT_TOUCHSCREEN is not set
# CONFIG_INPUT_MISC is not set
#
# Hardware I/O ports
#
CONFIG_SERIO=y
CONFIG_SERIO_I8042=y
CONFIG_SERIO_SERPORT=y
# CONFIG_SERIO_XILINXPS2 is not set
CONFIG_SERIO_RAW=m
CONFIG_GAMEPORT=m
CONFIG_GAMEPORT_NS558=m
CONFIG_GAMEPORT_L4=m
#
# Character devices
#
CONFIG_VT=y
CONFIG_VT_CONSOLE=y
CONFIG_HW_CONSOLE=y
# CONFIG_VT_HW_CONSOLE_BINDING is not set
# CONFIG_SERIAL_NONSTANDARD is not set
#
# Serial drivers
#
CONFIG_SERIAL_8250=y
CONFIG_SERIAL_8250_CONSOLE=y
# CONFIG_SERIAL_8250_CS is not set
CONFIG_SERIAL_8250_NR_UARTS=32
CONFIG_SERIAL_8250_RUNTIME_UARTS=4
# CONFIG_SERIAL_8250_EXTENDED is not set
#
# Non-8250 serial port support
#
# CONFIG_SERIAL_UARTLITE is not set
CONFIG_SERIAL_CORE=y
CONFIG_SERIAL_CORE_CONSOLE=y
CONFIG_UNIX98_PTYS=y
# CONFIG_LEGACY_PTYS is not set
# 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
# CONFIG_R3964 is not set
#
# PCMCIA character devices
#
# CONFIG_SYNCLINK_CS is not set
CONFIG_CARDMAN_4000=m
CONFIG_CARDMAN_4040=m
# CONFIG_RAW_DRIVER is not set
# CONFIG_I2C is not set
#
# SPI support
#
# CONFIG_SPI is not set
# CONFIG_SPI_MASTER is not set
# CONFIG_W1 is not set
# CONFIG_POWER_SUPPLY is not set
# CONFIG_HWMON is not set
#
# Multifunction device drivers
#
# CONFIG_MFD_SM501 is not set
#
# Multimedia devices
#
CONFIG_VIDEO_DEV=m
CONFIG_VIDEO_V4L1=y
CONFIG_VIDEO_V4L1_COMPAT=y
CONFIG_VIDEO_V4L2=y
CONFIG_VIDEO_CAPTURE_DRIVERS=y
# CONFIG_VIDEO_ADV_DEBUG is not set
CONFIG_VIDEO_HELPER_CHIPS_AUTO=y
CONFIG_VIDEO_CPIA=m
CONFIG_RADIO_ADAPTERS=y
CONFIG_DAB=y
#
# Graphics support
#
CONFIG_BACKLIGHT_LCD_SUPPORT=y
CONFIG_LCD_CLASS_DEVICE=m
CONFIG_BACKLIGHT_CLASS_DEVICE=m
#
# Display device support
#
# CONFIG_DISPLAY_SUPPORT is not set
CONFIG_VGASTATE=m
CONFIG_VIDEO_OUTPUT_CONTROL=m
CONFIG_FB=y
# CONFIG_FIRMWARE_EDID is not set
# CONFIG_FB_DDC is not set
CONFIG_FB_CFB_FILLRECT=m
CONFIG_FB_CFB_COPYAREA=m
CONFIG_FB_CFB_IMAGEBLIT=m
# CONFIG_FB_SYS_FILLRECT is not set
# CONFIG_FB_SYS_COPYAREA is not set
# CONFIG_FB_SYS_IMAGEBLIT is not set
# CONFIG_FB_SYS_FOPS is not set
CONFIG_FB_DEFERRED_IO=y
# CONFIG_FB_SVGALIB is not set
# CONFIG_FB_MACMODES is not set
# CONFIG_FB_BACKLIGHT is not set
CONFIG_FB_MODE_HELPERS=y
CONFIG_FB_TILEBLITTING=y
#
# Frame buffer hardware drivers
#
# CONFIG_FB_CT65550 is not set
CONFIG_FB_VGA16=m
# CONFIG_FB_S1D13XXX is not set
# CONFIG_FB_IBM_GXT4500 is not set
# CONFIG_FB_XILINX is not set
# CONFIG_FB_VIRTUAL is not set
#
# Console display driver support
#
CONFIG_DUMMY_CONSOLE=y
CONFIG_FRAMEBUFFER_CONSOLE=y
# CONFIG_FRAMEBUFFER_CONSOLE_DETECT_PRIMARY is not set
CONFIG_FRAMEBUFFER_CONSOLE_ROTATION=y
# CONFIG_FONTS is not set
CONFIG_FONT_8x8=y
CONFIG_FONT_8x16=y
CONFIG_LOGO=y
# CONFIG_LOGO_LINUX_MONO is not set
# CONFIG_LOGO_LINUX_VGA16 is not set
CONFIG_LOGO_LINUX_CLUT224=y
#
# Sound
#
CONFIG_SOUND=m
#
# Advanced Linux Sound Architecture
#
CONFIG_SND=m
CONFIG_SND_TIMER=m
CONFIG_SND_PCM=m
CONFIG_SND_RAWMIDI=m
CONFIG_SND_SEQUENCER=m
CONFIG_SND_SEQ_DUMMY=m
CONFIG_SND_OSSEMUL=y
CONFIG_SND_MIXER_OSS=m
CONFIG_SND_PCM_OSS=m
CONFIG_SND_PCM_OSS_PLUGINS=y
CONFIG_SND_SEQUENCER_OSS=y
CONFIG_SND_DYNAMIC_MINORS=y
# CONFIG_SND_SUPPORT_OLD_API is not set
CONFIG_SND_VERBOSE_PROCFS=y
# CONFIG_SND_VERBOSE_PRINTK is not set
# CONFIG_SND_DEBUG is not set
#
# Generic devices
#
CONFIG_SND_MPU401_UART=m
CONFIG_SND_DUMMY=m
CONFIG_SND_VIRMIDI=m
CONFIG_SND_MTPAV=m
# CONFIG_SND_SERIAL_U16550 is not set
CONFIG_SND_MPU401=m
# CONFIG_SND_ML403_AC97CR is not set
#
# ALSA PowerMac devices
#
#
# ALSA PowerMac requires I2C
#
#
# ALSA PowerPC devices
#
#
# PCMCIA devices
#
# CONFIG_SND_VXPOCKET is not set
# CONFIG_SND_PDAUDIOCF is not set
#
# System on Chip audio support
#
# CONFIG_SND_SOC is not set
#
# SoC Audio support for SuperH
#
#
# Open Sound System
#
# CONFIG_SOUND_PRIME is not set
# CONFIG_HID_SUPPORT is not set
# CONFIG_USB_SUPPORT is not set
# CONFIG_MMC is not set
# CONFIG_NEW_LEDS is not set
# CONFIG_RTC_CLASS is not set
#
# DMA Engine support
#
# CONFIG_DMA_ENGINE is not set
#
# DMA Clients
#
#
# DMA Devices
#
#
# Userspace I/O
#
# CONFIG_UIO is not set
#
# File systems
#
# CONFIG_EXT2_FS is not set
# CONFIG_EXT3_FS is not set
# CONFIG_REISERFS_FS is not set
# CONFIG_JFS_FS is not set
CONFIG_FS_POSIX_ACL=y
# CONFIG_XFS_FS is not set
# CONFIG_OCFS2_FS is not set
# CONFIG_MINIX_FS is not set
# CONFIG_ROMFS_FS is not set
# CONFIG_INOTIFY is not set
# CONFIG_QUOTA is not set
CONFIG_DNOTIFY=y
# CONFIG_AUTOFS_FS is not set
# CONFIG_AUTOFS4_FS is not set
# CONFIG_FUSE_FS is not set
CONFIG_GENERIC_ACL=y
#
# CD-ROM/DVD Filesystems
#
# CONFIG_ISO9660_FS is not set
# CONFIG_UDF_FS is not set
#
# DOS/FAT/NT Filesystems
#
CONFIG_FAT_FS=y
CONFIG_MSDOS_FS=y
CONFIG_VFAT_FS=y
CONFIG_FAT_DEFAULT_CODEPAGE=437
CONFIG_FAT_DEFAULT_IOCHARSET="ascii"
# CONFIG_NTFS_FS is not set
#
# Pseudo filesystems
#
CONFIG_PROC_FS=y
CONFIG_PROC_KCORE=y
CONFIG_PROC_SYSCTL=y
CONFIG_SYSFS=y
CONFIG_TMPFS=y
CONFIG_TMPFS_POSIX_ACL=y
# CONFIG_HUGETLB_PAGE is not set
CONFIG_RAMFS=y
#
# Miscellaneous filesystems
#
# CONFIG_HFSPLUS_FS is not set
# CONFIG_CRAMFS is not set
# CONFIG_VXFS_FS is not set
# CONFIG_HPFS_FS is not set
# CONFIG_QNX4FS_FS is not set
# CONFIG_SYSV_FS is not set
# CONFIG_UFS_FS is not set
#
# Network File Systems
#
#
# Partition Types
#
# CONFIG_PARTITION_ADVANCED is not set
CONFIG_MSDOS_PARTITION=y
#
# Native Language Support
#
CONFIG_NLS=y
CONFIG_NLS_DEFAULT="utf8"
CONFIG_NLS_CODEPAGE_437=y
# CONFIG_NLS_CODEPAGE_737 is not set
# CONFIG_NLS_CODEPAGE_775 is not set
# CONFIG_NLS_CODEPAGE_850 is not set
# CONFIG_NLS_CODEPAGE_852 is not set
# CONFIG_NLS_CODEPAGE_855 is not set
# CONFIG_NLS_CODEPAGE_857 is not set
# CONFIG_NLS_CODEPAGE_860 is not set
# CONFIG_NLS_CODEPAGE_861 is not set
# CONFIG_NLS_CODEPAGE_862 is not set
# CONFIG_NLS_CODEPAGE_863 is not set
# CONFIG_NLS_CODEPAGE_864 is not set
# CONFIG_NLS_CODEPAGE_865 is not set
# CONFIG_NLS_CODEPAGE_866 is not set
# CONFIG_NLS_CODEPAGE_869 is not set
# CONFIG_NLS_CODEPAGE_936 is not set
# CONFIG_NLS_CODEPAGE_950 is not set
# CONFIG_NLS_CODEPAGE_932 is not set
# CONFIG_NLS_CODEPAGE_949 is not set
# CONFIG_NLS_CODEPAGE_874 is not set
# CONFIG_NLS_ISO8859_8 is not set
# CONFIG_NLS_CODEPAGE_1250 is not set
# CONFIG_NLS_CODEPAGE_1251 is not set
# CONFIG_NLS_ASCII is not set
# CONFIG_NLS_ISO8859_1 is not set
# CONFIG_NLS_ISO8859_2 is not set
# CONFIG_NLS_ISO8859_3 is not set
# CONFIG_NLS_ISO8859_4 is not set
# CONFIG_NLS_ISO8859_5 is not set
# CONFIG_NLS_ISO8859_6 is not set
# CONFIG_NLS_ISO8859_7 is not set
# CONFIG_NLS_ISO8859_9 is not set
# CONFIG_NLS_ISO8859_13 is not set
# CONFIG_NLS_ISO8859_14 is not set
# CONFIG_NLS_ISO8859_15 is not set
# CONFIG_NLS_KOI8_R is not set
# CONFIG_NLS_KOI8_U is not set
# CONFIG_NLS_UTF8 is not set
#
# IBM 40x options
#
#
# Library routines
#
CONFIG_BITREVERSE=y
# CONFIG_CRC_CCITT is not set
# CONFIG_CRC16 is not set
# CONFIG_CRC_ITU_T is not set
CONFIG_CRC32=y
# CONFIG_CRC7 is not set
CONFIG_LIBCRC32C=y
CONFIG_TEXTSEARCH=y
CONFIG_TEXTSEARCH_KMP=m
CONFIG_TEXTSEARCH_BM=m
CONFIG_TEXTSEARCH_FSM=m
CONFIG_PLIST=y
CONFIG_HAS_IOMEM=y
CONFIG_HAS_IOPORT=y
CONFIG_HAS_DMA=y
# CONFIG_PROFILING is not set
#
# Kernel hacking
#
# CONFIG_PRINTK_TIME is not set
# CONFIG_ENABLE_MUST_CHECK is not set
# CONFIG_MAGIC_SYSRQ is not set
# CONFIG_UNUSED_SYMBOLS is not set
# CONFIG_DEBUG_FS is not set
# CONFIG_HEADERS_CHECK is not set
CONFIG_DEBUG_KERNEL=y
# CONFIG_DEBUG_SHIRQ is not set
# CONFIG_DETECT_SOFTLOCKUP is not set
# CONFIG_SCHED_DEBUG is not set
# CONFIG_SCHEDSTATS is not set
# CONFIG_TIMER_STATS is not set
# CONFIG_DEBUG_SLAB is not set
# CONFIG_DEBUG_RT_MUTEXES is not set
# CONFIG_RT_MUTEX_TESTER is not set
# CONFIG_DEBUG_SPINLOCK is not set
# CONFIG_DEBUG_MUTEXES is not set
# CONFIG_DEBUG_SPINLOCK_SLEEP is not set
# CONFIG_DEBUG_LOCKING_API_SELFTESTS is not set
# CONFIG_DEBUG_KOBJECT is not set
CONFIG_DEBUG_BUGVERBOSE=y
CONFIG_DEBUG_INFO=y
# CONFIG_DEBUG_VM is not set
# CONFIG_DEBUG_LIST is not set
# CONFIG_FORCED_INLINING is not set
# CONFIG_RCU_TORTURE_TEST is not set
# CONFIG_FAULT_INJECTION is not set
CONFIG_KGDB=y
CONFIG_KGDB_TTYS0=y
# CONFIG_KGDB_TTYS1 is not set
# CONFIG_KGDB_TTYS2 is not set
# CONFIG_KGDB_TTYS3 is not set
# CONFIG_XMON is not set
# CONFIG_BDI_SWITCH is not set
CONFIG_SERIAL_TEXT_DEBUG=y
#
# Security options
#
# CONFIG_KEYS is not set
# CONFIG_SECURITY is not set
# CONFIG_CRYPTO is not set
^ permalink raw reply
* Re: [PATCH RFC 0/7] "NAND on UPM" and related patches
From: Scott Wood @ 2007-12-12 16:39 UTC (permalink / raw)
To: Anton Vorontsov; +Cc: linuxppc-dev
In-Reply-To: <20071210204705.GA31263@localhost.localdomain>
On Mon, Dec 10, 2007 at 11:47:05PM +0300, Anton Vorontsov wrote:
> 6. FSL UPM NAND driver:
> -----------------------
> It's using FSL UPM functions and GPIO API. It does not implement
> device tree partitions parsing. That issue is completely other
> matter, that is, I have to factor out parsing functions from
> physmap_of.c. This desires separate patch on top of the whole
> series. If anyone currently working on this, let me know.
I've got a patch coming for that.
-Scott
^ permalink raw reply
* Re: [PATCH RFC 0/7] "NAND on UPM" and related patches
From: Scott Wood @ 2007-12-12 16:40 UTC (permalink / raw)
To: Anton Vorontsov; +Cc: linuxppc-dev
In-Reply-To: <20071210204705.GA31263@localhost.localdomain>
On Mon, Dec 10, 2007 at 11:47:05PM +0300, Anton Vorontsov wrote:
> 5 - FSL UPM infrastructure:
> ---------------------------
> UPM address register is shared among UPMs, so we have to do
> proper locking. On the other hand, if we know that specific
> board using only one UPM we could bypass locking, and gain some
> performance win.
Not enough to be worth the complexity compared to the overhead of NAND
access -- especially in the likely case of a non-SMP build.
-Scott
^ permalink raw reply
* [PATCH/RFC] CPM1: implement GPIO API
From: Jochen Friedrich @ 2007-12-12 16:42 UTC (permalink / raw)
To: avorontsov; +Cc: linuxppc-dev
This is based on [PATCH RFC 3/7] [POWERPC] CPM2: implement GPIO API.
Signed-off-by: Jochen Friedrich <jochen@scram.de>
---
arch/powerpc/platforms/8xx/Kconfig | 1 +
arch/powerpc/sysdev/commproc.c | 199 +++++++++++++++++++++++++++++++++++-
2 files changed, 199 insertions(+), 1 deletions(-)
diff --git a/arch/powerpc/platforms/8xx/Kconfig b/arch/powerpc/platforms/8xx/Kconfig
index bd28655..4dc4d0c 100644
--- a/arch/powerpc/platforms/8xx/Kconfig
+++ b/arch/powerpc/platforms/8xx/Kconfig
@@ -4,6 +4,7 @@ config FADS
config CPM1
bool
select CPM
+ select GENERIC_GPIO
choice
prompt "8xx Machine Type"
diff --git a/arch/powerpc/sysdev/commproc.c b/arch/powerpc/sysdev/commproc.c
index f6a6378..219cb4f 100644
--- a/arch/powerpc/sysdev/commproc.c
+++ b/arch/powerpc/sysdev/commproc.c
@@ -27,6 +27,7 @@
#include <linux/param.h>
#include <linux/string.h>
#include <linux/mm.h>
+#include <linux/spinlock.h>
#include <linux/interrupt.h>
#include <linux/irq.h>
#include <linux/module.h>
@@ -36,6 +37,7 @@
#include <asm/8xx_immap.h>
#include <asm/commproc.h>
#include <asm/io.h>
+#include <asm/gpio.h>
#include <asm/tlbflush.h>
#include <asm/rheap.h>
#include <asm/prom.h>
@@ -56,6 +58,57 @@ static cpic8xx_t __iomem *cpic_reg;
static struct irq_host *cpm_pic_host;
+static spinlock_t *cpm1_port_locks;
+static int cpm1_num_ports;
+
+static int par_io_xlate(struct device_node *np, int index)
+{
+ return __of_parse_gpio_bank_pin(np, index, 32, cpm1_num_ports);
+}
+
+static struct of_gpio_chip of_gpio_chip = {
+ .xlate = par_io_xlate,
+};
+
+int cpm_init_par_io(void)
+{
+ int ret;
+ struct device_node *np;
+ const u32 *num_ports;
+ int i;
+
+ np = of_find_node_by_name(NULL, "par_io");
+ if (!np) {
+ ret = -ENOENT;
+ goto err0;
+ }
+
+ num_ports = of_get_property(np, "num-ports", NULL);
+ if (!num_ports) {
+ ret = -ENOENT;
+ goto err1;
+ }
+
+ cpm1_num_ports = *num_ports;
+ cpm1_port_locks = kzalloc(sizeof(*cpm1_port_locks) * cpm1_num_ports,
+ GFP_KERNEL);
+ if (!cpm1_port_locks) {
+ ret = -ENOMEM;
+ goto err1;
+ }
+
+ for (i = 0; i < cpm1_num_ports; i++)
+ spin_lock_init(&cpm1_port_locks[i]);
+
+ np->data = &of_gpio_chip;
+
+ return 0;
+err1:
+ of_node_put(np);
+err0:
+ return ret;
+}
+
static void cpm_mask_irq(unsigned int irq)
{
unsigned int cpm_vec = (unsigned int)irq_map[irq].hwirq;
@@ -199,6 +252,7 @@ end:
void __init cpm_reset(void)
{
sysconf8xx_t __iomem *siu_conf;
+ int ret;
mpc8xx_immr = ioremap(get_immrbase(), 0x4000);
if (!mpc8xx_immr) {
@@ -238,6 +292,10 @@ void __init cpm_reset(void)
/* Reclaim the DP memory for our use. */
m8xx_cpm_dpinit();
#endif
+
+ ret = cpm_init_par_io();
+ if (ret)
+ pr_warning("CPM PIO not initialized!\n");
}
/* We used to do this earlier, but have to postpone as long as possible
@@ -413,7 +471,7 @@ struct cpm_ioport16 {
};
struct cpm_ioport32 {
- __be32 dir, par, sor;
+ __be32 dir, par, sor, dat;
};
static void cpm1_set_pin32(int port, int pin, int flags)
@@ -451,6 +509,39 @@ static void cpm1_set_pin32(int port, int pin, int flags)
}
}
+static void cpm1_set_value32(int port, int pin, int value)
+{
+ struct cpm_ioport32 __iomem *iop;
+ pin = 1 << (31 - pin);
+
+ if (port == CPM_PORTB)
+ iop = (struct cpm_ioport32 __iomem *)
+ &mpc8xx_immr->im_cpm.cp_pbdir;
+ else
+ iop = (struct cpm_ioport32 __iomem *)
+ &mpc8xx_immr->im_cpm.cp_pedir;
+
+ if (value)
+ setbits32(&iop->dat, pin);
+ else
+ clrbits32(&iop->dat, pin);
+}
+
+static int cpm1_get_value32(int port, int pin)
+{
+ struct cpm_ioport32 __iomem *iop;
+ pin = 1 << (31 - pin);
+
+ if (port == CPM_PORTB)
+ iop = (struct cpm_ioport32 __iomem *)
+ &mpc8xx_immr->im_cpm.cp_pbdir;
+ else
+ iop = (struct cpm_ioport32 __iomem *)
+ &mpc8xx_immr->im_cpm.cp_pedir;
+
+ return !!(in_be32(&iop->dat) & pin);
+}
+
static void cpm1_set_pin16(int port, int pin, int flags)
{
struct cpm_ioport16 __iomem *iop =
@@ -479,6 +570,35 @@ static void cpm1_set_pin16(int port, int pin, int flags)
}
}
+static void cpm1_set_value16(int port, int pin, int value)
+{
+ struct cpm_ioport16 __iomem *iop =
+ (struct cpm_ioport16 __iomem *)&mpc8xx_immr->im_ioport;
+
+ pin = 1 << (15 - pin);
+
+ if (port != 0)
+ iop += port - 1;
+
+ if (value)
+ setbits16(&iop->dat, pin);
+ else
+ clrbits16(&iop->dat, pin);
+}
+
+static int cpm1_get_value16(int port, int pin)
+{
+ struct cpm_ioport16 __iomem *iop =
+ (struct cpm_ioport16 __iomem *)&mpc8xx_immr->im_ioport;
+
+ pin = 1 << (15 - pin);
+
+ if (port != 0)
+ iop += port - 1;
+
+ return !!(in_be16(&iop->dat) & pin);
+}
+
void cpm1_set_pin(enum cpm_port port, int pin, int flags)
{
if (port == CPM_PORTB || port == CPM_PORTE)
@@ -607,3 +727,80 @@ int cpm1_clk_setup(enum cpm_clk_target target, int clock, int mode)
return 0;
}
+
+int gpio_request(unsigned int gpio, const char *label)
+{
+ if (!cpm1_port_locks)
+ return -ENODEV;
+
+ if (gpio / 32 > cpm1_num_ports)
+ return -EINVAL;
+ return 0;
+}
+EXPORT_SYMBOL_GPL(gpio_request);
+
+int gpio_direction_input(unsigned int gpio)
+{
+ unsigned long flags;
+ int port = gpio / 32;
+ int pin = gpio % 32;
+
+ spin_lock_irqsave(&cpm1_port_locks[port], flags);
+
+ cpm1_set_pin(port, pin, CPM_PIN_INPUT | CPM_PIN_GPIO);
+
+ spin_unlock_irqrestore(&cpm1_port_locks[port], flags);
+ return 0;
+}
+EXPORT_SYMBOL_GPL(gpio_direction_input);
+
+int gpio_direction_output(unsigned int gpio, int value)
+{
+ int port = gpio / 32;
+ int pin = gpio % 32;
+ unsigned long flags;
+
+ spin_lock_irqsave(&cpm1_port_locks[port], flags);
+
+ cpm1_set_pin(port, pin, CPM_PIN_OUTPUT | CPM_PIN_GPIO);
+
+ if (port == CPM_PORTB || port == CPM_PORTE)
+ cpm1_set_value32(port, pin, value);
+ else
+ cpm1_set_value16(port, pin, value);
+
+ spin_unlock_irqrestore(&cpm1_port_locks[port], flags);
+ return 0;
+}
+EXPORT_SYMBOL_GPL(gpio_direction_output);
+
+int gpio_get_value(unsigned int gpio)
+{
+ int port = gpio / 32;
+ int pin = gpio % 32;
+
+ if (port == CPM_PORTB || port == CPM_PORTE)
+ return cpm1_get_value32(port, pin);
+ else
+ return cpm1_get_value16(port, pin);
+}
+EXPORT_SYMBOL_GPL(gpio_get_value);
+
+int gpio_set_value(unsigned int gpio, int value)
+{
+ int port = gpio / 32;
+ int pin = gpio % 32;
+ unsigned long flags;
+
+ spin_lock_irqsave(&cpm1_port_locks[port], flags);
+
+ if (port == CPM_PORTB || port == CPM_PORTE)
+ cpm1_set_value32(port, pin, value);
+ else
+ cpm1_set_value16(port, pin, value);
+
+ spin_unlock_irqrestore(&cpm1_port_locks[port], flags);
+
+ return 0;
+}
+EXPORT_SYMBOL_GPL(gpio_set_value);
--
1.5.3.7
^ permalink raw reply related
* [PATCH/RFC] [POWERPC] Add fixed-phy support for fs_enet
From: Jochen Friedrich @ 2007-12-12 16:45 UTC (permalink / raw)
To: Vitaly Bordug; +Cc: linuxppc-dev, linux-kernel, Jeff Garzik, netdev
This patch adds support to use the fixed-link property
of an ethernet node to fs_enet for the
CONFIG_PPC_CPM_NEW_BINDING case.
Signed-off-by: Jochen Friedrich <jochen@scram.de>
---
drivers/net/fs_enet/fs_enet-main.c | 9 ++++++++-
1 files changed, 8 insertions(+), 1 deletions(-)
diff --git a/drivers/net/fs_enet/fs_enet-main.c b/drivers/net/fs_enet/fs_enet-main.c
index f2a4d39..8220c70 100644
--- a/drivers/net/fs_enet/fs_enet-main.c
+++ b/drivers/net/fs_enet/fs_enet-main.c
@@ -1174,8 +1174,15 @@ static int __devinit find_phy(struct device_node *np,
struct device_node *phynode, *mdionode;
struct resource res;
int ret = 0, len;
+ const u32 *data;
+
+ data = of_get_property(np, "fixed-link", NULL);
+ if (data) {
+ snprintf(fpi->bus_id, 16, PHY_ID_FMT, 0, *data);
+ return 0;
+ }
- const u32 *data = of_get_property(np, "phy-handle", &len);
+ data = of_get_property(np, "phy-handle", &len);
if (!data || len != 4)
return -EINVAL;
--
1.5.3.7
^ permalink raw reply related
* Re: [PATCH RFC 1/7] [POWERPC] Implement GPIO API embryo
From: Scott Wood @ 2007-12-12 16:48 UTC (permalink / raw)
To: Anton Vorontsov; +Cc: linuxppc-dev
In-Reply-To: <20071210204825.GA32278@localhost.localdomain>
On Mon, Dec 10, 2007 at 11:48:25PM +0300, Anton Vorontsov wrote:
> diff --git a/arch/powerpc/Kconfig b/arch/powerpc/Kconfig
> index 232c298..596982f 100644
> --- a/arch/powerpc/Kconfig
> +++ b/arch/powerpc/Kconfig
> @@ -73,6 +73,10 @@ config GENERIC_FIND_NEXT_BIT
> bool
> default y
>
> +config GENERIC_GPIO
> + bool
> + default n
> +
default n is the default. No need to explicitly state it.
> +
> +int __of_parse_gpio_bank_pin(struct device_node *np, int index,
> + int bank_width, int max_bank)
Why the leading underscores?
> diff --git a/include/asm-powerpc/gpio.h b/include/asm-powerpc/gpio.h
> new file mode 100644
> index 0000000..f7513ff
> --- /dev/null
> +++ b/include/asm-powerpc/gpio.h
> @@ -0,0 +1,51 @@
> +/*
> + * Generic GPIO API implementation for PowerPC.
Is there anything really powerpc specific here, or should it go under
drivers/of?
-Scott
^ permalink raw reply
* Re: [PATCH RFC 0/7] "NAND on UPM" and related patches
From: Anton Vorontsov @ 2007-12-12 16:55 UTC (permalink / raw)
To: Scott Wood; +Cc: linuxppc-dev
In-Reply-To: <20071212164035.GB4329@loki.buserror.net>
On Wed, Dec 12, 2007 at 10:40:35AM -0600, Scott Wood wrote:
> On Mon, Dec 10, 2007 at 11:47:05PM +0300, Anton Vorontsov wrote:
> > 5 - FSL UPM infrastructure:
> > ---------------------------
> > UPM address register is shared among UPMs, so we have to do
> > proper locking. On the other hand, if we know that specific
> > board using only one UPM we could bypass locking, and gain some
> > performance win.
>
> Not enough to be worth the complexity compared to the overhead of NAND
> access -- especially in the likely case of a non-SMP build.
I'm allowing UPM access from the IRQ handlers (because nothing prevents
this, so why deny?). Thus locks are needed even on non-SMP build, on
UP they aren't thrown away. Lockless variant occupy less than 30 lines of
code, so I'd rather keep it.
--
Anton Vorontsov
email: cbou@mail.ru
backup email: ya-cbou@yandex.ru
irc://irc.freenode.net/bd2
^ permalink raw reply
* Re: [PATCH RFC 0/7] "NAND on UPM" and related patches
From: Scott Wood @ 2007-12-12 16:54 UTC (permalink / raw)
To: avorontsov; +Cc: linuxppc-dev
In-Reply-To: <20071212165513.GA30981@localhost.localdomain>
Anton Vorontsov wrote:
> On Wed, Dec 12, 2007 at 10:40:35AM -0600, Scott Wood wrote:
>> Not enough to be worth the complexity compared to the overhead of NAND
>> access -- especially in the likely case of a non-SMP build.
>
> I'm allowing UPM access from the IRQ handlers (because nothing prevents
> this, so why deny?). Thus locks are needed even on non-SMP build,
No, it just needs to disable interrupts. Which is what locks do on
non-SMP. The overhead of this is not worth 30 lines of code to avoid.
-Scott
^ permalink raw reply
* Re: [PATCH RFC 3/7] [POWERPC] CPM2: implement GPIO API
From: Scott Wood @ 2007-12-12 16:56 UTC (permalink / raw)
To: Anton Vorontsov; +Cc: linuxppc-dev
In-Reply-To: <20071210204845.GC32278@localhost.localdomain>
On Mon, Dec 10, 2007 at 11:48:45PM +0300, Anton Vorontsov wrote:
> +EXPORT_SYMBOL_GPL(gpio_request);
> +EXPORT_SYMBOL_GPL(gpio_direction_input);
> +EXPORT_SYMBOL_GPL(gpio_direction_output);
> +EXPORT_SYMBOL_GPL(gpio_get_value);
> +EXPORT_SYMBOL_GPL(gpio_set_value);
These look like APIs, not internal functions. Why the GPL DRM?
-Scott
^ permalink raw reply
* [RFC] ehea: kdump support using new shutdown hook
From: Thomas Klein @ 2007-12-12 16:53 UTC (permalink / raw)
To: Paul Mackerras
Cc: Michael Neuling, Jan-Bernd Themann, netdev, linux-kernel,
linux-ppc, Christoph Raisch, Marcus Eder, Stefan Roscher
This patch adds kdump support using the new PPC crash shutdown hook to the
ehea driver. The driver now keeps a list of firmware handles which have to
be freed in case of a crash. The crash handler does the minimum required: it
frees the firmware resource handles plus broadcast/multicast registrations.
Please comment.
Shutdown hook patches:
http://ozlabs.org/pipermail/linuxppc-dev/2007-December/048058.html
http://ozlabs.org/pipermail/linuxppc-dev/2007-December/048059.html
Signed-off-by: Thomas Klein <tklein@de.ibm.com>
---
diff -Nurp -X dontdiff linux-2.6.24-rc5/drivers/net/ehea/ehea.h patched_kernel/drivers/net/ehea/ehea.h
--- linux-2.6.24-rc5/drivers/net/ehea/ehea.h 2007-12-11 04:48:43.000000000 +0100
+++ patched_kernel/drivers/net/ehea/ehea.h 2007-12-12 17:30:53.000000000 +0100
@@ -40,7 +40,7 @@
#include <asm/io.h>
#define DRV_NAME "ehea"
-#define DRV_VERSION "EHEA_0083"
+#define DRV_VERSION "EHEA_0084"
/* eHEA capability flags */
#define DLPAR_PORT_ADD_REM 1
@@ -386,6 +386,7 @@ struct ehea_port_res {
#define EHEA_MAX_PORTS 16
+#define EHEA_MAX_RES_HANDLES (100 * EHEA_MAX_PORTS + 10)
struct ehea_adapter {
u64 handle;
struct of_device *ofdev;
@@ -397,6 +398,7 @@ struct ehea_adapter {
u64 max_mc_mac; /* max number of multicast mac addresses */
int active_ports;
struct list_head list;
+ u64 res_handles[EHEA_MAX_RES_HANDLES];
};
diff -Nurp -X dontdiff linux-2.6.24-rc5/drivers/net/ehea/ehea_main.c patched_kernel/drivers/net/ehea/ehea_main.c
--- linux-2.6.24-rc5/drivers/net/ehea/ehea_main.c 2007-12-11 04:48:43.000000000 +0100
+++ patched_kernel/drivers/net/ehea/ehea_main.c 2007-12-12 17:30:53.000000000 +0100
@@ -35,6 +35,7 @@
#include <linux/if_ether.h>
#include <linux/notifier.h>
#include <linux/reboot.h>
+#include <asm-powerpc/kexec.h>
#include <net/ip.h>
@@ -2256,6 +2257,33 @@ static int ehea_clean_all_portres(struct
return ret;
}
+static void ehea_update_adapter_handles(struct ehea_adapter *adapter)
+{
+ int i, k;
+ int j = 0;
+
+ memset(adapter->res_handles, sizeof(adapter->res_handles), 0);
+
+ for (k = 0; k < EHEA_MAX_PORTS; k++) {
+ struct ehea_port *port = adapter->port[k];
+
+ if (!port || (port->state != EHEA_PORT_UP))
+ continue;
+
+ for(i = 0; i < port->num_def_qps + port->num_add_tx_qps; i++) {
+ struct ehea_port_res *pr = &port->port_res[i];
+
+ adapter->res_handles[j++] = pr->qp->fw_handle;
+ adapter->res_handles[j++] = pr->send_cq->fw_handle;
+ adapter->res_handles[j++] = pr->recv_cq->fw_handle;
+ adapter->res_handles[j++] = pr->eq->fw_handle;
+ adapter->res_handles[j++] = pr->send_mr.handle;
+ adapter->res_handles[j++] = pr->recv_mr.handle;
+ }
+ adapter->res_handles[j++] = port->qp_eq->fw_handle;
+ }
+}
+
static void ehea_remove_adapter_mr(struct ehea_adapter *adapter)
{
if (adapter->active_ports)
@@ -2318,6 +2346,7 @@ static int ehea_up(struct net_device *de
ret = 0;
port->state = EHEA_PORT_UP;
+ ehea_update_adapter_handles(port->adapter);
goto out;
out_free_irqs:
@@ -2387,6 +2416,8 @@ static int ehea_down(struct net_device *
ehea_info("Failed freeing resources for %s. ret=%i",
dev->name, ret);
+ ehea_update_adapter_handles(port->adapter);
+
return ret;
}
@@ -3302,6 +3333,71 @@ static int __devexit ehea_remove(struct
return 0;
}
+void ehea_crash_deregister(void)
+{
+ struct ehea_adapter *adapter;
+ int i;
+ u64 hret;
+ u8 reg_type;
+
+ list_for_each_entry(adapter, &adapter_list, list) {
+ for (i = 0; i < EHEA_MAX_PORTS; i++) {
+ struct ehea_port *port = adapter->port[i];
+ if (port->state == EHEA_PORT_UP) {
+ struct ehea_mc_list *mc_entry = port->mc_list;
+ struct list_head *pos;
+ struct list_head *temp;
+
+ /* Undo multicast registrations */
+ list_for_each_safe(pos, temp,
+ &(port->mc_list->list)) {
+ mc_entry = list_entry(pos,
+ struct ehea_mc_list,
+ list);
+ ehea_multicast_reg_helper(port,
+ mc_entry->macaddr,
+ H_DEREG_BCMC);
+ }
+
+ /* Undo broad registration */
+ reg_type = EHEA_BCMC_BROADCAST |
+ EHEA_BCMC_UNTAGGED;
+ ehea_h_reg_dereg_bcmc(port->adapter->handle,
+ port->logical_port_id,
+ reg_type, port->mac_addr,
+ 0, H_DEREG_BCMC);
+
+ reg_type = EHEA_BCMC_BROADCAST |
+ EHEA_BCMC_VLANID_ALL;
+ ehea_h_reg_dereg_bcmc(port->adapter->handle,
+ port->logical_port_id,
+ reg_type, port->mac_addr,
+ 0, H_DEREG_BCMC);
+ }
+ }
+ for (i = 0; i < EHEA_MAX_RES_HANDLES; i++) {
+ u64 handle = adapter->res_handles[i];
+ if (handle) {
+ hret = ehea_h_free_resource(adapter->handle,
+ handle,
+ FORCE_FREE);
+ }
+ }
+
+ if (adapter->neq) {
+ hret = ehea_h_free_resource(adapter->handle,
+ adapter->neq->fw_handle,
+ FORCE_FREE);
+ }
+
+ if (adapter->mr.handle) {
+ hret = ehea_h_free_resource(adapter->handle,
+ adapter->mr.handle,
+ FORCE_FREE);
+ }
+ }
+}
+
static int ehea_reboot_notifier(struct notifier_block *nb,
unsigned long action, void *unused)
{
@@ -3373,6 +3469,9 @@ int __init ehea_module_init(void)
goto out;
register_reboot_notifier(&ehea_reboot_nb);
+ ret = crash_shutdown_register(&ehea_crash_deregister);
+ if (ret)
+ ehea_info("failed registering crash handler");
ret = ibmebus_register_driver(&ehea_driver);
if (ret) {
@@ -3386,6 +3485,7 @@ int __init ehea_module_init(void)
ehea_error("failed to register capabilities attribute, ret=%d",
ret);
unregister_reboot_notifier(&ehea_reboot_nb);
+ crash_shutdown_unregister(&ehea_crash_deregister);
ibmebus_unregister_driver(&ehea_driver);
goto out;
}
@@ -3396,10 +3496,15 @@ out:
static void __exit ehea_module_exit(void)
{
+ int ret;
+
flush_scheduled_work();
driver_remove_file(&ehea_driver.driver, &driver_attr_capabilities);
ibmebus_unregister_driver(&ehea_driver);
unregister_reboot_notifier(&ehea_reboot_nb);
+ ret = crash_shutdown_unregister(&ehea_crash_deregister);
+ if (ret)
+ ehea_info("failed unregistering crash handler");
ehea_destroy_busmap();
}
^ permalink raw reply
* Re: [PATCH RFC 7/7] [POWERPC] MPC8360E-RDK: add support for NAND on UPM
From: Scott Wood @ 2007-12-12 16:59 UTC (permalink / raw)
To: Anton Vorontsov; +Cc: linuxppc-dev
In-Reply-To: <20071210204951.GG32278@localhost.localdomain>
On Mon, Dec 10, 2007 at 11:49:51PM +0300, Anton Vorontsov wrote:
> + localbus@e0005000 {
> + #address-cells = <2>;
> + #size-cells = <1>;
> + compatible = "fsl,mpc8360erdk-localbus",
> + "fsl,mpc8360e-localbus",
> + "fsl,pq2pro-localbus";
The board name shouldn't be in there.
> + reg = <0xe0005000 0xd8>;
> + ranges = <1 0 0x60000000 1>;
> +
> + nand-flash@1,0 {
> + compatible = "STMicro,NAND512W3A2BN6E", "fsl,upm-nand";
Technically, if the vendor part begins with a capital letter it's supposed
to be either a stock symbol or an OUI.
-Scott
^ 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