[PATCH] ub: suppress gcc warnings for pointer casts
When building on a 64-bit platform, gcc produces a warning
"cast of a pointer to an integer of a different size".
The scatterlist.offset on the LHS is unsigned int, so I used
that originally.
Signed-off-by: Pete Zaitcev <[EMAIL PROTECTED]>
Signed-off-by: Greg Kroah-Hartman <[EMAIL PROTECTED]>
drivers/block/ub.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
---
commit 38ffdd62b0f466ef9126ac9f060ade5f218b4887
tree 4f636beb7bcc713e0f454058541850b4cabf69fa
parent e639dd3f4edd4847d160899b19e95ee1a06a6dcb
author Pete Zaitcev <[EMAIL PROTECTED]> Sat, 24 Sep 2005 13:10:16 -0700
committer Greg Kroah-Hartman <[EMAIL PROTECTED]> Fri, 28 Oct 2005 16:47:38 -0700
drivers/block/ub.c | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/block/ub.c b/drivers/block/ub.c
index ed4d500..bfb23d5 100644
--- a/drivers/block/ub.c
+++ b/drivers/block/ub.c
@@ -1512,7 +1512,7 @@ static void ub_state_sense(struct ub_dev
scmd->nsg = 1;
sg = &scmd->sgv[0];
sg->page = virt_to_page(sc->top_sense);
- sg->offset = (unsigned int)sc->top_sense & (PAGE_SIZE-1);
+ sg->offset = (unsigned long)sc->top_sense & (PAGE_SIZE-1);
sg->length = UB_SENSE_SIZE;
scmd->len = UB_SENSE_SIZE;
scmd->lun = cmd->lun;
@@ -1891,7 +1891,7 @@ static int ub_sync_read_cap(struct ub_de
cmd->nsg = 1;
sg = &cmd->sgv[0];
sg->page = virt_to_page(p);
- sg->offset = (unsigned int)p & (PAGE_SIZE-1);
+ sg->offset = (unsigned long)p & (PAGE_SIZE-1);
sg->length = 8;
cmd->len = 8;
cmd->lun = lun;
-------------------------------------------------------
This SF.Net email is sponsored by the JBoss Inc.
Get Certified Today * Register for a JBoss Training Course
Free Certification Exam for All Training Attendees Through End of 2005
Visit http://www.jboss.com/services/certification for more information
_______________________________________________
[email protected]
To unsubscribe, use the last form field at:
https://lists.sourceforge.net/lists/listinfo/linux-usb-devel