Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit cc61f957 authored by Mariusz Kozlowski's avatar Mariusz Kozlowski Committed by Paul Mackerras
Browse files

[POWERPC] drivers/macintosh/therm_adt746x.c: kmalloc + memset conversion to kzalloc

parent 0d279d47
Loading
Loading
Loading
Loading
+1 −4
Original line number Diff line number Diff line
@@ -379,13 +379,10 @@ static int attach_one_thermostat(struct i2c_adapter *adapter, int addr,
	if (thermostat)
		return 0;

	th = (struct thermostat *)
		kmalloc(sizeof(struct thermostat), GFP_KERNEL);

	th = kzalloc(sizeof(struct thermostat), GFP_KERNEL);
	if (!th)
		return -ENOMEM;

	memset(th, 0, sizeof(*th));
	th->clt.addr = addr;
	th->clt.adapter = adapter;
	th->clt.driver = &thermostat_driver;