From 923da4d56992b35c64c9fc87201785c95305f548 Mon Sep 17 00:00:00 2001 From: "Enrico Weigelt, metux IT consult" Date: Fri, 15 Mar 2024 17:18:07 +0100 Subject: [PATCH] xfree86: os-support: unexport DEV_MEM defines DEV_MEM define isn't used by any drivers, and BSD seems to be the only one left using that define (Linux uses the symbol, but defines on its own) Therefore, just define it where actually used and drop it from the global xf86OSlib.h file. Signed-off-by: Enrico Weigelt, metux IT consult Part-of: --- hw/xfree86/os-support/bsd/alpha_video.c | 2 ++ hw/xfree86/os-support/bsd/arm_video.c | 2 ++ hw/xfree86/os-support/bsd/i386_video.c | 2 ++ hw/xfree86/os-support/xf86_OSlib.h | 4 ---- 4 files changed, 6 insertions(+), 4 deletions(-) diff --git a/hw/xfree86/os-support/bsd/alpha_video.c b/hw/xfree86/os-support/bsd/alpha_video.c index 279391e42..3d1d92467 100644 --- a/hw/xfree86/os-support/bsd/alpha_video.c +++ b/hw/xfree86/os-support/bsd/alpha_video.c @@ -42,6 +42,8 @@ #include "xf86_os_support.h" #include "xf86_OSlib.h" +#define DEV_MEM "/dev/mem" + #if defined(__NetBSD__) && !defined(MAP_FILE) #define MAP_FLAGS MAP_SHARED #else diff --git a/hw/xfree86/os-support/bsd/arm_video.c b/hw/xfree86/os-support/bsd/arm_video.c index 15b12a86f..b3da3b2ba 100644 --- a/hw/xfree86/os-support/bsd/arm_video.c +++ b/hw/xfree86/os-support/bsd/arm_video.c @@ -70,6 +70,8 @@ #include "xf86_OSlib.h" #include "compiler.h" +#define DEV_MEM "/dev/mem" + #if defined(__NetBSD__) && !defined(MAP_FILE) #define MAP_FLAGS MAP_SHARED #else diff --git a/hw/xfree86/os-support/bsd/i386_video.c b/hw/xfree86/os-support/bsd/i386_video.c index 607e4ca2b..ef64a61ed 100644 --- a/hw/xfree86/os-support/bsd/i386_video.c +++ b/hw/xfree86/os-support/bsd/i386_video.c @@ -40,6 +40,8 @@ #include #endif +#define DEV_MEM "/dev/mem" + #if defined(__NetBSD__) && !defined(MAP_FILE) #define MAP_FLAGS MAP_SHARED #else diff --git a/hw/xfree86/os-support/xf86_OSlib.h b/hw/xfree86/os-support/xf86_OSlib.h index f973ace86..582d5a9d8 100644 --- a/hw/xfree86/os-support/xf86_OSlib.h +++ b/hw/xfree86/os-support/xf86_OSlib.h @@ -230,10 +230,6 @@ struct pcvtid { #include -#ifndef DEV_MEM -#define DEV_MEM "/dev/mem" -#endif - #ifndef MAP_FAILED #define MAP_FAILED ((void *)-1) #endif