On Thu, Feb 22, 2024 at 01:07:43PM +0200, Dumitru Ceclan wrote: > The AD7173 family offer a complete integrated Sigma-Delta ADC solution > which can be used in high precision, low noise single channel > applications or higher speed multiplexed applications. The Sigma-Delta > ADC is intended primarily for measurement of signals close to DC but also > delivers outstanding performance with input bandwidths out to ~10kHz. A couple more comments which Jonathan might address when applying, up to him. ... With struct device *dev = &st->sd.spi->dev; the below will be neater. > + struct ad7173_state *st = iio_priv(indio_dev); > + u8 buf[AD7173_RESET_LENGTH]; > + unsigned int id; > + int ret; ... > + if (id != st->info->id) > + dev_warn(&st->sd.spi->dev, > + "Unexpected device id: 0x%04X, expected: 0x%04X\n", > + id, st->info->id); (like here) ... > + st->config_usage_counter = 0; > + st->config_cnts = devm_kcalloc(&st->sd.spi->dev, st->info->num_configs, > + sizeof(u64), GFP_KERNEL); sizeof(*st->config_cnts) ? (or here) > + if (!st->config_cnts) > + return -ENOMEM; ... > + ret = fwnode_property_match_property_string(dev_fwnode(dev), device_property_match_property_string() > + "clock-names", > + ad7173_clk_sel, > + ARRAY_SIZE(ad7173_clk_sel)); ... > + if (num_channels == 0) > + return dev_err_probe(dev, -EINVAL, "No channels specified\n"); -ENODATA? -- With Best Regards, Andy Shevchenko