	.file	"extr_intel_ddi.c_icl_program_mg_dp_mode.c"
	.intel_syntax noprefix
	.text
	.p2align 4
	.type	icl_program_mg_dp_mode, @function
icl_program_mg_dp_mode:
.LFB0:
	.cfi_startproc
	endbr64
	push	r14
	.cfi_def_cfa_offset 16
	.cfi_offset 14, -16
	push	r13
	.cfi_def_cfa_offset 24
	.cfi_offset 13, -24
	push	r12
	.cfi_def_cfa_offset 32
	.cfi_offset 12, -32
	push	rbp
	.cfi_def_cfa_offset 40
	.cfi_offset 6, -40
	mov	rbp, rdi
	sub	rsp, 8
	.cfi_def_cfa_offset 48
	mov	edi, DWORD PTR 8[rdi]
	call	to_i915@PLT
	mov	eax, DWORD PTR TC_PORT_TBT_ALT[rip]
	cmp	DWORD PTR 0[rbp], eax
	je	.L1
	mov	r13d, DWORD PTR 4[rbp]
	xor	edi, edi
	mov	esi, r13d
	call	MG_DP_MODE@PLT
	mov	edi, eax
	call	I915_READ@PLT
	mov	esi, r13d
	mov	edi, 1
	mov	r14d, eax
	call	MG_DP_MODE@PLT
	mov	edi, eax
	call	I915_READ@PLT
	mov	edi, DWORD PTR 0[rbp]
	cmp	edi, 128
	je	.L3
	cmp	edi, 129
	je	.L15
	add	rsp, 8
	.cfi_remember_state
	.cfi_def_cfa_offset 40
	pop	rbp
	.cfi_def_cfa_offset 32
	pop	r12
	.cfi_def_cfa_offset 24
	pop	r13
	.cfi_def_cfa_offset 16
	pop	r14
	.cfi_def_cfa_offset 8
	jmp	MISSING_CASE@PLT
	.p2align 4,,10
	.p2align 3
.L15:
	.cfi_restore_state
	mov	r12d, DWORD PTR MG_DP_MODE_CFG_DP_X1_MODE[rip]
	or	r12d, DWORD PTR MG_DP_MODE_CFG_DP_X2_MODE[rip]
	mov	rdi, rbp
	not	r12d
	and	r14d, r12d
	and	r12d, eax
	call	intel_tc_port_get_lane_mask@PLT
	mov	edi, eax
	cmp	eax, 15
	ja	.L5
	lea	rcx, .L7[rip]
	mov	edx, eax
	movsx	rax, DWORD PTR [rcx+rdx*4]
	add	rax, rcx
	notrack jmp	rax
	.section	.rodata
	.align 4
	.align 4
.L7:
	.long	.L5-.L7
	.long	.L10-.L7
	.long	.L12-.L7
	.long	.L11-.L7
	.long	.L10-.L7
	.long	.L5-.L7
	.long	.L5-.L7
	.long	.L5-.L7
	.long	.L9-.L7
	.long	.L5-.L7
	.long	.L5-.L7
	.long	.L5-.L7
	.long	.L8-.L7
	.long	.L5-.L7
	.long	.L5-.L7
	.long	.L6-.L7
	.text
	.p2align 4,,10
	.p2align 3
.L3:
	mov	r12d, DWORD PTR MG_DP_MODE_CFG_DP_X1_MODE[rip]
	or	r12d, DWORD PTR MG_DP_MODE_CFG_DP_X2_MODE[rip]
	or	r14d, r12d
	or	r12d, eax
.L10:
	mov	esi, r13d
	xor	edi, edi
	call	MG_DP_MODE@PLT
	mov	esi, r14d
	mov	edi, eax
	call	I915_WRITE@PLT
	mov	esi, r13d
	mov	edi, 1
	call	MG_DP_MODE@PLT
	add	rsp, 8
	.cfi_remember_state
	.cfi_def_cfa_offset 40
	mov	esi, r12d
	pop	rbp
	.cfi_def_cfa_offset 32
	mov	edi, eax
	pop	r12
	.cfi_def_cfa_offset 24
	pop	r13
	.cfi_def_cfa_offset 16
	pop	r14
	.cfi_def_cfa_offset 8
	jmp	I915_WRITE@PLT
	.p2align 4,,10
	.p2align 3
.L1:
	.cfi_restore_state
	add	rsp, 8
	.cfi_remember_state
	.cfi_def_cfa_offset 40
	pop	rbp
	.cfi_def_cfa_offset 32
	pop	r12
	.cfi_def_cfa_offset 24
	pop	r13
	.cfi_def_cfa_offset 16
	pop	r14
	.cfi_def_cfa_offset 8
	ret
	.p2align 4,,10
	.p2align 3
.L5:
	.cfi_restore_state
	call	MISSING_CASE@PLT
	jmp	.L10
	.p2align 4,,10
	.p2align 3
.L6:
	mov	eax, DWORD PTR MG_DP_MODE_CFG_DP_X1_MODE[rip]
	or	eax, DWORD PTR MG_DP_MODE_CFG_DP_X2_MODE[rip]
	or	r14d, eax
	or	r12d, eax
	jmp	.L10
	.p2align 4,,10
	.p2align 3
.L8:
	mov	eax, DWORD PTR MG_DP_MODE_CFG_DP_X1_MODE[rip]
	or	eax, DWORD PTR MG_DP_MODE_CFG_DP_X2_MODE[rip]
	or	r12d, eax
	jmp	.L10
	.p2align 4,,10
	.p2align 3
