From: Marek Vasut Date: Sat, 18 Apr 2020 00:32:19 +0000 (+0200) Subject: net: pcnet: Replace mips-specific accessors X-Git-Tag: v2020.07-rc2~18^2~44 X-Git-Url: https://git.librecmc.org/?a=commitdiff_plain;h=3c0bcb97d6d7ed7f9b4c46eb2a6dd0e910214faf;p=oweals%2Fu-boot.git net: pcnet: Replace mips-specific accessors Replace mips-specific UNCACHED_SDRAM() macro with standard map_physmem(), which permits the driver to work on other systems than mips. Signed-off-by: Marek Vasut Cc: Daniel Schwierzeck Cc: Joe Hershberger --- diff --git a/drivers/net/pcnet.c b/drivers/net/pcnet.c index 59241c95bc..e7d6c8d714 100644 --- a/drivers/net/pcnet.c +++ b/drivers/net/pcnet.c @@ -332,7 +332,9 @@ static int pcnet_init(struct eth_device *dev, bd_t *bis) addr = (unsigned long)memalign(ARCH_DMA_MINALIGN, sizeof(*lp->uc)); flush_dcache_range(addr, addr + sizeof(*lp->uc)); - addr = UNCACHED_SDRAM(addr); + addr = (unsigned long)map_physmem(addr, + roundup(sizeof(*lp->uc), ARCH_DMA_MINALIGN), + MAP_NOCACHE); lp->uc = (struct pcnet_uncached_priv *)addr; addr = (unsigned long)memalign(ARCH_DMA_MINALIGN,