1 /* 2 * Copyright 2006-2011, Haiku, Inc. All Rights Reserved. 3 * Distributed under the terms of the MIT License. 4 * 5 * Authors: 6 * Alexander von Gluck, kallisti5@unixzen.com 7 */ 8 #ifndef RADEON_HD_DISPLAY_H 9 #define RADEON_HD_DISPLAY_H 10 11 12 #include <video_configuration.h> 13 14 15 // convert radeon connector to common connector type 16 const int connector_convert_legacy[] = { 17 VIDEO_CONNECTOR_UNKNOWN, 18 VIDEO_CONNECTOR_VGA, 19 VIDEO_CONNECTOR_DVII, 20 VIDEO_CONNECTOR_DVID, 21 VIDEO_CONNECTOR_DVIA, 22 VIDEO_CONNECTOR_SVIDEO, 23 VIDEO_CONNECTOR_COMPOSITE, 24 VIDEO_CONNECTOR_LVDS, 25 VIDEO_CONNECTOR_UNKNOWN, 26 VIDEO_CONNECTOR_UNKNOWN, 27 VIDEO_CONNECTOR_HDMIA, 28 VIDEO_CONNECTOR_HDMIB, 29 VIDEO_CONNECTOR_UNKNOWN, 30 VIDEO_CONNECTOR_UNKNOWN, 31 VIDEO_CONNECTOR_9DIN, 32 VIDEO_CONNECTOR_DP 33 }; 34 35 const int connector_convert[] = { 36 VIDEO_CONNECTOR_UNKNOWN, 37 VIDEO_CONNECTOR_DVII, 38 VIDEO_CONNECTOR_DVII, 39 VIDEO_CONNECTOR_DVID, 40 VIDEO_CONNECTOR_DVID, 41 VIDEO_CONNECTOR_VGA, 42 VIDEO_CONNECTOR_COMPOSITE, 43 VIDEO_CONNECTOR_SVIDEO, 44 VIDEO_CONNECTOR_UNKNOWN, 45 VIDEO_CONNECTOR_UNKNOWN, 46 VIDEO_CONNECTOR_9DIN, 47 VIDEO_CONNECTOR_UNKNOWN, 48 VIDEO_CONNECTOR_HDMIA, 49 VIDEO_CONNECTOR_HDMIB, 50 VIDEO_CONNECTOR_LVDS, 51 VIDEO_CONNECTOR_9DIN, 52 VIDEO_CONNECTOR_UNKNOWN, 53 VIDEO_CONNECTOR_UNKNOWN, 54 VIDEO_CONNECTOR_UNKNOWN, 55 VIDEO_CONNECTOR_DP, 56 VIDEO_CONNECTOR_EDP, 57 VIDEO_CONNECTOR_UNKNOWN 58 }; 59 60 status_t init_registers(register_info* reg, uint8 crtid); 61 // status_t detect_connectors_legacy(); 62 status_t detect_connectors(); 63 status_t detect_crt_ranges(uint32 crtid); 64 status_t detect_displays(); 65 void debug_displays(); 66 void debug_connectors(); 67 68 uint32 display_get_encoder_mode(uint32 connectorIndex); 69 void display_crtc_lock(uint8 crtcID, int command); 70 void display_crtc_blank(uint8 crtcID, int command); 71 void display_crtc_scale(uint8 crtcID, display_mode *mode); 72 void display_crtc_fb_set(uint8 crtcID, display_mode *mode); 73 void display_crtc_set(uint8 crtcID, display_mode *mode); 74 void display_crtc_set_dtd(uint8 crtcID, display_mode *mode); 75 void display_crtc_power(uint8 crtcID, int command); 76 void display_crtc_memreq(uint8 crtcID, int command); 77 78 79 #endif /* RADEON_HD_DISPLAY_H */ 80