From patchwork Tue Dec 2 09:59:06 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?b?SsOpcsO0bWUgUG91aWxsZXI=?= X-Patchwork-Id: 416783 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from silver.osuosl.org (silver.osuosl.org [140.211.166.136]) by ozlabs.org (Postfix) with ESMTP id BEBD614009B for ; Tue, 2 Dec 2014 20:59:56 +1100 (AEDT) Received: from localhost (localhost [127.0.0.1]) by silver.osuosl.org (Postfix) with ESMTP id 124D333BEF; Tue, 2 Dec 2014 09:59:56 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from silver.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id U01hS5BEGODW; Tue, 2 Dec 2014 09:59:52 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by silver.osuosl.org (Postfix) with ESMTP id 12E7C33BF0; Tue, 2 Dec 2014 09:59:32 +0000 (UTC) X-Original-To: buildroot@lists.busybox.net Delivered-To: buildroot@osuosl.org Received: from whitealder.osuosl.org (whitealder.osuosl.org [140.211.166.138]) by ash.osuosl.org (Postfix) with ESMTP id 101181C2D4A for ; Tue, 2 Dec 2014 09:59:20 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by whitealder.osuosl.org (Postfix) with ESMTP id 0B82A91C47 for ; Tue, 2 Dec 2014 09:59:20 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from whitealder.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id GWq3b5JeNpyE for ; Tue, 2 Dec 2014 09:59:19 +0000 (UTC) X-Greylist: from auto-whitelisted by SQLgrey-1.7.6 Received: from lupi.sysmic.org (sysmic.org [62.210.89.17]) by whitealder.osuosl.org (Postfix) with ESMTPS id 4810291BDB for ; Tue, 2 Dec 2014 09:59:19 +0000 (UTC) Received: from lupi.online.net (sysmic.org [62.210.89.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-SHA256 (128/128 bits)) (No client certificate requested) (Authenticated sender: jezz) by lupi.sysmic.org (Postfix) with ESMTPSA id B2C4043413; Tue, 2 Dec 2014 10:59:16 +0100 (CET) From: =?UTF-8?q?J=C3=A9r=C3=B4me=20Pouiller?= To: buildroot@busybox.net Date: Tue, 2 Dec 2014 10:59:06 +0100 Message-Id: <1417514352-8825-9-git-send-email-jezz@sysmic.org> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1417514352-8825-1-git-send-email-jezz@sysmic.org> References: <1417514352-8825-1-git-send-email-jezz@sysmic.org> MIME-Version: 1.0 Cc: =?UTF-8?q?J=C3=A9r=C3=B4me=20Pouiller?= Subject: [Buildroot] [PATCH v4 08/14] libdrm: fix support for xserver with Vivante drivers X-BeenThere: buildroot@busybox.net X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: Discussion and development of buildroot List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: buildroot-bounces@busybox.net Sender: "buildroot" Signed-off-by: Jérôme Pouiller --- package/libdrm/0001-update-arm.patch | 37 ++++++++++++++++++++++++++++++++++++ 1 file changed, 37 insertions(+) create mode 100644 package/libdrm/0001-update-arm.patch diff --git a/package/libdrm/0001-update-arm.patch b/package/libdrm/0001-update-arm.patch new file mode 100644 index 0000000..8c874bb --- /dev/null +++ b/package/libdrm/0001-update-arm.patch @@ -0,0 +1,37 @@ +[Adapted from yocto project] + +Add ARM support into xf86arm.h. This provides support for Xorg interface. +Without this the vivante samples will hang during close requiring a reboot + +Upstream-Status: Pending + +Signed-off-by: Lauren Post +Signed-off-by: Evan Kotara + +diff --git a/xf86drm.h b/xf86drm.h +--- a/xf86drm.h ++++ b/xf86drm.h +@@ -461,6 +461,23 @@ do { register unsigned int __old __asm(" + : "cr0", "memory"); \ + } while (0) + ++#elif defined(__arm__) ++ #undef DRM_DEV_MODE ++ #define DRM_DEV_MODE (S_IRUSR|S_IWUSR|S_IRGRP|S_IWGRP|S_IROTH|S_IWOTH) ++ ++ #define DRM_CAS(lock,old,new,__ret) \ ++ do { \ ++ __asm__ __volatile__ ( \ ++ "1: ldrex %0, [%1]\n" \ ++ " teq %0, %2\n" \ ++ " ite eq\n" \ ++ " strexeq %0, %3, [%1]\n" \ ++ " movne %0, #1\n" \ ++ : "=&r" (__ret) \ ++ : "r" (lock), "r" (old), "r" (new) \ ++ : "cc","memory"); \ ++ } while (0) ++ + #endif /* architecture */ + #endif /* __GNUC__ >= 2 */ +