	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_komeda_dev_destroy             ## -- Begin function komeda_dev_destroy
	.p2align	4, 0x90
_komeda_dev_destroy:                    ## @komeda_dev_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	%r12
	pushq	%rbx
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %r12
	movq	40(%rdi), %r15
	movq	56(%rdi), %r14
	movq	_komeda_sysfs_attr_group@GOTPCREL(%rip), %rsi
	movq	%r14, %rdi
	callq	_sysfs_remove_group
	cmpq	$0, 32(%r12)
	je	LBB0_3
## %bb.1:
	movq	40(%r12), %rax
	movq	8(%rax), %rax
	testq	%rax, %rax
	je	LBB0_3
## %bb.2:
	movq	%r12, %rdi
	callq	*%rax
LBB0_3:
	movq	$0, 32(%r12)
	cmpl	$0, (%r12)
	jle	LBB0_6
## %bb.4:
	xorl	%ebx, %ebx
	.p2align	4, 0x90
LBB0_5:                                 ## =>This Inner Loop Header: Depth=1
	movq	24(%r12), %rax
	movq	(%rax,%rbx,8), %rsi
	movq	%r12, %rdi
	callq	_komeda_pipeline_destroy
	movq	24(%r12), %rax
	movq	$0, (%rax,%rbx,8)
	incq	%rbx
	movslq	(%r12), %rax
	cmpq	%rax, %rbx
	jl	LBB0_5
LBB0_6:
	movl	$0, (%r12)
	movq	%r14, %rdi
	callq	_of_reserved_mem_device_release
	testq	%r15, %r15
	je	LBB0_9
## %bb.7:
	movq	(%r15), %rax
	testq	%rax, %rax
	je	LBB0_9
## %bb.8:
	movq	%r12, %rdi
	callq	*%rax
LBB0_9:
	movq	16(%r12), %rsi
	testq	%rsi, %rsi
	je	LBB0_11
## %bb.10:
	movq	%r14, %rdi
	callq	_devm_iounmap
	movq	$0, 16(%r12)
LBB0_11:
	movq	8(%r12), %rdi
	testq	%rdi, %rdi
	je	LBB0_13
## %bb.12:
	callq	_clk_disable_unprepare
	movq	8(%r12), %rsi
	movq	%r14, %rdi
	callq	_devm_clk_put
	movq	$0, 8(%r12)
LBB0_13:
	movq	%r14, %rdi
	movq	%r12, %rsi
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_devm_kfree                     ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_komeda_sysfs_attr_group,4,2    ## @komeda_sysfs_attr_group
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_komeda_dev_destroy             ; -- Begin function komeda_dev_destroy
	.p2align	2
_komeda_dev_destroy:                    ; @komeda_dev_destroy
	.cfi_startproc
; %bb.0:
	stp	x24, x23, [sp, #-64]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 64
	stp	x22, x21, [sp, #16]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #32]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #48]             ; 16-byte Folded Spill
	add	x29, sp, #48
	.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
	.cfi_offset w23, -56
	.cfi_offset w24, -64
	mov	x19, x0
	ldr	x20, [x0, #56]
	ldr	x21, [x0, #40]
Lloh0:
	adrp	x1, _komeda_sysfs_attr_group@GOTPAGE
Lloh1:
	ldr	x1, [x1, _komeda_sysfs_attr_group@GOTPAGEOFF]
	mov	x0, x20
	bl	_sysfs_remove_group
	ldr	x8, [x19, #32]
	cbz	x8, LBB0_3
; %bb.1:
	ldr	x8, [x19, #40]
	ldr	x8, [x8, #8]
	cbz	x8, LBB0_3
; %bb.2:
	mov	x0, x19
	blr	x8
LBB0_3:
	str	xzr, [x19, #32]
	ldr	w8, [x19]
	cmp	w8, #1
	b.lt	LBB0_6
; %bb.4:
	mov	x22, #0
LBB0_5:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x8, [x19, #24]
	lsl	x23, x22, #3
	ldr	x1, [x8, x23]
	mov	x0, x19
	bl	_komeda_pipeline_destroy
	ldr	x8, [x19, #24]
	str	xzr, [x8, x23]
	add	x22, x22, #1
	ldrsw	x8, [x19]
	cmp	x22, x8
	b.lt	LBB0_5
LBB0_6:
	str	wzr, [x19]
	mov	x0, x20
	bl	_of_reserved_mem_device_release
	cbz	x21, LBB0_9
; %bb.7:
	ldr	x8, [x21]
	cbz	x8, LBB0_9
; %bb.8:
	mov	x0, x19
	blr	x8
LBB0_9:
	ldr	x1, [x19, #16]
	cbz	x1, LBB0_11
; %bb.10:
	mov	x0, x20
	bl	_devm_iounmap
	str	xzr, [x19, #16]
LBB0_11:
	ldr	x0, [x19, #8]
	cbz	x0, LBB0_13
; %bb.12:
	bl	_clk_disable_unprepare
	ldr	x1, [x19, #8]
	mov	x0, x20
	bl	_devm_clk_put
	str	xzr, [x19, #8]
LBB0_13:
	mov	x0, x20
	mov	x1, x19
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp], #64             ; 16-byte Folded Reload
	b	_devm_kfree
	.loh AdrpLdrGot	Lloh0, Lloh1
	.cfi_endproc
                                        ; -- End function
	.comm	_komeda_sysfs_attr_group,4,2    ; @komeda_sysfs_attr_group
.subsections_via_symbols
