From: Benjamin Gaignard Subject: [PATCH v1 08/19] drm: sti: add sti layer interface definition Date: Tue, 8 Apr 2014 14:19:15 +0200 Message-ID: <1396959566-2960-9-git-send-email-benjamin.gaignard@linaro.org> References: <1396959566-2960-1-git-send-email-benjamin.gaignard@linaro.org> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: Received: from mail-wg0-f43.google.com (mail-wg0-f43.google.com [74.125.82.43]) by gabe.freedesktop.org (Postfix) with ESMTP id 72F026E9DE for ; Tue, 8 Apr 2014 05:20:37 -0700 (PDT) Received: by mail-wg0-f43.google.com with SMTP id x13so860778wgg.14 for ; Tue, 08 Apr 2014 05:20:36 -0700 (PDT) In-Reply-To: <1396959566-2960-1-git-send-email-benjamin.gaignard@linaro.org> List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" To: dri-devel@lists.freedesktop.org, linaro-mm-sig@lists.linaro.org Cc: Fabien Dessenne , Benjamin Gaignard List-Id: dri-devel@lists.freedesktop.org STI hardware have various input sub-devices before mixing block. Each type of sub-device have different capabilities for scaling, filtering or accepted pixel format. This layer interface abstract those differences and make the interaction with compositor more simple. Signed-off-by: Benjamin Gaignard Signed-off-by: Vincent Abriou Signed-off-by: Fabien Dessenne --- drivers/gpu/drm/sti/sti_layer.h | 104 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 104 insertions(+) create mode 100644 drivers/gpu/drm/sti/sti_layer.h diff --git a/drivers/gpu/drm/sti/sti_layer.h b/drivers/gpu/drm/sti/sti_layer.h new file mode 100644 index 0000000..ed8386a --- /dev/null +++ b/drivers/gpu/drm/sti/sti_layer.h @@ -0,0 +1,104 @@ +/* + * Copyright (C) STMicroelectronics SA 2013 + * Authors: Benjamin Gaignard + * Fabien Dessenne + * for STMicroelectronics. + * License terms: GNU General Public License (GPL), version 2 + */ + +#ifndef _STI_LAYER_H_ +#define _STI_LAYER_H_ + +#include + +#define to_sti_layer(x) container_of(x, struct sti_layer, plane) + +#define STI_LAYER_TYPE_SHIFT 8 +#define STI_LAYER_TYPE_MASK (~((1<