dt-bindings: mtd: ingenic: Use standard ecc-engine property
[linux/fpc-iii.git] / drivers / gpu / drm / sun4i / sun4i_layer.h
blob36b20265bd31b851e4fc537ab92e6f38d7e88738
1 /*
2 * Copyright (C) 2015 Free Electrons
3 * Copyright (C) 2015 NextThing Co
5 * Maxime Ripard <maxime.ripard@free-electrons.com>
7 * This program is free software; you can redistribute it and/or
8 * modify it under the terms of the GNU General Public License as
9 * published by the Free Software Foundation; either version 2 of
10 * the License, or (at your option) any later version.
13 #ifndef _SUN4I_LAYER_H_
14 #define _SUN4I_LAYER_H_
16 struct sunxi_engine;
18 struct sun4i_layer {
19 struct drm_plane plane;
20 struct sun4i_drv *drv;
21 struct sun4i_backend *backend;
22 int id;
25 struct sun4i_layer_state {
26 struct drm_plane_state state;
27 unsigned int pipe;
28 bool uses_frontend;
31 static inline struct sun4i_layer *
32 plane_to_sun4i_layer(struct drm_plane *plane)
34 return container_of(plane, struct sun4i_layer, plane);
37 static inline struct sun4i_layer_state *
38 state_to_sun4i_layer_state(struct drm_plane_state *state)
40 return container_of(state, struct sun4i_layer_state, state);
43 struct drm_plane **sun4i_layers_init(struct drm_device *drm,
44 struct sunxi_engine *engine);
46 #endif /* _SUN4I_LAYER_H_ */