Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

iio: buffer: drop devm_iio_kfifo_free() API call

It's unused so far, so it can be removed. Also makes sense to remove it
to discourage weird uses of this call during review.

Signed-off-by: Alexandru Ardelean <alexandru.ardelean@analog.com>
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>

authored by

Alexandru Ardelean and committed by
Jonathan Cameron
608d98a2 05c09e3c

-24
-1
Documentation/driver-api/driver-model/devres.rst
··· 286 286 devm_iio_device_alloc() 287 287 devm_iio_device_register() 288 288 devm_iio_kfifo_allocate() 289 - devm_iio_kfifo_free() 290 289 devm_iio_triggered_buffer_setup() 291 290 devm_iio_trigger_alloc() 292 291 devm_iio_trigger_register()
-22
drivers/iio/buffer/kfifo_buf.c
··· 179 179 iio_kfifo_free(*(struct iio_buffer **)res); 180 180 } 181 181 182 - static int devm_iio_kfifo_match(struct device *dev, void *res, void *data) 183 - { 184 - struct iio_buffer **r = res; 185 - 186 - if (WARN_ON(!r || !*r)) 187 - return 0; 188 - 189 - return *r == data; 190 - } 191 - 192 182 /** 193 183 * devm_iio_fifo_allocate - Resource-managed iio_kfifo_allocate() 194 184 * @dev: Device to allocate kfifo buffer for ··· 205 215 return r; 206 216 } 207 217 EXPORT_SYMBOL(devm_iio_kfifo_allocate); 208 - 209 - /** 210 - * devm_iio_fifo_free - Resource-managed iio_kfifo_free() 211 - * @dev: Device the buffer belongs to 212 - * @r: The buffer associated with the device 213 - */ 214 - void devm_iio_kfifo_free(struct device *dev, struct iio_buffer *r) 215 - { 216 - WARN_ON(devres_release(dev, devm_iio_kfifo_release, 217 - devm_iio_kfifo_match, r)); 218 - } 219 - EXPORT_SYMBOL(devm_iio_kfifo_free); 220 218 221 219 MODULE_LICENSE("GPL");
-1
include/linux/iio/kfifo_buf.h
··· 9 9 void iio_kfifo_free(struct iio_buffer *r); 10 10 11 11 struct iio_buffer *devm_iio_kfifo_allocate(struct device *dev); 12 - void devm_iio_kfifo_free(struct device *dev, struct iio_buffer *r); 13 12 14 13 #endif