.L9:
	or	r12d, DWORD PTR MG_DP_MODE_CFG_DP_X1_MODE[rip]
	jmp	.L10
	.p2align 4,,10
	.p2align 3
.L11:
	mov	eax, DWORD PTR MG_DP_MODE_CFG_DP_X1_MODE[rip]
	or	eax, DWORD PTR MG_DP_MODE_CFG_DP_X2_MODE[rip]
	or	r14d, eax
	jmp	.L10
	.p2align 4,,10
	.p2align 3
.L12:
	or	r14d, DWORD PTR MG_DP_MODE_CFG_DP_X1_MODE[rip]
	jmp	.L10
	.cfi_endproc
.LFE0:
	.size	icl_program_mg_dp_mode, .-icl_program_mg_dp_mode
	.comm	TC_PORT_TBT_ALT,4,4
	.comm	MG_DP_MODE_CFG_DP_X2_MODE,4,4
	.comm	MG_DP_MODE_CFG_DP_X1_MODE,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",@progbits
	.section	.note.gnu.property,"a"
	.align 8
	.long	 1f - 0f
	.long	 4f - 1f
	.long	 5
0:
	.string	 "GNU"
1:
	.align 8
	.long	 0xc0000002
	.long	 3f - 2f
2:
	.long	 0x3
3:
	.align 8
4:

	.arch armv5t
	.eabi_attribute 20, 1
	.eabi_attribute 21, 1
	.eabi_attribute 23, 3
	.eabi_attribute 24, 1
	.eabi_attribute 25, 1
	.eabi_attribute 26, 2
	.eabi_attribute 30, 2
	.eabi_attribute 34, 0
	.eabi_attribute 18, 4
	.file	"extr_intel_ddi.c_icl_program_mg_dp_mode.c"
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	icl_program_mg_dp_mode, %function
icl_program_mg_dp_mode:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 0, uses_anonymous_args = 0
	push	{r4, r5, r6, r7, r8, lr}
	mov	r4, r0
	ldr	r0, [r0, #8]
	bl	to_i915
	ldr	r3, .L16
	ldr	r2, [r4]
	ldr	r3, [r3]
	cmp	r2, r3
	popeq	{r4, r5, r6, r7, r8, pc}
	ldr	r6, [r4, #4]
	mov	r0, #0
	mov	r1, r6
	bl	MG_DP_MODE
	bl	I915_READ
	mov	r1, r6
	mov	r5, r0
	mov	r0, #1
	bl	MG_DP_MODE
	bl	I915_READ
	ldr	r3, [r4]
	mov	r1, r0
	cmp	r3, #128
	beq	.L3
	cmp	r3, #129
	beq	.L15
	pop	{r4, r5, r6, r7, r8, lr}
	mov	r0, r3
	b	MISSING_CASE
.L15:
	ldr	r7, .L16+4
	ldr	r8, .L16+8
	ldr	r2, [r7]
	ldr	r3, [r8]
	mov	r0, r4
	orr	r2, r2, r3
	bic	r5, r5, r2
	bic	r4, r1, r2
	bl	intel_tc_port_get_lane_mask
	sub	r3, r0, #1
	cmp	r3, #14
	ldrls	pc, [pc, r3, asl #2]
	b	.L5
.L7:
	.word	.L10
	.word	.L12
	.word	.L11
	.word	.L10
	.word	.L5
	.word	.L5
	.word	.L5
	.word	.L9
	.word	.L5
	.word	.L5
	.word	.L5
	.word	.L8
	.word	.L5
	.word	.L5
	.word	.L6
.L3:
	ldr	r2, .L16+4
	ldr	r3, .L16+8
	ldr	r0, [r2]
	ldr	r4, [r3]
	orr	r0, r0, r4
	orr	r5, r0, r5
	orr	r4, r0, r1
.L10:
	mov	r1, r6
	mov	r0, #0
	bl	MG_DP_MODE
	mov	r1, r5
	bl	I915_WRITE
	mov	r1, r6
	mov	r0, #1
	bl	MG_DP_MODE
	mov	r1, r4
	pop	{r4, r5, r6, r7, r8, lr}
	b	I915_WRITE
.L5:
	bl	MISSING_CASE
	b	.L10
.L12:
	ldr	r3, [r7]
	orr	r5, r5, r3
	b	.L10
.L11:
	ldr	r3, [r7]
	ldr	r2, [r8]
	orr	r3, r3, r2
	orr	r5, r5, r3
	b	.L10
.L9:
	ldr	r3, [r7]
	orr	r4, r4, r3
	b	.L10
.L8:
	ldr	r3, [r7]
	ldr	r2, [r8]
	orr	r3, r3, r2
	orr	r4, r4, r3
	b	.L10
.L6:
	ldr	r3, [r7]
	ldr	r2, [r8]
	orr	r3, r3, r2
	orr	r5, r5, r3
	orr	r4, r4, r3
	b	.L10
.L17:
	.align	2
.L16:
	.word	TC_PORT_TBT_ALT
	.word	MG_DP_MODE_CFG_DP_X1_MODE
	.word	MG_DP_MODE_CFG_DP_X2_MODE
	.size	icl_program_mg_dp_mode, .-icl_program_mg_dp_mode
	.comm	TC_PORT_TBT_ALT,4,4
	.comm	MG_DP_MODE_CFG_DP_X2_MODE,4,4
	.comm	MG_DP_MODE_CFG_DP_X1_MODE,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
