aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/w1/slaves/w1_ds2433.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/w1/slaves/w1_ds2433.c')
-rw-r--r--drivers/w1/slaves/w1_ds2433.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/w1/slaves/w1_ds2433.c b/drivers/w1/slaves/w1_ds2433.c
index cab56005dd49..858c16a544c2 100644
--- a/drivers/w1/slaves/w1_ds2433.c
+++ b/drivers/w1/slaves/w1_ds2433.c
@@ -266,10 +266,9 @@ static int w1_f23_add_slave(struct w1_slave *sl)
266#ifdef CONFIG_W1_SLAVE_DS2433_CRC 266#ifdef CONFIG_W1_SLAVE_DS2433_CRC
267 struct w1_f23_data *data; 267 struct w1_f23_data *data;
268 268
269 data = kmalloc(sizeof(struct w1_f23_data), GFP_KERNEL); 269 data = kzalloc(sizeof(struct w1_f23_data), GFP_KERNEL);
270 if (!data) 270 if (!data)
271 return -ENOMEM; 271 return -ENOMEM;
272 memset(data, 0, sizeof(struct w1_f23_data));
273 sl->family_data = data; 272 sl->family_data = data;
274 273
275#endif /* CONFIG_W1_SLAVE_DS2433_CRC */ 274#endif /* CONFIG_W1_SLAVE_DS2433_CRC */