From patchwork Wed Apr 20 13:49:19 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Stefan Dirsch X-Patchwork-Id: 8890101 Return-Path: X-Original-To: patchwork-dri-devel@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork1.web.kernel.org (Postfix) with ESMTP id 997289F1C1 for ; Wed, 20 Apr 2016 13:49:28 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id D30EF20211 for ; Wed, 20 Apr 2016 13:49:27 +0000 (UTC) Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) by mail.kernel.org (Postfix) with ESMTP id C53C32015E for ; Wed, 20 Apr 2016 13:49:26 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 0409F6E9DF; Wed, 20 Apr 2016 13:49:25 +0000 (UTC) X-Original-To: dri-devel@lists.freedesktop.org Delivered-To: dri-devel@lists.freedesktop.org Received: from mx2.suse.de (mx2.suse.de [195.135.220.15]) by gabe.freedesktop.org (Postfix) with ESMTPS id 1333E6E9DF for ; Wed, 20 Apr 2016 13:49:23 +0000 (UTC) X-Virus-Scanned: by amavisd-new at test-mx.suse.de Received: from relay1.suse.de (charybdis-ext.suse.de [195.135.220.254]) by mx2.suse.de (Postfix) with ESMTP id E5A78AC54 for ; Wed, 20 Apr 2016 13:49:19 +0000 (UTC) From: Stefan Dirsch To: dri-devel@lists.freedesktop.org Subject: [PATCH] drm: Fix compilation on systems that don't provide O_CLOEXEC Date: Wed, 20 Apr 2016 15:49:19 +0200 Message-Id: <1461160159-22345-1-git-send-email-sndirsch@suse.de> X-Mailer: git-send-email 2.6.2 X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" X-Spam-Status: No, score=-5.2 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_MED, RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Patch suggestion by Thomas Klausner . See also http://mail-index.netbsd.org/pkgsrc-changes/2012/08/13/msg076887.html Signed-off-by: Stefan Dirsch --- include/drm/drm.h | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/include/drm/drm.h b/include/drm/drm.h index b4ebaa9..739df01 100644 --- a/include/drm/drm.h +++ b/include/drm/drm.h @@ -674,7 +674,11 @@ struct drm_set_client_cap { }; #define DRM_RDWR O_RDWR +#ifdef O_CLOEXEC #define DRM_CLOEXEC O_CLOEXEC +#else +#define DRM_CLOEXEC 0 +#endif struct drm_prime_handle { __u32 handle;