Skip to content

Commit

Permalink
sh: machvec IO death.
Browse files Browse the repository at this point in the history
This takes a bit of a sledgehammer to the machvec I/O routines. The
iomem case requires no special casing and so can just be dropped
outright. This only leaves the ioport casing for PCI and SuperIO
mangling. With the SuperIO case going through the standard ioport
mapping, it's possible to replace everything with generic routines.

With this done the standard I/O routines are tidied up and NO_IOPORT
now gets default-enabled for the vast majority of boards.

Signed-off-by: Paul Mundt <lethal@linux-sh.org>
  • Loading branch information
pmundt committed Nov 1, 2010
1 parent e2781ac commit 37b7a97
Show file tree
Hide file tree
Showing 11 changed files with 396 additions and 419 deletions.
3 changes: 2 additions & 1 deletion arch/sh/Kconfig
Expand Up @@ -161,7 +161,8 @@ config ARCH_HAS_CPU_IDLE_WAIT
def_bool y

config NO_IOPORT
bool
def_bool !PCI
depends on !SH_CAYMAN && !SH_SH4202_MICRODEV

config IO_TRAPPED
bool
Expand Down
2 changes: 0 additions & 2 deletions arch/sh/boards/board-secureedge5410.c
Expand Up @@ -29,8 +29,6 @@ unsigned short secureedge5410_ioport;
*/
static irqreturn_t eraseconfig_interrupt(int irq, void *dev_id)
{
ctrl_delay(); /* dummy read */

printk("SnapGear: erase switch interrupt!\n");

return IRQ_HANDLED;
Expand Down
3 changes: 1 addition & 2 deletions arch/sh/drivers/pci/pci.c
Expand Up @@ -382,14 +382,13 @@ static void __iomem *ioport_map_pci(struct pci_dev *dev,
struct pci_channel *chan = dev->sysdata;

if (unlikely(!chan->io_map_base)) {
chan->io_map_base = generic_io_base;
chan->io_map_base = sh_io_port_base;

if (pci_domains_supported)
panic("To avoid data corruption io_map_base MUST be "
"set with multiple PCI domains.");
}


return (void __iomem *)(chan->io_map_base + port);
}

Expand Down

0 comments on commit 37b7a97

Please sign in to comment.