	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function dumb_vga_attach
_dumb_vga_attach:                       ## @dumb_vga_attach
	.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, %r15
	callq	_drm_bridge_to_dumb_vga
	cmpl	$0, (%r15)
	je	LBB0_1
## %bb.2:
	movq	%rax, %r14
	movq	_dumb_vga_con_helper_funcs@GOTPCREL(%rip), %rsi
	movq	%rax, %rdi
	callq	_drm_connector_helper_add
	movl	4(%r15), %edi
	movq	_DRM_MODE_CONNECTOR_VGA@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	movl	4(%r14), %r8d
	movq	_dumb_vga_con_funcs@GOTPCREL(%rip), %rdx
	movq	%r14, %rsi
	callq	_drm_connector_init_with_ddc
	testl	%eax, %eax
	je	LBB0_4
## %bb.3:
	movl	%eax, %ebx
	leaq	L_.str.1(%rip), %rdi
	callq	_DRM_ERROR
	jmp	LBB0_5
LBB0_1:
	leaq	L_.str(%rip), %rdi
	callq	_DRM_ERROR
	movq	_ENODEV@GOTPCREL(%rip), %rax
	xorl	%ebx, %ebx
	subl	(%rax), %ebx
	jmp	LBB0_5
LBB0_4:
	movl	(%r15), %esi
	movq	%r14, %rdi
	callq	_drm_connector_attach_encoder
	xorl	%ebx, %ebx
LBB0_5:
	movl	%ebx, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Missing encoder\n"

	.comm	_ENODEV,4,2                     ## @ENODEV
	.comm	_dumb_vga_con_helper_funcs,4,2  ## @dumb_vga_con_helper_funcs
	.comm	_dumb_vga_con_funcs,4,2         ## @dumb_vga_con_funcs
	.comm	_DRM_MODE_CONNECTOR_VGA,4,2     ## @DRM_MODE_CONNECTOR_VGA
L_.str.1:                               ## @.str.1
	.asciz	"Failed to initialize connector\n"

	.no_dead_strip	_dumb_vga_attach
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function dumb_vga_attach
_dumb_vga_attach:                       ; @dumb_vga_attach
	.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	x19, x0
	bl	_drm_bridge_to_dumb_vga
	ldr	w8, [x19]
	cbz	w8, LBB0_3
; %bb.1:
	mov	x20, x0
Lloh0:
	adrp	x1, _dumb_vga_con_helper_funcs@GOTPAGE
Lloh1:
	ldr	x1, [x1, _dumb_vga_con_helper_funcs@GOTPAGEOFF]
	bl	_drm_connector_helper_add
	ldr	w0, [x19, #4]
Lloh2:
	adrp	x8, _DRM_MODE_CONNECTOR_VGA@GOTPAGE
Lloh3:
	ldr	x8, [x8, _DRM_MODE_CONNECTOR_VGA@GOTPAGEOFF]
Lloh4:
	ldr	w3, [x8]
	ldr	w4, [x20, #4]
Lloh5:
	adrp	x2, _dumb_vga_con_funcs@GOTPAGE
Lloh6:
	ldr	x2, [x2, _dumb_vga_con_funcs@GOTPAGEOFF]
	mov	x1, x20
	bl	_drm_connector_init_with_ddc
	mov	x21, x0
	cbz	w0, LBB0_4
; %bb.2:
Lloh7:
	adrp	x0, l_.str.1@PAGE
Lloh8:
	add	x0, x0, l_.str.1@PAGEOFF
	bl	_DRM_ERROR
	b	LBB0_5
LBB0_3:
Lloh9:
	adrp	x0, l_.str@PAGE
Lloh10:
	add	x0, x0, l_.str@PAGEOFF
	bl	_DRM_ERROR
Lloh11:
	adrp	x8, _ENODEV@GOTPAGE
Lloh12:
	ldr	x8, [x8, _ENODEV@GOTPAGEOFF]
Lloh13:
	ldr	w8, [x8]
	neg	w21, w8
	b	LBB0_5
LBB0_4:
	ldr	w1, [x19]
	mov	x0, x20
	bl	_drm_connector_attach_encoder
LBB0_5:
	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
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpAdd	Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpAdd	Lloh9, Lloh10
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Missing encoder\n"

	.comm	_ENODEV,4,2                     ; @ENODEV
	.comm	_dumb_vga_con_helper_funcs,4,2  ; @dumb_vga_con_helper_funcs
	.comm	_dumb_vga_con_funcs,4,2         ; @dumb_vga_con_funcs
	.comm	_DRM_MODE_CONNECTOR_VGA,4,2     ; @DRM_MODE_CONNECTOR_VGA
l_.str.1:                               ; @.str.1
	.asciz	"Failed to initialize connector\n"

	.no_dead_strip	_dumb_vga_attach
.subsections_via_symbols
