You've already forked linux-apfs
mirror of
https://github.com/linux-apfs/linux-apfs.git
synced 2026-05-01 15:00:59 -07:00
[SPARC64]: Privatize sun4u_get_pte() and fix name.
__get_phys is only called from init.c as is prom_virt_to_phys(), __get_iospace() is not called at all, and sun4u_get_pte() is largely misnamed. Privatize the implementation and helper functions of sun4u_get_phys() to mm/init.c, and rename to kvaddr_to_paddr(). The only used of this thing is flush_icache_range(), and thus things can be considerably further simplified. For example, we should only see module or PAGE_OFFSET kernel addresses here, so we don't need the OBP firmware range handling at all. Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
@@ -737,20 +737,6 @@ extern unsigned long pte_file(pte_t);
|
||||
extern pte_t pgoff_to_pte(unsigned long);
|
||||
#define PTE_FILE_MAX_BITS (64UL - PAGE_SHIFT - 1UL)
|
||||
|
||||
extern unsigned long prom_virt_to_phys(unsigned long, int *);
|
||||
|
||||
extern unsigned long sun4u_get_pte(unsigned long);
|
||||
|
||||
static inline unsigned long __get_phys(unsigned long addr)
|
||||
{
|
||||
return sun4u_get_pte(addr);
|
||||
}
|
||||
|
||||
static inline int __get_iospace(unsigned long addr)
|
||||
{
|
||||
return ((sun4u_get_pte(addr) & 0xf0000000) >> 28);
|
||||
}
|
||||
|
||||
extern unsigned long *sparc64_valid_addr_bitmap;
|
||||
|
||||
/* Needs to be defined here and not in linux/mm.h, as it is arch dependent */
|
||||
|
||||
Reference in New Issue
Block a user