parisc: firmware: Simplify calling non-PA20 functions
Instead of usig #ifdefs, simply return PDC_BAD_PROC for functions which aren't available on 64-bit CPUs. Signed-off-by: Helge Deller <deller@gmx.de>
This commit is contained in:
parent
4695e45ec0
commit
3756597a68
|
@ -44,13 +44,11 @@ int pdc_model_capabilities(unsigned long *capabilities);
|
|||
int pdc_model_platform_info(char *orig_prod_num, char *current_prod_num, char *serial_no);
|
||||
int pdc_cache_info(struct pdc_cache_info *cache);
|
||||
int pdc_spaceid_bits(unsigned long *space_bits);
|
||||
#ifndef CONFIG_PA20
|
||||
int pdc_btlb_info(struct pdc_btlb_info *btlb);
|
||||
int pdc_btlb_insert(unsigned long long vpage, unsigned long physpage, unsigned long len,
|
||||
unsigned long entry_info, unsigned long slot);
|
||||
int pdc_btlb_purge_all(void);
|
||||
int pdc_mem_map_hpa(struct pdc_memory_map *r_addr, struct pdc_module_path *mod_path);
|
||||
#endif /* !CONFIG_PA20 */
|
||||
int pdc_pim_toc11(struct pdc_toc_pim_11 *ret);
|
||||
int pdc_pim_toc20(struct pdc_toc_pim_20 *ret);
|
||||
int pdc_lan_station_id(char *lan_addr, unsigned long net_hpa);
|
||||
|
|
|
@ -687,7 +687,6 @@ int pdc_spaceid_bits(unsigned long *space_bits)
|
|||
return retval;
|
||||
}
|
||||
|
||||
#ifndef CONFIG_PA20
|
||||
/**
|
||||
* pdc_btlb_info - Return block TLB information.
|
||||
* @btlb: The return buffer.
|
||||
|
@ -699,6 +698,9 @@ int pdc_btlb_info(struct pdc_btlb_info *btlb)
|
|||
int retval;
|
||||
unsigned long flags;
|
||||
|
||||
if (IS_ENABLED(CONFIG_PA20))
|
||||
return PDC_BAD_PROC;
|
||||
|
||||
spin_lock_irqsave(&pdc_lock, flags);
|
||||
retval = mem_pdc_call(PDC_BLOCK_TLB, PDC_BTLB_INFO, __pa(pdc_result), 0);
|
||||
memcpy(btlb, pdc_result, sizeof(*btlb));
|
||||
|
@ -716,6 +718,9 @@ int pdc_btlb_insert(unsigned long long vpage, unsigned long physpage, unsigned l
|
|||
int retval;
|
||||
unsigned long flags;
|
||||
|
||||
if (IS_ENABLED(CONFIG_PA20))
|
||||
return PDC_BAD_PROC;
|
||||
|
||||
spin_lock_irqsave(&pdc_lock, flags);
|
||||
retval = mem_pdc_call(PDC_BLOCK_TLB, PDC_BTLB_INSERT, (unsigned long) (vpage >> 32),
|
||||
(unsigned long) vpage, physpage, len, entry_info, slot);
|
||||
|
@ -728,6 +733,9 @@ int pdc_btlb_purge_all(void)
|
|||
int retval;
|
||||
unsigned long flags;
|
||||
|
||||
if (IS_ENABLED(CONFIG_PA20))
|
||||
return PDC_BAD_PROC;
|
||||
|
||||
spin_lock_irqsave(&pdc_lock, flags);
|
||||
retval = mem_pdc_call(PDC_BLOCK_TLB, PDC_BTLB_PURGE_ALL);
|
||||
spin_unlock_irqrestore(&pdc_lock, flags);
|
||||
|
@ -752,6 +760,9 @@ int pdc_mem_map_hpa(struct pdc_memory_map *address,
|
|||
int retval;
|
||||
unsigned long flags;
|
||||
|
||||
if (IS_ENABLED(CONFIG_PA20))
|
||||
return PDC_BAD_PROC;
|
||||
|
||||
spin_lock_irqsave(&pdc_lock, flags);
|
||||
memcpy(pdc_result2, mod_path, sizeof(*mod_path));
|
||||
retval = mem_pdc_call(PDC_MEM_MAP, PDC_MEM_MAP_HPA, __pa(pdc_result),
|
||||
|
@ -761,7 +772,6 @@ int pdc_mem_map_hpa(struct pdc_memory_map *address,
|
|||
|
||||
return retval;
|
||||
}
|
||||
#endif /* !CONFIG_PA20 */
|
||||
|
||||
/**
|
||||
* pdc_lan_station_id - Get the LAN address.
|
||||
|
|
Loading…
Reference in New Issue