aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/char
diff options
context:
space:
mode:
authorJiri Slaby <jirislaby@gmail.com>2008-10-13 05:34:18 -0400
committerLinus Torvalds <torvalds@linux-foundation.org>2008-10-13 12:51:39 -0400
commit1361b7d3592b006574fb3cfeb21a02d520cca315 (patch)
treeeff43bb8794ed26439c7ecf11ad60eae353fb80b /drivers/char
parent24e6fd4cdc841176ca3713fddc9a02bd128b1191 (diff)
Char: sx, fix io unmapping
board->base is increased for CF cards after mapping. Use board->base2 for unmapping the region, since it holds the original/correct address. Signed-off-by: Jiri Slaby <jirislaby@gmail.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Alan Cox <alan@redhat.com> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'drivers/char')
-rw-r--r--drivers/char/sx.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/char/sx.c b/drivers/char/sx.c
index c385206f9db5..5b8d7a1aa3e6 100644
--- a/drivers/char/sx.c
+++ b/drivers/char/sx.c
@@ -2504,7 +2504,7 @@ static void __devexit sx_remove_card(struct sx_board *board,
2504 del_timer(&board->timer); 2504 del_timer(&board->timer);
2505 if (pdev) { 2505 if (pdev) {
2506#ifdef CONFIG_PCI 2506#ifdef CONFIG_PCI
2507 pci_iounmap(pdev, board->base); 2507 pci_iounmap(pdev, board->base2);
2508 pci_release_region(pdev, IS_CF_BOARD(board) ? 3 : 2); 2508 pci_release_region(pdev, IS_CF_BOARD(board) ? 3 : 2);
2509#endif 2509#endif
2510 } else { 2510 } else {
@@ -2703,7 +2703,7 @@ static int __devinit sx_pci_probe(struct pci_dev *pdev,
2703 2703
2704 return 0; 2704 return 0;
2705err_unmap: 2705err_unmap:
2706 pci_iounmap(pdev, board->base); 2706 pci_iounmap(pdev, board->base2);
2707err_reg: 2707err_reg:
2708 pci_release_region(pdev, reg); 2708 pci_release_region(pdev, reg);
2709err_flag: 2709err_flag: