Commit 2eb82aaa authored by Rodrigo Siqueira's avatar Rodrigo Siqueira Committed by Alex Deucher
Browse files

drm/amd/display: Remove unused code



Remove some code that is never used from freesync file.

Tested-by: default avatarDaniel Wheeler <Daniel.Wheeler@amd.com>
Signed-off-by: default avatarRodrigo Siqueira <Rodrigo.Siqueira@amd.com>
Signed-off-by: default avatarAlex Deucher <alexander.deucher@amd.com>
parent 3351ce5d
Loading
Loading
Loading
Loading
+0 −44
Original line number Diff line number Diff line
@@ -898,35 +898,9 @@ static void build_vrr_infopacket_v2(enum signal_type signal,

	infopacket->valid = true;
}
#ifndef TRIM_FSFT
static void build_vrr_infopacket_fast_transport_data(
	bool ftActive,
	unsigned int ftOutputRate,
	struct dc_info_packet *infopacket)
{
	/* PB9 : bit7 - fast transport Active*/
	unsigned char activeBit = (ftActive) ? 1 << 7 : 0;

	infopacket->sb[1] &= ~activeBit;  //clear bit
	infopacket->sb[1] |=  activeBit;  //set bit

	/* PB13 : Target Output Pixel Rate [kHz] - bits 7:0  */
	infopacket->sb[13] = ftOutputRate & 0xFF;

	/* PB14 : Target Output Pixel Rate [kHz] - bits 15:8  */
	infopacket->sb[14] = (ftOutputRate >> 8) & 0xFF;

	/* PB15 : Target Output Pixel Rate [kHz] - bits 23:16  */
	infopacket->sb[15] = (ftOutputRate >> 16) & 0xFF;

}
#endif

static void build_vrr_infopacket_v3(enum signal_type signal,
		const struct mod_vrr_params *vrr,
#ifndef TRIM_FSFT
		bool ftActive, unsigned int ftOutputRate,
#endif
		enum color_transfer_func app_tf,
		struct dc_info_packet *infopacket)
{
@@ -937,13 +911,6 @@ static void build_vrr_infopacket_v3(enum signal_type signal,

	build_vrr_infopacket_fs2_data(app_tf, infopacket);

#ifndef TRIM_FSFT
	build_vrr_infopacket_fast_transport_data(
			ftActive,
			ftOutputRate,
			infopacket);
#endif

	build_vrr_infopacket_checksum(&payload_size, infopacket);

	infopacket->valid = true;
@@ -985,18 +952,7 @@ void mod_freesync_build_vrr_infopacket(struct mod_freesync *mod_freesync,

	switch (packet_type) {
	case PACKET_TYPE_FS_V3:
#ifndef TRIM_FSFT
		// always populate with pixel rate.
		build_vrr_infopacket_v3(
				stream->signal, vrr,
				stream->timing.flags.FAST_TRANSPORT,
				(stream->timing.flags.FAST_TRANSPORT) ?
						stream->timing.fast_transport_output_rate_100hz :
						stream->timing.pix_clk_100hz,
				app_tf, infopacket);
#else
		build_vrr_infopacket_v3(stream->signal, vrr, app_tf, infopacket);
#endif
		break;
	case PACKET_TYPE_FS_V2:
		build_vrr_infopacket_v2(stream->signal, vrr, app_tf, infopacket, stream->freesync_on_desktop);