	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_analogix_dp_config_video_slave_mode ## -- Begin function analogix_dp_config_video_slave_mode
	.p2align	4, 0x90
_analogix_dp_config_video_slave_mode:   ## @analogix_dp_config_video_slave_mode
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%r15
	pushq	%r14
	pushq	%rbx
	pushq	%rax
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %rbx
	movq	_ANALOGIX_DP_FUNC_EN_1@GOTPCREL(%rip), %r15
	movq	(%r15), %rdi
	addq	(%rbx), %rdi
	callq	_readl
	movl	%eax, %r14d
	movq	24(%rbx), %rax
	testq	%rax, %rax
	je	LBB0_3
## %bb.1:
	movl	(%rax), %edi
	callq	_is_rockchip
	testq	%rax, %rax
	je	LBB0_3
## %bb.2:
	movq	_RK_VID_CAP_FUNC_EN_N@GOTPCREL(%rip), %rax
	movq	_RK_VID_FIFO_FUNC_EN_N@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	orl	(%rax), %ecx
	notl	%ecx
	andl	%ecx, %r14d
	jmp	LBB0_4
LBB0_3:
	movq	_MASTER_VID_FUNC_EN_N@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movq	_SLAVE_VID_FUNC_EN_N@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	orl	%eax, %ecx
	notl	%ecx
	andl	%ecx, %r14d
	orl	%eax, %r14d
LBB0_4:
	movq	(%r15), %rsi
	addq	(%rbx), %rsi
	movl	%r14d, %edi
	callq	_writel
	movq	_ANALOGIX_DP_VIDEO_CTL_10@GOTPCREL(%rip), %r14
	movq	(%r14), %rdi
	addq	(%rbx), %rdi
	callq	_readl
	movq	_INTERACE_SCAN_CFG@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	notl	%ecx
	andl	%eax, %ecx
	movl	8(%rbx), %edi
	shll	$2, %edi
	orl	%ecx, %edi
	movq	(%r14), %rsi
	addq	(%rbx), %rsi
	callq	_writel
	movq	(%r14), %rdi
	addq	(%rbx), %rdi
	callq	_readl
	movq	_VSYNC_POLARITY_CFG@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	notl	%ecx
	andl	%eax, %ecx
	movl	12(%rbx), %edi
	addl	%edi, %edi
	orl	%ecx, %edi
	movq	(%r14), %rsi
	addq	(%rbx), %rsi
	callq	_writel
	movq	(%r14), %rdi
	addq	(%rbx), %rdi
	callq	_readl
	movq	_HSYNC_POLARITY_CFG@GOTPCREL(%rip), %rcx
	movl	(%rcx), %edi
	notl	%edi
	andl	%eax, %edi
	orl	16(%rbx), %edi
	movq	(%r14), %rsi
	addq	(%rbx), %rsi
	callq	_writel
	movq	_AUDIO_MODE_SPDIF_MODE@GOTPCREL(%rip), %rax
	movq	_VIDEO_MODE_SLAVE_MODE@GOTPCREL(%rip), %rcx
	movl	(%rcx), %edi
	orl	(%rax), %edi
	movq	_ANALOGIX_DP_SOC_GENERAL_CTL@GOTPCREL(%rip), %rax
	movq	(%rax), %rsi
	addq	(%rbx), %rsi
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_writel                         ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_ANALOGIX_DP_FUNC_EN_1,8,3      ## @ANALOGIX_DP_FUNC_EN_1
	.comm	_RK_VID_CAP_FUNC_EN_N,4,2       ## @RK_VID_CAP_FUNC_EN_N
	.comm	_RK_VID_FIFO_FUNC_EN_N,4,2      ## @RK_VID_FIFO_FUNC_EN_N
	.comm	_MASTER_VID_FUNC_EN_N,4,2       ## @MASTER_VID_FUNC_EN_N
	.comm	_SLAVE_VID_FUNC_EN_N,4,2        ## @SLAVE_VID_FUNC_EN_N
	.comm	_ANALOGIX_DP_VIDEO_CTL_10,8,3   ## @ANALOGIX_DP_VIDEO_CTL_10
	.comm	_INTERACE_SCAN_CFG,4,2          ## @INTERACE_SCAN_CFG
	.comm	_VSYNC_POLARITY_CFG,4,2         ## @VSYNC_POLARITY_CFG
	.comm	_HSYNC_POLARITY_CFG,4,2         ## @HSYNC_POLARITY_CFG
	.comm	_AUDIO_MODE_SPDIF_MODE,4,2      ## @AUDIO_MODE_SPDIF_MODE
	.comm	_VIDEO_MODE_SLAVE_MODE,4,2      ## @VIDEO_MODE_SLAVE_MODE
	.comm	_ANALOGIX_DP_SOC_GENERAL_CTL,8,3 ## @ANALOGIX_DP_SOC_GENERAL_CTL
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_analogix_dp_config_video_slave_mode ; -- Begin function analogix_dp_config_video_slave_mode
	.p2align	2
