#include <linux/errno.h> /* for ENODEV */ #include <linux/types.h> /* for bool */
struct acpi_video_brightness_flags {
u8 _BCL_no_ac_battery_levels:1; /* no AC/Battery levels in _BCL */
u8 _BCL_reversed:1; /* _BCL package is in a reversed order */
u8 _BQC_use_index:1; /* _BQC returns an index value */
};
struct acpi_video_device_brightness { int curr; int count; int *levels; struct acpi_video_brightness_flags flags;
};
#if IS_ENABLED(CONFIG_ACPI_VIDEO) externint acpi_video_register(void); externvoid acpi_video_unregister(void); externvoid acpi_video_register_backlight(void); externint acpi_video_get_edid(struct acpi_device *device, int type, int device_id, void **edid); /* * Note: The value returned by acpi_video_handles_brightness_key_presses() * may change over time and should not be cached.
*/ externbool acpi_video_handles_brightness_key_presses(void); externint acpi_video_get_levels(struct acpi_device *device, struct acpi_video_device_brightness **dev_br, int *pmax_level);
/* * This function MUST only be called by GPU drivers to check if the driver * should register a backlight class device. This function not only checks * if a GPU native backlight device should be registered it *also* tells * the ACPI video-detect code that native GPU backlight control is available. * Therefor calling this from any place other then the GPU driver is wrong! * To check if GPU native backlight control is used in other places instead use: * if (acpi_video_get_backlight_type() == acpi_backlight_native) { ... }
*/ staticinlinebool acpi_video_backlight_use_native(void)
{ return __acpi_video_get_backlight_type(true, NULL) == acpi_backlight_native;
} #else staticinlineint acpi_video_register(void) { return -ENODEV; } staticinlinevoid acpi_video_unregister(void) { return; } staticinlinevoid acpi_video_register_backlight(void) { return; } staticinlineint acpi_video_get_edid(struct acpi_device *device, int type, int device_id, void **edid)
{ return -ENODEV;
} staticinlineenum acpi_backlight_type acpi_video_get_backlight_type(void)
{ return acpi_backlight_vendor;
} staticinlinebool acpi_video_backlight_use_native(void)
{ returntrue;
} staticinlinebool acpi_video_handles_brightness_key_presses(void)
{ returnfalse;
} staticinlineint acpi_video_get_levels(struct acpi_device *device, struct acpi_video_device_brightness **dev_br, int *pmax_level)
{ return -ENODEV;
} #endif
#endif
Messung V0.5
¤ Dauer der Verarbeitung: 0.18 Sekunden
(vorverarbeitet)
¤
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.