From patchwork Fri Sep 23 06:35:25 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Daniel Vetter X-Patchwork-Id: 9347515 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 6DA66607F2 for ; Fri, 23 Sep 2016 06:35:38 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 53ADA2A14A for ; Fri, 23 Sep 2016 06:35:38 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 4889A2A1B4; Fri, 23 Sep 2016 06:35:38 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-4.1 required=2.0 tests=BAYES_00,DKIM_SIGNED, RCVD_IN_DNSWL_MED,T_DKIM_INVALID autolearn=ham version=3.3.1 Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher DHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id DE0F12A14A for ; Fri, 23 Sep 2016 06:35:37 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id B55FB6E9D3; Fri, 23 Sep 2016 06:35:34 +0000 (UTC) X-Original-To: dri-devel@lists.freedesktop.org Delivered-To: dri-devel@lists.freedesktop.org Received: from mail-lf0-x244.google.com (mail-lf0-x244.google.com [IPv6:2a00:1450:4010:c07::244]) by gabe.freedesktop.org (Postfix) with ESMTPS id 1001F6E9D3 for ; Fri, 23 Sep 2016 06:35:33 +0000 (UTC) Received: by mail-lf0-x244.google.com with SMTP id s29so5132806lfg.3 for ; Thu, 22 Sep 2016 23:35:32 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ffwll.ch; s=google; h=from:to:cc:subject:date:message-id; bh=5aK63afpKGsJ2D0MJe+KLunWcUrFHO607S82uUaPkcU=; b=Wb3404JjDXGg+3/Sbzn261krEeAwG5W967pCjxfTTHkAD3TITJXbekbAFSNb7s8HUs cTDbMQr9wm5TZpXDFhOnPk0IYUPZHt2qpal/WZQUG/OMIREowWwSM8p0pxYNGzDZq+Mm a4wkFNxdwcQUX5aI4SKtvBZqlZDCAKZ3klMcA= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id; bh=5aK63afpKGsJ2D0MJe+KLunWcUrFHO607S82uUaPkcU=; b=ZrR1y3l+oNiIrkw8+C1QM6hmECTsLGyU/ge4fWfDMOGl6Esfmoihq3pRR9WU+pcpc3 dNz0Qukw1kS0oODJgv/dNqOcujdiFnM3yqJCDZzy1XNegOaaP75lIbbQ83m3KjHsGpWa xxCTrGP+Hq3renXdgH1CTMNixDlzW285v2rrJT5bkdYVjTx7aiH5YQTaj+b3xt1p5X26 tTw+OMCN7grJ7RPU1Ui7/TwLLb7cwJhuqt2BONfISKP1yuYnpk2UenD1DlyV0XKNozgE f/uaoXRZjswUCf2IhVuLjLFwtZw7plUM/OdpQH80Wich/3I8oFBwXYsdNiNKFmAI+Xqx I3Fg== X-Gm-Message-State: AE9vXwPtpROIpp1J7ygRLNmj5kE1LR8VGPUM5AEWlio2dLq0bVRPG8vKAUngobfzoHa/dA== X-Received: by 10.25.215.82 with SMTP id o79mr2330573lfg.132.1474612531391; Thu, 22 Sep 2016 23:35:31 -0700 (PDT) Received: from dvetter-linux.ger.corp.intel.com (pub-nat.haaga-helia.fi. [193.166.13.253]) by smtp.gmail.com with ESMTPSA id s187sm937232lfd.3.2016.09.22.23.35.30 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 22 Sep 2016 23:35:30 -0700 (PDT) From: Daniel Vetter To: Intel Graphics Development , DRI Development Subject: [PATCH] drm: Fix plane type uabi breakage Date: Fri, 23 Sep 2016 08:35:25 +0200 Message-Id: <1474612525-9488-1-git-send-email-daniel.vetter@ffwll.ch> X-Mailer: git-send-email 2.7.4 Cc: Daniel Vetter , Daniel Vetter 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-Virus-Scanned: ClamAV using ClamSMTP Turns out assuming that only stuff in uabi is uabi is a bit naive, and we have a bunch of properties for which the enum values are placed in random headers. A proper fix would be to split out uapi include headers, but meanwhile sprinkle at least some warning over them. Fixes: 532b36712ddf ("drm/doc: Polish for drm_plane.[hc]") Cc: Archit Taneja Cc: Sean Paul Signed-off-by: Daniel Vetter Reviewed-by: Jani Nikula Reviewed-by: Archit Taneja --- include/drm/drm_blend.h | 3 +++ include/drm/drm_plane.h | 19 +++++++++++-------- 2 files changed, 14 insertions(+), 8 deletions(-) diff --git a/include/drm/drm_blend.h b/include/drm/drm_blend.h index 868f0364e939..36baa175de99 100644 --- a/include/drm/drm_blend.h +++ b/include/drm/drm_blend.h @@ -33,6 +33,9 @@ struct drm_atomic_state; * Rotation property bits. DRM_ROTATE_ rotates the image by the * specified amount in degrees in counter clockwise direction. DRM_REFLECT_X and * DRM_REFLECT_Y reflects the image along the specified axis prior to rotation + * + * WARNING: These defines are UABI since they're exposed in the rotation + * property. */ #define DRM_ROTATE_0 BIT(0) #define DRM_ROTATE_90 BIT(1) diff --git a/include/drm/drm_plane.h b/include/drm/drm_plane.h index 256219bfd07b..43cf193e54d6 100644 --- a/include/drm/drm_plane.h +++ b/include/drm/drm_plane.h @@ -333,9 +333,20 @@ struct drm_plane_funcs { * DRM_CLIENT_CAP_UNIVERSAL_PLANES client capability bit to indicate that they * wish to receive a universal plane list containing all plane types. See also * drm_for_each_legacy_plane(). + * + * WARNING: The values of this enum is UABI since they're exposed in the "type" + * property. */ enum drm_plane_type { /** + * @DRM_PLANE_TYPE_OVERLAY: + * + * Overlay planes represent all non-primary, non-cursor planes. Some + * drivers refer to these types of planes as "sprites" internally. + */ + DRM_PLANE_TYPE_OVERLAY, + + /** * @DRM_PLANE_TYPE_PRIMARY: * * Primary planes represent a "main" plane for a CRTC. Primary planes @@ -353,14 +364,6 @@ enum drm_plane_type { * DRM_IOCTL_MODE_CURSOR2 IOCTLs. */ DRM_PLANE_TYPE_CURSOR, - - /** - * @DRM_PLANE_TYPE_OVERLAY: - * - * Overlay planes represent all non-primary, non-cursor planes. Some - * drivers refer to these types of planes as "sprites" internally. - */ - DRM_PLANE_TYPE_OVERLAY, };