Moi Mika, On Thu, Sep 06, 2018 at 06:50:19PM +0300, Mika Westerberg wrote: > @@ -427,32 +464,37 @@ static int acpi_data_get_property(const struct acpi_device_data *data, > const char *name, acpi_object_type type, > const union acpi_object **obj) > { > - const union acpi_object *properties; > - int i; > + struct acpi_device_properties *props; props could be const. > > if (!data || !name) > return -EINVAL; > > - if (!data->pointer || !data->properties) > + if (!data->pointer || list_empty(&data->properties)) > return -EINVAL; > > - properties = data->properties; > - for (i = 0; i < properties->package.count; i++) { > - const union acpi_object *propname, *propvalue; > - const union acpi_object *property; > + list_for_each_entry(props, &data->properties, list) { > + const union acpi_object *properties; > + int i; unsigned int i? > > - property = &properties->package.elements[i]; > + properties = props->properties; > + for (i = 0; i < properties->package.count; i++) { > + const union acpi_object *propname, *propvalue; > + const union acpi_object *property; > > - propname = &property->package.elements[0]; > - propvalue = &property->package.elements[1]; > + property = &properties->package.elements[i]; > With the above considered, Acked-by: Sakari Ailus <sakari.ailus@xxxxxxxxxxxxxxx> -- Terveisin, Sakari Ailus e-mail: sakari.ailus@xxxxxx