From 0d4a710fa0e4e7093c906077849f0158649a3ecf Mon Sep 17 00:00:00 2001 From: Hans de Goede Date: Sep 29 2016 09:26:56 +0000 Subject: Git snapshot du-jour - Add patches from upstream master for building with 1.19 which the endless fork we use misses - Rebuild against xserver-1.19 --- diff --git a/.gitignore b/.gitignore index affced6..92b893e 100644 --- a/.gitignore +++ b/.gitignore @@ -4,3 +4,4 @@ /xf86-video-armsoc-20150212.tar.bz2 /xf86-video-armsoc-20150531.tar.bz2 /xf86-video-armsoc-20151221.tar.bz2 +/xf86-video-armsoc-20160929.tar.bz2 diff --git a/sources b/sources index 47eb308..7edd739 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -3c615cd7484c729fa74ad4642cbe6897 xf86-video-armsoc-20151221.tar.bz2 +1be2252eb989e47b7963b23eb0182efa xf86-video-armsoc-20160929.tar.bz2 diff --git a/xf86-video-armsoc-endless-1.19-support.patch b/xf86-video-armsoc-endless-1.19-support.patch new file mode 100644 index 0000000..d3d444b --- /dev/null +++ b/xf86-video-armsoc-endless-1.19-support.patch @@ -0,0 +1,134 @@ +From a97ceb3bac8bcf53bf4ea3db0a2c8921d8017ef8 Mon Sep 17 00:00:00 2001 +From: Adam Jackson +Date: Tue, 19 Jul 2016 10:21:03 -0400 +Subject: [PATCH 1/2] Adapt Block/WakeupHandler signature for ABI 23 + +Signed-off-by: Adam Jackson +--- + src/compat-api.h | 6 ++++++ + 1 file changed, 6 insertions(+) + +diff --git a/src/compat-api.h b/src/compat-api.h +index fefbc59..78d3c91 100644 +--- a/src/compat-api.h ++++ b/src/compat-api.h +@@ -77,9 +77,15 @@ + + #define SCREEN_INIT_ARGS_DECL ScreenPtr pScreen, int argc, char **argv + ++#if ABI_VIDEODRV_VERSION >= SET_ABI_VERSION(23, 0) ++#define BLOCKHANDLER_ARGS_DECL \ ++ ScreenPtr arg, pointer pTimeout ++#define BLOCKHANDLER_ARGS arg, pTimeout ++#else + #define BLOCKHANDLER_ARGS_DECL \ + ScreenPtr arg, pointer pTimeout, pointer pReadmask + #define BLOCKHANDLER_ARGS arg, pTimeout, pReadmask ++#endif + + #define CLOSE_SCREEN_ARGS_DECL ScreenPtr pScreen + #define CLOSE_SCREEN_ARGS pScreen +-- +2.9.3 + +From 787c57c915e3a66dc10f525e0a05c7af35262c7d Mon Sep 17 00:00:00 2001 +From: Keith Packard +Date: Tue, 19 Jul 2016 08:51:12 -0700 +Subject: [PATCH 2/2] Use NotifyFd for drm fd + +NotifyFd is available after API 22, and must be used after API 23. + +Signed-off-by: Keith Packard +--- + src/compat-api.h | 5 +++++ + src/drmmode_display.c | 24 ++++++++++++++++++++++++ + 2 files changed, 29 insertions(+) + +diff --git a/src/compat-api.h b/src/compat-api.h +index 78d3c91..54f9f64 100644 +--- a/src/compat-api.h ++++ b/src/compat-api.h +@@ -77,7 +77,12 @@ + + #define SCREEN_INIT_ARGS_DECL ScreenPtr pScreen, int argc, char **argv + ++#if ABI_VIDEODRV_VERSION >= SET_ABI_VERSION(22,0) ++#define HAVE_NOTIFY_FD 1 ++#endif ++ + #if ABI_VIDEODRV_VERSION >= SET_ABI_VERSION(23, 0) ++#define RELOAD_CURSORS_DEPRECATED 1 + #define BLOCKHANDLER_ARGS_DECL \ + ScreenPtr arg, pointer pTimeout + #define BLOCKHANDLER_ARGS arg, pTimeout +diff --git a/src/drmmode_display.c b/src/drmmode_display.c +index 73c257a..33019a1 100644 +--- a/src/drmmode_display.c ++++ b/src/drmmode_display.c +@@ -450,9 +450,11 @@ done_setting: + drmmode_output_dpms(output, DPMSModeOn); + } + ++#if !RELOAD_CURSORS_DEPRECATED + /* if hw cursor is initialized, reload it */ + if (drmmode->cursor) + xf86_reload_cursors(pScrn->pScreen); ++#endif + + cleanup: + if (newcrtc) +@@ -2038,6 +2040,13 @@ drmmode_uevent_fini(ScrnInfoPtr pScrn) + TRACE_EXIT(); + } + ++#if HAVE_NOTIFY_FD ++static void ++drmmode_notify_fd(int fd, int notify, void *data) ++{ ++ drmHandleEvent(fd, &event_context); ++} ++#else + static void + drmmode_wakeup_handler(pointer data, int err, pointer p) + { +@@ -2053,6 +2062,7 @@ drmmode_wakeup_handler(pointer data, int err, pointer p) + if (FD_ISSET(drmmode->fd, read_mask)) + drmHandleEvent(drmmode->fd, &event_context); + } ++#endif + + void + drmmode_wait_for_event(ScrnInfoPtr pScrn) +@@ -2068,15 +2078,29 @@ drmmode_screen_init(ScrnInfoPtr pScrn) + + drmmode_uevent_init(pScrn); + ++#if HAVE_NOTIFY_FD ++ SetNotifyFd(drmmode->fd, drmmode_notify_fd, X_NOTIFY_READ, NULL); ++#else + AddGeneralSocket(drmmode->fd); + + /* Register a wakeup handler to get informed on DRM events */ + RegisterBlockAndWakeupHandlers((BlockHandlerProcPtr)NoopDDA, + drmmode_wakeup_handler, pScrn); ++#endif + } + + void + drmmode_screen_fini(ScrnInfoPtr pScrn) + { ++ struct drmmode_rec *drmmode = drmmode_from_scrn(pScrn); ++ ++#if HAVE_NOTIFY_FD ++ RemoveNotifyFd(drmmode->fd); ++#else ++ RemoveBlockAndWakeupHandlers((BlockHandlerProcPtr)NoopDDA, ++ drmmode_wakeup_handler, pScrn); ++ RemoveGeneralSocket(drmmode->fd); ++#endif ++ + drmmode_uevent_fini(pScrn); + } +-- +2.9.3 + diff --git a/xorg-x11-drv-armsoc.spec b/xorg-x11-drv-armsoc.spec index 892b5a3..1833dc0 100644 --- a/xorg-x11-drv-armsoc.spec +++ b/xorg-x11-drv-armsoc.spec @@ -1,6 +1,6 @@ %define moduledir %(pkg-config xorg-server --variable=moduledir ) %define driverdir %{moduledir}/drivers -%define gitdate 20151221 +%define gitdate 20160929 %define gitrev .%{gitdate} %undefine _hardened_build @@ -8,7 +8,7 @@ Summary: Xorg X11 armsocdrm driver Name: xorg-x11-drv-armsoc Version: 1.4.0 -Release: 2%{?gitrev}%{?dist} +Release: 3%{?gitrev}%{?dist} URL: http://cgit.freedesktop.org/xorg/driver/xf86-video-armsoc License: MIT Group: User Interface/X Hardware Support @@ -16,6 +16,7 @@ Group: User Interface/X Hardware Support Source0: xf86-video-armsoc-%{gitdate}.tar.bz2 Source2: make-git-snapshot.sh Patch0: stat-inc.patch +Patch1: xf86-video-armsoc-endless-1.19-support.patch ExclusiveArch: %{arm} aarch64 @@ -49,6 +50,7 @@ Exynos 4/5 series ARM devices. %setup -q -n xf86-video-armsoc-%{?gitdate:%{gitdate}}%{!?gitdate:%{dirsuffix}} touch AUTHORS %patch0 -p1 +%patch1 -p1 %build %{?gitdate:autoreconf -v --install} @@ -69,6 +71,12 @@ find $RPM_BUILD_ROOT -regex ".*\.la$" | xargs rm -f -- %{_mandir}/man4/armsoc.4* %changelog +* Thu Sep 29 2016 Hans de Goede - 1.4.0-3.20160929 +- Git snapshot du-jour +- Add patches from upstream master for building with 1.19 which the endless + fork we use misses +- Rebuild against xserver-1.19 + * Fri Feb 05 2016 Fedora Release Engineering - 1.4.0-2.20151221 - Rebuilt for https://fedoraproject.org/wiki/Fedora_24_Mass_Rebuild