* [PATCH 1/4] vgacon: rework Kconfig dependencies
@ 2023-07-07 9:52 Arnd Bergmann
2023-07-07 9:52 ` [PATCH 2/4] vgacon: rework screen_info #ifdef checks Arnd Bergmann
` (4 more replies)
0 siblings, 5 replies; 11+ messages in thread
From: Arnd Bergmann @ 2023-07-07 9:52 UTC (permalink / raw)
To: Thomas Zimmermann
Cc: javierm, linux-fbdev, linux-kernel, Russell King, dri-devel,
Ard Biesheuvel, Helge Deller, Greg Kroah-Hartman, Arnd Bergmann,
Paul Walmsley, Palmer Dabbelt, Albert Ou, Guo Ren, linux-riscv,
linux-csky
From: Arnd Bergmann <arnd@arndb.de>
The list of dependencies here is phrased as an opt-out, but this is missing
a lot of architectures that don't actually support VGA consoles, and some
of the entries are stale:
- powerpc used to support VGA consoles in the old arch/ppc codebase, but
the merged arch/powerpc never did
- arm lists footbridge, integrator and netwinder, but netwinder is actually
part of footbridge, and integrator does not appear to have an actual
VGA hardware, or list it in its ATAG or DT.
- mips has a few platforms (jazz, sibyte, and sni) that initialize
screen_info, on everything else the console is selected but cannot
actually work.
- csky, hexgagon, loongarch, nios2, riscv and xtensa are not listed
in the opt-out table and declare a screen_info to allow building
vga_con, but this cannot work because the console is never selected.
Replace this with an opt-in table that lists only the platforms that
remain. This is effectively x86, plus a couple of historic workstation
and server machines that reused parts of the x86 system architecture.
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
---
drivers/video/console/Kconfig | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/drivers/video/console/Kconfig b/drivers/video/console/Kconfig
index a2a88d42edf0c..47c498defc211 100644
--- a/drivers/video/console/Kconfig
+++ b/drivers/video/console/Kconfig
@@ -7,9 +7,9 @@ menu "Console display driver support"
config VGA_CONSOLE
bool "VGA text console" if EXPERT || !X86
- depends on !4xx && !PPC_8xx && !SPARC && !M68K && !PARISC && !SUPERH && \
- (!ARM || ARCH_FOOTBRIDGE || ARCH_INTEGRATOR || ARCH_NETWINDER) && \
- !ARM64 && !ARC && !MICROBLAZE && !OPENRISC && !S390 && !UML
+ depends on ALPHA || IA64 || X86 || \
+ (ARM && ARCH_FOOTBRIDGE) || \
+ (MIPS && (MIPS_MALTA || SIBYTE_BCM112X || SIBYTE_SB1250 || SIBYTE_BCM1x80 || SNI_RM))
select APERTURE_HELPERS if (DRM || FB || VFIO_PCI_CORE)
default y
help
--
2.39.2
_______________________________________________
linux-riscv mailing list
linux-riscv@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-riscv
^ permalink raw reply related [flat|nested] 11+ messages in thread
* [PATCH 2/4] vgacon: rework screen_info #ifdef checks
2023-07-07 9:52 [PATCH 1/4] vgacon: rework Kconfig dependencies Arnd Bergmann
@ 2023-07-07 9:52 ` Arnd Bergmann
2023-07-07 13:40 ` Javier Martinez Canillas
2023-07-08 14:11 ` Thomas Bogendoerfer
2023-07-07 13:17 ` [PATCH 1/4] vgacon: rework Kconfig dependencies Javier Martinez Canillas
` (3 subsequent siblings)
4 siblings, 2 replies; 11+ messages in thread
From: Arnd Bergmann @ 2023-07-07 9:52 UTC (permalink / raw)
To: Thomas Zimmermann
Cc: javierm, linux-fbdev, linux-kernel, Russell King, dri-devel,
Ard Biesheuvel, Helge Deller, Greg Kroah-Hartman, Arnd Bergmann,
Richard Henderson, Ivan Kokshaysky, Matt Turner, Huacai Chen,
WANG Xuerui, Thomas Bogendoerfer, Michael Ellerman,
Nicholas Piggin, Christophe Leroy, Paul Walmsley, Palmer Dabbelt,
Albert Ou, linux-alpha, linux-ia64, loongarch, linux-mips,
linuxppc-dev, linux-riscv
From: Arnd Bergmann <arnd@arndb.de>
On non-x86 architectures, the screen_info variable is generally only
used for the VGA console where supported, and in some cases the EFI
framebuffer or vga16fb.
Now that we have a definite list of which architectures actually use it
for what, use consistent #ifdef checks so the global variable is only
defined when it is actually used on those architectures.
On powerpc, there is no support for vgacon, but there is support for
vga16fb. Loongarch and riscv have no support for vgacon or vga16fb, but
they support EFI firmware, so only that needs to be checked, and the
initialization can be removed because that is handled by EFI.
IA64 has both vgacon and EFI.
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
---
arch/alpha/kernel/setup.c | 2 ++
arch/alpha/kernel/sys_sio.c | 2 ++
arch/ia64/kernel/setup.c | 4 ++++
arch/loongarch/kernel/setup.c | 2 ++
arch/mips/jazz/setup.c | 2 +-
arch/mips/kernel/setup.c | 2 +-
arch/mips/sibyte/swarm/setup.c | 2 +-
arch/mips/sni/setup.c | 2 +-
arch/powerpc/kernel/setup-common.c | 2 +-
arch/riscv/kernel/setup.c | 11 ++---------
10 files changed, 17 insertions(+), 14 deletions(-)
diff --git a/arch/alpha/kernel/setup.c b/arch/alpha/kernel/setup.c
index b650ff1cb022e..b4d2297765c02 100644
--- a/arch/alpha/kernel/setup.c
+++ b/arch/alpha/kernel/setup.c
@@ -131,6 +131,7 @@ static void determine_cpu_caches (unsigned int);
static char __initdata command_line[COMMAND_LINE_SIZE];
+#ifdef CONFIG_VGA_CONSOLE
/*
* The format of "screen_info" is strange, and due to early
* i386-setup code. This is just enough to make the console
@@ -147,6 +148,7 @@ struct screen_info screen_info = {
};
EXPORT_SYMBOL(screen_info);
+#endif
/*
* The direct map I/O window, if any. This should be the same
diff --git a/arch/alpha/kernel/sys_sio.c b/arch/alpha/kernel/sys_sio.c
index 7c420d8dac53d..7de8a5d2d2066 100644
--- a/arch/alpha/kernel/sys_sio.c
+++ b/arch/alpha/kernel/sys_sio.c
@@ -57,11 +57,13 @@ sio_init_irq(void)
static inline void __init
alphabook1_init_arch(void)
{
+#ifdef CONFIG_VGA_CONSOLE
/* The AlphaBook1 has LCD video fixed at 800x600,
37 rows and 100 cols. */
screen_info.orig_y = 37;
screen_info.orig_video_cols = 100;
screen_info.orig_video_lines = 37;
+#endif
lca_init_arch();
}
diff --git a/arch/ia64/kernel/setup.c b/arch/ia64/kernel/setup.c
index 5a55ac82c13a4..0c09ff7fde46b 100644
--- a/arch/ia64/kernel/setup.c
+++ b/arch/ia64/kernel/setup.c
@@ -86,9 +86,11 @@ EXPORT_SYMBOL(local_per_cpu_offset);
#endif
unsigned long ia64_cycles_per_usec;
struct ia64_boot_param *ia64_boot_param;
+#if defined(CONFIG_VGA_CONSOLE) || defined(CONFIG_EFI)
struct screen_info screen_info;
unsigned long vga_console_iobase;
unsigned long vga_console_membase;
+#endif
static struct resource data_resource = {
.name = "Kernel data",
@@ -497,6 +499,7 @@ early_console_setup (char *cmdline)
static void __init
screen_info_setup(void)
{
+#ifdef CONFIG_VGA_CONSOLE
unsigned int orig_x, orig_y, num_cols, num_rows, font_height;
memset(&screen_info, 0, sizeof(screen_info));
@@ -525,6 +528,7 @@ screen_info_setup(void)
screen_info.orig_video_mode = 3; /* XXX fake */
screen_info.orig_video_isVGA = 1; /* XXX fake */
screen_info.orig_video_ega_bx = 3; /* XXX fake */
+#endif
}
static inline void
diff --git a/arch/loongarch/kernel/setup.c b/arch/loongarch/kernel/setup.c
index 78a00359bde3c..6b3932677f5de 100644
--- a/arch/loongarch/kernel/setup.c
+++ b/arch/loongarch/kernel/setup.c
@@ -57,7 +57,9 @@
#define SMBIOS_CORE_PACKAGE_OFFSET 0x23
#define LOONGSON_EFI_ENABLE (1 << 3)
+#ifdef CONFIG_EFI
struct screen_info screen_info __section(".data");
+#endif
unsigned long fw_arg0, fw_arg1, fw_arg2;
DEFINE_PER_CPU(unsigned long, kernelsp);
diff --git a/arch/mips/jazz/setup.c b/arch/mips/jazz/setup.c
index ee044261eb223..3c14548353e47 100644
--- a/arch/mips/jazz/setup.c
+++ b/arch/mips/jazz/setup.c
@@ -76,7 +76,7 @@ void __init plat_mem_setup(void)
_machine_restart = jazz_machine_restart;
-#ifdef CONFIG_VT
+#ifdef CONFIG_VGA_CONSOLE
screen_info = (struct screen_info) {
.orig_video_cols = 160,
.orig_video_lines = 64,
diff --git a/arch/mips/kernel/setup.c b/arch/mips/kernel/setup.c
index cb871eb784a7c..1aba7dc95132c 100644
--- a/arch/mips/kernel/setup.c
+++ b/arch/mips/kernel/setup.c
@@ -54,7 +54,7 @@ struct cpuinfo_mips cpu_data[NR_CPUS] __read_mostly;
EXPORT_SYMBOL(cpu_data);
-#ifdef CONFIG_VT
+#ifdef CONFIG_VGA_CONSOLE
struct screen_info screen_info;
#endif
diff --git a/arch/mips/sibyte/swarm/setup.c b/arch/mips/sibyte/swarm/setup.c
index 76683993cdd3a..37df504d3ecbb 100644
--- a/arch/mips/sibyte/swarm/setup.c
+++ b/arch/mips/sibyte/swarm/setup.c
@@ -129,7 +129,7 @@ void __init plat_mem_setup(void)
if (m41t81_probe())
swarm_rtc_type = RTC_M41T81;
-#ifdef CONFIG_VT
+#ifdef CONFIG_VGA_CONSOLE
screen_info = (struct screen_info) {
.orig_video_page = 52,
.orig_video_mode = 3,
diff --git a/arch/mips/sni/setup.c b/arch/mips/sni/setup.c
index efad85c8c823b..9984cf91be7d0 100644
--- a/arch/mips/sni/setup.c
+++ b/arch/mips/sni/setup.c
@@ -38,7 +38,7 @@ extern void sni_machine_power_off(void);
static void __init sni_display_setup(void)
{
-#if defined(CONFIG_VT) && defined(CONFIG_VGA_CONSOLE) && defined(CONFIG_FW_ARC)
+#if defined(CONFIG_VGA_CONSOLE) && defined(CONFIG_FW_ARC)
struct screen_info *si = &screen_info;
DISPLAY_STATUS *di;
diff --git a/arch/powerpc/kernel/setup-common.c b/arch/powerpc/kernel/setup-common.c
index d2a446216444f..b717875a12a9a 100644
--- a/arch/powerpc/kernel/setup-common.c
+++ b/arch/powerpc/kernel/setup-common.c
@@ -98,6 +98,7 @@ int boot_cpu_hwid = -1;
int dcache_bsize;
int icache_bsize;
+#if IS_ENABLED(CONFIG_FB_VGA16)
/*
* This still seems to be needed... -- paulus
*/
@@ -109,7 +110,6 @@ struct screen_info screen_info = {
.orig_video_isVGA = 1,
.orig_video_points = 16
};
-#if defined(CONFIG_FB_VGA16_MODULE)
EXPORT_SYMBOL(screen_info);
#endif
diff --git a/arch/riscv/kernel/setup.c b/arch/riscv/kernel/setup.c
index 971fe776e2f8b..a3dbe13f45fb3 100644
--- a/arch/riscv/kernel/setup.c
+++ b/arch/riscv/kernel/setup.c
@@ -39,15 +39,8 @@
#include "head.h"
-#if defined(CONFIG_DUMMY_CONSOLE) || defined(CONFIG_EFI)
-struct screen_info screen_info __section(".data") = {
- .orig_video_lines = 30,
- .orig_video_cols = 80,
- .orig_video_mode = 0,
- .orig_video_ega_bx = 0,
- .orig_video_isVGA = 1,
- .orig_video_points = 8
-};
+#if defined(CONFIG_EFI)
+struct screen_info screen_info __section(".data");
#endif
/*
--
2.39.2
_______________________________________________
linux-riscv mailing list
linux-riscv@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-riscv
^ permalink raw reply related [flat|nested] 11+ messages in thread
* Re: [PATCH 1/4] vgacon: rework Kconfig dependencies
2023-07-07 9:52 [PATCH 1/4] vgacon: rework Kconfig dependencies Arnd Bergmann
2023-07-07 9:52 ` [PATCH 2/4] vgacon: rework screen_info #ifdef checks Arnd Bergmann
@ 2023-07-07 13:17 ` Javier Martinez Canillas
2023-07-07 15:07 ` Thomas Zimmermann
` (2 subsequent siblings)
4 siblings, 0 replies; 11+ messages in thread
From: Javier Martinez Canillas @ 2023-07-07 13:17 UTC (permalink / raw)
To: Arnd Bergmann, Thomas Zimmermann
Cc: linux-fbdev, linux-kernel, Russell King, dri-devel,
Ard Biesheuvel, Helge Deller, Greg Kroah-Hartman, Arnd Bergmann,
Paul Walmsley, Palmer Dabbelt, Albert Ou, Guo Ren, linux-riscv,
linux-csky
Arnd Bergmann <arnd@kernel.org> writes:
Hello Arnd,
> From: Arnd Bergmann <arnd@arndb.de>
>
> The list of dependencies here is phrased as an opt-out, but this is missing
> a lot of architectures that don't actually support VGA consoles, and some
> of the entries are stale:
>
> - powerpc used to support VGA consoles in the old arch/ppc codebase, but
> the merged arch/powerpc never did
>
> - arm lists footbridge, integrator and netwinder, but netwinder is actually
> part of footbridge, and integrator does not appear to have an actual
> VGA hardware, or list it in its ATAG or DT.
>
> - mips has a few platforms (jazz, sibyte, and sni) that initialize
> screen_info, on everything else the console is selected but cannot
> actually work.
>
> - csky, hexgagon, loongarch, nios2, riscv and xtensa are not listed
> in the opt-out table and declare a screen_info to allow building
> vga_con, but this cannot work because the console is never selected.
>
> Replace this with an opt-in table that lists only the platforms that
> remain. This is effectively x86, plus a couple of historic workstation
> and server machines that reused parts of the x86 system architecture.
>
> Signed-off-by: Arnd Bergmann <arnd@arndb.de>
> ---
Both our explanation and changes look good to me.
Reviewed-by: Javier Martinez Canillas <javierm@redhat.com>
--
Best regards,
Javier Martinez Canillas
Core Platforms
Red Hat
_______________________________________________
linux-riscv mailing list
linux-riscv@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-riscv
^ permalink raw reply [flat|nested] 11+ messages in thread
* Re: [PATCH 2/4] vgacon: rework screen_info #ifdef checks
2023-07-07 9:52 ` [PATCH 2/4] vgacon: rework screen_info #ifdef checks Arnd Bergmann
@ 2023-07-07 13:40 ` Javier Martinez Canillas
2023-07-07 14:32 ` Arnd Bergmann
2023-07-08 14:11 ` Thomas Bogendoerfer
1 sibling, 1 reply; 11+ messages in thread
From: Javier Martinez Canillas @ 2023-07-07 13:40 UTC (permalink / raw)
To: Arnd Bergmann, Thomas Zimmermann
Cc: linux-fbdev, linux-kernel, Russell King, dri-devel,
Ard Biesheuvel, Helge Deller, Greg Kroah-Hartman, Arnd Bergmann,
Richard Henderson, Ivan Kokshaysky, Matt Turner, Huacai Chen,
WANG Xuerui, Thomas Bogendoerfer, Michael Ellerman,
Nicholas Piggin, Christophe Leroy, Paul Walmsley, Palmer Dabbelt,
Albert Ou, linux-alpha, linux-ia64, loongarch, linux-mips,
linuxppc-dev, linux-riscv
Arnd Bergmann <arnd@kernel.org> writes:
> From: Arnd Bergmann <arnd@arndb.de>
>
> On non-x86 architectures, the screen_info variable is generally only
> used for the VGA console where supported, and in some cases the EFI
> framebuffer or vga16fb.
>
> Now that we have a definite list of which architectures actually use it
> for what, use consistent #ifdef checks so the global variable is only
> defined when it is actually used on those architectures.
>
> On powerpc, there is no support for vgacon, but there is support for
> vga16fb. Loongarch and riscv have no support for vgacon or vga16fb, but
> they support EFI firmware, so only that needs to be checked, and the
> initialization can be removed because that is handled by EFI.
> IA64 has both vgacon and EFI.
>
> Signed-off-by: Arnd Bergmann <arnd@arndb.de>
> ---
[...]
> diff --git a/arch/ia64/kernel/setup.c b/arch/ia64/kernel/setup.c
> index 5a55ac82c13a4..0c09ff7fde46b 100644
> --- a/arch/ia64/kernel/setup.c
> +++ b/arch/ia64/kernel/setup.c
> @@ -86,9 +86,11 @@ EXPORT_SYMBOL(local_per_cpu_offset);
> #endif
> unsigned long ia64_cycles_per_usec;
> struct ia64_boot_param *ia64_boot_param;
> +#if defined(CONFIG_VGA_CONSOLE) || defined(CONFIG_EFI)
> struct screen_info screen_info;
I think that only screen_info should be guarded by both symbols ?
> unsigned long vga_console_iobase;
It seems this variable was never used since it was introduced by commit
66b7f8a30437 ("[IA64-SGI] pcdp: add PCDP pci interface support") ?
> unsigned long vga_console_membase;
And this is only used by mdacon (not supported by ia64), vgacon and
vga16fb (not supported by ia64 either).
So this could just be guarded just by CONFIG_VGA_CONSOLE for ia64 ?
The rest of the patch looks good to me.
Reviewed-by: Javier Martinez Canillas <javierm@redhat.com>
--
Best regards,
Javier Martinez Canillas
Core Platforms
Red Hat
_______________________________________________
linux-riscv mailing list
linux-riscv@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-riscv
^ permalink raw reply [flat|nested] 11+ messages in thread
* Re: [PATCH 2/4] vgacon: rework screen_info #ifdef checks
2023-07-07 13:40 ` Javier Martinez Canillas
@ 2023-07-07 14:32 ` Arnd Bergmann
2023-07-07 15:27 ` Javier Martinez Canillas
0 siblings, 1 reply; 11+ messages in thread
From: Arnd Bergmann @ 2023-07-07 14:32 UTC (permalink / raw)
To: Javier Martinez Canillas, Arnd Bergmann, Thomas Zimmermann
Cc: linux-fbdev, linux-kernel, Russell King, dri-devel,
Ard Biesheuvel, Helge Deller, Greg Kroah-Hartman,
Richard Henderson, Ivan Kokshaysky, Matt Turner, Huacai Chen,
WANG Xuerui, Thomas Bogendoerfer, Michael Ellerman,
Nicholas Piggin, Christophe Leroy, Paul Walmsley, Palmer Dabbelt,
Albert Ou, linux-alpha, linux-ia64, loongarch, linux-mips,
linuxppc-dev, linux-riscv
On Fri, Jul 7, 2023, at 15:40, Javier Martinez Canillas wrote:
>> diff --git a/arch/ia64/kernel/setup.c b/arch/ia64/kernel/setup.c
>> index 5a55ac82c13a4..0c09ff7fde46b 100644
>> --- a/arch/ia64/kernel/setup.c
>> +++ b/arch/ia64/kernel/setup.c
>> @@ -86,9 +86,11 @@ EXPORT_SYMBOL(local_per_cpu_offset);
>> #endif
>> unsigned long ia64_cycles_per_usec;
>> struct ia64_boot_param *ia64_boot_param;
>> +#if defined(CONFIG_VGA_CONSOLE) || defined(CONFIG_EFI)
>> struct screen_info screen_info;
>
> I think that only screen_info should be guarded by both symbols ?
>
>> unsigned long vga_console_iobase;
>
> It seems this variable was never used since it was introduced by commit
> 66b7f8a30437 ("[IA64-SGI] pcdp: add PCDP pci interface support") ?
>
>> unsigned long vga_console_membase;
>
> And this is only used by mdacon (not supported by ia64), vgacon and
> vga16fb (not supported by ia64 either).
>
> So this could just be guarded just by CONFIG_VGA_CONSOLE for ia64 ?
Right, I though about doing this more accurately, but in the end
went for the simplest change rather than spending much more time
trying to clean up the unused variables etc.
Let me know if you'd prefer me to respin this part, otherwise
I'd call the ia64 bit good enough for the purpose of the series.
Arnd
_______________________________________________
linux-riscv mailing list
linux-riscv@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-riscv
^ permalink raw reply [flat|nested] 11+ messages in thread
* Re: [PATCH 1/4] vgacon: rework Kconfig dependencies
2023-07-07 9:52 [PATCH 1/4] vgacon: rework Kconfig dependencies Arnd Bergmann
2023-07-07 9:52 ` [PATCH 2/4] vgacon: rework screen_info #ifdef checks Arnd Bergmann
2023-07-07 13:17 ` [PATCH 1/4] vgacon: rework Kconfig dependencies Javier Martinez Canillas
@ 2023-07-07 15:07 ` Thomas Zimmermann
2023-08-01 16:55 ` Thomas Zimmermann
2023-08-01 17:05 ` Russell King (Oracle)
4 siblings, 0 replies; 11+ messages in thread
From: Thomas Zimmermann @ 2023-07-07 15:07 UTC (permalink / raw)
To: Arnd Bergmann
Cc: javierm, linux-fbdev, linux-kernel, Russell King, dri-devel,
Ard Biesheuvel, Helge Deller, Greg Kroah-Hartman, Arnd Bergmann,
Paul Walmsley, Palmer Dabbelt, Albert Ou, Guo Ren, linux-riscv,
linux-csky
[-- Attachment #1.1.1: Type: text/plain, Size: 2543 bytes --]
Hi,
for the whole series:
Reviewed-by: Thomas Zimmermann <tzimmermann@suse.de>
Best regards
Thomas
Am 07.07.23 um 11:52 schrieb Arnd Bergmann:
> From: Arnd Bergmann <arnd@arndb.de>
>
> The list of dependencies here is phrased as an opt-out, but this is missing
> a lot of architectures that don't actually support VGA consoles, and some
> of the entries are stale:
>
> - powerpc used to support VGA consoles in the old arch/ppc codebase, but
> the merged arch/powerpc never did
>
> - arm lists footbridge, integrator and netwinder, but netwinder is actually
> part of footbridge, and integrator does not appear to have an actual
> VGA hardware, or list it in its ATAG or DT.
>
> - mips has a few platforms (jazz, sibyte, and sni) that initialize
> screen_info, on everything else the console is selected but cannot
> actually work.
>
> - csky, hexgagon, loongarch, nios2, riscv and xtensa are not listed
> in the opt-out table and declare a screen_info to allow building
> vga_con, but this cannot work because the console is never selected.
>
> Replace this with an opt-in table that lists only the platforms that
> remain. This is effectively x86, plus a couple of historic workstation
> and server machines that reused parts of the x86 system architecture.
>
> Signed-off-by: Arnd Bergmann <arnd@arndb.de>
> ---
> drivers/video/console/Kconfig | 6 +++---
> 1 file changed, 3 insertions(+), 3 deletions(-)
>
> diff --git a/drivers/video/console/Kconfig b/drivers/video/console/Kconfig
> index a2a88d42edf0c..47c498defc211 100644
> --- a/drivers/video/console/Kconfig
> +++ b/drivers/video/console/Kconfig
> @@ -7,9 +7,9 @@ menu "Console display driver support"
>
> config VGA_CONSOLE
> bool "VGA text console" if EXPERT || !X86
> - depends on !4xx && !PPC_8xx && !SPARC && !M68K && !PARISC && !SUPERH && \
> - (!ARM || ARCH_FOOTBRIDGE || ARCH_INTEGRATOR || ARCH_NETWINDER) && \
> - !ARM64 && !ARC && !MICROBLAZE && !OPENRISC && !S390 && !UML
> + depends on ALPHA || IA64 || X86 || \
> + (ARM && ARCH_FOOTBRIDGE) || \
> + (MIPS && (MIPS_MALTA || SIBYTE_BCM112X || SIBYTE_SB1250 || SIBYTE_BCM1x80 || SNI_RM))
> select APERTURE_HELPERS if (DRM || FB || VFIO_PCI_CORE)
> default y
> help
--
Thomas Zimmermann
Graphics Driver Developer
SUSE Software Solutions Germany GmbH
Frankenstrasse 146, 90461 Nuernberg, Germany
GF: Ivo Totev, Andrew Myers, Andrew McDonald, Boudien Moerman
HRB 36809 (AG Nuernberg)
[-- Attachment #1.2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 840 bytes --]
[-- Attachment #2: Type: text/plain, Size: 161 bytes --]
_______________________________________________
linux-riscv mailing list
linux-riscv@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-riscv
^ permalink raw reply [flat|nested] 11+ messages in thread
* Re: [PATCH 2/4] vgacon: rework screen_info #ifdef checks
2023-07-07 14:32 ` Arnd Bergmann
@ 2023-07-07 15:27 ` Javier Martinez Canillas
0 siblings, 0 replies; 11+ messages in thread
From: Javier Martinez Canillas @ 2023-07-07 15:27 UTC (permalink / raw)
To: Arnd Bergmann, Arnd Bergmann, Thomas Zimmermann
Cc: linux-fbdev, linux-kernel, Russell King, dri-devel,
Ard Biesheuvel, Helge Deller, Greg Kroah-Hartman,
Richard Henderson, Ivan Kokshaysky, Matt Turner, Huacai Chen,
WANG Xuerui, Thomas Bogendoerfer, Michael Ellerman,
Nicholas Piggin, Christophe Leroy, Paul Walmsley, Palmer Dabbelt,
Albert Ou, linux-alpha, linux-ia64, loongarch, linux-mips,
linuxppc-dev, linux-riscv
"Arnd Bergmann" <arnd@arndb.de> writes:
> On Fri, Jul 7, 2023, at 15:40, Javier Martinez Canillas wrote:
[...]
>> And this is only used by mdacon (not supported by ia64), vgacon and
>> vga16fb (not supported by ia64 either).
>>
>> So this could just be guarded just by CONFIG_VGA_CONSOLE for ia64 ?
>
> Right, I though about doing this more accurately, but in the end
> went for the simplest change rather than spending much more time
> trying to clean up the unused variables etc.
>
> Let me know if you'd prefer me to respin this part, otherwise
> I'd call the ia64 bit good enough for the purpose of the series.
>
No need to re-spin, agreed that makes sense to keep it simpler.
--
Best regards,
Javier Martinez Canillas
Core Platforms
Red Hat
_______________________________________________
linux-riscv mailing list
linux-riscv@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-riscv
^ permalink raw reply [flat|nested] 11+ messages in thread
* Re: [PATCH 2/4] vgacon: rework screen_info #ifdef checks
2023-07-07 9:52 ` [PATCH 2/4] vgacon: rework screen_info #ifdef checks Arnd Bergmann
2023-07-07 13:40 ` Javier Martinez Canillas
@ 2023-07-08 14:11 ` Thomas Bogendoerfer
1 sibling, 0 replies; 11+ messages in thread
From: Thomas Bogendoerfer @ 2023-07-08 14:11 UTC (permalink / raw)
To: Arnd Bergmann
Cc: Thomas Zimmermann, javierm, linux-fbdev, linux-kernel,
Russell King, dri-devel, Ard Biesheuvel, Helge Deller,
Greg Kroah-Hartman, Arnd Bergmann, Richard Henderson,
Ivan Kokshaysky, Matt Turner, Huacai Chen, WANG Xuerui,
Michael Ellerman, Nicholas Piggin, Christophe Leroy,
Paul Walmsley, Palmer Dabbelt, Albert Ou, linux-alpha, linux-ia64,
loongarch, linux-mips, linuxppc-dev, linux-riscv
On Fri, Jul 07, 2023 at 11:52:24AM +0200, Arnd Bergmann wrote:
> diff --git a/arch/mips/jazz/setup.c b/arch/mips/jazz/setup.c
> index ee044261eb223..3c14548353e47 100644
> --- a/arch/mips/jazz/setup.c
> +++ b/arch/mips/jazz/setup.c
> @@ -76,7 +76,7 @@ void __init plat_mem_setup(void)
>
> _machine_restart = jazz_machine_restart;
>
> -#ifdef CONFIG_VT
> +#ifdef CONFIG_VGA_CONSOLE
> screen_info = (struct screen_info) {
> .orig_video_cols = 160,
> .orig_video_lines = 64,
that wssn't intended for VGA but for fbdev/g364fb, which doesn't use
it. So removing it is probably the best thing.
Thomas.
--
Crap can work. Given enough thrust pigs will fly, but it's not necessarily a
good idea. [ RFC1925, 2.3 ]
_______________________________________________
linux-riscv mailing list
linux-riscv@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-riscv
^ permalink raw reply [flat|nested] 11+ messages in thread
* Re: [PATCH 1/4] vgacon: rework Kconfig dependencies
2023-07-07 9:52 [PATCH 1/4] vgacon: rework Kconfig dependencies Arnd Bergmann
` (2 preceding siblings ...)
2023-07-07 15:07 ` Thomas Zimmermann
@ 2023-08-01 16:55 ` Thomas Zimmermann
2023-08-01 17:05 ` Russell King (Oracle)
4 siblings, 0 replies; 11+ messages in thread
From: Thomas Zimmermann @ 2023-08-01 16:55 UTC (permalink / raw)
To: Arnd Bergmann
Cc: javierm, linux-fbdev, linux-kernel, Russell King, dri-devel,
Ard Biesheuvel, Helge Deller, Greg Kroah-Hartman, Arnd Bergmann,
Paul Walmsley, Palmer Dabbelt, Albert Ou, Guo Ren, linux-riscv,
linux-csky
[-- Attachment #1.1.1: Type: text/plain, Size: 2476 bytes --]
ping! What's the status of this patchset?
Am 07.07.23 um 11:52 schrieb Arnd Bergmann:
> From: Arnd Bergmann <arnd@arndb.de>
>
> The list of dependencies here is phrased as an opt-out, but this is missing
> a lot of architectures that don't actually support VGA consoles, and some
> of the entries are stale:
>
> - powerpc used to support VGA consoles in the old arch/ppc codebase, but
> the merged arch/powerpc never did
>
> - arm lists footbridge, integrator and netwinder, but netwinder is actually
> part of footbridge, and integrator does not appear to have an actual
> VGA hardware, or list it in its ATAG or DT.
>
> - mips has a few platforms (jazz, sibyte, and sni) that initialize
> screen_info, on everything else the console is selected but cannot
> actually work.
>
> - csky, hexgagon, loongarch, nios2, riscv and xtensa are not listed
> in the opt-out table and declare a screen_info to allow building
> vga_con, but this cannot work because the console is never selected.
>
> Replace this with an opt-in table that lists only the platforms that
> remain. This is effectively x86, plus a couple of historic workstation
> and server machines that reused parts of the x86 system architecture.
>
> Signed-off-by: Arnd Bergmann <arnd@arndb.de>
> ---
> drivers/video/console/Kconfig | 6 +++---
> 1 file changed, 3 insertions(+), 3 deletions(-)
>
> diff --git a/drivers/video/console/Kconfig b/drivers/video/console/Kconfig
> index a2a88d42edf0c..47c498defc211 100644
> --- a/drivers/video/console/Kconfig
> +++ b/drivers/video/console/Kconfig
> @@ -7,9 +7,9 @@ menu "Console display driver support"
>
> config VGA_CONSOLE
> bool "VGA text console" if EXPERT || !X86
> - depends on !4xx && !PPC_8xx && !SPARC && !M68K && !PARISC && !SUPERH && \
> - (!ARM || ARCH_FOOTBRIDGE || ARCH_INTEGRATOR || ARCH_NETWINDER) && \
> - !ARM64 && !ARC && !MICROBLAZE && !OPENRISC && !S390 && !UML
> + depends on ALPHA || IA64 || X86 || \
> + (ARM && ARCH_FOOTBRIDGE) || \
> + (MIPS && (MIPS_MALTA || SIBYTE_BCM112X || SIBYTE_SB1250 || SIBYTE_BCM1x80 || SNI_RM))
> select APERTURE_HELPERS if (DRM || FB || VFIO_PCI_CORE)
> default y
> help
--
Thomas Zimmermann
Graphics Driver Developer
SUSE Software Solutions Germany GmbH
Frankenstrasse 146, 90461 Nuernberg, Germany
GF: Ivo Totev, Andrew Myers, Andrew McDonald, Boudien Moerman
HRB 36809 (AG Nuernberg)
[-- Attachment #1.2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 840 bytes --]
[-- Attachment #2: Type: text/plain, Size: 161 bytes --]
_______________________________________________
linux-riscv mailing list
linux-riscv@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-riscv
^ permalink raw reply [flat|nested] 11+ messages in thread
* Re: [PATCH 1/4] vgacon: rework Kconfig dependencies
2023-07-07 9:52 [PATCH 1/4] vgacon: rework Kconfig dependencies Arnd Bergmann
` (3 preceding siblings ...)
2023-08-01 16:55 ` Thomas Zimmermann
@ 2023-08-01 17:05 ` Russell King (Oracle)
2023-08-04 20:55 ` Arnd Bergmann
4 siblings, 1 reply; 11+ messages in thread
From: Russell King (Oracle) @ 2023-08-01 17:05 UTC (permalink / raw)
To: Arnd Bergmann
Cc: Thomas Zimmermann, javierm, linux-fbdev, linux-kernel, dri-devel,
Ard Biesheuvel, Helge Deller, Greg Kroah-Hartman, Arnd Bergmann,
Paul Walmsley, Palmer Dabbelt, Albert Ou, Guo Ren, linux-riscv,
linux-csky
On Fri, Jul 07, 2023 at 11:52:23AM +0200, Arnd Bergmann wrote:
> From: Arnd Bergmann <arnd@arndb.de>
>
> The list of dependencies here is phrased as an opt-out, but this is missing
> a lot of architectures that don't actually support VGA consoles, and some
> of the entries are stale:
>
> - powerpc used to support VGA consoles in the old arch/ppc codebase, but
> the merged arch/powerpc never did
>
> - arm lists footbridge, integrator and netwinder, but netwinder is actually
> part of footbridge, and integrator does not appear to have an actual
> VGA hardware, or list it in its ATAG or DT.
Integrator/AP has PCI, and I have had PCI VGA cards plugged in to that
hardware when I've had it.
Provided any platform sets up PCI in a compatible way, and can run the
VGA's BIOS to initialise the card, then vgacon is supportable.
--
RMK's Patch system: https://www.armlinux.org.uk/developer/patches/
FTTP is here! 80Mbps down 10Mbps up. Decent connectivity at last!
_______________________________________________
linux-riscv mailing list
linux-riscv@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-riscv
^ permalink raw reply [flat|nested] 11+ messages in thread
* Re: [PATCH 1/4] vgacon: rework Kconfig dependencies
2023-08-01 17:05 ` Russell King (Oracle)
@ 2023-08-04 20:55 ` Arnd Bergmann
0 siblings, 0 replies; 11+ messages in thread
From: Arnd Bergmann @ 2023-08-04 20:55 UTC (permalink / raw)
To: Russell King
Cc: Thomas Zimmermann, Javier Martinez Canillas, linux-fbdev,
linux-kernel, dri-devel, Ard Biesheuvel, Helge Deller,
Greg Kroah-Hartman, Arnd Bergmann, Paul Walmsley, Palmer Dabbelt,
Albert Ou, guoren, linux-riscv, linux-csky@vger.kernel.org
On Tue, Aug 1, 2023, at 19:05, Russell King (Oracle) wrote:
> On Fri, Jul 07, 2023 at 11:52:23AM +0200, Arnd Bergmann wrote:
>> From: Arnd Bergmann <arnd@arndb.de>
>>
>> The list of dependencies here is phrased as an opt-out, but this is missing
>> a lot of architectures that don't actually support VGA consoles, and some
>> of the entries are stale:
>>
>> - powerpc used to support VGA consoles in the old arch/ppc codebase, but
>> the merged arch/powerpc never did
>>
>> - arm lists footbridge, integrator and netwinder, but netwinder is actually
>> part of footbridge, and integrator does not appear to have an actual
>> VGA hardware, or list it in its ATAG or DT.
>
> Integrator/AP has PCI, and I have had PCI VGA cards plugged in to that
> hardware when I've had it.
I'm pretty sure it can no longer work and broke a while ago,
so I would prefer to leave it out unless someone actually has
a reason to use it and puts the work in to restore the support.
From what I can tell, it's broken in at least three ways with
the new PCI host driver:
- the PCI memory space is identity mapped to its CPU physical
address as of d3721efce22d1 ("ARM: dts: integratorap: Fix
PCI windows"), which is generally better for compatibility
with broken drivers that read the BAR directly, but it
prevents memory mapped ISA-style devices including VGA text
buffer.
- vga_base is no longer set by the new PCI host driver, so
any accesses to the text buffer just end up in user space
memory at (__iomem*)0xb8000
- there is no DT binding for setting the global screen_info
to whatever the boot firmware has initialized
the VGA BIOS to, and the default 80x30 on Arm does not match
the typical 80x25 text that would be set by the BIOS.
> Provided any platform sets up PCI in a compatible way, and can run the
> VGA's BIOS to initialise the card, then vgacon is supportable.
It looks like only footbridge does at this point, all the other
platforms would need to fix at least some of the three things I
mentioned above, in particular plat-orion is the only thing
setting vga_base but also has the identity map issue.
My impression is that nobody has cared about vgacon on most
Arm systems since it's harder to get working than fbcon with
a native PCI driver (or the built-in pl110 on integrator) but
also less useful.
Arnd
_______________________________________________
linux-riscv mailing list
linux-riscv@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-riscv
^ permalink raw reply [flat|nested] 11+ messages in thread
end of thread, other threads:[~2023-08-04 20:55 UTC | newest]
Thread overview: 11+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-07-07 9:52 [PATCH 1/4] vgacon: rework Kconfig dependencies Arnd Bergmann
2023-07-07 9:52 ` [PATCH 2/4] vgacon: rework screen_info #ifdef checks Arnd Bergmann
2023-07-07 13:40 ` Javier Martinez Canillas
2023-07-07 14:32 ` Arnd Bergmann
2023-07-07 15:27 ` Javier Martinez Canillas
2023-07-08 14:11 ` Thomas Bogendoerfer
2023-07-07 13:17 ` [PATCH 1/4] vgacon: rework Kconfig dependencies Javier Martinez Canillas
2023-07-07 15:07 ` Thomas Zimmermann
2023-08-01 16:55 ` Thomas Zimmermann
2023-08-01 17:05 ` Russell King (Oracle)
2023-08-04 20:55 ` Arnd Bergmann
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox