1 /* linux/arch/arm/plat-samsung/dev-i2c7.c
3 * Copyright (c) 2010 Samsung Electronics Co., Ltd.
4 * http://www.samsung.com/
6 * S3C series device definition for i2c device 8
8 * Based on plat-samsung/dev-i2c8.c
10 * This program is free software; you can redistribute it and/or modify
11 * it under the terms of the GNU General Public License version 2 as
12 * published by the Free Software Foundation.
15 #include <linux/gfp.h>
16 #include <linux/kernel.h>
17 #include <linux/string.h>
18 #include <linux/platform_device.h>
20 #include <mach/irqs.h>
23 #include <plat/regs-iic.h>
25 #include <plat/devs.h>
28 static struct resource s3c_i2c_resource[] = {
31 .end = S3C_PA_IIC8 + SZ_4K - 1,
32 .flags = IORESOURCE_MEM,
37 .flags = IORESOURCE_IRQ,
41 struct platform_device s3c_device_i2c8 = {
42 .name = "s3c2440-hdmiphy-i2c",
44 .num_resources = ARRAY_SIZE(s3c_i2c_resource),
45 .resource = s3c_i2c_resource,
48 static struct s3c2410_platform_i2c default_i2c_data8 __initdata = {
52 .frequency = 400*1000,
56 void __init s3c_i2c8_set_platdata(struct s3c2410_platform_i2c *pd)
58 struct s3c2410_platform_i2c *npd;
61 pd = &default_i2c_data8;
63 npd = kmemdup(pd, sizeof(struct s3c2410_platform_i2c), GFP_KERNEL);
65 printk(KERN_ERR "%s: no memory for platform data\n", __func__);
67 s3c_device_i2c8.dev.platform_data = npd;