[PATCH 05/22] x86/mm: make virt_to_xen_l1e() static

Roger Pau Monne posted 22 patches 1 month, 3 weeks ago
[PATCH 05/22] x86/mm: make virt_to_xen_l1e() static
Posted by Roger Pau Monne 1 month, 3 weeks ago
There are no callers outside the translation unit where it's defined, so make
the function static.

No functional change intended.

Signed-off-by: Roger Pau Monné <roger.pau@citrix.com>
---
 xen/arch/x86/include/asm/mm.h | 2 --
 xen/arch/x86/mm.c             | 2 +-
 2 files changed, 1 insertion(+), 3 deletions(-)

diff --git a/xen/arch/x86/include/asm/mm.h b/xen/arch/x86/include/asm/mm.h
index 98b66edaca5e..b3853ae734fa 100644
--- a/xen/arch/x86/include/asm/mm.h
+++ b/xen/arch/x86/include/asm/mm.h
@@ -567,8 +567,6 @@ mfn_t alloc_xen_pagetable(void);
 void free_xen_pagetable(mfn_t mfn);
 void *alloc_mapped_pagetable(mfn_t *pmfn);
 
-l1_pgentry_t *virt_to_xen_l1e(unsigned long v);
-
 int __sync_local_execstate(void);
 
 /* Arch-specific portion of memory_op hypercall. */
diff --git a/xen/arch/x86/mm.c b/xen/arch/x86/mm.c
index 01380fd82c9d..ca3d116b0e05 100644
--- a/xen/arch/x86/mm.c
+++ b/xen/arch/x86/mm.c
@@ -5087,7 +5087,7 @@ static l2_pgentry_t *virt_to_xen_l2e(unsigned long v)
     return map_l2t_from_l3e(l3e) + l2_table_offset(v);
 }
 
-l1_pgentry_t *virt_to_xen_l1e(unsigned long v)
+static l1_pgentry_t *virt_to_xen_l1e(unsigned long v)
 {
     l2_pgentry_t *pl2e, l2e;
 
-- 
2.45.2


Re: [PATCH 05/22] x86/mm: make virt_to_xen_l1e() static
Posted by Andrew Cooper 1 month, 2 weeks ago
On 26/07/2024 4:21 pm, Roger Pau Monne wrote:
> There are no callers outside the translation unit where it's defined, so make
> the function static.
>
> No functional change intended.
>
> Signed-off-by: Roger Pau Monné <roger.pau@citrix.com>

Acked-by: Andrew Cooper <andrew.cooper3@citrix.com>