Skip to content

Commit 7aa4f42

Browse files
dlechnunojsa
authored andcommitted
iio: adc: ad7944: remove unused parameter
In the ad7944 driver, the ad7944_convert_and_acquire() had an unused `chan` parameter. This patch removes the parameter. Signed-off-by: David Lechner <dlechner@baylibre.com> Link: https://lore.kernel.org/r/20240524-iio-ad7944-remove-unused-parameter-v1-1-fd824d7122a0@baylibre.com Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
1 parent 5ec0eeb commit 7aa4f42

File tree

1 file changed

+3
-5
lines changed

1 file changed

+3
-5
lines changed

drivers/iio/adc/ad7944.c

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -259,7 +259,6 @@ static int ad7944_chain_mode_init_msg(struct device *dev, struct ad7944_adc *adc
259259
/**
260260
* ad7944_convert_and_acquire - Perform a single conversion and acquisition
261261
* @adc: The ADC device structure
262-
* @chan: The channel specification
263262
* Return: 0 on success, a negative error code on failure
264263
*
265264
* Perform a conversion and acquisition of a single sample using the
@@ -268,8 +267,7 @@ static int ad7944_chain_mode_init_msg(struct device *dev, struct ad7944_adc *adc
268267
* Upon successful return adc->sample.raw will contain the conversion result
269268
* (or adc->chain_mode_buf if the device is using chain mode).
270269
*/
271-
static int ad7944_convert_and_acquire(struct ad7944_adc *adc,
272-
const struct iio_chan_spec *chan)
270+
static int ad7944_convert_and_acquire(struct ad7944_adc *adc)
273271
{
274272
int ret;
275273

@@ -291,7 +289,7 @@ static int ad7944_single_conversion(struct ad7944_adc *adc,
291289
{
292290
int ret;
293291

294-
ret = ad7944_convert_and_acquire(adc, chan);
292+
ret = ad7944_convert_and_acquire(adc);
295293
if (ret)
296294
return ret;
297295

@@ -361,7 +359,7 @@ static irqreturn_t ad7944_trigger_handler(int irq, void *p)
361359
struct ad7944_adc *adc = iio_priv(indio_dev);
362360
int ret;
363361

364-
ret = ad7944_convert_and_acquire(adc, &indio_dev->channels[0]);
362+
ret = ad7944_convert_and_acquire(adc);
365363
if (ret)
366364
goto out;
367365

0 commit comments

Comments
 (0)