7 Jan
2019
7 Jan
'19
5:04 p.m.
On Sat, Jan 05, 2019 at 07:44:27AM -0600, Aditya Pakki wrote:
rt5663->imp_table = devm_kzalloc(dev, table_size, GFP_KERNEL);
device_property_read_u32_array(dev,
return device_property_read_u32_array(dev, "realtek,impedance_sensing_table", (u32 *)rt5663->imp_table, table_size);
This is going to silently fail without giving any indication of what's wrong which isn't great - it's not clear that completely failing to load the driver is the best option here, and even if it is we should probably tell the user what went wrong.
We're also not checking the result of the memory allocation...