All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] x86/shadow: make sh_remove_write_access() helper HVM only
@ 2020-04-21 12:05 Jan Beulich
  2020-04-21 12:06 ` Andrew Cooper
  2020-04-22  6:48 ` Tim Deegan
  0 siblings, 2 replies; 3+ messages in thread
From: Jan Beulich @ 2020-04-21 12:05 UTC (permalink / raw)
  To: xen-devel
  Cc: Andrew Cooper, Tim Deegan, George Dunlap, Wei Liu, Roger Pau Monné

Despite the inline attribute at least some clang versions warn about
trace_shadow_wrmap_bf() being unused in !HVM builds. Include the helper
in the #ifdef region.

Fixes: 8b8d011ad868 ("x86/shadow: the guess_wrmap() hook is needed for HVM only")
Reported-by: Andrew Cooper <andrew.cooper3@citrix.com>
Signed-off-by: Jan Beulich <jbeulich@suse.com>

--- a/xen/arch/x86/mm/shadow/common.c
+++ b/xen/arch/x86/mm/shadow/common.c
@@ -1756,6 +1756,7 @@ void sh_destroy_shadow(struct domain *d,
     }
 }
 
+#ifdef CONFIG_HVM
 static inline void trace_shadow_wrmap_bf(mfn_t gmfn)
 {
     if ( tb_init_done )
@@ -1767,7 +1768,6 @@ static inline void trace_shadow_wrmap_bf
     }
 }
 
-#ifdef CONFIG_HVM
 /**************************************************************************/
 /* Remove all writeable mappings of a guest frame from the shadow tables
  * Returns non-zero if we need to flush TLBs.


^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH] x86/shadow: make sh_remove_write_access() helper HVM only
  2020-04-21 12:05 [PATCH] x86/shadow: make sh_remove_write_access() helper HVM only Jan Beulich
@ 2020-04-21 12:06 ` Andrew Cooper
  2020-04-22  6:48 ` Tim Deegan
  1 sibling, 0 replies; 3+ messages in thread
From: Andrew Cooper @ 2020-04-21 12:06 UTC (permalink / raw)
  To: Jan Beulich, xen-devel
  Cc: Tim Deegan, George Dunlap, Wei Liu, Roger Pau Monné

On 21/04/2020 13:05, Jan Beulich wrote:
> Despite the inline attribute at least some clang versions warn about
> trace_shadow_wrmap_bf() being unused in !HVM builds. Include the helper
> in the #ifdef region.
>
> Fixes: 8b8d011ad868 ("x86/shadow: the guess_wrmap() hook is needed for HVM only")
> Reported-by: Andrew Cooper <andrew.cooper3@citrix.com>
> Signed-off-by: Jan Beulich <jbeulich@suse.com>

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


^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH] x86/shadow: make sh_remove_write_access() helper HVM only
  2020-04-21 12:05 [PATCH] x86/shadow: make sh_remove_write_access() helper HVM only Jan Beulich
  2020-04-21 12:06 ` Andrew Cooper
@ 2020-04-22  6:48 ` Tim Deegan
  1 sibling, 0 replies; 3+ messages in thread
From: Tim Deegan @ 2020-04-22  6:48 UTC (permalink / raw)
  To: Jan Beulich
  Cc: xen-devel, Roger Pau Monné, George Dunlap, Wei Liu, Andrew Cooper

At 14:05 +0200 on 21 Apr (1587477956), Jan Beulich wrote:
> Despite the inline attribute at least some clang versions warn about
> trace_shadow_wrmap_bf() being unused in !HVM builds. Include the helper
> in the #ifdef region.
> 
> Fixes: 8b8d011ad868 ("x86/shadow: the guess_wrmap() hook is needed for HVM only")
> Reported-by: Andrew Cooper <andrew.cooper3@citrix.com>
> Signed-off-by: Jan Beulich <jbeulich@suse.com>

Acked-by: Tim Deegan <tim@xen.org>


^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2020-04-22  6:48 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-04-21 12:05 [PATCH] x86/shadow: make sh_remove_write_access() helper HVM only Jan Beulich
2020-04-21 12:06 ` Andrew Cooper
2020-04-22  6:48 ` Tim Deegan

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.