Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F164670206
D27578.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Size
1 KB
Referenced Files
None
Subscribers
None
D27578.diff
View Options
Index: head/sys/dev/mrsas/mrsas_ioctl.c
===================================================================
--- head/sys/dev/mrsas/mrsas_ioctl.c
+++ head/sys/dev/mrsas/mrsas_ioctl.c
@@ -136,7 +136,7 @@
* iocpacket itself.
*/
kern_sge32 = (struct mrsas_sge32 *)
- ((unsigned long)cmd->frame + user_ioc->sgl_off);
+ ((uintptr_t)cmd->frame + user_ioc->sgl_off);
memset(ioctl_data_tag, 0, (sizeof(bus_dma_tag_t) * MAX_IOCTL_SGE));
memset(ioctl_data_dmamap, 0, (sizeof(bus_dmamap_t) * MAX_IOCTL_SGE));
@@ -243,7 +243,7 @@
goto out;
}
sense_ptr =
- (unsigned long *)((unsigned long)cmd->frame + user_ioc->sense_off);
+ (unsigned long *)((uintptr_t)cmd->frame + user_ioc->sense_off);
*sense_ptr = ioctl_sense_phys_addr;
}
/*
@@ -290,9 +290,9 @@
* sense_buff points to the location that has the user sense
* buffer address
*/
- sense_ptr = (unsigned long *)((unsigned long)user_ioc->frame.raw +
+ sense_ptr = (unsigned long *)((uintptr_t)user_ioc->frame.raw +
user_ioc->sense_off);
- ret = copyout(ioctl_sense_mem, (unsigned long *)*sense_ptr,
+ ret = copyout(ioctl_sense_mem, (unsigned long *)(uintptr_t)*sense_ptr,
user_ioc->sense_len);
if (ret) {
device_printf(sc->mrsas_dev, "IOCTL sense copyout failed!\n");
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Tue, Aug 4, 2:19 AM (3 h, 31 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
35926668
Default Alt Text
D27578.diff (1 KB)
Attached To
Mode
D27578: Use uintptr_t instead of unsigned long for pointers.
Attached
Detach File
Event Timeline
Log In to Comment