[PATCH] ARM: S5PC110: Samsung Goni board update
STALE5810d
18 messages,
4 authors,
2010-09-14 · open the first message on its own page
Hello,
This patch series updates the devices supported by Samsung Goni board.
The patch series has been prepared against latest kgene/for-next kernel
tree.
The complete list of patches:
[PATCH 1/6] ARM: S5PC110: update framebuffer setup information for Goni
[PATCH 2/6] ARM: S5PC110: add support for S6E63M0 LCD controller on Goni board
[PATCH 3/6] ARM: S5PC110: Add si470x radio device to the GONI board
[PATCH 4/6] ARM: S5PV210: Enable USB HSOTG gadget build
[PATCH 5/6] ARM: S5PC110: add support for otg usb gadget on Goni board
[PATCH 6/6] ARM: S5PC110: add support for MMC regulators on Goni board
Best regards
--
Marek Szyprowski
Samsung Poland R&D Center
Change the default upper_margin and vsync_len to get rid of repeated last
line on the display.
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 | 5 ++---
1 files changed, 2 insertions(+), 3 deletions(-)
diff --git a/arch/arm/mach-s5pv210/mach-goni.c b/arch/arm/mach-s5pv210/mach-goni.c
index d9fe739..b0ae208 100644
--- a/arch/arm/mach-s5pv210/mach-goni.c
+++ b/arch/arm/mach-s5pv210/mach-goni.c @@ -88,13 +88,12 @@ static struct s3c2410_uartcfg goni_uartcfgs[] __initdata = {
/* Frame Buffer */
static struct s3c_fb_pd_win goni_fb_win0 = {
. win_mode = {
- . pixclock = 1000000000000ULL / (( 16 + 16 + 2 + 480 ) * ( 28 + 3 + 2 + 800 ) * 55 ),
. left_margin = 16 ,
. right_margin = 16 ,
- . upper_margin = 3 ,
+ . upper_margin = 2 ,
. lower_margin = 28 ,
. hsync_len = 2 ,
- . vsync_len = 2 ,
+ . vsync_len = 1 ,
. xres = 480 ,
. yres = 800 ,
. refresh = 55 , --
1.7.2.2
Add required platform definitions for S6E63M0 LCD controller on Samsung
Goni 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 | 71 +++++++++++++++++++++++++++++++++++++
1 files changed, 71 insertions(+), 0 deletions(-)
diff --git a/arch/arm/mach-s5pv210/mach-goni.c b/arch/arm/mach-s5pv210/mach-goni.c
index b0ae208..b263f3a 100644
--- a/arch/arm/mach-s5pv210/mach-goni.c
+++ b/arch/arm/mach-s5pv210/mach-goni.c @@ -16,6 +16,9 @@
#include <linux/i2c.h>
#include <linux/i2c-gpio.h>
#include <linux/mfd/max8998.h>
+ #include <linux/spi/spi.h>
+ #include <linux/spi/spi_gpio.h>
+ #include <linux/lcd.h>
#include <linux/gpio_keys.h>
#include <linux/input.h>
#include <linux/gpio.h> @@ -111,6 +114,70 @@ static struct s3c_fb_platdata goni_lcd_pdata __initdata = {
. setup_gpio = s5pv210_fb_gpio_setup_24bpp ,
};
+ static int lcd_power_on ( struct lcd_device * ld , int enable )
+ {
+ return 1 ;
+ }
+
+ static int reset_lcd ( struct lcd_device * ld )
+ {
+ static unsigned int first = 1 ;
+ int reset_gpio = -1 ;
+
+ reset_gpio = S5PV210_MP05 ( 5 );
+
+ if ( first ) {
+ gpio_request ( reset_gpio , "MLCD_RST" );
+ first = 0 ;
+ }
+
+ gpio_direction_output ( reset_gpio , 1 );
+ return 1 ;
+ }
+
+ static struct lcd_platform_data s6e63m0_platform_data = {
+ . reset = reset_lcd ,
+ . power_on = lcd_power_on ,
+ . lcd_enabled = 0 ,
+
+ . reset_delay = 120 , /* 120ms */
+ . power_on_delay = 25 , /* 25ms */
+ . power_off_delay = 200 , /* 200ms */
+ };
+
+ #define LCD_BUS_NUM 3
+ #define DISPLAY_CS S5PV210_MP01(1)
+ static struct spi_board_info spi_board_info [] __initdata = {
+ {
+ . modalias = "s6e63m0" ,
+ . platform_data = ( void * ) & s6e63m0_platform_data ,
+ . max_speed_hz = 1200000 ,
+ . bus_num = LCD_BUS_NUM ,
+ . chip_select = 0 ,
+ . mode = SPI_MODE_3 ,
+ . controller_data = ( void * ) DISPLAY_CS ,
+ },
+ };
+
+ #define DISPLAY_CLK S5PV210_MP04(1)
+ #define DISPLAY_SI S5PV210_MP04(3)
+ static struct spi_gpio_platform_data lcd_spi_gpio_data = {
+ . sck = DISPLAY_CLK ,
+ . mosi = DISPLAY_SI ,
+ . miso = SPI_GPIO_NO_MISO ,
+
+ . num_chipselect = 1 ,
+ };
+
+ static struct platform_device goni_spi_gpio = {
+ . name = "spi_gpio" ,
+ . id = LCD_BUS_NUM ,
+ . dev = {
+ . parent = & s3c_device_fb . dev ,
+ . platform_data = & lcd_spi_gpio_data ,
+ },
+ };
+
/* KEYPAD */
static uint32_t keymap [] __initdata = {
/* KEY(row, col, keycode) */ @@ -479,6 +546,7 @@ static void goni_setup_sdhci(void)
static struct platform_device * goni_devices [] __initdata = {
& s3c_device_fb ,
& s5p_device_onenand ,
+ & goni_spi_gpio ,
& goni_i2c_gpio_pmic ,
& goni_device_gpiokeys ,
& s5p_device_fimc0 , @@ -509,6 +577,9 @@ static void __init goni_machine_init(void)
/* FB */
s3c_fb_set_platdata ( & goni_lcd_pdata );
+ /* SPI */
+ spi_register_board_info ( spi_board_info , ARRAY_SIZE ( spi_board_info ));
+
/* KEYPAD */
samsung_keypad_set_platdata ( & keypad_data );
--
1.7.2.2
Add required platform definitions for si470x radio device on Samsung
Goni board.
Signed-off-by: Joonyoung Shim <redacted>
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com>
---
arch/arm/mach-s5pv210/Kconfig | 2 ++
arch/arm/mach-s5pv210/mach-goni.c | 29 +++++++++++++++++++++++++++++
2 files changed, 31 insertions(+), 0 deletions(-)
diff --git a/arch/arm/mach-s5pv210/Kconfig b/arch/arm/mach-s5pv210/Kconfig
index b46925b..b1f671d 100644
--- a/arch/arm/mach-s5pv210/Kconfig
+++ b/arch/arm/mach-s5pv210/Kconfig @@ -83,9 +83,11 @@ config MACH_GONI
select S3C_DEV_HSMMC
select S3C_DEV_HSMMC1
select S3C_DEV_HSMMC2
+ select S3C_DEV_I2C1
select S5P_DEV_ONENAND
select SAMSUNG_DEV_KEYPAD
select S5PV210_SETUP_FB_24BPP
+ select S5PV210_SETUP_I2C1
select S5PV210_SETUP_KEYPAD
select S5PV210_SETUP_SDHCI
help diff --git a/arch/arm/mach-s5pv210/mach-goni.c b/arch/arm/mach-s5pv210/mach-goni.c
index b263f3a..30da422 100644
--- a/arch/arm/mach-s5pv210/mach-goni.c
+++ b/arch/arm/mach-s5pv210/mach-goni.c @@ -38,6 +38,7 @@
#include <plat/devs.h>
#include <plat/cpu.h>
#include <plat/fb.h>
+ #include <plat/iic.h>
#include <plat/keypad.h>
#include <plat/sdhci.h>
@@ -200,6 +201,27 @@ static struct samsung_keypad_platdata keypad_data __initdata = {
. cols = 3 ,
};
+ /* Radio */
+ static struct i2c_board_info i2c1_devs [] __initdata = {
+ {
+ I2C_BOARD_INFO ( "si470x" , 0x10 ),
+ },
+ };
+
+ static void __init goni_radio_init ( void )
+ {
+ int gpio ;
+
+ gpio = S5PV210_GPJ2 ( 4 ); /* XMSMDATA_4 */
+ gpio_request ( gpio , "FM_INT" );
+ s3c_gpio_cfgpin ( gpio , S3C_GPIO_SFN ( 0xf ));
+ i2c1_devs [ 0 ]. irq = gpio_to_irq ( gpio );
+
+ gpio = S5PV210_GPJ2 ( 5 ); /* XMSMDATA_5 */
+ gpio_request ( gpio , "FM_RST" );
+ gpio_direction_output ( gpio , 1 );
+ }
+
/* MAX8998 regulators */
#if defined(CONFIG_REGULATOR_MAX8998) || defined(CONFIG_REGULATOR_MAX8998_MODULE)
@@ -567,6 +589,13 @@ static void __init goni_map_io(void)
static void __init goni_machine_init ( void )
{
+ /* Radio: call before I2C 1 registeration */
+ goni_radio_init ();
+
+ /* I2C1 */
+ s3c_i2c1_set_platdata ( NULL );
+ i2c_register_board_info ( 1 , i2c1_devs , ARRAY_SIZE ( i2c1_devs ));
+
/* PMIC */
goni_pmic_init ();
i2c_register_board_info ( AP_I2C_GPIO_PMIC_BUS_4 , i2c_gpio_pmic_devs , --
1.7.2.2
Add the necessary definitions and mapping information to enable the
s3c-hsotg gadget to build.
Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com>
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
---
arch/arm/mach-s5pv210/cpu.c | 5 +++++
arch/arm/mach-s5pv210/include/mach/map.h | 6 ++++++
arch/arm/mach-s5pv210/include/mach/regs-sys.h | 19 +++++++++++++++++++
3 files changed, 30 insertions(+), 0 deletions(-)
create mode 100644 arch/arm/mach-s5pv210/include/mach/regs-sys.h
diff --git a/arch/arm/mach-s5pv210/cpu.c b/arch/arm/mach-s5pv210/cpu.c
index c551ab1..6183b55 100644
--- a/arch/arm/mach-s5pv210/cpu.c
+++ b/arch/arm/mach-s5pv210/cpu.c @@ -84,6 +84,11 @@ static struct map_desc s5pv210_iodesc[] __initdata = {
. pfn = __phys_to_pfn ( S5PV210_PA_SROMC ),
. length = SZ_4K ,
. type = MT_DEVICE ,
+ }, {
+ . virtual = ( unsigned long ) S3C_VA_USB_HSPHY ,
+ . pfn = __phys_to_pfn ( S3C_PA_USB_HSPHY ),
+ . length = SZ_4K ,
+ . type = MT_DEVICE ,
}
};
diff --git a/arch/arm/mach-s5pv210/include/mach/map.h b/arch/arm/mach-s5pv210/include/mach/map.h
index bd9afd5..724a428 100644
--- a/arch/arm/mach-s5pv210/include/mach/map.h
+++ b/arch/arm/mach-s5pv210/include/mach/map.h @@ -73,6 +73,9 @@
#define S5PV210_PA_HSMMC(x) (0xEB000000 + ((x) * 0x100000))
+ #define S5PV210_PA_HSOTG (0xEC000000)
+ #define S5PV210_PA_HSPHY (0xEC100000)
+
#define S5PV210_PA_VIC0 (0xF2000000)
#define S5PV210_PA_VIC1 (0xF2100000)
#define S5PV210_PA_VIC2 (0xF2200000) @@ -111,6 +114,9 @@
#define S5P_PA_FIMC0 S5PV210_PA_FIMC0
#define S5P_PA_FIMC1 S5PV210_PA_FIMC1
#define S5P_PA_FIMC2 S5PV210_PA_FIMC2
+ #define S3C_PA_USB_HSOTG S5PV210_PA_HSOTG
+ #define S3C_PA_USB_HSPHY S5PV210_PA_HSPHY
+ #define S3C_VA_USB_HSPHY S3C_ADDR(0x02000000)
#define SAMSUNG_PA_ADC S5PV210_PA_ADC
#define SAMSUNG_PA_CFCON S5PV210_PA_CFCON diff --git a/arch/arm/mach-s5pv210/include/mach/regs-sys.h b/arch/arm/mach-s5pv210/include/mach/regs-sys.h
new file mode 100644
index 0000000..26691d3
--- /dev/null
+++ b/arch/arm/mach-s5pv210/include/mach/regs-sys.h @@ -0,0 +1,19 @@
+ /* arch/arm/mach-s5pv210/include/mach/regs-sys.h
+ *
+ * Copyright ( c ) 2010 Samsung Electronics Co ., Ltd .
+ * http : //www.samsung.com/
+ *
+ * S5PV210 - System registers 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 .
+ */
+
+ #define S5PV210_USB_PHY_CON (S3C_VA_SYS + 0xE80C)
+ #define S5PV210_USB_PHY0_EN (1 << 0)
+ #define S5PV210_USB_PHY1_EN (1 << 1)
+
+ /* compatibility defines for s3c-hsotg driver */
+ #define S3C64XX_OTHERS S5PV210_USB_PHY_CON
+ #define S3C64XX_OTHERS_USBMASK S5PV210_USB_PHY0_EN --
1.7.2.2
Add required platform definitions for s3c-hsotg driver to enable usb
gadget support on Samsung Goni 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 | 5 +++++
2 files changed, 6 insertions(+), 0 deletions(-)
diff --git a/arch/arm/mach-s5pv210/Kconfig b/arch/arm/mach-s5pv210/Kconfig
index b1f671d..f8bac5a 100644
--- a/arch/arm/mach-s5pv210/Kconfig
+++ b/arch/arm/mach-s5pv210/Kconfig @@ -85,6 +85,7 @@ config MACH_GONI
select S3C_DEV_HSMMC2
select S3C_DEV_I2C1
select S5P_DEV_ONENAND
+ select S3C_DEV_USB_HSOTG
select SAMSUNG_DEV_KEYPAD
select S5PV210_SETUP_FB_24BPP
select S5PV210_SETUP_I2C1 diff --git a/arch/arm/mach-s5pv210/mach-goni.c b/arch/arm/mach-s5pv210/mach-goni.c
index 30da422..b28a42b 100644
--- a/arch/arm/mach-s5pv210/mach-goni.c
+++ b/arch/arm/mach-s5pv210/mach-goni.c @@ -41,6 +41,8 @@
#include <plat/iic.h>
#include <plat/keypad.h>
#include <plat/sdhci.h>
+ #include <plat/clock.h>
+ #include <plat/s5p-clock.h>
/* Following are default values for UCON, ULCON and UFCON UART registers */
#define GONI_UCON_DEFAULT (S3C2410_UCON_TXILEVEL | \ @@ -569,6 +571,7 @@ static struct platform_device *goni_devices[] __initdata = {
& s3c_device_fb ,
& s5p_device_onenand ,
& goni_spi_gpio ,
+ & s3c_device_usb_hsotg ,
& goni_i2c_gpio_pmic ,
& goni_device_gpiokeys ,
& s5p_device_fimc0 , @@ -613,6 +616,8 @@ static void __init goni_machine_init(void)
samsung_keypad_set_platdata ( & keypad_data );
platform_add_devices ( goni_devices , ARRAY_SIZE ( goni_devices ));
+
+ clk_xusbxti . rate = 24000000 ;
}
MACHINE_START ( GONI , "GONI" ) --
1.7.2.2
Add required platform definitions for MMC power regulators on Samsung
Goni board.
Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com>
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
CC: Mark Brown <redacted>
---
arch/arm/mach-s5pv210/mach-goni.c | 44 ++++++++++++++++++++++++++++++++++--
1 files changed, 41 insertions(+), 3 deletions(-)
diff --git a/arch/arm/mach-s5pv210/mach-goni.c b/arch/arm/mach-s5pv210/mach-goni.c
index b28a42b..595afc37 100644
--- a/arch/arm/mach-s5pv210/mach-goni.c
+++ b/arch/arm/mach-s5pv210/mach-goni.c @@ -16,6 +16,7 @@
#include <linux/i2c.h>
#include <linux/i2c-gpio.h>
#include <linux/mfd/max8998.h>
+ #include <linux/regulator/fixed.h>
#include <linux/spi/spi.h>
#include <linux/spi/spi_gpio.h>
#include <linux/lcd.h> @@ -227,6 +228,10 @@ static void __init goni_radio_init(void)
/* MAX8998 regulators */
#if defined(CONFIG_REGULATOR_MAX8998) || defined(CONFIG_REGULATOR_MAX8998_MODULE)
+ static struct regulator_consumer_supply goni_ldo5_consumers [] = {
+ { . supply = "vmmc" , . dev = & s3c_device_hsmmc0 . dev },
+ };
+
static struct regulator_init_data goni_ldo2_data = {
. constraints = {
. name = "VALIVE_1.1V" , @@ -266,6 +271,8 @@ static struct regulator_init_data goni_ldo5_data = {
. max_uV = 2800000 ,
. apply_uV = 1 ,
},
+ . num_consumer_supplies = ARRAY_SIZE ( goni_ldo5_consumers ),
+ . consumer_supplies = goni_ldo5_consumers ,
};
static struct regulator_init_data goni_ldo6_data = { @@ -471,6 +478,39 @@ static struct max8998_platform_data goni_max8998_pdata = {
. num_regulators = ARRAY_SIZE ( goni_regulators ),
. regulators = goni_regulators ,
};
+
+ static struct regulator_consumer_supply mmc2_supplies [] = {
+ {
+ . dev = & s3c_device_hsmmc2 . dev ,
+ . supply = "vmmc" ,
+ },
+ };
+
+ static struct regulator_init_data mmc2_fixed_voltage_init_data = {
+ . constraints = {
+ . name = "V_TF_2.8V" ,
+ . valid_ops_mask = REGULATOR_CHANGE_STATUS ,
+ },
+ . num_consumer_supplies = ARRAY_SIZE ( mmc2_supplies ),
+ . consumer_supplies = mmc2_supplies ,
+ };
+
+ static struct fixed_voltage_config mmc2_fixed_voltage_config = {
+ . supply_name = "T_FLASH_EN" ,
+ . microvolts = 2800000 ,
+ . gpio = S5PV210_MP05 ( 4 ), /* XM0ADDR_12 */
+ . enable_high = true ,
+ . init_data = & mmc2_fixed_voltage_init_data ,
+ };
+
+ static struct platform_device mmc2_fixed_voltage = {
+ . name = "reg-fixed-voltage" ,
+ . id = 2 ,
+ . dev = {
+ . platform_data = & mmc2_fixed_voltage_config ,
+ },
+ };
+
#endif
/* GPIO I2C PMIC */ @@ -559,9 +599,6 @@ static struct s3c_sdhci_platdata goni_hsmmc2_data __initdata = {
static void goni_setup_sdhci ( void )
{
- gpio_request ( GONI_EXT_FLASH_EN , "FLASH_EN" );
- gpio_direction_output ( GONI_EXT_FLASH_EN , 1 );
-
s3c_sdhci0_set_platdata ( & goni_hsmmc0_data );
s3c_sdhci1_set_platdata ( & goni_hsmmc1_data );
s3c_sdhci2_set_platdata ( & goni_hsmmc2_data ); @@ -573,6 +610,7 @@ static struct platform_device *goni_devices[] __initdata = {
& goni_spi_gpio ,
& s3c_device_usb_hsotg ,
& goni_i2c_gpio_pmic ,
+ & mmc2_fixed_voltage ,
& goni_device_gpiokeys ,
& s5p_device_fimc0 ,
& s5p_device_fimc1 , --
1.7.2.2
On Fri, Sep 10, 2010 at 09:23:23AM +0200, Marek Szyprowski wrote:
+static struct regulator_consumer_supply goni_ldo5_consumers[] = {
+ { .supply = "vmmc", .dev = &s3c_device_hsmmc0.dev },
+};
+
This is OK but it is better to use dev_name rather than dev - dev may
be removed at some point since given dev you can always use dev_name but
you don't always have dev.
Acked-by: Mark Brown <redacted>
Marek Szyprowski wrote:
Change the default upper_margin and vsync_len to get rid of repeated last
line on the display. How about Aquila board? Maybe same in my thinking.
And it'd better that another stuff like removing pixclock is in different
patch.
Anyway, looks ok to me...will apply.
quoted hunk 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 | 5 ++---
1 files changed, 2 insertions(+), 3 deletions(-)
diff --git a/arch/arm/mach-s5pv210/mach-goni.c b/arch/arm/mach-s5pv210/mach- quoted hunk goni.c
index d9fe739..b0ae208 100644 --- a/arch/arm/mach-s5pv210/mach-goni.c
+++ b/arch/arm/mach-s5pv210/mach-goni.c @@ -88,13 +88,12 @@ static struct s3c2410_uartcfg goni_uartcfgs[] __initdata = { /* Frame Buffer */
static struct s3c_fb_pd_win goni_fb_win0 = {
.win_mode = {
- .pixclock = 1000000000000ULL /
((16+16+2+480)*(28+3+2+800)*55),
.left_margin = 16,
.right_margin = 16,
- .upper_margin = 3,
+ .upper_margin = 2,
.lower_margin = 28,
.hsync_len = 2,
- .vsync_len = 2,
+ .vsync_len = 1,
.xres = 480,
.yres = 800,
.refresh = 55,
--
1.7.2.2
Thanks.
Best regards,
Kgene.
--
Kukjin Kim [off-list ref], Senior Engineer,
SW Solution Development Team, Samsung Electronics Co., Ltd.
Marek Szyprowski wrote: quoted hunk
Add required platform definitions for MMC power regulators on Samsung
Goni board.
Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com>
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
CC: Mark Brown <redacted>
---
arch/arm/mach-s5pv210/mach-goni.c | 44
++++++++++++++++++++++++++++++++++--
1 files changed, 41 insertions(+), 3 deletions(-)
diff --git a/arch/arm/mach-s5pv210/mach-goni.c b/arch/arm/mach-s5pv210/mach- quoted hunk goni.c
index b28a42b..595afc37 100644 --- a/arch/arm/mach-s5pv210/mach-goni.c
+++ b/arch/arm/mach-s5pv210/mach-goni.c @@ -16,6 +16,7 @@
#include <linux/i2c.h>
#include <linux/i2c-gpio.h>
#include <linux/mfd/max8998.h>
+ #include <linux/regulator/fixed.h>
#include <linux/spi/spi.h>
#include <linux/spi/spi_gpio.h>
#include <linux/lcd.h> @@ -227,6 +228,10 @@ static void __init goni_radio_init(void)
/* MAX8998 regulators */
#if defined(CONFIG_REGULATOR_MAX8998) || defined(CONFIG_REGULATOR_MAX8998_MODULE)
+static struct regulator_consumer_supply goni_ldo5_consumers[] = {
+ { .supply = "vmmc", .dev = &s3c_device_hsmmc0.dev },
+};
+
static struct regulator_init_data goni_ldo2_data = {
.constraints = {
.name = "VALIVE_1.1V", @@ -266,6 +271,8 @@ static struct regulator_init_data goni_ldo5_data = {
.max_uV = 2800000,
.apply_uV = 1,
},
+ .num_consumer_supplies = ARRAY_SIZE(goni_ldo5_consumers),
+ .consumer_supplies = goni_ldo5_consumers,
};
static struct regulator_init_data goni_ldo6_data = { @@ -471,6 +478,39 @@ static struct max8998_platform_data goni_max8998_pdata = {
.num_regulators = ARRAY_SIZE(goni_regulators),
.regulators = goni_regulators,
};
+
+static struct regulator_consumer_supply mmc2_supplies[] = {
+ {
+ .dev = &s3c_device_hsmmc2.dev,
+ .supply = "vmmc",
+ },
+};
+
+static struct regulator_init_data mmc2_fixed_voltage_init_data = {
+ .constraints = {
+ .name = "V_TF_2.8V",
+ .valid_ops_mask = REGULATOR_CHANGE_STATUS,
+ },
+ .num_consumer_supplies = ARRAY_SIZE(mmc2_supplies),
+ .consumer_supplies = mmc2_supplies,
+};
+
+static struct fixed_voltage_config mmc2_fixed_voltage_config = {
+ .supply_name = "T_FLASH_EN",
+ .microvolts = 2800000,
+ .gpio = S5PV210_MP05(4), /* XM0ADDR_12 */
+ .enable_high = true,
+ .init_data = &mmc2_fixed_voltage_init_data,
+};
+
+static struct platform_device mmc2_fixed_voltage = {
+ .name = "reg-fixed-voltage",
+ .id = 2,
+ .dev = {
+ .platform_data = &mmc2_fixed_voltage_config,
+ },
+};
+
#endif
/* GPIO I2C PMIC */ @@ -559,9 +599,6 @@ static struct s3c_sdhci_platdata goni_hsmmc2_data __initdata = {
static void goni_setup_sdhci(void)
{
- gpio_request(GONI_EXT_FLASH_EN, "FLASH_EN");
- gpio_direction_output(GONI_EXT_FLASH_EN, 1);
-
Why need above changes in this patch?
Others, looks ok.
quoted hunk s3c_sdhci0_set_platdata(&goni_hsmmc0_data);
s3c_sdhci1_set_platdata(&goni_hsmmc1_data);
s3c_sdhci2_set_platdata(&goni_hsmmc2_data); @@ -573,6 +610,7 @@ static struct platform_device *goni_devices[] __initdata = { &goni_spi_gpio,
&s3c_device_usb_hsotg,
&goni_i2c_gpio_pmic,
+ &mmc2_fixed_voltage,
&goni_device_gpiokeys,
&s5p_device_fimc0,
&s5p_device_fimc1,
--
Thanks.
Best regards,
Kgene.
--
Kukjin Kim [off-list ref], Senior Engineer,
SW Solution Development Team, Samsung Electronics Co., Ltd.
Marek Szyprowski wrote:
Add required platform definitions for si470x radio device on Samsung
Goni board. Is this the same with following?
http://marc.info/?l=linux-arm-kernel&m=128220793700997&w=2
quoted hunk Signed-off-by: Joonyoung Shim <redacted>
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com>
---
arch/arm/mach-s5pv210/Kconfig | 2 ++
arch/arm/mach-s5pv210/mach-goni.c | 29
+++++++++++++++++++++++++++++
2 files changed, 31 insertions(+), 0 deletions(-)
diff --git a/arch/arm/mach-s5pv210/Kconfig b/arch/arm/mach-s5pv210/Kconfig
index b46925b..b1f671d 100644
--- a/arch/arm/mach-s5pv210/Kconfig
+++ b/arch/arm/mach-s5pv210/Kconfig @@ -83,9 +83,11 @@ config MACH_GONI
select S3C_DEV_HSMMC
select S3C_DEV_HSMMC1
select S3C_DEV_HSMMC2
+ select S3C_DEV_I2C1
select S5P_DEV_ONENAND
select SAMSUNG_DEV_KEYPAD
select S5PV210_SETUP_FB_24BPP
+ select S5PV210_SETUP_I2C1
select S5PV210_SETUP_KEYPAD
select S5PV210_SETUP_SDHCI
help diff --git a/arch/arm/mach-s5pv210/mach-goni.c b/arch/arm/mach-s5pv210/mach- quoted hunk goni.c
index b263f3a..30da422 100644 --- a/arch/arm/mach-s5pv210/mach-goni.c
+++ b/arch/arm/mach-s5pv210/mach-goni.c @@ -38,6 +38,7 @@
#include <plat/devs.h>
#include <plat/cpu.h>
#include <plat/fb.h>
+ #include <plat/iic.h>
#include <plat/keypad.h>
#include <plat/sdhci.h>
@@ -200,6 +201,27 @@ static struct samsung_keypad_platdata keypad_data __initdata = {
.cols = 3,
};
+/* Radio */
+static struct i2c_board_info i2c1_devs[] __initdata = {
+ {
+ I2C_BOARD_INFO("si470x", 0x10),
+ },
+};
+
+static void __init goni_radio_init(void)
+{
+ int gpio;
+
+ gpio = S5PV210_GPJ2(4); /* XMSMDATA_4 */
+ gpio_request(gpio, "FM_INT");
+ s3c_gpio_cfgpin(gpio, S3C_GPIO_SFN(0xf));
+ i2c1_devs[0].irq = gpio_to_irq(gpio);
+
+ gpio = S5PV210_GPJ2(5); /* XMSMDATA_5 */
+ gpio_request(gpio, "FM_RST");
+ gpio_direction_output(gpio, 1);
+}
+
/* MAX8998 regulators */
#if defined(CONFIG_REGULATOR_MAX8998) ||
defined(CONFIG_REGULATOR_MAX8998_MODULE)
@@ -567,6 +589,13 @@ static void __init goni_map_io(void)
static void __init goni_machine_init(void)
{
+ /* Radio: call before I2C 1 registeration */
+ goni_radio_init();
+
+ /* I2C1 */
+ s3c_i2c1_set_platdata(NULL);
+ i2c_register_board_info(1, i2c1_devs, ARRAY_SIZE(i2c1_devs));
+
/* PMIC */
goni_pmic_init();
i2c_register_board_info(AP_I2C_GPIO_PMIC_BUS_4, i2c_gpio_pmic_devs,
--
Thanks.
Best regards,
Kgene.
--
Kukjin Kim [off-list ref], Senior Engineer,
SW Solution Development Team, Samsung Electronics Co., Ltd.
On Fri, Sep 10, 2010 at 06:55:50PM +0900, Kukjin Kim wrote: quoted +static struct fixed_voltage_config mmc2_fixed_voltage_config = {
+ .supply_name = "T_FLASH_EN",
+ .microvolts = 2800000,
+ .gpio = S5PV210_MP05(4), /* XM0ADDR_12 */
...
quoted static void goni_setup_sdhci(void)
{
- gpio_request(GONI_EXT_FLASH_EN, "FLASH_EN");
- gpio_direction_output(GONI_EXT_FLASH_EN, 1);
- Why need above changes in this patch?
Others, looks ok.
It looks like ownership of this GPIO has been transferred to the fixed
voltage regulator added in the patch (though using the #define in the
fixed voltage regulator platform data might be a good idea).
Marek Szyprowski wrote: quoted hunk
Add the necessary definitions and mapping information to enable the
s3c-hsotg gadget to build.
Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com>
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
---
arch/arm/mach-s5pv210/cpu.c | 5 +++++
arch/arm/mach-s5pv210/include/mach/map.h | 6 ++++++
arch/arm/mach-s5pv210/include/mach/regs-sys.h | 19
+++++++++++++++++++
3 files changed, 30 insertions(+), 0 deletions(-)
create mode 100644 arch/arm/mach-s5pv210/include/mach/regs-sys.h
diff --git a/arch/arm/mach-s5pv210/cpu.c b/arch/arm/mach-s5pv210/cpu.c
index c551ab1..6183b55 100644
--- a/arch/arm/mach-s5pv210/cpu.c
+++ b/arch/arm/mach-s5pv210/cpu.c @@ -84,6 +84,11 @@ static struct map_desc s5pv210_iodesc[] __initdata = {
. pfn = __phys_to_pfn ( S5PV210_PA_SROMC ),
. length = SZ_4K ,
. type = MT_DEVICE ,
+ }, {
+ . virtual = ( unsigned long ) S3C_VA_USB_HSPHY ,
+ . pfn = __phys_to_pfn ( S3C_PA_USB_HSPHY ),
It's better to use S5PV210_PA_HSPHY directly without re-mapping.
Because don't need S3C_PA_USB_HSPHY except here.
quoted hunk + .length = SZ_4K,
+ .type = MT_DEVICE,
}
};
diff --git a/arch/arm/mach-s5pv210/include/mach/map.h b/arch/arm/mach- s5pv210/include/mach/map.h
index bd9afd5..724a428 100644 --- a/arch/arm/mach-s5pv210/include/mach/map.h
+++ b/arch/arm/mach-s5pv210/include/mach/map.h @@ -73,6 +73,9 @@
#define S5PV210_PA_HSMMC(x) (0xEB000000 + ((x) * 0x100000))
+ #define S5PV210_PA_HSOTG (0xEC000000)
+ #define S5PV210_PA_HSPHY (0xEC100000)
+
#define S5PV210_PA_VIC0 (0xF2000000)
#define S5PV210_PA_VIC1 (0xF2100000)
#define S5PV210_PA_VIC2 (0xF2200000) @@ -111,6 +114,9 @@
#define S5P_PA_FIMC0 S5PV210_PA_FIMC0
#define S5P_PA_FIMC1 S5PV210_PA_FIMC1
#define S5P_PA_FIMC2 S5PV210_PA_FIMC2
+ #define S3C_PA_USB_HSOTG S5PV210_PA_HSOTG
IMHO, would be better if we could define S3C_PA_XXX first than S5P_PA_XXX.
+#define S3C_PA_USB_HSPHY S5PV210_PA_HSPHY
As I said, no need re-mapping to S3C_PA_USB_HSPHY.
+#define S3C_VA_USB_HSPHY S3C_ADDR(0x02000000) How about moving definition of VA_ to plat/map-s5p.h or plat/map-base.h?
Yeah, I know in the case of s3c64xx, same address mapping is in mach/map.h.
quoted hunk #define SAMSUNG_PA_ADC S5PV210_PA_ADC
#define SAMSUNG_PA_CFCON S5PV210_PA_CFCON diff --git a/arch/arm/mach-s5pv210/include/mach/regs-sys.h b/arch/arm/mach- quoted hunk s5pv210/include/mach/regs-sys.h
new file mode 100644
index 0000000..26691d3 --- /dev/null
+++ b/arch/arm/mach-s5pv210/include/mach/regs-sys.h @@ -0,0 +1,19 @@
+ /* arch/arm/mach-s5pv210/include/mach/regs-sys.h
+ *
+ * Copyright ( c ) 2010 Samsung Electronics Co ., Ltd .
+ * http : //www.samsung.com/
+ *
+ * S5PV210 - System registers 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 .
+ */
+
+ #define S5PV210_USB_PHY_CON (S3C_VA_SYS + 0xE80C)
+ #define S5PV210_USB_PHY0_EN (1 << 0)
+ #define S5PV210_USB_PHY1_EN (1 << 1)
+
+ /* compatibility defines for s3c-hsotg driver */
+ #define S3C64XX_OTHERS S5PV210_USB_PHY_CON
+ #define S3C64XX_OTHERS_USBMASK S5PV210_USB_PHY0_EN
- -
Others, ok.
Thanks.
Best regards,
Kgene.
--
Kukjin Kim [off-list ref], Senior Engineer,
SW Solution Development Team, Samsung Electronics Co., Ltd.
Marek Szyprowski wrote: quoted hunk
Add required platform definitions for s3c-hsotg driver to enable usb
gadget support on Samsung Goni 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 | 5 +++++
2 files changed, 6 insertions(+), 0 deletions(-)
diff --git a/arch/arm/mach-s5pv210/Kconfig b/arch/arm/mach-s5pv210/Kconfig
index b1f671d..f8bac5a 100644
--- a/arch/arm/mach-s5pv210/Kconfig
+++ b/arch/arm/mach-s5pv210/Kconfig @@ -85,6 +85,7 @@ config MACH_GONI
select S3C_DEV_HSMMC2
select S3C_DEV_I2C1
select S5P_DEV_ONENAND
+ select S3C_DEV_USB_HSOTG
select SAMSUNG_DEV_KEYPAD
select S5PV210_SETUP_FB_24BPP
select S5PV210_SETUP_I2C1 diff --git a/arch/arm/mach-s5pv210/mach-goni.c b/arch/arm/mach-s5pv210/mach- quoted hunk goni.c
index 30da422..b28a42b 100644 --- a/arch/arm/mach-s5pv210/mach-goni.c
+++ b/arch/arm/mach-s5pv210/mach-goni.c @@ -41,6 +41,8 @@
#include <plat/iic.h>
#include <plat/keypad.h>
#include <plat/sdhci.h>
+ #include <plat/clock.h>
+ #include <plat/s5p-clock.h>
Hmm...same 'extern struct clk_xusbxti' defined both.
I will sort out :-)
I think, just one inclusion is enough now.
If any problems, please let me know.
/* Following are default values for UCON, ULCON and UFCON UART registers */ quoted hunk #define GONI_UCON_DEFAULT (S3C2410_UCON_TXILEVEL | \ @@ -569,6 +571,7 @@ static struct platform_device *goni_devices[] __initdata = { quoted hunk &s3c_device_fb,
&s5p_device_onenand,
&goni_spi_gpio,
+ &s3c_device_usb_hsotg,
&goni_i2c_gpio_pmic,
&goni_device_gpiokeys,
&s5p_device_fimc0, @@ -613,6 +616,8 @@ static void __init goni_machine_init(void)
samsung_keypad_set_platdata(&keypad_data);
platform_add_devices(goni_devices, ARRAY_SIZE(goni_devices));
+
+ clk_xusbxti.rate = 24000000;
}
MACHINE_START(GONI, "GONI")
- -
Thanks.
Best regards,
Kgene.
--
Kukjin Kim [off-list ref], Senior Engineer,
SW Solution Development Team, Samsung Electronics Co., Ltd.
Hi Kgene,
Actually IMHO these basic devices connected at AP are done by System
LSI. Anyway I hope you or your team implement SMDK board support fully
first. Now SMDK board is just placeholder and not much features.
My request is that these are supported on mainline at least.
1. Basic AP peripherals support. RTC, timer, and so on.
2. Suspend & wakeup,
3. clock & power gating.
I think these features are SoC specific and it's under
arch/arm/mach-samsung-soc. So no need to communicate with other
subsystem. just implement it and verified at your side.
I hope use the mainline kernel for our board.
Thank you,
Kyungmin Park
On Fri, Sep 10, 2010 at 7:33 PM, Kukjin Kim [off-list ref] wrote: Marek Szyprowski wrote: quoted
Add the necessary definitions and mapping information to enable the
s3c-hsotg gadget to build.
Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com>
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
---
?arch/arm/mach-s5pv210/cpu.c ? ? ? ? ? ? ? ? ? | ? ?5 +++++
?arch/arm/mach-s5pv210/include/mach/map.h ? ? ?| ? ?6 ++++++
?arch/arm/mach-s5pv210/include/mach/regs-sys.h | ? 19
+++++++++++++++++++
?3 files changed, 30 insertions(+), 0 deletions(-)
?create mode 100644 arch/arm/mach-s5pv210/include/mach/regs-sys.h
diff --git a/arch/arm/mach-s5pv210/cpu.c b/arch/arm/mach-s5pv210/cpu.c
index c551ab1..6183b55 100644
--- a/arch/arm/mach-s5pv210/cpu.c
+++ b/arch/arm/mach-s5pv210/cpu.c @@ -84,6 +84,11 @@ static struct map_desc s5pv210_iodesc[] __initdata = { ? ? ? ? ? ? ? .pfn ? ? ? ? ? ?= __phys_to_pfn(S5PV210_PA_SROMC),
? ? ? ? ? ? ? .length ? ? ? ? = SZ_4K,
? ? ? ? ? ? ? .type ? ? ? ? ? = MT_DEVICE,
+ ? ? }, {
+ ? ? ? ? ? ? .virtual ? ? ? ?= (unsigned long)S3C_VA_USB_HSPHY,
+ ? ? ? ? ? ? .pfn ? ? ? ? ? ?=__phys_to_pfn(S3C_PA_USB_HSPHY),
It's better to use S5PV210_PA_HSPHY directly without re-mapping.
Because don't need S3C_PA_USB_HSPHY except here.
quoted + ? ? ? ? ? ? .length ? ? ? ? = SZ_4K,
+ ? ? ? ? ? ? .type ? ? ? ? ? = MT_DEVICE,
? ? ? }
?};
diff --git a/arch/arm/mach-s5pv210/include/mach/map.h b/arch/arm/mach- s5pv210/include/mach/map.h
index bd9afd5..724a428 100644 --- a/arch/arm/mach-s5pv210/include/mach/map.h
+++ b/arch/arm/mach-s5pv210/include/mach/map.h ?#define S5PV210_PA_HSMMC(x) ?(0xEB000000 + ((x) * 0x100000))
+#define S5PV210_PA_HSOTG ? ? (0xEC000000)
+#define S5PV210_PA_HSPHY ? ? (0xEC100000)
+
?#define S5PV210_PA_VIC0 ? ? ? ? ? ? ?(0xF2000000)
?#define S5PV210_PA_VIC1 ? ? ? ? ? ? ?(0xF2100000)
?#define S5PV210_PA_VIC2 ? ? ? ? ? ? ?(0xF2200000) ?#define S5P_PA_FIMC0 ? ? ? ? S5PV210_PA_FIMC0
?#define S5P_PA_FIMC1 ? ? ? ? S5PV210_PA_FIMC1
?#define S5P_PA_FIMC2 ? ? ? ? S5PV210_PA_FIMC2
+#define S3C_PA_USB_HSOTG ? ? S5PV210_PA_HSOTG
IMHO, would be better if we could define S3C_PA_XXX first than S5P_PA_XXX.
quoted +#define S3C_PA_USB_HSPHY ? ? S5PV210_PA_HSPHY
As I said, no need re-mapping to S3C_PA_USB_HSPHY.
quoted +#define S3C_VA_USB_HSPHY ? ? S3C_ADDR(0x02000000) How about moving definition of VA_ to plat/map-s5p.h or plat/map-base.h?
Yeah, I know in the case of s3c64xx, same address mapping is in mach/map.h.
quoted ?#define SAMSUNG_PA_ADC ? ? ? ? ? ? ? S5PV210_PA_ADC
?#define SAMSUNG_PA_CFCON ? ? S5PV210_PA_CFCON diff --git a/arch/arm/mach-s5pv210/include/mach/regs-sys.h b/arch/arm/mach- quoted s5pv210/include/mach/regs-sys.h
new file mode 100644
index 0000000..26691d3 --- /dev/null
+++ b/arch/arm/mach-s5pv210/include/mach/regs-sys.h @@ -0,0 +1,19 @@
+ /* arch/arm/mach-s5pv210/include/mach/regs-sys.h
+ *
+ * Copyright ( c ) 2010 Samsung Electronics Co ., Ltd .
+ * ? ? ? ? ? http : //www.samsung.com/
+ *
+ * S5PV210 - System registers 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 .
+ */
+
+ #define S5PV210_USB_PHY_CON ?(S3C_VA_SYS + 0xE80C)
+ #define S5PV210_USB_PHY0_EN ?(1 << 0)
+ #define S5PV210_USB_PHY1_EN ?(1 << 1)
+
+ /* compatibility defines for s3c-hsotg driver */
+ #define S3C64XX_OTHERS ? ? ? ? ? ? ? S5PV210_USB_PHY_CON
+ #define S3C64XX_OTHERS_USBMASK ? ? ? S5PV210_USB_PHY0_EN
- -
Others, ok.
Thanks.
Best regards,
Kgene.
--
Kukjin Kim [off-list ref], Senior Engineer,
SW Solution Development Team, Samsung Electronics Co., Ltd.
--
To unsubscribe from this list: send the line "unsubscribe linux-samsung-soc" in
the body of a message to majordomo at vger.kernel.org
More majordomo info at ?http://vger.kernel.org/majordomo-info.html
Hello,
On Friday, September 10, 2010 11:50 AM Kukjin Kim wrote:
Marek Szyprowski wrote: quoted
Change the default upper_margin and vsync_len to get rid of repeated last
line on the display. How about Aquila board? Maybe same in my thinking.
Yes, I will send a similar patch once I do a test. Had no access to Aquila
board that time.
And it'd better that another stuff like removing pixclock is in different
patch.
Well, Goni machine was the last one that had pixelclock defined. All other
boards had pixel clock definition already removed, so I thought that it would
be a good opportunity to fix this together with screen definition update.
Anyway, looks ok to me...will apply.
Thx
quoted 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 | 5 ++---
1 files changed, 2 insertions(+), 3 deletions(-)
diff --git a/arch/arm/mach-s5pv210/mach-goni.c b/arch/arm/mach-s5pv210/mach- quoted goni.c
index d9fe739..b0ae208 100644 --- a/arch/arm/mach-s5pv210/mach-goni.c
+++ b/arch/arm/mach-s5pv210/mach-goni.c @@ -88,13 +88,12 @@ static struct s3c2410_uartcfg goni_uartcfgs[] __initdata = { quoted /* Frame Buffer */
static struct s3c_fb_pd_win goni_fb_win0 = {
.win_mode = {
- .pixclock = 1000000000000ULL /
((16+16+2+480)*(28+3+2+800)*55),
.left_margin = 16,
.right_margin = 16,
- .upper_margin = 3,
+ .upper_margin = 2,
.lower_margin = 28,
.hsync_len = 2,
- .vsync_len = 2,
+ .vsync_len = 1,
.xres = 480,
.yres = 800,
.refresh = 55,
--
1.7.2.2
Best regards
--
Marek Szyprowski
Samsung Poland R&D Center
Hello,
On Friday, September 10, 2010 11:58 AM Kukjin Kim wrote:
Marek Szyprowski wrote: quoted
Add required platform definitions for si470x radio device on Samsung
Goni board. Is this the same with following?
http://marc.info/?l=linux-arm-kernel&m=128220793700997&w=2
Yes, but I rebased it onto latest kgene/for-next kernel tree together with
other Goni patches. I did this to collect all Goni patches together for
easier merging.
quoted Signed-off-by: Joonyoung Shim <redacted>
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com>
---
arch/arm/mach-s5pv210/Kconfig | 2 ++
arch/arm/mach-s5pv210/mach-goni.c | 29
+++++++++++++++++++++++++++++
2 files changed, 31 insertions(+), 0 deletions(-)
diff --git a/arch/arm/mach-s5pv210/Kconfig b/arch/arm/mach- s5pv210/Kconfig quoted index b46925b..b1f671d 100644 --- a/arch/arm/mach-s5pv210/Kconfig
+++ b/arch/arm/mach-s5pv210/Kconfig @@ -83,9 +83,11 @@ config MACH_GONI
select S3C_DEV_HSMMC
select S3C_DEV_HSMMC1
select S3C_DEV_HSMMC2
+ select S3C_DEV_I2C1
select S5P_DEV_ONENAND
select SAMSUNG_DEV_KEYPAD
select S5PV210_SETUP_FB_24BPP
+ select S5PV210_SETUP_I2C1
select S5PV210_SETUP_KEYPAD
select S5PV210_SETUP_SDHCI
help diff --git a/arch/arm/mach-s5pv210/mach-goni.c b/arch/arm/mach-s5pv210/mach- quoted goni.c
index b263f3a..30da422 100644 --- a/arch/arm/mach-s5pv210/mach-goni.c
+++ b/arch/arm/mach-s5pv210/mach-goni.c @@ -38,6 +38,7 @@
#include <plat/devs.h>
#include <plat/cpu.h>
#include <plat/fb.h>
+ #include <plat/iic.h>
#include <plat/keypad.h>
#include <plat/sdhci.h>
@@ -200,6 +201,27 @@ static struct samsung_keypad_platdata keypad_data __initdata = {
.cols = 3,
};
+/* Radio */
+static struct i2c_board_info i2c1_devs[] __initdata = {
+ {
+ I2C_BOARD_INFO("si470x", 0x10),
+ },
+};
+
+static void __init goni_radio_init(void)
+{
+ int gpio;
+
+ gpio = S5PV210_GPJ2(4); /* XMSMDATA_4 */
+ gpio_request(gpio, "FM_INT");
+ s3c_gpio_cfgpin(gpio, S3C_GPIO_SFN(0xf));
+ i2c1_devs[0].irq = gpio_to_irq(gpio);
+
+ gpio = S5PV210_GPJ2(5); /* XMSMDATA_5 */
+ gpio_request(gpio, "FM_RST");
+ gpio_direction_output(gpio, 1);
+}
+
/* MAX8998 regulators */
#if defined(CONFIG_REGULATOR_MAX8998) ||
defined(CONFIG_REGULATOR_MAX8998_MODULE)
@@ -567,6 +589,13 @@ static void __init goni_map_io(void)
static void __init goni_machine_init(void)
{
+ /* Radio: call before I2C 1 registeration */
+ goni_radio_init();
+
+ /* I2C1 */
+ s3c_i2c1_set_platdata(NULL);
+ i2c_register_board_info(1, i2c1_devs, ARRAY_SIZE(i2c1_devs));
+
/* PMIC */
goni_pmic_init();
i2c_register_board_info(AP_I2C_GPIO_PMIC_BUS_4, i2c_gpio_pmic_devs,
--
Best regards
--
Marek Szyprowski
Samsung Poland R&D Center
Hello,
On Friday, September 10, 2010 12:45 PM Kukjin Kim wrote:
Marek Szyprowski wrote: quoted
Add required platform definitions for s3c-hsotg driver to enable usb
gadget support on Samsung Goni 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 | 5 +++++
2 files changed, 6 insertions(+), 0 deletions(-)
diff --git a/arch/arm/mach-s5pv210/Kconfig b/arch/arm/mach- s5pv210/Kconfig quoted index b1f671d..f8bac5a 100644 --- a/arch/arm/mach-s5pv210/Kconfig
+++ b/arch/arm/mach-s5pv210/Kconfig @@ -85,6 +85,7 @@ config MACH_GONI
select S3C_DEV_HSMMC2
select S3C_DEV_I2C1
select S5P_DEV_ONENAND
+ select S3C_DEV_USB_HSOTG
select SAMSUNG_DEV_KEYPAD
select S5PV210_SETUP_FB_24BPP
select S5PV210_SETUP_I2C1 diff --git a/arch/arm/mach-s5pv210/mach-goni.c b/arch/arm/mach-s5pv210/mach- quoted goni.c
index 30da422..b28a42b 100644 --- a/arch/arm/mach-s5pv210/mach-goni.c
+++ b/arch/arm/mach-s5pv210/mach-goni.c @@ -41,6 +41,8 @@
#include <plat/iic.h>
#include <plat/keypad.h>
#include <plat/sdhci.h>
+ #include <plat/clock.h>
+ #include <plat/s5p-clock.h>
Hmm...same 'extern struct clk_xusbxti' defined both.
I will sort out :-)
I think, just one inclusion is enough now.
Ok. I will fix this. This patch is quite old and I remember that
some time ago both includes were required.
If any problems, please let me know.
quoted
/* Following are default values for UCON, ULCON and UFCON UART registers */ quoted #define GONI_UCON_DEFAULT (S3C2410_UCON_TXILEVEL | \ @@ -569,6 +571,7 @@ static struct platform_device *goni_devices[] __initdata = { quoted &s3c_device_fb,
&s5p_device_onenand,
&goni_spi_gpio,
+ &s3c_device_usb_hsotg,
&goni_i2c_gpio_pmic,
&goni_device_gpiokeys,
&s5p_device_fimc0, @@ -613,6 +616,8 @@ static void __init goni_machine_init(void)
samsung_keypad_set_platdata(&keypad_data);
platform_add_devices(goni_devices, ARRAY_SIZE(goni_devices));
+
+ clk_xusbxti.rate = 24000000;
}
MACHINE_START(GONI, "GONI")
- -
Best regards
--
Marek Szyprowski
Samsung Poland R&D Center