Introduce the dpu_writeback module which serves as the interface between dpu operations and the drm_writeback. This module manages the connector related operations for dpu writeback. changes in v2: - start using drm_writeback_connector_init_with_encoder() - drop unnecessary arguments from dpu_writeback_init() - rebase on msm-next tip and remove usage of priv->connectors changes in v3: - none changes in v4: - none changes in v5: - store the drm_enc in the dpu_wb_conn to be used while using dpu_encoder APIs Signed-off-by: Abhinav Kumar <quic_abhinavk@quicinc.com> Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org> Patchwork: https://patchwork.freedesktop.org/patch/483520/ Link: https://lore.kernel.org/r/1650984096-9964-15-git-send-email-quic_abhinavk@quicinc.com Signed-off-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org>
31 lines
769 B
C
31 lines
769 B
C
/* SPDX-License-Identifier: GPL-2.0-only */
|
|
/*
|
|
* Copyright (c) 2022 Qualcomm Innovation Center, Inc. All rights reserved.
|
|
*/
|
|
|
|
#ifndef _DPU_WRITEBACK_H
|
|
#define _DPU_WRITEBACK_H
|
|
|
|
#include <drm/drm_crtc.h>
|
|
#include <drm/drm_file.h>
|
|
#include <drm/drm_probe_helper.h>
|
|
#include <drm/drm_writeback.h>
|
|
|
|
#include "msm_drv.h"
|
|
#include "dpu_kms.h"
|
|
#include "dpu_encoder_phys.h"
|
|
|
|
struct dpu_wb_connector {
|
|
struct drm_writeback_connector base;
|
|
struct drm_encoder *wb_enc;
|
|
};
|
|
|
|
static inline struct dpu_wb_connector *to_dpu_wb_conn(struct drm_writeback_connector *conn)
|
|
{
|
|
return container_of(conn, struct dpu_wb_connector, base);
|
|
}
|
|
|
|
int dpu_writeback_init(struct drm_device *dev, struct drm_encoder *enc,
|
|
const u32 *format_list, u32 num_formats);
|
|
|
|
#endif /*_DPU_WRITEBACK_H */
|