79 lines · c
1/*2 * Copyright 2014 Advanced Micro Devices, Inc.3 *4 * Permission is hereby granted, free of charge, to any person obtaining a5 * copy of this software and associated documentation files (the "Software"),6 * to deal in the Software without restriction, including without limitation7 * the rights to use, copy, modify, merge, publish, distribute, sublicense,8 * and/or sell copies of the Software, and to permit persons to whom the9 * Software is furnished to do so, subject to the following conditions:10 *11 * The above copyright notice and this permission notice shall be included in12 * all copies or substantial portions of the Software.13 *14 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR15 * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,16 * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL17 * THE COPYRIGHT HOLDER(S) OR AUTHOR(S) BE LIABLE FOR ANY CLAIM, DAMAGES OR18 * OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,19 * ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR20 * OTHER DEALINGS IN THE SOFTWARE.21 *22 */23 24#ifndef __ATOMBIOS_ENCODER_H__25#define __ATOMBIOS_ENCODER_H__26 27u828amdgpu_atombios_encoder_get_backlight_level_from_reg(struct amdgpu_device *adev);29void30amdgpu_atombios_encoder_set_backlight_level_to_reg(struct amdgpu_device *adev,31 u8 backlight_level);32u833amdgpu_atombios_encoder_get_backlight_level(struct amdgpu_encoder *amdgpu_encoder);34void35amdgpu_atombios_encoder_set_backlight_level(struct amdgpu_encoder *amdgpu_encoder,36 u8 level);37void amdgpu_atombios_encoder_init_backlight(struct amdgpu_encoder *amdgpu_encoder,38 struct drm_connector *drm_connector);39void40amdgpu_atombios_encoder_fini_backlight(struct amdgpu_encoder *amdgpu_encoder);41bool amdgpu_atombios_encoder_is_digital(struct drm_encoder *encoder);42bool amdgpu_atombios_encoder_mode_fixup(struct drm_encoder *encoder,43 const struct drm_display_mode *mode,44 struct drm_display_mode *adjusted_mode);45int amdgpu_atombios_encoder_get_encoder_mode(struct drm_encoder *encoder);46void47amdgpu_atombios_encoder_setup_dig_encoder(struct drm_encoder *encoder,48 int action, int panel_mode);49void50amdgpu_atombios_encoder_setup_dig_transmitter(struct drm_encoder *encoder, int action,51 uint8_t lane_num, uint8_t lane_set);52bool53amdgpu_atombios_encoder_set_edp_panel_power(struct drm_connector *connector,54 int action);55void56amdgpu_atombios_encoder_dpms(struct drm_encoder *encoder, int mode);57void58amdgpu_atombios_encoder_set_crtc_source(struct drm_encoder *encoder);59void60amdgpu_atombios_encoder_init_dig(struct amdgpu_device *adev);61enum drm_connector_status62amdgpu_atombios_encoder_dac_detect(struct drm_encoder *encoder,63 struct drm_connector *connector);64enum drm_connector_status65amdgpu_atombios_encoder_dig_detect(struct drm_encoder *encoder,66 struct drm_connector *connector);67void68amdgpu_atombios_encoder_setup_ext_encoder_ddc(struct drm_encoder *encoder);69void70amdgpu_atombios_encoder_set_bios_scratch_regs(struct drm_connector *connector,71 struct drm_encoder *encoder,72 bool connected);73struct amdgpu_encoder_atom_dig *74amdgpu_atombios_encoder_get_lcd_info(struct amdgpu_encoder *encoder);75struct amdgpu_encoder_atom_dig *76amdgpu_atombios_encoder_get_dig_info(struct amdgpu_encoder *amdgpu_encoder);77 78#endif79