	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function cafe_shutdown
_cafe_shutdown:                         ## @cafe_shutdown
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%rbx
	pushq	%rax
	.cfi_offset %rbx, -24
	movq	%rdi, %rbx
	cmpq	$0, (%rdi)
	jle	LBB0_2
## %bb.1:
	movq	%rbx, %rdi
	callq	_cafe_free_sio_buffers
LBB0_2:
	movq	%rbx, %rdi
	callq	_cafe_ctlr_stop_dma
	movq	%rbx, %rdi
	callq	_cafe_ctlr_power_down
	movq	%rbx, %rdi
	callq	_cafe_smbus_shutdown
	movq	%rbx, %rdi
	callq	_cafe_free_dma_bufs
	movq	16(%rbx), %rax
	movl	(%rax), %edi
	movq	%rbx, %rsi
	callq	_free_irq
	movq	16(%rbx), %rdi
	movl	12(%rbx), %esi
	callq	_pci_iounmap
	addq	$8, %rbx
	movq	%rbx, %rdi
	addq	$8, %rsp
	popq	%rbx
	popq	%rbp
	jmp	_video_unregister_device        ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.no_dead_strip	_cafe_shutdown
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function cafe_shutdown
_cafe_shutdown:                         ; @cafe_shutdown
	.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
	mov	x19, x0
	ldr	x8, [x0]
	cmp	x8, #1
	b.lt	LBB0_2
; %bb.1:
	mov	x0, x19
	bl	_cafe_free_sio_buffers
LBB0_2:
	mov	x0, x19
	bl	_cafe_ctlr_stop_dma
	mov	x0, x19
	bl	_cafe_ctlr_power_down
	mov	x0, x19
	bl	_cafe_smbus_shutdown
	mov	x0, x19
	bl	_cafe_free_dma_bufs
	ldr	x8, [x19, #16]
	ldr	w0, [x8]
	mov	x1, x19
	bl	_free_irq
	ldr	x0, [x19, #16]
	ldr	w1, [x19, #12]
	bl	_pci_iounmap
	add	x0, x19, #8
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	b	_video_unregister_device
	.cfi_endproc
                                        ; -- End function
	.no_dead_strip	_cafe_shutdown
.subsections_via_symbols
