drm: Use new DRM_BUS_FLAG_*_(DRIVE|SAMPLE)_(POS|NEG)EDGE flags
The DRM_BUS_FLAG_PIXDATA_(POS|NEG)EDGE and DRM_BUS_FLAG_SYNC_(POS|NEG)EDGE flags are deprecated in favour of the new DRM_BUS_FLAG_PIXDATA_(DRIVE|SAMPLE)_(POS|NEG)EDGE and new DRM_BUS_FLAG_SYNC_(DRIVE|SAMPLE)_(POS|NEG)EDGE flags. Replace them through the code. This effectively changes the value of the .sampling_edge bridge timings field in the dumb-vga-dac driver. This is safe to do as no driver consumes these values yet. Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Acked-by: Linus Walleij <linus.walleij@linaro.org> Reviewed-by: Stefan Agner <stefan@agner.ch> Tested-by: Sebastian Reichel <sebastian.reichel@collabora.com> Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
This commit is contained in:

committed by
Tomi Valkeinen

parent
a792fa0e21
commit
88bc417856
@@ -655,22 +655,22 @@ EXPORT_SYMBOL_GPL(drm_display_mode_to_videomode);
|
||||
* @bus_flags: information about pixelclk, sync and DE polarity will be stored
|
||||
* here
|
||||
*
|
||||
* Sets DRM_BUS_FLAG_DE_(LOW|HIGH), DRM_BUS_FLAG_PIXDATA_(POS|NEG)EDGE and
|
||||
* DISPLAY_FLAGS_SYNC_(POS|NEG)EDGE in @bus_flags according to DISPLAY_FLAGS
|
||||
* Sets DRM_BUS_FLAG_DE_(LOW|HIGH), DRM_BUS_FLAG_PIXDATA_DRIVE_(POS|NEG)EDGE
|
||||
* and DISPLAY_FLAGS_SYNC_(POS|NEG)EDGE in @bus_flags according to DISPLAY_FLAGS
|
||||
* found in @vm
|
||||
*/
|
||||
void drm_bus_flags_from_videomode(const struct videomode *vm, u32 *bus_flags)
|
||||
{
|
||||
*bus_flags = 0;
|
||||
if (vm->flags & DISPLAY_FLAGS_PIXDATA_POSEDGE)
|
||||
*bus_flags |= DRM_BUS_FLAG_PIXDATA_POSEDGE;
|
||||
*bus_flags |= DRM_BUS_FLAG_PIXDATA_DRIVE_POSEDGE;
|
||||
if (vm->flags & DISPLAY_FLAGS_PIXDATA_NEGEDGE)
|
||||
*bus_flags |= DRM_BUS_FLAG_PIXDATA_NEGEDGE;
|
||||
*bus_flags |= DRM_BUS_FLAG_PIXDATA_DRIVE_NEGEDGE;
|
||||
|
||||
if (vm->flags & DISPLAY_FLAGS_SYNC_POSEDGE)
|
||||
*bus_flags |= DRM_BUS_FLAG_SYNC_POSEDGE;
|
||||
*bus_flags |= DRM_BUS_FLAG_SYNC_DRIVE_POSEDGE;
|
||||
if (vm->flags & DISPLAY_FLAGS_SYNC_NEGEDGE)
|
||||
*bus_flags |= DRM_BUS_FLAG_SYNC_NEGEDGE;
|
||||
*bus_flags |= DRM_BUS_FLAG_SYNC_DRIVE_NEGEDGE;
|
||||
|
||||
if (vm->flags & DISPLAY_FLAGS_DE_LOW)
|
||||
*bus_flags |= DRM_BUS_FLAG_DE_LOW;
|
||||
|
Reference in New Issue
Block a user