* [PATCH] ARM: nommu: avoid mapping vectors page when !CONFIG_MMU
@ 2011-01-11 12:02 Will Deacon
2011-01-11 12:13 ` Russell King - ARM Linux
2011-01-11 12:33 ` Greg Ungerer
0 siblings, 2 replies; 4+ messages in thread
From: Will Deacon @ 2011-01-11 12:02 UTC (permalink / raw)
To: linux-arm-kernel
When running without an MMU, we do not need to install a mapping for the
vectors page. Attempting to do so causes a compile-time error because
install_special_mapping is not defined.
This patch adds compile-time guards to the vector mapping functions
so that we can build nommu configurations once more.
Cc: Greg Ungerer <gerg@uclinux.org>
Signed-off-by: Will Deacon <will.deacon@arm.com>
---
arch/arm/kernel/process.c | 2 ++
1 files changed, 2 insertions(+), 0 deletions(-)
diff --git a/arch/arm/kernel/process.c b/arch/arm/kernel/process.c
index e76fcaa..94bbedb 100644
--- a/arch/arm/kernel/process.c
+++ b/arch/arm/kernel/process.c
@@ -483,6 +483,7 @@ unsigned long arch_randomize_brk(struct mm_struct *mm)
return randomize_range(mm->brk, range_end, 0) ? : mm->brk;
}
+#ifdef CONFIG_MMU
/*
* The vectors page is always readable from user space for the
* atomic helpers and the signal restart code. Let's declare a mapping
@@ -503,3 +504,4 @@ const char *arch_vma_name(struct vm_area_struct *vma)
{
return (vma->vm_start == 0xffff0000) ? "[vectors]" : NULL;
}
+#endif
--
1.7.0.4
^ permalink raw reply related [flat|nested] 4+ messages in thread
* [PATCH] ARM: nommu: avoid mapping vectors page when !CONFIG_MMU
2011-01-11 12:02 [PATCH] ARM: nommu: avoid mapping vectors page when !CONFIG_MMU Will Deacon
@ 2011-01-11 12:13 ` Russell King - ARM Linux
2011-01-11 12:33 ` Greg Ungerer
1 sibling, 0 replies; 4+ messages in thread
From: Russell King - ARM Linux @ 2011-01-11 12:13 UTC (permalink / raw)
To: linux-arm-kernel
On Tue, Jan 11, 2011 at 12:02:17PM +0000, Will Deacon wrote:
> When running without an MMU, we do not need to install a mapping for the
> vectors page. Attempting to do so causes a compile-time error because
> install_special_mapping is not defined.
>
> This patch adds compile-time guards to the vector mapping functions
> so that we can build nommu configurations once more.
I had a similar patch a few days ago doing the same thing... when Greg's
acked it, please submit to the patch system, thanks.
^ permalink raw reply [flat|nested] 4+ messages in thread
* [PATCH] ARM: nommu: avoid mapping vectors page when !CONFIG_MMU
2011-01-11 12:02 [PATCH] ARM: nommu: avoid mapping vectors page when !CONFIG_MMU Will Deacon
2011-01-11 12:13 ` Russell King - ARM Linux
@ 2011-01-11 12:33 ` Greg Ungerer
2011-01-11 13:06 ` Will Deacon
1 sibling, 1 reply; 4+ messages in thread
From: Greg Ungerer @ 2011-01-11 12:33 UTC (permalink / raw)
To: linux-arm-kernel
Hi Will,
On 11/01/11 22:02, Will Deacon wrote:
> When running without an MMU, we do not need to install a mapping for the
> vectors page. Attempting to do so causes a compile-time error because
> install_special_mapping is not defined.
>
> This patch adds compile-time guards to the vector mapping functions
> so that we can build nommu configurations once more.
>
> Cc: Greg Ungerer<gerg@uclinux.org>
> Signed-off-by: Will Deacon<will.deacon@arm.com>
I hit this a couple of days ago too, looks good.
Acked-by: Greg Ungerer <gerg@uclinux.org>
Regards
Greg
> arch/arm/kernel/process.c | 2 ++
> 1 files changed, 2 insertions(+), 0 deletions(-)
>
> diff --git a/arch/arm/kernel/process.c b/arch/arm/kernel/process.c
> index e76fcaa..94bbedb 100644
> --- a/arch/arm/kernel/process.c
> +++ b/arch/arm/kernel/process.c
> @@ -483,6 +483,7 @@ unsigned long arch_randomize_brk(struct mm_struct *mm)
> return randomize_range(mm->brk, range_end, 0) ? : mm->brk;
> }
>
> +#ifdef CONFIG_MMU
> /*
> * The vectors page is always readable from user space for the
> * atomic helpers and the signal restart code. Let's declare a mapping
> @@ -503,3 +504,4 @@ const char *arch_vma_name(struct vm_area_struct *vma)
> {
> return (vma->vm_start == 0xffff0000) ? "[vectors]" : NULL;
> }
> +#endif
--
------------------------------------------------------------------------
Greg Ungerer -- Principal Engineer EMAIL: gerg at snapgear.com
SnapGear Group, McAfee PHONE: +61 7 3435 2888
8 Gardner Close, FAX: +61 7 3891 3630
Milton, QLD, 4064, Australia WEB: http://www.SnapGear.com
^ permalink raw reply [flat|nested] 4+ messages in thread
* [PATCH] ARM: nommu: avoid mapping vectors page when !CONFIG_MMU
2011-01-11 12:33 ` Greg Ungerer
@ 2011-01-11 13:06 ` Will Deacon
0 siblings, 0 replies; 4+ messages in thread
From: Will Deacon @ 2011-01-11 13:06 UTC (permalink / raw)
To: linux-arm-kernel
Hi Greg,
> > When running without an MMU, we do not need to install a mapping for the
> > vectors page. Attempting to do so causes a compile-time error because
> > install_special_mapping is not defined.
> >
> > This patch adds compile-time guards to the vector mapping functions
> > so that we can build nommu configurations once more.
> >
> > Cc: Greg Ungerer<gerg@uclinux.org>
> > Signed-off-by: Will Deacon<will.deacon@arm.com>
>
> I hit this a couple of days ago too, looks good.
>
> Acked-by: Greg Ungerer <gerg@uclinux.org>
Thanks. Submitted to Russell as 6619/1.
Will
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2011-01-11 13:06 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-01-11 12:02 [PATCH] ARM: nommu: avoid mapping vectors page when !CONFIG_MMU Will Deacon
2011-01-11 12:13 ` Russell King - ARM Linux
2011-01-11 12:33 ` Greg Ungerer
2011-01-11 13:06 ` Will Deacon
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).