Skip to content

Commit 319f829

Browse files
fbdev: FBIOGET_FSCREENINFO + FBIOPUT_VSCREENINFO
Signed-off-by: Andy-Python-Programmer <[email protected]>
1 parent 04d6cac commit 319f829

File tree

7 files changed

+409
-10
lines changed

7 files changed

+409
-10
lines changed

bootstrap/xorg.yml

Lines changed: 135 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1210,3 +1210,138 @@ packages:
12101210
- args: ['make', 'install']
12111211
environ:
12121212
DESTDIR: '@THIS_COLLECT_DIR@'
1213+
1214+
- name: libxv
1215+
source:
1216+
subdir: 'bundled'
1217+
git: 'https://gitlab.freedesktop.org/xorg/lib/libxv.git'
1218+
tag: 'libXv-1.0.11'
1219+
version: '1.0.11'
1220+
tools_required:
1221+
- host-autoconf-v2.69
1222+
- host-automake-v1.16
1223+
- host-libtool
1224+
- host-pkg-config
1225+
- host-xorg-macros
1226+
regenerate:
1227+
- args: ['./autogen.sh']
1228+
environ:
1229+
NOCONFIGURE: 'yes'
1230+
tools_required:
1231+
- host-gcc
1232+
- host-autoconf-v2.69
1233+
- host-automake-v1.16
1234+
- host-pkg-config
1235+
pkgs_required:
1236+
- mlibc
1237+
- xorg-util-macros
1238+
- xorg-proto
1239+
- libx11
1240+
- libxext
1241+
- libxfixes
1242+
configure:
1243+
- args:
1244+
- '@THIS_SOURCE_DIR@/configure'
1245+
- '--host=x86_64-aero'
1246+
- '--prefix=/usr'
1247+
- '--sysconfdir=/etc'
1248+
- '--localstatedir=/var'
1249+
- '--disable-static'
1250+
- '--disable-malloc0returnsnull'
1251+
- '--with-sysroot=@SYSROOT_DIR@' # Set libtool's lt_sysroot.
1252+
build:
1253+
- args: ['make', '-j@PARALLELISM@']
1254+
- args: ['make', 'install-strip']
1255+
environ:
1256+
DESTDIR: '@THIS_COLLECT_DIR@'
1257+
1258+
- name: libxrandr
1259+
source:
1260+
subdir: 'bundled'
1261+
git: 'https://gitlab.freedesktop.org/xorg/lib/libxrandr.git'
1262+
tag: 'libXrandr-1.5.2'
1263+
version: '1.5.2'
1264+
tools_required:
1265+
- host-autoconf-v2.69
1266+
- host-automake-v1.16
1267+
- host-libtool
1268+
- host-pkg-config
1269+
- host-xorg-macros
1270+
regenerate:
1271+
- args: ['./autogen.sh']
1272+
environ:
1273+
NOCONFIGURE: 'yes'
1274+
tools_required:
1275+
- host-gcc
1276+
- host-autoconf-v2.69
1277+
- host-automake-v1.16
1278+
- host-pkg-config
1279+
pkgs_required:
1280+
- mlibc
1281+
- xorg-util-macros
1282+
- xorg-proto
1283+
- libx11
1284+
- libxtrans
1285+
- libxrender
1286+
- libxext
1287+
configure:
1288+
- args:
1289+
- '@THIS_SOURCE_DIR@/configure'
1290+
- '--host=x86_64-aero'
1291+
- '--prefix=/usr'
1292+
- '--sysconfdir=/etc'
1293+
- '--localstatedir=/var'
1294+
- '--disable-static'
1295+
- '--disable-malloc0returnsnull'
1296+
build:
1297+
- args: ['make', '-j@PARALLELISM@']
1298+
- args: ['make', 'install-strip']
1299+
environ:
1300+
DESTDIR: '@THIS_COLLECT_DIR@'
1301+
1302+
- name: xf86-video-fbdev
1303+
source:
1304+
subdir: 'bundled'
1305+
git: 'https://gitlab.freedesktop.org/xorg/driver/xf86-video-fbdev.git'
1306+
tag: 'xf86-video-fbdev-0.5.0'
1307+
version: '0.5.0'
1308+
tools_required:
1309+
- host-autoconf-v2.69
1310+
- host-automake-v1.16
1311+
- host-libtool
1312+
- host-pkg-config
1313+
- host-xorg-macros
1314+
regenerate:
1315+
- args: ['./autogen.sh']
1316+
environ:
1317+
NOCONFIGURE: 'yes'
1318+
tools_required:
1319+
- host-gcc
1320+
- host-autoconf-v2.69
1321+
- host-automake-v1.16
1322+
- host-pkg-config
1323+
pkgs_required:
1324+
- mlibc
1325+
- xorg-server
1326+
- xorg-util-macros
1327+
- libx11
1328+
- libxrandr
1329+
- libxrender
1330+
- libxv
1331+
configure:
1332+
- args:
1333+
- '@THIS_SOURCE_DIR@/configure'
1334+
- '--host=x86_64-aero'
1335+
- '--prefix=/usr'
1336+
- '--sysconfdir=/etc'
1337+
- '--localstatedir=/var'
1338+
- '--disable-static'
1339+
- '--with-sysroot=@SYSROOT_DIR@' # Set libtool's lt_sysroot.
1340+
- '--disable-pciaccess'
1341+
environ:
1342+
SYSROOT: '@SYSROOT_DIR@'
1343+
build:
1344+
- args: ['make', '-j@PARALLELISM@']
1345+
- args: ['make', 'install-strip']
1346+
environ:
1347+
DESTDIR: '@THIS_COLLECT_DIR@'
Lines changed: 112 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,112 @@
1+
From 4a125d73f79cffc1edb41c4a9e9c0524bbc0abbd Mon Sep 17 00:00:00 2001
2+
From: Andy-Python-Programmer <[email protected]>
3+
Date: Sat, 2 Jul 2022 18:40:03 +1000
4+
Subject: [PATCH] fbdev: aero specific changes
5+
6+
Signed-off-by: Andy-Python-Programmer <[email protected]>
7+
---
8+
.gitignore | 2 ++
9+
configure.ac | 8 +++++---
10+
src/Makefile.am | 2 +-
11+
src/fbdev.c | 8 +++++---
12+
4 files changed, 13 insertions(+), 7 deletions(-)
13+
14+
diff --git a/.gitignore b/.gitignore
15+
index 1c9de22..69be940 100644
16+
--- a/.gitignore
17+
+++ b/.gitignore
18+
@@ -76,3 +76,5 @@ core
19+
# Edit the following section as needed
20+
# For example, !report.pc overrides *.pc. See 'man gitignore'
21+
#
22+
+# editor configs:
23+
+.vscode
24+
diff --git a/configure.ac b/configure.ac
25+
index 27778cd..11f5e38 100644
26+
--- a/configure.ac
27+
+++ b/configure.ac
28+
@@ -56,9 +56,9 @@ AC_ARG_ENABLE(pciaccess, AS_HELP_STRING([--enable-pciaccess],
29+
[PCIACCESS=$enableval], [PCIACCESS=no])
30+
31+
# Store the list of server defined optional extensions in REQUIRED_MODULES
32+
-XORG_DRIVER_CHECK_EXT(RANDR, randrproto)
33+
-XORG_DRIVER_CHECK_EXT(RENDER, renderproto)
34+
-XORG_DRIVER_CHECK_EXT(XV, videoproto)
35+
+# XORG_DRIVER_CHECK_EXT(RANDR, randrproto)
36+
+# XORG_DRIVER_CHECK_EXT(RENDER, renderproto)
37+
+# XORG_DRIVER_CHECK_EXT(XV, videoproto)
38+
39+
# Obtain compiler/linker options for the driver dependencies
40+
PKG_CHECK_MODULES(XORG, [xorg-server >= 1.0.99.901 xproto fontsproto $REQUIRED_MODULES])
41+
@@ -86,6 +86,8 @@ AC_SUBST([moduledir])
42+
DRIVER_NAME=fbdev
43+
AC_SUBST([DRIVER_NAME])
44+
45+
+AC_SUBST([SYSROOT])
46+
+
47+
AC_CONFIG_FILES([
48+
Makefile
49+
src/Makefile
50+
diff --git a/src/Makefile.am b/src/Makefile.am
51+
index fbe420e..6e0779c 100644
52+
--- a/src/Makefile.am
53+
+++ b/src/Makefile.am
54+
@@ -25,7 +25,7 @@
55+
# TODO: -nostdlib/-Bstatic/-lgcc platform magic, not installing the .a, etc.
56+
AM_CFLAGS = @XORG_CFLAGS@
57+
fbdev_drv_la_LTLIBRARIES = fbdev_drv.la
58+
-fbdev_drv_la_LDFLAGS = -module -avoid-version
59+
+fbdev_drv_la_LDFLAGS = -module -avoid-version -R@moduledir@ -L@SYSROOT@@moduledir@ -lfb -lfbdevhw -lshadow
60+
fbdev_drv_ladir = @moduledir@/drivers
61+
62+
fbdev_drv_la_SOURCES = \
63+
diff --git a/src/fbdev.c b/src/fbdev.c
64+
index f25ef72..7facb9f 100644
65+
--- a/src/fbdev.c
66+
+++ b/src/fbdev.c
67+
@@ -339,7 +339,7 @@ FBDevProbe(DriverPtr drv, int flags)
68+
69+
dev = xf86FindOptionValue(devSections[i]->options,"fbdev");
70+
if (devSections[i]->busID) {
71+
-#ifndef XSERVER_LIBPCIACCESS
72+
+#ifdef XSERVER_LIBPCIACCESS
73+
if (xf86ParsePciBusString(devSections[i]->busID,&bus,&device,
74+
&func)) {
75+
if (!xf86CheckPciSlot(bus,device,func))
76+
@@ -358,7 +358,7 @@ FBDevProbe(DriverPtr drv, int flags)
77+
if (fbdevHWProbe(NULL,dev,NULL)) {
78+
pScrn = NULL;
79+
if (isPci) {
80+
-#ifndef XSERVER_LIBPCIACCESS
81+
+#ifdef XSERVER_LIBPCIACCESS
82+
/* XXX what about when there's no busID set? */
83+
int entity;
84+
85+
@@ -444,6 +444,7 @@ FBDevPreInit(ScrnInfoPtr pScrn, int flags)
86+
fPtr->pEnt = xf86GetEntityInfo(pScrn->entityList[0]);
87+
88+
#ifndef XSERVER_LIBPCIACCESS
89+
+#if 0
90+
pScrn->racMemFlags = RAC_FB | RAC_COLORMAP | RAC_CURSOR | RAC_VIEWPORT;
91+
/* XXX Is this right? Can probably remove RAC_FB */
92+
pScrn->racIoFlags = RAC_FB | RAC_COLORMAP | RAC_CURSOR | RAC_VIEWPORT;
93+
@@ -454,6 +455,7 @@ FBDevPreInit(ScrnInfoPtr pScrn, int flags)
94+
"xf86RegisterResources() found resource conflicts\n");
95+
return FALSE;
96+
}
97+
+#endif
98+
#else
99+
if (fPtr->pEnt->location.type == BUS_PCI)
100+
pci_dev = fPtr->pEnt->location.id.pci;
101+
@@ -1010,7 +1012,7 @@ FBDevScreenInit(SCREEN_INIT_ARGS_DECL)
102+
fPtr->CloseScreen = pScreen->CloseScreen;
103+
pScreen->CloseScreen = FBDevCloseScreen;
104+
105+
-#if XV
106+
+#ifdef XV
107+
{
108+
XF86VideoAdaptorPtr *ptr;
109+
110+
--
111+
2.25.1
112+

patches/xorg-server/0001-xserver-aero-specific-changes.patch

Lines changed: 23 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
From 58219693860f53ac12dd1849e5457bf30126a8ce Mon Sep 17 00:00:00 2001
1+
From ec91d28586ecf3df66e23da1ce94dbba3042cd86 Mon Sep 17 00:00:00 2001
22
From: Andy-Python-Programmer <[email protected]>
33
Date: Thu, 30 Jun 2022 11:10:21 +1000
44
Subject: [PATCH] xserver: aero specific changes
@@ -7,6 +7,7 @@ Signed-off-by: Andy-Python-Programmer <[email protected]>
77
---
88
.gitignore | 2 ++
99
configure.ac | 2 ++
10+
hw/xfree86/common/xf86Bus.c | 2 ++
1011
hw/xfree86/common/xf86Config.c | 2 ++
1112
hw/xfree86/common/xf86Configure.c | 1 +
1213
hw/xfree86/common/xf86Events.c | 1 +
@@ -20,7 +21,7 @@ Signed-off-by: Andy-Python-Programmer <[email protected]>
2021
mi/mibitblt.c | 2 ++
2122
os/access.c | 2 +-
2223
os/utils.c | 4 +--
23-
15 files changed, 47 insertions(+), 19 deletions(-)
24+
16 files changed, 49 insertions(+), 19 deletions(-)
2425

2526
diff --git a/.gitignore b/.gitignore
2627
index dc56b46..81d9886 100644
@@ -45,6 +46,26 @@ index 0909cc5..080b906 100644
4546
AC_SUBST([XORG_LIBS])
4647
AC_SUBST([XORG_SYS_LIBS])
4748
AC_SUBST([XORG_INCS])
49+
diff --git a/hw/xfree86/common/xf86Bus.c b/hw/xfree86/common/xf86Bus.c
50+
index a8f1073..d7399aa 100644
51+
--- a/hw/xfree86/common/xf86Bus.c
52+
+++ b/hw/xfree86/common/xf86Bus.c
53+
@@ -536,6 +536,7 @@ xf86GetDevFromEntity(int entityIndex, int instance)
54+
void
55+
xf86PostProbe(void)
56+
{
57+
+#if 0
58+
if (fbSlotClaimed && (
59+
#if (defined(__sparc__) || defined(__sparc)) && !defined(__OpenBSD__)
60+
sbusSlotClaimed ||
61+
@@ -551,6 +552,7 @@ xf86PostProbe(void)
62+
))
63+
FatalError("Cannot run in framebuffer mode. Please specify busIDs "
64+
" for all framebuffer devices\n");
65+
+#endif
66+
}
67+
68+
int
4869
diff --git a/hw/xfree86/common/xf86Config.c b/hw/xfree86/common/xf86Config.c
4970
index 09d27ec..83be062 100644
5071
--- a/hw/xfree86/common/xf86Config.c

0 commit comments

Comments
 (0)