	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function acpi_bus_remove
_acpi_bus_remove:                       ## @acpi_bus_remove
	.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
	testq	%rdi, %rdi
	je	LBB0_1
## %bb.2:
	movl	%esi, %r15d
	movq	%rdi, %rbx
	movq	_ACPI_BUS_REMOVAL_EJECT@GOTPCREL(%rip), %r12
	movl	(%r12), %eax
	movl	%eax, 20(%rdi)
	addq	$16, %rdi
	callq	_device_release_driver
	xorl	%r14d, %r14d
	testl	%r15d, %r15d
	je	LBB0_8
## %bb.3:
	cmpq	$0, 8(%rbx)
	je	LBB0_7
## %bb.4:
	movq	(%rbx), %rax
	testq	%rax, %rax
	je	LBB0_7
## %bb.5:
	movq	(%rax), %rax
	testq	%rax, %rax
	je	LBB0_7
## %bb.6:
	movq	%rbx, %rdi
	callq	*%rax
LBB0_7:
	movl	(%r12), %esi
	movq	%rbx, %rdi
	callq	_acpi_device_unregister
	jmp	LBB0_8
LBB0_1:
	movq	_EINVAL@GOTPCREL(%rip), %rax
	xorl	%r14d, %r14d
	subl	(%rax), %r14d
LBB0_8:
	movl	%r14d, %eax
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_EINVAL,4,2                     ## @EINVAL
	.comm	_ACPI_BUS_REMOVAL_EJECT,4,2     ## @ACPI_BUS_REMOVAL_EJECT
	.no_dead_strip	_acpi_bus_remove
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function acpi_bus_remove
_acpi_bus_remove:                       ; @acpi_bus_remove
	.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
	cbz	x0, LBB0_8
; %bb.1:
	mov	x20, x1
	mov	x19, x0
Lloh0:
	adrp	x21, _ACPI_BUS_REMOVAL_EJECT@GOTPAGE
Lloh1:
	ldr	x21, [x21, _ACPI_BUS_REMOVAL_EJECT@GOTPAGEOFF]
	ldr	w8, [x21]
	str	w8, [x0, #20]
	add	x0, x0, #16
	bl	_device_release_driver
	cbz	w20, LBB0_7
; %bb.2:
	ldr	x8, [x19, #8]
	cbz	x8, LBB0_6
; %bb.3:
	ldr	x8, [x19]
	cbz	x8, LBB0_6
; %bb.4:
	ldr	x8, [x8]
	cbz	x8, LBB0_6
; %bb.5:
	mov	x0, x19
	blr	x8
LBB0_6:
	ldr	w1, [x21]
	mov	x0, x19
	bl	_acpi_device_unregister
LBB0_7:
	mov	w0, #0
	b	LBB0_9
LBB0_8:
Lloh2:
	adrp	x8, _EINVAL@GOTPAGE
Lloh3:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh4:
	ldr	w8, [x8]
	neg	w0, w8
LBB0_9:
	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
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.cfi_endproc
                                        ; -- End function
	.comm	_EINVAL,4,2                     ; @EINVAL
	.comm	_ACPI_BUS_REMOVAL_EJECT,4,2     ; @ACPI_BUS_REMOVAL_EJECT
	.no_dead_strip	_acpi_bus_remove
.subsections_via_symbols
