xref: /freebsd/share/man/man9/backlight.9 (revision 320686674b3c8ce3ffe135c421a22d063917ee46)
1675aae73SEmmanuel Vadot.\" Copyright (c) 2020 Emmanuel Vadot <manu@freebsd.org>
2675aae73SEmmanuel Vadot.\"
3675aae73SEmmanuel Vadot.\" Redistribution and use in source and binary forms, with or without
4675aae73SEmmanuel Vadot.\" modification, are permitted provided that the following conditions
5675aae73SEmmanuel Vadot.\" are met:
6675aae73SEmmanuel Vadot.\" 1. Redistributions of source code must retain the above copyright
7675aae73SEmmanuel Vadot.\"    notice, this list of conditions and the following disclaimer.
8675aae73SEmmanuel Vadot.\" 2. Redistributions in binary form must reproduce the above copyright
9675aae73SEmmanuel Vadot.\"    notice, this list of conditions and the following disclaimer in the
10675aae73SEmmanuel Vadot.\"    documentation and/or other materials provided with the distribution.
11675aae73SEmmanuel Vadot.\"
12675aae73SEmmanuel Vadot.\" THIS SOFTWARE IS PROVIDED BY THE DEVELOPERS ``AS IS'' AND ANY EXPRESS OR
13675aae73SEmmanuel Vadot.\" IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
14675aae73SEmmanuel Vadot.\" OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
15675aae73SEmmanuel Vadot.\" IN NO EVENT SHALL THE DEVELOPERS BE LIABLE FOR ANY DIRECT, INDIRECT,
16675aae73SEmmanuel Vadot.\" INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
17675aae73SEmmanuel Vadot.\" NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
18675aae73SEmmanuel Vadot.\" DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
19675aae73SEmmanuel Vadot.\" THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
20675aae73SEmmanuel Vadot.\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
21675aae73SEmmanuel Vadot.\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
22675aae73SEmmanuel Vadot.\"
23675aae73SEmmanuel Vadot.\" $FreeBSD$
24675aae73SEmmanuel Vadot.\"
253d265fceSGordon Bergling.Dd October 2, 2020
26675aae73SEmmanuel Vadot.Dt BACKLIGHT 9
27675aae73SEmmanuel Vadot.Os
28675aae73SEmmanuel Vadot.Sh NAME
29675aae73SEmmanuel Vadot.Nm backlight ,
30675aae73SEmmanuel Vadot.Nm backlight_register ,
31675aae73SEmmanuel Vadot.Nm backlight_destroy ,
32675aae73SEmmanuel Vadot.Nm BACKLIGHT_GET_STATUS ,
33*32068667SChristian Brueffer.Nm BACKLIGHT_SET_STATUS
34675aae73SEmmanuel Vadot.Nd BACKLIGHT methods
35675aae73SEmmanuel Vadot.Sh SYNOPSIS
36675aae73SEmmanuel Vadot.Cd "device backlight"
37675aae73SEmmanuel Vadot.In "backlight_if.h"
38675aae73SEmmanuel Vadot.In "sys/sys/backlight.h"
39675aae73SEmmanuel Vadot.Ft int
40675aae73SEmmanuel Vadot.Fn BACKLIGHT_GET_STATUS "device_t bus" "struct backlight_props *props"
41675aae73SEmmanuel Vadot.Ft int
42675aae73SEmmanuel Vadot.Fn BACKLIGHT_SET_STATUS "device_t bus" "struct backlight_props *props"
43675aae73SEmmanuel Vadot.Ft struct cdev *
44675aae73SEmmanuel Vadot.Fn backlight_register "const char *name" "device_t dev"
45675aae73SEmmanuel Vadot.Ft int
46675aae73SEmmanuel Vadot.Fn backlight_destroy "struct cdev *cdev"
47675aae73SEmmanuel Vadot.Sh DESCRIPTION
48675aae73SEmmanuel VadotThe backlight driver provides a generic way for handling a panel backlight.
49675aae73SEmmanuel Vadot.Pp
50675aae73SEmmanuel VadotDrivers for backlight system register themselves globally using the
51675aae73SEmmanuel Vadot.Fn backlight_register
52675aae73SEmmanuel Vadotfunction.
53675aae73SEmmanuel VadotThey must define two methods,
54675aae73SEmmanuel Vadot.Fn BACKLIGHT_GET_STATUS
55675aae73SEmmanuel Vadotwhich is used to query the current brightness level and
56675aae73SEmmanuel Vadot.Fn BACKLIGHT_SET_STATUS
57675aae73SEmmanuel Vadotwhich is used to update it.
58675aae73SEmmanuel Vadot.Sh INTERFACE
59675aae73SEmmanuel Vadot.Bl -tag -width indent
60675aae73SEmmanuel Vadot.It Fn BACKLIGHT_GET_STATUS "device_t bus" "struct backlight_props *props"
61675aae73SEmmanuel VadotDriver fills the current brightless level and the optional supported levels.
62675aae73SEmmanuel Vadot.It Fn BACKLIGHT_SET_STATUS "device_t bus" "struct backlight_props *props"
63675aae73SEmmanuel VadotDriver update the backlight level based on the brightness member of the props
64675aae73SEmmanuel Vadotstruct.
65675aae73SEmmanuel Vadot.El
66675aae73SEmmanuel Vadot.Sh FILES
67675aae73SEmmanuel Vadot.Bl -tag -width "/dev/backlight/*"
68675aae73SEmmanuel Vadot.It Pa /dev/backlight/*
6916ee5cd1SChristian Brueffer.El
70675aae73SEmmanuel Vadot.Sh HISTORY
71675aae73SEmmanuel VadotThe
72675aae73SEmmanuel Vadot.Nm backlight
73675aae73SEmmanuel Vadotinterface first appear in
74675aae73SEmmanuel Vadot.Fx 13.0 .
75675aae73SEmmanuel VadotThe
76675aae73SEmmanuel Vadot.Nm backlight
77675aae73SEmmanuel Vadotdriver and manual page was written by
78675aae73SEmmanuel Vadot.An Emmanuel Vadot Aq Mt manu@FreeBSD.org .
79