	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function mtk_dsi_set_mode
_mtk_dsi_set_mode:                      ## @mtk_dsi_set_mode
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	movl	(%rdi), %eax
	movq	_MIPI_DSI_MODE_VIDEO@GOTPCREL(%rip), %rcx
	testl	%eax, (%rcx)
	je	LBB0_1
## %bb.2:
	movq	_MIPI_DSI_MODE_VIDEO_BURST@GOTPCREL(%rip), %rcx
	testl	%eax, (%rcx)
	je	LBB0_4
## %bb.3:
	movq	_BURST_MODE@GOTPCREL(%rip), %rax
	jmp	LBB0_7
LBB0_1:
	movq	_CMD_MODE@GOTPCREL(%rip), %rax
	jmp	LBB0_7
LBB0_4:
	movq	_MIPI_DSI_MODE_VIDEO_SYNC_PULSE@GOTPCREL(%rip), %rcx
	testl	%eax, (%rcx)
	jne	LBB0_5
## %bb.6:
	movq	_SYNC_EVENT_MODE@GOTPCREL(%rip), %rax
	jmp	LBB0_7
LBB0_5:
	movq	_SYNC_PULSE_MODE@GOTPCREL(%rip), %rax
LBB0_7:
	movl	(%rax), %eax
	movq	_DSI_MODE_CTRL@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rsi
	addq	8(%rdi), %rsi
	movl	%eax, %edi
	popq	%rbp
	jmp	_writel                         ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_CMD_MODE,4,2                   ## @CMD_MODE
	.comm	_MIPI_DSI_MODE_VIDEO,4,2        ## @MIPI_DSI_MODE_VIDEO
	.comm	_MIPI_DSI_MODE_VIDEO_BURST,4,2  ## @MIPI_DSI_MODE_VIDEO_BURST
	.comm	_BURST_MODE,4,2                 ## @BURST_MODE
	.comm	_MIPI_DSI_MODE_VIDEO_SYNC_PULSE,4,2 ## @MIPI_DSI_MODE_VIDEO_SYNC_PULSE
	.comm	_SYNC_PULSE_MODE,4,2            ## @SYNC_PULSE_MODE
	.comm	_SYNC_EVENT_MODE,4,2            ## @SYNC_EVENT_MODE
	.comm	_DSI_MODE_CTRL,8,3              ## @DSI_MODE_CTRL
	.no_dead_strip	_mtk_dsi_set_mode
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function mtk_dsi_set_mode
_mtk_dsi_set_mode:                      ; @mtk_dsi_set_mode
	.cfi_startproc
; %bb.0:
	ldr	w8, [x0]
Lloh0:
	adrp	x9, _MIPI_DSI_MODE_VIDEO@GOTPAGE
Lloh1:
	ldr	x9, [x9, _MIPI_DSI_MODE_VIDEO@GOTPAGEOFF]
Lloh2:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_3
; %bb.1:
Lloh3:
	adrp	x9, _MIPI_DSI_MODE_VIDEO_BURST@GOTPAGE
Lloh4:
	ldr	x9, [x9, _MIPI_DSI_MODE_VIDEO_BURST@GOTPAGEOFF]
Lloh5:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_4
; %bb.2:
Lloh6:
	adrp	x8, _BURST_MODE@GOTPAGE
Lloh7:
	ldr	x8, [x8, _BURST_MODE@GOTPAGEOFF]
	b	LBB0_5
LBB0_3:
Lloh8:
	adrp	x8, _CMD_MODE@GOTPAGE
Lloh9:
	ldr	x8, [x8, _CMD_MODE@GOTPAGEOFF]
	b	LBB0_5
LBB0_4:
Lloh10:
	adrp	x9, _MIPI_DSI_MODE_VIDEO_SYNC_PULSE@GOTPAGE
Lloh11:
	ldr	x9, [x9, _MIPI_DSI_MODE_VIDEO_SYNC_PULSE@GOTPAGEOFF]
Lloh12:
	ldr	w9, [x9]
Lloh13:
	adrp	x10, _SYNC_PULSE_MODE@GOTPAGE
Lloh14:
	ldr	x10, [x10, _SYNC_PULSE_MODE@GOTPAGEOFF]
Lloh15:
	adrp	x11, _SYNC_EVENT_MODE@GOTPAGE
Lloh16:
	ldr	x11, [x11, _SYNC_EVENT_MODE@GOTPAGEOFF]
	tst	w9, w8
	csel	x8, x11, x10, eq
LBB0_5:
	ldr	w8, [x8]
	ldr	x9, [x0, #8]
Lloh17:
	adrp	x10, _DSI_MODE_CTRL@GOTPAGE
Lloh18:
	ldr	x10, [x10, _DSI_MODE_CTRL@GOTPAGEOFF]
Lloh19:
	ldr	x10, [x10]
	add	x1, x10, x9
	mov	x0, x8
	b	_writel
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh8, Lloh9
	.loh AdrpLdrGot	Lloh15, Lloh16
	.loh AdrpLdrGot	Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh12
	.loh AdrpLdrGotLdr	Lloh17, Lloh18, Lloh19
	.cfi_endproc
                                        ; -- End function
	.comm	_CMD_MODE,4,2                   ; @CMD_MODE
	.comm	_MIPI_DSI_MODE_VIDEO,4,2        ; @MIPI_DSI_MODE_VIDEO
	.comm	_MIPI_DSI_MODE_VIDEO_BURST,4,2  ; @MIPI_DSI_MODE_VIDEO_BURST
	.comm	_BURST_MODE,4,2                 ; @BURST_MODE
	.comm	_MIPI_DSI_MODE_VIDEO_SYNC_PULSE,4,2 ; @MIPI_DSI_MODE_VIDEO_SYNC_PULSE
	.comm	_SYNC_PULSE_MODE,4,2            ; @SYNC_PULSE_MODE
	.comm	_SYNC_EVENT_MODE,4,2            ; @SYNC_EVENT_MODE
	.comm	_DSI_MODE_CTRL,8,3              ; @DSI_MODE_CTRL
	.no_dead_strip	_mtk_dsi_set_mode
.subsections_via_symbols
