Commit dbba62f3 authored by Alexander Viro's avatar Alexander Viro Committed by Linus Torvalds

[PATCH] sparse: drivers/message/fusion annotations and fixes

Sigh...  First of all, LSI folks have very quaint idea of existing
platforms and word sizes on those.  Their definitions of U32 and S32
should really be reserved for posterity (preferably chiseled into the
rock they have between the ears), but kernel is the wrong place for
that.  Fixed.

mptctl_do_mpt_command() was always called on userland pointers;
kernel/userland argument removed along with dead code, function
annotated, callers updated.

The rest is trivial annotations in mptctl.c and in its ioctl structures
- nothing fancy there.
parent 17f5f84d
...@@ -47,18 +47,13 @@ typedef signed short S16; ...@@ -47,18 +47,13 @@ typedef signed short S16;
typedef unsigned short U16; typedef unsigned short U16;
#if defined(unix) || defined(__arm) || defined(ALPHA) typedef int32_t S32;
typedef u_int32_t U32;
typedef signed int S32;
typedef unsigned int U32;
#else
typedef signed long S32;
typedef unsigned long U32;
#endif
/*
* The only way crap below could work on big-endian boxen would be if it
* wasn't used at all.
*/
typedef struct _S64 typedef struct _S64
{ {
......
This diff is collapsed.
...@@ -115,7 +115,7 @@ ...@@ -115,7 +115,7 @@
struct mpt_fw_xfer { struct mpt_fw_xfer {
unsigned int iocnum; /* IOC unit number */ unsigned int iocnum; /* IOC unit number */
unsigned int fwlen; unsigned int fwlen;
void *bufp; /* Pointer to firmware buffer */ void __user *bufp; /* Pointer to firmware buffer */
}; };
#if defined(__KERNEL__) && defined(CONFIG_COMPAT) #if defined(__KERNEL__) && defined(CONFIG_COMPAT)
...@@ -332,10 +332,10 @@ typedef struct mpt_ioctl_replace_fw { ...@@ -332,10 +332,10 @@ typedef struct mpt_ioctl_replace_fw {
struct mpt_ioctl_command { struct mpt_ioctl_command {
mpt_ioctl_header hdr; mpt_ioctl_header hdr;
int timeout; /* optional (seconds) */ int timeout; /* optional (seconds) */
char *replyFrameBufPtr; char __user *replyFrameBufPtr;
char *dataInBufPtr; char __user *dataInBufPtr;
char *dataOutBufPtr; char __user *dataOutBufPtr;
char *senseDataPtr; char __user *senseDataPtr;
int maxReplyBytes; int maxReplyBytes;
int dataInSize; int dataInSize;
int dataOutSize; int dataOutSize;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment