List of values like the DRM_MODE_SUBCONNECTOR_xx ones are better represented with enums. Turn the DRM_MODE_SUBCONNECTOR_xx macros into an enum.
Showing the changes to include/uapi/drm (1 of 1 file). Show all
Unified · Split
| @@ -220,14 +220,16 @@ struct drm_mode_get_encoder { · 219 unmodified lines | |||
| 220 | 220 | ||
| 221 | /* This is for connectors with multiple signal types. */ | 221 | /* This is for connectors with multiple signal types. */ |
| 222 | /* Try to match DRM_MODE_CONNECTOR_X as closely as possible. */ | 222 | /* Try to match DRM_MODE_CONNECTOR_X as closely as possible. */ |
| 223 | #define DRM_MODE_SUBCONNECTOR_Automatic 0 | 223 | enum drm_mode_subconnector { |
| 224 | #define DRM_MODE_SUBCONNECTOR_Unknown 0 | 224 | DRM_MODE_SUBCONNECTOR_Automatic = 0, |
| 225 | #define DRM_MODE_SUBCONNECTOR_DVID 3 | 225 | DRM_MODE_SUBCONNECTOR_Unknown = 0, |
| 226 | #define DRM_MODE_SUBCONNECTOR_DVIA 4 | 226 | DRM_MODE_SUBCONNECTOR_DVID = 3, |
| 227 | #define DRM_MODE_SUBCONNECTOR_Composite 5 | 227 | DRM_MODE_SUBCONNECTOR_DVIA = 4, |
| 228 | #define DRM_MODE_SUBCONNECTOR_SVIDEO 6 | 228 | DRM_MODE_SUBCONNECTOR_Composite = 5, |
| 229 | #define DRM_MODE_SUBCONNECTOR_Component 8 | 229 | DRM_MODE_SUBCONNECTOR_SVIDEO = 6, |
| 230 | #define DRM_MODE_SUBCONNECTOR_SCART 9 | 230 | DRM_MODE_SUBCONNECTOR_Component = 8, |
| 231 | DRM_MODE_SUBCONNECTOR_SCART = 9, | ||
| 232 | }; | ||
| 231 | 233 | ||
| 232 | #define DRM_MODE_CONNECTOR_Unknown 0 | 234 | #define DRM_MODE_CONNECTOR_Unknown 0 |
| 233 | #define DRM_MODE_CONNECTOR_VGA 1 | 235 | #define DRM_MODE_CONNECTOR_VGA 1 |