summaryrefslogtreecommitdiffstats
path: root/arch/powerpc/sysdev/fsl_soc.c
diff options
context:
space:
mode:
authorAnton Vorontsov <avorontsov@ru.mvista.com>2007-10-02 15:47:40 +0200
committerKumar Gala <galak@kernel.crashing.org>2007-10-04 22:47:23 +0200
commitda1bb3a0e1f7f9cabe70fb2c41b47fa57c42fdfd (patch)
treefca0a59724aba282128f5a0dec79630cf532306c /arch/powerpc/sysdev/fsl_soc.c
parent[POWERPC] cpm: Describe multi-user ram in its own device node. (diff)
downloadlinux-da1bb3a0e1f7f9cabe70fb2c41b47fa57c42fdfd.tar.xz
linux-da1bb3a0e1f7f9cabe70fb2c41b47fa57c42fdfd.zip
[POWERPC] fsl_soc: fix uninitialized i2c_board_info structure
i2c_board_info used semi-initialized, causing garbage in the info->flags, and that, in turn, causes various symptoms of i2c malfunctioning, like PEC mismatches. Signed-off-by: Anton Vorontsov <avorontsov@ru.mvista.com> Signed-off-by: Kumar Gala <galak@kernel.crashing.org>
Diffstat (limited to 'arch/powerpc/sysdev/fsl_soc.c')
-rw-r--r--arch/powerpc/sysdev/fsl_soc.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/arch/powerpc/sysdev/fsl_soc.c b/arch/powerpc/sysdev/fsl_soc.c
index 4a1645691fb1..91987e000d25 100644
--- a/arch/powerpc/sysdev/fsl_soc.c
+++ b/arch/powerpc/sysdev/fsl_soc.c
@@ -363,7 +363,7 @@ static void __init of_register_i2c_devices(struct device_node *adap_node,
struct device_node *node = NULL;
while ((node = of_get_next_child(adap_node, node))) {
- struct i2c_board_info info;
+ struct i2c_board_info info = {};
const u32 *addr;
int len;
@@ -380,7 +380,6 @@ static void __init of_register_i2c_devices(struct device_node *adap_node,
if (of_find_i2c_driver(node, &info) < 0)
continue;
- info.platform_data = NULL;
info.addr = *addr;
i2c_register_board_info(bus_num, &info, 1);