	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_mlx4_ib_mcg_port_init          ## -- Begin function mlx4_ib_mcg_port_init
	.p2align	4, 0x90
_mlx4_ib_mcg_port_init:                 ## @mlx4_ib_mcg_port_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
	subq	$40, %rsp
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %rbx
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -32(%rbp)
	addq	$32, %rdi
	xorl	%r14d, %r14d
	xorl	%esi, %esi
	callq	_atomic_set
	movl	(%rbx), %edx
	leaq	L_.str(%rip), %rsi
	leaq	-64(%rbp), %r15
	movq	%r15, %rdi
	callq	_sprintf
	movq	_WQ_MEM_RECLAIM@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r15, %rdi
	callq	_alloc_ordered_workqueue
	movl	%eax, 28(%rbx)
	testl	%eax, %eax
	je	LBB0_1
## %bb.2:
	leaq	24(%rbx), %rdi
	callq	_mutex_init
	movq	_RB_ROOT@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 20(%rbx)
	leaq	16(%rbx), %rdi
	callq	_INIT_LIST_HEAD
	movq	$0, 8(%rbx)
	jmp	LBB0_3
LBB0_1:
	movq	_ENOMEM@GOTPCREL(%rip), %rax
	xorl	%r14d, %r14d
	subl	(%rax), %r14d
LBB0_3:
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-32(%rbp), %rax
	jne	LBB0_5
## %bb.4:
	movl	%r14d, %eax
	addq	$40, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_5:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"mlx4_ib_mcg%d"

	.comm	_WQ_MEM_RECLAIM,4,2             ## @WQ_MEM_RECLAIM
	.comm	_ENOMEM,4,2                     ## @ENOMEM
	.comm	_RB_ROOT,4,2                    ## @RB_ROOT
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_mlx4_ib_mcg_port_init          ; -- Begin function mlx4_ib_mcg_port_init
	.p2align	2
_mlx4_ib_mcg_port_init:                 ; @mlx4_ib_mcg_port_init
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #64
	.cfi_def_cfa_offset 64
	stp	x20, x19, [sp, #32]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #48]             ; 16-byte Folded Spill
	add	x29, sp, #48
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	mov	x19, x0
Lloh0:
	adrp	x8, ___stack_chk_guard@GOTPAGE
Lloh1:
	ldr	x8, [x8, ___stack_chk_guard@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	str	x8, [sp, #24]
	add	x0, x0, #32
	mov	w1, #0
	bl	_atomic_set
	ldr	w2, [x19]
Lloh3:
	adrp	x1, l_.str@PAGE
Lloh4:
	add	x1, x1, l_.str@PAGEOFF
	add	x0, sp, #4
	bl	_sprintf
Lloh5:
	adrp	x8, _WQ_MEM_RECLAIM@GOTPAGE
Lloh6:
	ldr	x8, [x8, _WQ_MEM_RECLAIM@GOTPAGEOFF]
Lloh7:
	ldr	w1, [x8]
	add	x0, sp, #4
	bl	_alloc_ordered_workqueue
	str	w0, [x19, #28]
	cbz	w0, LBB0_2
; %bb.1:
	add	x0, x19, #24
	bl	_mutex_init
Lloh8:
	adrp	x8, _RB_ROOT@GOTPAGE
Lloh9:
	ldr	x8, [x8, _RB_ROOT@GOTPAGEOFF]
Lloh10:
	ldr	w8, [x8]
	str	w8, [x19, #20]
	add	x0, x19, #16
	bl	_INIT_LIST_HEAD
	mov	w0, #0
	str	xzr, [x19, #8]
	b	LBB0_3
LBB0_2:
Lloh11:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh12:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
Lloh13:
	ldr	w8, [x8]
	neg	w0, w8
LBB0_3:
	ldr	x8, [sp, #24]
Lloh14:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh15:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh16:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_5
; %bb.4:
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	add	sp, sp, #64
	ret
LBB0_5:
	bl	___stack_chk_fail
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpAdd	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"mlx4_ib_mcg%d"

	.comm	_WQ_MEM_RECLAIM,4,2             ; @WQ_MEM_RECLAIM
	.comm	_ENOMEM,4,2                     ; @ENOMEM
	.comm	_RB_ROOT,4,2                    ; @RB_ROOT
.subsections_via_symbols
