	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function poseidon_fm_close
_poseidon_fm_close:                     ## @poseidon_fm_close
	.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, %r14
	movq	(%rdi), %rbx
	leaq	4(%rbx), %r15
	movq	%r15, %rdi
	callq	_mutex_lock
	decq	32(%rbx)
	je	LBB0_1
## %bb.2:
	cmpq	$0, 40(%rbx)
	jne	LBB0_3
	jmp	LBB0_5
LBB0_1:
	movq	_POSEIDON_STATE_FM@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	notl	%eax
	andl	%eax, 24(%rbx)
	cmpq	$0, 40(%rbx)
	je	LBB0_5
LBB0_3:
	cmpq	%r14, 16(%rbx)
	jne	LBB0_5
## %bb.4:
	movq	$0, 40(%rbx)
	movq	_PLAY_SERVICE@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_TLG_TUNE_PLAY_SVC_STOP@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	leaq	-28(%rbp), %rcx
	movq	%rbx, %rdi
	callq	_send_set_req
LBB0_5:
	movl	8(%rbx), %edi
	callq	_usb_autopm_put_interface
	movq	%r15, %rdi
	callq	_mutex_unlock
	movq	_poseidon_delete@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%rbx, %rdi
	callq	_kref_put
	movq	$0, (%r14)
	xorl	%eax, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_POSEIDON_STATE_FM,4,2          ## @POSEIDON_STATE_FM
	.comm	_PLAY_SERVICE,4,2               ## @PLAY_SERVICE
	.comm	_TLG_TUNE_PLAY_SVC_STOP,4,2     ## @TLG_TUNE_PLAY_SVC_STOP
	.comm	_poseidon_delete,4,2            ## @poseidon_delete
	.no_dead_strip	_poseidon_fm_close
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function poseidon_fm_close
_poseidon_fm_close:                     ; @poseidon_fm_close
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #64
	.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
	mov	x19, x0
	ldr	x20, [x0]
	add	x21, x20, #4
	mov	x0, x21
	bl	_mutex_lock
	ldr	x8, [x20, #32]
	subs	x8, x8, #1
	str	x8, [x20, #32]
	b.eq	LBB0_2
; %bb.1:
	ldr	x8, [x20, #40]
	cbnz	x8, LBB0_3
	b	LBB0_5
LBB0_2:
Lloh0:
	adrp	x8, _POSEIDON_STATE_FM@GOTPAGE
Lloh1:
	ldr	x8, [x8, _POSEIDON_STATE_FM@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
	ldr	w9, [x20, #24]
	bic	w8, w9, w8
	str	w8, [x20, #24]
	ldr	x8, [x20, #40]
	cbz	x8, LBB0_5
LBB0_3:
	ldr	x8, [x20, #16]
	cmp	x8, x19
	b.ne	LBB0_5
; %bb.4:
	str	xzr, [x20, #40]
Lloh3:
	adrp	x8, _PLAY_SERVICE@GOTPAGE
Lloh4:
	ldr	x8, [x8, _PLAY_SERVICE@GOTPAGEOFF]
Lloh5:
	ldr	w1, [x8]
Lloh6:
	adrp	x8, _TLG_TUNE_PLAY_SVC_STOP@GOTPAGE
Lloh7:
	ldr	x8, [x8, _TLG_TUNE_PLAY_SVC_STOP@GOTPAGEOFF]
Lloh8:
	ldr	w2, [x8]
	add	x3, sp, #12
	mov	x0, x20
	bl	_send_set_req
LBB0_5:
	ldr	w0, [x20, #8]
	bl	_usb_autopm_put_interface
	mov	x0, x21
	bl	_mutex_unlock
Lloh9:
	adrp	x8, _poseidon_delete@GOTPAGE
Lloh10:
	ldr	x8, [x8, _poseidon_delete@GOTPAGEOFF]
Lloh11:
	ldr	w1, [x8]
	mov	x0, x20
	bl	_kref_put
	str	xzr, [x19]
	mov	w0, #0
	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
	add	sp, sp, #64
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.cfi_endproc
                                        ; -- End function
	.comm	_POSEIDON_STATE_FM,4,2          ; @POSEIDON_STATE_FM
	.comm	_PLAY_SERVICE,4,2               ; @PLAY_SERVICE
	.comm	_TLG_TUNE_PLAY_SVC_STOP,4,2     ; @TLG_TUNE_PLAY_SVC_STOP
	.comm	_poseidon_delete,4,2            ; @poseidon_delete
	.no_dead_strip	_poseidon_fm_close
.subsections_via_symbols
