.. | .. |
---|
| 1 | +/* SPDX-License-Identifier: GPL-2.0+ */ |
---|
1 | 2 | /* |
---|
2 | 3 | * vsp1.h -- R-Car VSP1 API |
---|
3 | 4 | * |
---|
4 | 5 | * Copyright (C) 2015 Renesas Electronics Corporation |
---|
5 | 6 | * |
---|
6 | 7 | * Contact: Laurent Pinchart (laurent.pinchart@ideasonboard.com) |
---|
7 | | - * |
---|
8 | | - * This program is free software; you can redistribute it and/or modify |
---|
9 | | - * it under the terms of the GNU General Public License as published by |
---|
10 | | - * the Free Software Foundation; either version 2 of the License, or |
---|
11 | | - * (at your option) any later version. |
---|
12 | 8 | */ |
---|
13 | 9 | #ifndef __MEDIA_VSP1_H__ |
---|
14 | 10 | #define __MEDIA_VSP1_H__ |
---|
.. | .. |
---|
20 | 16 | struct device; |
---|
21 | 17 | |
---|
22 | 18 | int vsp1_du_init(struct device *dev); |
---|
| 19 | + |
---|
| 20 | +#define VSP1_DU_STATUS_COMPLETE BIT(0) |
---|
| 21 | +#define VSP1_DU_STATUS_WRITEBACK BIT(1) |
---|
23 | 22 | |
---|
24 | 23 | /** |
---|
25 | 24 | * struct vsp1_du_lif_config - VSP LIF configuration |
---|
.. | .. |
---|
36 | 35 | unsigned int height; |
---|
37 | 36 | bool interlaced; |
---|
38 | 37 | |
---|
39 | | - void (*callback)(void *data, bool completed, u32 crc); |
---|
| 38 | + void (*callback)(void *data, unsigned int status, u32 crc); |
---|
40 | 39 | void *callback_data; |
---|
41 | 40 | }; |
---|
42 | 41 | |
---|
.. | .. |
---|
86 | 85 | }; |
---|
87 | 86 | |
---|
88 | 87 | /** |
---|
| 88 | + * struct vsp1_du_writeback_config - VSP writeback configuration parameters |
---|
| 89 | + * @pixelformat: plane pixel format (V4L2 4CC) |
---|
| 90 | + * @pitch: line pitch in bytes for the first plane |
---|
| 91 | + * @mem: DMA memory address for each plane of the frame buffer |
---|
| 92 | + */ |
---|
| 93 | +struct vsp1_du_writeback_config { |
---|
| 94 | + u32 pixelformat; |
---|
| 95 | + unsigned int pitch; |
---|
| 96 | + dma_addr_t mem[3]; |
---|
| 97 | +}; |
---|
| 98 | + |
---|
| 99 | +/** |
---|
89 | 100 | * struct vsp1_du_atomic_pipe_config - VSP atomic pipe configuration parameters |
---|
90 | 101 | * @crc: CRC computation configuration |
---|
| 102 | + * @writeback: writeback configuration |
---|
91 | 103 | */ |
---|
92 | 104 | struct vsp1_du_atomic_pipe_config { |
---|
93 | 105 | struct vsp1_du_crc_config crc; |
---|
| 106 | + struct vsp1_du_writeback_config writeback; |
---|
94 | 107 | }; |
---|
95 | 108 | |
---|
96 | 109 | void vsp1_du_atomic_begin(struct device *dev, unsigned int pipe_index); |
---|