From: Joe Perches <joe@perches.com>
To: Ben Hutchings <bhutchings@solarflare.com>
Cc: "David S. Miller" <davem@davemloft.net>, netdev@vger.kernel.org
Subject: [PATCH] net/9p: Add __force to cast of __user pointer
Date: Mon, 04 Jun 2012 10:16:14 -0700 [thread overview]
Message-ID: <1338830174.15683.2.camel@joe2Laptop> (raw)
In-Reply-To: <1338825881.3979.203.camel@deadeye>
A recent commit that removed unnecessary casts of pointers
to the same type uncovered a missing __force cast.
Add it.
Reported by: Ben Hutchings <bhutchings@solarflare.com>
Signed-off-by: Joe Perches <joe@perches.com>
---
net/9p/client.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/net/9p/client.c b/net/9p/client.c
index 5cbea90..8260f13 100644
--- a/net/9p/client.c
+++ b/net/9p/client.c
@@ -1548,7 +1548,7 @@ p9_client_read(struct p9_fid *fid, char *data, char __user *udata, u64 offset,
kernel_buf = 1;
indata = data;
} else
- indata = udata;
+ indata = (__force char *)udata;
/*
* response header len is 11
* PDU Header(7) + IO Size (4)
next prev parent reply other threads:[~2012-06-04 17:16 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-06-04 3:41 [PATCH] net: Remove casts to same type Joe Perches
2012-06-04 15:45 ` David Miller
2012-06-04 15:52 ` Joe Perches
2012-06-04 15:53 ` David Miller
2012-06-04 16:04 ` Ben Hutchings
2012-06-04 17:16 ` Joe Perches [this message]
2012-06-04 18:12 ` [PATCH] net/9p: Add __force to cast of __user pointer David Miller
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1338830174.15683.2.camel@joe2Laptop \
--to=joe@perches.com \
--cc=bhutchings@solarflare.com \
--cc=davem@davemloft.net \
--cc=netdev@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).