From 83e1bd97da27cd747714be508d2a84b2eb59b9e4 Mon Sep 17 00:00:00 2001 From: Vladislav Bolkhovitin Date: Fri, 24 Sep 2010 19:21:35 +0000 Subject: [PATCH] As is clear from the output of the nightly build, sparse goes crazy on the current scst_vdisk.c code: it reports 99 times "cast removes address space of expression" on the same scst_vdisk.c line before giving up. The patch below makes sparse stop complaining on scst_vdisk.c. Signed-off-by: Bart Van Assche git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@2251 d57e44dd-8a1f-0410-8b47-8ef2f437770f --- scst/src/dev_handlers/scst_vdisk.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/scst/src/dev_handlers/scst_vdisk.c b/scst/src/dev_handlers/scst_vdisk.c index bc9328c95..a7d5081c2 100644 --- a/scst/src/dev_handlers/scst_vdisk.c +++ b/scst/src/dev_handlers/scst_vdisk.c @@ -1257,13 +1257,13 @@ static void vdisk_exec_unmap(struct scst_cmd *cmd, struct scst_vdisk_thr *thr) ssize_t length; struct file *fd = thr->fd; struct inode *inode; - uint8_t __user *address; + uint8_t *address; int offset, descriptor_len, total_len; uint64_t range[2]; TRACE_ENTRY(); - length = scst_get_full_buf(cmd, (uint8_t __force **)&address); + length = scst_get_full_buf(cmd, &address); if (unlikely(length <= 0)) { if (length == 0) goto out_put;