	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_radeon_driver_load_kms         ## -- Begin function radeon_driver_load_kms
	.p2align	4, 0x90
_radeon_driver_load_kms:                ## @radeon_driver_load_kms
	.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	%rsi, %r15
	movq	%rdi, %r14
	movq	_GFP_KERNEL@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	$4, %edi
	callq	_kzalloc
	testq	%rax, %rax
	je	LBB0_1
## %bb.2:
	movq	%rax, %r12
	movq	%rax, 8(%r14)
	movq	%r14, %rdi
	callq	_drm_pci_device_is_agp
	testq	%rax, %rax
	je	LBB0_4
## %bb.3:
	movq	_RADEON_IS_AGP@GOTPCREL(%rip), %rax
	jmp	LBB0_7
LBB0_1:
	movq	_ENOMEM@GOTPCREL(%rip), %rax
	xorl	%ebx, %ebx
	subl	(%rax), %ebx
	jmp	LBB0_14
LBB0_4:
	movq	(%r14), %rdi
	callq	_pci_is_pcie
	testq	%rax, %rax
	jne	LBB0_5
## %bb.6:
	movq	_RADEON_IS_PCI@GOTPCREL(%rip), %rax
	jmp	LBB0_7
LBB0_5:
	movq	_RADEON_IS_PCIE@GOTPCREL(%rip), %rax
LBB0_7:
	orq	(%rax), %r15
	movq	(%r14), %rdx
	movq	%r12, %rdi
	movq	%r14, %rsi
	movq	%r15, %rcx
	callq	_radeon_device_init
	testl	%eax, %eax
	je	LBB0_10
## %bb.8:
	movl	%eax, %ebx
	leaq	L_.str(%rip), %rsi
	jmp	LBB0_9
LBB0_10:
	movq	%r12, %rdi
	callq	_radeon_modeset_init
	testl	%eax, %eax
	je	LBB0_12
## %bb.11:
	movl	%eax, %ebx
	leaq	L_.str.1(%rip), %rsi
LBB0_9:
	movq	(%r14), %rdi
	callq	_dev_err
	movq	%r14, %rdi
	callq	_radeon_driver_unload_kms
LBB0_14:
	movl	%ebx, %eax
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_12:
	movq	%r12, %rdi
	callq	_radeon_acpi_init
	xorl	%ebx, %ebx
	testl	%eax, %eax
	je	LBB0_14
## %bb.13:
	movq	(%r14), %rdi
	leaq	L_.str.2(%rip), %rsi
	callq	_dev_dbg
	jmp	LBB0_14
	.cfi_endproc
                                        ## -- End function
	.comm	_GFP_KERNEL,4,2                 ## @GFP_KERNEL
	.comm	_ENOMEM,4,2                     ## @ENOMEM
	.comm	_RADEON_IS_AGP,8,3              ## @RADEON_IS_AGP
	.comm	_RADEON_IS_PCIE,8,3             ## @RADEON_IS_PCIE
	.comm	_RADEON_IS_PCI,8,3              ## @RADEON_IS_PCI
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Fatal error during GPU init\n"

L_.str.1:                               ## @.str.1
	.asciz	"Fatal error during modeset init\n"

L_.str.2:                               ## @.str.2
	.asciz	"Error during ACPI methods call\n"

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_radeon_driver_load_kms         ; -- Begin function radeon_driver_load_kms
	.p2align	2
_radeon_driver_load_kms:                ; @radeon_driver_load_kms
	.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
	mov	x21, x1
	mov	x19, x0
Lloh0:
	adrp	x8, _GFP_KERNEL@GOTPAGE
Lloh1:
	ldr	x8, [x8, _GFP_KERNEL@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
	mov	w0, #4
	bl	_kzalloc
	cbz	x0, LBB0_3
; %bb.1:
	mov	x20, x0
	str	x0, [x19, #8]
	mov	x0, x19
	bl	_drm_pci_device_is_agp
	cbz	x0, LBB0_4
; %bb.2:
Lloh3:
	adrp	x8, _RADEON_IS_AGP@GOTPAGE
Lloh4:
	ldr	x8, [x8, _RADEON_IS_AGP@GOTPAGEOFF]
	b	LBB0_5
LBB0_3:
Lloh5:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh6:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
Lloh7:
	ldr	w8, [x8]
	neg	w21, w8
	b	LBB0_10
LBB0_4:
	ldr	x0, [x19]
	bl	_pci_is_pcie
Lloh8:
	adrp	x8, _RADEON_IS_PCIE@GOTPAGE
Lloh9:
	ldr	x8, [x8, _RADEON_IS_PCIE@GOTPAGEOFF]
Lloh10:
	adrp	x9, _RADEON_IS_PCI@GOTPAGE
Lloh11:
	ldr	x9, [x9, _RADEON_IS_PCI@GOTPAGEOFF]
	cmp	x0, #0
	csel	x8, x9, x8, eq
LBB0_5:
	ldr	x8, [x8]
	orr	x3, x8, x21
	ldr	x2, [x19]
	mov	x0, x20
	mov	x1, x19
	bl	_radeon_device_init
	cbz	w0, LBB0_7
; %bb.6:
	mov	x21, x0
Lloh12:
	adrp	x1, l_.str@PAGE
Lloh13:
	add	x1, x1, l_.str@PAGEOFF
	b	LBB0_9
LBB0_7:
	mov	x0, x20
	bl	_radeon_modeset_init
	cbz	w0, LBB0_11
; %bb.8:
	mov	x21, x0
Lloh14:
	adrp	x1, l_.str.1@PAGE
Lloh15:
	add	x1, x1, l_.str.1@PAGEOFF
LBB0_9:
	ldr	x0, [x19]
	bl	_dev_err
	mov	x0, x19
	bl	_radeon_driver_unload_kms
LBB0_10:
	mov	x0, x21
	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
LBB0_11:
	mov	x0, x20
	bl	_radeon_acpi_init
	cbz	w0, LBB0_13
; %bb.12:
	ldr	x0, [x19]
Lloh16:
	adrp	x1, l_.str.2@PAGE
Lloh17:
	add	x1, x1, l_.str.2@PAGEOFF
	bl	_dev_dbg
LBB0_13:
	mov	w21, #0
	b	LBB0_10
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh10, Lloh11
	.loh AdrpLdrGot	Lloh8, Lloh9
	.loh AdrpAdd	Lloh12, Lloh13
	.loh AdrpAdd	Lloh14, Lloh15
	.loh AdrpAdd	Lloh16, Lloh17
	.cfi_endproc
                                        ; -- End function
	.comm	_GFP_KERNEL,4,2                 ; @GFP_KERNEL
	.comm	_ENOMEM,4,2                     ; @ENOMEM
	.comm	_RADEON_IS_AGP,8,3              ; @RADEON_IS_AGP
	.comm	_RADEON_IS_PCIE,8,3             ; @RADEON_IS_PCIE
	.comm	_RADEON_IS_PCI,8,3              ; @RADEON_IS_PCI
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Fatal error during GPU init\n"

l_.str.1:                               ; @.str.1
	.asciz	"Fatal error during modeset init\n"

l_.str.2:                               ; @.str.2
	.asciz	"Error during ACPI methods call\n"

.subsections_via_symbols
