X-Git-Url: https://review.fuel-infra.org/gitweb?a=blobdiff_plain;f=cirros-testvm%2Fsrc-cirros%2Fbuildroot-2015.05%2Fpackage%2Flibdrm%2F0001-update-arm.patch;fp=cirros-testvm%2Fsrc-cirros%2Fbuildroot-2015.05%2Fpackage%2Flibdrm%2F0001-update-arm.patch;h=1a95a14ba04da1515b969efd1bd62588b482d4e0;hb=b0a0f15dfaa205161a7fcb20cf1b8cd4948c2ef3;hp=0000000000000000000000000000000000000000;hpb=c6ac3cd55ee2da956195eee393b0882105dfad4e;p=packages%2Ftrusty%2Fcirros-testvm.git diff --git a/cirros-testvm/src-cirros/buildroot-2015.05/package/libdrm/0001-update-arm.patch b/cirros-testvm/src-cirros/buildroot-2015.05/package/libdrm/0001-update-arm.patch new file mode 100644 index 0000000..1a95a14 --- /dev/null +++ b/cirros-testvm/src-cirros/buildroot-2015.05/package/libdrm/0001-update-arm.patch @@ -0,0 +1,37 @@ +[Adapted from yocto project] + +Add ARM support into xf86drm.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 */ +