mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH] staging: vt6655: preserve address space by not casting
@ 2014-06-13 10:11 Martin Kepplinger
  2014-06-16  7:55 ` Dan Carpenter
  0 siblings, 1 reply; 5+ messages in thread
From: Martin Kepplinger @ 2014-06-13 10:11 UTC (permalink / raw)
  To: gregkh; +Cc: forest, devel, linux-kernel, Martin Kepplinger

Fix the sparse error: cast removes address space of expression.
---
Is that even correct? I haven't signed-off on it yet.
ethtool_ioctl() takes a (void *) as user data, dereferenced and assigend to u32.
applies to next-20140611

 drivers/staging/vt6655/device_main.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/staging/vt6655/device_main.c b/drivers/staging/vt6655/device_main.c
index 1d3908d..15b2ee5 100644
--- a/drivers/staging/vt6655/device_main.c
+++ b/drivers/staging/vt6655/device_main.c
@@ -3067,7 +3067,7 @@ static int  device_ioctl(struct net_device *dev, struct ifreq *rq, int cmd) {
 		break;
 
 	case SIOCETHTOOL:
-		return ethtool_ioctl(dev, (void *)rq->ifr_data);
+		return ethtool_ioctl(dev, &rq->ifr_data);
 		// All other calls are currently unsupported
 
 	default:
-- 
1.7.10.4


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

end of thread, other threads:[~2014-06-19 23:33 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-06-13 10:11 [PATCH] staging: vt6655: preserve address space by not casting Martin Kepplinger
2014-06-16  7:55 ` Dan Carpenter
2014-06-17 12:32   ` [PATCH v2] staging: vt6655: preserve address space in ethtool_ioctl() Martin Kepplinger
2014-06-17 12:40     ` [PATCH v3] " Martin Kepplinger
2014-06-19 23:37       ` Greg KH

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

Powered by JetHome