diff options
Diffstat (limited to 'drivers/char')
-rw-r--r-- | drivers/char/Kconfig | 6 | ||||
-rw-r--r-- | drivers/char/ipmi/ipmi_si_intf.c | 32 | ||||
-rw-r--r-- | drivers/char/ipmi/ipmi_si_sm.h | 2 | ||||
-rw-r--r-- | drivers/char/mbcs.c | 4 | ||||
-rw-r--r-- | drivers/char/mbcs.h | 4 | ||||
-rw-r--r-- | drivers/char/sonypi.c | 6 |
6 files changed, 27 insertions, 27 deletions
diff --git a/drivers/char/Kconfig b/drivers/char/Kconfig index e162dab64ff..5ed6515ae01 100644 --- a/drivers/char/Kconfig +++ b/drivers/char/Kconfig @@ -153,7 +153,7 @@ config DIGIEPCA config ESPSERIAL tristate "Hayes ESP serial port support" - depends on SERIAL_NONSTANDARD && ISA && BROKEN_ON_SMP + depends on SERIAL_NONSTANDARD && ISA && BROKEN_ON_SMP && ISA_DMA_API help This is a driver which supports Hayes ESP serial ports. Both single port cards and multiport cards are supported. Make sure to read @@ -195,7 +195,7 @@ config ISI config SYNCLINK tristate "Microgate SyncLink card support" - depends on SERIAL_NONSTANDARD && PCI + depends on SERIAL_NONSTANDARD && PCI && ISA_DMA_API help Provides support for the SyncLink ISA and PCI multiprotocol serial adapters. These adapters support asynchronous and HDLC bit @@ -408,7 +408,7 @@ config SGI_TIOCX config SGI_MBCS tristate "SGI FPGA Core Services driver support" - depends on (IA64_SGI_SN2 || IA64_GENERIC) + depends on SGI_TIOCX help If you have an SGI Altix with an attached SABrick say Y or M here, otherwise say N. diff --git a/drivers/char/ipmi/ipmi_si_intf.c b/drivers/char/ipmi/ipmi_si_intf.c index 5419440087f..298574e1606 100644 --- a/drivers/char/ipmi/ipmi_si_intf.c +++ b/drivers/char/ipmi/ipmi_si_intf.c @@ -1617,15 +1617,15 @@ typedef struct dmi_header u16 handle; } dmi_header_t; -static int decode_dmi(dmi_header_t *dm, int intf_num) +static int decode_dmi(dmi_header_t __iomem *dm, int intf_num) { - u8 *data = (u8 *)dm; + u8 __iomem *data = (u8 __iomem *)dm; unsigned long base_addr; u8 reg_spacing; - u8 len = dm->length; + u8 len = readb(&dm->length); dmi_ipmi_data_t *ipmi_data = dmi_data+intf_num; - ipmi_data->type = data[4]; + ipmi_data->type = readb(&data[4]); memcpy(&base_addr, data+8, sizeof(unsigned long)); if (len >= 0x11) { @@ -1640,12 +1640,12 @@ static int decode_dmi(dmi_header_t *dm, int intf_num) } /* If bit 4 of byte 0x10 is set, then the lsb for the address is odd. */ - ipmi_data->base_addr = base_addr | ((data[0x10] & 0x10) >> 4); + ipmi_data->base_addr = base_addr | ((readb(&data[0x10]) & 0x10) >> 4); - ipmi_data->irq = data[0x11]; + ipmi_data->irq = readb(&data[0x11]); /* The top two bits of byte 0x10 hold the register spacing. */ - reg_spacing = (data[0x10] & 0xC0) >> 6; + reg_spacing = (readb(&data[0x10]) & 0xC0) >> 6; switch(reg_spacing){ case 0x00: /* Byte boundaries */ ipmi_data->offset = 1; @@ -1673,7 +1673,7 @@ static int decode_dmi(dmi_header_t *dm, int intf_num) ipmi_data->offset = 1; } - ipmi_data->slave_addr = data[6]; + ipmi_data->slave_addr = readb(&data[6]); if (is_new_interface(-1, ipmi_data->addr_space,ipmi_data->base_addr)) { dmi_data_entries++; @@ -1687,9 +1687,9 @@ static int decode_dmi(dmi_header_t *dm, int intf_num) static int dmi_table(u32 base, int len, int num) { - u8 *buf; - struct dmi_header *dm; - u8 *data; + u8 __iomem *buf; + struct dmi_header __iomem *dm; + u8 __iomem *data; int i=1; int status=-1; int intf_num = 0; @@ -1702,12 +1702,12 @@ static int dmi_table(u32 base, int len, int num) while(i<num && (data - buf) < len) { - dm=(dmi_header_t *)data; + dm=(dmi_header_t __iomem *)data; - if((data-buf+dm->length) >= len) + if((data-buf+readb(&dm->length)) >= len) break; - if (dm->type == 38) { + if (readb(&dm->type) == 38) { if (decode_dmi(dm, intf_num) == 0) { intf_num++; if (intf_num >= SI_MAX_DRIVERS) @@ -1715,8 +1715,8 @@ static int dmi_table(u32 base, int len, int num) } } - data+=dm->length; - while((data-buf) < len && (*data || data[1])) + data+=readb(&dm->length); + while((data-buf) < len && (readb(data)||readb(data+1))) data++; data+=2; i++; diff --git a/drivers/char/ipmi/ipmi_si_sm.h b/drivers/char/ipmi/ipmi_si_sm.h index a0212b00401..62791dd4298 100644 --- a/drivers/char/ipmi/ipmi_si_sm.h +++ b/drivers/char/ipmi/ipmi_si_sm.h @@ -51,7 +51,7 @@ struct si_sm_io /* Generic info used by the actual handling routines, the state machine shouldn't touch these. */ void *info; - void *addr; + void __iomem *addr; int regspacing; int regsize; int regshift; diff --git a/drivers/char/mbcs.c b/drivers/char/mbcs.c index ec7100556c5..ac9cfa9701e 100644 --- a/drivers/char/mbcs.c +++ b/drivers/char/mbcs.c @@ -394,7 +394,7 @@ int mbcs_open(struct inode *ip, struct file *fp) return -ENODEV; } -ssize_t mbcs_sram_read(struct file * fp, char *buf, size_t len, loff_t * off) +ssize_t mbcs_sram_read(struct file * fp, char __user *buf, size_t len, loff_t * off) { struct cx_dev *cx_dev = fp->private_data; struct mbcs_soft *soft = cx_dev->soft; @@ -419,7 +419,7 @@ ssize_t mbcs_sram_read(struct file * fp, char *buf, size_t len, loff_t * off) } ssize_t -mbcs_sram_write(struct file * fp, const char *buf, size_t len, loff_t * off) +mbcs_sram_write(struct file * fp, const char __user *buf, size_t len, loff_t * off) { struct cx_dev *cx_dev = fp->private_data; struct mbcs_soft *soft = cx_dev->soft; diff --git a/drivers/char/mbcs.h b/drivers/char/mbcs.h index 844644d201c..e7fd47e4325 100644 --- a/drivers/char/mbcs.h +++ b/drivers/char/mbcs.h @@ -543,9 +543,9 @@ struct mbcs_soft { }; extern int mbcs_open(struct inode *ip, struct file *fp); -extern ssize_t mbcs_sram_read(struct file *fp, char *buf, size_t len, +extern ssize_t mbcs_sram_read(struct file *fp, char __user *buf, size_t len, loff_t * off); -extern ssize_t mbcs_sram_write(struct file *fp, const char *buf, size_t len, +extern ssize_t mbcs_sram_write(struct file *fp, const char __user *buf, size_t len, loff_t * off); extern loff_t mbcs_sram_llseek(struct file *filp, loff_t off, int whence); extern int mbcs_gscr_mmap(struct file *fp, struct vm_area_struct *vma); diff --git a/drivers/char/sonypi.c b/drivers/char/sonypi.c index c812191417c..fd042060809 100644 --- a/drivers/char/sonypi.c +++ b/drivers/char/sonypi.c @@ -1021,11 +1021,11 @@ static int sonypi_misc_ioctl(struct inode *ip, struct file *fp, ret = -EIO; break; } - if (copy_to_user((u8 *)arg, &val8, sizeof(val8))) + if (copy_to_user(argp, &val8, sizeof(val8))) ret = -EFAULT; break; case SONYPI_IOCSFAN: - if (copy_from_user(&val8, (u8 *)arg, sizeof(val8))) { + if (copy_from_user(&val8, argp, sizeof(val8))) { ret = -EFAULT; break; } @@ -1038,7 +1038,7 @@ static int sonypi_misc_ioctl(struct inode *ip, struct file *fp, ret = -EIO; break; } - if (copy_to_user((u8 *)arg, &val8, sizeof(val8))) + if (copy_to_user(argp, &val8, sizeof(val8))) ret = -EFAULT; break; default: |