From 4c4cf3a38a65617599225cbb8e4820f046c5e311 Mon Sep 17 00:00:00 2001 From: Jonathan Gray Date: Mon, 1 Nov 2021 03:29:54 +0000 Subject: use hw_power to implement power_supply_is_system_supplied() --- sys/dev/pci/drm/include/linux/power_supply.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sys/dev/pci/drm/include/linux/power_supply.h b/sys/dev/pci/drm/include/linux/power_supply.h index 20391f528ae..706363a2f6f 100644 --- a/sys/dev/pci/drm/include/linux/power_supply.h +++ b/sys/dev/pci/drm/include/linux/power_supply.h @@ -6,8 +6,8 @@ static inline int power_supply_is_system_supplied(void) { - /* XXX return 0 if on battery */ - return (1); + extern int hw_power; + return hw_power; } #endif -- cgit v1.2.3