Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 208800
b: refs/heads/master
c: 33c14ff
h: refs/heads/master
v: v3
  • Loading branch information
Sylwester Nawrocki authored and Kukjin Kim committed Aug 6, 2010
1 parent 1acc2f7 commit d9dbf38
Show file tree
Hide file tree
Showing 10 changed files with 182 additions and 1 deletion.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 290d0983b86f6243beffaa3ddb02c14adc30f02a
refs/heads/master: 33c14ff838c3617616112b6dd833f2d7b70d6224
8 changes: 8 additions & 0 deletions trunk/arch/arm/mach-s5pc100/include/mach/map.h
Original file line number Diff line number Diff line change
Expand Up @@ -94,6 +94,10 @@

#define S5PC100_PA_FB (0xEE000000)

#define S5PC100_PA_FIMC0 (0xEE200000)
#define S5PC100_PA_FIMC1 (0xEE300000)
#define S5PC100_PA_FIMC2 (0xEE400000)

#define S5PC100_PA_I2S0 (0xF2000000)
#define S5PC100_PA_I2S1 (0xF2100000)
#define S5PC100_PA_I2S2 (0xF2200000)
Expand Down Expand Up @@ -135,4 +139,8 @@
#define S3C_PA_ONENAND_BUF S5PC100_PA_ONENAND_BUF
#define S3C_SZ_ONENAND_BUF S5PC100_SZ_ONENAND_BUF

#define S5P_PA_FIMC0 S5PC100_PA_FIMC0
#define S5P_PA_FIMC1 S5PC100_PA_FIMC1
#define S5P_PA_FIMC2 S5PC100_PA_FIMC2

#endif /* __ASM_ARCH_C100_MAP_H */
5 changes: 5 additions & 0 deletions trunk/arch/arm/mach-s5pv210/cpu.c
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@
#include <plat/clock.h>
#include <plat/s5pv210.h>
#include <plat/adc-core.h>
#include <plat/fimc-core.h>
#include <plat/iic-core.h>
#include <plat/sdhci.h>

Expand Down Expand Up @@ -90,6 +91,10 @@ void __init s5pv210_map_io(void)
s3c_i2c0_setname("s3c2440-i2c");
s3c_i2c1_setname("s3c2440-i2c");
s3c_i2c2_setname("s3c2440-i2c");

s3c_fimc_setname(0, "s5pv210-fimc");
s3c_fimc_setname(1, "s5pv210-fimc");
s3c_fimc_setname(2, "s5pv210-fimc");
}

void __init s5pv210_init_clocks(int xtal)
Expand Down
7 changes: 7 additions & 0 deletions trunk/arch/arm/mach-s5pv210/include/mach/map.h
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,10 @@

#define S5PV210_PA_FB (0xF8000000)

#define S5PV210_PA_FIMC0 (0xFB200000)
#define S5PV210_PA_FIMC1 (0xFB300000)
#define S5PV210_PA_FIMC2 (0xFB400000)

#define S5PV210_PA_HSMMC(x) (0xEB000000 + ((x) * 0x100000))

#define S5PV210_PA_VIC0 (0xF2000000)
Expand Down Expand Up @@ -102,6 +106,9 @@
#define S3C_PA_IIC2 S5PV210_PA_IIC2
#define S3C_PA_FB S5PV210_PA_FB
#define S3C_PA_WDT S5PV210_PA_WATCHDOG
#define S5P_PA_FIMC0 S5PV210_PA_FIMC0
#define S5P_PA_FIMC1 S5PV210_PA_FIMC1
#define S5P_PA_FIMC2 S5PV210_PA_FIMC2

#define SAMSUNG_PA_ADC S5PV210_PA_ADC

Expand Down
5 changes: 5 additions & 0 deletions trunk/arch/arm/plat-s5p/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -18,3 +18,8 @@ obj-y += clock.o
obj-y += irq.o
obj-$(CONFIG_S5P_EXT_INT) += irq-eint.o

# devices

obj-$(CONFIG_S5P_DEV_FIMC0) += dev-fimc0.o
obj-$(CONFIG_S5P_DEV_FIMC1) += dev-fimc1.o
obj-$(CONFIG_S5P_DEV_FIMC2) += dev-fimc2.o
36 changes: 36 additions & 0 deletions trunk/arch/arm/plat-s5p/dev-fimc0.c
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
/* linux/arch/arm/plat-s5p/dev-fimc0.c
*
* Copyright (c) 2010 Samsung Electronics
*
* Base S5P FIMC0 resource and device definitions
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License version 2 as
* published by the Free Software Foundation.
*/

#include <linux/kernel.h>
#include <linux/platform_device.h>
#include <linux/interrupt.h>
#include <linux/ioport.h>
#include <mach/map.h>

