BTRFS: Implement BTree::Path and change _Find.
[haiku.git] / src / add-ons / accelerants / intel_810 / hooks.cpp
blob3bd4481301930763880b510b4e622e2a2a6038de
1 /*
2 * Copyright 2008-2012 Haiku, Inc. All rights reserved.
3 * Distributed under the terms of the MIT license.
5 * Authors:
6 * Gerald Zajac
7 */
10 #include "accelerant.h"
13 extern "C" void*
14 get_accelerant_hook(uint32 feature, void* data)
16 (void)data;
17 // avoid compiler warning for unused arg
19 switch (feature) {
20 // General
21 case B_INIT_ACCELERANT:
22 return (void*)InitAccelerant;
23 case B_UNINIT_ACCELERANT:
24 return (void*)UninitAccelerant;
25 case B_CLONE_ACCELERANT:
26 return (void*)CloneAccelerant;
27 case B_ACCELERANT_CLONE_INFO_SIZE:
28 return (void*)AccelerantCloneInfoSize;
29 case B_GET_ACCELERANT_CLONE_INFO:
30 return (void*)GetAccelerantCloneInfo;
31 case B_GET_ACCELERANT_DEVICE_INFO:
32 return (void*)GetAccelerantDeviceInfo;
33 case B_ACCELERANT_RETRACE_SEMAPHORE:
34 return NULL;
36 // Mode Configuration
37 case B_ACCELERANT_MODE_COUNT:
38 return (void*)AccelerantModeCount;
39 case B_GET_MODE_LIST:
40 return (void*)GetModeList;
41 case B_PROPOSE_DISPLAY_MODE:
42 return (void*)ProposeDisplayMode;
43 case B_SET_DISPLAY_MODE:
44 return (void*)SetDisplayMode;
45 case B_GET_DISPLAY_MODE:
46 return (void*)GetDisplayMode;
47 #ifdef __HAIKU__
48 case B_GET_EDID_INFO:
49 return (void*)GetEdidInfo;
50 #endif
51 case B_GET_FRAME_BUFFER_CONFIG:
52 return (void*)GetFrameBufferConfig;
53 case B_GET_PIXEL_CLOCK_LIMITS:
54 return (void*)GetPixelClockLimits;
55 case B_MOVE_DISPLAY:
56 return (void*)MoveDisplay;
57 case B_SET_INDEXED_COLORS:
58 return (void*)(I810_SetIndexedColors);
59 case B_GET_TIMING_CONSTRAINTS:
60 return NULL;
62 // DPMS
63 case B_DPMS_CAPABILITIES:
64 return (void*)(I810_DPMSCapabilities);
65 case B_DPMS_MODE:
66 return (void*)(I810_GetDPMSMode);
67 case B_SET_DPMS_MODE:
68 return (void*)(I810_SetDPMSMode);
70 // Engine Management
71 case B_ACCELERANT_ENGINE_COUNT:
72 return (void*)AccelerantEngineCount;
73 case B_ACQUIRE_ENGINE:
74 return (void*)AcquireEngine;
75 case B_RELEASE_ENGINE:
76 return (void*)ReleaseEngine;
77 case B_WAIT_ENGINE_IDLE:
78 return (void*)WaitEngineIdle;
79 case B_GET_SYNC_TOKEN:
80 return (void*)GetSyncToken;
81 case B_SYNC_TO_TOKEN:
82 return (void*)SyncToToken;
85 return NULL; // Return null pointer for any feature not handled above