diff options
Diffstat (limited to 'drivers/message/i2o/i2o_config.c')
-rw-r--r-- | drivers/message/i2o/i2o_config.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/drivers/message/i2o/i2o_config.c b/drivers/message/i2o/i2o_config.c index 7636833b4623..8160a1f6c73a 100644 --- a/drivers/message/i2o/i2o_config.c +++ b/drivers/message/i2o/i2o_config.c | |||
@@ -36,6 +36,8 @@ | |||
36 | 36 | ||
37 | #include <asm/uaccess.h> | 37 | #include <asm/uaccess.h> |
38 | 38 | ||
39 | #define SG_TABLESIZE 30 | ||
40 | |||
39 | extern int i2o_parm_issue(struct i2o_device *, int, void *, int, void *, int); | 41 | extern int i2o_parm_issue(struct i2o_device *, int, void *, int, void *, int); |
40 | 42 | ||
41 | static int i2o_cfg_ioctl(struct inode *inode, struct file *fp, unsigned int cmd, | 43 | static int i2o_cfg_ioctl(struct inode *inode, struct file *fp, unsigned int cmd, |
@@ -663,7 +665,7 @@ static int i2o_cfg_passthru32(struct file *file, unsigned cmnd, unsigned long ar | |||
663 | goto sg_list_cleanup; | 665 | goto sg_list_cleanup; |
664 | 666 | ||
665 | if (sg_offset) { | 667 | if (sg_offset) { |
666 | u32 msg[MSG_FRAME_SIZE]; | 668 | u32 msg[I2O_OUTBOUND_MSG_FRAME_SIZE]; |
667 | /* Copy back the Scatter Gather buffers back to user space */ | 669 | /* Copy back the Scatter Gather buffers back to user space */ |
668 | u32 j; | 670 | u32 j; |
669 | // TODO 64bit fix | 671 | // TODO 64bit fix |
@@ -671,7 +673,7 @@ static int i2o_cfg_passthru32(struct file *file, unsigned cmnd, unsigned long ar | |||
671 | int sg_size; | 673 | int sg_size; |
672 | 674 | ||
673 | // re-acquire the original message to handle correctly the sg copy operation | 675 | // re-acquire the original message to handle correctly the sg copy operation |
674 | memset(&msg, 0, MSG_FRAME_SIZE * 4); | 676 | memset(&msg, 0, I2O_OUTBOUND_MSG_FRAME_SIZE * 4); |
675 | // get user msg size in u32s | 677 | // get user msg size in u32s |
676 | if (get_user(size, &user_msg[0])) { | 678 | if (get_user(size, &user_msg[0])) { |
677 | rcode = -EFAULT; | 679 | rcode = -EFAULT; |
@@ -902,7 +904,7 @@ static int i2o_cfg_passthru(unsigned long arg) | |||
902 | int sg_size; | 904 | int sg_size; |
903 | 905 | ||
904 | // re-acquire the original message to handle correctly the sg copy operation | 906 | // re-acquire the original message to handle correctly the sg copy operation |
905 | memset(&msg, 0, MSG_FRAME_SIZE * 4); | 907 | memset(&msg, 0, I2O_OUTBOUND_MSG_FRAME_SIZE * 4); |
906 | // get user msg size in u32s | 908 | // get user msg size in u32s |
907 | if (get_user(size, &user_msg[0])) { | 909 | if (get_user(size, &user_msg[0])) { |
908 | rcode = -EFAULT; | 910 | rcode = -EFAULT; |