* Re: [PATCH 2/2] [POWERPC] Wire up sys_utimensat
From: Domen Puncer @ 2007-05-09 6:42 UTC (permalink / raw)
To: Stephen Rothwell; +Cc: ppc-dev, paulus
In-Reply-To: <20070509162442.11760e79.sfr@canb.auug.org.au>
On 09/05/07 16:24 +1000, Stephen Rothwell wrote:
>
> Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
> ---
> include/asm-powerpc/systbl.h | 1 +
> include/asm-powerpc/unistd.h | 3 ++-
> 2 files changed, 3 insertions(+), 1 deletions(-)
>
> This depends on the patch to declare {compat_}sys_utimensat
> --
> Cheers,
> Stephen Rothwell sfr@canb.auug.org.au
>
> diff --git a/include/asm-powerpc/unistd.h b/include/asm-powerpc/unistd.h
> index 2baedbe..2b11631 100644
> --- a/include/asm-powerpc/unistd.h
> +++ b/include/asm-powerpc/unistd.h
> @@ -326,10 +326,11 @@
> #define __NR_move_pages 301
> #define __NR_getcpu 302
> #define __NR_epoll_pwait 303
> +#define __NR_utimensat 303
^ 304?
Domen
>
> #ifdef __KERNEL__
>
> -#define __NR_syscalls 304
> +#define __NR_syscalls 305
>
> #define __NR__exit __NR_exit
> #define NR_syscalls __NR_syscalls
> --
> 1.5.1.3
>
> _______________________________________________
> Linuxppc-dev mailing list
> Linuxppc-dev@ozlabs.org
> https://ozlabs.org/mailman/listinfo/linuxppc-dev
^ permalink raw reply
* Re: PPC_OCP and ppc_sys problem while running kernel2.6 on ML403
From: David H. Lynch Jr. @ 2007-05-09 6:46 UTC (permalink / raw)
To: angelalinyao; +Cc: Linuxppc-embedded
In-Reply-To: <25023070.235791178678701658.JavaMail.nabble@isper.nabble.com>
angelalinyao@163.com wrote:
> Hi, all
> I met the CONFIG_PPC_OCP related problem while running MontaVista linux based on kernel 2.6.17 on Xilinx ML403.I have been confused with some questions about CONFIG_PPC_OCP and ppc_sys.Any reply from anyone is appreciate.
> From which version did the kernel.org tree stop using the OCP infrastructure and begin to use the ppc_sys infrastructure?Why did this change occur?what disadvantages dose the OCP infrastructure have?
> The LSP generated by EDK is still using the OCP infrastructure,so when it overwrites the kernel,mistakes happen.Is there any BSP version using ppc_sys which can solve the OCP problem?
> Also,the ppc_sys dosen't seem to support Virtex board well because I saw most patches supplied drop both ppc_ocp and ppc_sys.What disadventages dose ppc_sys have?Is patching the only method to solve this problem?
> Are there any patches supporting 2.6.17?
> Expect your reply,thanks!
I am not sure about versions, but I think OCP has been dropped for
mainline Linux Kernel sources for about a year.
Even the replacement will be somewhat obsoleted when the Xilinx
BSP's move from the arch/ppc tree to the arch/powerpc trees.
There is a some significant divergence between the Xilinx EDK
approach to supporting Linux and what is in the mainline kernel source.
Slowly mainline kernel support for various Xilinx devices is
maturing. If your product does not require much support for hardware
that is not yet in the mainline sources I would highly recommend using
the mainline Kernel source.
Currently there is support for the Xilinx ML300 and ML403 (with
support for Xilinx PIC, and UartLite) in the distribution kernels.
My source (following the distribution source closely) for Pico cards
is available on Pico's Web Site, www.picocomputing.com.
Grant Likely seems to be the staging point for moving broader Xilinx
IP support into the mailine kernel source.
Grant maintains a xilinx-dev git tree that is even closer to the
source trees from kernel.org that includes deeper support that is in the
pipeline.
I beleive with the exception of the Xilinx TEMAC, the only EDK
component needed is an xparameters.h file for your particular hardware.
--
Dave Lynch DLA Systems
Software Development: Embedded Linux
717.627.3770 dhlii@dlasys.net http://www.dlasys.net
fax: 1.253.369.9244 Cell: 1.717.587.7774
Over 25 years' experience in platforms, languages, and technologies too numerous to list.
"Any intelligent fool can make things bigger and more complex... It takes a touch of genius - and a lot of courage to move in the opposite direction."
Albert Einstein
^ permalink raw reply
* Re: [PATCH] swsusp: introduce register_nosave_region_late
From: Paul Mackerras @ 2007-05-09 6:36 UTC (permalink / raw)
To: Johannes Berg, Rafael J. Wysocki, linuxppc-dev list
In-Reply-To: <17985.26509.807018.401277@cargo.ozlabs.ibm.com>
Paul Mackerras writes:
> OK, but the patch doesn't apply against Linus' tree. It has no
> mention of register_nosave_region in include/linux/suspend.h, for
> instance. Which tree is this patch against?
Sorry, ignore this, I had the wrong branch checked out.
Paul.
^ permalink raw reply
* [PATCH 1/2] Declare {compat_}sys_utimensat
From: Stephen Rothwell @ 2007-05-09 6:23 UTC (permalink / raw)
To: paulus; +Cc: ppc-dev, Andrew Morton, Linus, LKML
Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
---
include/linux/compat.h | 3 +++
include/linux/syscalls.h | 2 ++
2 files changed, 5 insertions(+), 0 deletions(-)
This is needed before Powerpc can wire up the syscall.
--
Cheers,
Stephen Rothwell sfr@canb.auug.org.au
diff --git a/include/linux/compat.h b/include/linux/compat.h
index ccd863d..70a157a 100644
--- a/include/linux/compat.h
+++ b/include/linux/compat.h
@@ -253,5 +253,8 @@ asmlinkage long compat_sys_epoll_pwait(int epfd,
const compat_sigset_t __user *sigmask,
compat_size_t sigsetsize);
+asmlinkage long compat_sys_utimensat(unsigned int dfd, char __user *filename,
+ struct compat_timespec __user *t, int flags);
+
#endif /* CONFIG_COMPAT */
#endif /* _LINUX_COMPAT_H */
diff --git a/include/linux/syscalls.h b/include/linux/syscalls.h
index 1912c6c..3139f44 100644
--- a/include/linux/syscalls.h
+++ b/include/linux/syscalls.h
@@ -576,6 +576,8 @@ asmlinkage long sys_fstatat64(int dfd, char __user *filename,
struct stat64 __user *statbuf, int flag);
asmlinkage long sys_readlinkat(int dfd, const char __user *path, char __user *buf,
int bufsiz);
+asmlinkage long sys_utimensat(int dfd, char __user *filename,
+ struct timespec __user *utimes, int flags);
asmlinkage long compat_sys_futimesat(unsigned int dfd, char __user *filename,
struct compat_timeval __user *t);
asmlinkage long compat_sys_newfstatat(unsigned int dfd, char __user * filename,
--
1.5.1.3
^ permalink raw reply related
* [PATCH 2/2] [POWERPC] Wire up sys_utimensat
From: Stephen Rothwell @ 2007-05-09 6:24 UTC (permalink / raw)
To: paulus; +Cc: ppc-dev
In-Reply-To: <20070509162151.6a54507a.sfr@canb.auug.org.au>
Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
---
include/asm-powerpc/systbl.h | 1 +
include/asm-powerpc/unistd.h | 3 ++-
2 files changed, 3 insertions(+), 1 deletions(-)
This depends on the patch to declare {compat_}sys_utimensat
--
Cheers,
Stephen Rothwell sfr@canb.auug.org.au
diff --git a/include/asm-powerpc/systbl.h b/include/asm-powerpc/systbl.h
index 0b00068..3d44446 100644
--- a/include/asm-powerpc/systbl.h
+++ b/include/asm-powerpc/systbl.h
@@ -307,3 +307,4 @@ COMPAT_SYS_SPU(set_robust_list)
COMPAT_SYS_SPU(move_pages)
SYSCALL_SPU(getcpu)
COMPAT_SYS(epoll_pwait)
+COMPAT_SYS_SPU(utimensat)
diff --git a/include/asm-powerpc/unistd.h b/include/asm-powerpc/unistd.h
index 2baedbe..2b11631 100644
--- a/include/asm-powerpc/unistd.h
+++ b/include/asm-powerpc/unistd.h
@@ -326,10 +326,11 @@
#define __NR_move_pages 301
#define __NR_getcpu 302
#define __NR_epoll_pwait 303
+#define __NR_utimensat 303
#ifdef __KERNEL__
-#define __NR_syscalls 304
+#define __NR_syscalls 305
#define __NR__exit __NR_exit
#define NR_syscalls __NR_syscalls
--
1.5.1.3
^ permalink raw reply related
* Re: [PATCH] swsusp: introduce register_nosave_region_late
From: Paul Mackerras @ 2007-05-09 6:17 UTC (permalink / raw)
To: Johannes Berg; +Cc: Rafael J. Wysocki, linuxppc-dev list
In-Reply-To: <1178616229.18162.40.camel@johannes.berg>
Johannes Berg writes:
> This patch introduces a new register_nosave_region_late function that
> can be called from initcalls when register_nosave_region can no longer
> be used because it uses bootmem.
>
> Signed-off-by: Johannes Berg <johannes@sipsolutions.net>
> Acked-by: Rafael J. Wysocki <rjw@sisk.pl>
>
> ---
> Paul, I see you merged the suspend to disk for G5 patches, but this one
> is required for it to build. Rafael said that we should merge it with
> the user, since our code is the only user right now I take it that means
> it should go through the powerpc tree.
OK, but the patch doesn't apply against Linus' tree. It has no
mention of register_nosave_region in include/linux/suspend.h, for
instance. Which tree is this patch against?
Paul.
^ permalink raw reply
* [PATCH] drivers/ata/pata_scc.c: compile error fix
From: Akira Iguchi @ 2007-05-09 6:14 UTC (permalink / raw)
To: jeff; +Cc: linux-ide, linuxppc-dev
The previous change (ata_probe_ent -> ata_host) was incomplete
and generated compile error. This patch fix it.
Signed-off-by: Kou Ishizaki <kou.ishizaki@toshiba.co.jp>
Signed-off-by: Akira Iguchi <akira2.iguchi@toshiba.co.jp>
---
diff -purN -X linux-powerpc-git/Documentation/dontdiff linux-powerpc-git/drivers/ata/pata_scc.c linux-powerpc-git_mod/drivers/ata/pata_scc.c
--- linux-powerpc-git/drivers/ata/pata_scc.c 2007-05-08 09:41:52.000000000 +0900
+++ linux-powerpc-git_mod/drivers/ata/pata_scc.c 2007-05-09 14:13:15.000000000 +0900
@@ -1142,14 +1142,14 @@ static int scc_init_one (struct pci_dev
static int printed_version;
unsigned int board_idx = (unsigned int) ent->driver_data;
const struct ata_port_info *ppi[] = { &scc_port_info[board_idx], NULL };
- struct device *dev = &pdev->dev;
+ struct ata_host *host;
int rc;
if (!printed_version++)
dev_printk(KERN_DEBUG, &pdev->dev,
"version " DRV_VERSION "\n");
- host = ata_port_alloc_pinfo(&pdev->dev, ppi, 1);
+ host = ata_host_alloc_pinfo(&pdev->dev, ppi, 1);
if (!host)
return -ENOMEM;
^ permalink raw reply
* Re: PATCH: free mm if spufs_fill_dir() failed
From: Jeremy Kerr @ 2007-05-09 6:08 UTC (permalink / raw)
To: linuxppc-dev
In-Reply-To: <463B6D16.9050400@linux.vnet.ibm.com>
Sebastian,
> In case spufs_fill_dir() fails only put_spu_context()
> gets called for cleanup and the acquired mm_struct never gets freed.
Good catch. However - could we do the mmput in the context destroy path
instead?
Also, you're probably better-off sending patches inline. It makes
commenting on the patch much easier for some mailers.
Cheers,
Jeremy
^ permalink raw reply
* Re: Current powerpc.git build failures
From: David Gibson @ 2007-05-09 5:20 UTC (permalink / raw)
To: Loeliger Jon-LOELIGER, Kumar Gala, jdl, linuxppc-dev, paulus,
Olof Johansson, arnd, Tabi Timur-B04825
In-Reply-To: <20070509015753.GH4198@localhost.localdomain>
On Wed, May 09, 2007 at 11:57:54AM +1000, David Gibson wrote:
> On Wed, May 09, 2007 at 11:51:46AM +1000, David Gibson wrote:
> > On Tue, May 08, 2007 at 06:18:29PM -0700, Jon Loeliger wrote:
> > > > Looks like. AFAICT, the generic nopud.h and nopmd.h headers expect
> > > > page.h to be included before pgtable.h. I think this patch should fix
> > > > the problem, but I don't have a suitable board to test with.
> > > >
> > >
> > > That would be me. I'll give it a spin.
> >
> > Duh, of course, I wasn't thinking at that point and realizing I could
> > at least test the build was fixed. Which I've now done; and found
> > some other warnings caused by my patch. Improved fix below. Unless
> > you report that it breaks something, I'll ask Paul to pull it.
>
> Gah, sorry. Really below, this time:
Double gah. How about the *right* patch this time.
Further fixes for the removal of 4level-fixup hack from ppc32
Commit d1953c8888ef034b912ee33bc2ea2cce6a414402 removed the use of
4level-fixup.h for 32-bit systems under arch/powerpc. However, I
missed a few things activated on some configurations, resulting in
some warnings (at least with STRICT_MM_TYPECHECKS enabled) and build
errors in some circumstances. Fixes below.
Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
Index: working-2.6/arch/powerpc/platforms/86xx/mpc86xx_smp.c
===================================================================
--- working-2.6.orig/arch/powerpc/platforms/86xx/mpc86xx_smp.c 2007-05-09 11:08:15.000000000 +1000
+++ working-2.6/arch/powerpc/platforms/86xx/mpc86xx_smp.c 2007-05-09 11:08:33.000000000 +1000
@@ -15,8 +15,8 @@
#include <linux/init.h>
#include <linux/delay.h>
-#include <asm/pgtable.h>
#include <asm/page.h>
+#include <asm/pgtable.h>
#include <asm/pci-bridge.h>
#include <asm-powerpc/mpic.h>
#include <asm/mpc86xx.h>
Index: working-2.6/arch/powerpc/mm/ppc_mmu_32.c
===================================================================
--- working-2.6.orig/arch/powerpc/mm/ppc_mmu_32.c 2007-05-09 11:30:22.000000000 +1000
+++ working-2.6/arch/powerpc/mm/ppc_mmu_32.c 2007-05-09 11:31:09.000000000 +1000
@@ -185,7 +185,7 @@ void hash_preload(struct mm_struct *mm,
if (Hash == 0)
return;
- pmd = pmd_offset(pgd_offset(mm, ea), ea);
+ pmd = pmd_offset(pud_offset(pgd_offset(mm, ea), ea), ea);
if (!pmd_none(*pmd))
add_hash_page(mm->context.id, ea, pmd_val(*pmd));
}
Index: working-2.6/arch/powerpc/mm/tlb_32.c
===================================================================
--- working-2.6.orig/arch/powerpc/mm/tlb_32.c 2007-05-09 11:31:52.000000000 +1000
+++ working-2.6/arch/powerpc/mm/tlb_32.c 2007-05-09 11:32:17.000000000 +1000
@@ -111,7 +111,7 @@ static void flush_range(struct mm_struct
if (start >= end)
return;
end = (end - 1) | ~PAGE_MASK;
- pmd = pmd_offset(pgd_offset(mm, start), start);
+ pmd = pmd_offset(pud_offset(pgd_offset(mm, start), start), start);
for (;;) {
pmd_end = ((start + PGDIR_SIZE) & PGDIR_MASK) - 1;
if (pmd_end > end)
@@ -169,7 +169,7 @@ void flush_tlb_page(struct vm_area_struc
return;
}
mm = (vmaddr < TASK_SIZE)? vma->vm_mm: &init_mm;
- pmd = pmd_offset(pgd_offset(mm, vmaddr), vmaddr);
+ pmd = pmd_offset(pud_offset(pgd_offset(mm, vmaddr), vmaddr), vmaddr);
if (!pmd_none(*pmd))
flush_hash_pages(mm->context.id, vmaddr, pmd_val(*pmd), 1);
FINISH_FLUSH;
--
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/4] powerpc: EEH: capture and log pci state on error
From: Olof Johansson @ 2007-05-09 4:54 UTC (permalink / raw)
To: Linas Vepstas; +Cc: linuxppc-dev, Paul Mackerras
In-Reply-To: <20070508233532.GR4452@austin.ibm.com>
Hi,
On Tue, May 08, 2007 at 06:35:32PM -0500, Linas Vepstas wrote:
> Index: linux-2.6.21-rc7-mm2/arch/powerpc/platforms/pseries/eeh.c
> ===================================================================
> --- linux-2.6.21-rc7-mm2.orig/arch/powerpc/platforms/pseries/eeh.c 2007-04-26 15:37:32.000000000 -0500
> +++ linux-2.6.21-rc7-mm2/arch/powerpc/platforms/pseries/eeh.c 2007-04-26 16:19:28.000000000 -0500
> @@ -100,6 +100,9 @@ static unsigned char slot_errbuf[RTAS_ER
> static DEFINE_SPINLOCK(slot_errbuf_lock);
> static int eeh_error_buf_size;
>
> +#define EEH_PCI_REGS_LOG_LEN 4096
> +static unsigned char pci_regs_buf[EEH_PCI_REGS_LOG_LEN];
> +
I'm guessing this has to be in BSS because of the requrements of being
addressable in realmode for RTAS? Could be nice to document in a comment
so noone tries to make it a local variable later on.
> +void eeh_slot_error_detail(struct pci_dn *pdn, int severity)
> +{
> + size_t loglen = 0;
> + memset(pci_regs_buf, 0, EEH_PCI_REGS_LOG_LEN);
Should be no need to do a full memset, just set the first character to 0?
> + rtas_pci_enable(pdn, EEH_THAW_MMIO);
> + loglen = gather_pci_data(pdn, pci_regs_buf, EEH_PCI_REGS_LOG_LEN);
> +
> + rtas_slot_error_detail(pdn, severity, pci_regs_buf, loglen);
-Olof
^ permalink raw reply
* Re: [PATCH 1/4] powerpc: EEH: log error only after driver notification.
From: Olof Johansson @ 2007-05-09 4:51 UTC (permalink / raw)
To: Linas Vepstas; +Cc: linuxppc-dev, Paul Mackerras
In-Reply-To: <20070508233329.GP4452@austin.ibm.com>
Hi,
On Tue, May 08, 2007 at 06:33:29PM -0500, Linas Vepstas wrote:
> Index: linux-2.6.21-rc7-mm2/arch/powerpc/platforms/pseries/eeh_driver.c
> ===================================================================
> --- linux-2.6.21-rc7-mm2.orig/arch/powerpc/platforms/pseries/eeh_driver.c 2007-05-08 17:55:43.000000000 -0500
> +++ linux-2.6.21-rc7-mm2/arch/powerpc/platforms/pseries/eeh_driver.c 2007-05-08 17:56:42.000000000 -0500
> @@ -361,7 +361,6 @@ struct pci_dn * handle_eeh_events (struc
> goto hard_fail;
> }
>
> - eeh_slot_error_detail(frozen_pdn, 1 /* Temporary Error */);
> printk(KERN_WARNING
> "EEH: This PCI device has failed %d times since last reboot: "
> "location=%s driver=%s pci addr=%s\n",
> @@ -375,6 +374,11 @@ struct pci_dn * handle_eeh_events (struc
> */
> pci_walk_bus(frozen_bus, eeh_report_error, &result);
>
> + /* Since rtas may enable MMIO when posting the error log,
> + * don't post the error log until after all dev drivers
> + * have been informed. */
> + eeh_slot_error_detail(frozen_pdn, 1 /* Temporary Error */);
I know you only moved it, but if you have to document what '1' means,
you really should add a symbolic define/enum instead. Not saying it should
stop this from going in, but it could be a good separate improvement.
(Also, the comment style: */ should be on it's own line.)
-Olof
^ permalink raw reply
* [PATCH 5/5] powerpc: Don't use SLAB/SLUB for PTE pages
From: Benjamin Herrenschmidt @ 2007-05-09 4:38 UTC (permalink / raw)
To: linuxppc-dev; +Cc: Hugh Dickins, Paul Mackerras
In-Reply-To: <20070508062750.A5CBBDDE42@ozlabs.org>
powerpc: Don't use SLAB/SLUB for PTE pages
From: Hugh Dickins <hugh@veritas.com>
The SLUB allocator relies on struct page fields first_page and slab,
overwritten by ptl when SPLIT_PTLOCK: so the SLUB allocator cannot then
be used for the lowest level of pagetable pages. This was obstructing
SLUB on PowerPC, which uses kmem_caches for its pagetables. So convert
its pte level to use normal gfp pages (whereas pmd, pud and 64k-page pgd
want partpages, so continue to use kmem_caches for pmd, pud and pgd).
Signed-off-by: Hugh Dickins <hugh@veritas.com>
Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
---
This version uses __GFP_ZERO instead of clear_page() and re-enables
SLUB on powerpc.
Index: linux-cell/arch/powerpc/mm/init_64.c
===================================================================
--- linux-cell.orig/arch/powerpc/mm/init_64.c 2007-05-08 16:47:48.000000000 +1000
+++ linux-cell/arch/powerpc/mm/init_64.c 2007-05-09 12:15:22.000000000 +1000
@@ -146,21 +146,16 @@ static void zero_ctor(void *addr, struct
memset(addr, 0, kmem_cache_size(cache));
}
-#ifdef CONFIG_PPC_64K_PAGES
-static const unsigned int pgtable_cache_size[3] = {
- PTE_TABLE_SIZE, PMD_TABLE_SIZE, PGD_TABLE_SIZE
-};
-static const char *pgtable_cache_name[ARRAY_SIZE(pgtable_cache_size)] = {
- "pte_pmd_cache", "pmd_cache", "pgd_cache",
-};
-#else
static const unsigned int pgtable_cache_size[2] = {
- PTE_TABLE_SIZE, PMD_TABLE_SIZE
+ PGD_TABLE_SIZE, PMD_TABLE_SIZE
};
static const char *pgtable_cache_name[ARRAY_SIZE(pgtable_cache_size)] = {
- "pgd_pte_cache", "pud_pmd_cache",
-};
+#ifdef CONFIG_PPC_64K_PAGES
+ "pgd_cache", "pmd_cache",
+#else
+ "pgd_cache", "pud_pmd_cache",
#endif /* CONFIG_PPC_64K_PAGES */
+};
#ifdef CONFIG_HUGETLB_PAGE
/* Hugepages need one extra cache, initialized in hugetlbpage.c. We
Index: linux-cell/include/asm-powerpc/pgalloc.h
===================================================================
--- linux-cell.orig/include/asm-powerpc/pgalloc.h 2007-05-08 16:47:48.000000000 +1000
+++ linux-cell/include/asm-powerpc/pgalloc.h 2007-05-09 12:17:11.000000000 +1000
@@ -13,18 +13,11 @@
extern struct kmem_cache *pgtable_cache[];
-#ifdef CONFIG_PPC_64K_PAGES
-#define PTE_CACHE_NUM 0
-#define PMD_CACHE_NUM 1
-#define PGD_CACHE_NUM 2
-#define HUGEPTE_CACHE_NUM 3
-#else
-#define PTE_CACHE_NUM 0
-#define PMD_CACHE_NUM 1
-#define PUD_CACHE_NUM 1
-#define PGD_CACHE_NUM 0
-#define HUGEPTE_CACHE_NUM 2
-#endif
+#define PGD_CACHE_NUM 0
+#define PUD_CACHE_NUM 1
+#define PMD_CACHE_NUM 1
+#define HUGEPTE_CACHE_NUM 2
+#define PTE_NONCACHE_NUM 3 /* from GFP rather than kmem_cache */
/*
* This program is free software; you can redistribute it and/or
@@ -97,8 +90,7 @@ static inline void pmd_free(pmd_t *pmd)
static inline pte_t *pte_alloc_one_kernel(struct mm_struct *mm,
unsigned long address)
{
- return kmem_cache_alloc(pgtable_cache[PTE_CACHE_NUM],
- GFP_KERNEL|__GFP_REPEAT);
+ return (pte_t *)__get_free_page(GFP_KERNEL | __GFP_REPEAT | __GFP_ZERO);
}
static inline struct page *pte_alloc_one(struct mm_struct *mm,
@@ -109,12 +101,12 @@ static inline struct page *pte_alloc_one
static inline void pte_free_kernel(pte_t *pte)
{
- kmem_cache_free(pgtable_cache[PTE_CACHE_NUM], pte);
+ free_page((unsigned long)pte);
}
static inline void pte_free(struct page *ptepage)
{
- pte_free_kernel(page_address(ptepage));
+ __free_page(ptepage);
}
#define PGF_CACHENUM_MASK 0x3
@@ -136,14 +128,17 @@ static inline void pgtable_free(pgtable_
void *p = (void *)(pgf.val & ~PGF_CACHENUM_MASK);
int cachenum = pgf.val & PGF_CACHENUM_MASK;
- kmem_cache_free(pgtable_cache[cachenum], p);
+ if (cachenum == PTE_NONCACHE_NUM)
+ free_page((unsigned long)p);
+ else
+ kmem_cache_free(pgtable_cache[cachenum], p);
}
extern void pgtable_free_tlb(struct mmu_gather *tlb, pgtable_free_t pgf);
#define __pte_free_tlb(tlb, ptepage) \
pgtable_free_tlb(tlb, pgtable_free_cache(page_address(ptepage), \
- PTE_CACHE_NUM, PTE_TABLE_SIZE-1))
+ PTE_NONCACHE_NUM, PTE_TABLE_SIZE-1))
#define __pmd_free_tlb(tlb, pmd) \
pgtable_free_tlb(tlb, pgtable_free_cache(pmd, \
PMD_CACHE_NUM, PMD_TABLE_SIZE-1))
Index: linux-cell/arch/powerpc/Kconfig
===================================================================
--- linux-cell.orig/arch/powerpc/Kconfig 2007-05-09 12:17:50.000000000 +1000
+++ linux-cell/arch/powerpc/Kconfig 2007-05-09 12:18:02.000000000 +1000
@@ -117,19 +117,6 @@ config GENERIC_BUG
default y
depends on BUG
-#
-# Powerpc uses the slab allocator to manage its ptes and the
-# page structs of ptes are used for splitting the page table
-# lock for configurations supporting more than SPLIT_PTLOCK_CPUS.
-#
-# In that special configuration the page structs of slabs are modified.
-# This setting disables the selection of SLUB as a slab allocator.
-#
-config ARCH_USES_SLAB_PAGE_STRUCT
- bool
- default y
- depends on SPLIT_PTLOCK_CPUS <= NR_CPUS
-
config DEFAULT_UIMAGE
bool
help
A.
^ permalink raw reply
* RE: [PATCH v4 0/7] Add support for 750CL Holly board
From: Zang Roy-r61911 @ 2007-05-09 2:52 UTC (permalink / raw)
To: Josh Boyer; +Cc: linuxppc-dev, paulus
In-Reply-To: <1178678089.3453.51.camel@zod.rchland.ibm.com>
>=20
> > Patch 7/7 seems broken on current Paul's tree. I fixed it myself.
>=20
> Depending on the definition of "current", all of these patches should
> already be in Paul's tree :)
Notice it. That's great!
I used my yesterday's tree. I do not update it this morning :-).
Roy
^ permalink raw reply
* PPC_OCP and ppc_sys problem while running kernel2.6 on ML403
From: angelalinyao @ 2007-05-09 2:45 UTC (permalink / raw)
To: Linuxppc-embedded
Hi, all
I met the CONFIG_PPC_OCP related problem while running MontaVista linux based on kernel 2.6.17 on Xilinx ML403.I have been confused with some questions about CONFIG_PPC_OCP and ppc_sys.Any reply from anyone is appreciate.
From which version did the kernel.org tree stop using the OCP infrastructure and begin to use the ppc_sys infrastructure?Why did this change occur?what disadvantages dose the OCP infrastructure have?
The LSP generated by EDK is still using the OCP infrastructure,so when it overwrites the kernel,mistakes happen.Is there any BSP version using ppc_sys which can solve the OCP problem?
Also,the ppc_sys dosen't seem to support Virtex board well because I saw most patches supplied drop both ppc_ocp and ppc_sys.What disadventages dose ppc_sys have?Is patching the only method to solve this problem?
Are there any patches supporting 2.6.17?
Expect your reply,thanks!
linyao
^ permalink raw reply
* RE: [PATCH v4 0/7] Add support for 750CL Holly board
From: Josh Boyer @ 2007-05-09 2:34 UTC (permalink / raw)
To: Zang Roy-r61911; +Cc: linuxppc-dev, paulus
In-Reply-To: <7EA18FDD2DC2154AA3BD6D2F22A62A0E753C30@zch01exm23.fsl.freescale.net>
On Wed, 2007-05-09 at 10:19 +0800, Zang Roy-r61911 wrote:
> > > On Tue, May 08, 2007 at 11:45:05AM +0800, Zang Roy-r61911 wrote:
> > > > >
> > > > > Hi All,
> > > > >
> > > > > This is round 4 of the patches to support the 750CL Holly
> > > board, and
> > > > > hopefully the last. They also fix one of the PCI issues
> > > I was seeing.
> > > > Sorry, Maybe I missed your previous comment.
> > > > What is the PCI issue? Associated with your board or tsi108/9 ?
> > >
> > > Mostly it was the fact that PIBS (the low level boot
> > > firmware) setup the PCI
> > > bridge in an odd fashion. The other small issue was that the
> > > TSI PCI bridge
> > > was not being designated as the primary. Both of these were
> > > found working
> > > with a developer from Tundra.
> > That is great.
> > I will test your patch on 7448hpc2 board tomorrow and give
> > the feedback.
> > Roy
> Patches were fine for 7448hpc2 board.
Excellent. Thanks for testing that Roy.
> Patch 7/7 seems broken on current Paul's tree. I fixed it myself.
Depending on the definition of "current", all of these patches should
already be in Paul's tree :)
josh
^ permalink raw reply
* RE: [PATCH v4 0/7] Add support for 750CL Holly board
From: Zang Roy-r61911 @ 2007-05-09 2:19 UTC (permalink / raw)
To: Josh Boyer; +Cc: linuxppc-dev, paulus
In-Reply-To: <7EA18FDD2DC2154AA3BD6D2F22A62A0E753B9F@zch01exm23.fsl.freescale.net>
> > On Tue, May 08, 2007 at 11:45:05AM +0800, Zang Roy-r61911 wrote:
> > > >=20
> > > > Hi All,
> > > >=20
> > > > This is round 4 of the patches to support the 750CL Holly=20
> > board, and
> > > > hopefully the last. They also fix one of the PCI issues=20
> > I was seeing.
> > > Sorry, Maybe I missed your previous comment.
> > > What is the PCI issue? Associated with your board or tsi108/9 ?
> >=20
> > Mostly it was the fact that PIBS (the low level boot=20
> > firmware) setup the PCI
> > bridge in an odd fashion. The other small issue was that the=20
> > TSI PCI bridge
> > was not being designated as the primary. Both of these were=20
> > found working
> > with a developer from Tundra.
> That is great.=20
> I will test your patch on 7448hpc2 board tomorrow and give=20
> the feedback.
> Roy
Patches were fine for 7448hpc2 board.
Patch 7/7 seems broken on current Paul's tree. I fixed it myself.
Roy
^ permalink raw reply
* Re: Current powerpc.git build failures
From: David Gibson @ 2007-05-09 1:57 UTC (permalink / raw)
To: Loeliger Jon-LOELIGER, Kumar Gala, jdl, linuxppc-dev, paulus,
Olof Johansson, arnd, Tabi Timur-B04825
In-Reply-To: <20070509015146.GF4198@localhost.localdomain>
On Wed, May 09, 2007 at 11:51:46AM +1000, David Gibson wrote:
> On Tue, May 08, 2007 at 06:18:29PM -0700, Jon Loeliger wrote:
> > > Looks like. AFAICT, the generic nopud.h and nopmd.h headers expect
> > > page.h to be included before pgtable.h. I think this patch should fix
> > > the problem, but I don't have a suitable board to test with.
> > >
> >
> > That would be me. I'll give it a spin.
>
> Duh, of course, I wasn't thinking at that point and realizing I could
> at least test the build was fixed. Which I've now done; and found
> some other warnings caused by my patch. Improved fix below. Unless
> you report that it breaks something, I'll ask Paul to pull it.
Gah, sorry. Really below, this time:
Fix missing printk() parameter in physmap_of.c MTD driver
Squashes a compiler warning, and provides more useful information in
the case messed up device tree information.
Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
Index: working-2.6/drivers/mtd/maps/physmap_of.c
===================================================================
--- working-2.6.orig/drivers/mtd/maps/physmap_of.c 2007-05-07 12:57:07.000000000 +1000
+++ working-2.6/drivers/mtd/maps/physmap_of.c 2007-05-09 11:53:53.000000000 +1000
@@ -186,7 +186,7 @@ static int __devinit of_physmap_probe(st
else {
if (strcmp(of_probe, "ROM"))
dev_dbg(&dev->dev, "map_probe: don't know probe type "
- "'%s', mapping as rom\n");
+ "'%s', mapping as rom\n", of_probe);
info->mtd = do_map_probe("mtd_rom", &info->map);
}
if (info->mtd == NULL) {
--
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
* Fix missing printk() parameter in physmap_of.c MTD driver
From: David Gibson @ 2007-05-09 1:55 UTC (permalink / raw)
To: Vitaly Wool, David Woodhouse; +Cc: linuxppc-dev
Squashes a compiler warning, and provides more useful information in
the case messed up device tree information.
Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
Index: working-2.6/drivers/mtd/maps/physmap_of.c
===================================================================
--- working-2.6.orig/drivers/mtd/maps/physmap_of.c 2007-05-07 12:57:07.000000000 +1000
+++ working-2.6/drivers/mtd/maps/physmap_of.c 2007-05-09 11:53:53.000000000 +1000
@@ -186,7 +186,7 @@ static int __devinit of_physmap_probe(st
else {
if (strcmp(of_probe, "ROM"))
dev_dbg(&dev->dev, "map_probe: don't know probe type "
- "'%s', mapping as rom\n");
+ "'%s', mapping as rom\n", of_probe);
info->mtd = do_map_probe("mtd_rom", &info->map);
}
if (info->mtd == NULL) {
--
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: Current powerpc.git build failures
From: David Gibson @ 2007-05-09 1:51 UTC (permalink / raw)
To: Loeliger Jon-LOELIGER
Cc: jdl, linuxppc-dev, paulus, Olof Johansson, arnd,
Tabi Timur-B04825
In-Reply-To: <AF0367BA48C55940A43CCF08DF35553C012AA6B2@az33exm24.fsl.freescale.net>
On Tue, May 08, 2007 at 06:18:29PM -0700, Jon Loeliger wrote:
> > Looks like. AFAICT, the generic nopud.h and nopmd.h headers expect
> > page.h to be included before pgtable.h. I think this patch should fix
> > the problem, but I don't have a suitable board to test with.
> >
>
> That would be me. I'll give it a spin.
Duh, of course, I wasn't thinking at that point and realizing I could
at least test the build was fixed. Which I've now done; and found
some other warnings caused by my patch. Improved fix below. Unless
you report that it breaks something, I'll ask Paul to pull 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: Current powerpc.git build failures
From: Loeliger Jon-LOELIGER @ 2007-05-09 1:18 UTC (permalink / raw)
To: David Gibson, Kumar Gala
Cc: jdl, linuxppc-dev, paulus, Olof Johansson, arnd,
Tabi Timur-B04825
In-Reply-To: <20070509010941.GC4198@localhost.localdomain>
> Looks like. AFAICT, the generic nopud.h and nopmd.h headers expect
> page.h to be included before pgtable.h. I think this patch should fix
> the problem, but I don't have a suitable board to test with.
>=20
That would be me. I'll give it a spin.
Thanks,
Jdl
^ permalink raw reply
* Re: Current powerpc.git build failures
From: David Gibson @ 2007-05-09 1:09 UTC (permalink / raw)
To: Kumar Gala; +Cc: jdl, linuxppc-dev, paulus, Olof Johansson, arnd, Timur Tabi
In-Reply-To: <5E47D5F4-DD15-46D1-A947-3031D069486F@kernel.crashing.org>
On Tue, May 08, 2007 at 03:38:35PM -0500, Kumar Gala wrote:
>
> On May 8, 2007, at 3:30 PM, Timur Tabi wrote:
>
> > Olof Johansson wrote:
> >
> >> powerpc.mpc8641_hpcn_defconfig:
> >> In file included from include/asm-generic/pgtable-nopmd.h:6,
> >> from include/asm/pgtable-ppc32.h:4,
> >> from include/asm/pgtable.h:8,
> >> from arch/powerpc/platforms/86xx/mpc86xx_smp.c:18:
> >> include/asm-generic/pgtable-nopud.h:13: error: expected specifier-
> >> qualifier-list before 'pgd_t'
> >
> > This must have occurred in the past 24 hours because I built the
> > latest 8641 yesterday
> > morning and it worked fine. mpc86xx_smp.c has not changed since
> > February, so I'm guessing
> > that some header file that mpc86xx_smp.c includes no longer
> > includes some other header.
>
> I'm guessing this is from david gibson's 4level-fixup.h for ppc32
> patch.
Looks like. AFAICT, the generic nopud.h and nopmd.h headers expect
page.h to be included before pgtable.h. I think this patch should fix
the problem, but I don't have a suitable board to test with.
Index: working-2.6/arch/powerpc/platforms/86xx/mpc86xx_smp.c
===================================================================
--- working-2.6.orig/arch/powerpc/platforms/86xx/mpc86xx_smp.c 2007-05-09 11:08:15.000000000 +1000
+++ working-2.6/arch/powerpc/platforms/86xx/mpc86xx_smp.c 2007-05-09 11:08:33.000000000 +1000
@@ -15,8 +15,8 @@
#include <linux/init.h>
#include <linux/delay.h>
-#include <asm/pgtable.h>
#include <asm/page.h>
+#include <asm/pgtable.h>
#include <asm/pci-bridge.h>
#include <asm-powerpc/mpic.h>
#include <asm/mpc86xx.h>
--
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 v2 6/7] Holly DTS
From: David Gibson @ 2007-05-09 0:49 UTC (permalink / raw)
To: Loeliger Jon-LOELIGER; +Cc: Olof Johansson, linuxppc-dev
In-Reply-To: <AF0367BA48C55940A43CCF08DF35553C012AA296@az33exm24.fsl.freescale.net>
On Mon, May 07, 2007 at 10:50:50AM -0700, Jon Loeliger wrote:
> > > Other dts'es are similar. Could be nice
> > > to have a comment next to it if that's the case.
> >
> > Yeah. There's also this ?? syntax now I believe.
>
> Not quite yet.
Yes, the idea was raised, but discussion kind of petered out and
nobody (read: me) got around to implementing it.
> We didn't really get a 2/3 majority
> Ratification from The Syndicate yet. The debate
> Is ongoing, I suspect.
/me wonders who jdl is thinking of as The Syndicate.
--
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 1/4] Add support for 750CL Holly board
From: Josh Boyer @ 2007-05-09 0:39 UTC (permalink / raw)
To: Benjamin Herrenschmidt; +Cc: linuxppc-dev, Arnd Bergmann
In-Reply-To: <1178666385.14928.119.camel@localhost.localdomain>
On Wed, 2007-05-09 at 09:19 +1000, Benjamin Herrenschmidt wrote:
> On Fri, 2007-05-04 at 21:44 +0200, Arnd Bergmann wrote:
>
> > > +void holly_show_cpuinfo(struct seq_file *m)
> > > +{
> > > + seq_printf(m, "vendor\t\t: IBM\n");
> > > + seq_printf(m, "machine\t\t: PPC750 GX/CL\n");
> > > +}
> >
> > If it's an IBM product, it should come with a product code like 123-4567,
> > which fits in here, instead of just listing the CPU.
>
> Should probably come from the device tree anyway.
It will with some cleanup patches I'm planning on.
> > > + const struct exception_table_entry *entry;
> > > +
> > > + /* Are we prepared to handle this fault */
> > > + if ((entry = search_exception_tables(regs->nip)) != NULL) {
> > > + tsi108_clear_pci_cfg_error();
> > > + regs->msr |= MSR_RI;
> > > + regs->nip = entry->fixup;
> > > + return 1;
> > > + }
> > > + return 0;
> > > +}
> >
> > Are you sure that you can use the generic exception table mechanism
> > like this? I can't see why it doesn't work, but it's something I haven't
> > seen anyone do like this.
>
> Also, can't the TSI be configured to not generate MCE in that case ?
Not that I'm aware of. They should only occur on the initial PCI bus
scan.
josh
^ permalink raw reply
* Re: [PATCH] Mark prop unused in early_init_dt_scan_chosen().
From: David Gibson @ 2007-05-09 0:41 UTC (permalink / raw)
To: Michael Ellerman; +Cc: linuxppc-dev list
In-Reply-To: <1178668594.3696.5.camel@concordia.ozlabs.ibm.com>
[-- Attachment #1: Type: text/plain, Size: 1364 bytes --]
On Wed, May 09, 2007 at 09:56:34AM +1000, Michael Ellerman wrote:
> On Tue, 2007-05-08 at 12:14 -0500, Scott Wood wrote:
> > The prop variable is only referenced when initrd support is
> > turned on.
> >
> > Signed-off-by: Scott Wood <scottwood@freescale.com>
> > ---
> > arch/powerpc/kernel/prom.c | 2 +-
> > 1 files changed, 1 insertions(+), 1 deletions(-)
> >
> > diff --git a/arch/powerpc/kernel/prom.c b/arch/powerpc/kernel/prom.c
> > index caef555..6705459 100644
> > --- a/arch/powerpc/kernel/prom.c
> > +++ b/arch/powerpc/kernel/prom.c
> > @@ -720,7 +720,7 @@ static int __init early_init_dt_scan_chosen(unsigned long node,
> > const char *uname, int depth, void *data)
> > {
> > unsigned long *lprop;
> > - u32 *prop;
> > + u32 __attribute__((unused)) *prop;
> > unsigned long l;
> > char *p;
>
> Hi Scott,
>
> Let's be honest, this is a hack. I think it'd be cleaner to pull the
> initrd logic out into a separate function.
More speficially, if the variable ever really becomes unused, this
will continue to suppress the warning. I'd be happied with an #ifdef
initrd around it, ugly though that is.
--
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
[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 189 bytes --]
^ permalink raw reply
* Re: [PATCH 1/4] Add support for 750CL Holly board
From: Josh Boyer @ 2007-05-09 0:32 UTC (permalink / raw)
To: Benjamin Herrenschmidt; +Cc: linuxppc-dev, Arnd Bergmann
In-Reply-To: <1178666428.14928.121.camel@localhost.localdomain>
On Wed, 2007-05-09 at 09:20 +1000, Benjamin Herrenschmidt wrote:
> > I know. Looking for a better suggestions. Kumar suggested a Kconfig
> > option at least, which is what I'm going to go with unless someone has a
> > better idea...
>
> Yes, I do: Fix the TSI driver, it should be trivial :-)
You're a bit late. It was fixed in a more generic manner :)
josh
^ 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