All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] staging: iio: Remove unnecessary cast on void pointer
@ 2018-03-07 13:17 ` Arushi Singhal
  0 siblings, 0 replies; 4+ messages in thread
From: Arushi Singhal @ 2018-03-07 13:17 UTC (permalink / raw)
  To: lars
  Cc: devel, Michael Hennerich, linux-iio, Greg Kroah-Hartman,
	linux-kernel, outreachy-kernel, Peter Meerwald-Stadler,
	Hartmut Knaack, Jonathan Cameron

The following Coccinelle script was used to detect this:
@r@
expression x;
void* e;
type T;
identifier f;
@@
(
  *((T *)e)
|
  ((T *)x)[...]
|
  ((T*)x)->f
|

- (T*)
  e
)

Signed-off-by: Arushi Singhal <arushisinghal19971997@gmail.com>
---
 drivers/staging/iio/adc/ad7816.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/staging/iio/adc/ad7816.c b/drivers/staging/iio/adc/ad7816.c
index bfe180a..bf76a86 100644
--- a/drivers/staging/iio/adc/ad7816.c
+++ b/drivers/staging/iio/adc/ad7816.c
@@ -254,7 +254,7 @@ static const struct attribute_group ad7816_attribute_group = {
 static irqreturn_t ad7816_event_handler(int irq, void *private)
 {
 	iio_push_event(private, IIO_EVENT_CODE_AD7816_OTI,
-		       iio_get_time_ns((struct iio_dev *)private));
+		       iio_get_time_ns(private));
 	return IRQ_HANDLED;
 }
 
-- 
2.7.4

_______________________________________________
devel mailing list
devel@linuxdriverproject.org
http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel

^ permalink raw reply related	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2018-03-07 19:53 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-03-07 13:17 [PATCH] staging: iio: Remove unnecessary cast on void pointer Arushi Singhal
2018-03-07 13:17 ` Arushi Singhal
2018-03-07 19:53 ` Jonathan Cameron
2018-03-07 19:53   ` Jonathan Cameron

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.