* [PATCH] PCI Error Recovery: e100 network device driver
From: Linas Vepstas @ 2006-04-06 22:24 UTC (permalink / raw)
To: Jeff Garzik, netdev, linux-pci
Cc: linuxppc-dev, john.ronciak, linux-kernel, jeffrey.t.kirsher,
jesse.brandeburg
Please apply and forward upstream.
--linas
[PATCH] PCI Error Recovery: e100 network device driver
Various PCI bus errors can be signaled by newer PCI controllers. This
patch adds the PCI error recovery callbacks to the intel ethernet e100
device driver. The patch has been tested, and appears to work well.
Signed-off-by: Linas Vepstas <linas@linas.org>
Acked-by: Jesse Brandeburg <jesse.brandeburg@intel.com>
----
drivers/net/e100.c | 65 +++++++++++++++++++++++++++++++++++++++++++++++++++++
1 files changed, 65 insertions(+)
Index: linux-2.6.17-rc1/drivers/net/e100.c
===================================================================
--- linux-2.6.17-rc1.orig/drivers/net/e100.c 2006-04-05 09:56:06.000000000 -0500
+++ linux-2.6.17-rc1/drivers/net/e100.c 2006-04-06 15:17:29.000000000 -0500
@@ -2781,6 +2781,70 @@ static void e100_shutdown(struct pci_dev
}
+/* ------------------ PCI Error Recovery infrastructure -------------- */
+/** e100_io_error_detected() is called when PCI error is detected */
+static pci_ers_result_t e100_io_error_detected(struct pci_dev *pdev, pci_channel_state_t state)
+{
+ struct net_device *netdev = pci_get_drvdata(pdev);
+
+ /* Same as calling e100_down(netdev_priv(netdev)), but generic */
+ netdev->stop(netdev);
+
+ /* Detach; put netif into state similar to hotplug unplug */
+ netif_poll_enable(netdev);
+ netif_device_detach(netdev);
+
+ /* Request a slot reset. */
+ return PCI_ERS_RESULT_NEED_RESET;
+}
+
+/** e100_io_slot_reset is called after the pci bus has been reset.
+ * Restart the card from scratch. */
+static pci_ers_result_t e100_io_slot_reset(struct pci_dev *pdev)
+{
+ struct net_device *netdev = pci_get_drvdata(pdev);
+ struct nic *nic = netdev_priv(netdev);
+
+ if(pci_enable_device(pdev)) {
+ printk(KERN_ERR "e100: Cannot re-enable PCI device after reset.\n");
+ return PCI_ERS_RESULT_DISCONNECT;
+ }
+ pci_set_master(pdev);
+
+ /* Only one device per card can do a reset */
+ if (0 != PCI_FUNC (pdev->devfn))
+ return PCI_ERS_RESULT_RECOVERED;
+ e100_hw_reset(nic);
+ e100_phy_init(nic);
+
+ return PCI_ERS_RESULT_RECOVERED;
+}
+
+/** e100_io_resume is called when the error recovery driver
+ * tells us that its OK to resume normal operation.
+ */
+static void e100_io_resume(struct pci_dev *pdev)
+{
+ struct net_device *netdev = pci_get_drvdata(pdev);
+ struct nic *nic = netdev_priv(netdev);
+
+ /* ack any pending wake events, disable PME */
+ pci_enable_wake(pdev, 0, 0);
+
+ netif_device_attach(netdev);
+ if(netif_running(netdev)) {
+ e100_open (netdev);
+ mod_timer(&nic->watchdog, jiffies);
+ }
+}
+
+static struct pci_error_handlers e100_err_handler = {
+ .error_detected = e100_io_error_detected,
+ .slot_reset = e100_io_slot_reset,
+ .resume = e100_io_resume,
+};
+
+
static struct pci_driver e100_driver = {
.name = DRV_NAME,
.id_table = e100_id_table,
@@ -2791,6 +2855,7 @@ static struct pci_driver e100_driver = {
.resume = e100_resume,
#endif
.shutdown = e100_shutdown,
+ .err_handler = &e100_err_handler,
};
static int __init e100_init_module(void)
^ permalink raw reply
* Re: freescale lite 5200 board and kernel 2.6
From: Domenico Andreoli @ 2006-04-06 22:10 UTC (permalink / raw)
To: linuxppc-embedded
In-Reply-To: <20060405212741.GC61331@server.idefix.loc>
[-- Attachment #1: Type: text/plain, Size: 1231 bytes --]
On Wed, Apr 05, 2006 at 11:27:41PM +0200, Matthias Fechner wrote:
> Hello Domenico,
hi Matthias,
> * Domenico Andreoli <cavokz@gmail.com> [05-04-06 23:06]:
> > is there any patchset i can use for kernel 2.6? is it production-ready?
> > why isn't already in vanilla 2.6? has any sense to stay with kernel 2.4?
>
> I'm not sure if this helps, but I was successfully in getting a kernel
> 2.6 running with the icecube board. I have written a short docu in my
> wiki (booting with tftp and rootnfs over NFS):
> http://wiki.idefix.fechner.net/index.php/IceCube#Writing_kernel_modules_for_2.6
this is a very nice page, it is now my reference :)
anyway i cannot say i made it, my icecube is still not under control.
every time i boot the 2.6 kernel after the original 2.4 one, the nic
seems to work. on subsequent boots, even after board resets, it does not.
i still need to check what happens removing the power cord.
kernel is built following the instructions on your wiki, i attached
the config file. please have a look, let me know if any check/test may
be advised.
cheers
domenico
-----[ Domenico Andreoli, aka cavok
--[ http://people.debian.org/~cavok/gpgkey.asc
---[ 3A0F 2F80 F79C 678A 8936 4FEE 0677 9033 A20E BC50
[-- Attachment #2: config-2.6.16.1-mpc52xx.gz --]
[-- Type: application/octet-stream, Size: 5476 bytes --]
^ permalink raw reply
* [PATCH 5/5] cell: enable CPU_FTR_CI_LARGE_PAGE
From: arnd @ 2006-04-06 22:00 UTC (permalink / raw)
To: Paul Mackerras; +Cc: linuxppc-dev, cbe-oss-dev, Arnd Bergmann
In-Reply-To: <20060407150124.422051000@dyn-9-152-242-103.boeblingen.de.ibm.com>
Reflect the fact that the Cell Broadband Engine supports 64k
pages by adding the bit to the CPU features.
Signed-off-by: Arnd Bergmann <arnd.bergmann@de.ibm.com>
---
Index: linus-2.6/include/asm-powerpc/cputable.h
===================================================================
--- linus-2.6.orig/include/asm-powerpc/cputable.h
+++ linus-2.6/include/asm-powerpc/cputable.h
@@ -323,7 +323,7 @@ extern void do_cpu_ftr_fixups(unsigned l
#define CPU_FTRS_CELL (CPU_FTR_SPLIT_ID_CACHE | CPU_FTR_USE_TB | \
CPU_FTR_HPTE_TABLE | CPU_FTR_PPCAS_ARCH_V2 | \
CPU_FTR_ALTIVEC_COMP | CPU_FTR_MMCRA | CPU_FTR_SMT | \
- CPU_FTR_CTRL | CPU_FTR_PAUSE_ZERO)
+ CPU_FTR_CTRL | CPU_FTR_PAUSE_ZERO | CPU_FTR_CI_LARGE_PAGE)
#define CPU_FTRS_COMPATIBLE (CPU_FTR_SPLIT_ID_CACHE | CPU_FTR_USE_TB | \
CPU_FTR_HPTE_TABLE | CPU_FTR_PPCAS_ARCH_V2)
#endif
--
^ permalink raw reply
* [PATCH 4/5] powerpc: export symbols for page size selection
From: arnd @ 2006-04-06 22:00 UTC (permalink / raw)
To: Paul Mackerras; +Cc: linuxppc-dev, cbe-oss-dev, Arnd Bergmann
In-Reply-To: <20060407150124.422051000@dyn-9-152-242-103.boeblingen.de.ibm.com>
We need access to some symbols in powerpc memory management
from spufs in order to create proper SLB entries.
Signed-off-by: Arnd Bergmann <arnd.bergmann@de.ibm.com>
Index: linus-2.6/arch/powerpc/mm/hash_utils_64.c
===================================================================
--- linus-2.6.orig/arch/powerpc/mm/hash_utils_64.c
+++ linus-2.6/arch/powerpc/mm/hash_utils_64.c
@@ -85,16 +85,26 @@ extern unsigned long dart_tablebase;
#endif /* CONFIG_U3_DART */
static unsigned long _SDR1;
-struct mmu_psize_def mmu_psize_defs[MMU_PAGE_COUNT];
hpte_t *htab_address;
unsigned long htab_size_bytes;
unsigned long htab_hash_mask;
+
+struct mmu_psize_def mmu_psize_defs[MMU_PAGE_COUNT];
+EXPORT_SYMBOL_GPL(mmu_psize_defs);
+
int mmu_linear_psize = MMU_PAGE_4K;
+EXPORT_SYMBOL_GPL(mmu_linear_psize);
+
int mmu_virtual_psize = MMU_PAGE_4K;
+EXPORT_SYMBOL_GPL(mmu_virtual_psize);
+
#ifdef CONFIG_HUGETLB_PAGE
int mmu_huge_psize = MMU_PAGE_16M;
+EXPORT_SYMBOL_GPL(mmu_huge_psize);
+
unsigned int HPAGE_SHIFT;
+EXPORT_SYMBOL_GPL(HPAGE_SHIFT);
#endif
/* There are definitions of page sizes arrays to be used when none
--
^ permalink raw reply
* [PATCH 3/5] spufs: set up correct SLB entries for 64k pages
From: arnd @ 2006-04-06 22:00 UTC (permalink / raw)
To: Paul Mackerras; +Cc: linuxppc-dev, cbe-oss-dev, Arnd Bergmann
In-Reply-To: <20060407150124.422051000@dyn-9-152-242-103.boeblingen.de.ibm.com>
spufs currently knows only 4k pages and 16M hugetlb
pages. Make it use the regular methods for deciding on
the SLB bits.
Signed-off-by: Arnd Bergmann <arnd.bergmann@de.ibm.com>
Index: linus-2.6/arch/powerpc/platforms/cell/spu_base.c
===================================================================
--- linus-2.6.orig/arch/powerpc/platforms/cell/spu_base.c
+++ linus-2.6/arch/powerpc/platforms/cell/spu_base.c
@@ -71,7 +71,7 @@ static int __spu_trap_data_seg(struct sp
{
struct spu_priv2 __iomem *priv2 = spu->priv2;
struct mm_struct *mm = spu->mm;
- u64 esid, vsid;
+ u64 esid, vsid, llp;
pr_debug("%s\n", __FUNCTION__);
@@ -91,9 +91,14 @@ static int __spu_trap_data_seg(struct sp
}
esid = (ea & ESID_MASK) | SLB_ESID_V;
- vsid = (get_vsid(mm->context.id, ea) << SLB_VSID_SHIFT) | SLB_VSID_USER;
+#ifdef CONFIG_HUGETLB_PAGE
if (in_hugepage_area(mm->context, ea))
- vsid |= SLB_VSID_L;
+ llp = mmu_psize_defs[mmu_huge_psize].sllp;
+ else
+#endif
+ llp = mmu_psize_defs[mmu_virtual_psize].sllp;
+ vsid = (get_vsid(mm->context.id, ea) << SLB_VSID_SHIFT) |
+ SLB_VSID_USER | llp;
out_be64(&priv2->slb_index_W, spu->slb_replace);
out_be64(&priv2->slb_vsid_RW, vsid);
Index: linus-2.6/arch/powerpc/platforms/cell/spufs/switch.c
===================================================================
--- linus-2.6.orig/arch/powerpc/platforms/cell/spufs/switch.c
+++ linus-2.6/arch/powerpc/platforms/cell/spufs/switch.c
@@ -718,13 +718,15 @@ static inline void invalidate_slbs(struc
static inline void get_kernel_slb(u64 ea, u64 slb[2])
{
- slb[0] = (get_kernel_vsid(ea) << SLB_VSID_SHIFT) | SLB_VSID_KERNEL;
- slb[1] = (ea & ESID_MASK) | SLB_ESID_V;
+ u64 llp;
- /* Large pages are used for kernel text/data, but not vmalloc. */
- if (cpu_has_feature(CPU_FTR_16M_PAGE)
- && REGION_ID(ea) == KERNEL_REGION_ID)
- slb[0] |= SLB_VSID_L;
+ if (REGION_ID(ea) == KERNEL_REGION_ID)
+ llp = mmu_psize_defs[mmu_linear_psize].sllp;
+ else
+ llp = mmu_psize_defs[mmu_virtual_psize].sllp;
+ slb[0] = (get_kernel_vsid(ea) << SLB_VSID_SHIFT) |
+ SLB_VSID_KERNEL | llp;
+ slb[1] = (ea & ESID_MASK) | SLB_ESID_V;
}
static inline void load_mfc_slb(struct spu *spu, u64 slb[2], int slbe)
Index: linus-2.6/arch/powerpc/platforms/cell/Kconfig
===================================================================
--- linus-2.6.orig/arch/powerpc/platforms/cell/Kconfig
+++ linus-2.6/arch/powerpc/platforms/cell/Kconfig
@@ -22,7 +22,7 @@ config SPU_FS
config SPUFS_MMAP
bool
- depends on SPU_FS && SPARSEMEM && !PPC_64K_PAGES
+ depends on SPU_FS && SPARSEMEM
default y
endmenu
--
^ permalink raw reply
* [PATCH 2/5] powerpc: fix 64k pages on non-hypervisor
From: arnd @ 2006-04-06 22:00 UTC (permalink / raw)
To: Paul Mackerras; +Cc: Arnd Bergmann, linuxppc-dev, cbe-oss-dev
In-Reply-To: <20060407150124.422051000@dyn-9-152-242-103.boeblingen.de.ibm.com>
The page size encoding passed to tlbie is incorrect for
new-style large pages. This fixes it.
Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Signed-off-by: Arnd Bergmann <arnd.bergmann@de.ibm.com>
Index: linus-2.6/arch/powerpc/mm/hash_native_64.c
===================================================================
--- linus-2.6.orig/arch/powerpc/mm/hash_native_64.c
+++ linus-2.6/arch/powerpc/mm/hash_native_64.c
@@ -52,7 +52,7 @@ static inline void __tlbie(unsigned long
default:
penc = mmu_psize_defs[psize].penc;
va &= ~((1ul << mmu_psize_defs[psize].shift) - 1);
- va |= (0x7f >> (8 - penc)) << 12;
+ va |= penc << 12;
asm volatile("tlbie %0,1" : : "r" (va) : "memory");
break;
}
@@ -74,7 +74,7 @@ static inline void __tlbiel(unsigned lon
default:
penc = mmu_psize_defs[psize].penc;
va &= ~((1ul << mmu_psize_defs[psize].shift) - 1);
- va |= (0x7f >> (8 - penc)) << 12;
+ va |= penc << 12;
asm volatile(".long 0x7c000224 | (%0 << 11) | (1 << 21)"
: : "r"(va) : "memory");
break;
--
^ permalink raw reply
* [PATCH 1/5] spufs: Disable local interrupts for SPE hash_page calls.
From: arnd @ 2006-04-06 22:00 UTC (permalink / raw)
To: Paul Mackerras; +Cc: linuxppc-dev, cbe-oss-dev, Arnd Bergmann
In-Reply-To: <20060407150124.422051000@dyn-9-152-242-103.boeblingen.de.ibm.com>
This patch disables and saves local interrupts during
hash_page processing for SPE contexts.
We have to do it explicitly in the spu_irq_class_1_bottom
function. For the interrupt handlers, we get the behaviour
implicitly by using SA_INTERRUPT to disable interrupts while
in the handler.
Signed-off-by: Arnd Bergmann <arnd.bergmann@de.ibm.com>
---
Index: linus-2.6/arch/powerpc/platforms/cell/spu_base.c
===================================================================
--- linus-2.6.orig/arch/powerpc/platforms/cell/spu_base.c
+++ linus-2.6/arch/powerpc/platforms/cell/spu_base.c
@@ -306,19 +306,19 @@ spu_request_irqs(struct spu *spu)
snprintf(spu->irq_c0, sizeof (spu->irq_c0), "spe%02d.0", spu->number);
ret = request_irq(irq_base + spu->isrc,
- spu_irq_class_0, 0, spu->irq_c0, spu);
+ spu_irq_class_0, SA_INTERRUPT, spu->irq_c0, spu);
if (ret)
goto out;
snprintf(spu->irq_c1, sizeof (spu->irq_c1), "spe%02d.1", spu->number);
ret = request_irq(irq_base + IIC_CLASS_STRIDE + spu->isrc,
- spu_irq_class_1, 0, spu->irq_c1, spu);
+ spu_irq_class_1, SA_INTERRUPT, spu->irq_c1, spu);
if (ret)
goto out1;
snprintf(spu->irq_c2, sizeof (spu->irq_c2), "spe%02d.2", spu->number);
ret = request_irq(irq_base + 2*IIC_CLASS_STRIDE + spu->isrc,
- spu_irq_class_2, 0, spu->irq_c2, spu);
+ spu_irq_class_2, SA_INTERRUPT, spu->irq_c2, spu);
if (ret)
goto out2;
goto out;
@@ -487,10 +487,14 @@ int spu_irq_class_1_bottom(struct spu *s
ea = spu->dar;
dsisr = spu->dsisr;
if (dsisr & (MFC_DSISR_PTE_NOT_FOUND | MFC_DSISR_ACCESS_DENIED)) {
+ u64 flags;
+
access = (_PAGE_PRESENT | _PAGE_USER);
access |= (dsisr & MFC_DSISR_ACCESS_PUT) ? _PAGE_RW : 0UL;
+ local_irq_save(flags);
if (hash_page(ea, access, 0x300) != 0)
error |= CLASS1_ENABLE_STORAGE_FAULT_INTR;
+ local_irq_restore(flags);
}
if (error & CLASS1_ENABLE_STORAGE_FAULT_INTR) {
if ((ret = spu_handle_mm_fault(spu)) != 0)
--
^ permalink raw reply
* [PATCH]: powerpc/pseries: bugfix: balance calls to pci_device_put
From: Linas Vepstas @ 2006-04-06 20:41 UTC (permalink / raw)
To: Paul Mackerras; +Cc: linuxppc-dev, linux-kernel
[PATCH]: powerpc/pseries: bugfix: balance calls to pci_device_put
Repeated calls to eeh_remove_device() can result in multiple
(and thus unbalanced) calls to pci_dev_put(). Make sure the
pci_device_put() is called only once (since there was only
one call to the matching pci_device_get()).
Signed-off-by: Linas Vepstas <linas@austin.ibm.com>
----
arch/powerpc/platforms/pseries/eeh.c | 6 ++++--
1 files changed, 4 insertions(+), 2 deletions(-)
Index: linux-2.6.17-rc1/arch/powerpc/platforms/pseries/eeh.c
===================================================================
--- linux-2.6.17-rc1.orig/arch/powerpc/platforms/pseries/eeh.c 2006-04-06 15:35:55.000000000 -0500
+++ linux-2.6.17-rc1/arch/powerpc/platforms/pseries/eeh.c 2006-04-06 15:38:04.968433419 -0500
@@ -957,8 +957,10 @@ static void eeh_remove_device(struct pci
pci_addr_cache_remove_device(dev);
dn = pci_device_to_OF_node(dev);
- PCI_DN(dn)->pcidev = NULL;
- pci_dev_put (dev);
+ if (PCI_DN(dn)->pcidev) {
+ PCI_DN(dn)->pcidev = NULL;
+ pci_dev_put (dev);
+ }
}
void eeh_remove_bus_device(struct pci_dev *dev)
^ permalink raw reply
* RE: Porting new MPC5200 based Board to linux kernel
From: bukhari @ 2006-04-06 20:57 UTC (permalink / raw)
To: 'Hans Thielemans', Linuxppc-embedded; +Cc: Linuxppc-embedded
In-Reply-To: <Pine.LNX.4.44.0604062158500.31146-100000@gandalf.inthazo.be>
Hi Hans,
> Hi Amir,
>
> Which MEN board is this? The EM01(A) or the PP01.
I am using EM01A
> We are using the EM01A and have linux running.
> We always got reasonable fast response from the MEN support service.
>
> If this does not work, I could send you my config file.
>
That will be nice from you to send me that.
Is that config file what I need to get linux running, didn't I need any
board special code. Like tqm5xxx.c etc. which located on arch\ppc\platforms
Thanks,
-Amir
> Hans
>
> On Thu, 6 Apr 2006, Amir Bukhari wrote:
>
> > We have a MEN mpc5200 base board and we want to get linux
> running on it.
> > MEN has a bios and can load linux kernel and passing to
> parameters. I
> > have tried to configure kernel manualy but without success.
> MEN bios
> > load kernel, but nothing happend after that, I don't see
> anything on console.
> >
> > I am new in this area, I need a first working kernel so that I can
> > implement other part.
> > I will need some guidnes.
> > Any help will be appretiated!!
> >
> > -Amir
> > _______________________________________________
> > Linuxppc-embedded mailing list
> > Linuxppc-embedded@ozlabs.org
> > https://ozlabs.org/mailman/listinfo/linuxppc-embedded
> >
>
^ permalink raw reply
* Upgrading cramfs root file system
From: Antonio Di Bacco @ 2006-04-06 20:38 UTC (permalink / raw)
To: linuxppc-embedded
Hi,
how could I upgrade my cramfs rootfs? I have a CGI in the rootfs that receives
the new rootfs from a web interface and then tries to write it in the flash.
While overwriting the old cramfs, the CGI will continue to work? something
weird could happen?
Best regards,
Antonio.
^ permalink raw reply
* Re: Porting new MPC5200 based Board to linux kernel
From: Hans Thielemans @ 2006-04-06 20:02 UTC (permalink / raw)
To: Amir Bukhari; +Cc: Linuxppc-embedded
In-Reply-To: <EE3E34EBE104B24DA5DF5DBC1EA998D528801E@loretta.fzi.de>
Hi Amir,
Which MEN board is this? The EM01(A) or the PP01.
We are using the EM01A and have linux running.
We always got reasonable fast response from the MEN support service.
If this does not work, I could send you my config file.
Hans
On Thu, 6 Apr 2006, Amir Bukhari wrote:
> We have a MEN mpc5200 base board and we want to get linux running on it.
> MEN has a bios and can load linux kernel and passing to parameters. I have
> tried to configure kernel manualy but without success. MEN bios load kernel,
> but nothing happend after that, I don't see anything on console.
>
> I am new in this area, I need a first working kernel so that I can implement
> other part.
> I will need some guidnes.
> Any help will be appretiated!!
>
> -Amir
> _______________________________________________
> Linuxppc-embedded mailing list
> Linuxppc-embedded@ozlabs.org
> https://ozlabs.org/mailman/listinfo/linuxppc-embedded
>
^ permalink raw reply
* Re: [PATCH] ppc32: Support for Freescale PQ2FADS
From: Wade Farnsworth @ 2006-04-06 16:44 UTC (permalink / raw)
To: Vitaly Bordug; +Cc: linuxppc-embedded
In-Reply-To: <1144339578.11172.19.camel@rhino.az.mvista.com>
On Thu, 2006-04-06 at 09:06, Wade Farnsworth wrote:
> On Thu, 2006-04-06 at 07:05, Vitaly Bordug wrote:
> >
> > Though I doubt if new boards are accepting to ppc/ currently, it's nice to have a patch
> > available. BTW, I suggest to use phy abstraction and updated fs_enet (submitted here recently)
<snip>
> > > +CONFIG_USB_ARCH_HAS_HCD=y
> > > +CONFIG_USB_ARCH_HAS_OHCI=y
> >
> > Not sure this is required as well.
>
> I'll disable this as well.
Looking at drivers/usb/Kconfig, these are actually enabled by default if
CONFIG_PCI is enabled. CONFIG_USB then depends on
CONFIG_USB_ARCH_HAS_HCD.
>
> <snip>
>
> > > +#ifdef CONFIG_PQ2FADS
> > > +#define F2_RXCLK 13
> > > +#define F2_TXCLK 14
> > > +#else
> > > #define F2_RXCLK 15
> > > #define F2_TXCLK 16
> > > +#endif
> > >
> > Hmm, this should go into the board-specific header - here should exist just a "reasonable default" (pq2ads.h in this context).
> >
> >
> > > /* FCC3 Clock Source Configuration. These can be redefined in the board specific file.
> > > Can only choose from CLK13-16 */
> > > +#ifdef CONFIG_PQ2FADS
> > > +#define F3_RXCLK 15
> > > +#define F3_TXCLK 16
> > > +#else
> > > #define F3_RXCLK 13
> > > #define F3_TXCLK 14
> > > +#endif
> > >
> > ditto.
>
> Ok, I'll move these defines into pq2ads.h
>
Also, moving the defines into pq2ads.h results in some nasty warning
messages. I'll put some #ifndef's around the #define's in pq2ads_pd.h
to squelch them.
-Wade
^ permalink raw reply
* Re: [PATCH] ppc32: Support for Freescale PQ2FADS
From: Wade Farnsworth @ 2006-04-06 16:06 UTC (permalink / raw)
To: Vitaly Bordug; +Cc: linuxppc-embedded
In-Reply-To: <20060406180517.36ad1b7d@vitb.ru.mvista.com>
On Thu, 2006-04-06 at 07:05, Vitaly Bordug wrote:
>
> Though I doubt if new boards are accepting to ppc/ currently, it's nice to have a patch
> available. BTW, I suggest to use phy abstraction and updated fs_enet (submitted here recently)
I'll look into that.
>
> Some more notes below.
<snip>
> > +CONFIG_INPUT=y
>
> This is useless for the board iirc.
<snip>
> >
> > +CONFIG_SOUND_GAMEPORT=y
> ditto.
Yes, you're right. I'm not sure why I had those enabled.
<snip>
> > +CONFIG_USB_ARCH_HAS_HCD=y
> > +CONFIG_USB_ARCH_HAS_OHCI=y
>
> Not sure this is required as well.
I'll disable this as well.
<snip>
> > +#ifdef CONFIG_PQ2FADS
> > +#define F2_RXCLK 13
> > +#define F2_TXCLK 14
> > +#else
> > #define F2_RXCLK 15
> > #define F2_TXCLK 16
> > +#endif
> >
> Hmm, this should go into the board-specific header - here should exist just a "reasonable default" (pq2ads.h in this context).
>
>
> > /* FCC3 Clock Source Configuration. These can be redefined in the board specific file.
> > Can only choose from CLK13-16 */
> > +#ifdef CONFIG_PQ2FADS
> > +#define F3_RXCLK 15
> > +#define F3_TXCLK 16
> > +#else
> > #define F3_RXCLK 13
> > #define F3_TXCLK 14
> > +#endif
> >
> ditto.
Ok, I'll move these defines into pq2ads.h
Thanks for the feedback. I'll make the changes and resubmit.
-Wade Farnsworth
^ permalink raw reply
* Porting new MPC5200 based Board to linux kernel
From: Amir Bukhari @ 2006-04-06 14:39 UTC (permalink / raw)
To: Linuxppc-embedded
We have a MEN mpc5200 base board and we want to get linux running on it.
MEN has a bios and can load linux kernel and passing to parameters. I =
have
tried to configure kernel manualy but without success. MEN bios load =
kernel,
but nothing happend after that, I don't see anything on console.
I am new in this area, I need a first working kernel so that I can =
implement
other part.
I will need some guidnes.
Any help will be appretiated!!
-Amir
^ permalink raw reply
* Re: MPC5200 + LocalPlus Bus + memcpy
From: Andrey Volkov @ 2006-04-06 14:21 UTC (permalink / raw)
To: Sascha Hauer; +Cc: Sylvain Munaut, Paul Mackerras, Linuxppc-embedded
In-Reply-To: <20060405113825.GA9110@localhost.localdomain>
[-- Attachment #1: Type: text/plain, Size: 1254 bytes --]
Hello, Sascha.
On Wednesday, April 5, 2006, Sascha Hauer wrote:
> Hi all,
> I try to use jffs2 on a flash device connected to the mpc5200
> LocalPlus Bus. This bus does not allow misaligned accesses.
> The jffs2 code uses memcpy to copy from a word aligned address to an
> odd address. The ppc memcpy implementation first copies three bytes to get
> the target address word aligned, but then the source address is on an
> odd address. The following word accesses on this unaligned address fail
> badly.
Invalid crc on 'name' field ;)?
> I have fixed my problem by modifying the physmap mtd driver, but some
> day someone wants to connect SRAM to the LocalPlus Bus and I guess he
> will expect memcpy to work.
Heh, I'll have same problem. Patch (dirty hack)
attached (vs head of vanilla 2.6. tree)
> (BTW the arm implementation of memcpy seems to work around this problem)
Wrong, memcpy to/from SDRAM _may_ be unaligned, only
memcpy_fromio/memcpy_toio _must_ be aligned to even addresses.
P.S.
Paul, Sylvain, any suggestions to fix it?
AFAIK, memcpy_to/from_io must be it string.s, isn't it?
P.P.S Sacha if you start to write mscan driver, then please wait a
week, I planned to send my work to can-socket at next Friday.
--
Regards,
Andrey Volkov
[-- Attachment #2: mpc52xx_LPB_jffs2_hack.diff --]
[-- Type: application/octet-stream, Size: 1493 bytes --]
diff --git a/fs/jffs2/scan.c b/fs/jffs2/scan.c
index cf55b22..3bf61d6 100644
--- a/fs/jffs2/scan.c
+++ b/fs/jffs2/scan.c
@@ -831,7 +831,7 @@ static int jffs2_scan_dirent_node(struct
if (!fd) {
return -ENOMEM;
}
- memcpy(&fd->name, rd->name, rd->nsize);
+ memcpy_fromio(&fd->name, rd->name, rd->nsize);
fd->name[rd->nsize] = 0;
crc = crc32(0, fd->name, rd->nsize);
diff --git a/include/asm-ppc/io.h b/include/asm-ppc/io.h
index b919d8f..c2f173a 100644
--- a/include/asm-ppc/io.h
+++ b/include/asm-ppc/io.h
@@ -354,6 +354,29 @@ extern void _outsl_ns(volatile u32 __iom
#define memset_io(a,b,c) memset((void *)(a),(b),(c))
#define memcpy_fromio(a,b,c) memcpy((a),(void *)(b),(c))
#define memcpy_toio(a,b,c) memcpy((void *)(a),(b),(c))
+#elif defined (CONFIG_PPC_MPC52xx)
+static inline void memset_io(volatile void __iomem *addr, unsigned char val, int count)
+{
+ volatile u8 __iomem *addr_u8 = addr;
+ for(;count>0;count--)
+ *addr_u8++ = val;
+}
+
+static inline void memcpy_fromio(void *dst,const volatile void __iomem *src, int count)
+{
+ const volatile u8 __iomem *src_u8 = src;
+ u8 *dst_u8 = dst;
+ for(;count>0;count--)
+ *dst_u8++ = *src_u8++;
+}
+
+static inline void memcpy_toio(volatile void __iomem *dst, const void *src, int count)
+{
+ const u8 *src_u8 = src;
+ volatile u8 __iomem *dst_u8 = dst;
+ for(;count>0;count--)
+ *dst_u8++ = *src_u8++;
+}
#else
static inline void memset_io(volatile void __iomem *addr, unsigned char val, int count)
{
^ permalink raw reply related
* [PATCH] spufs: fix section conflicts
From: Christoph Hellwig @ 2006-04-06 14:12 UTC (permalink / raw)
To: arndb; +Cc: linuxppc-dev
spufs_init/spufs_exit call various __init/__exit functions so they
need to be marked __init/__exit aswell to not get section conflicts.
Also move the module_init call to where it belongs.
Signed-off-by: Christoph Hellwig <hch@lst.de>
Index: linux-2.6/arch/powerpc/platforms/cell/spufs/inode.c
===================================================================
--- linux-2.6.orig/arch/powerpc/platforms/cell/spufs/inode.c 2006-04-06 15:53:42.000000000 +0200
+++ linux-2.6/arch/powerpc/platforms/cell/spufs/inode.c 2006-04-06 15:56:21.000000000 +0200
@@ -442,7 +442,7 @@
.kill_sb = kill_litter_super,
};
-static int spufs_init(void)
+static int __init spufs_init(void)
{
int ret;
ret = -ENOMEM;
@@ -470,15 +470,16 @@
out:
return ret;
}
-module_init(spufs_init);
-static void spufs_exit(void)
+static void __exit spufs_exit(void)
{
spu_sched_exit();
unregister_spu_syscalls(&spufs_calls);
unregister_filesystem(&spufs_type);
kmem_cache_destroy(spufs_inode_cache);
}
+
+module_init(spufs_init);
module_exit(spufs_exit);
MODULE_LICENSE("GPL");
^ permalink raw reply
* Re: [PATCH] ppc32: Support for Freescale PQ2FADS
From: Vitaly Bordug @ 2006-04-06 14:05 UTC (permalink / raw)
To: Wade Farnsworth; +Cc: linuxppc-embedded
In-Reply-To: <1144194855.32471.64.camel@rhino.az.mvista.com>
On 04 Apr 2006 16:54:16 -0700
Wade Farnsworth <wfarnsworth@mvista.com> wrote:
> From: Wade Farnsworth <wfarnsworth@mvista.com>
>
> Adds support for the Freescale PQ2FADS board.
>
> Signed-off-by: Wade Farnsworth <wfarnsworth@mvista.com>
>
Though I doubt if new boards are accepting to ppc/ currently, it's nice to have a patch
available. BTW, I suggest to use phy abstraction and updated fs_enet (submitted here recently)
Some more notes below.
> ---
>
> arch/ppc/Kconfig | 2
> arch/ppc/configs/pq2fads_defconfig | 712 +++++++++++++++++++++++++++
> arch/ppc/platforms/Makefile | 1
> arch/ppc/platforms/pq2ads.h | 10
> arch/ppc/platforms/pq2ads_pd.h | 11
> arch/ppc/platforms/pq2fads_setup.c | 235 ++++++++
> arch/ppc/syslib/m82xx_pci.c | 5
> 7 files changed, 975 insertions(+), 1 deletion(-)
>
> diff --git a/arch/ppc/Kconfig b/arch/ppc/Kconfig
> --- a/arch/ppc/Kconfig
> +++ b/arch/ppc/Kconfig
> @@ -731,7 +731,7 @@ endchoice
>
> config PQ2ADS
> bool
> - depends on ADS8272
> + depends on ADS8272 || PQ2FADS
> default y
>
> config TQM8xxL
> diff --git a/arch/ppc/configs/pq2fads_defconfig b/arch/ppc/configs/pq2fads_defconfig
> new file mode 100644
> --- /dev/null
> +++ b/arch/ppc/configs/pq2fads_defconfig
> @@ -0,0 +1,712 @@
> +#
> +# Automatically generated make config: don't edit
> +# Linux kernel version: 2.6.10_mvl401
> +# Thu Mar 23 14:28:38 2006
> +#
> +CONFIG_MMU=y
> +CONFIG_GENERIC_HARDIRQS=y
> +CONFIG_RWSEM_GENERIC_SPINLOCK=y
> +CONFIG_ASM_SEMAPHORES=y
> +CONFIG_HAVE_DEC_LOCK=y
> +CONFIG_PPC=y
> +CONFIG_PPC32=y
> +CONFIG_GENERIC_NVRAM=y
> +
> +#
> +# Code maturity level options
> +#
> +CONFIG_EXPERIMENTAL=y
> +CONFIG_CLEAN_COMPILE=y
> +CONFIG_BROKEN_ON_SMP=y
> +
> +#
> +# General setup
> +#
> +CONFIG_LOCALVERSION=""
> +CONFIG_SWAP=y
> +CONFIG_SYSVIPC=y
> +CONFIG_SYSVIPC_SEMMNI=128
> +CONFIG_SYSVIPC_SEMMSL=250
> +# CONFIG_POSIX_MQUEUE is not set
> +# CONFIG_BSD_PROCESS_ACCT is not set
> +CONFIG_SYSCTL=y
> +# CONFIG_AUDIT is not set
> +CONFIG_LOG_BUF_SHIFT=14
> +# CONFIG_HOTPLUG is not set
> +CONFIG_KOBJECT_UEVENT=y
> +# CONFIG_IKCONFIG is not set
> +CONFIG_EMBEDDED=y
> +# CONFIG_KALLSYMS is not set
> +CONFIG_FUTEX=y
> +# CONFIG_EPOLL is not set
> +# CONFIG_CC_OPTIMIZE_FOR_SIZE is not set
> +CONFIG_SHMEM=y
> +CONFIG_CC_ALIGN_FUNCTIONS=0
> +CONFIG_CC_ALIGN_LABELS=0
> +CONFIG_CC_ALIGN_LOOPS=0
> +CONFIG_CC_ALIGN_JUMPS=0
> +# CONFIG_BOOT_FLIGHT_RECORDER is not set
> +CONFIG_LOCKLESS=y
> +CONFIG_BOOT_FLIGHT_BUFFERS=4
> +CONFIG_BOOT_FLIGHT_SIZE=524288
> +CONFIG_FLIGHT_PROC_BUFFERS=8
> +CONFIG_FLIGHT_PROC_SIZE=8192
> +CONFIG_NEWEV=y
> +CONFIG_CSTM=y
> +# CONFIG_TINY_SHMEM is not set
> +
> +#
> +# Loadable module support
> +#
> +# CONFIG_MODULES is not set
> +
> +#
> +# Processor
> +#
> +CONFIG_6xx=y
> +# CONFIG_40x is not set
> +# CONFIG_44x is not set
> +# CONFIG_POWER3 is not set
> +# CONFIG_POWER4 is not set
> +# CONFIG_8xx is not set
> +# CONFIG_E200 is not set
> +# CONFIG_E500 is not set
> +CONFIG_PPC_FPU=y
> +# CONFIG_CPU_FREQ is not set
> +CONFIG_EMBEDDEDBOOT=y
> +CONFIG_PPC_STD_MMU=y
> +
> +#
> +# Platform options
> +#
> +
> +#
> +# Freescale Ethernet driver platform-specific options
> +#
> +# CONFIG_PPC_MULTIPLATFORM is not set
> +# CONFIG_APUS is not set
> +# CONFIG_KATANA is not set
> +# CONFIG_WILLOW is not set
> +# CONFIG_CPCI690 is not set
> +# CONFIG_PCORE is not set
> +# CONFIG_POWERPMC250 is not set
> +# CONFIG_CHESTNUT is not set
> +# CONFIG_SPRUCE is not set
> +# CONFIG_EV64260 is not set
> +# CONFIG_LOPEC is not set
> +# CONFIG_MCPN765 is not set
> +# CONFIG_MVME5100 is not set
> +# CONFIG_PPLUS is not set
> +# CONFIG_PRPMC750 is not set
> +# CONFIG_PRPMC800 is not set
> +# CONFIG_SANDPOINT is not set
> +# CONFIG_ADIR is not set
> +# CONFIG_K2 is not set
> +# CONFIG_PAL4 is not set
> +# CONFIG_GEMINI is not set
> +# CONFIG_EST8260 is not set
> +# CONFIG_SBC82xx is not set
> +# CONFIG_SBS8260 is not set
> +# CONFIG_RPX8260 is not set
> +# CONFIG_TQM8260 is not set
> +# CONFIG_ADS8272 is not set
> +CONFIG_PQ2FADS=y
> +# CONFIG_LITE5200 is not set
> +# CONFIG_MPC834x_SYS is not set
> +CONFIG_PQ2ADS=y
> +CONFIG_8260=y
> +CONFIG_CPM2=y
> +# CONFIG_PC_KEYBOARD is not set
> +# CONFIG_SMP is not set
> +CONFIG_PREEMPT_NONE=y
> +# CONFIG_PREEMPT_VOLUNTARY is not set
> +# CONFIG_PREEMPT_DESKTOP is not set
> +# CONFIG_PREEMPT_RT is not set
> +# CONFIG_PREEMPT_SOFTIRQS is not set
> +# CONFIG_PREEMPT_HARDIRQS is not set
> +# CONFIG_PREEMPT_BKL is not set
> +# CONFIG_HIGHMEM is not set
> +# CONFIG_HIGH_RES_TIMERS is not set
> +CONFIG_BINFMT_ELF=y
> +# CONFIG_BINFMT_MISC is not set
> +# CONFIG_CMDLINE_BOOL is not set
> +
> +#
> +# Bus options
> +#
> +CONFIG_PCI=y
> +CONFIG_PCI_DOMAINS=y
> +CONFIG_PCI_8260=y
> +# CONFIG_8260_PCI9 is not set
> +# CONFIG_PCI_LEGACY_PROC is not set
> +# CONFIG_PCI_NAMES 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_BOOT_LOAD=0x00400000
> +
> +#
> +# Device Drivers
> +#
> +
> +#
> +# Generic Driver Options
> +#
> +CONFIG_STANDALONE=y
> +CONFIG_PREVENT_FIRMWARE_BUILD=y
> +
> +#
> +# Memory Technology Devices (MTD)
> +#
> +# CONFIG_MTD is not set
> +
> +#
> +# Parallel port support
> +#
> +# CONFIG_PARPORT is not set
> +
> +#
> +# Plug and Play support
> +#
> +
> +#
> +# Block devices
> +#
> +# CONFIG_BLK_DEV_FD is not set
> +# CONFIG_BLK_CPQ_DA is not set
> +# CONFIG_BLK_CPQ_CISS_DA is not set
> +# CONFIG_BLK_DEV_DAC960 is not set
> +# CONFIG_BLK_DEV_UMEM 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_SX8 is not set
> +CONFIG_BLK_DEV_RAM=y
> +CONFIG_BLK_DEV_RAM_COUNT=16
> +CONFIG_BLK_DEV_RAM_SIZE=32768
> +CONFIG_BLK_DEV_INITRD=y
> +CONFIG_INITRAMFS_SOURCE=""
> +# CONFIG_LBD is not set
> +# CONFIG_CDROM_PKTCDVD is not set
> +
> +#
> +# IO Schedulers
> +#
> +CONFIG_IOSCHED_NOOP=y
> +CONFIG_IOSCHED_AS=y
> +CONFIG_IOSCHED_DEADLINE=y
> +CONFIG_IOSCHED_CFQ=y
> +
> +#
> +# ATA/ATAPI/MFM/RLL support
> +#
> +# CONFIG_IDE is not set
> +
> +#
> +# SCSI device support
> +#
> +# CONFIG_SCSI is not set
> +
> +#
> +# Multi-device support (RAID and LVM)
> +#
> +# CONFIG_MD is not set
> +
> +#
> +# Fusion MPT device support
> +#
> +
> +#
> +# IEEE 1394 (FireWire) support
> +#
> +# CONFIG_IEEE1394 is not set
> +
> +#
> +# I2O device support
> +#
> +# CONFIG_I2O is not set
> +
> +#
> +# Macintosh device drivers
> +#
> +
> +#
> +# Networking support
> +#
> +CONFIG_NET=y
> +
> +#
> +# Networking options
> +#
> +CONFIG_PACKET=y
> +# CONFIG_PACKET_MMAP is not set
> +# CONFIG_NETLINK_DEV is not set
> +CONFIG_UNIX=y
> +# CONFIG_NET_KEY is not set
> +CONFIG_USE_POLICY_FWD=y
> +CONFIG_INET=y
> +CONFIG_IP_MULTICAST=y
> +# CONFIG_IP_ADVANCED_ROUTER is not set
> +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_IP_MROUTE is not set
> +# CONFIG_ARPD is not set
> +CONFIG_SYN_COOKIES=y
> +# CONFIG_INET_AH is not set
> +# CONFIG_INET_ESP is not set
> +# CONFIG_INET_IPCOMP is not set
> +# CONFIG_INET_TUNNEL is not set
> +CONFIG_IP_TCPDIAG=y
> +# CONFIG_IP_TCPDIAG_IPV6 is not set
> +# CONFIG_IPV6 is not set
> +# CONFIG_NETFILTER is not set
> +
> +#
> +# SCTP Configuration (EXPERIMENTAL)
> +#
> +# CONFIG_IP_SCTP 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_NET_DIVERT 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
> +# CONFIG_NET_CLS_ROUTE is not set
> +
> +#
> +# Network testing
> +#
> +# CONFIG_NET_PKTGEN is not set
> +# CONFIG_NETPOLL is not set
> +# CONFIG_NET_POLL_CONTROLLER is not set
> +# CONFIG_HAMRADIO is not set
> +# CONFIG_IRDA is not set
> +# CONFIG_BT is not set
> +# CONFIG_IEEE80211 is not set
> +CONFIG_NETDEVICES=y
> +# CONFIG_DUMMY is not set
> +# CONFIG_BONDING is not set
> +# CONFIG_EQUALIZER is not set
> +# CONFIG_TUN is not set
> +
> +#
> +# ARCnet devices
> +#
> +# CONFIG_ARCNET is not set
> +
> +#
> +# PHY device support
> +#
> +# CONFIG_PHYLIB is not set
> +
> +#
> +# Ethernet (10 or 100Mbit)
> +#
> +CONFIG_NET_ETHERNET=y
> +CONFIG_MII=y
> +# CONFIG_HAPPYMEAL is not set
> +# CONFIG_SUNGEM is not set
> +# CONFIG_NET_VENDOR_3COM is not set
> +
> +#
> +# Tulip family network device support
> +#
> +# CONFIG_NET_TULIP is not set
> +# CONFIG_HP100 is not set
> +
> +#
> +# Broadcom network devices
> +#
> +# CONFIG_HND is not set
> +# CONFIG_NET_PCI is not set
> +CONFIG_FS_ENET=y
> +# CONFIG_FS_ENET_HAS_SCC is not set
> +CONFIG_FS_ENET_HAS_FCC=y
> +
> +#
> +# Ethernet (1000 Mbit)
> +#
> +# CONFIG_ACENIC is not set
> +# CONFIG_DL2K is not set
> +# CONFIG_E1000 is not set
> +# CONFIG_NS83820 is not set
> +# CONFIG_HAMACHI is not set
> +# CONFIG_YELLOWFIN is not set
> +# CONFIG_R8169 is not set
> +# CONFIG_SK98LIN is not set
> +# CONFIG_TIGON3 is not set
> +
> +#
> +# Ethernet (10000 Mbit)
> +#
> +# CONFIG_IXGB is not set
> +# CONFIG_S2IO is not set
> +
> +#
> +# Token Ring devices
> +#
> +# CONFIG_TR is not set
> +
> +#
> +# Wireless LAN (non-hamradio)
> +#
> +# CONFIG_NET_RADIO is not set
> +
> +#
> +# Wan interfaces
> +#
> +# CONFIG_WAN is not set
> +# CONFIG_FDDI is not set
> +# CONFIG_HIPPI is not set
> +# CONFIG_PPP is not set
> +# CONFIG_SLIP is not set
> +# CONFIG_SHAPER is not set
> +# CONFIG_NETCONSOLE is not set
> +
> +#
> +# ISDN subsystem
> +#
> +# CONFIG_ISDN is not set
> +
> +#
> +# Telephony Support
> +#
> +# CONFIG_PHONE is not set
> +
> +#
> +# Input device support
> +#
> +CONFIG_INPUT=y
This is useless for the board iirc.
> +
> +#
> +# Userland interfaces
> +#
> +# CONFIG_INPUT_MOUSEDEV is not set
> +# CONFIG_INPUT_JOYDEV is not set
> +# CONFIG_INPUT_TSDEV is not set
> +# CONFIG_INPUT_TSLIBDEV is not set
> +# CONFIG_INPUT_EVDEV is not set
> +# CONFIG_INPUT_EVBUG is not set
> +
> +#
> +# Input I/O drivers
> +#
> +# CONFIG_GAMEPORT is not set
> +CONFIG_SOUND_GAMEPORT=y
ditto.
> +# CONFIG_SERIO is not set
> +# CONFIG_SERIO_I8042 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_TOUCHSCREEN is not set
> +# CONFIG_INPUT_MISC is not set
> +
> +#
> +# Character devices
> +#
> +# CONFIG_VT is not set
> +# CONFIG_SERIAL_NONSTANDARD is not set
> +
> +#
> +# Serial drivers
> +#
> +# CONFIG_SERIAL_8250 is not set
> +
> +#
> +# Non-8250 serial port support
> +#
> +CONFIG_SERIAL_CORE=y
> +CONFIG_SERIAL_CORE_CONSOLE=y
> +CONFIG_SERIAL_CPM=y
> +CONFIG_SERIAL_CPM_CONSOLE=y
> +CONFIG_SERIAL_CPM_SCC1=y
> +CONFIG_SERIAL_CPM_SCC2=y
> +# CONFIG_SERIAL_CPM_SCC3 is not set
> +# CONFIG_SERIAL_CPM_SCC4 is not set
> +# CONFIG_SERIAL_CPM_SMC1 is not set
> +# CONFIG_SERIAL_CPM_SMC2 is not set
> +CONFIG_UNIX98_PTYS=y
> +CONFIG_LEGACY_PTYS=y
> +CONFIG_LEGACY_PTY_COUNT=256
> +
> +#
> +# IPMI
> +#
> +# CONFIG_IPMI_HANDLER is not set
> +
> +#
> +# Watchdog Cards
> +#
> +# CONFIG_WATCHDOG is not set
> +# CONFIG_NVRAM is not set
> +# CONFIG_BLOCKER is not set
> +CONFIG_GEN_RTC=y
> +# CONFIG_GEN_RTC_X is not set
> +# CONFIG_DTLK is not set
> +# CONFIG_R3964 is not set
> +# CONFIG_APPLICOM is not set
> +
> +#
> +# Ftape, the floppy tape device driver
> +#
> +# CONFIG_AGP is not set
> +# CONFIG_DRM is not set
> +# CONFIG_RAW_DRIVER is not set
> +
> +#
> +# I2C support
> +#
> +# CONFIG_I2C is not set
> +
> +#
> +# SPI support
> +#
> +# CONFIG_SPI is not set
> +# CONFIG_SPI_MASTER is not set
> +
> +#
> +# Dallas's 1-wire bus
> +#
> +# CONFIG_W1 is not set
> +
> +#
> +# Misc devices
> +#
> +
> +#
> +# Multimedia Capabilities Port drivers
> +#
> +
> +#
> +# Multimedia devices
> +#
> +# CONFIG_VIDEO_DEV is not set
> +
> +#
> +# Digital Video Broadcasting Devices
> +#
> +# CONFIG_DVB is not set
> +
> +#
> +# Graphics support
> +#
> +# CONFIG_FB is not set
> +
> +#
> +# Sound
> +#
> +# CONFIG_SOUND is not set
> +
> +#
> +# USB support
> +#
> +# CONFIG_USB is not set
> +CONFIG_USB_ARCH_HAS_HCD=y
> +CONFIG_USB_ARCH_HAS_OHCI=y
Not sure this is required as well.
> +
> +#
> +# NOTE: USB_STORAGE enables SCSI, and 'SCSI disk support' may also be needed; see USB_STORAGE Help for more information
> +#
> +
> +#
> +# USB Gadget Support
> +#
> +# CONFIG_USB_GADGET is not set
> +
> +#
> +# MMC/SD Card support
> +#
> +# CONFIG_MMC is not set
> +
> +#
> +# Synchronous Serial Interfaces (SSI)
> +#
> +
> +#
> +# File systems
> +#
> +CONFIG_EXT2_FS=y
> +# CONFIG_EXT2_FS_XATTR is not set
> +CONFIG_EXT3_FS=y
> +CONFIG_EXT3_FS_XATTR=y
> +# CONFIG_EXT3_FS_POSIX_ACL is not set
> +# CONFIG_EXT3_FS_SECURITY is not set
> +CONFIG_JBD=y
> +# CONFIG_JBD_DEBUG is not set
> +CONFIG_FS_MBCACHE=y
> +# CONFIG_REISERFS_FS is not set
> +# CONFIG_JFS_FS is not set
> +# CONFIG_XFS_FS is not set
> +# CONFIG_MINIX_FS is not set
> +# CONFIG_ROMFS_FS is not set
> +# CONFIG_QUOTA is not set
> +CONFIG_DNOTIFY=y
> +# CONFIG_AUTOFS_FS is not set
> +# CONFIG_AUTOFS4_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_SYSFS=y
> +# CONFIG_DEVFS_FS is not set
> +# CONFIG_DEVPTS_FS_XATTR is not set
> +CONFIG_TMPFS=y
> +# CONFIG_TMPFS_XATTR is not set
> +# CONFIG_HUGETLB_PAGE is not set
> +CONFIG_RAMFS=y
> +# CONFIG_RELAYFS_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_JFFS2_COMPRESSION_OPTIONS 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
> +# CONFIG_YAFFS_FS is not set
> +# CONFIG_YAFFS1_FS is not set
> +
> +#
> +# Network File Systems
> +#
> +CONFIG_NFS_FS=y
> +# CONFIG_NFS_V3 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_EXPORTFS is not set
> +CONFIG_SUNRPC=y
> +# CONFIG_RPCSEC_GSS_KRB5 is not set
> +# CONFIG_RPCSEC_GSS_SPKM3 is not set
> +# CONFIG_SMB_FS is not set
> +# CONFIG_CIFS is not set
> +# CONFIG_NCP_FS is not set
> +# CONFIG_CODA_FS is not set
> +# CONFIG_AFS_FS is not set
> +
> +#
> +# Partition Types
> +#
> +CONFIG_PARTITION_ADVANCED=y
> +# CONFIG_ACORN_PARTITION is not set
> +# CONFIG_OSF_PARTITION is not set
> +# CONFIG_AMIGA_PARTITION is not set
> +# CONFIG_ATARI_PARTITION is not set
> +# CONFIG_MAC_PARTITION is not set
> +# CONFIG_MSDOS_PARTITION is not set
> +# CONFIG_LDM_PARTITION is not set
> +# CONFIG_SGI_PARTITION is not set
> +# CONFIG_ULTRIX_PARTITION is not set
> +# CONFIG_SUN_PARTITION is not set
> +# CONFIG_EFI_PARTITION is not set
> +
> +#
> +# Native Language Support
> +#
> +# CONFIG_NLS is not set
> +# CONFIG_SCC_ENET is not set
> +# CONFIG_FEC_ENET is not set
> +
> +#
> +# CPM2 Options
> +#
> +
> +#
> +# Library routines
> +#
> +# CONFIG_CRC_CCITT is not set
> +# CONFIG_CRC32 is not set
> +# CONFIG_LIBCRC32C is not set
> +
> +#
> +# Fast Real-Time Domain
> +#
> +# CONFIG_FRD is not set
> +
> +#
> +# Fast Real-Time Domain Advanced Options
> +#
> +
> +#
> +# Profiling support
> +#
> +# CONFIG_PROFILING is not set
> +
> +#
> +# MontaVista System tools
> +#
> +# CONFIG_ILATENCY is not set
> +
> +#
> +# Kernel hacking
> +#
> +# CONFIG_DEBUG_KERNEL is not set
> +# CONFIG_WAKEUP_TIMING is not set
> +# CONFIG_CRITICAL_IRQSOFF_TIMING is not set
> +
> +#
> +# Security options
> +#
> +# CONFIG_KEYS is not set
> +# CONFIG_SECURITY is not set
> +
> +#
> +# Cryptographic options
> +#
> +# CONFIG_CRYPTO is not set
> diff --git a/arch/ppc/platforms/Makefile b/arch/ppc/platforms/Makefile
> --- a/arch/ppc/platforms/Makefile
> +++ b/arch/ppc/platforms/Makefile
> @@ -21,6 +21,7 @@ obj-$(CONFIG_MVME5100) += mvme5100.o
> obj-$(CONFIG_PAL4) += pal4_setup.o pal4_pci.o
> obj-$(CONFIG_POWERPMC250) += powerpmc250.o
> obj-$(CONFIG_PPLUS) += pplus.o
> +obj-$(CONFIG_PQ2FADS) += pq2fads_setup.o
> obj-$(CONFIG_PRPMC750) += prpmc750.o
> obj-$(CONFIG_PRPMC800) += prpmc800.o
> obj-$(CONFIG_RADSTONE_PPC7D) += radstone_ppc7d.o
> diff --git a/arch/ppc/platforms/pq2ads.h b/arch/ppc/platforms/pq2ads.h
> --- a/arch/ppc/platforms/pq2ads.h
> +++ b/arch/ppc/platforms/pq2ads.h
> @@ -15,6 +15,8 @@
>
> #if defined(CONFIG_ADS8272)
> #define BOARD_CHIP_NAME "8272"
> +#elif defined(CONFIG_PQ2FADS)
> +#define BOARD_CHIP_NAME "8280"
> #endif
>
> /* Memory map is configured by the PROM startup.
> @@ -25,7 +27,11 @@
> #define BCSR_ADDR ((uint)0xf4500000)
> #define BCSR_SIZE ((uint)(32 * 1024))
>
> +#ifdef CONFIG_PQ2FADS
> +#define BOOTROM_RESTART_ADDR ((uint)0xfff40004)
> +#else
> #define BOOTROM_RESTART_ADDR ((uint)0xff000104)
> +#endif
>
> /* For our show_cpuinfo hooks. */
> #define CPUINFO_VENDOR "Motorola"
> @@ -45,7 +51,11 @@
> #define BCSR1_RS232_EN1 ((uint)0x02000000) /* 0 == enable */
> #define BCSR1_RS232_EN2 ((uint)0x01000000) /* 0 == enable */
> #define BCSR3_FETHIEN2 ((uint)0x10000000) /* 0 == enable */
> +#ifdef CONFIG_PQ2FADS
> +#define BCSR3_FETH2_RST ((uint)0x08000000) /* 0 == reset */
> +#else
> #define BCSR3_FETH2_RST ((uint)0x80000000) /* 0 == reset */
> +#endif
>
> #define PHY_INTERRUPT SIU_INT_IRQ7
>
> diff --git a/arch/ppc/platforms/pq2ads_pd.h b/arch/ppc/platforms/pq2ads_pd.h
> --- a/arch/ppc/platforms/pq2ads_pd.h
> +++ b/arch/ppc/platforms/pq2ads_pd.h
> @@ -21,13 +21,23 @@
>
> /* FCC2 Clock Source Configuration. These can be redefined in the board specific file.
> Can only choose from CLK13-16 */
> +#ifdef CONFIG_PQ2FADS
> +#define F2_RXCLK 13
> +#define F2_TXCLK 14
> +#else
> #define F2_RXCLK 15
> #define F2_TXCLK 16
> +#endif
>
Hmm, this should go into the board-specific header - here should exist just a "reasonable default" (pq2ads.h in this context).
> /* FCC3 Clock Source Configuration. These can be redefined in the board specific file.
> Can only choose from CLK13-16 */
> +#ifdef CONFIG_PQ2FADS
> +#define F3_RXCLK 15
> +#define F3_TXCLK 16
> +#else
> #define F3_RXCLK 13
> #define F3_TXCLK 14
> +#endif
>
ditto.
> /* Automatically generates register configurations */
> #define PC_CLK(x) ((uint)(1<<(x-1))) /* FCC CLK I/O ports */
> @@ -110,5 +120,6 @@
> #define FCC_MEM_OFFSET(x) (CPM_FCC_SPECIAL_BASE + (x*128))
> #define FCC1_MEM_OFFSET FCC_MEM_OFFSET(0)
> #define FCC2_MEM_OFFSET FCC_MEM_OFFSET(1)
> +#define FCC3_MEM_OFFSET FCC_MEM_OFFSET(2)
>
> #endif
> diff --git a/arch/ppc/platforms/pq2fads_setup.c b/arch/ppc/platforms/pq2fads_setup.c
> new file mode 100644
> --- /dev/null
> +++ b/arch/ppc/platforms/pq2fads_setup.c
> @@ -0,0 +1,235 @@
> +/*
> + * arch/ppc/platforms/pq2fads_setup.c
> + *
> + * PQ2FADS Board-specific Platform Device descriptions
> + *
> + * 2006 (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 <linux/module.h>
> +#include <linux/device.h>
> +#include <linux/ioport.h>
> +#include <linux/fs_enet_pd.h>
> +
> +#include <asm/io.h>
> +#include <asm/mpc8260.h>
> +#include <asm/cpm2.h>
> +#include <asm/immap_cpm2.h>
> +#include <asm/irq.h>
> +#include <asm/ppc_sys.h>
> +#include <asm/ppcboot.h>
> +#include <asm/delay.h>
> +
> +#include "pq2ads_pd.h"
> +
> +void ppc_sys_device_enable(enum ppc_sys_devices);
> +static void init_fcc2_ioports(void);
> +static void init_fcc3_ioports(void);
> +
> +static struct fs_mii_bus_info mii_bus_info = {
> + .method = fsmii_bitbang,
> + .id = 0,
> + .i.bitbang = {
> + .mdio_port = fsiop_portc,
> + .mdc_port = fsiop_portc,
> + .mdio_bit = 9,
> + .mdc_bit = 10,
> + .delay = 1,
> + },
> +};
> +
> +/* First Ethernet Port - FCC2 */
> +static struct fs_platform_info mpc82xx_fcc2_pdata = {
> + .fs_no = fsid_fcc2,
> + .cp_page = CPM_CR_FCC2_PAGE,
> + .cp_block = CPM_CR_FCC2_SBLOCK,
> + .clk_trx = (PC_F2RXCLK | PC_F2TXCLK),
> + .clk_route = CMX2_CLK_ROUTE,
> + .clk_mask = CMX2_CLK_MASK,
> + .init_ioports = init_fcc2_ioports,
> +
> + .phy_addr = 0,
> +#ifdef PHY_INTERRUPT
> + .phy_irq = PHY_INTERRUPT,
> +#else
> + .phy_irq = -1;
> +#endif
> + .mem_offset = FCC2_MEM_OFFSET,
> + .bus_info = &mii_bus_info,
> + .rx_ring = 32,
> + .tx_ring = 32,
> + .rx_copybreak = 240,
> + .use_napi = 0,
> + .napi_weight = 17,
> +};
> +
> +/* Second Ethernet Port - FCC3 */
> +static struct fs_platform_info mpc82xx_fcc3_pdata = {
> + .fs_no = fsid_fcc3,
> + .cp_page = CPM_CR_FCC3_PAGE,
> + .cp_block = CPM_CR_FCC3_SBLOCK,
> + .clk_trx = (PC_F3RXCLK | PC_F3TXCLK),
> + .clk_route = CMX3_CLK_ROUTE,
> + .clk_mask = CMX3_CLK_MASK,
> + .init_ioports = init_fcc3_ioports,
> +
> + .phy_addr = 3,
> +#ifdef PHY_INTERRUPT
> + .phy_irq = PHY_INTERRUPT,
> +#else
> + .phy_irq = -1;
> +#endif
> + .mem_offset = FCC3_MEM_OFFSET,
> + .bus_info = &mii_bus_info,
> + .rx_ring = 32,
> + .tx_ring = 32,
> + .rx_copybreak = 240,
> + .use_napi = 0,
> + .napi_weight = 17,
> +};
> +
> +static void init_fcc2_ioports(void)
> +{
> + struct io_port *io;
> + u32 tempval;
> + cpm2_map_t* immap = ioremap(CPM_MAP_ADDR, sizeof(cpm2_map_t));
> + u32 *bcsr = ioremap(BCSR_ADDR+4, sizeof(u32));
> +
> + io = &immap->im_ioport;
> +
> + /* Enable the PHY */
> + clrbits32(bcsr, BCSR1_FETHIEN);
> + setbits32(bcsr, BCSR1_FETH_RST);
> +
> + /* FCC2 pins are on port B/C. */
> + /* Configure port B and C pins for FCC2 Ethernet. */
> +
> + tempval = in_be32(&io->iop_pdirb);
> + tempval &= ~PB2_DIRB0;
> + tempval |= PB2_DIRB1;
> + out_be32(&io->iop_pdirb, tempval);
> +
> + tempval = in_be32(&io->iop_psorb);
> + tempval &= ~PB2_PSORB0;
> + tempval |= PB2_PSORB1;
> + out_be32(&io->iop_psorb, tempval);
> +
> + setbits32(&io->iop_pparb,PB2_DIRB0 | PB2_DIRB1);
> +
> + tempval = PC_F2RXCLK|PC_F2TXCLK;
> +
> + /* Alter clocks */
> + clrbits32(&io->iop_psorc,tempval);
> + clrbits32(&io->iop_pdirc,tempval);
> + setbits32(&io->iop_pparc,tempval);
> +
> + clrbits32(&immap->im_cpmux.cmx_fcr, CMX2_CLK_MASK);
> + setbits32(&immap->im_cpmux.cmx_fcr, CMX2_CLK_ROUTE);
> +
> + iounmap(bcsr);
> + iounmap(immap);
> +}
> +
> +static void init_fcc3_ioports(void)
> +{
> + struct io_port *io;
> + u32 tempval;
> + cpm2_map_t* immap = ioremap(CPM_MAP_ADDR, sizeof(cpm2_map_t));
> + u32 *bcsr = ioremap(BCSR_ADDR+12, sizeof(u32));
> +
> + io = &immap->im_ioport;
> +
> + /* Enable the PHY */
> + clrbits32(bcsr, BCSR3_FETHIEN2);
> + setbits32(bcsr, BCSR3_FETH2_RST);
> +
> + /* FCC3 pins are on port B/C. */
> + /* Configure port B and C pins for FCC3 Ethernet. */
> +
> + tempval = in_be32(&io->iop_pdirb);
> + tempval &= ~PB3_DIRB0;
> + tempval |= PB3_DIRB1;
> + out_be32(&io->iop_pdirb, tempval);
> +
> + tempval = in_be32(&io->iop_psorb);
> + tempval &= ~PB3_PSORB0;
> + tempval |= PB3_PSORB1;
> + out_be32(&io->iop_psorb, tempval);
> +
> + setbits32(&io->iop_pparb,PB3_DIRB0 | PB3_DIRB1);
> +
> + /* Alter clocks */
> + tempval = PC_F3TXCLK|PC_F3RXCLK;
> +
> + clrbits32(&io->iop_psorc, tempval);
> + clrbits32(&io->iop_pdirc, tempval);
> + setbits32(&io->iop_pparc, tempval);
> +
> + clrbits32(&immap->im_cpmux.cmx_fcr, CMX3_CLK_MASK);
> + setbits32(&immap->im_cpmux.cmx_fcr, CMX3_CLK_ROUTE);
> +
> + iounmap(bcsr);
> + iounmap(immap);
> +}
> +
> +static void __init pq2fads_fixup_enet_pdata(struct platform_device *pdev,
> + int idx)
> +{
> + bd_t* bi = (void*)__res;
> + int fs_no = fsid_fcc1+pdev->id-1;
> +
> + mpc82xx_fcc3_pdata.dpram_offset = mpc82xx_fcc2_pdata.dpram_offset = (u32)cpm2_immr->im_dprambase;
> + mpc82xx_fcc3_pdata.fcc_regs_c = mpc82xx_fcc2_pdata.fcc_regs_c = (u32)cpm2_immr->im_fcc_c;
> +
> + switch(fs_no) {
> + case fsid_fcc2:
> + memcpy(&mpc82xx_fcc2_pdata.macaddr,bi->bi_enetaddr,6);
> + pdev->dev.platform_data = &mpc82xx_fcc2_pdata;
> + break;
> + case fsid_fcc3:
> + memcpy(&mpc82xx_fcc3_pdata.macaddr,bi->bi_enetaddr,6);
> + mpc82xx_fcc3_pdata.macaddr[5] ^= 1;
> + pdev->dev.platform_data = &mpc82xx_fcc3_pdata;
> + break;
> + }
> +}
> +
> +static int pq2fads_platform_notify(struct device *dev)
> +{
> + static const struct platform_notify_dev_map dev_map[] = {
> + {
> + .bus_id = "fsl-cpm-fcc",
> + .rtn = pq2fads_fixup_enet_pdata
> + },
> + {
> + .bus_id = NULL
> + }
> + };
> + platform_notify_map(dev_map,dev);
> +
> + return 0;
> +
> +}
> +
> +int __init pq2fads_init(void)
> +{
> + printk(KERN_NOTICE "pq2fads: Init\n");
> +
> + platform_notify = pq2fads_platform_notify;
> +
> + ppc_sys_device_initfunc();
> +
> + ppc_sys_device_disable_all();
> + ppc_sys_device_enable(MPC82xx_CPM_FCC2);
> + ppc_sys_device_enable(MPC82xx_CPM_FCC3);
> +
> + return 0;
> +}
> +
> +arch_initcall(pq2fads_init);
> diff --git a/arch/ppc/syslib/m82xx_pci.c b/arch/ppc/syslib/m82xx_pci.c
> --- a/arch/ppc/syslib/m82xx_pci.c
> +++ b/arch/ppc/syslib/m82xx_pci.c
> @@ -279,8 +279,13 @@ pq2ads_setup_pci(struct pci_controller *
> immap->im_pci.pci_pobar2 = cpu_to_le32((M82xx_PCI_LOWER_MEM - M82xx_PCI_MEM_OFFSET) >> POTA_ADDR_SHIFT);
>
> /* Inbound transactions from PCI memory space */
> +#ifdef CONFIG_PQ2FADS
> + immap->im_pci.pci_picmr0 = cpu_to_le32(PICMR_ENABLE |
> + ((~(M82xx_PCI_SLAVE_MEM_SIZE-1U)) >> PITA_ADDR_SHIFT));
> +#else
> immap->im_pci.pci_picmr0 = cpu_to_le32(PICMR_ENABLE | PICMR_PREFETCH_EN |
> ((~(M82xx_PCI_SLAVE_MEM_SIZE-1U)) >> PITA_ADDR_SHIFT));
> +#endif
> immap->im_pci.pci_pibar0 = cpu_to_le32(M82xx_PCI_SLAVE_MEM_BUS >> PITA_ADDR_SHIFT);
> immap->im_pci.pci_pitar0 = cpu_to_le32(M82xx_PCI_SLAVE_MEM_LOCAL>> PITA_ADDR_SHIFT);
>
>
>
--
Sincerely,
Vitaly
^ permalink raw reply
* [PATCH] spufs: fix compile
From: Christoph Hellwig @ 2006-04-06 13:48 UTC (permalink / raw)
To: arndb; +Cc: linuxppc-dev
The current tree isn't exctly sure about the arguments to
alloc_spu_context, let it agree on the no-arguments version.
Signed-off-by: Christoph Hellwig <hch@lst.de>
Index: linux-2.6/arch/powerpc/platforms/cell/spufs/inode.c
===================================================================
--- linux-2.6.orig/arch/powerpc/platforms/cell/spufs/inode.c 2006-04-06 10:28:08.000000000 +0200
+++ linux-2.6/arch/powerpc/platforms/cell/spufs/inode.c 2006-04-06 15:45:36.000000000 +0200
@@ -241,7 +241,7 @@
inode->i_gid = dir->i_gid;
inode->i_mode &= S_ISGID;
}
- ctx = alloc_spu_context(inode->i_mapping);
+ ctx = alloc_spu_context();
SPUFS_I(inode)->i_ctx = ctx;
if (!ctx)
goto out_iput;
^ permalink raw reply
* [PATCH] spufs: const fops
From: Christoph Hellwig @ 2006-04-06 13:50 UTC (permalink / raw)
To: arndb; +Cc: linuxppc
file_operations are const post-2.6.16, fix spufs_new_file to propagate
that properly.
Signed-off-by: Christoph Hellwig <hch@lst.de>
Index: linux-2.6/arch/powerpc/platforms/cell/spufs/inode.c
===================================================================
--- linux-2.6.orig/arch/powerpc/platforms/cell/spufs/inode.c 2006-04-06 11:48:33.000000000 +0200
+++ linux-2.6/arch/powerpc/platforms/cell/spufs/inode.c 2006-04-06 11:49:53.000000000 +0200
@@ -103,7 +103,7 @@
static int
spufs_new_file(struct super_block *sb, struct dentry *dentry,
- struct file_operations *fops, int mode,
+ const struct file_operations *fops, int mode,
struct spu_context *ctx)
{
static struct inode_operations spufs_file_iops = {
^ permalink raw reply
* SBC 8245 which architecture on kernel configuration ?
From: kevin morizur @ 2006-04-06 13:27 UTC (permalink / raw)
To: linuxppc-embedded
Hello everybody,
I use a MEN A12 SBC card with MPC8245 processor. I want to install a linux
kernel version 2.6.15 via ELDK 4.0. My Problem is that when i configure my
kernel with xconfig ARCH=ppc , i don't know if the architecture sbc82xx is
the right. When i choose this architecture i have compilation error when PCI
bus is select in the config menu. So if anyone works with SBC8245 and know
how to configure kernel or PCI bus or have a kernel with Power Pc SBC8245
support please help me.
Thanks.
Dear.
Kevin Morizur
_________________________________________________________________
Tout savoir sur la sécurité de vos enfants sur Internet !
http://go.msn.fr/10-channel/80-security/protection/default.asp
^ permalink raw reply
* Re: freescale lite 5200 board and kernel 2.6
From: Matthias Fechner @ 2006-04-06 9:32 UTC (permalink / raw)
To: Sylvain Munaut; +Cc: linuxppc-embedded
In-Reply-To: <44344F50.8010401@246tNt.com>
Hello Sylvain,
* Sylvain Munaut <tnt@246tNt.com> [06-04-06 01:14]:
> It made me realize the git commands I gave on my website were kinda
> wrong, I messed
> up git fetch and git pull among other things ...
ah that explains why I have some problems with git.
It seems that on the actual kernel-git-repository something has
changed (kernel.org).
The patch:
git pull http://gitbits.246tNt.com/gitbits/linux-2.6-mpc52xx.git master:mpc52xx
failed last week, so I used the complete repository from your side.
Maybe you can fix this problem, I will adapt then my wiki. :)
Matthias
--
"Programming today is a race between software engineers striving to build
bigger and better idiot-proof programs, and the universe trying to produce
bigger and better idiots. So far, the universe is winning." -- Rich Cook
^ permalink raw reply
* va_copy() support for powerpc
From: HappyPhot @ 2006-04-06 7:59 UTC (permalink / raw)
To: linuxppc-embedded
Hello,
I am trying use "ELDK 4" to build "xorp" for ppc 8xx, but it shows
"configure: error: cannot run test program while cross compiling"
when it checks whether the build environment has va_copy() support.
How to make the va_copy() be supported by powerpc or ELDK ?
Does anybody know this ?
thank you,
Phot
^ permalink raw reply
* Re: [PATCH] Set cpu explicitly in kernel compiles
From: Paul Mackerras @ 2006-04-06 4:37 UTC (permalink / raw)
To: Olaf Hering; +Cc: linuxppc-dev, trini
In-Reply-To: <20060402194044.GA866@suse.de>
Olaf Hering writes:
> --- linux-2.6.16-olh.orig/arch/powerpc/Makefile
> +++ linux-2.6.16-olh/arch/powerpc/Makefile
> @@ -107,6 +107,7 @@ endif
> cpu-as-$(CONFIG_PPC64BRIDGE) += -Wa,-mppc64bridge
> cpu-as-$(CONFIG_4xx) += -Wa,-m405
> cpu-as-$(CONFIG_6xx) += -Wa,-maltivec
> +cpu-as-$(CONFIG_6xx) += -mcpu=powerpc
Is this really the right place for this? The cpu-as- thing is really
for assembler options.
Paul.
^ permalink raw reply
* Re: freescale lite 5200 board and kernel 2.6
From: Sylvain Munaut @ 2006-04-05 23:14 UTC (permalink / raw)
To: linuxppc-embedded, idefix
In-Reply-To: <20060405212741.GC61331@server.idefix.loc>
Matthias Fechner wrote:
> Hello Domenico,
>
> * Domenico Andreoli <cavokz@gmail.com> [05-04-06 23:06]:
>
>> is there any patchset i can use for kernel 2.6? is it production-ready?
>> why isn't already in vanilla 2.6? has any sense to stay with kernel 2.4?
>>
>
> I'm not sure if this helps, but I was successfully in getting a kernel
> 2.6 running with the icecube board. I have written a short docu in my
> wiki (booting with tftp and rootnfs over NFS):
> http://wiki.idefix.fechner.net/index.php/IceCube#Writing_kernel_modules_for_2.6
>
> Maybe this will help.
> Please give me some feedback.
>
Nice !
It made me realize the git commands I gave on my website were kinda
wrong, I messed
up git fetch and git pull among other things ...
Sylvain
^ permalink raw reply
* Re: [PATCH] powerpc: Disable and EOI interrupts in machine_crash_shutdown()
From: Haren Myneni @ 2006-04-05 22:50 UTC (permalink / raw)
To: Michael Ellerman; +Cc: linuxppc-dev, Paul Mackerras, Milton Miller
In-Reply-To: <20060404114306.8DC0F679EF@ozlabs.org>
[-- Attachment #1: Type: text/plain, Size: 2775 bytes --]
linuxppc-dev-bounces+hbabu=us.ibm.com@ozlabs.org wrote on 04/04/2006
04:43:01 AM:
> We've seen several bugs caused by interrupt weirdness in the kdump
kernel.
> Panicking from an interrupt handler means we fail to EOI the interrupt,
and
> so the second kernel never gets that interrupt ever again. We also see
hangs
> on JS20 where we take interrupts in the second kernel early during boot.
>
> This patch fixes both those problems, and although it adds more code to
the
> crash path I think it is the best solution.
>
Michael,
Noticing the following issues when invoked kdump boot using
soft-reset. But the kdump boot is successful. Not a problem using sysrq-c
or Oops.
rtas_call retuned these error messages
"xics_disable_irq: irq=655360: ibm_set_xive(0xff) returned -3" for IRQ#
182
"xics_disable_irq: irq=589825: ibm_set_xive(0xff) returned -3" for IRQ#
216
cat /proc/interrupts
18: 2997 3401 1317 1442 XICS Edge IPI
134: 0 0 0 0 XICS Edge
ehci_hcd:usb1, ohci_hcd:usb2, ohci_hcd:usb3
167: 2169 0 0 0 XICS Edge ipr
182: 55 0 0 0 XICS Edge
hvc_console
216: 0 0 0 0 XICS Edge RAS_EPOW
BAD: 117
Thanks
Haren
> Signed-off-by: Michael Ellerman <michael@ellerman.id.au>
> ---
>
> arch/powerpc/kernel/crash.c | 13 +++++++++++++
> 1 file changed, 13 insertions(+)
>
> Index: kdump/arch/powerpc/kernel/crash.c
> ===================================================================
> --- kdump.orig/arch/powerpc/kernel/crash.c
> +++ kdump/arch/powerpc/kernel/crash.c
> @@ -22,6 +22,7 @@
> #include <linux/elf.h>
> #include <linux/elfcore.h>
> #include <linux/init.h>
> +#include <linux/irq.h>
> #include <linux/types.h>
>
> #include <asm/processor.h>
> @@ -174,6 +175,8 @@ static void crash_kexec_prepare_cpus(voi
>
> void default_machine_crash_shutdown(struct pt_regs *regs)
> {
> + unsigned int irq;
> +
> /*
> * This function is only called after the system
> * has paniced or is otherwise in a critical state.
> @@ -186,6 +189,16 @@ void default_machine_crash_shutdown(stru
> */
> local_irq_disable();
>
> + for_each_irq(irq) {
> + struct irq_desc *desc = irq_descp(irq);
> +
> + if (desc->status & IRQ_INPROGRESS)
> + desc->handler->end(irq);
> +
> + if (!(desc->status & IRQ_DISABLED))
> + desc->handler->disable(irq);
> + }
> +
> if (ppc_md.kexec_cpu_down)
> ppc_md.kexec_cpu_down(1, 0);
>
> _______________________________________________
> Linuxppc-dev mailing list
> Linuxppc-dev@ozlabs.org
> https://ozlabs.org/mailman/listinfo/linuxppc-dev
[-- Attachment #2: Type: text/html, Size: 4485 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