mirror of
https://github.com/KolibriOS/kolibrios.git
synced 2024-11-25 02:09:36 +03:00
f75e5bc283
git-svn-id: svn://kolibrios.org@6936 a494cfbc-eb01-0410-851d-a64ba20cac60
51 lines
1.2 KiB
C
51 lines
1.2 KiB
C
/*
|
|
* Backlight Lowlevel Control Abstraction
|
|
*
|
|
* Copyright (C) 2003,2004 Hewlett-Packard Company
|
|
*
|
|
*/
|
|
|
|
#ifndef _LINUX_BACKLIGHT_H
|
|
#define _LINUX_BACKLIGHT_H
|
|
|
|
#include <linux/device.h>
|
|
#include <linux/fb.h>
|
|
#include <linux/mutex.h>
|
|
#include <linux/notifier.h>
|
|
|
|
/* Notes on locking:
|
|
*
|
|
* backlight_device->ops_lock is an internal backlight lock protecting the
|
|
* ops pointer and no code outside the core should need to touch it.
|
|
*
|
|
* Access to update_status() is serialised by the update_lock mutex since
|
|
* most drivers seem to need this and historically get it wrong.
|
|
*
|
|
* Most drivers don't need locking on their get_brightness() method.
|
|
* If yours does, you need to implement it in the driver. You can use the
|
|
* update_lock mutex if appropriate.
|
|
*
|
|
* Any other use of the locks below is probably wrong.
|
|
*/
|
|
|
|
enum backlight_update_reason {
|
|
BACKLIGHT_UPDATE_HOTKEY,
|
|
BACKLIGHT_UPDATE_SYSFS,
|
|
};
|
|
|
|
enum backlight_type {
|
|
BACKLIGHT_RAW = 1,
|
|
BACKLIGHT_PLATFORM,
|
|
BACKLIGHT_FIRMWARE,
|
|
BACKLIGHT_TYPE_MAX,
|
|
};
|
|
|
|
enum backlight_notification {
|
|
BACKLIGHT_REGISTERED,
|
|
BACKLIGHT_UNREGISTERED,
|
|
};
|
|
|
|
struct backlight_device;
|
|
struct fb_info;
|
|
#endif
|