Skip to contentSkip to conversation

x86: don't offer Hyper-V option when "PV Shim Exclusive"

PATCH In review Jan Beulich 4 participants 4 messages Dec 5, 2019

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 x86: don't offer Hyper-V option when "PV Shim Exclusive"

This only added dead code. Use "if" instead of "depends on" to make (halfway) clear that other guest options should also go in thae same block. Move the option down such that the shim related options get presented first, avoiding to ask the question when the answer may end up being discarded.

While in the neighborhood also bring PV_SHIM_EXCLUSIVE into more "canonical" shape.

xen/arch/x86/Kconfig +13 -10
@@ -164,14 +164,6 @@ endchoice
 config GUEST
 	bool
 
-config HYPERV_GUEST
-	bool "Hyper-V Guest"
-	select GUEST
-	---help---
-	  Support for Xen detecting when it is running under Hyper-V.
-
-	  If unsure, say N.
-
 config XEN_GUEST
 	bool "Xen Guest"
 	select GUEST
@@ -201,8 +193,7 @@ config PV_SHIM
 	  If unsure, say Y.
 
 config PV_SHIM_EXCLUSIVE
-	def_bool n
-	prompt "PV Shim Exclusive"
+	bool "PV Shim Exclusive"
 	depends on PV_SHIM
 	---help---
 	  Build Xen in a way which unconditionally assumes PV_SHIM mode.  This
@@ -211,6 +202,18 @@ config PV_SHIM_EXCLUSIVE
 
 	  If unsure, say N.
 
+if !PV_SHIM_EXCLUSIVE
+
+config HYPERV_GUEST
+	bool "Hyper-V Guest"
+	select GUEST
+	---help---
+	  Support for Xen detecting when it is running under Hyper-V.
+
+	  If unsure, say N.
+
+endif
+
 config MEM_SHARING
 	bool "Xen memory sharing support" if EXPERT = "y"
 	depends on HVM

_______________________________________________
Xen-devel mailing list
[email protected]
https://lists.xenproject.org/mailman/listinfo/xen-devel

Reviewed-by on v1 1/1
#1 lore raw
Quoted 7 lines · Jan Beulich

This only added dead code. Use "if" instead of "depends on" to make (halfway) clear that other guest options should also go in thae same block. Move the option down such that the shim related options get presented first, avoiding to ask the question when the answer may end up being discarded.

Quoted 5 lines

While in the neighborhood also bring PV_SHIM_EXCLUSIVE into more "canonical" shape.

_______________________________________________
Xen-devel mailing list
[email protected]
https://lists.xenproject.org/mailman/listinfo/xen-devel

#2 lore raw
In reply to Jan Beulich
Quoted 3 lines · Jan Beulich

This only added dead code. Use "if" instead of "depends on" to make (halfway) clear that other guest options should also go in thae same

s/thae/the/

Quoted 7 lines

block. Move the option down such that the shim related options get presented first, avoiding to ask the question when the answer may end up being discarded.

While in the neighborhood also bring PV_SHIM_EXCLUSIVE into more "canonical" shape.

Alan

_______________________________________________
Xen-devel mailing list
[email protected]
https://lists.xenproject.org/mailman/listinfo/xen-devel

Acked-by on v1 1/1
#3 lore raw
In reply to Jan Beulich
Quoted 10 lines · Jan Beulich

This only added dead code. Use "if" instead of "depends on" to make (halfway) clear that other guest options should also go in thae same block. Move the option down such that the shim related options get presented first, avoiding to ask the question when the answer may end up being discarded.

While in the neighborhood also bring PV_SHIM_EXCLUSIVE into more "canonical" shape.

_______________________________________________
Xen-devel mailing list
[email protected]
https://lists.xenproject.org/mailman/listinfo/xen-devel