2005-04-17 06:20:36 +08:00
|
|
|
/*
|
|
|
|
* Routines for handling backlight control on PowerBooks
|
|
|
|
*
|
2005-10-11 07:26:48 +08:00
|
|
|
* For now, implementation resides in
|
2006-06-25 20:47:08 +08:00
|
|
|
* arch/powerpc/platforms/powermac/backlight.c
|
2005-04-17 06:20:36 +08:00
|
|
|
*
|
|
|
|
*/
|
2005-10-11 07:26:48 +08:00
|
|
|
#ifndef __ASM_POWERPC_BACKLIGHT_H
|
|
|
|
#define __ASM_POWERPC_BACKLIGHT_H
|
2005-04-17 06:20:36 +08:00
|
|
|
#ifdef __KERNEL__
|
|
|
|
|
2006-06-25 20:47:08 +08:00
|
|
|
#include <linux/fb.h>
|
|
|
|
#include <linux/mutex.h>
|
2005-04-17 06:20:36 +08:00
|
|
|
|
2006-06-25 20:47:08 +08:00
|
|
|
/* For locking instructions, see the implementation file */
|
|
|
|
extern struct backlight_device *pmac_backlight;
|
|
|
|
extern struct mutex pmac_backlight_mutex;
|
2005-04-17 06:20:36 +08:00
|
|
|
|
2006-06-25 20:47:08 +08:00
|
|
|
extern int pmac_backlight_curve_lookup(struct fb_info *info, int value);
|
2005-04-17 06:20:36 +08:00
|
|
|
|
2006-06-25 20:47:08 +08:00
|
|
|
extern int pmac_has_backlight_type(const char *type);
|
|
|
|
|
2006-07-10 19:44:45 +08:00
|
|
|
extern void pmac_backlight_key(int direction);
|
|
|
|
static inline void pmac_backlight_key_up(void)
|
|
|
|
{
|
|
|
|
pmac_backlight_key(0);
|
|
|
|
}
|
|
|
|
static inline void pmac_backlight_key_down(void)
|
|
|
|
{
|
|
|
|
pmac_backlight_key(1);
|
|
|
|
}
|
2006-06-25 20:47:08 +08:00
|
|
|
|
|
|
|
extern int pmac_backlight_set_legacy_brightness(int brightness);
|
|
|
|
extern int pmac_backlight_get_legacy_brightness(void);
|
2005-04-17 06:20:36 +08:00
|
|
|
|
|
|
|
#endif /* __KERNEL__ */
|
2005-10-11 07:26:48 +08:00
|
|
|
#endif
|