MIPS: Remove empty prom_free_prom_memory functions

Most of the prom_free_prom_memory functions are empty. With
a new weak prom_free_prom_memory() we can remove all of them.

Signed-off-by: Thomas Bogendoerfer <tsbogend@alpha.franken.de>
Acked-by: Florian Fainelli <f.fainelli@gmail.com>
This commit is contained in:
Thomas Bogendoerfer 2021-01-05 22:36:31 +01:00
parent c58734eee6
commit a6e83acee2
28 changed files with 6 additions and 114 deletions

View File

@ -143,7 +143,3 @@ int __init prom_get_ethernet_addr(char *ethernet_addr)
return 0;
}
void __init prom_free_prom_memory(void)
{
}

View File

@ -49,8 +49,3 @@ void __init prom_meminit(void)
pages = memsize() >> PAGE_SHIFT;
memblock_add(PHYS_OFFSET, pages << PAGE_SHIFT);
}
void __init prom_free_prom_memory(void)
{
/* Nothing to free */
}

View File

@ -20,7 +20,3 @@
void __init prom_init(void)
{
}
void __init prom_free_prom_memory(void)
{
}

View File

@ -32,8 +32,3 @@ void __init prom_init(void)
}
#endif
}
void __init prom_free_prom_memory(void)
{
/* We do not have to prom memory to free */
}

View File

@ -113,10 +113,6 @@ void __init prom_init(void)
setup_8250_early_printk_port(CKSEG1ADDR(BCM47XX_SERIAL_ADDR), 0, 0);
}
void __init prom_free_prom_memory(void)
{
}
#if defined(CONFIG_BCM47XX_BCMA) && defined(CONFIG_HIGHMEM)
#define EXTVBASE 0xc0000000

View File

@ -94,7 +94,3 @@ void __init prom_init(void)
*/
}
}
void __init prom_free_prom_memory(void)
{
}

View File

@ -129,10 +129,6 @@ void __init prom_init(void)
register_bmips_smp_ops();
}
void __init prom_free_prom_memory(void)
{
}
const char *get_system_type(void)
{
return "Generic BMIPS kernel";

View File

@ -117,8 +117,3 @@ void __init prom_init(void)
setup_8250_early_printk_port(CKSEG1ADDR(0x1c800000), 0, 0);
}
void __init prom_free_prom_memory(void)
{
/* Nothing to do! */
}

View File

@ -173,7 +173,7 @@ void __weak __init prom_cleanup(void)
{
}
void __weak __init prom_free_prom_memory(void)
void __init prom_free_prom_memory(void)
{
int i;

View File

@ -87,10 +87,6 @@ void *prom_get_hwconf(void)
return (void *)CKSEG1ADDR(hwconf);
}
void __init prom_free_prom_memory(void)
{
}
/*
* /proc/cpuinfo system type
*

View File

@ -202,7 +202,3 @@ void __init arch_init_irq(void)
irqchip_init();
}
void __init prom_free_prom_memory(void)
{
}

View File

@ -44,10 +44,6 @@ int ltq_soc_type(void)
return soc_info.type;
}
void __init prom_free_prom_memory(void)
{
}
static void __init prom_init_cmdline(void)
{
int argc = fw_arg0;

View File

@ -46,7 +46,3 @@ void __init prom_init(void)
prom_init_uart_base();
board_nmi_handler_setup = mips_nmi_setup;
}
void __init prom_free_prom_memory(void)
{
}

View File

@ -36,10 +36,6 @@ void __init prom_init(void)
setup_8250_early_printk_port((unsigned long)uart_base, 0, 0);
}
void __init prom_free_prom_memory(void)
{
}
void __init plat_mem_setup(void)
{
memblock_add(0x0, (memsize << 20));

View File

@ -115,10 +115,6 @@ void __init prom_init(void)
board_nmi_handler_setup = mips_nmi_setup;
}
void __init prom_free_prom_memory(void)
{
}
static int __init add_legacy_isa_io(struct fwnode_handle *fwnode, resource_size_t hw_start,
resource_size_t size)
{

View File

@ -495,6 +495,11 @@ void free_init_pages(const char *what, unsigned long begin, unsigned long end)
void (*free_init_pages_eva)(void *begin, void *end) = NULL;
void __weak __init prom_free_prom_memory(void)
{
/* nothing to do */
}
void __ref free_initmem(void)
{
prom_free_prom_memory();

View File

@ -37,10 +37,6 @@ void __init fw_meminit(void)
free_init_pages_eva = eva ? free_init_pages_eva_malta : NULL;
}
void __init prom_free_prom_memory(void)
{
}
phys_addr_t mips_cdmm_phys_base(void)
{
/* This address is "typically unused" */

View File

@ -130,11 +130,6 @@ const char *get_system_type(void)
}
}
void __init prom_free_prom_memory(void)
{
/* Nothing yet */
}
void xlp_mmu_init(void)
{
u32 conf4;

View File

@ -89,11 +89,6 @@ unsigned int nlm_get_cpu_frequency(void)
return (unsigned int)nlm_prom_info.cpu_frequency;
}
void __init prom_free_prom_memory(void)
{
/* Nothing yet */
}
void nlm_percpu_init(int hwcpuid)
{
if (hwcpuid % 4 == 0)

View File

@ -91,10 +91,6 @@ void __init prom_init(void)
pic32_init_cmdline((int)fw_arg0, (char **)fw_arg1);
}
void __init prom_free_prom_memory(void)
{
}
void __init device_tree_init(void)
{
if (!initial_boot_params)

View File

@ -118,10 +118,6 @@ void __init prom_init(void)
pr_info("SoC Type: %s\n", get_system_type());
}
void __init prom_free_prom_memory(void)
{
}
void __init device_tree_init(void)
{
if (!initial_boot_params)

View File

@ -66,7 +66,3 @@ void __init prom_init(void)
prom_init_cmdline();
}
void __init prom_free_prom_memory(void)
{
}

View File

@ -34,11 +34,6 @@ static struct resource ddr_reg[] = {
}
};
void __init prom_free_prom_memory(void)
{
/* No prom memory to free */
}
static inline int match_tag(char *arg, const char *tag)
{
return strncmp(arg, tag, strlen(tag)) == 0;

View File

@ -404,11 +404,6 @@ void __init prom_meminit(void)
}
}
void __init prom_free_prom_memory(void)
{
/* We got nothing to free here ... */
}
extern void setup_zero_pages(void);
void __init paging_init(void)

View File

@ -40,8 +40,3 @@ void __init prom_meminit(void)
memblock_add(base, size);
}
}
void __init prom_free_prom_memory(void)
{
}

View File

@ -316,11 +316,6 @@ void __init prom_init(void)
#endif
}
void __init prom_free_prom_memory(void)
{
/* Not sure what I'm supposed to do here. Nothing, I think */
}
void prom_putchar(char c)
{
int ret;

View File

@ -340,10 +340,6 @@ void __init prom_init(void)
txx9_board_vec->prom_init();
}
void __init prom_free_prom_memory(void)
{
}
const char *get_system_type(void)
{
return txx9_system_type;

View File

@ -58,7 +58,3 @@ void __init prom_init(void)
strlcat(arcs_cmdline, " ", COMMAND_LINE_SIZE);
}
}
void __init prom_free_prom_memory(void)
{
}