_analogix_dp_config_video_slave_mode:   ; @analogix_dp_config_video_slave_mode
	.cfi_startproc
; %bb.0:
	stp	x22, x21, [sp, #-48]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 48
	stp	x20, x19, [sp, #16]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #32]             ; 16-byte Folded Spill
	add	x29, sp, #32
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	.cfi_offset w21, -40
	.cfi_offset w22, -48
	mov	x19, x0
	ldr	x8, [x0]
Lloh0:
	adrp	x21, _ANALOGIX_DP_FUNC_EN_1@GOTPAGE
Lloh1:
	ldr	x21, [x21, _ANALOGIX_DP_FUNC_EN_1@GOTPAGEOFF]
	ldr	x9, [x21]
	add	x0, x9, x8
	bl	_readl
	mov	x20, x0
	ldr	x8, [x19, #24]
	cbz	x8, LBB0_3
; %bb.1:
	ldr	w0, [x8]
	bl	_is_rockchip
	cbz	x0, LBB0_3
; %bb.2:
Lloh2:
	adrp	x8, _RK_VID_CAP_FUNC_EN_N@GOTPAGE
Lloh3:
	ldr	x8, [x8, _RK_VID_CAP_FUNC_EN_N@GOTPAGEOFF]
Lloh4:
	ldr	w8, [x8]
Lloh5:
	adrp	x9, _RK_VID_FIFO_FUNC_EN_N@GOTPAGE
Lloh6:
	ldr	x9, [x9, _RK_VID_FIFO_FUNC_EN_N@GOTPAGEOFF]
Lloh7:
	ldr	w9, [x9]
	orr	w8, w9, w8
	bic	w0, w20, w8
	b	LBB0_4
LBB0_3:
Lloh8:
	adrp	x8, _MASTER_VID_FUNC_EN_N@GOTPAGE
Lloh9:
	ldr	x8, [x8, _MASTER_VID_FUNC_EN_N@GOTPAGEOFF]
Lloh10:
	ldr	w8, [x8]
Lloh11:
	adrp	x9, _SLAVE_VID_FUNC_EN_N@GOTPAGE
Lloh12:
	ldr	x9, [x9, _SLAVE_VID_FUNC_EN_N@GOTPAGEOFF]
Lloh13:
	ldr	w9, [x9]
	orr	w9, w9, w8
	bic	w9, w20, w9
	orr	w0, w9, w8
LBB0_4:
	ldr	x8, [x19]
	ldr	x9, [x21]
	add	x1, x9, x8
	bl	_writel
	ldr	x8, [x19]
Lloh14:
	adrp	x20, _ANALOGIX_DP_VIDEO_CTL_10@GOTPAGE
Lloh15:
	ldr	x20, [x20, _ANALOGIX_DP_VIDEO_CTL_10@GOTPAGEOFF]
	ldr	x9, [x20]
	add	x0, x9, x8
	bl	_readl
Lloh16:
	adrp	x8, _INTERACE_SCAN_CFG@GOTPAGE
Lloh17:
	ldr	x8, [x8, _INTERACE_SCAN_CFG@GOTPAGEOFF]
Lloh18:
	ldr	w8, [x8]
	bic	w8, w0, w8
	ldr	w9, [x19, #8]
	orr	w0, w8, w9, lsl #2
	ldr	x8, [x19]
	ldr	x9, [x20]
	add	x1, x9, x8
	bl	_writel
	ldr	x8, [x19]
	ldr	x9, [x20]
	add	x0, x9, x8
	bl	_readl
Lloh19:
	adrp	x8, _VSYNC_POLARITY_CFG@GOTPAGE
Lloh20:
	ldr	x8, [x8, _VSYNC_POLARITY_CFG@GOTPAGEOFF]
Lloh21:
	ldr	w8, [x8]
	bic	w8, w0, w8
	ldr	w9, [x19, #12]
	orr	w0, w8, w9, lsl #1
	ldr	x8, [x19]
	ldr	x9, [x20]
	add	x1, x9, x8
	bl	_writel
	ldr	x8, [x19]
	ldr	x9, [x20]
	add	x0, x9, x8
	bl	_readl
Lloh22:
	adrp	x8, _HSYNC_POLARITY_CFG@GOTPAGE
Lloh23:
	ldr	x8, [x8, _HSYNC_POLARITY_CFG@GOTPAGEOFF]
Lloh24:
	ldr	w8, [x8]
	bic	w8, w0, w8
	ldr	w9, [x19, #16]
	orr	w0, w8, w9
	ldr	x8, [x19]
	ldr	x9, [x20]
	add	x1, x9, x8
	bl	_writel
Lloh25:
	adrp	x8, _AUDIO_MODE_SPDIF_MODE@GOTPAGE
Lloh26:
	ldr	x8, [x8, _AUDIO_MODE_SPDIF_MODE@GOTPAGEOFF]
Lloh27:
	ldr	w8, [x8]
Lloh28:
	adrp	x9, _VIDEO_MODE_SLAVE_MODE@GOTPAGE
Lloh29:
	ldr	x9, [x9, _VIDEO_MODE_SLAVE_MODE@GOTPAGEOFF]
Lloh30:
	ldr	w9, [x9]
	orr	w0, w9, w8
	ldr	x8, [x19]
Lloh31:
	adrp	x9, _ANALOGIX_DP_SOC_GENERAL_CTL@GOTPAGE
Lloh32:
	ldr	x9, [x9, _ANALOGIX_DP_SOC_GENERAL_CTL@GOTPAGEOFF]
Lloh33:
	ldr	x9, [x9]
	add	x1, x9, x8
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp], #48             ; 16-byte Folded Reload
	b	_writel
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh31, Lloh32, Lloh33
	.loh AdrpLdrGotLdr	Lloh28, Lloh29, Lloh30
	.loh AdrpLdrGotLdr	Lloh25, Lloh26, Lloh27
	.loh AdrpLdrGotLdr	Lloh22, Lloh23, Lloh24
	.loh AdrpLdrGotLdr	Lloh19, Lloh20, Lloh21
	.loh AdrpLdrGotLdr	Lloh16, Lloh17, Lloh18
	.loh AdrpLdrGot	Lloh14, Lloh15
	.cfi_endproc
                                        ; -- End function
	.comm	_ANALOGIX_DP_FUNC_EN_1,8,3      ; @ANALOGIX_DP_FUNC_EN_1
	.comm	_RK_VID_CAP_FUNC_EN_N,4,2       ; @RK_VID_CAP_FUNC_EN_N
	.comm	_RK_VID_FIFO_FUNC_EN_N,4,2      ; @RK_VID_FIFO_FUNC_EN_N
	.comm	_MASTER_VID_FUNC_EN_N,4,2       ; @MASTER_VID_FUNC_EN_N
	.comm	_SLAVE_VID_FUNC_EN_N,4,2        ; @SLAVE_VID_FUNC_EN_N
	.comm	_ANALOGIX_DP_VIDEO_CTL_10,8,3   ; @ANALOGIX_DP_VIDEO_CTL_10
	.comm	_INTERACE_SCAN_CFG,4,2          ; @INTERACE_SCAN_CFG
	.comm	_VSYNC_POLARITY_CFG,4,2         ; @VSYNC_POLARITY_CFG
	.comm	_HSYNC_POLARITY_CFG,4,2         ; @HSYNC_POLARITY_CFG
	.comm	_AUDIO_MODE_SPDIF_MODE,4,2      ; @AUDIO_MODE_SPDIF_MODE
	.comm	_VIDEO_MODE_SLAVE_MODE,4,2      ; @VIDEO_MODE_SLAVE_MODE
	.comm	_ANALOGIX_DP_SOC_GENERAL_CTL,8,3 ; @ANALOGIX_DP_SOC_GENERAL_CTL
.subsections_via_symbols
