	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function mga_vga_init
_mga_vga_init:                          ## @mga_vga_init
	.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	_GFP_KERNEL@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	$16, %edi
	callq	_kzalloc
	testq	%rax, %rax
	je	LBB0_1
## %bb.2:
	movq	%rax, %rbx
	movq	%rax, %r15
	addq	$8, %r15
	movq	%r14, %rdi
	callq	_mgag200_i2c_create
	movq	%rax, (%rbx)
	testq	%rax, %rax
	jne	LBB0_4
## %bb.3:
	leaq	L_.str(%rip), %rdi
	callq	_DRM_ERROR
	movq	(%rbx), %rax
LBB0_4:
	movq	_DRM_MODE_CONNECTOR_VGA@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	movq	_mga_vga_connector_funcs@GOTPCREL(%rip), %rdx
	movq	%r14, %rdi
	movq	%r15, %rsi
	movq	%rax, %r8
	callq	_drm_connector_init_with_ddc
	movq	_mga_vga_connector_helper_funcs@GOTPCREL(%rip), %rsi
	movq	%r15, %rdi
	callq	_drm_connector_helper_add
	movq	%r15, %rdi
	callq	_drm_connector_register
	jmp	LBB0_5
LBB0_1:
	xorl	%r15d, %r15d
LBB0_5:
	movq	%r15, %rax
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_GFP_KERNEL,4,2                 ## @GFP_KERNEL
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"failed to add ddc bus\n"

	.comm	_mga_vga_connector_funcs,4,2    ## @mga_vga_connector_funcs
	.comm	_DRM_MODE_CONNECTOR_VGA,4,2     ## @DRM_MODE_CONNECTOR_VGA
	.comm	_mga_vga_connector_helper_funcs,4,2 ## @mga_vga_connector_helper_funcs
	.no_dead_strip	_mga_vga_init
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function mga_vga_init
_mga_vga_init:                          ; @mga_vga_init
	.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	x20, x0
Lloh0:
	adrp	x8, _GFP_KERNEL@GOTPAGE
Lloh1:
	ldr	x8, [x8, _GFP_KERNEL@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
	mov	w0, #16
	bl	_kzalloc
	cbz	x0, LBB0_4
; %bb.1:
	mov	x21, x0
	mov	x0, x20
	bl	_mgag200_i2c_create
	mov	x4, x0
	mov	x19, x21
	str	x0, [x19], #8
	cbnz	x0, LBB0_3
; %bb.2:
Lloh3:
	adrp	x0, l_.str@PAGE
Lloh4:
	add	x0, x0, l_.str@PAGEOFF
	bl	_DRM_ERROR
	ldr	x4, [x21]
LBB0_3:
Lloh5:
	adrp	x8, _DRM_MODE_CONNECTOR_VGA@GOTPAGE
Lloh6:
	ldr	x8, [x8, _DRM_MODE_CONNECTOR_VGA@GOTPAGEOFF]
Lloh7:
	ldr	w3, [x8]
Lloh8:
	adrp	x2, _mga_vga_connector_funcs@GOTPAGE
Lloh9:
	ldr	x2, [x2, _mga_vga_connector_funcs@GOTPAGEOFF]
	mov	x0, x20
	mov	x1, x19
	bl	_drm_connector_init_with_ddc
Lloh10:
	adrp	x1, _mga_vga_connector_helper_funcs@GOTPAGE
Lloh11:
	ldr	x1, [x1, _mga_vga_connector_helper_funcs@GOTPAGEOFF]
	mov	x0, x19
	bl	_drm_connector_helper_add
	mov	x0, x19
	bl	_drm_connector_register
	b	LBB0_5
LBB0_4:
	mov	x19, #0
LBB0_5:
	mov	x0, x19
	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 AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh10, Lloh11
	.loh AdrpLdrGot	Lloh8, Lloh9
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.cfi_endproc
                                        ; -- End function
	.comm	_GFP_KERNEL,4,2                 ; @GFP_KERNEL
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"failed to add ddc bus\n"

	.comm	_mga_vga_connector_funcs,4,2    ; @mga_vga_connector_funcs
	.comm	_DRM_MODE_CONNECTOR_VGA,4,2     ; @DRM_MODE_CONNECTOR_VGA
	.comm	_mga_vga_connector_helper_funcs,4,2 ; @mga_vga_connector_helper_funcs
	.no_dead_strip	_mga_vga_init
.subsections_via_symbols
