162306a36Sopenharmony_ci/* SPDX-License-Identifier: GPL-2.0-or-later */
262306a36Sopenharmony_ci/*
362306a36Sopenharmony_ci * Xilinx DMA Engine drivers support header file
462306a36Sopenharmony_ci *
562306a36Sopenharmony_ci * Copyright (C) 2010-2014 Xilinx, Inc. All rights reserved.
662306a36Sopenharmony_ci */
762306a36Sopenharmony_ci
862306a36Sopenharmony_ci#ifndef __DMA_XILINX_DMA_H
962306a36Sopenharmony_ci#define __DMA_XILINX_DMA_H
1062306a36Sopenharmony_ci
1162306a36Sopenharmony_ci#include <linux/dma-mapping.h>
1262306a36Sopenharmony_ci#include <linux/dmaengine.h>
1362306a36Sopenharmony_ci
1462306a36Sopenharmony_ci/**
1562306a36Sopenharmony_ci * struct xilinx_vdma_config - VDMA Configuration structure
1662306a36Sopenharmony_ci * @frm_dly: Frame delay
1762306a36Sopenharmony_ci * @gen_lock: Whether in gen-lock mode
1862306a36Sopenharmony_ci * @master: Master that it syncs to
1962306a36Sopenharmony_ci * @frm_cnt_en: Enable frame count enable
2062306a36Sopenharmony_ci * @park: Whether wants to park
2162306a36Sopenharmony_ci * @park_frm: Frame to park on
2262306a36Sopenharmony_ci * @coalesc: Interrupt coalescing threshold
2362306a36Sopenharmony_ci * @delay: Delay counter
2462306a36Sopenharmony_ci * @reset: Reset Channel
2562306a36Sopenharmony_ci * @ext_fsync: External Frame Sync source
2662306a36Sopenharmony_ci * @vflip_en:  Vertical Flip enable
2762306a36Sopenharmony_ci */
2862306a36Sopenharmony_cistruct xilinx_vdma_config {
2962306a36Sopenharmony_ci	int frm_dly;
3062306a36Sopenharmony_ci	int gen_lock;
3162306a36Sopenharmony_ci	int master;
3262306a36Sopenharmony_ci	int frm_cnt_en;
3362306a36Sopenharmony_ci	int park;
3462306a36Sopenharmony_ci	int park_frm;
3562306a36Sopenharmony_ci	int coalesc;
3662306a36Sopenharmony_ci	int delay;
3762306a36Sopenharmony_ci	int reset;
3862306a36Sopenharmony_ci	int ext_fsync;
3962306a36Sopenharmony_ci	bool vflip_en;
4062306a36Sopenharmony_ci};
4162306a36Sopenharmony_ci
4262306a36Sopenharmony_ciint xilinx_vdma_channel_set_config(struct dma_chan *dchan,
4362306a36Sopenharmony_ci					struct xilinx_vdma_config *cfg);
4462306a36Sopenharmony_ci
4562306a36Sopenharmony_ci#endif
46