net/9p: Fix compile warning

Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com>
Signed-off-by: Venkateswararao Jujjuri <jvrao@linux.vnet.ibm.com>
Signed-off-by: Eric Van Hensbergen <ericvh@gmail.com>
This commit is contained in:
Aneesh Kumar K.V 2011-03-08 16:39:47 +05:30 committed by Eric Van Hensbergen
parent eeff66ef6e
commit 472e7f9f8b
1 changed files with 5 additions and 5 deletions

View File

@ -41,9 +41,9 @@ EXPORT_SYMBOL(p9_release_req_pages);
int int
p9_nr_pages(struct p9_req_t *req) p9_nr_pages(struct p9_req_t *req)
{ {
int start_page, end_page; unsigned long start_page, end_page;
start_page = (unsigned long long)req->tc->pubuf >> PAGE_SHIFT; start_page = (unsigned long)req->tc->pubuf >> PAGE_SHIFT;
end_page = ((unsigned long long)req->tc->pubuf + req->tc->pbuf_size + end_page = ((unsigned long)req->tc->pubuf + req->tc->pbuf_size +
PAGE_SIZE - 1) >> PAGE_SHIFT; PAGE_SIZE - 1) >> PAGE_SHIFT;
return end_page - start_page; return end_page - start_page;
} }
@ -69,7 +69,7 @@ p9_payload_gup(struct p9_req_t *req, size_t *pdata_off, int *pdata_len,
*pdata_off = (size_t)req->tc->pubuf & (PAGE_SIZE-1); *pdata_off = (size_t)req->tc->pubuf & (PAGE_SIZE-1);
if (*pdata_off) if (*pdata_off)
first_page_bytes = min((PAGE_SIZE - *pdata_off), first_page_bytes = min(((size_t)PAGE_SIZE - *pdata_off),
req->tc->pbuf_size); req->tc->pbuf_size);
rpinfo = req->tc->private; rpinfo = req->tc->private;