	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function pci_vtcon_port_add
_pci_vtcon_port_add:                    ## @pci_vtcon_port_add
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	movl	(%rdi), %r8d
	movq	_VTCON_MAXPORTS@GOTPCREL(%rip), %rax
	cmpl	(%rax), %r8d
	jne	LBB0_2
## %bb.1:
	movq	_EBUSY@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movq	_errno@GOTPCREL(%rip), %rcx
	movl	%eax, (%rcx)
	xorl	%eax, %eax
	popq	%rbp
	retq
LBB0_2:
	movslq	%r8d, %r10
	movq	8(%rdi), %r9
	leal	1(%r8), %eax
	movl	%eax, (%rdi)
	imulq	$56, %r10, %r10
	leaq	(%r9,%r10), %rax
	movl	%r8d, (%r9,%r10)
	movq	%rdi, 48(%r9,%r10)
	movq	%rsi, 8(%r9,%r10)
	movq	%rdx, 40(%r9,%r10)
	testl	%r8d, %r8d
	leal	2(%r8,%r8), %edx
	cmovel	%r8d, %edx
	leal	3(%r8,%r8), %esi
	movl	$1, %edi
	cmovnel	%esi, %edi
	movq	%rcx, 32(%r9,%r10)
	movl	%edx, 16(%r9,%r10)
	movl	%edi, 20(%r9,%r10)
	movl	$1, 24(%r9,%r10)
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_VTCON_MAXPORTS,4,2             ## @VTCON_MAXPORTS
	.comm	_EBUSY,4,2                      ## @EBUSY
	.comm	_errno,4,2                      ## @errno
	.no_dead_strip	_pci_vtcon_port_add
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function pci_vtcon_port_add
_pci_vtcon_port_add:                    ; @pci_vtcon_port_add
	.cfi_startproc
; %bb.0:
	ldr	w9, [x0]
Lloh0:
	adrp	x10, _VTCON_MAXPORTS@GOTPAGE
Lloh1:
	ldr	x10, [x10, _VTCON_MAXPORTS@GOTPAGEOFF]
Lloh2:
	ldr	w10, [x10]
	cmp	w9, w10
	b.ne	LBB0_2
; %bb.1:
	mov	x0, #0
Lloh3:
	adrp	x8, _EBUSY@GOTPAGE
Lloh4:
	ldr	x8, [x8, _EBUSY@GOTPAGEOFF]
Lloh5:
	ldr	w8, [x8]
Lloh6:
	adrp	x9, _errno@GOTPAGE
Lloh7:
	ldr	x9, [x9, _errno@GOTPAGEOFF]
Lloh8:
	str	w8, [x9]
	ret
LBB0_2:
	mov	x8, x0
	sxtw	x10, w9
	ldr	x11, [x0, #8]
	add	w12, w9, #1
	str	w12, [x0]
	mov	w13, #56
	madd	x0, x10, x13, x11
	str	w9, [x0]
	stp	x2, x8, [x0, #40]
	str	x1, [x0, #8]
	str	x3, [x0, #32]
	lsl	w8, w12, #1
	mov	w10, #1
	mov	w11, #1
	bfi	w11, w12, #1, #31
	cmp	w9, #0
	csel	w8, wzr, w8, eq
	csinc	w9, w11, wzr, ne
	stp	w8, w9, [x0, #16]
	str	w10, [x0, #24]
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotStr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.cfi_endproc
                                        ; -- End function
	.comm	_VTCON_MAXPORTS,4,2             ; @VTCON_MAXPORTS
	.comm	_EBUSY,4,2                      ; @EBUSY
	.comm	_errno,4,2                      ; @errno
	.no_dead_strip	_pci_vtcon_port_add
.subsections_via_symbols
