* [PATCH 0/2] mm: memblock: Couple of kbuild fixes after the memblock series
@ 2013-12-10 19:29 Santosh Shilimkar
2013-12-10 19:29 ` [PATCH 1/2] mm/ARM: dma: fix conflicting types for 'arm_dma_zone_size' Santosh Shilimkar
2013-12-10 19:29 ` [PATCH 2/2] mm/memblock: fix buld of "cris" arch Santosh Shilimkar
0 siblings, 2 replies; 4+ messages in thread
From: Santosh Shilimkar @ 2013-12-10 19:29 UTC (permalink / raw)
To: linux-arm-kernel
Andrew,
Thanks to kbuild which almost covers all the architectures builds, couple
of build related issues poped up after the memblock series applied [1]
This series tries to address those build issues.
Cc: Russell King <linux@arm.linux.org.uk>
Cc: Yinghai Lu <yinghai@kernel.org>
Cc: Tejun Heo <tj@kernel.org>
Cc: Andrew Morton <akpm@linux-foundation.org>
Grygorii Strashko (2):
mm/ARM: dma: fix conflicting types for 'arm_dma_zone_size'
mm/memblock: fix buld of "cris" arch
arch/arm/include/asm/dma.h | 2 +-
include/linux/bootmem.h | 1 +
2 files changed, 2 insertions(+), 1 deletion(-)
Regards,
Santosh
[1] https://lkml.org/lkml/2013/12/9/715
--
1.7.9.5
^ permalink raw reply [flat|nested] 4+ messages in thread
* [PATCH 1/2] mm/ARM: dma: fix conflicting types for 'arm_dma_zone_size'
2013-12-10 19:29 [PATCH 0/2] mm: memblock: Couple of kbuild fixes after the memblock series Santosh Shilimkar
@ 2013-12-10 19:29 ` Santosh Shilimkar
2013-12-10 21:25 ` Russell King - ARM Linux
2013-12-10 19:29 ` [PATCH 2/2] mm/memblock: fix buld of "cris" arch Santosh Shilimkar
1 sibling, 1 reply; 4+ messages in thread
From: Santosh Shilimkar @ 2013-12-10 19:29 UTC (permalink / raw)
To: linux-arm-kernel
From: Grygorii Strashko <grygorii.strashko@ti.com>
Commit 364230b9 "ARM: use phys_addr_t for DMA zone sizes" changes
type of arm_dma_zone_size to phys_addr_t, but misses to update
external definition of it in in arch/arm/include/asm/dma.h.
As result, kernel build is failed if CONFIG_ZONE_DMA is enabled:
arch/arm/mm/init.c:202:13: error: conflicting types for 'arm_dma_zone_size'
include/linux/bootmem.h:258:66: note: previous declaration of 'arm_dma_zone_size' was here
Hence, fix external definition of arm_dma_zone_size.
Cc: Russell King <linux@arm.linux.org.uk>
Cc: Rob Herring <rob.herring@calxeda.com>
Cc: Yinghai Lu <yinghai@kernel.org>
Cc: Tejun Heo <tj@kernel.org>
Cc: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Grygorii Strashko <grygorii.strashko@ti.com>
Signed-off-by: Santosh Shilimkar <santosh.shilimkar@ti.com>
---
arch/arm/include/asm/dma.h | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/arch/arm/include/asm/dma.h b/arch/arm/include/asm/dma.h
index 58b8c6a..1439b80 100644
--- a/arch/arm/include/asm/dma.h
+++ b/arch/arm/include/asm/dma.h
@@ -8,7 +8,7 @@
#define MAX_DMA_ADDRESS 0xffffffffUL
#else
#define MAX_DMA_ADDRESS ({ \
- extern unsigned long arm_dma_zone_size; \
+ extern phys_addr_t arm_dma_zone_size; \
arm_dma_zone_size ? \
(PAGE_OFFSET + arm_dma_zone_size) : 0xffffffffUL; })
#endif
--
1.7.9.5
^ permalink raw reply related [flat|nested] 4+ messages in thread* [PATCH 1/2] mm/ARM: dma: fix conflicting types for 'arm_dma_zone_size'
2013-12-10 19:29 ` [PATCH 1/2] mm/ARM: dma: fix conflicting types for 'arm_dma_zone_size' Santosh Shilimkar
@ 2013-12-10 21:25 ` Russell King - ARM Linux
0 siblings, 0 replies; 4+ messages in thread
From: Russell King - ARM Linux @ 2013-12-10 21:25 UTC (permalink / raw)
To: linux-arm-kernel
On Tue, Dec 10, 2013 at 02:29:57PM -0500, Santosh Shilimkar wrote:
> diff --git a/arch/arm/include/asm/dma.h b/arch/arm/include/asm/dma.h
> index 58b8c6a..1439b80 100644
> --- a/arch/arm/include/asm/dma.h
> +++ b/arch/arm/include/asm/dma.h
> @@ -8,7 +8,7 @@
> #define MAX_DMA_ADDRESS 0xffffffffUL
> #else
> #define MAX_DMA_ADDRESS ({ \
> - extern unsigned long arm_dma_zone_size; \
> + extern phys_addr_t arm_dma_zone_size; \
> arm_dma_zone_size ? \
> (PAGE_OFFSET + arm_dma_zone_size) : 0xffffffffUL; })
This is wrong. Take a moment to look at it more closely. What does
"PAGE_OFFSET" tell you about what its returning?
What happens if arm_dma_zone_size is greater than 1GB when PAGE_OFFSET
is at the default setting of 3GB?
^ permalink raw reply [flat|nested] 4+ messages in thread
* [PATCH 2/2] mm/memblock: fix buld of "cris" arch
2013-12-10 19:29 [PATCH 0/2] mm: memblock: Couple of kbuild fixes after the memblock series Santosh Shilimkar
2013-12-10 19:29 ` [PATCH 1/2] mm/ARM: dma: fix conflicting types for 'arm_dma_zone_size' Santosh Shilimkar
@ 2013-12-10 19:29 ` Santosh Shilimkar
1 sibling, 0 replies; 4+ messages in thread
From: Santosh Shilimkar @ 2013-12-10 19:29 UTC (permalink / raw)
To: linux-arm-kernel
From: Grygorii Strashko <grygorii.strashko@ti.com>
The build of "criss" arch is broken after applying new memblock API
series.
In file included from arch/cris/mm/init.c:13:0:
include/linux/bootmem.h: In function 'memblock_virt_alloc':
include/linux/bootmem.h:229:55: error: 'KSEG_C' undeclared (first use in this function)
include/linux/bootmem.h:229:55: note: each undeclared identifier is reported only once for each function it appears in
include/linux/bootmem.h: In function 'memblock_virt_alloc_nopanic':
include/linux/bootmem.h:237:63: error: 'KSEG_C' undeclared (first use in this function)
include/linux/bootmem.h: In function 'memblock_virt_alloc_node':
include/linux/bootmem.h:250:27: error: 'KSEG_C' undeclared (first use in this function)
include/linux/bootmem.h: In function 'memblock_virt_alloc_node_nopanic':
include/linux/bootmem.h:258:28: error: 'KSEG_C' undeclared (first use in this function)
In file included from mm/bootmem.c:14:0:
include/linux/bootmem.h: In function 'memblock_virt_alloc':
include/linux/bootmem.h:229:55: error: 'KSEG_C' undeclared (first use in this function)
include/linux/bootmem.h:229:55: note: each undeclared identifier is reported only once for each function it appears in
include/linux/bootmem.h: In function 'memblock_virt_alloc_nopanic':
include/linux/bootmem.h:237:63: error: 'KSEG_C' undeclared (first use in this function)
include/linux/bootmem.h: In function 'memblock_virt_alloc_node':
include/linux/bootmem.h:250:27: error: 'KSEG_C' undeclared (first use in this function)
The "cris" arch defines memory parameters in a different manner than other
arch's and they are splitted between 2 headers: <asm/page.h> and <asm/mmu.h>
As result, now build is failed if "bootmem.h" included before
<asm/page.h> and <asm/mmu.h>. Hence, fix it by including additional
header in bootmem.h.
Cc: Yinghai Lu <yinghai@kernel.org>
Cc: Tejun Heo <tj@kernel.org>
Cc: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Grygorii Strashko <grygorii.strashko@ti.com>
Signed-off-by: Santosh Shilimkar <santosh.shilimkar@ti.com>
---
include/linux/bootmem.h | 1 +
1 file changed, 1 insertion(+)
diff --git a/include/linux/bootmem.h b/include/linux/bootmem.h
index 1c9aa0e..2fae55d 100644
--- a/include/linux/bootmem.h
+++ b/include/linux/bootmem.h
@@ -5,6 +5,7 @@
#define _LINUX_BOOTMEM_H
#include <linux/mmzone.h>
+#include <linux/mm_types.h>
#include <asm/dma.h>
/*
--
1.7.9.5
^ permalink raw reply related [flat|nested] 4+ messages in thread
end of thread, other threads:[~2013-12-10 21:25 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-12-10 19:29 [PATCH 0/2] mm: memblock: Couple of kbuild fixes after the memblock series Santosh Shilimkar
2013-12-10 19:29 ` [PATCH 1/2] mm/ARM: dma: fix conflicting types for 'arm_dma_zone_size' Santosh Shilimkar
2013-12-10 21:25 ` Russell King - ARM Linux
2013-12-10 19:29 ` [PATCH 2/2] mm/memblock: fix buld of "cris" arch Santosh Shilimkar
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).