1 /* 2 * Copyright 2005-2009, Axel Dörfler, axeld@pinc-software.de. 3 * Distributed under the terms of the MIT License. 4 */ 5 6 7 #include <errno.h> 8 9 #include "accelerant_protos.h" 10 #include "accelerant.h" 11 12 13 uint32 14 vesa_dpms_capabilities(void) 15 { 16 return gInfo->shared_info->dpms_capabilities; 17 } 18 19 20 uint32 21 vesa_dpms_mode(void) 22 { 23 uint32 mode; 24 if (ioctl(gInfo->device, VESA_GET_DPMS_MODE, &mode, sizeof(mode)) != 0) 25 return B_DPMS_ON; 26 27 return mode; 28 } 29 30 31 status_t 32 vesa_set_dpms_mode(uint32 mode) 33 { 34 if (ioctl(gInfo->device, VESA_SET_DPMS_MODE, &mode, sizeof(mode)) != 0) 35 return errno; 36 37 return B_OK; 38 } 39 40