aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRussell King <rmk+kernel@arm.linux.org.uk>2009-11-21 06:58:36 -0500
committerRussell King <rmk+kernel@arm.linux.org.uk>2010-02-12 12:32:40 -0500
commit88d968b22fa26d5e3a8cab46fc7c3a21c89a91d3 (patch)
tree59be21a4c25305dceb02210b54ae17f296020779
parent2781681ea6629ac0a685f5afe2011f916ab3c8ba (diff)
ARM: PNX4008: Make ioaddr 'void __iomem *' rather than 'u32'
This avoids unnecessary casting. Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
-rw-r--r--drivers/i2c/busses/i2c-pnx.c8
-rw-r--r--include/linux/i2c-pnx.h2
2 files changed, 5 insertions, 5 deletions
diff --git a/drivers/i2c/busses/i2c-pnx.c b/drivers/i2c/busses/i2c-pnx.c
index bfcd079e885c..882579e64111 100644
--- a/drivers/i2c/busses/i2c-pnx.c
+++ b/drivers/i2c/busses/i2c-pnx.c
@@ -612,8 +612,8 @@ static int __devinit i2c_pnx_probe(struct platform_device *pdev)
612 goto out_clkget; 612 goto out_clkget;
613 } 613 }
614 614
615 if (!(alg_data->ioaddr = 615 alg_data->ioaddr = ioremap(alg_data->base, I2C_PNX_REGION_SIZE);
616 (u32)ioremap(alg_data->base, I2C_PNX_REGION_SIZE))) { 616 if (!alg_data->ioaddr) {
617 dev_err(&pdev->dev, "Couldn't ioremap I2C I/O region\n"); 617 dev_err(&pdev->dev, "Couldn't ioremap I2C I/O region\n");
618 ret = -ENOMEM; 618 ret = -ENOMEM;
619 goto out_release; 619 goto out_release;
@@ -671,7 +671,7 @@ out_irq:
671out_clock: 671out_clock:
672 clk_disable(alg_data->clk); 672 clk_disable(alg_data->clk);
673out_unmap: 673out_unmap:
674 iounmap((void *)alg_data->ioaddr); 674 iounmap(alg_data->ioaddr);
675out_release: 675out_release:
676 release_mem_region(alg_data->base, I2C_PNX_REGION_SIZE); 676 release_mem_region(alg_data->base, I2C_PNX_REGION_SIZE);
677out_clkget: 677out_clkget:
@@ -691,7 +691,7 @@ static int __devexit i2c_pnx_remove(struct platform_device *pdev)
691 free_irq(alg_data->irq, i2c_pnx->adapter); 691 free_irq(alg_data->irq, i2c_pnx->adapter);
692 i2c_del_adapter(adap); 692 i2c_del_adapter(adap);
693 clk_disable(alg_data->clk); 693 clk_disable(alg_data->clk);
694 iounmap((void *)alg_data->ioaddr); 694 iounmap(alg_data->ioaddr);
695 release_mem_region(alg_data->base, I2C_PNX_REGION_SIZE); 695 release_mem_region(alg_data->base, I2C_PNX_REGION_SIZE);
696 clk_put(alg_data->clk); 696 clk_put(alg_data->clk);
697 platform_set_drvdata(pdev, NULL); 697 platform_set_drvdata(pdev, NULL);
diff --git a/include/linux/i2c-pnx.h b/include/linux/i2c-pnx.h
index 9035711cb3b1..5a48f33046fb 100644
--- a/include/linux/i2c-pnx.h
+++ b/include/linux/i2c-pnx.h
@@ -26,7 +26,7 @@ struct i2c_pnx_mif {
26 26
27struct i2c_pnx_algo_data { 27struct i2c_pnx_algo_data {
28 u32 base; 28 u32 base;
29 u32 ioaddr; 29 void __iomem *ioaddr;
30 int irq; 30 int irq;
31 struct i2c_pnx_mif mif; 31 struct i2c_pnx_mif mif;
32 int last; 32 int last;