aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDavid S. Miller <davem@davemloft.net>2011-04-12 18:58:41 -0400
committerDavid S. Miller <davem@davemloft.net>2011-04-12 18:58:41 -0400
commit095d3da610d4022d341c517c59dd5a5d656d966f (patch)
tree949aa05edeb978d344653d571bb7820efc8832b1
parent1aac62671686e6234c91b5f6fc4caaa850419d5d (diff)
9p: Kill set but unused variable in 9p_client_{read,write}() and p9_client_readdir()
Fixes the following warnings: net/9p/client.c:1305:18: warning: variable ‘total’ set but not used [-Wunused-but-set-variable] net/9p/client.c:1370:18: warning: variable ‘total’ set but not used [-Wunused-but-set-variable] net/9p/client.c:1769:18: warning: variable ‘total’ set but not used [-Wunused-but-set-variable] Signed-off-by: David S. Miller <davem@davemloft.net>
-rw-r--r--net/9p/client.c9
1 files changed, 3 insertions, 6 deletions
diff --git a/net/9p/client.c b/net/9p/client.c
index 48b8e084e710..0ce959218607 100644
--- a/net/9p/client.c
+++ b/net/9p/client.c
@@ -1302,7 +1302,7 @@ int
1302p9_client_read(struct p9_fid *fid, char *data, char __user *udata, u64 offset, 1302p9_client_read(struct p9_fid *fid, char *data, char __user *udata, u64 offset,
1303 u32 count) 1303 u32 count)
1304{ 1304{
1305 int err, rsize, total; 1305 int err, rsize;
1306 struct p9_client *clnt; 1306 struct p9_client *clnt;
1307 struct p9_req_t *req; 1307 struct p9_req_t *req;
1308 char *dataptr; 1308 char *dataptr;
@@ -1311,7 +1311,6 @@ p9_client_read(struct p9_fid *fid, char *data, char __user *udata, u64 offset,
1311 (long long unsigned) offset, count); 1311 (long long unsigned) offset, count);
1312 err = 0; 1312 err = 0;
1313 clnt = fid->clnt; 1313 clnt = fid->clnt;
1314 total = 0;
1315 1314
1316 rsize = fid->iounit; 1315 rsize = fid->iounit;
1317 if (!rsize || rsize > clnt->msize-P9_IOHDRSZ) 1316 if (!rsize || rsize > clnt->msize-P9_IOHDRSZ)
@@ -1367,7 +1366,7 @@ int
1367p9_client_write(struct p9_fid *fid, char *data, const char __user *udata, 1366p9_client_write(struct p9_fid *fid, char *data, const char __user *udata,
1368 u64 offset, u32 count) 1367 u64 offset, u32 count)
1369{ 1368{
1370 int err, rsize, total; 1369 int err, rsize;
1371 struct p9_client *clnt; 1370 struct p9_client *clnt;
1372 struct p9_req_t *req; 1371 struct p9_req_t *req;
1373 1372
@@ -1375,7 +1374,6 @@ p9_client_write(struct p9_fid *fid, char *data, const char __user *udata,
1375 fid->fid, (long long unsigned) offset, count); 1374 fid->fid, (long long unsigned) offset, count);
1376 err = 0; 1375 err = 0;
1377 clnt = fid->clnt; 1376 clnt = fid->clnt;
1378 total = 0;
1379 1377
1380 rsize = fid->iounit; 1378 rsize = fid->iounit;
1381 if (!rsize || rsize > clnt->msize-P9_IOHDRSZ) 1379 if (!rsize || rsize > clnt->msize-P9_IOHDRSZ)
@@ -1766,7 +1764,7 @@ EXPORT_SYMBOL_GPL(p9_client_xattrcreate);
1766 1764
1767int p9_client_readdir(struct p9_fid *fid, char *data, u32 count, u64 offset) 1765int p9_client_readdir(struct p9_fid *fid, char *data, u32 count, u64 offset)
1768{ 1766{
1769 int err, rsize, total; 1767 int err, rsize;
1770 struct p9_client *clnt; 1768 struct p9_client *clnt;
1771 struct p9_req_t *req; 1769 struct p9_req_t *req;
1772 char *dataptr; 1770 char *dataptr;
@@ -1776,7 +1774,6 @@ int p9_client_readdir(struct p9_fid *fid, char *data, u32 count, u64 offset)
1776 1774
1777 err = 0; 1775 err = 0;
1778 clnt = fid->clnt; 1776 clnt = fid->clnt;
1779 total = 0;
1780 1777
1781 rsize = fid->iounit; 1778 rsize = fid->iounit;
1782 if (!rsize || rsize > clnt->msize-P9_READDIRHDRSZ) 1779 if (!rsize || rsize > clnt->msize-P9_READDIRHDRSZ)