* [PATCH 00/03] fbdev: maxine: clean up build issues
@ 2026-08-13 23:29 Randy Dunlap
2026-08-13 23:29 ` [PATCH 01/03] fbdev: maxine: make functions static Randy Dunlap
` (3 more replies)
0 siblings, 4 replies; 5+ messages in thread
From: Randy Dunlap @ 2026-08-13 23:29 UTC (permalink / raw)
To: linux-kernel
Cc: Randy Dunlap, Helge Deller, linux-fbdev, dri-devel,
Maciej W. Rozycki
This is all ancient source code from the beginning of git time.
Now builds cleanly on 32-bit and 64-bit MACH_DECSTATION.
Subject: [PATCH 01/03] fbdev: maxine: make functions static
Subject: [PATCH 02/03] fbdev: maxine: elide an unused function
Subject: [PATCH 03/03] fbdev: maxine: fix 64-bit build error
drivers/video/fbdev/maxinefb.c | 9 ++++++---
include/video/maxinefb.h | 4 ++--
2 files changed, 8 insertions(+), 5 deletions(-)
Cc: Helge Deller <deller@gmx.de>
Cc: linux-fbdev@vger.kernel.org
Cc: dri-devel@lists.freedesktop.org
Cc: "Maciej W. Rozycki" <macro@orcam.me.uk>
^ permalink raw reply [flat|nested] 5+ messages in thread
* [PATCH 01/03] fbdev: maxine: make functions static
2026-08-13 23:29 [PATCH 00/03] fbdev: maxine: clean up build issues Randy Dunlap
@ 2026-08-13 23:29 ` Randy Dunlap
2026-08-13 23:29 ` [PATCH 02/03] fbdev: maxine: elide an unused function Randy Dunlap
` (2 subsequent siblings)
3 siblings, 0 replies; 5+ messages in thread
From: Randy Dunlap @ 2026-08-13 23:29 UTC (permalink / raw)
To: linux-kernel
Cc: Randy Dunlap, Helge Deller, linux-fbdev, dri-devel,
Maciej W. Rozycki
Make 3 functions static so that they don't need to be declared in a
header file.
../drivers/video/fbdev/maxinefb.c:64:6: warning: no previous prototype for 'maxinefb_ims332_write_register' [-Wmissing-prototypes]
64 | void maxinefb_ims332_write_register(int regno, register unsigned int val)
../drivers/video/fbdev/maxinefb.c:74:14: warning: no previous prototype for 'maxinefb_ims332_read_register' [-Wmissing-prototypes]
74 | unsigned int maxinefb_ims332_read_register(int regno)
../drivers/video/fbdev/maxinefb.c:114:12: warning: no previous prototype for 'maxinefb_init' [-Wmissing-prototypes]
114 | int __init maxinefb_init(void)
Signed-off-by: Randy Dunlap <rdunlap@infradead.org>
---
Cc: Helge Deller <deller@gmx.de>
Cc: linux-fbdev@vger.kernel.org
Cc: dri-devel@lists.freedesktop.org
Cc: "Maciej W. Rozycki" <macro@orcam.me.uk>
drivers/video/fbdev/maxinefb.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
--- linux-next-20260812.orig/drivers/video/fbdev/maxinefb.c
+++ linux-next-20260812/drivers/video/fbdev/maxinefb.c
@@ -61,7 +61,7 @@ static struct fb_fix_screeninfo maxinefb
/* Handle the funny Inmos RamDAC/video controller ... */
-void maxinefb_ims332_write_register(int regno, register unsigned int val)
+static void maxinefb_ims332_write_register(int regno, register unsigned int val)
{
register unsigned char *regs = (char *) MAXINEFB_IMS332_ADDRESS;
unsigned char *wptr;
@@ -71,7 +71,7 @@ void maxinefb_ims332_write_register(int
*((volatile unsigned short *) (wptr)) = val;
}
-unsigned int maxinefb_ims332_read_register(int regno)
+static unsigned int maxinefb_ims332_read_register(int regno)
{
register unsigned char *regs = (char *) MAXINEFB_IMS332_ADDRESS;
unsigned char *rptr;
@@ -111,7 +111,7 @@ static const struct fb_ops maxinefb_ops
.fb_setcolreg = maxinefb_setcolreg,
};
-int __init maxinefb_init(void)
+static int __init maxinefb_init(void)
{
unsigned long fboff;
unsigned long fb_start;
^ permalink raw reply [flat|nested] 5+ messages in thread
* [PATCH 02/03] fbdev: maxine: elide an unused function
2026-08-13 23:29 [PATCH 00/03] fbdev: maxine: clean up build issues Randy Dunlap
2026-08-13 23:29 ` [PATCH 01/03] fbdev: maxine: make functions static Randy Dunlap
@ 2026-08-13 23:29 ` Randy Dunlap
2026-08-13 23:29 ` [PATCH 03/03] fbdev: maxine: fix 64-bit build error Randy Dunlap
2026-08-14 7:39 ` [PATCH 00/03] fbdev: maxine: clean up build issues Helge Deller
3 siblings, 0 replies; 5+ messages in thread
From: Randy Dunlap @ 2026-08-13 23:29 UTC (permalink / raw)
To: linux-kernel
Cc: Randy Dunlap, Helge Deller, linux-fbdev, dri-devel,
Maciej W. Rozycki
maxinefb_ims332_read_register() is not used, but since it describes a
hardware interface, leave it in the source file as documentation
and surround it inside an #if 0/#endif block.
../drivers/video/fbdev/maxinefb.c:74:21: warning: 'maxinefb_ims332_read_register' defined but not used [-Wunused-function]
74 | static unsigned int maxinefb_ims332_read_register(int regno)
Signed-off-by: Randy Dunlap <rdunlap@infradead.org>
---
Cc: Helge Deller <deller@gmx.de>
Cc: linux-fbdev@vger.kernel.org
Cc: dri-devel@lists.freedesktop.org
Cc: "Maciej W. Rozycki" <macro@orcam.me.uk>
drivers/video/fbdev/maxinefb.c | 3 +++
1 file changed, 3 insertions(+)
--- linux-next-20260812.orig/drivers/video/fbdev/maxinefb.c
+++ linux-next-20260812/drivers/video/fbdev/maxinefb.c
@@ -71,6 +71,8 @@ static void maxinefb_ims332_write_regist
*((volatile unsigned short *) (wptr)) = val;
}
+#if 0
+/* dead code: leave here for hardware interface documentation */
static unsigned int maxinefb_ims332_read_register(int regno)
{
register unsigned char *regs = (char *) MAXINEFB_IMS332_ADDRESS;
@@ -83,6 +85,7 @@ static unsigned int maxinefb_ims332_read
return (j & 0xffff) | ((k & 0xff00) << 8);
}
+#endif
/* Set the palette */
static int maxinefb_setcolreg(unsigned regno, unsigned red, unsigned green,
^ permalink raw reply [flat|nested] 5+ messages in thread
* [PATCH 03/03] fbdev: maxine: fix 64-bit build error
2026-08-13 23:29 [PATCH 00/03] fbdev: maxine: clean up build issues Randy Dunlap
2026-08-13 23:29 ` [PATCH 01/03] fbdev: maxine: make functions static Randy Dunlap
2026-08-13 23:29 ` [PATCH 02/03] fbdev: maxine: elide an unused function Randy Dunlap
@ 2026-08-13 23:29 ` Randy Dunlap
2026-08-14 7:39 ` [PATCH 00/03] fbdev: maxine: clean up build issues Helge Deller
3 siblings, 0 replies; 5+ messages in thread
From: Randy Dunlap @ 2026-08-13 23:29 UTC (permalink / raw)
To: linux-kernel
Cc: Randy Dunlap, Helge Deller, linux-fbdev, dri-devel,
Maciej W. Rozycki
The KSEG1ADDR() macro is only defined for non-64BIT builds.
Use the CKSEG1ADDR() macro instead.
In file included from ../drivers/video/fbdev/maxinefb.c:34:
../drivers/video/fbdev/maxinefb.c: In function 'maxinefb_ims332_write_register':
../include/video/maxinefb.h:16:41: error: implicit declaration of function 'KSEG1ADDR'; did you mean 'CKSEG1ADDR'? [-Wimplicit-function-declaration]
16 | #define MAXINEFB_IMS332_ADDRESS KSEG1ADDR(0x1c140000)
../drivers/video/fbdev/maxinefb.c:66:49: note: in expansion of macro 'MAXINEFB_IMS332_ADDRESS'
66 | register unsigned char *regs = (char *) MAXINEFB_IMS332_ADDRESS;
../drivers/video/fbdev/maxinefb.c:66:40: warning: cast to pointer from integer of different size [-Wint-to-pointer-cast]
66 | register unsigned char *regs = (char *) MAXINEFB_IMS332_ADDRESS;
Signed-off-by: Randy Dunlap <rdunlap@infradead.org>
---
Cc: Helge Deller <deller@gmx.de>
Cc: linux-fbdev@vger.kernel.org
Cc: dri-devel@lists.freedesktop.org
Cc: "Maciej W. Rozycki" <macro@orcam.me.uk>
include/video/maxinefb.h | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
--- linux-next-20260812.orig/include/video/maxinefb.h
+++ linux-next-20260812/include/video/maxinefb.h
@@ -13,13 +13,13 @@
/*
* IMS332 video controller register base address
*/
-#define MAXINEFB_IMS332_ADDRESS KSEG1ADDR(0x1c140000)
+#define MAXINEFB_IMS332_ADDRESS CKSEG1ADDR(0x1c140000)
/*
* Begin of DECstation 5000/xx onboard framebuffer memory, default resolution
* is 1024x768x8
*/
-#define DS5000_xx_ONBOARD_FBMEM_START KSEG1ADDR(0x0a000000)
+#define DS5000_xx_ONBOARD_FBMEM_START CKSEG1ADDR(0x0a000000)
/*
* The IMS 332 video controller used in the DECstation 5000/xx series
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH 00/03] fbdev: maxine: clean up build issues
2026-08-13 23:29 [PATCH 00/03] fbdev: maxine: clean up build issues Randy Dunlap
` (2 preceding siblings ...)
2026-08-13 23:29 ` [PATCH 03/03] fbdev: maxine: fix 64-bit build error Randy Dunlap
@ 2026-08-14 7:39 ` Helge Deller
3 siblings, 0 replies; 5+ messages in thread
From: Helge Deller @ 2026-08-14 7:39 UTC (permalink / raw)
To: Randy Dunlap, linux-kernel; +Cc: linux-fbdev, dri-devel, Maciej W. Rozycki
On 8/14/26 01:29, Randy Dunlap wrote:
> This is all ancient source code from the beginning of git time.
> Now builds cleanly on 32-bit and 64-bit MACH_DECSTATION.
>
>
> Subject: [PATCH 01/03] fbdev: maxine: make functions static
> Subject: [PATCH 02/03] fbdev: maxine: elide an unused function
> Subject: [PATCH 03/03] fbdev: maxine: fix 64-bit build error
>
> drivers/video/fbdev/maxinefb.c | 9 ++++++---
> include/video/maxinefb.h | 4 ++--
> 2 files changed, 8 insertions(+), 5 deletions(-)
Thanks Randy!
I've applied all patches (including #4).
I'll add upcoming Reviewed-by/Acked-by tags too.
Helge
> Cc: Helge Deller <deller@gmx.de>
> Cc: linux-fbdev@vger.kernel.org
> Cc: dri-devel@lists.freedesktop.org
> Cc: "Maciej W. Rozycki" <macro@orcam.me.uk>
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2026-08-14 7:39 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-08-13 23:29 [PATCH 00/03] fbdev: maxine: clean up build issues Randy Dunlap
2026-08-13 23:29 ` [PATCH 01/03] fbdev: maxine: make functions static Randy Dunlap
2026-08-13 23:29 ` [PATCH 02/03] fbdev: maxine: elide an unused function Randy Dunlap
2026-08-13 23:29 ` [PATCH 03/03] fbdev: maxine: fix 64-bit build error Randy Dunlap
2026-08-14 7:39 ` [PATCH 00/03] fbdev: maxine: clean up build issues Helge Deller
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox