aboutsummaryrefslogtreecommitdiff
path: root/drivers/video/video_osd-uclass.c
blob: 82136a292bf1c99e8e8936f6c97ec625f0eaf7bc (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
// SPDX-License-Identifier: GPL-2.0+
/*
 * (C) Copyright 2017
 * Mario Six,  Guntermann & Drunck GmbH, mario.six@gdsys.cc
 */

#include <common.h>
#include <dm.h>
#include <video_osd.h>

int video_osd_get_info(struct udevice *dev, struct video_osd_info *info)
{
	struct video_osd_ops *ops = video_osd_get_ops(dev);

	return ops->get_info(dev, info);
}

int video_osd_set_mem(struct udevice *dev, uint col, uint row, u8 *buf,
		      size_t buflen, uint count)
{
	struct video_osd_ops *ops = video_osd_get_ops(dev);

	return ops->set_mem(dev, col, row, buf, buflen, count);
}

int video_osd_set_size(struct udevice *dev, uint col, uint row)
{
	struct video_osd_ops *ops = video_osd_get_ops(dev);

	return ops->set_size(dev, col, row);
}

int video_osd_print(struct udevice *dev, uint col, uint row, ulong color,
		    char *text)
{
	struct video_osd_ops *ops = video_osd_get_ops(dev);

	return ops->print(dev, col, row, color, text);
}

UCLASS_DRIVER(video_osd) = {
	.id		= UCLASS_VIDEO_OSD,
	.name		= "video_osd",
	.flags		= DM_UC_FLAG_SEQ_ALIAS,
};