From patchwork Fri Feb 6 12:52:08 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Benjamin Gaignard X-Patchwork-Id: 44481 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-we0-f198.google.com (mail-we0-f198.google.com [74.125.82.198]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id 06CF921529 for ; Fri, 6 Feb 2015 12:52:40 +0000 (UTC) Received: by mail-we0-f198.google.com with SMTP id p10sf6775078wes.1 for ; Fri, 06 Feb 2015 04:52:39 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:delivered-to:delivered-to:from:to:subject:date :message-id:in-reply-to:references:cc:precedence:list-id :list-unsubscribe:list-archive:list-post:list-help:list-subscribe :mime-version:content-type:content-transfer-encoding:errors-to :sender:x-original-sender:x-original-authentication-results :mailing-list; bh=AO15NHXn6jlk8zswNTTfdWgx3/Kjbay8OLUvnSIVpgE=; b=T7vzfH+k2cop+Q1yIYCQoSPe4pa58K0VsMY2L8b4+UayEQWOec0gPt/BkcKyrADNaF M6GXQQFZdouJRt27dARCgIUlYW1zGTSOxstReAqoUeVjvBNz/QY90YkSwPPHACdd5nz8 V3HckOT8lMO6IKCkzoQHnJvzz/f7IcU+3GPBEHokR5Dz0AGE2P7TRYgbHjtCltu64JNX zAdU+Z0ByYqIHRcXwZfHhg3vJjaXGSzFtj+0GX+9cDUgBbl5TPWD9h4uZsyJ4BUPKn0C inonNnPQYlBuWhVvN2X4cILrbMFWKFOyEOT+0pkx+GpHrcLdfcjuGVDj+Skqptk53Cob G+/g== X-Gm-Message-State: ALoCoQlwbd6BqejCTW0sAuykmqw9iLIO9oxksBMp4BZYb1vCW8AmpPfuhqVpPcmfwJ8myHchbQi9 X-Received: by 10.112.174.36 with SMTP id bp4mr418131lbc.15.1423227159272; Fri, 06 Feb 2015 04:52:39 -0800 (PST) X-BeenThere: patchwork-forward@linaro.org Received: by 10.152.8.167 with SMTP id s7ls288170laa.80.gmail; Fri, 06 Feb 2015 04:52:39 -0800 (PST) X-Received: by 10.112.40.65 with SMTP id v1mr2538522lbk.26.1423227159093; Fri, 06 Feb 2015 04:52:39 -0800 (PST) Received: from mail-lb0-f174.google.com (mail-lb0-f174.google.com. [209.85.217.174]) by mx.google.com with ESMTPS id mz7si1359586lbb.36.2015.02.06.04.52.39 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 06 Feb 2015 04:52:39 -0800 (PST) Received-SPF: pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.217.174 as permitted sender) client-ip=209.85.217.174; Received: by mail-lb0-f174.google.com with SMTP id f15so17739189lbj.5 for ; Fri, 06 Feb 2015 04:52:38 -0800 (PST) X-Received: by 10.112.114.230 with SMTP id jj6mr2479830lbb.112.1423227158945; Fri, 06 Feb 2015 04:52:38 -0800 (PST) X-Forwarded-To: patchwork-forward@linaro.org X-Forwarded-For: patch@linaro.org patchwork-forward@linaro.org Delivered-To: patch@linaro.org Received: by 10.112.35.133 with SMTP id h5csp1781987lbj; Fri, 6 Feb 2015 04:52:38 -0800 (PST) X-Received: by 10.70.123.1 with SMTP id lw1mr5706928pdb.26.1423227153955; Fri, 06 Feb 2015 04:52:33 -0800 (PST) Received: from gabe.freedesktop.org (gabe.freedesktop.org. [131.252.210.177]) by mx.google.com with ESMTP id t5si10282487pdh.70.2015.02.06.04.52.32; Fri, 06 Feb 2015 04:52:33 -0800 (PST) Received-SPF: none (google.com: dri-devel-bounces@lists.freedesktop.org does not designate permitted sender hosts) client-ip=131.252.210.177; Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 55A996E926; Fri, 6 Feb 2015 04:52:31 -0800 (PST) X-Original-To: dri-devel@lists.freedesktop.org Delivered-To: dri-devel@lists.freedesktop.org Received: from mail-we0-f180.google.com (mail-we0-f180.google.com [74.125.82.180]) by gabe.freedesktop.org (Postfix) with ESMTP id B44006E926 for ; Fri, 6 Feb 2015 04:52:29 -0800 (PST) Received: by mail-we0-f180.google.com with SMTP id m14so13476265wev.11 for ; Fri, 06 Feb 2015 04:52:29 -0800 (PST) X-Received: by 10.194.60.104 with SMTP id g8mr7274839wjr.96.1423227149041; Fri, 06 Feb 2015 04:52:29 -0800 (PST) Received: from lmenx321.st.com. (lya72-2-88-175-155-153.fbx.proxad.net. [88.175.155.153]) by mx.google.com with ESMTPSA id hr1sm1392601wib.1.2015.02.06.04.52.28 (version=TLSv1.1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Fri, 06 Feb 2015 04:52:28 -0800 (PST) From: Benjamin Gaignard To: dri-devel@lists.freedesktop.org, linaro-mm-sig@lists.linaro.org, airlied@redhat.com Subject: [PATCH 4/5] drm: sti: add support of XBGR8888 for gdp plane Date: Fri, 6 Feb 2015 13:52:08 +0100 Message-Id: <1423227129-17588-5-git-send-email-benjamin.gaignard@linaro.org> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1423227129-17588-1-git-send-email-benjamin.gaignard@linaro.org> References: <1423227129-17588-1-git-send-email-benjamin.gaignard@linaro.org> Cc: Fabien Dessenne X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: 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-Removed-Original-Auth: Dkim didn't pass. X-Original-Sender: benjamin.gaignard@linaro.org X-Original-Authentication-Results: mx.google.com; spf=pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.217.174 as permitted sender) smtp.mail=patch+caf_=patchwork-forward=linaro.org@linaro.org Mailing-list: list patchwork-forward@linaro.org; contact patchwork-forward+owners@linaro.org X-Google-Group-Id: 836684582541 From: Fabien Dessenne Use GDP capabilities to support DRM_FORMAT_XBGR8888 (XB24) Signed-off-by: Fabien Dessenne --- drivers/gpu/drm/sti/sti_gdp.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/drivers/gpu/drm/sti/sti_gdp.c b/drivers/gpu/drm/sti/sti_gdp.c index f018bb1..087906f 100644 --- a/drivers/gpu/drm/sti/sti_gdp.c +++ b/drivers/gpu/drm/sti/sti_gdp.c @@ -23,6 +23,7 @@ #define GDP_RGB565 0x00 #define GDP_RGB888 0x01 #define GDP_RGB888_32 0x02 +#define GDP_XBGR8888 (GDP_RGB888_32 | BIGNOTLITTLE | ALPHASWITCH) #define GDP_ARGB8565 0x04 #define GDP_ARGB8888 0x05 #define GDP_ABGR8888 (GDP_ARGB8888 | BIGNOTLITTLE | ALPHASWITCH) @@ -106,6 +107,7 @@ struct sti_gdp { static const uint32_t gdp_supported_formats[] = { DRM_FORMAT_XRGB8888, + DRM_FORMAT_XBGR8888, DRM_FORMAT_ARGB8888, DRM_FORMAT_ABGR8888, DRM_FORMAT_ARGB4444, @@ -133,6 +135,8 @@ static int sti_gdp_fourcc2format(int fourcc) switch (fourcc) { case DRM_FORMAT_XRGB8888: return GDP_RGB888_32; + case DRM_FORMAT_XBGR8888: + return GDP_XBGR8888; case DRM_FORMAT_ARGB8888: return GDP_ARGB8888; case DRM_FORMAT_ABGR8888: