* Re: [PATCH 8/8] ARM: S5PV210: example of CMA private area for FIMC device on Goni board
@ 2011-08-24 15:41 Aguirre, Sergio
2011-08-25 7:22 ` Marek Szyprowski
0 siblings, 1 reply; 6+ messages in thread
From: Aguirre, Sergio @ 2011-08-24 15:41 UTC (permalink / raw)
To: Marek Szyprowski, Kyungmin Park
Cc: linux-kernel, linux-arm-kernel, linux-media, linux-mm,
linaro-mm-sig, Michal Nazarewicz, Russell King, Andrew Morton
Hi Marek/Kyungmin,
On Fri, Aug 19, 2011 at 04:27:44PM +0200, Marek Szyprowski wrote:
> This patch is an example how device private CMA area can be activated.
> It creates one CMA region and assigns it to the first s5p-fimc device on
> Samsung Goni S5PC110 board.
>
> Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com>
> Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
> ---
> arch/arm/mach-s5pv210/mach-goni.c | 4 ++++
> 1 files changed, 4 insertions(+), 0 deletions(-)
> diff --git a/arch/arm/mach-s5pv210/mach-goni.c b/arch/arm/mach-s5pv210/mach-goni.c
> index 14578f5..f766c45 100644
> --- a/arch/arm/mach-s5pv210/mach-goni.c
> +++ b/arch/arm/mach-s5pv210/mach-goni.c
> @@ -26,6 +26,7 @@
> #include <linux/input.h>
> #include <linux/gpio.h>
> #include <linux/interrupt.h>
> +#include <linux/dma-contiguous.h>
>
> #include <asm/mach/arch.h>
> #include <asm/mach/map.h>
> @@ -857,6 +858,9 @@ static void __init goni_map_io(void)
> static void __init goni_reserve(void)
> {
> s5p_mfc_reserve_mem(0x43000000, 8 << 20, 0x51000000, 8 << 20);
> +
> + /* Create private 16MiB contiguous memory area for s5p-fimc.0 device */
> + dma_declare_contiguous(&s5p_device_fimc0.dev, 16*SZ_1M, 0);
This is broken, since according to patch #0006, dma_declare_contiguous requires
a 4th param (limit) which you're not providing here.
Regards,
Sergio
> }
>
> static void __init goni_machine_init(void)
> --
> 1.7.1.569.g6f426
--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org. For more info on Linux MM,
see: http://www.linux-mm.org/ .
Fight unfair telecom internet charges in Canada: sign http://stopthemeter.ca/
Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>
^ permalink raw reply [flat|nested] 6+ messages in thread
* RE: [PATCH 8/8] ARM: S5PV210: example of CMA private area for FIMC device on Goni board
2011-08-24 15:41 [PATCH 8/8] ARM: S5PV210: example of CMA private area for FIMC device on Goni board Aguirre, Sergio
@ 2011-08-25 7:22 ` Marek Szyprowski
0 siblings, 0 replies; 6+ messages in thread
From: Marek Szyprowski @ 2011-08-25 7:22 UTC (permalink / raw)
To: 'Aguirre, Sergio', 'Kyungmin Park'
Cc: linux-kernel, linux-arm-kernel, linux-media, linux-mm,
linaro-mm-sig, 'Michal Nazarewicz',
'Russell King', 'Andrew Morton'
Hello,
On Wednesday, August 24, 2011 5:41 PM Aguirre, Sergio wrote:
> On Fri, Aug 19, 2011 at 04:27:44PM +0200, Marek Szyprowski wrote:
> > This patch is an example how device private CMA area can be activated.
> > It creates one CMA region and assigns it to the first s5p-fimc device on
> > Samsung Goni S5PC110 board.
> >
> > Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com>
> > Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
> > ---
> > arch/arm/mach-s5pv210/mach-goni.c | 4 ++++
> > 1 files changed, 4 insertions(+), 0 deletions(-)
> > diff --git a/arch/arm/mach-s5pv210/mach-goni.c b/arch/arm/mach-s5pv210/mach-
> goni.c
> > index 14578f5..f766c45 100644
> > --- a/arch/arm/mach-s5pv210/mach-goni.c
> > +++ b/arch/arm/mach-s5pv210/mach-goni.c
> > @@ -26,6 +26,7 @@
> > #include <linux/input.h>
> > #include <linux/gpio.h>
> > #include <linux/interrupt.h>
> > +#include <linux/dma-contiguous.h>
> >
> > #include <asm/mach/arch.h>
> > #include <asm/mach/map.h>
> > @@ -857,6 +858,9 @@ static void __init goni_map_io(void)
> > static void __init goni_reserve(void)
> > {
> > s5p_mfc_reserve_mem(0x43000000, 8 << 20, 0x51000000, 8 << 20);
> > +
> > + /* Create private 16MiB contiguous memory area for s5p-fimc.0 device */
> > + dma_declare_contiguous(&s5p_device_fimc0.dev, 16*SZ_1M, 0);
>
> This is broken, since according to patch #0006, dma_declare_contiguous
requires
> a 4th param (limit) which you're not providing here.
You are definitely right, there should be one more parameter. This patch was
just
cherry-picked from older version just before posting to mailing lists. I'm
really
sorry for this trivial bug.
Best regards
--
Marek Szyprowski
Samsung Poland R&D Center
--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org. For more info on Linux MM,
see: http://www.linux-mm.org/ .
Fight unfair telecom internet charges in Canada: sign http://stopthemeter.ca/
Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>
^ permalink raw reply [flat|nested] 6+ messages in thread
* [PATCH 8/8] ARM: S5PV210: example of CMA private area for FIMC device on Goni board
2011-08-19 14:27 [PATCHv15 0/8] Contiguous Memory Allocator Marek Szyprowski
@ 2011-08-19 14:27 ` Marek Szyprowski
0 siblings, 0 replies; 6+ messages in thread
From: Marek Szyprowski @ 2011-08-19 14:27 UTC (permalink / raw)
To: linux-kernel, linux-arm-kernel, linux-media, linux-mm, linaro-mm-sig
Cc: Michal Nazarewicz, Marek Szyprowski, Kyungmin Park, Russell King,
Andrew Morton, KAMEZAWA Hiroyuki, Ankita Garg, Daniel Walker,
Mel Gorman, Arnd Bergmann, Jesse Barker, Jonathan Corbet,
Shariq Hasnain, Chunsang Jeong
This patch is an example how device private CMA area can be activated.
It creates one CMA region and assigns it to the first s5p-fimc device on
Samsung Goni S5PC110 board.
Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com>
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
---
arch/arm/mach-s5pv210/mach-goni.c | 4 ++++
1 files changed, 4 insertions(+), 0 deletions(-)
diff --git a/arch/arm/mach-s5pv210/mach-goni.c b/arch/arm/mach-s5pv210/mach-goni.c
index 14578f5..f766c45 100644
--- a/arch/arm/mach-s5pv210/mach-goni.c
+++ b/arch/arm/mach-s5pv210/mach-goni.c
@@ -26,6 +26,7 @@
#include <linux/input.h>
#include <linux/gpio.h>
#include <linux/interrupt.h>
+#include <linux/dma-contiguous.h>
#include <asm/mach/arch.h>
#include <asm/mach/map.h>
@@ -857,6 +858,9 @@ static void __init goni_map_io(void)
static void __init goni_reserve(void)
{
s5p_mfc_reserve_mem(0x43000000, 8 << 20, 0x51000000, 8 << 20);
+
+ /* Create private 16MiB contiguous memory area for s5p-fimc.0 device */
+ dma_declare_contiguous(&s5p_device_fimc0.dev, 16*SZ_1M, 0);
}
static void __init goni_machine_init(void)
--
1.7.1.569.g6f426
--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org. For more info on Linux MM,
see: http://www.linux-mm.org/ .
Fight unfair telecom internet charges in Canada: sign http://stopthemeter.ca/
Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>
^ permalink raw reply [flat|nested] 6+ messages in thread
* [PATCH 8/8] ARM: S5PV210: example of CMA private area for FIMC device on Goni board
2011-07-20 8:57 [PATCHv12 0/8] Contiguous Memory Allocator Marek Szyprowski
@ 2011-07-20 8:57 ` Marek Szyprowski
0 siblings, 0 replies; 6+ messages in thread
From: Marek Szyprowski @ 2011-07-20 8:57 UTC (permalink / raw)
To: linux-kernel, linux-arm-kernel, linux-media, linux-mm, linaro-mm-sig
Cc: Michal Nazarewicz, Marek Szyprowski, Kyungmin Park,
Andrew Morton, KAMEZAWA Hiroyuki, Ankita Garg, Daniel Walker,
Mel Gorman, Arnd Bergmann, Jesse Barker, Jonathan Corbet,
Chunsang Jeong, Russell King
This patch is an example how device private CMA area can be activated.
It creates one CMA region and assigns it to the first s5p-fimc device on
Samsung Goni S5PC110 board.
Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com>
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
---
arch/arm/mach-s5pv210/Kconfig | 1 +
arch/arm/mach-s5pv210/mach-goni.c | 8 ++++++++
2 files changed, 9 insertions(+), 0 deletions(-)
diff --git a/arch/arm/mach-s5pv210/Kconfig b/arch/arm/mach-s5pv210/Kconfig
index 37b5a97..c09a92c 100644
--- a/arch/arm/mach-s5pv210/Kconfig
+++ b/arch/arm/mach-s5pv210/Kconfig
@@ -64,6 +64,7 @@ menu "S5PC110 Machines"
config MACH_AQUILA
bool "Aquila"
select CPU_S5PV210
+ select CMA
select S3C_DEV_FB
select S5P_DEV_FIMC0
select S5P_DEV_FIMC1
diff --git a/arch/arm/mach-s5pv210/mach-goni.c b/arch/arm/mach-s5pv210/mach-goni.c
index 31d5aa7..d9e565d 100644
--- a/arch/arm/mach-s5pv210/mach-goni.c
+++ b/arch/arm/mach-s5pv210/mach-goni.c
@@ -26,6 +26,7 @@
#include <linux/input.h>
#include <linux/gpio.h>
#include <linux/interrupt.h>
+#include <linux/dma-contiguous.h>
#include <asm/mach/arch.h>
#include <asm/mach/map.h>
@@ -886,6 +887,12 @@ static void __init goni_machine_init(void)
platform_add_devices(goni_devices, ARRAY_SIZE(goni_devices));
}
+static void __init goni_reserve(void)
+{
+ /* Create private 16MiB contiguous memory area for s5p-fimc.0 device */
+ dma_declare_contiguous(&s5p_device_fimc0.dev, 16*SZ_1M, 0);
+}
+
MACHINE_START(GONI, "GONI")
/* Maintainers: Kyungmin Park <kyungmin.park@samsung.com> */
.boot_params = S5P_PA_SDRAM + 0x100,
@@ -893,4 +900,5 @@ MACHINE_START(GONI, "GONI")
.map_io = goni_map_io,
.init_machine = goni_machine_init,
.timer = &s5p_timer,
+ .reserve = goni_reserve,
MACHINE_END
--
1.7.1.569.g6f426
--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org. For more info on Linux MM,
see: http://www.linux-mm.org/ .
Fight unfair telecom internet charges in Canada: sign http://stopthemeter.ca/
Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH 8/8] ARM: S5PV210: example of CMA private area for FIMC device on Goni board
2011-07-05 7:41 ` [PATCH 8/8] ARM: S5PV210: example of CMA private area for FIMC device on Goni board Marek Szyprowski
@ 2011-07-05 11:51 ` Arnd Bergmann
0 siblings, 0 replies; 6+ messages in thread
From: Arnd Bergmann @ 2011-07-05 11:51 UTC (permalink / raw)
To: Marek Szyprowski
Cc: linux-kernel, linux-arm-kernel, linux-media, linux-mm,
linaro-mm-sig, Michal Nazarewicz, Kyungmin Park, Andrew Morton,
KAMEZAWA Hiroyuki, Ankita Garg, Daniel Walker, Mel Gorman,
Jesse Barker, Jonathan Corbet, Chunsang Jeong
On Tuesday 05 July 2011, Marek Szyprowski wrote:
>
> This patch is an example how device private CMA area can be activated.
> It creates one CMA region and assigns it to the first s5p-fimc device on
> Samsung Goni S5PC110 board.
>
> Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com>
> Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
Reviewed-by: Arnd Bergmann <arnd@arndb.de>
--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org. For more info on Linux MM,
see: http://www.linux-mm.org/ .
Fight unfair telecom internet charges in Canada: sign http://stopthemeter.ca/
Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>
^ permalink raw reply [flat|nested] 6+ messages in thread
* [PATCH 8/8] ARM: S5PV210: example of CMA private area for FIMC device on Goni board
2011-07-05 7:41 [PATCHv11 0/8] Contiguous Memory Allocator Marek Szyprowski
@ 2011-07-05 7:41 ` Marek Szyprowski
2011-07-05 11:51 ` Arnd Bergmann
0 siblings, 1 reply; 6+ messages in thread
From: Marek Szyprowski @ 2011-07-05 7:41 UTC (permalink / raw)
To: linux-kernel, linux-arm-kernel, linux-media, linux-mm, linaro-mm-sig
Cc: Michal Nazarewicz, Marek Szyprowski, Kyungmin Park,
Andrew Morton, KAMEZAWA Hiroyuki, Ankita Garg, Daniel Walker,
Mel Gorman, Arnd Bergmann, Jesse Barker, Jonathan Corbet,
Chunsang Jeong
This patch is an example how device private CMA area can be activated.
It creates one CMA region and assigns it to the first s5p-fimc device on
Samsung Goni S5PC110 board.
Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com>
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
---
arch/arm/mach-s5pv210/Kconfig | 1 +
arch/arm/mach-s5pv210/mach-goni.c | 8 ++++++++
2 files changed, 9 insertions(+), 0 deletions(-)
diff --git a/arch/arm/mach-s5pv210/Kconfig b/arch/arm/mach-s5pv210/Kconfig
index 37b5a97..c09a92c 100644
--- a/arch/arm/mach-s5pv210/Kconfig
+++ b/arch/arm/mach-s5pv210/Kconfig
@@ -64,6 +64,7 @@ menu "S5PC110 Machines"
config MACH_AQUILA
bool "Aquila"
select CPU_S5PV210
+ select CMA
select S3C_DEV_FB
select S5P_DEV_FIMC0
select S5P_DEV_FIMC1
diff --git a/arch/arm/mach-s5pv210/mach-goni.c b/arch/arm/mach-s5pv210/mach-goni.c
index 31d5aa7..d9e565d 100644
--- a/arch/arm/mach-s5pv210/mach-goni.c
+++ b/arch/arm/mach-s5pv210/mach-goni.c
@@ -26,6 +26,7 @@
#include <linux/input.h>
#include <linux/gpio.h>
#include <linux/interrupt.h>
+#include <linux/dma-contiguous.h>
#include <asm/mach/arch.h>
#include <asm/mach/map.h>
@@ -886,6 +887,12 @@ static void __init goni_machine_init(void)
platform_add_devices(goni_devices, ARRAY_SIZE(goni_devices));
}
+static void __init goni_reserve(void)
+{
+ /* Create private 16MiB contiguous memory area for s5p-fimc.0 device */
+ dma_declare_contiguous(&s5p_device_fimc0.dev, 16*SZ_1M, 0);
+}
+
MACHINE_START(GONI, "GONI")
/* Maintainers: Kyungmin Park <kyungmin.park@samsung.com> */
.boot_params = S5P_PA_SDRAM + 0x100,
@@ -893,4 +900,5 @@ MACHINE_START(GONI, "GONI")
.map_io = goni_map_io,
.init_machine = goni_machine_init,
.timer = &s5p_timer,
+ .reserve = goni_reserve,
MACHINE_END
--
1.7.1.569.g6f426
--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org. For more info on Linux MM,
see: http://www.linux-mm.org/ .
Fight unfair telecom internet charges in Canada: sign http://stopthemeter.ca/
Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2011-08-25 7:25 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-08-24 15:41 [PATCH 8/8] ARM: S5PV210: example of CMA private area for FIMC device on Goni board Aguirre, Sergio
2011-08-25 7:22 ` Marek Szyprowski
-- strict thread matches above, loose matches on Subject: below --
2011-08-19 14:27 [PATCHv15 0/8] Contiguous Memory Allocator Marek Szyprowski
2011-08-19 14:27 ` [PATCH 8/8] ARM: S5PV210: example of CMA private area for FIMC device on Goni board Marek Szyprowski
2011-07-20 8:57 [PATCHv12 0/8] Contiguous Memory Allocator Marek Szyprowski
2011-07-20 8:57 ` [PATCH 8/8] ARM: S5PV210: example of CMA private area for FIMC device on Goni board Marek Szyprowski
2011-07-05 7:41 [PATCHv11 0/8] Contiguous Memory Allocator Marek Szyprowski
2011-07-05 7:41 ` [PATCH 8/8] ARM: S5PV210: example of CMA private area for FIMC device on Goni board Marek Szyprowski
2011-07-05 11:51 ` Arnd Bergmann
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox