1 /* 2 * Copyright 2011-2015, Haiku, Inc. All Rights Reserved. 3 * Distributed under the terms of the MIT License. 4 * 5 * Authors: 6 * Michael Lotz, mmlr@mlotz.ch 7 * Alexander von Gluck IV, kallisti5@unixzen.com 8 */ 9 #ifndef INTEL_PIPE_H 10 #define INTEL_PIPE_H 11 12 13 #include <edid.h> 14 15 #include "intel_extreme.h" 16 17 #include "pll.h" 18 #include "FlexibleDisplayInterface.h" 19 20 21 #define MAX_PIPES 2 22 23 24 void program_pipe_color_modes(uint32 colorMode); 25 26 //class FDILink; 27 //class PanelFitter; 28 29 class Pipe { 30 public: 31 Pipe(pipe_index pipeIndex); 32 ~Pipe(); 33 34 pipe_index Index() 35 { return fPipeIndex; } 36 37 bool IsEnabled(); 38 void Enable(bool enable); 39 void Disable(); 40 41 void Configure(display_mode* mode); 42 void ConfigureTimings(display_mode* mode, 43 bool hardware = true); 44 void ConfigureClocks( 45 const pll_divisors& divisors, 46 uint32 pixelClock, 47 uint32 extraFlags); 48 49 // access to the various parts of the pipe 50 ::FDILink* FDI() 51 { return fFDILink; } 52 // ::PanelFitter* PanelFitter() 53 // { return fPanelFitter; } 54 55 private: 56 void _ConfigureTranscoder(display_mode* mode); 57 58 bool fHasTranscoder; 59 60 FDILink* fFDILink; 61 // PanelFitter* fPanelFitter; 62 63 pipe_index fPipeIndex; 64 65 addr_t fPipeOffset; 66 addr_t fPlaneOffset; 67 }; 68 69 70 #endif // INTEL_PIPE_H 71