Commit 2f78c642 authored by Greg Kroah-Hartman's avatar Greg Kroah-Hartman

Staging: comedi: addi_common.c: sparse cleanups

Now that we are properly marking the variable as __iomem, don't
cast it.

Also fix up some other sparse warnings.

Cc: Ian Abbott <abbotti@mev.co.uk>
Cc: Frank Mori Hess <fmhess@users.sourceforge.net>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
parent 6dd22814
...@@ -293,8 +293,8 @@ static const struct addi_board boardtypes[] = { ...@@ -293,8 +293,8 @@ static const struct addi_board boardtypes[] = {
0, 0,
0, 0,
0, 0,
0, NULL,
0, NULL,
32, 32,
0, 0,
0, 0,
...@@ -2527,7 +2527,7 @@ static const struct addi_board boardtypes[] = { ...@@ -2527,7 +2527,7 @@ static const struct addi_board boardtypes[] = {
#define n_boardtypes (sizeof(boardtypes)/sizeof(struct addi_board)) #define n_boardtypes (sizeof(boardtypes)/sizeof(struct addi_board))
struct comedi_driver driver_addi = { static struct comedi_driver driver_addi = {
.driver_name = "addi_common", .driver_name = "addi_common",
.module = THIS_MODULE, .module = THIS_MODULE,
.attach = i_ADDI_Attach, .attach = i_ADDI_Attach,
...@@ -2639,9 +2639,8 @@ static int i_ADDI_Attach(struct comedi_device *dev, struct comedi_devconfig *it) ...@@ -2639,9 +2639,8 @@ static int i_ADDI_Attach(struct comedi_device *dev, struct comedi_devconfig *it)
devpriv->ps_BoardInfo = this_board; devpriv->ps_BoardInfo = this_board;
devpriv->i_IobaseReserved = (int) io_addr[3]; devpriv->i_IobaseReserved = (int) io_addr[3];
printk("\nioremap begin"); printk("\nioremap begin");
devpriv->dw_AiBase = devpriv->dw_AiBase = ioremap(io_addr[3],
(unsigned long) ioremap(io_addr[3], this_board->i_IorangeBase3);
this_board->i_IorangeBase3);
printk("\nioremap end"); printk("\nioremap end");
} }
...@@ -2952,7 +2951,7 @@ static int i_ADDI_Detach(struct comedi_device *dev) ...@@ -2952,7 +2951,7 @@ static int i_ADDI_Detach(struct comedi_device *dev)
devpriv->ui_DmaBufferPages[1]); devpriv->ui_DmaBufferPages[1]);
} }
} else { } else {
iounmap((void *)devpriv->dw_AiBase); iounmap(devpriv->dw_AiBase);
if (devpriv->allocated) { if (devpriv->allocated) {
i_pci_card_free(devpriv->amcc); i_pci_card_free(devpriv->amcc);
......
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