iio: st_sensors: Drop unneeded casting when print error code

Explicit casting in printf() usually shows that something is not okay.
Here, we really don't need it by providing correct specifier.

Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
This commit is contained in:
Andy Shevchenko 2020-03-13 12:49:51 +02:00 committed by Jonathan Cameron
parent 1f38527d58
commit 7da08588b9
2 changed files with 4 additions and 4 deletions

View File

@ -49,8 +49,8 @@ int st_sensors_i2c_configure(struct iio_dev *indio_dev,
sdata->regmap = devm_regmap_init_i2c(client, config);
if (IS_ERR(sdata->regmap)) {
dev_err(&client->dev, "Failed to register i2c regmap (%d)\n",
(int)PTR_ERR(sdata->regmap));
dev_err(&client->dev, "Failed to register i2c regmap (%ld)\n",
PTR_ERR(sdata->regmap));
return PTR_ERR(sdata->regmap);
}

View File

@ -101,8 +101,8 @@ int st_sensors_spi_configure(struct iio_dev *indio_dev,
sdata->regmap = devm_regmap_init_spi(spi, config);
if (IS_ERR(sdata->regmap)) {
dev_err(&spi->dev, "Failed to register spi regmap (%d)\n",
(int)PTR_ERR(sdata->regmap));
dev_err(&spi->dev, "Failed to register spi regmap (%ld)\n",
PTR_ERR(sdata->regmap));
return PTR_ERR(sdata->regmap);
}