change prefix for kernelpatchbase 2.6.26
[openwrt/svn-archive/archive.git] / target / linux / s3c24xx / patches-2.6.26 / 1234-pcf50606-fix-gllin-compat-link.patch
1 From 38581b29a95f542e5696f436fea874a881f75825 Mon Sep 17 00:00:00 2001
2 From: Cesar Eduardo Barros <cesarb@cesarb.net>
3 Date: Mon, 4 Aug 2008 08:34:50 +0100
4 Subject: [PATCH] pcf50606: fix gllin compat link
5
6 Uses bus_create_device_link to correctly create the gllin compat link.
7
8 Signed-off-by: Cesar Eduardo Barros <cesarb@cesarb.net>
9 ---
10 drivers/i2c/chips/pcf50606.c | 17 +++--------------
11 1 files changed, 3 insertions(+), 14 deletions(-)
12
13 diff --git a/drivers/i2c/chips/pcf50606.c b/drivers/i2c/chips/pcf50606.c
14 index 4218917..c97cad3 100644
15 --- a/drivers/i2c/chips/pcf50606.c
16 +++ b/drivers/i2c/chips/pcf50606.c
17 @@ -1784,12 +1784,6 @@ static int pcf50606_detect(struct i2c_adapter *adapter, int address, int kind)
18
19 #ifdef CONFIG_MACH_NEO1973_GTA01
20 if (machine_is_neo1973_gta01()) {
21 - /* FIXME: what is the device name we are symlinking to?
22 - * symlink won't get created until this is fixed.
23 - */
24 - struct device * busdev = bus_find_device_by_name(
25 - &platform_bus_type,
26 - NULL, "FIXME");
27 gta01_pm_gps_dev.dev.parent = &new_client->dev;
28 switch (system_rev) {
29 case GTA01Bv2_SYSTEM_REV:
30 @@ -1801,16 +1795,11 @@ static int pcf50606_detect(struct i2c_adapter *adapter, int address, int kind)
31 }
32 platform_device_register(&gta01_pm_gps_dev);
33 /* a link for gllin compatibility */
34 - /* 2.6.25 tracking: platform_bus_type.devices that was here
35 - * has gone away in mainline
36 - */
37 - if (busdev) {
38 - err = sysfs_create_link(&busdev->kobj,
39 + err = bus_create_device_link(&platform_bus_type,
40 &gta01_pm_gps_dev.dev.kobj, "gta01-pm-gps.0");
41 - if (err)
42 - printk(KERN_ERR
43 + if (err)
44 + printk(KERN_ERR
45 "sysfs_create_link (gta01-pm-gps.0): %d\n", err);
46 - }
47 }
48 #endif
49
50 --
51 1.5.6.3
52