	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function __bte_shutdown_finished
___bte_shutdown_finished:               ## @__bte_shutdown_finished
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%r14
	pushq	%rbx
	.cfi_offset %rbx, -32
	.cfi_offset %r14, -24
	testq	%rdi, %rdi
	je	LBB0_5
## %bb.1:
	movq	%r8, %r14
	movq	%rdi, %rbx
	movq	$0, (%rdi)
	xorl	%edi, %edi
	callq	_hci_cmd_complete
	movq	_HCI_SUCCESS@GOTPCREL(%rip), %rax
	cmpq	%r14, (%rax)
	jne	LBB0_2
## %bb.3:
	movq	_ERR_OK@GOTPCREL(%rip), %rax
	jmp	LBB0_4
LBB0_5:
	movq	_ERR_OK@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	popq	%rbx
	popq	%r14
	popq	%rbp
	retq
LBB0_2:
	movq	_ERR_CONN@GOTPCREL(%rip), %rax
LBB0_4:
	movl	(%rax), %r14d
	xorl	%eax, %eax
	callq	_physbusif_close
	movq	%rbx, %rdi
	movl	%r14d, %esi
	popq	%rbx
	popq	%r14
	popq	%rbp
	jmp	___bte_cmdfinish                ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_ERR_OK,4,2                     ## @ERR_OK
	.comm	_HCI_SUCCESS,8,3                ## @HCI_SUCCESS
	.comm	_ERR_CONN,4,2                   ## @ERR_CONN
	.no_dead_strip	___bte_shutdown_finished
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function __bte_shutdown_finished
___bte_shutdown_finished:               ; @__bte_shutdown_finished
	.cfi_startproc
; %bb.0:
	stp	x20, x19, [sp, #-32]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 32
	stp	x29, x30, [sp, #16]             ; 16-byte Folded Spill
	add	x29, sp, #16
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	cbz	x0, LBB0_2
; %bb.1:
	mov	x20, x4
	mov	x19, x0
	str	xzr, [x0]
	mov	x0, #0
	bl	_hci_cmd_complete
Lloh0:
	adrp	x8, _HCI_SUCCESS@GOTPAGE
Lloh1:
	ldr	x8, [x8, _HCI_SUCCESS@GOTPAGEOFF]
Lloh2:
	adrp	x9, _ERR_OK@GOTPAGE
Lloh3:
	ldr	x9, [x9, _ERR_OK@GOTPAGEOFF]
Lloh4:
	ldr	x8, [x8]
Lloh5:
	adrp	x10, _ERR_CONN@GOTPAGE
Lloh6:
	ldr	x10, [x10, _ERR_CONN@GOTPAGEOFF]
	cmp	x8, x20
	csel	x8, x9, x10, eq
	ldr	w20, [x8]
	bl	_physbusif_close
	mov	x0, x19
	mov	x1, x20
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	b	___bte_cmdfinish
LBB0_2:
Lloh7:
	adrp	x8, _ERR_OK@GOTPAGE
Lloh8:
	ldr	x8, [x8, _ERR_OK@GOTPAGEOFF]
Lloh9:
	ldr	w0, [x8]
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh4
	.loh AdrpLdrGotLdr	Lloh7, Lloh8, Lloh9
	.cfi_endproc
                                        ; -- End function
	.comm	_ERR_OK,4,2                     ; @ERR_OK
	.comm	_HCI_SUCCESS,8,3                ; @HCI_SUCCESS
	.comm	_ERR_CONN,4,2                   ; @ERR_CONN
	.no_dead_strip	___bte_shutdown_finished
.subsections_via_symbols
