* Re: [patch 6/6] Walnut zImage wrapper
From: David Gibson @ 2007-09-03 1:13 UTC (permalink / raw)
To: Josh Boyer; +Cc: linuxppc-dev
In-Reply-To: <20070831200643.675381000@linux.vnet.ibm.com>
On Fri, Aug 31, 2007 at 03:04:55PM -0500, Josh Boyer wrote:
> Add zImage wrapper for walnut board
>
> Signed-off-by: Josh Boyer <jwboyer@linux.vnet.ibm.com>
[snip]
> --- /dev/null
> +++ linux-2.6/arch/powerpc/boot/treeboot-walnut.c
> @@ -0,0 +1,133 @@
> +/*
> + * Old U-boot compatibility for Walnut
> + *
> + * Author: Josh Boyer <jwboyer@linux.vnet.ibm.com>
> + *
> + * Copyright 2007 IBM Corporation
> + * Based on cuboot-83xx.c, which is:
> + * Copyright (c) 2007 Freescale Semiconductor, Inc.
> + *
> + * This program is free software; you can redistribute it and/or modify it
> + * under the terms of the GNU General Public License version 2 as published
> + * by the Free Software Foundation.
> + */
> +
> +#include "ops.h"
> +#include "stdio.h"
> +#include "dcr.h"
> +#include "4xx.h"
> +#include "io.h"
> +
> +BSS_STACK(4096);
> +
> +void ibm405gp_fixup_clocks(unsigned int sysclk, unsigned int ser_clk)
> +{
> + u32 pllmr = mfdcr(0xb0);
Please add #defines for the DCR numbers, rather than using literals.
> + u32 cpc0_cr0 = mfdcr(0xb1);
> + u32 cpc0_cr1 = mfdcr(0xb2);
> + u32 cpu, plb, opb, ebc, tb, uart0, uart1, m;
> + u32 fwdv, fbdv, cbdv, opdv, epdv, udiv;
> +
> + fwdv = (8 - ((pllmr & 0xe0000000) >> 29));
> + fbdv = (pllmr & 0x1e000000) >> 25;
> + cbdv = ((pllmr & 0x00060000) >> 17) + 1;
> + opdv = ((pllmr & 0x00018000) >> 15) + 1;
> + epdv = ((pllmr & 0x00001800) >> 13) + 2;
> + udiv = ((cpc0_cr0 & 0x3e) >> 1) + 1;
> +
> + m = fwdv * fbdv * cbdv;
> +
> + cpu = sysclk * m / fwdv;
> + plb = cpu / cbdv;
> + opb = plb / opdv;
> + ebc = plb / epdv;
> +
> + if (cpc0_cr0 & 0x80) {
> + /* uart0 uses the external clock */
> + uart0 = ser_clk;
> + } else {
> + uart0 = cpu / udiv;
> + }
> +
> + if (cpc0_cr0 & 0x40) {
> + /* uart1 uses the external clock */
> + uart1 = ser_clk;
> + } else {
> + uart1 = cpu / udiv;
> + }
> +
> + /* setup the timebase clock to tick at the cpu frequency */
> + cpc0_cr1 = cpc0_cr1 & ~ 0x00800000;
> + mtdcr(0xb2, cpc0_cr1);
> + tb = cpu;
> +
> + dt_fixup_cpu_clocks(cpu, tb, 0);
> + dt_fixup_clock("/plb", plb);
> + dt_fixup_clock("/plb/opb", opb);
> + dt_fixup_clock("/plb/ebc", ebc);
> + dt_fixup_clock("/plb/opb/serial@300", uart0);
> + dt_fixup_clock("/plb/opb/serial@400", uart1);
> +}
> +
> +static void walnut_flashsel_fixup(void)
> +{
> + void *devp, *sram;
> + u32 reg_flash[3] = {0x0, 0x0, 0x80000};
> + u32 reg_sram[3] = {0x0, 0x0, 0x80000};
> + u8 *fpga;
> + u8 fpga_brds1 = 0x0;
> +
> + devp = finddevice("/plb/ebc/fpga");
> + if (!devp)
> + fatal("Couldn't locate FPGA node\n\r");
> +
> + if (getprop(devp, "virtual-reg", &fpga, sizeof(fpga)) != sizeof(fpga))
> + fatal("no virtual-reg property\n\r");
> +
> + fpga_brds1 = in_8(fpga);
> +
> + printf("FPGA_BRDS1: %08x\n", fpga_brds1);
> +
> + devp = finddevice("/plb/ebc/flash");
> + if (!devp)
> + fatal("Couldn't locate flash node\n\r");
> +
> + if (getprop(devp, "reg", reg_flash, sizeof(reg_flash)) != sizeof(reg_flash))
> + fatal("flash reg property has unexpected size\n\r");
> +
> + sram = finddevice("/plb/ebc/sram");
> + if (!sram)
> + fatal("Couldn't locate sram node\n\r");
> +
> + if (getprop(sram, "reg", reg_sram, sizeof(reg_sram)) != sizeof(reg_sram))
> + fatal("sram reg property has unexpected size\n\r");
> +
> + if (fpga_brds1 & 0x1) {
> + reg_flash[1] ^= 0x80000;
> + reg_sram[1] ^= 0x80000;
> + }
> +
> + setprop(devp, "reg", reg_flash, sizeof(reg_flash));
> + setprop(sram, "reg", reg_sram, sizeof(reg_sram));
> +}
> +
> +static void walnut_fixups(void)
> +{
> + ibm4xx_fixup_memsize();
> + ibm405gp_fixup_clocks(33330000, 0xa8c000);
> + ibm4xx_quiesce_eth((u32 *)0xef600800, NULL);
> + ibm4xx_fixup_ebc_ranges("/plb/ebc");
> + walnut_flashsel_fixup();
> +}
> +
> +void platform_init(void)
> +{
> + unsigned long end_of_ram = 0x2000000;
> + unsigned long avail_ram = end_of_ram - (unsigned long) _end;
> +
> + simple_alloc_init(_end, avail_ram, 32, 32);
> + platform_ops.fixups = walnut_fixups;
> + platform_ops.exit = ibm40x_dbcr_reset;
> + ft_init(_dtb_start, _dtb_end - _dtb_start, 32);
> + serial_console_init();
> +}
>
--
David Gibson | I'll have my music baroque, and my code
david AT gibson.dropbear.id.au | minimalist, thank you. NOT _the_ _other_
| _way_ _around_!
http://www.ozlabs.org/~dgibson
^ permalink raw reply
* Re: [patch 3/6] Walnut DTS
From: David Gibson @ 2007-09-03 1:08 UTC (permalink / raw)
To: Josh Boyer; +Cc: linuxppc-dev
In-Reply-To: <20070831200643.202414000@linux.vnet.ibm.com>
On Fri, Aug 31, 2007 at 03:04:52PM -0500, Josh Boyer wrote:
> Device tree source file for the PPC405 Walnut evaluation board.
>
> Signed-off-by: Josh Boyer <jwboyer@linux.vnet.ibm.com>
>
> ---
> arch/powerpc/boot/dts/walnut.dts | 183 +++++++++++++++++++++++++++++++++++++++
> 1 file changed, 183 insertions(+)
>
> --- /dev/null
> +++ linux-2.6/arch/powerpc/boot/dts/walnut.dts
> @@ -0,0 +1,183 @@
> +/*
> + * Device Tree Source for IBM Walnut
> + *
> + * Copyright 2007 IBM Corp.
> + * Josh Boyer <jwboyer@linux.vnet.ibm.com>
> + *
> + * This file is licensed under the terms of the GNU General Public
> + * License version 2. This program is licensed "as is" without
> + * any warranty of any kind, whether express or implied.
> + */
> +
> +/ {
> + #address-cells = <1>;
> + #size-cells = <1>;
> + model = "ibm,walnut";
> + compatible = "ibm,walnut";
> + dcr-parent = <&/cpus/PowerPC,405GP@0>;
> +
> + cpus {
> + #address-cells = <1>;
> + #size-cells = <0>;
> +
> + PowerPC,405GP@0 {
> + device_type = "cpu";
> + reg = <0>;
> + clock-frequency = <bebc200>; /* Filled in by zImage */
> + timebase-frequency = <0>; /* Filled in by zImage */
> + i-cache-line-size = <20>;
> + d-cache-line-size = <20>;
> + i-cache-size = <4000>;
> + d-cache-size = <4000>;
> + dcr-controller;
> + dcr-access-method = "native";
> + };
> + };
> +
> + memory {
> + device_type = "memory";
> + reg = <0 0>; /* Filled in by zImage */
> + };
> +
> + UIC0: interrupt-controller {
> + compatible = "ibm,uic";
> + interrupt-controller;
> + cell-index = <0>;
> + dcr-reg = <0c0 9>;
> + #address-cells = <0>;
> + #size-cells = <0>;
> + #interrupt-cells = <2>;
> + };
> +
> + plb {
> + compatible = "ibm,plb3";
> + #address-cells = <1>;
> + #size-cells = <1>;
> + ranges;
> + clock-frequency = <0>; /* Filled in by zImage */
> +
> + SDRAM0: memory-controller {
> + compatible = "ibm,sdram-405gp";
> + dcr-reg = <010 2>;
> + };
> +
> + MAL: mcmal {
> + compatible = "ibm,mcmal-405gp", "ibm,mcmal";
> + dcr-reg = <180 62>;
> + num-tx-chans = <2>;
> + num-rx-chans = <1>;
> + interrupt-parent = <&UIC0>;
> + interrupts = <a 4 b 4 c 4 d 4 e 4>;
> + };
> +
> + POB0: opb {
> + compatible = "ibm,opb";
Need an opb-405gp here, too.
> + #address-cells = <1>;
> + #size-cells = <1>;
> + ranges = <0 ef600000 a00000>;
Hrm... something we ought to clarify is the interpretation of the
POB0_BEAR register with respect to the bridge's ranges property. For
440 I think the BEAR will need to be interpreted as an OPB address,
rather than a PLB address, but I'm not sure if that will work here
with the limited ranges property you have.
> + dcr-reg = <0a0 5>;
> + clock-frequency = <0>; /* Filled in by zImage */
> +
> + UART0: serial@300 {
> + device_type = "serial";
> + compatible = "ns16550";
> + reg = <300 8>;
> + virtual-reg = <ef600300>;
> + clock-frequency = <0>; /* Filled in by zImage */
> + current-speed = <2580>;
> + interrupt-parent = <&UIC0>;
> + interrupts = <0 4>;
> + };
> +
> + UART1: serial@400 {
> + device_type = "serial";
> + compatible = "ns16550";
> + reg = <400 8>;
> + virtual-reg = <ef600400>;
> + clock-frequency = <0>; /* Filled in by zImage */
> + current-speed = <2580>;
> + interrupt-parent = <&UIC0>;
> + interrupts = <1 4>;
> + };
> +
> + IIC: i2c@500 {
> + compatible = "ibm,iic-405gp", "ibm,iic";
> + reg = <500 11>;
> + interrupt-parent = <&UIC0>;
> + interrupts = <2 4>;
> + };
> +
> + GPIO: gpio@700 {
> + compatible = "ibm,gpio-405gp";
> + reg = <700 20>;
> + };
> +
> + EMAC: ethernet@800 {
> + linux,network-index = <0>;
> + device_type = "network";
> + compatible = "ibm,emac-405gp", "ibm,emac";
> + interrupt-parent = <&UIC0>;
> + interrupts = <9 4 f 4>;
> + reg = <800 70>;
> + mal-device = <&MAL>;
> + mal-tx-channel = <0 1>;
> + mal-rx-channel = <0>;
> + cell-index = <0>;
> + max-frame-size = <5dc>;
> + rx-fifo-size = <1000>;
> + tx-fifo-size = <800>;
> + phy-mode = "rmii";
> + phy-map = <00000001>;
> + };
> +
> + };
> +
> + EBC0: ebc {
> + compatible = "ibm,ebc-405gp", "ibm,ebc";
> + dcr-reg = <012 2>;
> + #address-cells = <2>;
> + #size-cells = <1>;
> + clock-frequency = <0>; /* Filled in by zImage */
> +
> + sram@0,0 {
> + reg = <0 0 80000>;
> + };
> +
> + flash@0,80000 {
> + device_type = "rom";
> + compatible = "direct-mapped";
> + probe-type = "JEDEC";
> + bank-width = <1>;
> + partitions = <0 80000>;
> + partition-names = "OpenBIOS";
> + reg = <0 80000 80000>;
> + };
> +
> + ds1743@1,0 {
> + /* NVRAM and RTC */
> + compatible = "ds1743";
> + reg = <1 0 2000>;
> + };
> +
> + keyboard@2,0 {
> + compatible = "intel,82C42PC";
> + reg = <2 0 2>;
> + };
> +
> + ir@3,0 {
> + compatible = "ti,TIR2000PAG";
> + reg = <3 0 10>;
> + };
> +
> + fpga@7,0 {
> + compatible = "Walnut-FPGA";
> + reg = <7 0 10>;
> + virtual-reg = <f0300005>;
> + };
> + };
> + };
> +
> + chosen {
> + linux,stdout-path = "/plb/opb/serial@300";
> + };
> +};
>
--
David Gibson | I'll have my music baroque, and my code
david AT gibson.dropbear.id.au | minimalist, thank you. NOT _the_ _other_
| _way_ _around_!
http://www.ozlabs.org/~dgibson
^ permalink raw reply
* Re: [patch 2/6] cuimage for Bamboo board
From: David Gibson @ 2007-09-03 1:01 UTC (permalink / raw)
To: Josh Boyer; +Cc: linuxppc-dev
In-Reply-To: <20070831200643.029244000@linux.vnet.ibm.com>
On Fri, Aug 31, 2007 at 03:04:51PM -0500, Josh Boyer wrote:
> Add a cuboot wrapper for the Bamboo board. This also removes some obsoleted
> linker declarations that have been moved into ops.h
>
> Signed-off-by: Josh Boyer <jwboyer@linux.vnet.ibm.com>
[snip]
> --- linux-2.6.orig/arch/powerpc/boot/bamboo.c
> +++ linux-2.6/arch/powerpc/boot/bamboo.c
> @@ -24,8 +24,7 @@
> #include "4xx.h"
> #include "44x.h"
>
> -extern char _dtb_start[];
> -extern char _dtb_end[];
> +static u8 *bamboo_mac0, *bamboo_mac1;
>
> static void bamboo_fixups(void)
> {
> @@ -34,12 +33,16 @@ static void bamboo_fixups(void)
> ibm440ep_fixup_clocks(sysclk, 11059200);
> ibm4xx_fixup_memsize();
> ibm4xx_quiesce_eth((u32 *)0xef600e00, (u32 *)0xef600f00);
> + if (bamboo_mac0 && bamboo_mac1)
> + dt_fixup_mac_addresses(bamboo_mac0, bamboo_mac1);
Bit ugly that you only set the MAC address for any ethernet if they're
supplied for every ethernet.
> }
>
> -void bamboo_init(void)
> +void bamboo_init(void *mac0, void *mac1)
> {
> platform_ops.fixups = bamboo_fixups;
> platform_ops.exit = ibm44x_dbcr_reset;
> + bamboo_mac0 = mac0;
> + bamboo_mac1 = mac1;
> ft_init(_dtb_start, 0, 32);
> serial_console_init();
> }
> --- linux-2.6.orig/arch/powerpc/boot/treeboot-bamboo.c
> +++ linux-2.6/arch/powerpc/boot/treeboot-bamboo.c
> @@ -13,8 +13,6 @@
> #include "stdio.h"
> #include "44x.h"
>
> -extern char _end[];
> -
> BSS_STACK(4096);
>
> void platform_init(void)
> @@ -23,5 +21,5 @@ void platform_init(void)
> unsigned long avail_ram = end_of_ram - (unsigned long)_end;
>
> simple_alloc_init(_end, avail_ram, 32, 64);
> - bamboo_init();
> + bamboo_init(NULL, NULL);
There must surely be a way to get the MAC addresses out of OpenBIOS...
--
David Gibson | I'll have my music baroque, and my code
david AT gibson.dropbear.id.au | minimalist, thank you. NOT _the_ _other_
| _way_ _around_!
http://www.ozlabs.org/~dgibson
^ permalink raw reply
* Re: [PATCH] mpc5200: add cuimage support for mpc5200 boards
From: David Gibson @ 2007-09-03 0:44 UTC (permalink / raw)
To: Grant Likely; +Cc: linuxppc-dev
In-Reply-To: <20070831173437.11244.80596.stgit@trillian.cg.shawcable.net>
On Fri, Aug 31, 2007 at 11:34:37AM -0600, Grant Likely wrote:
> From: Grant Likely <grant.likely@secretlab.ca>
>
> Signed-off-by: Grant Likely <grant.likely@secretlab.ca>
Acked-by: David Gibson <david@gibson.dropbear.id.au>
With all these FSL boards poking the bus-frequency and so forth in the
soc node, we should see if it's possible to make a common helper
function to do some of it.
--
David Gibson | I'll have my music baroque, and my code
david AT gibson.dropbear.id.au | minimalist, thank you. NOT _the_ _other_
| _way_ _around_!
http://www.ozlabs.org/~dgibson
^ permalink raw reply
* Re: Ethernet weirdness on 82xx
From: Denys @ 2007-09-02 11:12 UTC (permalink / raw)
To: Rune Torgersen, linuxppc-embedded, netdev
In-Reply-To: <DCEAAC0833DD314AB0B58112AD99B93B0353A6AB@ismail.innsys.innovsys.com>
Thats normal.
Check arp_filter sysctl :
arp_filter - BOOLEAN
1 - Allows you to have multiple network interfaces on the same
subnet, and have the ARPs for each interface be answered
based on whether or not the kernel would route a packet from
the ARP'd IP out that interface (therefore you must use source
based routing for this to work). In other words it allows control
of which cards (usually 1) will respond to an arp request.
0 - (default) The kernel can respond to arp requests with addresses
from other interfaces. This may seem wrong but it usually makes
sense, because it increases the chance of successful communication.
IP addresses are owned by the complete host on Linux, not by
particular interfaces. Only for more complex setups like load-
balancing, does this behaviour cause problems.
arp_filter for the interface will be enabled if at least one of
conf/{all,interface}/arp_filter is set to TRUE,
it will be disabled otherwise
IMHO default setting can mess up things in some conditions.
On Fri, 31 Aug 2007 16:35:19 -0500, Rune Torgersen wrote
> I'm not sure if this is by design or an actual bug.
>
> We have a system witb an 8280 with two active ethernets (fcc2 and
> fcc3) We are running kernel 2.6.18.1 (and won't be upgrading in a
> while) out of arch/ppc
>
> Eth0 and eth1 are in totally different subnets.
> We happened to have both ehternets connected to the same network,
> and I ran a arping agains the IP on eth0. Both ports (eth0 and eth1)
> responded with the same address, but different macs....
>
> sudo /sbin/arping -c1 172.23.12.114
> ARPING 172.23.12.114 from 172.23.15.21 eth0
> Unicast reply from 172.23.12.114 [00:30:D7:00:14:55] 0.838ms
> Unicast reply from 172.23.12.114 [00:30:D7:00:14:54] 0.890ms
> Sent 1 probes (1 broadcast(s))
> Received 2 response(s)
>
> It only gets both responses on the first (broadcast) query from
> arping All responses afterward is then from the wrong port....
>
> The ethernet setup on the target box:
>
> eth0 Link encap:Ethernet HWaddr 00:30:D7:00:14:54
> inet addr:172.23.12.114 Bcast:172.23.15.255
> Mask:255.255.248.0
> UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
> RX packets:473244 errors:0 dropped:2 overruns:0 frame:0
> TX packets:186655 errors:0 dropped:0 overruns:0 carrier:0
> collisions:0 txqueuelen:1000
> RX bytes:162928671 (155.3 Mb) TX bytes:42222862 (40.2 Mb)
> Base address:0x8500
>
> eth1 Link encap:Ethernet HWaddr 00:30:D7:00:14:55
> inet addr:192.168.0.100 Bcast:192.168.0.255
> Mask:255.255.255.0
> UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
> RX packets:1553 errors:0 dropped:0 overruns:0 frame:0
> TX packets:4 errors:0 dropped:0 overruns:0 carrier:0
> collisions:0 txqueuelen:1000
> RX bytes:203182 (198.4 Kb) TX bytes:168 (168.0 b)
> Base address:0x8600
> -
> To unsubscribe from this list: send the line "unsubscribe netdev" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at http://vger.kernel.org/majordomo-info.html
--
Denys Fedoryshchenko
Technical Manager
Virtual ISP S.A.L.
^ permalink raw reply
* Re: Ethernet weirdness on 82xx
From: Denys @ 2007-09-02 11:14 UTC (permalink / raw)
To: Rune Torgersen, linuxppc-embedded, netdev
In-Reply-To: <DCEAAC0833DD314AB0B58112AD99B93B0353A6AB@ismail.innsys.innovsys.com>
Sorry forgot, maybe also arp_ignore is related to that
--
Denys Fedoryshchenko
Technical Manager
Virtual ISP S.A.L.
^ permalink raw reply
* kernel stack overflow problem
From: Qin Lin @ 2007-09-02 8:08 UTC (permalink / raw)
To: linuxppc-embedded
Hi all
I am a newer for kernel programming.
when i testing codec ,there is a kernel stack overflow. NOW i want to find
where the problem was from?
Does that message following mean the ac97 drive or xsysace driver has
problem?
Thanks!
# aplay root/aq_ac97/yonggan.wav
[ 205.995325] ml403_ac97cr: open(playback)
Playing WAVE 'root/aq_ac97/yonggan.wav' : Signed 16 bit Little Endian, Rate
44100 Hz, Stereo
[ 206.189147] ml403_ac97cr: hw_params(): desired buffer bytes=65536,
desired period bytes=16384
[ 206.291230] ml403_ac97cr: prepare(): period_bytes=16384,
minperiod_bytes=16
[ 206.379885] ml403_ac97cr: codec_write(): (done) reg=0x2c, value=44100 /
0xac44 (no RAF check)
[ 206.481245] ml403_ac97cr: codec_read(): read access answered by shadow
register 0x2c (value=0xbb80 / 4)[ 206.597893] ml403_ac97cr: prepare():
rate=44100
[ 206.652192] ml403_ac97cr: prepare(): hw_buffer_size=32,
sw_buffer_size=65536, min_multiple=1024
[ 207.023382] ml403_ac97cr: trigger(playback): START
[ 207.079881] ml403_ac97cr: trigger(playback): (done)
[ 207.152947] Kernel stack overflow in process c02a2850, r1=c0313f30
[ 207.226581] Oops: kernel access of bad area, sig: 11 [#1]
[ 207.290679] NIP: C001327C LR: C001666C CTR: 00000000
[ 207.350048] REGS: c01971f0 TRAP: 0300 Not tainted (2.6.20)
[ 207.418778] MSR: 00021030 <ME,IR,DR> CR: 22000028 XER: 00000000
[ 207.491683] DAR: 00000005, DSISR: 00000000
[ 207.540639] TASK = c02a2850[134] 'xsysace' THREAD: c0314000
[ 207.605205] GPR00: 00000001 C01972A0 C02A2850 00000000 C01B7770 00000012
00000300 00000010
[ 207.705188] GPR08: FFFFFFFA 00000020 00000000 00000005 00000000 FFFF87B8
03FD0700 00000000
[ 207.805172] GPR16: 00000001 00800000 03FCF588 00000000 FFFFFFFF 007FFF00
03FC9FFC 00000002
[ 207.905156] GPR24: 03E667C0 C01B0000 C010600C C01B7770 00000012 00000000
00000000 C0197470
[ 208.007224] NIP [C001327C] xmon_write+0x38/0xbc
[ 208.061381] LR [C001666C] xmon_vfprintf+0x34/0x48
[ 208.117622] Call Trace:
[ 208.146784] Instruction dump:
[ 208.182198] bf61000c 90010024 3d20c01b 800931bc 7c9b2378 2f800000
7cbc2b78 40be0008
[ 208.274889] 4bfffe2d 3ba00000 3bc00000 48000054 <880b0000> 7c0a4839
4182fff8 7ffbf0ae
[ 208.369705] Oops: kernel access of bad area, sig: 11 [#2]
[ 208.434244] NIP: C001327C LR: C001666C CTR: 00000000
[ 208.493613] REGS: c0196d30 TRAP: 0300 Not tainted (2.6.20)
[ 208.562342] MSR: 00021030 <ME,IR,DR> CR: 22000048 XER: 00000000
[ 208.635247] DAR: 00000005, DSISR: 00000000
[ 208.684204] TASK = c02a2850[134] 'xsysace' THREAD: c0314000
[ 208.748768] GPR00: 00000001 C0196DE0 C02A2850 00000000 C01B7770 00000012
00000700 00000010
[ 208.848752] GPR08: FFFFFFFA 00000020 00000000 00000005 00000000 FFFF87B8
03FD0700 00000000
[ 208.948737] GPR16: 00000001 00800000 03FCF588 00000000 FFFFFFFF 007FFF00
03FC9FFC 00000002
[ 209.048720] GPR24: 03E667C0 C01B0000 C010600C C01B7770 00000012 00000000
00000000 C0197040
[ 209.150788] NIP [C001327C] xmon_write+0x38/0xbc
[ 209.204948] LR [C001666C] xmon_vfprintf+0x34/0x48
[ 209.261190] Call Trace:
[ 209.290349] Instruction dump:
[ 209.325763] bf61000c 90010024 3d20c01b 800931bc 7c9b2378 2f800000
7cbc2b78 40be0008
[ 209.418454] 4bfffe2d 3ba00000 3bc00000 48000054 <880b0000> 7c0a4839
4182fff8 7ffbf0ae
[ 209.513264] Oops: kernel access of bad area, sig: 11 [#3]
[ 209.577808] NIP: C001327C LR: C001666C CTR: 00000000
[ 209.637177] REGS: c0196870 TRAP: 0300 Not tainted (2.6.20)
[ 209.705907] MSR: 00021030 <ME,IR,DR> CR: 22000048 XER: 00000000
[ 209.778812] DAR: 00000005, DSISR: 00000000
[ 209.827769] TASK = c02a2850[134] 'xsysace' THREAD: c0314000
[ 209.892334] GPR00: 00000001 C0196920 C02A2850 00000000 C01B7770 00000012
00000700 00000010
[ 209.992318] GPR08: FFFFFFFA 00000020 00000000 00000005 00000000 FFFF87B8
03FD0700 00000000
[ 210.092303] GPR16: 00000001 00800000 03FCF588 00000000 FFFFFFFF 007FFF00
03FC9FFC 00000002
[ 210.192286] GPR24: 03E667C0 C01B0000 C010600C C01B7770 00000012 00000000
00000000 C0196B80
[ 210.294353] NIP [C001327C] xmon_write+0x38/0xbc
[ 210.348512] LR [C001666C] xmon_vfprintf+0x34/0x48
[ 210.404753] Call Trace:
[ 210.433914] Instruction dump:
[ 210.469328] bf61000c 90010024 3d20c01b 800931bc 7c9b2378 2f800000
7cbc2b78 40be0008
[ 210.562020] 4bfffe2d 3ba00000 3bc00000 48000054 <880b0000> 7c0a4839
4182fff8 7ffbf0ae
[ 210.656833] Oops: kernel access of bad area, sig: 11 [#4]
[ 210.721375] NIP: C001327C LR: C001666C CTR: 00000000
[ 210.780741] REGS: c01963b0 TRAP: 0300 Not tainted (2.6.20)
[ 210.849472] MSR: 00021030 <ME,IR,DR> CR: 22000048 XER: 00000000
[ 210.922377] DAR: 00000005, DSISR: 00000000
[ 210.971335] TASK = c02a2850[134] 'xsysace' THREAD: c0314000
[ 211.035899] GPR00: 00000001 C0196460 C02A2850 00000000 C01B7770 00000012
00000700 00000010
[ 211.135883] GPR08: FFFFFFFA 00000020 00000000 00000005 00000000 FFFF87B8
03FD0700 00000000
[ 211.235867] GPR16: 00000001 00800000 03FCF588 00000000 FFFFFFFF 007FFF00
03FC9FFC 00000002
[ 211.335851] GPR24: 03E667C0 C01B0000 C010600C C01B7770 00000012 00000000
00000000 C01966C0
[ 211.437919] NIP [C001327C] xmon_write+0x38/0xbc
[ 211.492077] LR [C001666C] xmon_vfprintf+0x34/0x48
[ 211.548316] Call Trace:
[ 211.577478] Instruction dump:
[ 211.612892] bf61000c 90010024 3d20c01b 800931bc 7c9b2378 2f800000
7cbc2b78 40be0008
[ 211.705584] 4bfffe2d 3ba00000 3bc00000 48000054 <880b0000> 7c0a4839
4182fff8 7ffbf0ae
[ 211.800400] Oops: kernel access of bad area, sig: 11 [#5]
[ 211.864939] NIP: C001327C LR: C001666C CTR: 00000000
[ 211.924307] REGS: c0195ef0 TRAP: 0300 Not tainted (2.6.20)
[ 211.993036] MSR: 00021030 <ME,IR,DR> CR: 22000048 XER: 00000000
[ 212.065942] DAR: 00000005, DSISR: 00000000
[ 212.114900] TASK = c02a2850[134] 'xsysace' THREAD: c0314000
[ 212.179464] GPR00: 00000001 C0195FA0 C02A2850 00000000 C01B7770 00000012
00000700 00000010
[ 212.279448] GPR08: FFFFFFFA 00000020 00000000 00000005 00000000 FFFF87B8
03FD0700 00000000
[ 212.379433] GPR16: 00000001 00800000 03FCF588 00000000 FFFFFFFF 007FFF00
03FC9FFC 00000002
[ 212.479416] GPR24: 03E667C0 C01B0000 C010600C C01B7770 00000012 00000000
00000000 C0196200
[ 212.581484] NIP [C001327C] xmon_write+0x38/0xbc
[ 212.635642] LR [C001666C] xmon_vfprintf+0x34/0x48
[ 212.691881] Call Trace:
[ 212.721045] Instruction dump:
[ 212.756458] bf61000c 90010024 3d20c01b 800931bc 7c9b2378 2f800000
7cbc2b78 40be0008
[ 212.849149] 4bfffe2d 3ba00000 3bc00000 48000054 <880b0000> 7c0a4839
4182fff8 7ffbf0ae
[ 212.943963] Oops: kernel access of bad area, sig: 11 [#6]
[ 213.008504] NIP: C001327C LR: C001666C CTR: 00000000
[ 213.067872] REGS: c0195a30 TRAP: 0300 Not tainted (2.6.20)
[ 213.136602] MSR: 00021030 <ME,IR,DR> CR: 22000048 XER: 00000000
[ 213.209508] DAR: 00000005, DSISR: 00000000
[ 213.258465] TASK = c02a2850[134] 'xsysace' THREAD: c0314000
[ 213.323030] GPR00: 00000001 C0195AE0 C02A2850 00000000 C01B7770 00000012
00000700 00000010
[ 213.423014] GPR08: FFFFFFFA 00000020 00000000 00000005 00000000 FFFF87B8
03FD0700 00000000
[ 213.522998] GPR16: 00000001 00800000 03FCF588 00000000 FFFFFFFF 007FFF00
03FC9FFC 00000002
[ 213.622982] GPR24: 03E667C0 C01B0000 C010600C C01B7770 00000012 00000000
00000000 C0195D40
[ 213.725048] NIP [C001327C] xmon_write+0x38/0xbc
[ 213.779207] LR [C001666C] xmon_vfprintf+0x34/0x48
[ 213.835446] Call Trace:
[ 213.864610] Instruction dump:
[ 213.900023] bf61000c 90010024 3d20c01b 800931bc 7c9b2378 2f800000
7cbc2b78 40be0008
[ 213.992714] 4bfffe2d 3ba00000 3bc00000 48000054 <880b0000> 7c0a4839
4182fff8 7ffbf0ae
[ 214.087525] Oops: kernel access of bad area, sig: 11 [#7]
[ 214.152068] NIP: C001327C LR: C001666C CTR: 00000000
[ 214.211437] REGS: c0195570 TRAP: 0300 Not tainted (2.6.20)
[ 214.280167] MSR: 00021030 <ME,IR,DR> CR: 22000048 XER: 00000000
[ 214.353073] DAR: 00000005, DSISR: 00000000
[ 214.402029] TASK = c02a2850[134] 'xsysace' THREAD: c0314000
[ 214.466594] GPR00: 00000001 C0195620 C02A2850 00000000 C01B7770 00000012
00000700 00000010
[ 214.566579] GPR08: FFFFFFFA 00000020 00000000 00000005 00000000 FFFF87B8
03FD0700 00000000
[ 214.666563] GPR16: 00000001 00800000 03FCF588 00000000 FFFFFFFF 007FFF00
03FC9FFC 00000002
[ 214.766547] GPR24: 03E667C0 C01B0000 C010600C C01B7770 00000012 00000000
00000000 C0195880
[ 214.868614] NIP [C001327C] xmon_write+0x38/0xbc
[ 214.922772] LR [C001666C] xmon_vfprintf+0x34/0x48
[ 214.979012] Call Trace:
[ 215.008176] Instruction dump:
[ 215.043588] bf61000c 90010024 3d20c01b 800931bc 7c9b2378 2f800000
7cbc2b78 40be0008
[ 215.136280] 4bfffe2d 3ba00000 3bc00000 48000054 <880b0000> 7c0a4839
4182fff8 7ffbf0ae
[ 215.231092] Oops: kernel access of bad area, sig: 11 [#8]
[ 215.295634] NIP: C001327C LR: C001666C CTR: 00000000
[ 215.355004] REGS: c01950b0 TRAP: 0300 Not tainted (2.6.20)
[ 215.423732] MSR: 00021030 <ME,IR,DR> CR: 22000048 XER: 00000000
[ 215.496638] DAR: 00000005, DSISR: 00000000
[ 215.545595] TASK = c02a2850[134] 'xsysace' THREAD: c0314000
[ 215.610159] GPR00: 00000001 C0195160 C02A2850 00000000 C01B7770 00000012
00000700 00000010
[ 215.710144] GPR08: FFFFFFFA 00000020 00000000 00000005 00000000 FFFF87B8
03FD0700 00000000
[ 215.810128] GPR16: 00000001 00800000 03FCF588 00000000 FFFFFFFF 007FFF00
03FC9FFC 00000002
[ 215.910111] GPR24: 03E667C0 C01B0000 C010600C C01B7770 00000012 00000000
00000000 C01953C0
[ 216.012179] NIP [C001327C] xmon_write+0x38/0xbc
[ 216.066337] LR [C001666C] xmon_vfprintf+0x34/0x48
[ 216.122577] Call Trace:
[ 216.151740] Instruction dump:
[ 216.187152] bf61000c 90010024 3d20c01b 800931bc 7c9b2378 2f800000
7cbc2b78 40be0008
[ 216.279845] 4bfffe2d 3ba00000 3bc00000 48000054 <880b0000> 7c0a4839
4182fff8 7ffbf0ae
--
View this message in context: http://www.nabble.com/kernel-stack-overflow-problem-tf4367007.html#a12447116
Sent from the linuxppc-embedded mailing list archive at Nabble.com.
^ permalink raw reply
* Re:The question about the relocate_code on u-boot for MPC8360?
From: jxnuxdy @ 2007-09-02 2:01 UTC (permalink / raw)
To: 郭劲; +Cc: linuxppc-embedded
In-Reply-To: <388526407.00819@tsinghua.org.cn>
[-- Attachment #1: Type: text/plain, Size: 164 bytes --]
Why did you say the DDR is OK? This sympton is most probably due to your DDR memory issue, pls check the CS on it, and see if it continusly reset or not. - Denny
[-- Attachment #2: Type: text/html, Size: 621 bytes --]
^ permalink raw reply
* Re: [PATCH v7 3/3] [POWERPC] MPC832x_RDB: update dts to use SPI1in QE, register mmc_spi stub
From: Segher Boessenkool @ 2007-09-01 23:59 UTC (permalink / raw)
To: Li Yang-r58472; +Cc: linuxppc-dev, Tabi Timur-B04825
In-Reply-To: <989B956029373F45A0B8AF02970818900147BD4D@zch01exm26.fsl.freescale.net>
>>> + par_io_config_pin(3, 13, 1, 0, 0, 0); /* !SD_CS, O */
>>> + par_io_config_pin(3, 14, 2, 0, 0, 0); /* SD_INSERT, I */
>>> + par_io_config_pin(3, 15, 2, 0, 0, 0); /* SD_PROTECT,I */
>>
>> Why are you doing this here, and not in the device tree?
>
> I saw you used pio node, but later changed to make it hardcoded.
> What's
> the reason? IMO, device tree is used to describe the hardware
> settings,
> pio node is a perfect match.
Not at all. The device tree describe how the hardware _is_
set up (after firmware, bootloader etc.); now how it _should
be_ set up by the kernel.
It would make a lot of sense to do this work in the firmware
instead, but it doesn't make sense at all to put this stuff
into the device tree.
> Moreover, changing the device tree is much
> easier than changing the code.
How so? You don't like C code? :-)
Segher
^ permalink raw reply
* Re: STK5200 pci_enable_device problem
From: Wolfgang Denk @ 2007-09-01 23:23 UTC (permalink / raw)
To: Oliver Rutsch; +Cc: linuxppc-embedded
In-Reply-To: <46D68BA6.4020102@sympatec.com>
In message <46D68BA6.4020102@sympatec.com> you wrote:
>
> Thanks, Wolfang, now it's booting fine!
> I've updated u-boot to the newest git version, builded the device tree
> file and now everything's working.
I'm glad to hear that. Happy hacking!
Best regards,
Wolfgang Denk
--
DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd@denx.de
Yes, it's a technical challenge, and you have to kind of admire
people who go to the lengths of actually implementing it, but at the
same time you wonder about their IQ...
-- Linus Torvalds in <5phda5$ml6$1@palladium.transmeta.com>
^ permalink raw reply
* Ethernet weirdness on 82xx
From: Rune Torgersen @ 2007-08-31 21:35 UTC (permalink / raw)
To: linuxppc-embedded, netdev
I'm not sure if this is by design or an actual bug.
We have a system witb an 8280 with two active ethernets (fcc2 and fcc3)
We are running kernel 2.6.18.1 (and won't be upgrading in a while) out
of arch/ppc
Eth0 and eth1 are in totally different subnets.
We happened to have both ehternets connected to the same network, and I
ran a arping agains the IP on eth0.
Both ports (eth0 and eth1) responded with the same address, but
different macs....
sudo /sbin/arping -c1 172.23.12.114
ARPING 172.23.12.114 from 172.23.15.21 eth0
Unicast reply from 172.23.12.114 [00:30:D7:00:14:55] 0.838ms
Unicast reply from 172.23.12.114 [00:30:D7:00:14:54] 0.890ms
Sent 1 probes (1 broadcast(s))
Received 2 response(s)
It only gets both responses on the first (broadcast) query from arping
All responses afterward is then from the wrong port....
The ethernet setup on the target box:
eth0 Link encap:Ethernet HWaddr 00:30:D7:00:14:54
inet addr:172.23.12.114 Bcast:172.23.15.255
Mask:255.255.248.0
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:473244 errors:0 dropped:2 overruns:0 frame:0
TX packets:186655 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:162928671 (155.3 Mb) TX bytes:42222862 (40.2 Mb)
Base address:0x8500
eth1 Link encap:Ethernet HWaddr 00:30:D7:00:14:55
inet addr:192.168.0.100 Bcast:192.168.0.255
Mask:255.255.255.0
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:1553 errors:0 dropped:0 overruns:0 frame:0
TX packets:4 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:203182 (198.4 Kb) TX bytes:168 (168.0 b)
Base address:0x8600
^ permalink raw reply
* Re: [PATCH 2/2] IB/ehca: SRQ fixes to enable IPoIB CM
From: Roland Dreier @ 2007-08-31 20:59 UTC (permalink / raw)
To: Joachim Fenkes
Cc: LKML, LinuxPPC-Dev, Christoph Raisch, OF-General, Stefan Roscher
In-Reply-To: <200708311603.38822.fenkes@de.ibm.com>
thanks, applied 1 and 2.
^ permalink raw reply
* [patch 4/6] Walnut defconfig
From: Josh Boyer @ 2007-08-31 20:04 UTC (permalink / raw)
To: linuxppc-dev
In-Reply-To: <20070831200449.598781000@linux.vnet.ibm.com>
Walnut board defconfig
Signed-off-by: Josh Boyer <jwboyer@linux.vnet.ibm.com>
---
arch/powerpc/configs/walnut_defconfig | 698 ++++++++++++++++++++++++++++++++++
1 file changed, 698 insertions(+)
--- /dev/null
+++ linux-2.6/arch/powerpc/configs/walnut_defconfig
@@ -0,0 +1,698 @@
+#
+# Automatically generated make config: don't edit
+# Linux kernel version: 2.6.23-rc4
+# Tue Aug 28 09:29:22 2007
+#
+# CONFIG_PPC64 is not set
+
+#
+# Processor support
+#
+# CONFIG_6xx is not set
+# CONFIG_PPC_85xx is not set
+# CONFIG_PPC_8xx is not set
+CONFIG_40x=y
+# CONFIG_44x is not set
+# CONFIG_E200 is not set
+CONFIG_4xx=y
+# CONFIG_PPC_MM_SLICES is not set
+CONFIG_NOT_COHERENT_CACHE=y
+CONFIG_PPC32=y
+CONFIG_PPC_MERGE=y
+CONFIG_MMU=y
+CONFIG_GENERIC_HARDIRQS=y
+CONFIG_IRQ_PER_CPU=y
+CONFIG_RWSEM_XCHGADD_ALGORITHM=y
+CONFIG_ARCH_HAS_ILOG2_U32=y
+CONFIG_GENERIC_HWEIGHT=y
+CONFIG_GENERIC_CALIBRATE_DELAY=y
+CONFIG_GENERIC_FIND_NEXT_BIT=y
+# CONFIG_ARCH_NO_VIRT_TO_BUS is not set
+CONFIG_PPC=y
+CONFIG_EARLY_PRINTK=y
+CONFIG_GENERIC_NVRAM=y
+CONFIG_SCHED_NO_NO_OMIT_FRAME_POINTER=y
+CONFIG_ARCH_MAY_HAVE_PC_FDC=y
+CONFIG_PPC_OF=y
+CONFIG_OF=y
+# CONFIG_PPC_UDBG_16550 is not set
+# CONFIG_GENERIC_TBSYNC is not set
+CONFIG_AUDIT_ARCH=y
+CONFIG_GENERIC_BUG=y
+# CONFIG_DEFAULT_UIMAGE is not set
+CONFIG_PPC_DCR_NATIVE=y
+# CONFIG_PPC_DCR_MMIO is not set
+CONFIG_PPC_DCR=y
+CONFIG_DEFCONFIG_LIST="/lib/modules/$UNAME_RELEASE/.config"
+
+#
+# General setup
+#
+CONFIG_EXPERIMENTAL=y
+CONFIG_BROKEN_ON_SMP=y
+CONFIG_INIT_ENV_ARG_LIMIT=32
+CONFIG_LOCALVERSION=""
+CONFIG_LOCALVERSION_AUTO=y
+CONFIG_SWAP=y
+CONFIG_SYSVIPC=y
+CONFIG_SYSVIPC_SYSCTL=y
+CONFIG_POSIX_MQUEUE=y
+# CONFIG_BSD_PROCESS_ACCT is not set
+# CONFIG_TASKSTATS is not set
+# CONFIG_USER_NS is not set
+# CONFIG_AUDIT is not set
+# CONFIG_IKCONFIG is not set
+CONFIG_LOG_BUF_SHIFT=14
+CONFIG_SYSFS_DEPRECATED=y
+# CONFIG_RELAY is not set
+CONFIG_BLK_DEV_INITRD=y
+CONFIG_INITRAMFS_SOURCE=""
+# CONFIG_CC_OPTIMIZE_FOR_SIZE is not set
+CONFIG_SYSCTL=y
+CONFIG_EMBEDDED=y
+CONFIG_SYSCTL_SYSCALL=y
+CONFIG_KALLSYMS=y
+CONFIG_KALLSYMS_ALL=y
+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_MODULE_FORCE_UNLOAD is not set
+# CONFIG_MODVERSIONS is not set
+# CONFIG_MODULE_SRCVERSION_ALL is not set
+CONFIG_KMOD=y
+CONFIG_BLOCK=y
+CONFIG_LBD=y
+# CONFIG_BLK_DEV_IO_TRACE is not set
+# CONFIG_LSF is not set
+# CONFIG_BLK_DEV_BSG is not set
+
+#
+# IO Schedulers
+#
+CONFIG_IOSCHED_NOOP=y
+CONFIG_IOSCHED_AS=y
+CONFIG_IOSCHED_DEADLINE=y
+CONFIG_IOSCHED_CFQ=y
+CONFIG_DEFAULT_AS=y
+# CONFIG_DEFAULT_DEADLINE is not set
+# CONFIG_DEFAULT_CFQ is not set
+# CONFIG_DEFAULT_NOOP is not set
+CONFIG_DEFAULT_IOSCHED="anticipatory"
+
+#
+# Platform support
+#
+# CONFIG_PPC_MPC52xx is not set
+# CONFIG_PPC_MPC5200 is not set
+# CONFIG_PPC_CELL is not set
+# CONFIG_PPC_CELL_NATIVE is not set
+# CONFIG_PQ2ADS is not set
+CONFIG_WALNUT=y
+CONFIG_405GP=y
+CONFIG_IBM405_ERR77=y
+CONFIG_IBM405_ERR51=y
+# CONFIG_MPIC is not set
+# CONFIG_MPIC_WEIRD is not set
+# CONFIG_PPC_I8259 is not set
+# CONFIG_PPC_RTAS is not set
+# CONFIG_MMIO_NVRAM is not set
+# CONFIG_PPC_MPC106 is not set
+# CONFIG_PPC_970_NAP is not set
+# CONFIG_PPC_INDIRECT_IO is not set
+# CONFIG_GENERIC_IOMAP is not set
+# CONFIG_CPU_FREQ is not set
+# CONFIG_CPM2 is not set
+# CONFIG_FSL_ULI1575 is not set
+
+#
+# Kernel options
+#
+# CONFIG_HIGHMEM is not set
+# CONFIG_HZ_100 is not set
+CONFIG_HZ_250=y
+# CONFIG_HZ_300 is not set
+# CONFIG_HZ_1000 is not set
+CONFIG_HZ=250
+CONFIG_PREEMPT_NONE=y
+# CONFIG_PREEMPT_VOLUNTARY is not set
+# CONFIG_PREEMPT is not set
+CONFIG_BINFMT_ELF=y
+# CONFIG_BINFMT_MISC is not set
+# CONFIG_MATH_EMULATION is not set
+CONFIG_ARCH_ENABLE_MEMORY_HOTPLUG=y
+CONFIG_ARCH_FLATMEM_ENABLE=y
+CONFIG_ARCH_POPULATES_NODE_MAP=y
+CONFIG_SELECT_MEMORY_MODEL=y
+CONFIG_FLATMEM_MANUAL=y
+# CONFIG_DISCONTIGMEM_MANUAL is not set
+# CONFIG_SPARSEMEM_MANUAL 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=y
+CONFIG_ZONE_DMA_FLAG=1
+CONFIG_BOUNCE=y
+CONFIG_VIRT_TO_BUS=y
+CONFIG_PROC_DEVICETREE=y
+# CONFIG_CMDLINE_BOOL is not set
+# CONFIG_PM is not set
+CONFIG_SECCOMP=y
+CONFIG_WANT_DEVICE_TREE=y
+CONFIG_DEVICE_TREE="walnut.dts"
+CONFIG_ISA_DMA_API=y
+
+#
+# Bus options
+#
+CONFIG_ZONE_DMA=y
+# 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 is not set
+
+#
+# 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=y
+# CONFIG_PACKET_MMAP is not set
+CONFIG_UNIX=y
+# CONFIG_NET_KEY is not set
+CONFIG_INET=y
+# CONFIG_IP_MULTICAST is not set
+# CONFIG_IP_ADVANCED_ROUTER is not set
+CONFIG_IP_FIB_HASH=y
+CONFIG_IP_PNP=y
+CONFIG_IP_PNP_DHCP=y
+CONFIG_IP_PNP_BOOTP=y
+# CONFIG_IP_PNP_RARP is not set
+# CONFIG_NET_IPIP is not set
+# CONFIG_NET_IPGRE is not set
+# CONFIG_ARPD is not set
+# CONFIG_SYN_COOKIES is not set
+# CONFIG_INET_AH is not set
+# CONFIG_INET_ESP is not set
+# CONFIG_INET_IPCOMP is not set
+# CONFIG_INET_XFRM_TUNNEL is not set
+# CONFIG_INET_TUNNEL is not set
+# CONFIG_INET_XFRM_MODE_TRANSPORT is not set
+# CONFIG_INET_XFRM_MODE_TUNNEL is not set
+# CONFIG_INET_XFRM_MODE_BEET is not set
+CONFIG_INET_DIAG=y
+CONFIG_INET_TCP_DIAG=y
+# CONFIG_TCP_CONG_ADVANCED is not set
+CONFIG_TCP_CONG_CUBIC=y
+CONFIG_DEFAULT_TCP_CONG="cubic"
+# CONFIG_TCP_MD5SIG is not set
+# CONFIG_IPV6 is not set
+# CONFIG_INET6_XFRM_TUNNEL is not set
+# CONFIG_INET6_TUNNEL is not set
+# CONFIG_NETWORK_SECMARK is not set
+# CONFIG_NETFILTER is not set
+# CONFIG_IP_DCCP is not set
+# CONFIG_IP_SCTP is not set
+# CONFIG_TIPC is not set
+# CONFIG_ATM 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
+# CONFIG_X25 is not set
+# 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
+
+#
+# Network testing
+#
+# CONFIG_NET_PKTGEN is not set
+# CONFIG_HAMRADIO is not set
+# CONFIG_IRDA is not set
+# CONFIG_BT is not set
+# CONFIG_AF_RXRPC is not set
+
+#
+# Wireless
+#
+# CONFIG_CFG80211 is not set
+# CONFIG_WIRELESS_EXT is not set
+# CONFIG_MAC80211 is not set
+# CONFIG_IEEE80211 is not set
+# CONFIG_RFKILL is not set
+# CONFIG_NET_9P 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=y
+CONFIG_PROC_EVENTS=y
+# CONFIG_MTD is not set
+CONFIG_OF_DEVICE=y
+# 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 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=35000
+CONFIG_BLK_DEV_RAM_BLOCKSIZE=1024
+# CONFIG_CDROM_PKTCDVD is not set
+# CONFIG_ATA_OVER_ETH is not set
+# CONFIG_XILINX_SYSACE is not set
+CONFIG_MISC_DEVICES=y
+# CONFIG_EEPROM_93CX6 is not set
+# CONFIG_IDE is not set
+
+#
+# SCSI device support
+#
+# CONFIG_RAID_ATTRS is not set
+# CONFIG_SCSI is not set
+# CONFIG_SCSI_DMA is not set
+# CONFIG_SCSI_NETLINK is not set
+# CONFIG_ATA is not set
+# CONFIG_MD is not set
+# CONFIG_MACINTOSH_DRIVERS is not set
+CONFIG_NETDEVICES=y
+# CONFIG_NETDEVICES_MULTIQUEUE is not set
+# CONFIG_DUMMY is not set
+# CONFIG_BONDING is not set
+# CONFIG_MACVLAN is not set
+# CONFIG_EQUALIZER is not set
+# CONFIG_TUN is not set
+# CONFIG_NET_ETHERNET is not set
+CONFIG_NETDEV_1000=y
+CONFIG_NETDEV_10000=y
+
+#
+# Wireless LAN
+#
+# CONFIG_WLAN_PRE80211 is not set
+# CONFIG_WLAN_80211 is not set
+# CONFIG_WAN is not set
+# CONFIG_PPP is not set
+# CONFIG_SLIP is not set
+# CONFIG_SHAPER is not set
+# CONFIG_NETCONSOLE is not set
+# CONFIG_NETPOLL is not set
+# CONFIG_NET_POLL_CONTROLLER is not set
+# CONFIG_ISDN is not set
+# CONFIG_PHONE is not set
+
+#
+# Input device support
+#
+# CONFIG_INPUT is not set
+
+#
+# Hardware I/O ports
+#
+# CONFIG_SERIO is not set
+# CONFIG_GAMEPORT is not set
+
+#
+# Character devices
+#
+# CONFIG_VT is not set
+# CONFIG_SERIAL_NONSTANDARD is not set
+
+#
+# Serial drivers
+#
+CONFIG_SERIAL_8250=y
+CONFIG_SERIAL_8250_CONSOLE=y
+CONFIG_SERIAL_8250_NR_UARTS=4
+CONFIG_SERIAL_8250_RUNTIME_UARTS=4
+CONFIG_SERIAL_8250_EXTENDED=y
+# CONFIG_SERIAL_8250_MANY_PORTS is not set
+CONFIG_SERIAL_8250_SHARE_IRQ=y
+# CONFIG_SERIAL_8250_DETECT_IRQ is not set
+# CONFIG_SERIAL_8250_RSA is not set
+
+#
+# Non-8250 serial port support
+#
+# CONFIG_SERIAL_UARTLITE is not set
+CONFIG_SERIAL_CORE=y
+CONFIG_SERIAL_CORE_CONSOLE=y
+CONFIG_SERIAL_OF_PLATFORM=y
+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
+# CONFIG_R3964 is not set
+# CONFIG_RAW_DRIVER is not set
+# CONFIG_TCG_TPM 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 is not set
+# CONFIG_DVB_CORE is not set
+# CONFIG_DAB is not set
+
+#
+# Graphics support
+#
+# CONFIG_BACKLIGHT_LCD_SUPPORT is not set
+
+#
+# Display device support
+#
+# CONFIG_DISPLAY_SUPPORT is not set
+# CONFIG_VGASTATE is not set
+CONFIG_VIDEO_OUTPUT_CONTROL=m
+# CONFIG_FB is not set
+# CONFIG_FB_IBM_GXT4500 is not set
+
+#
+# Sound
+#
+# CONFIG_SOUND is not set
+CONFIG_USB_SUPPORT=y
+# CONFIG_USB_ARCH_HAS_HCD is not set
+# CONFIG_USB_ARCH_HAS_OHCI is not set
+# CONFIG_USB_ARCH_HAS_EHCI is not set
+
+#
+# NOTE: USB_STORAGE enables SCSI, and 'SCSI disk support'
+#
+
+#
+# USB Gadget Support
+#
+# CONFIG_USB_GADGET is not set
+# CONFIG_MMC is not set
+# CONFIG_NEW_LEDS is not set
+# CONFIG_EDAC 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=y
+# CONFIG_EXT2_FS_XATTR is not set
+# CONFIG_EXT2_FS_XIP is not set
+# CONFIG_EXT3_FS is not set
+# CONFIG_EXT4DEV_FS is not set
+# CONFIG_REISERFS_FS is not set
+# CONFIG_JFS_FS is not set
+# CONFIG_FS_POSIX_ACL is not set
+# CONFIG_XFS_FS is not set
+# CONFIG_GFS2_FS is not set
+# CONFIG_OCFS2_FS is not set
+# CONFIG_MINIX_FS is not set
+# CONFIG_ROMFS_FS is not set
+CONFIG_INOTIFY=y
+CONFIG_INOTIFY_USER=y
+# 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
+
+#
+# CD-ROM/DVD Filesystems
+#
+# CONFIG_ISO9660_FS is not set
+# CONFIG_UDF_FS is not set
+
+#
+# DOS/FAT/NT Filesystems
+#
+# CONFIG_MSDOS_FS is not set
+# CONFIG_VFAT_FS is not set
+# 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 is not set
+# CONFIG_HUGETLB_PAGE is not set
+CONFIG_RAMFS=y
+# CONFIG_CONFIGFS_FS is not set
+
+#
+# Miscellaneous filesystems
+#
+# CONFIG_ADFS_FS is not set
+# CONFIG_AFFS_FS is not set
+# CONFIG_HFS_FS is not set
+# CONFIG_HFSPLUS_FS is not set
+# CONFIG_BEFS_FS is not set
+# CONFIG_BFS_FS is not set
+# CONFIG_EFS_FS is not set
+CONFIG_CRAMFS=y
+# 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
+#
+CONFIG_NFS_FS=y
+CONFIG_NFS_V3=y
+# CONFIG_NFS_V3_ACL is not set
+# CONFIG_NFS_V4 is not set
+# CONFIG_NFS_DIRECTIO is not set
+# CONFIG_NFSD is not set
+CONFIG_ROOT_NFS=y
+CONFIG_LOCKD=y
+CONFIG_LOCKD_V4=y
+CONFIG_NFS_COMMON=y
+CONFIG_SUNRPC=y
+# CONFIG_SUNRPC_BIND34 is not set
+# 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
+# CONFIG_NCP_FS is not set
+# CONFIG_CODA_FS is not set
+# CONFIG_AFS_FS is not set
+
+#
+# Partition Types
+#
+# CONFIG_PARTITION_ADVANCED is not set
+CONFIG_MSDOS_PARTITION=y
+
+#
+# Native Language Support
+#
+# CONFIG_NLS is not set
+
+#
+# Distributed Lock Manager
+#
+# CONFIG_DLM is not set
+# CONFIG_UCC_SLOW is not set
+
+#
+# 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 is not set
+CONFIG_ZLIB_INFLATE=y
+CONFIG_PLIST=y
+CONFIG_HAS_IOMEM=y
+CONFIG_HAS_IOPORT=y
+CONFIG_HAS_DMA=y
+
+#
+# Instrumentation Support
+#
+# CONFIG_PROFILING is not set
+
+#
+# Kernel hacking
+#
+# CONFIG_PRINTK_TIME is not set
+CONFIG_ENABLE_MUST_CHECK=y
+CONFIG_MAGIC_SYSRQ=y
+# 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=y
+CONFIG_SCHED_DEBUG=y
+# 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 is not set
+# CONFIG_DEBUG_VM is not set
+# CONFIG_DEBUG_LIST is not set
+CONFIG_FORCED_INLINING=y
+# CONFIG_RCU_TORTURE_TEST is not set
+# CONFIG_FAULT_INJECTION is not set
+# CONFIG_DEBUG_STACKOVERFLOW is not set
+# CONFIG_DEBUG_STACK_USAGE is not set
+# CONFIG_DEBUG_PAGEALLOC is not set
+# CONFIG_DEBUGGER is not set
+# CONFIG_BDI_SWITCH is not set
+# CONFIG_PPC_EARLY_DEBUG is not set
+
+#
+# Security options
+#
+# CONFIG_KEYS is not set
+# CONFIG_SECURITY is not set
+CONFIG_CRYPTO=y
+CONFIG_CRYPTO_ALGAPI=y
+CONFIG_CRYPTO_BLKCIPHER=y
+CONFIG_CRYPTO_MANAGER=y
+# CONFIG_CRYPTO_HMAC is not set
+# CONFIG_CRYPTO_XCBC is not set
+# CONFIG_CRYPTO_NULL is not set
+# CONFIG_CRYPTO_MD4 is not set
+CONFIG_CRYPTO_MD5=y
+# CONFIG_CRYPTO_SHA1 is not set
+# CONFIG_CRYPTO_SHA256 is not set
+# CONFIG_CRYPTO_SHA512 is not set
+# CONFIG_CRYPTO_WP512 is not set
+# CONFIG_CRYPTO_TGR192 is not set
+# CONFIG_CRYPTO_GF128MUL is not set
+CONFIG_CRYPTO_ECB=y
+CONFIG_CRYPTO_CBC=y
+CONFIG_CRYPTO_PCBC=y
+# CONFIG_CRYPTO_LRW is not set
+# CONFIG_CRYPTO_CRYPTD is not set
+CONFIG_CRYPTO_DES=y
+# CONFIG_CRYPTO_FCRYPT is not set
+# CONFIG_CRYPTO_BLOWFISH is not set
+# CONFIG_CRYPTO_TWOFISH is not set
+# CONFIG_CRYPTO_SERPENT is not set
+# CONFIG_CRYPTO_AES is not set
+# CONFIG_CRYPTO_CAST5 is not set
+# CONFIG_CRYPTO_CAST6 is not set
+# CONFIG_CRYPTO_TEA is not set
+# CONFIG_CRYPTO_ARC4 is not set
+# CONFIG_CRYPTO_KHAZAD is not set
+# CONFIG_CRYPTO_ANUBIS is not set
+# CONFIG_CRYPTO_DEFLATE is not set
+# 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_HW=y
--
^ permalink raw reply
* [patch 6/6] Walnut zImage wrapper
From: Josh Boyer @ 2007-08-31 20:04 UTC (permalink / raw)
To: linuxppc-dev
In-Reply-To: <20070831200449.598781000@linux.vnet.ibm.com>
Add zImage wrapper for walnut board
Signed-off-by: Josh Boyer <jwboyer@linux.vnet.ibm.com>
---
arch/powerpc/boot/Makefile | 3
arch/powerpc/boot/treeboot-walnut.c | 133 ++++++++++++++++++++++++++++++++++++
2 files changed, 135 insertions(+), 1 deletion(-)
--- linux-2.6.orig/arch/powerpc/boot/Makefile
+++ linux-2.6/arch/powerpc/boot/Makefile
@@ -49,7 +49,7 @@ src-wlib := string.S crt0.S stdio.c main
src-plat := of.c cuboot-83xx.c cuboot-85xx.c holly.c \
cuboot-ebony.c treeboot-ebony.c prpmc2800.c \
ps3-head.S ps3-hvcall.S ps3.c treeboot-bamboo.c cuboot-8xx.c \
- cuboot-pq2.c cuboot-bamboo.c
+ cuboot-pq2.c cuboot-bamboo.c treeboot-walnut.c
src-boot := $(src-wlib) $(src-plat) empty.c
src-boot := $(addprefix $(obj)/, $(src-boot))
@@ -147,6 +147,7 @@ image-$(CONFIG_PPC_83xx) += cuImage.83x
image-$(CONFIG_PPC_85xx) += cuImage.85xx
image-$(CONFIG_EBONY) += treeImage.ebony cuImage.ebony
image-$(CONFIG_BAMBOO) += treeImage.bamboo cuImage.bamboo
+image-$(CONFIG_WALNUT) += treeImage.walnut
endif
# For 32-bit powermacs, build the COFF and miboot images
--- /dev/null
+++ linux-2.6/arch/powerpc/boot/treeboot-walnut.c
@@ -0,0 +1,133 @@
+/*
+ * Old U-boot compatibility for Walnut
+ *
+ * Author: Josh Boyer <jwboyer@linux.vnet.ibm.com>
+ *
+ * Copyright 2007 IBM Corporation
+ * Based on cuboot-83xx.c, which is:
+ * Copyright (c) 2007 Freescale Semiconductor, Inc.
+ *
+ * This program is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 as published
+ * by the Free Software Foundation.
+ */
+
+#include "ops.h"
+#include "stdio.h"
+#include "dcr.h"
+#include "4xx.h"
+#include "io.h"
+
+BSS_STACK(4096);
+
+void ibm405gp_fixup_clocks(unsigned int sysclk, unsigned int ser_clk)
+{
+ u32 pllmr = mfdcr(0xb0);
+ u32 cpc0_cr0 = mfdcr(0xb1);
+ u32 cpc0_cr1 = mfdcr(0xb2);
+ u32 cpu, plb, opb, ebc, tb, uart0, uart1, m;
+ u32 fwdv, fbdv, cbdv, opdv, epdv, udiv;
+
+ fwdv = (8 - ((pllmr & 0xe0000000) >> 29));
+ fbdv = (pllmr & 0x1e000000) >> 25;
+ cbdv = ((pllmr & 0x00060000) >> 17) + 1;
+ opdv = ((pllmr & 0x00018000) >> 15) + 1;
+ epdv = ((pllmr & 0x00001800) >> 13) + 2;
+ udiv = ((cpc0_cr0 & 0x3e) >> 1) + 1;
+
+ m = fwdv * fbdv * cbdv;
+
+ cpu = sysclk * m / fwdv;
+ plb = cpu / cbdv;
+ opb = plb / opdv;
+ ebc = plb / epdv;
+
+ if (cpc0_cr0 & 0x80) {
+ /* uart0 uses the external clock */
+ uart0 = ser_clk;
+ } else {
+ uart0 = cpu / udiv;
+ }
+
+ if (cpc0_cr0 & 0x40) {
+ /* uart1 uses the external clock */
+ uart1 = ser_clk;
+ } else {
+ uart1 = cpu / udiv;
+ }
+
+ /* setup the timebase clock to tick at the cpu frequency */
+ cpc0_cr1 = cpc0_cr1 & ~ 0x00800000;
+ mtdcr(0xb2, cpc0_cr1);
+ tb = cpu;
+
+ dt_fixup_cpu_clocks(cpu, tb, 0);
+ dt_fixup_clock("/plb", plb);
+ dt_fixup_clock("/plb/opb", opb);
+ dt_fixup_clock("/plb/ebc", ebc);
+ dt_fixup_clock("/plb/opb/serial@300", uart0);
+ dt_fixup_clock("/plb/opb/serial@400", uart1);
+}
+
+static void walnut_flashsel_fixup(void)
+{
+ void *devp, *sram;
+ u32 reg_flash[3] = {0x0, 0x0, 0x80000};
+ u32 reg_sram[3] = {0x0, 0x0, 0x80000};
+ u8 *fpga;
+ u8 fpga_brds1 = 0x0;
+
+ devp = finddevice("/plb/ebc/fpga");
+ if (!devp)
+ fatal("Couldn't locate FPGA node\n\r");
+
+ if (getprop(devp, "virtual-reg", &fpga, sizeof(fpga)) != sizeof(fpga))
+ fatal("no virtual-reg property\n\r");
+
+ fpga_brds1 = in_8(fpga);
+
+ printf("FPGA_BRDS1: %08x\n", fpga_brds1);
+
+ devp = finddevice("/plb/ebc/flash");
+ if (!devp)
+ fatal("Couldn't locate flash node\n\r");
+
+ if (getprop(devp, "reg", reg_flash, sizeof(reg_flash)) != sizeof(reg_flash))
+ fatal("flash reg property has unexpected size\n\r");
+
+ sram = finddevice("/plb/ebc/sram");
+ if (!sram)
+ fatal("Couldn't locate sram node\n\r");
+
+ if (getprop(sram, "reg", reg_sram, sizeof(reg_sram)) != sizeof(reg_sram))
+ fatal("sram reg property has unexpected size\n\r");
+
+ if (fpga_brds1 & 0x1) {
+ reg_flash[1] ^= 0x80000;
+ reg_sram[1] ^= 0x80000;
+ }
+
+ setprop(devp, "reg", reg_flash, sizeof(reg_flash));
+ setprop(sram, "reg", reg_sram, sizeof(reg_sram));
+}
+
+static void walnut_fixups(void)
+{
+ ibm4xx_fixup_memsize();
+ ibm405gp_fixup_clocks(33330000, 0xa8c000);
+ ibm4xx_quiesce_eth((u32 *)0xef600800, NULL);
+ ibm4xx_fixup_ebc_ranges("/plb/ebc");
+ walnut_flashsel_fixup();
+}
+
+void platform_init(void)
+{
+ unsigned long end_of_ram = 0x2000000;
+ unsigned long avail_ram = end_of_ram - (unsigned long) _end;
+
+ simple_alloc_init(_end, avail_ram, 32, 32);
+ platform_ops.fixups = walnut_fixups;
+ platform_ops.exit = ibm40x_dbcr_reset;
+ ft_init(_dtb_start, _dtb_end - _dtb_start, 32);
+ serial_console_init();
+}
--
^ permalink raw reply
* [patch 5/6] Walnut board support
From: Josh Boyer @ 2007-08-31 20:04 UTC (permalink / raw)
To: linuxppc-dev
In-Reply-To: <20070831200449.598781000@linux.vnet.ibm.com>
Board support for the PPC405 Walnut evaluation board
Signed-off-by: Josh Boyer <jwboyer@linux.vnet.ibm.com>
---
arch/powerpc/platforms/40x/Kconfig | 14 +++----
arch/powerpc/platforms/40x/Makefile | 2 -
arch/powerpc/platforms/40x/walnut.c | 68 ++++++++++++++++++++++++++++++++++++
arch/powerpc/platforms/Kconfig | 2 -
arch/powerpc/platforms/Makefile | 2 -
5 files changed, 78 insertions(+), 10 deletions(-)
--- linux-2.6.orig/arch/powerpc/platforms/40x/Makefile
+++ linux-2.6/arch/powerpc/platforms/40x/Makefile
@@ -1 +1 @@
-# empty makefile so make clean works
\ No newline at end of file
+obj-$(CONFIG_WALNUT) += walnut.o
--- /dev/null
+++ linux-2.6/arch/powerpc/platforms/40x/walnut.c
@@ -0,0 +1,68 @@
+/*
+ * Architecture- / platform-specific boot-time initialization code for
+ * IBM PowerPC 4xx based boards. Adapted from original
+ * code by Gary Thomas, Cort Dougan <cort@fsmlabs.com>, and Dan Malek
+ * <dan@net4x.com>.
+ *
+ * Copyright(c) 1999-2000 Grant Erickson <grant@lcse.umn.edu>
+ *
+ * Rewritten and ported to the merged powerpc tree:
+ * Copyright 2007 IBM Corporation
+ * Josh Boyer <jwboyer@linux.vnet.ibm.com>
+ *
+ * 2002 (c) MontaVista, Software, Inc. This file is licensed under
+ * the terms of the GNU General Public License version 2. This program
+ * is licensed "as is" without any warranty of any kind, whether express
+ * or implied.
+ */
+
+#include <linux/init.h>
+#include <asm/machdep.h>
+#include <asm/prom.h>
+#include <asm/udbg.h>
+#include <asm/time.h>
+#include <asm/uic.h>
+#include <asm/of_platform.h>
+
+static struct of_device_id walnut_of_bus[] = {
+ { .compatible = "ibm,plb3", },
+ { .compatible = "ibm,opb", },
+ { .compatible = "ibm,ebc", },
+ {},
+};
+
+static int __init walnut_device_probe(void)
+{
+ if (!machine_is(walnut))
+ return 0;
+
+ /* FIXME: do bus probe here */
+ of_platform_bus_probe(NULL, walnut_of_bus, NULL);
+
+ return 0;
+}
+device_initcall(walnut_device_probe);
+
+static int __init walnut_probe(void)
+{
+ unsigned long root = of_get_flat_dt_root();
+
+ if (!of_flat_dt_is_compatible(root, "ibm,walnut"))
+ return 0;
+
+ return 1;
+}
+
+static void __init walnut_setup_arch(void)
+{
+}
+
+define_machine(walnut) {
+ .name = "Walnut",
+ .probe = walnut_probe,
+ .setup_arch = walnut_setup_arch,
+ .progress = udbg_progress,
+ .init_IRQ = uic_init_tree,
+ .get_irq = uic_get_irq,
+ .calibrate_decr = generic_calibrate_decr,
+};
--- linux-2.6.orig/arch/powerpc/platforms/40x/Kconfig
+++ linux-2.6/arch/powerpc/platforms/40x/Kconfig
@@ -53,13 +53,13 @@
# help
# This option enables support for the IBM PPC405GPr evaluation board.
-#config WALNUT
-# bool "Walnut"
-# depends on 40x
-# default y
-# select 405GP
-# help
-# This option enables support for the IBM PPC405GP evaluation board.
+config WALNUT
+ bool "Walnut"
+ depends on 40x
+ default y
+ select 405GP
+ help
+ This option enables support for the IBM PPC405GP evaluation board.
#config XILINX_ML300
# bool "Xilinx-ML300"
--- linux-2.6.orig/arch/powerpc/platforms/Kconfig
+++ linux-2.6/arch/powerpc/platforms/Kconfig
@@ -59,7 +59,7 @@ source "arch/powerpc/platforms/85xx/Kcon
source "arch/powerpc/platforms/86xx/Kconfig"
source "arch/powerpc/platforms/embedded6xx/Kconfig"
source "arch/powerpc/platforms/44x/Kconfig"
-#source "arch/powerpc/platforms/4xx/Kconfig
+source "arch/powerpc/platforms/40x/Kconfig"
config PPC_NATIVE
bool
--- linux-2.6.orig/arch/powerpc/platforms/Makefile
+++ linux-2.6/arch/powerpc/platforms/Makefile
@@ -9,7 +9,7 @@ obj-$(CONFIG_PPC_PMAC) += powermac/
endif
endif
obj-$(CONFIG_PPC_CHRP) += chrp/
-#obj-$(CONFIG_4xx) += 4xx/
+obj-$(CONFIG_40x) += 40x/
obj-$(CONFIG_44x) += 44x/
obj-$(CONFIG_PPC_MPC52xx) += 52xx/
obj-$(CONFIG_PPC_8xx) += 8xx/
--
^ permalink raw reply
* [patch 0/6] Current 4xx patch queue
From: Josh Boyer @ 2007-08-31 20:04 UTC (permalink / raw)
To: linuxppc-dev
Hi All,
Below is my latest patch queue for 4xx. There are a couple Bamboo updates,
and the next round of PPC 405 Walnut support.
josh
--
^ permalink raw reply
* [patch 2/6] cuimage for Bamboo board
From: Josh Boyer @ 2007-08-31 20:04 UTC (permalink / raw)
To: linuxppc-dev
In-Reply-To: <20070831200449.598781000@linux.vnet.ibm.com>
Add a cuboot wrapper for the Bamboo board. This also removes some obsoleted
linker declarations that have been moved into ops.h
Signed-off-by: Josh Boyer <jwboyer@linux.vnet.ibm.com>
---
arch/powerpc/boot/44x.h | 2 +-
arch/powerpc/boot/Makefile | 5 +++--
arch/powerpc/boot/bamboo.c | 9 ++++++---
arch/powerpc/boot/cuboot-bamboo.c | 30 ++++++++++++++++++++++++++++++
arch/powerpc/boot/treeboot-bamboo.c | 4 +---
5 files changed, 41 insertions(+), 9 deletions(-)
--- linux-2.6.orig/arch/powerpc/boot/Makefile
+++ linux-2.6/arch/powerpc/boot/Makefile
@@ -48,7 +48,8 @@ src-wlib := string.S crt0.S stdio.c main
cpm-serial.c
src-plat := of.c cuboot-83xx.c cuboot-85xx.c holly.c \
cuboot-ebony.c treeboot-ebony.c prpmc2800.c \
- ps3-head.S ps3-hvcall.S ps3.c treeboot-bamboo.c cuboot-8xx.c cuboot-pq2.c
+ ps3-head.S ps3-hvcall.S ps3.c treeboot-bamboo.c cuboot-8xx.c \
+ cuboot-pq2.c cuboot-bamboo.c
src-boot := $(src-wlib) $(src-plat) empty.c
src-boot := $(addprefix $(obj)/, $(src-boot))
@@ -145,7 +146,7 @@ image-$(CONFIG_8260) += cuImage.pq2
image-$(CONFIG_PPC_83xx) += cuImage.83xx
image-$(CONFIG_PPC_85xx) += cuImage.85xx
image-$(CONFIG_EBONY) += treeImage.ebony cuImage.ebony
-image-$(CONFIG_BAMBOO) += treeImage.bamboo
+image-$(CONFIG_BAMBOO) += treeImage.bamboo cuImage.bamboo
endif
# For 32-bit powermacs, build the COFF and miboot images
--- /dev/null
+++ linux-2.6/arch/powerpc/boot/cuboot-bamboo.c
@@ -0,0 +1,30 @@
+/*
+ * Old U-boot compatibility for Ebony
+ *
+ * Author: Josh Boyer <jwboyer@linux.vnet.ibm.com>
+ *
+ * Copyright 2007 IBM Corporation
+ *
+ * Based on cuboot-ebony.c
+ *
+ * This program is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 as published
+ * by the Free Software Foundation.
+ */
+
+#include "ops.h"
+#include "stdio.h"
+#include "44x.h"
+#include "cuboot.h"
+
+#define TARGET_44x
+#include "ppcboot.h"
+
+static bd_t bd;
+
+void platform_init(unsigned long r3, unsigned long r4, unsigned long r5,
+ unsigned long r6, unsigned long r7)
+{
+ CUBOOT_INIT();
+ bamboo_init(&bd.bi_enetaddr, &bd.bi_enet1addr);
+}
--- linux-2.6.orig/arch/powerpc/boot/44x.h
+++ linux-2.6/arch/powerpc/boot/44x.h
@@ -11,6 +11,6 @@
#define _PPC_BOOT_44X_H_
void ebony_init(void *mac0, void *mac1);
-void bamboo_init(void);
+void bamboo_init(void *mac0, void *mac1);
#endif /* _PPC_BOOT_44X_H_ */
--- linux-2.6.orig/arch/powerpc/boot/bamboo.c
+++ linux-2.6/arch/powerpc/boot/bamboo.c
@@ -24,8 +24,7 @@
#include "4xx.h"
#include "44x.h"
-extern char _dtb_start[];
-extern char _dtb_end[];
+static u8 *bamboo_mac0, *bamboo_mac1;
static void bamboo_fixups(void)
{
@@ -34,12 +33,16 @@ static void bamboo_fixups(void)
ibm440ep_fixup_clocks(sysclk, 11059200);
ibm4xx_fixup_memsize();
ibm4xx_quiesce_eth((u32 *)0xef600e00, (u32 *)0xef600f00);
+ if (bamboo_mac0 && bamboo_mac1)
+ dt_fixup_mac_addresses(bamboo_mac0, bamboo_mac1);
}
-void bamboo_init(void)
+void bamboo_init(void *mac0, void *mac1)
{
platform_ops.fixups = bamboo_fixups;
platform_ops.exit = ibm44x_dbcr_reset;
+ bamboo_mac0 = mac0;
+ bamboo_mac1 = mac1;
ft_init(_dtb_start, 0, 32);
serial_console_init();
}
--- linux-2.6.orig/arch/powerpc/boot/treeboot-bamboo.c
+++ linux-2.6/arch/powerpc/boot/treeboot-bamboo.c
@@ -13,8 +13,6 @@
#include "stdio.h"
#include "44x.h"
-extern char _end[];
-
BSS_STACK(4096);
void platform_init(void)
@@ -23,5 +21,5 @@ void platform_init(void)
unsigned long avail_ram = end_of_ram - (unsigned long)_end;
simple_alloc_init(_end, avail_ram, 32, 64);
- bamboo_init();
+ bamboo_init(NULL, NULL);
}
--
^ permalink raw reply
* [patch 3/6] Walnut DTS
From: Josh Boyer @ 2007-08-31 20:04 UTC (permalink / raw)
To: linuxppc-dev
In-Reply-To: <20070831200449.598781000@linux.vnet.ibm.com>
Device tree source file for the PPC405 Walnut evaluation board.
Signed-off-by: Josh Boyer <jwboyer@linux.vnet.ibm.com>
---
arch/powerpc/boot/dts/walnut.dts | 183 +++++++++++++++++++++++++++++++++++++++
1 file changed, 183 insertions(+)
--- /dev/null
+++ linux-2.6/arch/powerpc/boot/dts/walnut.dts
@@ -0,0 +1,183 @@
+/*
+ * Device Tree Source for IBM Walnut
+ *
+ * Copyright 2007 IBM Corp.
+ * Josh Boyer <jwboyer@linux.vnet.ibm.com>
+ *
+ * This file is licensed under the terms of the GNU General Public
+ * License version 2. This program is licensed "as is" without
+ * any warranty of any kind, whether express or implied.
+ */
+
+/ {
+ #address-cells = <1>;
+ #size-cells = <1>;
+ model = "ibm,walnut";
+ compatible = "ibm,walnut";
+ dcr-parent = <&/cpus/PowerPC,405GP@0>;
+
+ cpus {
+ #address-cells = <1>;
+ #size-cells = <0>;
+
+ PowerPC,405GP@0 {
+ device_type = "cpu";
+ reg = <0>;
+ clock-frequency = <bebc200>; /* Filled in by zImage */
+ timebase-frequency = <0>; /* Filled in by zImage */
+ i-cache-line-size = <20>;
+ d-cache-line-size = <20>;
+ i-cache-size = <4000>;
+ d-cache-size = <4000>;
+ dcr-controller;
+ dcr-access-method = "native";
+ };
+ };
+
+ memory {
+ device_type = "memory";
+ reg = <0 0>; /* Filled in by zImage */
+ };
+
+ UIC0: interrupt-controller {
+ compatible = "ibm,uic";
+ interrupt-controller;
+ cell-index = <0>;
+ dcr-reg = <0c0 9>;
+ #address-cells = <0>;
+ #size-cells = <0>;
+ #interrupt-cells = <2>;
+ };
+
+ plb {
+ compatible = "ibm,plb3";
+ #address-cells = <1>;
+ #size-cells = <1>;
+ ranges;
+ clock-frequency = <0>; /* Filled in by zImage */
+
+ SDRAM0: memory-controller {
+ compatible = "ibm,sdram-405gp";
+ dcr-reg = <010 2>;
+ };
+
+ MAL: mcmal {
+ compatible = "ibm,mcmal-405gp", "ibm,mcmal";
+ dcr-reg = <180 62>;
+ num-tx-chans = <2>;
+ num-rx-chans = <1>;
+ interrupt-parent = <&UIC0>;
+ interrupts = <a 4 b 4 c 4 d 4 e 4>;
+ };
+
+ POB0: opb {
+ compatible = "ibm,opb";
+ #address-cells = <1>;
+ #size-cells = <1>;
+ ranges = <0 ef600000 a00000>;
+ dcr-reg = <0a0 5>;
+ clock-frequency = <0>; /* Filled in by zImage */
+
+ UART0: serial@300 {
+ device_type = "serial";
+ compatible = "ns16550";
+ reg = <300 8>;
+ virtual-reg = <ef600300>;
+ clock-frequency = <0>; /* Filled in by zImage */
+ current-speed = <2580>;
+ interrupt-parent = <&UIC0>;
+ interrupts = <0 4>;
+ };
+
+ UART1: serial@400 {
+ device_type = "serial";
+ compatible = "ns16550";
+ reg = <400 8>;
+ virtual-reg = <ef600400>;
+ clock-frequency = <0>; /* Filled in by zImage */
+ current-speed = <2580>;
+ interrupt-parent = <&UIC0>;
+ interrupts = <1 4>;
+ };
+
+ IIC: i2c@500 {
+ compatible = "ibm,iic-405gp", "ibm,iic";
+ reg = <500 11>;
+ interrupt-parent = <&UIC0>;
+ interrupts = <2 4>;
+ };
+
+ GPIO: gpio@700 {
+ compatible = "ibm,gpio-405gp";
+ reg = <700 20>;
+ };
+
+ EMAC: ethernet@800 {
+ linux,network-index = <0>;
+ device_type = "network";
+ compatible = "ibm,emac-405gp", "ibm,emac";
+ interrupt-parent = <&UIC0>;
+ interrupts = <9 4 f 4>;
+ reg = <800 70>;
+ mal-device = <&MAL>;
+ mal-tx-channel = <0 1>;
+ mal-rx-channel = <0>;
+ cell-index = <0>;
+ max-frame-size = <5dc>;
+ rx-fifo-size = <1000>;
+ tx-fifo-size = <800>;
+ phy-mode = "rmii";
+ phy-map = <00000001>;
+ };
+
+ };
+
+ EBC0: ebc {
+ compatible = "ibm,ebc-405gp", "ibm,ebc";
+ dcr-reg = <012 2>;
+ #address-cells = <2>;
+ #size-cells = <1>;
+ clock-frequency = <0>; /* Filled in by zImage */
+
+ sram@0,0 {
+ reg = <0 0 80000>;
+ };
+
+ flash@0,80000 {
+ device_type = "rom";
+ compatible = "direct-mapped";
+ probe-type = "JEDEC";
+ bank-width = <1>;
+ partitions = <0 80000>;
+ partition-names = "OpenBIOS";
+ reg = <0 80000 80000>;
+ };
+
+ ds1743@1,0 {
+ /* NVRAM and RTC */
+ compatible = "ds1743";
+ reg = <1 0 2000>;
+ };
+
+ keyboard@2,0 {
+ compatible = "intel,82C42PC";
+ reg = <2 0 2>;
+ };
+
+ ir@3,0 {
+ compatible = "ti,TIR2000PAG";
+ reg = <3 0 10>;
+ };
+
+ fpga@7,0 {
+ compatible = "Walnut-FPGA";
+ reg = <7 0 10>;
+ virtual-reg = <f0300005>;
+ };
+ };
+ };
+
+ chosen {
+ linux,stdout-path = "/plb/opb/serial@300";
+ };
+};
--
^ permalink raw reply
* [patch 1/6] Fix bus probe on Bamboo board
From: Josh Boyer @ 2007-08-31 20:04 UTC (permalink / raw)
To: linuxppc-dev
In-Reply-To: <20070831200449.598781000@linux.vnet.ibm.com>
Commit 804ace8881d21 changed the behavior of how compatible nodes are found.
This highlighted a bug on the Bamboo board where it wasn't probing the bus
specified in the DTS file. We fix it by being explicit about which bus to
probe.
Signed-off-by: Josh Boyer <jwboyer@linux.vnet.ibm.com>
---
arch/powerpc/platforms/44x/bamboo.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
--- linux-2.6.orig/arch/powerpc/platforms/44x/bamboo.c
+++ linux-2.6/arch/powerpc/platforms/44x/bamboo.c
@@ -23,7 +23,7 @@
#include "44x.h"
static struct of_device_id bamboo_of_bus[] = {
- { .compatible = "ibm,plb", },
+ { .compatible = "ibm,plb4", },
{ .compatible = "ibm,opb", },
{ .compatible = "ibm,ebc", },
{},
--
^ permalink raw reply
* Re: [PATCH 3/9] 8xx: Add pin and clock setting functions.
From: Scott Wood @ 2007-08-31 20:44 UTC (permalink / raw)
To: Vitaly Bordug; +Cc: linuxppc-dev
In-Reply-To: <20070830013833.4c4d5d0b@localhost.localdomain>
On Thu, Aug 30, 2007 at 01:38:33AM +0400, Vitaly Bordug wrote:
> On Tue, 28 Aug 2007 15:17:19 -0500
> Scott Wood wrote:
> > +struct cpm_ioport16 {
> > + __be16 dir, par, sor, dat, intr;
> > + __be16 res[3];
> > +};
> > +
> Hmm. If we are using such a non-standard types, it worths at least
> explanation why...
It's so I can index into the port array. The standard struct has
non-indexable names such as "padir", "pcpar", etc.
> > +struct cpm_ioport32 {
> > + __be32 dir, par, sor;
> > +};
> > +
> > +static void cpm1_set_pin32(int port, int pin, int flags)
> > +{
> > + struct cpm_ioport32 __iomem *iop;
> > + pin = 1 << (31 - pin);
> > +
> > + if (port == 1)
> Probably put here define or alike so that we wouldn't have confusion what 1/whatever port number does mean.
> Or some comment explaining for PQ newcomer what's going on here. ditto below.
I suppose I could add CPM_PORTA, CPM_PORTB, etc. defines.
> > +int cpm1_clk_setup(enum cpm_clk_target target, int clock, int mode)
> > +{
> > + int shift;
> > + int i, bits = 0;
> > + u32 __iomem *reg;
> > + u32 mask = 7;
> > +
> gotta at least briefly explain the clue here, too.
I'm not sure what you mean... what exactly are you asking me to explain?
Note that this code is mostly duplicated from the existing CPM2 version.
> We're adding helper functions and should be ready that something
> somewhere won't work as expected.
Could you elaborate on what you expect to possibly not work, or what we
should do to "be ready"?
> > diff --git a/include/asm-powerpc/commproc.h
> > b/include/asm-powerpc/commproc.h index ccb32cd..a95a434 100644
> > --- a/include/asm-powerpc/commproc.h
> > +++ b/include/asm-powerpc/commproc.h
> > @@ -692,4 +692,45 @@ extern void cpm_free_handler(int vec);
> > #define IMAP_ADDR (get_immrbase())
> > #define IMAP_SIZE ((uint)(64 * 1024))
> >
> Pull from the dts?
It is. I kept IMAP_ADDR around to ease interdependencies on changes in
drivers/net/fs_enet. It appears IMAP_SIZE isn't used.
-Scott
^ permalink raw reply
* [RFC] AmigaOne device tree source v2
From: Gerhard Pircher @ 2007-08-31 17:50 UTC (permalink / raw)
To: linuxppc-dev
Hi,
I updated the AmigaOne device tree based on the comments in this thread:
http://ozlabs.org/pipermail/linuxppc-dev/2007-June/038069.html
All the ISA devices are now subnodes of the PCI2ISA bridge, which marks
the first 64k (of PCI address space) as I/O space. The pci node doesn't
contain any interrupt routing information, because interrupt routing
differs between the three AmigaOne models. Thus I would like to omit it,
if it is not really necessary. The PCI host for bus 0 is a subnode of
the pci node, but I'm not sure if this is correct.
Please take a look at the reg and ranges properties of the PCI devices.
The PCI OF spec defined "zero" reg properties (like
reg = <00xxxx00 00000000 00000000 00000000 00000000>, where xxxx is
the device number), even if all the other BARs are defined. What are
they good for?
The BARs of the VIA IDE controller are assumed to be relocateable,
even if the address is fixed in compatibility mode.
BTW: Is there a way to specify the addresses for PCI config with
indirect addressing?
Thanks!
regards,
Gerhard
/*
* AmigaOne Device Tree Source
*
* Copyright 2007 Gerhard Pircher (gerhard_pircher@gmx.net)
*
* This program is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License as published by the
* Free Software Foundation; either version 2 of the License, or (at your
* option) any later version.
*/
/ {
model = "Eyetech,AmigaOne";
compatible = "Eyetech,AmigaOne" "MAI,Teron";
#address-cells = <1>;
#size-cells = <1>;
cpus {
#address-cells = <1>;
#size-cells = <0>;
cpu@0 {
device_type = "cpu";
reg = <0>;
d-cache-line-size = <20>; // 32 bytes
i-cache-line-size = <20>; // 32 bytes
d-cache-size = <8000>; // L1, 32K
i-cache-size = <8000>; // L1, 32K
timebase-frequency = <0>; // 33.3 MHz, from U-boot
clock-frequency = <0>; // From U-boot
bus-frequency = <0>; // From U-boot
32-bit;
};
};
memory {
device_type = "memory";
reg = <0 0>; // From U-boot
};
pci@80000000 {
device_type = "pci";
bus-frequency = <01fca055>; // 33.3MHz
bus-range = <0 1>;
reg = <80000000 7f000000>; // Whole PCI space.
ranges = <01000000 0 00000000 fe000000 0 00c00000 // PCI I/O
02000000 0 80000000 80000000 0 7d000000 // PCI memory
02000000 0 fd000000 fd000000 0 01000000>; // PCI alias memory
8259-interrupt-acknowledge = <fef00000>;
#address-cells = <3>;
#size-cells = <2>;
host@0 {
vendor-id = 0x000010cc;
device-id = 0x00000660;
revision-id = 0x00000001;
class-code = 0x00060000;
subsystem-id = 0x00000000;
subsystem-vendor-id = 0x00000000;
devsel-speed = 0x00000001;
66mhz-capable;
min-grant = 0x00000000;
max-latency = 0x00000000;
// AGP aperture is unset.
reg = <42000010 0 00000000 0 00400000>;
assigned-addresses = <42000010 0 00000000 0 00400000>;
}
isa@7 {
device_type = "isa";
vendor-id = 0x00001106;
device-id = 0x00000686;
revision-id = 0x00000010;
class-code = 0x00060100;
subsystem-id = 0x00000000;
subsystem-vendor-id = 0x00000000;
devsel-speed = 0x00000001;
min-grant = 0x00000000;
max-latency = 0x00000000;
/* First 64k for I/O at 0x0 on PCI mapped to 0x0 on ISA. */
ranges = <00000001 0 01000000 0 00000000 00010000>;
interrupt-parent = <&/pci@80000000/isa@7/interrupt-controller>;
#interrupt-cells = <2>;
#address-cells = <2>;
#size-cells = <1>;
dma-controller {
device_type = "dma-controller";
compatible = "pnpPNP,200";
reg = <00000001 00000000 00000010
00000001 00000080 00000010
00000001 000000c0 00000020>;
/* Channel 4 reserverd, cascade mode, 2x32k transfer/counter
* widths and bus master capability. Is this really necessary?
*/
/* dma = <4 4 20 20 1>; */
};
interrupt-controller {
device_type = "interrupt-controller";
compatible = "pnpPNP,000";
interrupt-controller;
reg = <00000001 00000020 00000002
00000001 000000a0 00000002
00000001 000004d0 00000002>;
reserved-interrupts = <2>;
};
8042@60 {
device_type = "8042";
compatible = "pnpPNP,303";
reg = <00000001 00000060 00000010>;
interrupts = <1 3 c 3>; // IRQ1, IRQ12 (rising edge)
keyboard {
device_type = "keyboard";
compatible = "pnpPNP,303"; // Here again?
reg = <0 0 0>;
};
mouse {
device_type = "mouse";
compatible = "pnpPNP,f03";
reg = <0 0 0>;
};
};
timer@40 {
/* device_type = "timer"; */ // No device type binding for now.
compatibe = "pnpPNP,100"; // Also add pcspkr to platform devices.
reg = <00000001 00000040 00000020>;
};
rtc@70 {
device_type = "rtc";
compatible = "pnpPNP,b00"; // <ds1385-rtc>; // What should be used here?
reg = <00000001 00000070 00000002>;
interrupts = <8 3>;
};
serial@2f8 {
device_type = "serial";
compatible = "pnpPNP,501" "pnpPNP,500"; // "ns16550"; add property check to OF serial code.
reg = <00000001 000002f8 00000008>;
interrupts = <3 3>; // IRQ3 (rising edge)
clock-frequency = <0>; // Not necessary?
};
serial@3f8 {
device_type = "serial";
compatible = "pnpPNP,501" "pnpPNP,500"; // "ns16550"; add property check to OF serial code.
reg = <00000001 000003f8 00000008>;
interrupts = <4 3>; // IRQ4 (rising edge)
clock-frequency = <0>; // Not necessary?
};
parallel@378 {
device_type = "parallel";
compatible = "pnpPNP,400"; // "pnpPNP,401" // No ECP support for now.
reg = <00000001 00000378 00000003
00000001 00000778 00000003>;
/* interrupts = <7>; */ // No IRQ free on AmigaOne!
/* dma = <3 0 0 0>; */ // Parallel port DMA mode?
};
fdc@3f0 {
device_type = "fdc";
compatible = "pnpPNP,700";
reg = <00000001 000003f0 00000008>;
interrupts = <6 3>; // IRQ6 (rising edge)
/* dma = < >; */ // Floppy DMA mode?
disk@0 {
device_type = "block";
reg = <0 0 0>;
};
};
};
ide@7,1 {
// Is there a device_type defined for IDE controllers?
vendor-id = 0x00001106;
device-id = 0x00000571;
revision-id = 0x00000006;
// Class code with PCI IDE programming interface indicator.
class-code = 0x0001018f;
subsystem-id = 0;
subsystem-vendor-id = 0;
devsel-speed = 0x00000001;
min-grant = 0;
max-latency = 0;
fast-back-to-back;
// Assume base addresses are relocateable, even if
// controller operates in compatibility mode. Right?
reg = <21003910 0 00000000 0 00000000
21003914 0 00000000 0 00000000
21003918 0 00000000 0 00000000
2100391c 0 00000000 0 00000000
21003920 0 00000000 0 00000000>;
assigned-addresses = <01003910 0 000001f0 0 00000008
01003914 0 000003f4 0 00000004
01003918 0 00000170 0 00000008
0100391c 0 00000374 0 00000004
01003920 0 0000cc00 0 00000010>;
};
chosen {
linux,stdout-path = "/pci@80000000/isa@7/serial@2f8";
};
};
--
Psssst! Schon vom neuen GMX MultiMessenger gehört?
Der kanns mit allen: http://www.gmx.net/de/go/multimessenger
^ permalink raw reply
* Re: [PATCH 2.6.23] ibmebus: Prevent bus_id collisions
From: Joachim Fenkes @ 2007-08-31 17:46 UTC (permalink / raw)
To: Arnd Bergmann
Cc: Thomas Q Klein, Paul Mackerras, Jan-Bernd Themann, LKML,
linuxppc-dev, Christoph Raisch, Paul Mackerras, Stefan Roscher
In-Reply-To: <200708311908.05255.arnd@arndb.de>
> > The plaintiff makes a valid point. How about a staging approach: We
put
> > the patch as it is now into 2.6.23 so the problem is fixed, and I'll
post
> > a "nice" version with autoloading support and a generic of_make_bus_id
> > function for 2.6.24. Agree?
>
> Ok, sounds fair. Can you make sure that the resulting bus_id is the same
> for the final version then?
No, it would change once more -- the current, minimal-invasive, variant of
the fix uses the full_name -> "ehca@12345678", while of_make_bus_id uses
another format: "12345678.ehca". I don't think this makes much of a
difference, though, and users shouldn't rely on the bus_id having a
certain format anyway, so IMHO we can live with this.
Regards,
Joachim
^ permalink raw reply
* To post to this list
From: José Luis Añamuro @ 2007-08-31 17:44 UTC (permalink / raw)
To: linuxppc-embedded
[-- Attachment #1: Type: text/plain, Size: 307 bytes --]
To post to this list
Jose Luis
____________________________________________________________________________________
Sé un Mejor Amante del Cine
¿Quieres saber cómo? ¡Deja que otras personas te ayuden!
http://advision.webevents.yahoo.com/reto/entretenimiento.html
[-- Attachment #2: Type: text/html, Size: 528 bytes --]
^ permalink raw reply
* [PATCH] mpc5200: add cuimage support for mpc5200 boards
From: Grant Likely @ 2007-08-31 17:34 UTC (permalink / raw)
To: tnt, scottwood, galak, linuxppc-dev
From: Grant Likely <grant.likely@secretlab.ca>
Signed-off-by: Grant Likely <grant.likely@secretlab.ca>
---
arch/powerpc/boot/Makefile | 5 ++-
arch/powerpc/boot/cuboot-52xx.c | 59 ++++++++++++++++++++++++++++++
arch/powerpc/boot/mpc52xx-psc.c | 69 +++++++++++++++++++++++++++++++++++
arch/powerpc/boot/ops.h | 1 +
arch/powerpc/boot/serial.c | 2 +
arch/powerpc/platforms/52xx/Kconfig | 1 +
6 files changed, 135 insertions(+), 2 deletions(-)
diff --git a/arch/powerpc/boot/Makefile b/arch/powerpc/boot/Makefile
index cd7c057..45be0e5 100644
--- a/arch/powerpc/boot/Makefile
+++ b/arch/powerpc/boot/Makefile
@@ -45,8 +45,8 @@ src-wlib := string.S crt0.S stdio.c main.c flatdevtree.c flatdevtree_misc.c \
ns16550.c serial.c simple_alloc.c div64.S util.S \
gunzip_util.c elf_util.c $(zlib) devtree.c oflib.c ofconsole.c \
4xx.c ebony.c mv64x60.c mpsc.c mv64x60_i2c.c cuboot.c bamboo.c \
- cpm-serial.c
-src-plat := of.c cuboot-83xx.c cuboot-85xx.c holly.c \
+ cpm-serial.c mpc52xx-psc.c
+src-plat := of.c cuboot-52xx.c cuboot-83xx.c cuboot-85xx.c holly.c \
cuboot-ebony.c treeboot-ebony.c prpmc2800.c \
ps3-head.S ps3-hvcall.S ps3.c treeboot-bamboo.c cuboot-8xx.c cuboot-pq2.c
src-boot := $(src-wlib) $(src-plat) empty.c
@@ -142,6 +142,7 @@ image-$(CONFIG_DEFAULT_UIMAGE) += uImage
ifneq ($(CONFIG_DEVICE_TREE),"")
image-$(CONFIG_PPC_8xx) += cuImage.8xx
image-$(CONFIG_8260) += cuImage.pq2
+image-$(CONFIG_PPC_MPC52xx) += cuImage.52xx
image-$(CONFIG_PPC_83xx) += cuImage.83xx
image-$(CONFIG_PPC_85xx) += cuImage.85xx
image-$(CONFIG_EBONY) += treeImage.ebony cuImage.ebony
diff --git a/arch/powerpc/boot/cuboot-52xx.c b/arch/powerpc/boot/cuboot-52xx.c
new file mode 100644
index 0000000..9256a26
--- /dev/null
+++ b/arch/powerpc/boot/cuboot-52xx.c
@@ -0,0 +1,59 @@
+/*
+ * Old U-boot compatibility for MPC5200
+ *
+ * Author: Grant Likely <grant.likely@secretlab.ca>
+ *
+ * Copyright (c) 2007 Secret Lab Technologies Ltd.
+ * Copyright (c) 2007 Freescale Semiconductor, Inc.
+ *
+ * This program is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License version 2 as published
+ * by the Free Software Foundation.
+ */
+
+#include "ops.h"
+#include "stdio.h"
+#include "io.h"
+#include "cuboot.h"
+
+#define TARGET_PPC_MPC52xx
+#include "ppcboot.h"
+
+static bd_t bd;
+
+static void platform_fixups(void)
+{
+ void *soc, *reg;
+ int div;
+ u32 sysfreq;
+
+
+ dt_fixup_memory(bd.bi_memstart, bd.bi_memsize);
+ dt_fixup_mac_addresses(bd.bi_enetaddr);
+ dt_fixup_cpu_clocks(bd.bi_intfreq, bd.bi_busfreq / 4, bd.bi_busfreq);
+
+ /* Unfortunately, the specific model number is encoded in the
+ * soc node name in existing dts files -- once that is fixed,
+ * this can do a simple path lookup.
+ */
+ soc = find_node_by_devtype(NULL, "soc");
+ if (soc) {
+ setprop(soc, "bus-frequency", &bd.bi_ipbfreq,
+ sizeof(bd.bi_ipbfreq));
+
+ if (!dt_xlate_reg(soc, 0, (void*)®, NULL))
+ return;
+ div = in_8(reg + 0x204) & 0x0020 ? 8 : 4;
+ sysfreq = bd.bi_busfreq * div;
+ setprop(soc, "system-frequency", &sysfreq, sizeof(sysfreq));
+ }
+}
+
+void platform_init(unsigned long r3, unsigned long r4, unsigned long r5,
+ unsigned long r6, unsigned long r7)
+{
+ CUBOOT_INIT();
+ ft_init(_dtb_start, _dtb_end - _dtb_start, 32);
+ serial_console_init();
+ platform_ops.fixups = platform_fixups;
+}
diff --git a/arch/powerpc/boot/mpc52xx-psc.c b/arch/powerpc/boot/mpc52xx-psc.c
new file mode 100644
index 0000000..1074626
--- /dev/null
+++ b/arch/powerpc/boot/mpc52xx-psc.c
@@ -0,0 +1,69 @@
+/*
+ * MPC5200 PSC serial console support.
+ *
+ * Author: Grant Likely <grant.likely@secretlab.ca>
+ *
+ * Copyright (c) 2007 Secret Lab Technologies Ltd.
+ * Copyright (c) 2007 Freescale Semiconductor, Inc.
+ *
+ * It is assumed that the firmware (or the platform file) has already set
+ * up the port.
+ */
+
+#include "types.h"
+#include "io.h"
+#include "ops.h"
+
+/* Programmable Serial Controller (PSC) status register bits */
+#define MPC52xx_PSC_SR 0x04
+#define MPC52xx_PSC_SR_RXRDY 0x0100
+#define MPC52xx_PSC_SR_RXFULL 0x0200
+#define MPC52xx_PSC_SR_TXRDY 0x0400
+#define MPC52xx_PSC_SR_TXEMP 0x0800
+
+#define MPC52xx_PSC_BUFFER 0x0C
+
+static void *psc;
+
+static int psc_open(void)
+{
+ /* Assume the firmware has already configured the PSC into
+ * uart mode */
+ return 0;
+}
+
+static void psc_putc(unsigned char c)
+{
+ while (!(in_be16(psc + MPC52xx_PSC_SR) & MPC52xx_PSC_SR_TXRDY)) ;
+ out_8(psc + MPC52xx_PSC_BUFFER, c);
+}
+
+static unsigned char psc_tstc(void)
+{
+ return (in_be16(psc + MPC52xx_PSC_SR) & MPC52xx_PSC_SR_RXRDY) != 0;
+}
+
+static unsigned char psc_getc(void)
+{
+ while (!(in_be16(psc + MPC52xx_PSC_SR) & MPC52xx_PSC_SR_RXRDY)) ;
+ return in_8(psc + MPC52xx_PSC_BUFFER);
+}
+
+int mpc5200_psc_console_init(void *devp, struct serial_console_data *scdp)
+{
+ int n;
+
+ /* Get the base address of the psc registers */
+ n = getprop(devp, "virtual-reg", &psc, sizeof(psc));
+ if (n != sizeof(psc)) {
+ if (!dt_xlate_reg(devp, 0, (void *)&psc, NULL))
+ return -1;
+ }
+
+ scdp->open = psc_open;
+ scdp->putc = psc_putc;
+ scdp->getc = psc_getc;
+ scdp->tstc = psc_tstc;
+
+ return 0;
+}
diff --git a/arch/powerpc/boot/ops.h b/arch/powerpc/boot/ops.h
index 45c2268..5ab9b51 100644
--- a/arch/powerpc/boot/ops.h
+++ b/arch/powerpc/boot/ops.h
@@ -83,6 +83,7 @@ int serial_console_init(void);
int ns16550_console_init(void *devp, struct serial_console_data *scdp);
int mpsc_console_init(void *devp, struct serial_console_data *scdp);
int cpm_console_init(void *devp, struct serial_console_data *scdp);
+int mpc5200_psc_console_init(void *devp, struct serial_console_data *scdp);
void *simple_alloc_init(char *base, unsigned long heap_size,
unsigned long granularity, unsigned long max_allocs);
extern void flush_cache(void *, unsigned long);
diff --git a/arch/powerpc/boot/serial.c b/arch/powerpc/boot/serial.c
index d47f8e0..95e08e4 100644
--- a/arch/powerpc/boot/serial.c
+++ b/arch/powerpc/boot/serial.c
@@ -126,6 +126,8 @@ int serial_console_init(void)
dt_is_compatible(devp, "fsl,cpm2-scc-uart") ||
dt_is_compatible(devp, "fsl,cpm2-smc-uart"))
rc = cpm_console_init(devp, &serial_cd);
+ else if (dt_is_compatible(devp, "mpc5200-psc-uart"))
+ rc = mpc5200_psc_console_init(devp, &serial_cd);
/* Add other serial console driver calls here */
diff --git a/arch/powerpc/platforms/52xx/Kconfig b/arch/powerpc/platforms/52xx/Kconfig
index 3ffaa06..9ddf251 100644
--- a/arch/powerpc/platforms/52xx/Kconfig
+++ b/arch/powerpc/platforms/52xx/Kconfig
@@ -30,6 +30,7 @@ config PPC_EFIKA
config PPC_LITE5200
bool "Freescale Lite5200 Eval Board"
depends on PPC_MULTIPLATFORM && PPC32
+ select WANT_DEVICE_TREE
select PPC_MPC5200
default n
^ permalink raw reply related
* to post to this list
From: José Luis Añamuro @ 2007-08-31 17:22 UTC (permalink / raw)
To: linuxppc-embedded
[-- Attachment #1: Type: text/plain, Size: 307 bytes --]
to post to this list
José Luis
____________________________________________________________________________________
Sé un Mejor Amante del Cine
¿Quieres saber cómo? ¡Deja que otras personas te ayuden!
http://advision.webevents.yahoo.com/reto/entretenimiento.html
[-- Attachment #2: Type: text/html, Size: 543 bytes --]
^ 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