static struct resource s5p_fimc0_resource[] = {
[0] = {
.start = S5P_PA_FIMC0,
.end = S5P_PA_FIMC0 + SZ_1M - 1,
.flags = IORESOURCE_MEM,
},
[1] = {
.start = IRQ_FIMC0,
.end = IRQ_FIMC0,
.flags = IORESOURCE_IRQ,
},
};

struct platform_device s5p_device_fimc0 = {
.name = "s5p-fimc",
.id = 0,
.num_resources = ARRAY_SIZE(s5p_fimc0_resource),
.resource = s5p_fimc0_resource,
};
36 changes: 36 additions & 0 deletions trunk/arch/arm/plat-s5p/dev-fimc1.c
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
/* linux/arch/arm/plat-s5p/dev-fimc1.c
*
* Copyright (c) 2010 Samsung Electronics
*
* Base S5P FIMC1 resource and device definitions
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License version 2 as
* published by the Free Software Foundation.
*/

#include <linux/kernel.h>
#include <linux/platform_device.h>
#include <linux/interrupt.h>
#include <linux/ioport.h>
#include <mach/map.h>

static struct resource s5p_fimc1_resource[] = {
[0] = {
.start = S5P_PA_FIMC1,
.end = S5P_PA_FIMC1 + SZ_1M - 1,
.flags = IORESOURCE_MEM,
},
[1] = {
.start = IRQ_FIMC1,
.end = IRQ_FIMC1,
.flags = IORESOURCE_IRQ,
},
};

struct platform_device s5p_device_fimc1 = {
.name = "s5p-fimc",
.id = 1,
.num_resources = ARRAY_SIZE(s5p_fimc1_resource),
.resource = s5p_fimc1_resource,
};
36 changes: 36 additions & 0 deletions trunk/arch/arm/plat-s5p/dev-fimc2.c
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
/* linux/arch/arm/plat-s5p/dev-fimc2.c
*
* Copyright (c) 2010 Samsung Electronics
*
* Base S5P FIMC2 resource and device definitions
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License version 2 as
* published by the Free Software Foundation.
*/

#include <linux/kernel.h>
#include <linux/platform_device.h>
#include <linux/interrupt.h>
#include <linux/ioport.h>
#include <mach/map.h>

static struct resource s5p_fimc2_resource[] = {
[0] = {
.start = S5P_PA_FIMC2,
.end = S5P_PA_FIMC2 + SZ_1M - 1,
.flags = IORESOURCE_MEM,
},
[1] = {
.start = IRQ_FIMC2,
.end = IRQ_FIMC2,
.flags = IORESOURCE_IRQ,
},
};

struct platform_device s5p_device_fimc2 = {
.name = "s5p-fimc",
.id = 2,
.num_resources = ARRAY_SIZE(s5p_fimc2_resource),
.resource = s5p_fimc2_resource,
};
4 changes: 4 additions & 0 deletions trunk/arch/arm/plat-samsung/include/plat/devs.h
Original file line number Diff line number Diff line change
Expand Up @@ -104,6 +104,10 @@ extern struct platform_device s5pc100_device_iis2;

extern struct platform_device samsung_device_keypad;

extern struct platform_device s5p_device_fimc0;
extern struct platform_device s5p_device_fimc1;
extern struct platform_device s5p_device_fimc2;

/* s3c2440 specific devices */

#ifdef CONFIG_CPU_S3C2440
Expand Down
44 changes: 44 additions & 0 deletions trunk/arch/arm/plat-samsung/include/plat/fimc-core.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
/*
* arch/arm/plat-samsung/include/plat/fimc-core.h
*
* Copyright 2010 Samsung Electronics Co., Ltd.
* Sylwester Nawrocki <s.nawrocki@samsung.com>
*
* Samsung camera interface driver core functions
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License version 2 as
* published by the Free Software Foundation.
*/

#ifndef __ASM_PLAT_FIMC_CORE_H
#define __ASM_PLAT_FIMC_CORE_H __FILE__

/*
* These functions are only for use with the core support code, such as
* the CPU-specific initialization code.
*/

/* Re-define device name to differentiate the subsystem in various SoCs. */
static inline void s3c_fimc_setname(int id, char *name)
{
switch (id) {
#ifdef CONFIG_S5P_DEV_FIMC0
case 0:
s5p_device_fimc0.name = name;
break;
#endif
#ifdef CONFIG_S5P_DEV_FIMC1
case 1:
s5p_device_fimc1.name = name;
break;
#endif
#ifdef CONFIG_S5P_DEV_FIMC2
case 2:
s5p_device_fimc2.name = name;
break;
#endif
}
}

#endif /* __ASM_PLAT_FIMC_CORE_H */

0 comments on commit d9dbf38

Please sign in to comment.