diff mbox series

[v2,1/5] xen/char: Default HAS_NS16550 to y only for X86 and ARM

Message ID 3960a676376e0163d97ac02f968966cdfaccbf75.1620965208.git.connojdavis@gmail.com (mailing list archive)
State Superseded
Headers show
Series Minimal build for RISCV | expand

Commit Message

Connor Davis May 14, 2021, 4:17 a.m. UTC
Defaulting to yes only for X86 and ARM reduces the requirements
for a minimal build when porting new architectures.

Signed-off-by: Connor Davis <connojdavis@gmail.com>
---
 xen/drivers/char/Kconfig | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Elliott Mitchell May 14, 2021, 5:34 a.m. UTC | #1
On Thu, May 13, 2021 at 10:17:08PM -0600, Connor Davis wrote:
> Defaulting to yes only for X86 and ARM reduces the requirements
> for a minimal build when porting new architectures.
> 
> Signed-off-by: Connor Davis <connojdavis@gmail.com>
> ---
>  xen/drivers/char/Kconfig | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/xen/drivers/char/Kconfig b/xen/drivers/char/Kconfig
> index b572305657..b15b0c8d6a 100644
> --- a/xen/drivers/char/Kconfig
> +++ b/xen/drivers/char/Kconfig
> @@ -1,6 +1,6 @@
>  config HAS_NS16550
>  	bool "NS16550 UART driver" if ARM
> -	default y
> +	default y if (ARM || X86)
>  	help
>  	  This selects the 16550-series UART support. For most systems, say Y.

Are you sure this is necessary?  I've been working on something else
recently, but did you confirm this with a full build?

If you observe the line directly above that one, `_if_ARM_`.  I'm pretty
sure this driver will refuse to show up in a RISC-V build.
Connor Davis May 14, 2021, 2:13 p.m. UTC | #2
On 5/13/21 11:34 PM, Elliott Mitchell wrote:
> On Thu, May 13, 2021 at 10:17:08PM -0600, Connor Davis wrote:
>> Defaulting to yes only for X86 and ARM reduces the requirements
>> for a minimal build when porting new architectures.
>>
>> Signed-off-by: Connor Davis <connojdavis@gmail.com>
>> ---
>>   xen/drivers/char/Kconfig | 2 +-
>>   1 file changed, 1 insertion(+), 1 deletion(-)
>>
>> diff --git a/xen/drivers/char/Kconfig b/xen/drivers/char/Kconfig
>> index b572305657..b15b0c8d6a 100644
>> --- a/xen/drivers/char/Kconfig
>> +++ b/xen/drivers/char/Kconfig
>> @@ -1,6 +1,6 @@
>>   config HAS_NS16550
>>   	bool "NS16550 UART driver" if ARM
>> -	default y
>> +	default y if (ARM || X86)
>>   	help
>>   	  This selects the 16550-series UART support. For most systems, say Y.
> Are you sure this is necessary?  I've been working on something else
> recently, but did you confirm this with a full build?
>
> If you observe the line directly above that one, `_if_ARM_`.  I'm pretty
> sure this driver will refuse to show up in a RISC-V build.
>
It isn't visible in Kconfig, true, but it will still be built because of

the unconditional "default y"


Thanks,

Connor
diff mbox series

Patch

diff --git a/xen/drivers/char/Kconfig b/xen/drivers/char/Kconfig
index b572305657..b15b0c8d6a 100644
--- a/xen/drivers/char/Kconfig
+++ b/xen/drivers/char/Kconfig
@@ -1,6 +1,6 @@ 
 config HAS_NS16550
 	bool "NS16550 UART driver" if ARM
-	default y
+	default y if (ARM || X86)
 	help
 	  This selects the 16550-series UART support. For most systems, say Y.