	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_ntb_register_device            ## -- Begin function ntb_register_device
	.p2align	4, 0x90
_ntb_register_device:                   ## @ntb_register_device
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%rbx
	pushq	%rax
	.cfi_offset %rbx, -24
	testq	%rdi, %rdi
	je	LBB0_4
## %bb.1:
	movq	%rdi, %rbx
	cmpq	$0, 48(%rdi)
	je	LBB0_4
## %bb.2:
	movl	60(%rbx), %edi
	testl	%edi, %edi
	je	LBB0_4
## %bb.3:
	callq	_ntb_dev_ops_is_valid
	testl	%eax, %eax
	je	LBB0_4
## %bb.5:
	leaq	56(%rbx), %rdi
	callq	_init_completion
	movq	_ntb_bus@GOTPCREL(%rip), %rax
	movq	%rax, 16(%rbx)
	movq	48(%rbx), %rdi
	movq	%rdi, 8(%rbx)
	movq	_ntb_dev_release@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, (%rbx)
	callq	_pci_name
	leaq	L_.str(%rip), %rsi
	movq	%rbx, %rdi
	movl	%eax, %edx
	callq	_dev_set_name
	leaq	24(%rbx), %rdi
	xorps	%xmm0, %xmm0
	movups	%xmm0, 32(%rbx)
	callq	_spin_lock_init
	movq	%rbx, %rdi
	addq	$8, %rsp
	popq	%rbx
	popq	%rbp
	jmp	_device_register                ## TAILCALL
LBB0_4:
	movq	_EINVAL@GOTPCREL(%rip), %rcx
	xorl	%eax, %eax
	subl	(%rcx), %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_EINVAL,4,2                     ## @EINVAL
	.comm	_ntb_bus,4,2                    ## @ntb_bus
	.comm	_ntb_dev_release,4,2            ## @ntb_dev_release
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"%s"

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_ntb_register_device            ; -- Begin function ntb_register_device
	.p2align	2
_ntb_register_device:                   ; @ntb_register_device
	.cfi_startproc
; %bb.0:
	stp	x20, x19, [sp, #-32]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 32
	stp	x29, x30, [sp, #16]             ; 16-byte Folded Spill
	add	x29, sp, #16
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	cbz	x0, LBB0_5
; %bb.1:
	mov	x19, x0
	ldr	x8, [x0, #48]
	cbz	x8, LBB0_5
; %bb.2:
	ldr	w0, [x19, #60]
	cbz	w0, LBB0_5
; %bb.3:
	bl	_ntb_dev_ops_is_valid
	cbz	w0, LBB0_5
; %bb.4:
	add	x0, x19, #56
	bl	_init_completion
Lloh0:
	adrp	x8, _ntb_bus@GOTPAGE
Lloh1:
	ldr	x8, [x8, _ntb_bus@GOTPAGEOFF]
	ldr	x0, [x19, #48]
	stp	x0, x8, [x19, #8]
Lloh2:
	adrp	x8, _ntb_dev_release@GOTPAGE
Lloh3:
	ldr	x8, [x8, _ntb_dev_release@GOTPAGEOFF]
Lloh4:
	ldr	w8, [x8]
	str	w8, [x19]
	bl	_pci_name
	mov	x2, x0
Lloh5:
	adrp	x1, l_.str@PAGE
Lloh6:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x19
	bl	_dev_set_name
	add	x0, x19, #24
	stp	xzr, xzr, [x19, #32]
	bl	_spin_lock_init
	mov	x0, x19
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	b	_device_register
LBB0_5:
Lloh7:
	adrp	x8, _EINVAL@GOTPAGE
Lloh8:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh9:
	ldr	w8, [x8]
	neg	w0, w8
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	ret
	.loh AdrpAdd	Lloh5, Lloh6
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh7, Lloh8, Lloh9
	.cfi_endproc
                                        ; -- End function
	.comm	_EINVAL,4,2                     ; @EINVAL
	.comm	_ntb_bus,4,2                    ; @ntb_bus
	.comm	_ntb_dev_release,4,2            ; @ntb_dev_release
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"%s"

.subsections_via_symbols
