Commit 5e6cb39a authored by Christophe Leroy's avatar Christophe Leroy Committed by Jakub Kicinski

net: fs_enet: Use cpm_muram_xxx() functions instead of cpm_dpxxx() macros

cpm_dpxxx() macros are now always referring to cpm_muram_xxx() functions
directly since commit 3dd82a1e ("[POWERPC] CPM: Always use new
binding.")

Use cpm_muram_xxx() functions directly so that the cpm_dpxxx() macros
can be removed in the near future.
Signed-off-by: default avatarChristophe Leroy <christophe.leroy@csgroup.eu>
Reviewed-by: default avatarSimon Horman <horms@kernel.org>
Link: https://lore.kernel.org/r/2400b3156891adb653dc387fff6393de10cf2b24.1691155347.git.christophe.leroy@csgroup.euSigned-off-by: default avatarJakub Kicinski <kuba@kernel.org>
parent 7149b38d
...@@ -105,7 +105,7 @@ static int do_pd_setup(struct fs_enet_private *fep) ...@@ -105,7 +105,7 @@ static int do_pd_setup(struct fs_enet_private *fep)
goto out_ep; goto out_ep;
fep->fcc.mem = (void __iomem *)cpm2_immr; fep->fcc.mem = (void __iomem *)cpm2_immr;
fpi->dpram_offset = cpm_dpalloc(128, 32); fpi->dpram_offset = cpm_muram_alloc(128, 32);
if (IS_ERR_VALUE(fpi->dpram_offset)) { if (IS_ERR_VALUE(fpi->dpram_offset)) {
ret = fpi->dpram_offset; ret = fpi->dpram_offset;
goto out_fcccp; goto out_fcccp;
......
...@@ -133,13 +133,13 @@ static int allocate_bd(struct net_device *dev) ...@@ -133,13 +133,13 @@ static int allocate_bd(struct net_device *dev)
struct fs_enet_private *fep = netdev_priv(dev); struct fs_enet_private *fep = netdev_priv(dev);
const struct fs_platform_info *fpi = fep->fpi; const struct fs_platform_info *fpi = fep->fpi;
fep->ring_mem_addr = cpm_dpalloc((fpi->tx_ring + fpi->rx_ring) * fep->ring_mem_addr = cpm_muram_alloc((fpi->tx_ring + fpi->rx_ring) *
sizeof(cbd_t), 8); sizeof(cbd_t), 8);
if (IS_ERR_VALUE(fep->ring_mem_addr)) if (IS_ERR_VALUE(fep->ring_mem_addr))
return -ENOMEM; return -ENOMEM;
fep->ring_base = (void __iomem __force*) fep->ring_base = (void __iomem __force*)
cpm_dpram_addr(fep->ring_mem_addr); cpm_muram_addr(fep->ring_mem_addr);
return 0; return 0;
} }
...@@ -149,7 +149,7 @@ static void free_bd(struct net_device *dev) ...@@ -149,7 +149,7 @@ static void free_bd(struct net_device *dev)
struct fs_enet_private *fep = netdev_priv(dev); struct fs_enet_private *fep = netdev_priv(dev);
if (fep->ring_base) if (fep->ring_base)
cpm_dpfree(fep->ring_mem_addr); cpm_muram_free(fep->ring_mem_addr);
} }
static void cleanup_data(struct net_device *dev) static void cleanup_data(struct net_device *dev)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment