	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function dpu_mdss_destroy
_dpu_mdss_destroy:                      ## @dpu_mdss_destroy
	.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	%r13
	pushq	%r12
	pushq	%rbx
	pushq	%rax
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %r15
	movl	(%rdi), %edi
	callq	_to_platform_device
	movq	%rax, %r14
	movq	8(%r15), %r12
	movq	(%r12), %rdi
	callq	_to_dpu_mdss
	movq	%rax, %r13
	movl	(%r15), %edi
	callq	_pm_runtime_suspend
	movl	(%r15), %edi
	callq	_pm_runtime_disable
	movq	%r13, %rdi
	callq	__dpu_mdss_irq_domain_fini
	movq	%r14, %rdi
	xorl	%esi, %esi
	callq	_platform_get_irq
	movl	%eax, %edi
	xorl	%esi, %esi
	xorl	%edx, %edx
	callq	_irq_set_chained_handler_and_data
	movl	24(%r13), %edi
	movl	28(%r13), %esi
	callq	_msm_dss_put_clk
	movl	24(%r13), %esi
	movq	%r14, %rdi
	callq	_devm_kfree
	cmpl	$0, (%r13)
	jle	LBB0_3
## %bb.1:
	xorl	%ebx, %ebx
	.p2align	4, 0x90
LBB0_2:                                 ## =>This Inner Loop Header: Depth=1
	movq	16(%r13), %rax
	movl	(%rax,%rbx,4), %edi
	callq	_icc_put
	incq	%rbx
	movslq	(%r13), %rax
	cmpq	%rax, %rbx
	jl	LBB0_2
LBB0_3:
	movq	8(%r13), %rsi
	testq	%rsi, %rsi
	je	LBB0_5
## %bb.4:
	movq	%r14, %rdi
	callq	_devm_iounmap
LBB0_5:
	movq	$0, 8(%r13)
	movq	$0, (%r12)
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.no_dead_strip	_dpu_mdss_destroy
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function dpu_mdss_destroy
_dpu_mdss_destroy:                      ; @dpu_mdss_destroy
	.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	x21, x0
	ldr	w0, [x0]
	bl	_to_platform_device
	mov	x19, x0
	ldr	x22, [x21, #8]
	ldr	x0, [x22]
	bl	_to_dpu_mdss
	mov	x20, x0
	ldr	w0, [x21]
	bl	_pm_runtime_suspend
	ldr	w0, [x21]
	bl	_pm_runtime_disable
	mov	x0, x20
	bl	__dpu_mdss_irq_domain_fini
	mov	x0, x19
	mov	w1, #0
	bl	_platform_get_irq
	mov	x1, #0
	mov	x2, #0
	bl	_irq_set_chained_handler_and_data
	ldp	w0, w1, [x20, #24]
	bl	_msm_dss_put_clk
	ldr	w1, [x20, #24]
	mov	x0, x19
	bl	_devm_kfree
	ldr	w8, [x20]
	cmp	w8, #1
	b.lt	LBB0_3
; %bb.1:
	mov	x21, #0
LBB0_2:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x8, [x20, #16]
	ldr	w0, [x8, x21, lsl #2]
	bl	_icc_put
	add	x21, x21, #1
	ldrsw	x8, [x20]
	cmp	x21, x8
	b.lt	LBB0_2
LBB0_3:
	ldr	x1, [x20, #8]
	cbz	x1, LBB0_5
; %bb.4:
	mov	x0, x19
	bl	_devm_iounmap
LBB0_5:
	str	xzr, [x20, #8]
	str	xzr, [x22]
	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
	ret
	.cfi_endproc
                                        ; -- End function
	.no_dead_strip	_dpu_mdss_destroy
.subsections_via_symbols
