Lines Matching full:backlight
3 * Backlight Lowlevel Control Abstraction
14 #include <linux/backlight.h>
22 #include <asm/backlight.h>
28 * The backlight core supports implementing backlight drivers.
30 * A backlight driver registers a driver using
31 * devm_backlight_device_register(). The properties of the backlight
34 * the update_status() operation is called. The backlight driver shall
35 * implement this operation and use it to adjust backlight.
37 * Several sysfs attributes are provided by the backlight core::
43 * See Documentation/ABI/stable/sysfs-class-backlight for the full list.
45 * The backlight can be adjusted using the sysfs interface, and
46 * the backlight driver may also support adjusting backlight using
54 * When the backlight changes this is reported to user-space using
57 * a hot-key to adjust backlight, the driver must notify the backlight
60 * The backlight driver core receives notifications from fbdev and
62 * FBIOBLANK ioctrl, results in a change in the backlight state the
87 * framebuffer driver. The backlight core only cares about FB_BLANK_UNBLANK
91 * There may be several fbdev's connected to the backlight device,
93 * if there is a change in backlight for the specified fbdev.
372 .name = "backlight",
378 * backlight_force_update - tell the backlight subsystem that hardware state
380 * @bd: the backlight device to update
383 * Updates the internal state of the backlight in response to a hardware event,
384 * and generates an uevent to notify userspace. A backlight driver shall call
385 * backlight_force_update() when the backlight is changed using, for example,
437 WARN(1, "%s: invalid backlight type", name); in backlight_device_register()
473 /** backlight_device_get_by_type - find first backlight device of a type
474 * @type: the type of backlight device
476 * Look up the first backlight device of the specified type
480 * Pointer to backlight device if any was found. Otherwise NULL.
501 * backlight_device_get_by_name - Get backlight device by name
504 * This function looks up a backlight device by its name. It obtains a reference
505 * on the backlight device and it is the caller's responsibility to drop the
509 * A pointer to the backlight device if found, otherwise NULL.
549 struct backlight_device *backlight = *(struct backlight_device **)res; in devm_backlight_device_release() local
551 backlight_device_unregister(backlight); in devm_backlight_device_release()
563 * devm_backlight_device_register - register a new backlight device
568 * @ops: the backlight operations structure
569 * @props: the backlight properties
571 * Creates and registers new backlight device. When a backlight device
577 * struct backlight on success, or an ERR_PTR on error
584 struct backlight_device **ptr, *backlight; in devm_backlight_device_register() local
591 backlight = backlight_device_register(name, parent, devdata, ops, in devm_backlight_device_register()
593 if (!IS_ERR(backlight)) { in devm_backlight_device_register()
594 *ptr = backlight; in devm_backlight_device_register()
600 return backlight; in devm_backlight_device_register()
605 * devm_backlight_device_unregister - unregister backlight device
607 * @bd: the backlight device to unregister
609 * Deallocates a backlight allocated with devm_backlight_device_register().
631 * of_find_backlight_by_node() - find backlight device by device-tree node
632 * @node: device-tree node of the backlight device
634 * Returns a pointer to the backlight device corresponding to the given DT
635 * node or NULL if no such backlight device exists or if the device hasn't
638 * This function obtains a reference on the backlight device and it is the
640 * the backlight device's .dev field.
662 np = of_parse_phandle(dev->of_node, "backlight", 0); in of_find_backlight()
682 * devm_of_find_backlight - find backlight for a device
685 * This function looks for a property named 'backlight' on the DT node
686 * connected to @dev and looks up the backlight device. The lookup is
687 * device managed so the reference to the backlight device is automatically
692 * A pointer to the backlight device if found.
693 * Error pointer -EPROBE_DEFER if the DT property is set, but no backlight
694 * device is found. NULL if there's no backlight property.
723 pr_warn("Unable to create backlight class; errno = %d\n", ret); in backlight_class_init()
742 MODULE_DESCRIPTION("Backlight Lowlevel Control Abstraction");