Skip to content

Commit

Permalink
[MIPS] Alchemy: SMBus resource fix
Browse files Browse the repository at this point in the history
The Alchemy platform code registers the SMBus device using the virtual
address of its registers instead of the physical one -- fix this, taking
into account that actually the whole megabyte is decoded by any of the
programmable serial controllers (one of which is SMBus), and that all the
Alchemy peripherals are directly mappable into KSEG1 kernel space and
therefore ioremap() call would just boil down to CKSEG1ADDR() invocation.

Signed-off-by: Sergei Shtylyov <sshtylyov@ru.mvista.com>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
  • Loading branch information
Sergei Shtylyov authored and Ralf Baechle committed May 12, 2008
1 parent 492c2e4 commit 8e07c2c
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions arch/mips/au1000/common/platform.c
Original file line number Diff line number Diff line change
Expand Up @@ -269,8 +269,8 @@ static struct platform_device au1x00_pcmcia_device = {
#ifdef SMBUS_PSC_BASE
static struct resource pbdb_smbus_resources[] = {
{
.start = SMBUS_PSC_BASE,
.end = SMBUS_PSC_BASE + 0x24 - 1,
.start = CPHYSADDR(SMBUS_PSC_BASE),
.end = CPHYSADDR(SMBUS_PSC_BASE + 0xfffff),
.flags = IORESOURCE_MEM,
},
};
Expand Down
2 changes: 1 addition & 1 deletion drivers/i2c/busses/i2c-au1550.c
Original file line number Diff line number Diff line change
Expand Up @@ -335,7 +335,7 @@ i2c_au1550_probe(struct platform_device *pdev)
goto out_mem;
}

priv->psc_base = r->start;
priv->psc_base = CKSEG1ADDR(r->start);
priv->xfer_timeout = 200;
priv->ack_timeout = 200;

Expand Down

0 comments on commit 8e07c2c

Please sign in to comment.