The Linux Kernel Mailing List
 help / color / mirror / Atom feed
* [PATCH] /drivers/char sx.c ioremap -> pci_ioremap api
@ 2007-08-24 18:49 Scott Thompson
  2007-08-24 18:59 ` Jiri Slaby
  0 siblings, 1 reply; 9+ messages in thread
From: Scott Thompson @ 2007-08-24 18:49 UTC (permalink / raw)
  To: linux-kernel, kernel-janitors, jirislaby


patchset against 2.6.23-rc3.

moves the iomap/iounmap call to pci 'flavor'.  this was a
recommendation from a previously submitted patch that handles
the unchecked iomap (or, now, pci_iomap) return code.

Signed-off-by: Scott Thompson <postfail <at> hushmail.com>
----------------------------------------------------------

diff --git a/drivers/char/sx.c b/drivers/char/sx.c
index 85a2328..481334f 100644
--- a/drivers/char/sx.c
+++ b/drivers/char/sx.c
@@ -2626,14 +2626,14 @@ static void __devinit fix_sx_pci(struct pci_dev *pdev, struct sx_board *board)

  	pci_read_config_dword(pdev, PCI_BASE_ADDRESS_0, &hwbase);
  	hwbase &= PCI_BASE_ADDRESS_MEM_MASK;
-	rebase = ioremap(hwbase, 0x80);
+	rebase = pci_iomap(pdev, 0, 0x80);
  	t = readl(rebase + CNTRL_REG_OFFSET);
  	if (t != CNTRL_REG_GOODVALUE) {
  		printk(KERN_DEBUG "sx: performing cntrl reg fix: %08x -> "
  			"%08x\n", t, CNTRL_REG_GOODVALUE);
  		writel(CNTRL_REG_GOODVALUE, rebase + CNTRL_REG_OFFSET);
  	}
-	iounmap(rebase);
+	pci_iounmap(pdev, rebase);
  }
  #endif

^ permalink raw reply related	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2007-08-25 10:10 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-08-24 18:49 [PATCH] /drivers/char sx.c ioremap -> pci_ioremap api Scott Thompson
2007-08-24 18:59 ` Jiri Slaby
2007-08-24 19:15   ` Alan Cox
2007-08-24 20:03     ` Jiri Slaby
2007-08-24 20:34       ` Alan Cox
2007-08-25  8:45         ` readXs on pci*iomap-ped regions [Was: [PATCH] /drivers/char sx.c ioremap -> pci_ioremap api] Jiri Slaby
2007-08-25  8:56           ` Jeff Garzik
2007-08-25  9:02             ` Jiri Slaby
2007-08-25 10:17             ` Alan Cox

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox