	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.section	__TEXT,__literal16,16byte_literals
	.p2align	4                               ## -- Begin function mlx4_slave_cap
LCPI0_0:
	.long	1065353216                      ## 0x3f800000
	.long	1065353216                      ## 0x3f800000
	.long	1065353216                      ## 0x3f800000
	.long	1065353216                      ## 0x3f800000
	.section	__TEXT,__text,regular,pure_instructions
	.p2align	4, 0x90
_mlx4_slave_cap:                        ## @mlx4_slave_cap
	.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	%r13
	pushq	%r12
	pushq	%rbx
	pushq	%rax
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %r12
	movq	_GFP_KERNEL@GOTPCREL(%rip), %rbx
	movl	(%rbx), %esi
	movl	$120, %edi
	callq	_kzalloc
	movq	%rax, %r13
	movl	(%rbx), %esi
	movl	$120, %edi
	callq	_kzalloc
	movq	%rax, %r14
	movl	(%rbx), %esi
	movl	$120, %edi
	callq	_kzalloc
	movq	%rax, %r15
	testq	%r13, %r13
	je	LBB0_6
## %bb.1:
	testq	%r14, %r14
	je	LBB0_6
## %bb.2:
	testq	%r15, %r15
	je	LBB0_6
## %bb.3:
	movq	%r12, %rdi
	movq	%r13, %rsi
	callq	_mlx4_QUERY_HCA
	testl	%eax, %eax
	je	LBB0_9
## %bb.4:
	movl	%eax, %ebx
	leaq	L_.str.1(%rip), %rsi
LBB0_5:
	movq	%r12, %rdi
	xorl	%eax, %eax
	callq	_mlx4_err
	jmp	LBB0_8
LBB0_6:
	leaq	L_.str(%rip), %rsi
	xorl	%ebx, %ebx
	movq	%r12, %rdi
	xorl	%eax, %eax
	callq	_mlx4_err
	movq	_ENOMEM@GOTPCREL(%rip), %rax
LBB0_7:
	subl	(%rax), %ebx
LBB0_8:
	movq	%r13, %rdi
	callq	_kfree
	movq	%r14, %rdi
	callq	_kfree
	movq	%r15, %rdi
	callq	_kfree
	movl	%ebx, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_9:
	cmpq	$0, 112(%r13)
	je	LBB0_12
## %bb.10:
	leaq	L_.str.2(%rip), %rsi
	xorl	%ebx, %ebx
	movq	%r12, %rdi
	xorl	%eax, %eax
	callq	_mlx4_err
LBB0_11:
	movq	_EINVAL@GOTPCREL(%rip), %rax
	jmp	LBB0_7
LBB0_12:
	movl	104(%r13), %eax
	movl	%eax, 128(%r12)
	movb	(%r13), %cl
	movl	$1, %eax
	shll	%cl, %eax
	movl	%eax, 8(%r12)
	movq	%r12, %rdi
	movq	%r15, %rsi
	callq	_mlx4_dev_cap
	testl	%eax, %eax
	je	LBB0_14
## %bb.13:
	movl	%eax, %ebx
	leaq	L_.str.3(%rip), %rsi
	jmp	LBB0_5
LBB0_14:
	movq	%r12, %rdi
	callq	_mlx4_QUERY_FW
	testl	%eax, %eax
	je	LBB0_16
## %bb.15:
	leaq	L_.str.4(%rip), %rsi
	movq	%r12, %rdi
	xorl	%eax, %eax
	callq	_mlx4_err
LBB0_16:
	xorl	%ebx, %ebx
	xorl	%eax, %eax
	subl	12(%r12), %eax
	movslq	%eax, %rdx
	movq	%rdx, -48(%rbp)                 ## 8-byte Spill
	leaq	L_.str.5(%rip), %rsi
	movq	%r12, %rdi
	xorl	%eax, %eax
	callq	_mlx4_warn
	movq	-48(%rbp), %rdx                 ## 8-byte Reload
	movq	_PAGE_SIZE@GOTPCREL(%rip), %rsi
	movq	(%rsi), %rcx
	cmpq	%rdx, %rcx
	jae	LBB0_19
## %bb.17:
	leaq	L_.str.6(%rip), %rsi
LBB0_18:
	movq	%r12, %rdi
	xorl	%eax, %eax
	callq	_mlx4_err
	jmp	LBB0_21
LBB0_19:
	movq	8(%r13), %rax
	addq	$12, %rax
	movq	%rax, (%r12)
	movq	_PAGE_SHIFT@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jle	LBB0_22
## %bb.20:
	leaq	L_.str.7(%rip), %rsi
	xorl	%ebx, %ebx
	movq	%r12, %rdi
	xorl	%eax, %eax
	callq	_mlx4_err
LBB0_21:
	movq	_ENODEV@GOTPCREL(%rip), %rax
	jmp	LBB0_7
LBB0_22:
	movq	%r12, %rdi
	movq	%rsi, %rbx
	movq	%r15, %rsi
	callq	_mlx4_set_num_reserved_uars
	movq	(%rbx), %rax
	movq	%rax, 16(%r12)
	movq	%r12, %rdi
	xorl	%esi, %esi
	movq	%r14, %rdx
	callq	_mlx4_QUERY_FUNC_CAP
	testl	%eax, %eax
	je	LBB0_24
## %bb.23:
	movl	%eax, %ebx
	leaq	L_.str.8(%rip), %rsi
	movq	%r12, %rdi
	movl	%eax, %edx
	xorl	%eax, %eax
	callq	_mlx4_err
	jmp	LBB0_8
LBB0_24:
	movq	16(%r14), %rdx
	movq	_PF_CONTEXT_BEHAVIOUR_MASK@GOTPCREL(%rip), %rax
	movq	(%rax), %rcx
	movq	%rcx, %rax
	notq	%rax
	testq	%rdx, %rax
	jne	LBB0_27
## %bb.25:
	movq	24(%r14), %rdx
	movq	%rdx, 24(%r12)
	movl	100(%r14), %eax
	movl	%eax, 160(%r12)
	movups	84(%r14), %xmm0
	movups	%xmm0, 144(%r12)
	movdqu	32(%r13), %xmm0
	pslld	$23, %xmm0
	paddd	LCPI0_0(%rip), %xmm0
	cvttps2dq	%xmm0, %xmm0
	movups	%xmm0, 32(%r12)
	movl	80(%r14), %eax
	movl	%eax, 124(%r12)
	movl	76(%r14), %eax
	movl	%eax, 120(%r12)
	movl	72(%r14), %eax
	movl	%eax, 116(%r12)
	movq	_MLX4_NUM_PDS@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 112(%r12)
	xorps	%xmm0, %xmm0
	movups	%xmm0, 96(%r12)
	movq	_MLX4_MAX_PORTS@GOTPCREL(%rip), %rax
	movq	(%rax), %rcx
	cmpq	%rcx, %rdx
	jbe	LBB0_28
## %bb.26:
	leaq	L_.str.10(%rip), %rsi
	xorl	%ebx, %ebx
	jmp	LBB0_18
LBB0_27:
	leaq	L_.str.9(%rip), %rsi
	xorl	%ebx, %ebx
	movq	%r12, %rdi
	xorl	%eax, %eax
	callq	_mlx4_err
	jmp	LBB0_11
LBB0_28:
	movq	%r12, %rdi
	callq	_mlx4_replace_zero_macs
	movq	%r12, %rdi
	callq	_mlx4_slave_special_qp_cap
	testl	%eax, %eax
	je	LBB0_30
## %bb.29:
	movl	%eax, %ebx
	leaq	L_.str.11(%rip), %rsi
	jmp	LBB0_5
LBB0_30:
	movslq	56(%r12), %rax
	movq	48(%r12), %rbx
	subq	%rax, %rbx
	movq	136(%r12), %rax
	imulq	16(%r12), %rbx
	movl	(%rax), %edi
	movl	$2, %esi
	callq	_pci_resource_len
	cltq
	cmpq	%rax, %rbx
	jbe	LBB0_33
## %bb.31:
	movq	48(%r12), %rcx
	movq	136(%r12), %rax
	imulq	16(%r12), %rcx
	movq	%rcx, -48(%rbp)                 ## 8-byte Spill
	movl	(%rax), %edi
	movl	$2, %esi
	callq	_pci_resource_len
	movslq	%eax, %rcx
	leaq	L_.str.12(%rip), %rsi
	xorl	%ebx, %ebx
	movq	%r12, %rdi
	movq	-48(%rbp), %rdx                 ## 8-byte Reload
	xorl	%eax, %eax
	callq	_mlx4_err
	movq	_ENOMEM@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	testl	%eax, %eax
	je	LBB0_8
## %bb.32:
	negl	%eax
	movq	%r12, %rdi
	movl	%eax, %ebx
	callq	_mlx4_slave_destroy_special_qp_cap
	jmp	LBB0_8
LBB0_33:
	movl	48(%r13), %eax
	movq	_MLX4_DEV_CAP_64B_EQE_ENABLED@GOTPCREL(%rip), %rcx
	xorl	%edx, %edx
	movl	(%rcx), %ecx
	andl	%eax, %ecx
	setne	%dl
	movl	%edx, %ecx
	shll	$5, %ecx
	addl	$32, %ecx
	movl	%ecx, 60(%r12)
	movl	%edx, 64(%r12)
	movq	_MLX4_DEV_CAP_64B_CQE_ENABLED@GOTPCREL(%rip), %rcx
	testl	%eax, (%rcx)
	je	LBB0_35
## %bb.34:
	movq	_MLX4_USER_DEV_CAP_LARGE_CQE@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	orl	%ecx, 92(%r12)
	movl	$64, %ecx
	jmp	LBB0_36
LBB0_35:
	movl	$32, %ecx
LBB0_36:
	movl	%ecx, 68(%r12)
	movq	_MLX4_DEV_CAP_EQE_STRIDE_ENABLED@GOTPCREL(%rip), %rcx
	testl	%eax, (%rcx)
	je	LBB0_38
## %bb.37:
	movl	52(%r13), %ecx
	movl	%ecx, 60(%r12)
	movl	$0, 64(%r12)
LBB0_38:
	movq	_MLX4_DEV_CAP_CQE_STRIDE_ENABLED@GOTPCREL(%rip), %rcx
	testl	%eax, (%rcx)
	je	LBB0_40
## %bb.39:
	movl	56(%r13), %eax
	movl	%eax, 68(%r12)
	movq	_MLX4_USER_DEV_CAP_LARGE_CQE@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	orl	%eax, 92(%r12)
LBB0_40:
	movq	_MLX4_DEV_CAP_FLAG2_TS@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	notl	%eax
	andl	%eax, 88(%r12)
	leaq	L_.str.13(%rip), %rsi
	xorl	%ebx, %ebx
	movq	%r12, %rdi
	xorl	%eax, %eax
	callq	_mlx4_warn
	movq	_MLX4_DEV_CAP_FLAG2_USER_MAC_EN@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	notl	%eax
	andl	%eax, 88(%r12)
	leaq	L_.str.14(%rip), %rsi
	movq	%r12, %rdi
	xorl	%eax, %eax
	callq	_mlx4_dbg
	movq	%r12, %rdi
	movq	%r15, %rsi
	movq	%r13, %rdx
	callq	_slave_adjust_steering_mode
	cmpq	$0, 64(%r13)
	leaq	L_.str.17(%rip), %rax
	leaq	L_.str.16(%rip), %rdx
	cmoveq	%rax, %rdx
	leaq	L_.str.15(%rip), %rsi
	movq	%r12, %rdi
	xorl	%eax, %eax
	callq	_mlx4_dbg
	movl	60(%r14), %eax
	movq	_MLX4_QUERY_FUNC_FLAGS_BF_RES_QP@GOTPCREL(%rip), %rcx
	testl	%eax, (%rcx)
	je	LBB0_43
## %bb.41:
	cmpq	$0, 80(%r12)
	je	LBB0_43
## %bb.42:
	movq	_MLX4_RESERVE_ETH_BF_QP@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	orl	%ecx, 72(%r12)
LBB0_43:
	movq	_MLX4_QUERY_FUNC_FLAGS_A0_RES_QP@GOTPCREL(%rip), %rcx
	testl	%eax, (%rcx)
	je	LBB0_8
## %bb.44:
	movq	_MLX4_RESERVE_A0_QP@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	orl	%eax, 72(%r12)
	jmp	LBB0_8
	.cfi_endproc
                                        ## -- End function
	.comm	_GFP_KERNEL,4,2                 ## @GFP_KERNEL
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Failed to allocate memory for slave_cap\n"

	.comm	_ENOMEM,4,2                     ## @ENOMEM
L_.str.1:                               ## @.str.1
	.asciz	"QUERY_HCA command failed, aborting\n"

L_.str.2:                               ## @.str.2
	.asciz	"Unknown hca global capabilities\n"

	.comm	_EINVAL,4,2                     ## @EINVAL
L_.str.3:                               ## @.str.3
	.asciz	"QUERY_DEV_CAP command failed, aborting\n"

L_.str.4:                               ## @.str.4
	.asciz	"QUERY_FW command failed: could not get FW version\n"

L_.str.5:                               ## @.str.5
	.asciz	"HCA minimum page size:%d\n"

	.comm	_PAGE_SIZE,8,3                  ## @PAGE_SIZE
L_.str.6:                               ## @.str.6
	.asciz	"HCA minimum page size of %d bigger than kernel PAGE_SIZE of %ld, aborting\n"

	.comm	_ENODEV,4,2                     ## @ENODEV
	.comm	_PAGE_SHIFT,8,3                 ## @PAGE_SHIFT
L_.str.7:                               ## @.str.7
	.asciz	"Invalid configuration: uar page size is larger than system page size\n"

L_.str.8:                               ## @.str.8
	.asciz	"QUERY_FUNC_CAP general command failed, aborting (%d)\n"

	.comm	_PF_CONTEXT_BEHAVIOUR_MASK,8,3  ## @PF_CONTEXT_BEHAVIOUR_MASK
L_.str.9:                               ## @.str.9
	.asciz	"Unknown pf context behaviour %x known flags %x\n"

	.comm	_MLX4_NUM_PDS,4,2               ## @MLX4_NUM_PDS
	.comm	_MLX4_MAX_PORTS,8,3             ## @MLX4_MAX_PORTS
L_.str.10:                              ## @.str.10
	.asciz	"HCA has %d ports, but we only support %d, aborting\n"

L_.str.11:                              ## @.str.11
	.asciz	"Set special QP caps failed. aborting\n"

L_.str.12:                              ## @.str.12
	.asciz	"HCA reported UAR region size of 0x%x bigger than PCI resource 2 size of 0x%llx, aborting\n"

	.comm	_MLX4_DEV_CAP_64B_EQE_ENABLED,4,2 ## @MLX4_DEV_CAP_64B_EQE_ENABLED
	.comm	_MLX4_DEV_CAP_64B_CQE_ENABLED,4,2 ## @MLX4_DEV_CAP_64B_CQE_ENABLED
	.comm	_MLX4_USER_DEV_CAP_LARGE_CQE,4,2 ## @MLX4_USER_DEV_CAP_LARGE_CQE
	.comm	_MLX4_DEV_CAP_EQE_STRIDE_ENABLED,4,2 ## @MLX4_DEV_CAP_EQE_STRIDE_ENABLED
	.comm	_MLX4_DEV_CAP_CQE_STRIDE_ENABLED,4,2 ## @MLX4_DEV_CAP_CQE_STRIDE_ENABLED
	.comm	_MLX4_DEV_CAP_FLAG2_TS,4,2      ## @MLX4_DEV_CAP_FLAG2_TS
L_.str.13:                              ## @.str.13
	.asciz	"Timestamping is not supported in slave mode\n"

	.comm	_MLX4_DEV_CAP_FLAG2_USER_MAC_EN,4,2 ## @MLX4_DEV_CAP_FLAG2_USER_MAC_EN
L_.str.14:                              ## @.str.14
	.asciz	"User MAC FW update is not supported in slave mode\n"

L_.str.15:                              ## @.str.15
	.asciz	"RSS support for IP fragments is %s\n"

L_.str.16:                              ## @.str.16
	.asciz	"on"

L_.str.17:                              ## @.str.17
	.asciz	"off"

	.comm	_MLX4_QUERY_FUNC_FLAGS_BF_RES_QP,4,2 ## @MLX4_QUERY_FUNC_FLAGS_BF_RES_QP
	.comm	_MLX4_RESERVE_ETH_BF_QP,4,2     ## @MLX4_RESERVE_ETH_BF_QP
	.comm	_MLX4_QUERY_FUNC_FLAGS_A0_RES_QP,4,2 ## @MLX4_QUERY_FUNC_FLAGS_A0_RES_QP
	.comm	_MLX4_RESERVE_A0_QP,4,2         ## @MLX4_RESERVE_A0_QP
	.no_dead_strip	_mlx4_slave_cap
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function mlx4_slave_cap
_mlx4_slave_cap:                        ; @mlx4_slave_cap
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #80
	.cfi_def_cfa_offset 80
	stp	x24, x23, [sp, #16]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #32]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #48]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #64]             ; 16-byte Folded Spill
	add	x29, sp, #64
	.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
	.cfi_offset w23, -56
	.cfi_offset w24, -64
	mov	x22, x0
Lloh0:
	adrp	x21, _GFP_KERNEL@GOTPAGE
Lloh1:
	ldr	x21, [x21, _GFP_KERNEL@GOTPAGEOFF]
	ldr	w1, [x21]
	mov	w0, #120
	bl	_kzalloc
	mov	x19, x0
	ldr	w1, [x21]
	mov	w0, #120
	bl	_kzalloc
	mov	x20, x0
	ldr	w1, [x21]
	mov	w0, #120
	bl	_kzalloc
	mov	x21, x0
	cmp	x19, #0
	ccmp	x20, #0, #4, ne
	ccmp	x0, #0, #4, ne
	b.ne	LBB0_3
; %bb.1:
Lloh2:
	adrp	x1, l_.str@PAGE
Lloh3:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x22
	bl	_mlx4_err
Lloh4:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh5:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
LBB0_2:
	ldr	w8, [x8]
	neg	w23, w8
	b	LBB0_6
LBB0_3:
	mov	x0, x22
	mov	x1, x19
	bl	_mlx4_QUERY_HCA
	cbz	w0, LBB0_7
; %bb.4:
	mov	x23, x0
Lloh6:
	adrp	x1, l_.str.1@PAGE
Lloh7:
	add	x1, x1, l_.str.1@PAGEOFF
LBB0_5:
	mov	x0, x22
	bl	_mlx4_err
LBB0_6:
	mov	x0, x19
	bl	_kfree
	mov	x0, x20
	bl	_kfree
	mov	x0, x21
	bl	_kfree
	mov	x0, x23
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #32]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #80
	ret
LBB0_7:
	ldr	x8, [x19, #112]
	cbz	x8, LBB0_10
; %bb.8:
Lloh8:
	adrp	x1, l_.str.2@PAGE
Lloh9:
	add	x1, x1, l_.str.2@PAGEOFF
LBB0_9:
	mov	x0, x22
	bl	_mlx4_err
Lloh10:
	adrp	x8, _EINVAL@GOTPAGE
Lloh11:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
	b	LBB0_2
LBB0_10:
	ldr	w8, [x19, #104]
	str	w8, [x22, #128]
	ldr	w8, [x19]
	mov	w9, #1
	lsl	w8, w9, w8
	str	w8, [x22, #8]
	mov	x0, x22
	mov	x1, x21
	bl	_mlx4_dev_cap
	cbz	w0, LBB0_12
; %bb.11:
	mov	x23, x0
Lloh12:
	adrp	x1, l_.str.3@PAGE
Lloh13:
	add	x1, x1, l_.str.3@PAGEOFF
	b	LBB0_5
LBB0_12:
	mov	x0, x22
	bl	_mlx4_QUERY_FW
	cbz	w0, LBB0_14
; %bb.13:
Lloh14:
	adrp	x1, l_.str.4@PAGE
Lloh15:
	add	x1, x1, l_.str.4@PAGEOFF
	mov	x0, x22
	bl	_mlx4_err
LBB0_14:
	ldr	w8, [x22, #12]
	neg	w8, w8
	sxtw	x23, w8
	str	x23, [sp]
Lloh16:
	adrp	x1, l_.str.5@PAGE
Lloh17:
	add	x1, x1, l_.str.5@PAGEOFF
	mov	x0, x22
	bl	_mlx4_warn
Lloh18:
	adrp	x24, _PAGE_SIZE@GOTPAGE
Lloh19:
	ldr	x24, [x24, _PAGE_SIZE@GOTPAGEOFF]
	ldr	x8, [x24]
	cmp	x8, x23
	b.hs	LBB0_16
; %bb.15:
	stp	x23, x8, [sp]
Lloh20:
	adrp	x1, l_.str.6@PAGE
Lloh21:
	add	x1, x1, l_.str.6@PAGEOFF
	b	LBB0_18
LBB0_16:
	ldr	x8, [x19, #8]
	add	x8, x8, #12
	str	x8, [x22]
Lloh22:
	adrp	x9, _PAGE_SHIFT@GOTPAGE
Lloh23:
	ldr	x9, [x9, _PAGE_SHIFT@GOTPAGEOFF]
Lloh24:
	ldr	x9, [x9]
	cmp	x8, x9
	b.le	LBB0_19
; %bb.17:
Lloh25:
	adrp	x1, l_.str.7@PAGE
Lloh26:
	add	x1, x1, l_.str.7@PAGEOFF
LBB0_18:
	mov	x0, x22
	bl	_mlx4_err
Lloh27:
	adrp	x8, _ENODEV@GOTPAGE
Lloh28:
	ldr	x8, [x8, _ENODEV@GOTPAGEOFF]
	b	LBB0_2
LBB0_19:
	mov	x0, x22
	mov	x1, x21
	bl	_mlx4_set_num_reserved_uars
	ldr	x8, [x24]
	str	x8, [x22, #16]
	mov	x0, x22
	mov	w1, #0
	mov	x2, x20
	bl	_mlx4_QUERY_FUNC_CAP
	cbz	w0, LBB0_21
; %bb.20:
	mov	x23, x0
	str	x23, [sp]
Lloh29:
	adrp	x1, l_.str.8@PAGE
Lloh30:
	add	x1, x1, l_.str.8@PAGEOFF
	b	LBB0_5
LBB0_21:
	ldr	x8, [x20, #16]
Lloh31:
	adrp	x9, _PF_CONTEXT_BEHAVIOUR_MASK@GOTPAGE
Lloh32:
	ldr	x9, [x9, _PF_CONTEXT_BEHAVIOUR_MASK@GOTPAGEOFF]
Lloh33:
	ldr	x9, [x9]
	orr	x10, x9, x8
	cmp	x10, x9
	b.ne	LBB0_24
; %bb.22:
	ldr	x8, [x20, #24]
	str	x8, [x22, #24]
	ldr	w9, [x20, #100]
	str	w9, [x22, #160]
	ldur	q0, [x20, #84]
	str	q0, [x22, #144]
	ldr	q0, [x19, #32]
	movi.4s	v1, #1
	ushl.4s	v0, v1, v0
	str	q0, [x22, #32]
	ldr	w9, [x20, #80]
	str	w9, [x22, #124]
	ldr	d0, [x20, #72]
	stur	d0, [x22, #116]
Lloh34:
	adrp	x9, _MLX4_NUM_PDS@GOTPAGE
Lloh35:
	ldr	x9, [x9, _MLX4_NUM_PDS@GOTPAGEOFF]
Lloh36:
	ldr	w9, [x9]
	str	w9, [x22, #112]
	stp	xzr, xzr, [x22, #96]
Lloh37:
	adrp	x9, _MLX4_MAX_PORTS@GOTPAGE
Lloh38:
	ldr	x9, [x9, _MLX4_MAX_PORTS@GOTPAGEOFF]
Lloh39:
	ldr	x9, [x9]
	cmp	x8, x9
	b.ls	LBB0_25
; %bb.23:
	stp	x8, x9, [sp]
Lloh40:
	adrp	x1, l_.str.10@PAGE
Lloh41:
	add	x1, x1, l_.str.10@PAGEOFF
	b	LBB0_18
LBB0_24:
	stp	x8, x9, [sp]
Lloh42:
	adrp	x1, l_.str.9@PAGE
Lloh43:
	add	x1, x1, l_.str.9@PAGEOFF
	b	LBB0_9
LBB0_25:
	mov	x0, x22
	bl	_mlx4_replace_zero_macs
	mov	x0, x22
	bl	_mlx4_slave_special_qp_cap
	cbz	w0, LBB0_27
; %bb.26:
	mov	x23, x0
Lloh44:
	adrp	x1, l_.str.11@PAGE
Lloh45:
	add	x1, x1, l_.str.11@PAGEOFF
	b	LBB0_5
LBB0_27:
	ldr	x8, [x22, #16]
	ldr	x9, [x22, #48]
	ldrsw	x10, [x22, #56]
	sub	x9, x9, x10
	mul	x23, x9, x8
	ldr	x8, [x22, #136]
	ldr	w0, [x8]
	mov	w1, #2
	bl	_pci_resource_len
	cmp	x23, w0, sxtw
	b.ls	LBB0_30
; %bb.28:
	ldr	x8, [x22, #16]
	ldr	x9, [x22, #48]
	mul	x23, x9, x8
	ldr	x8, [x22, #136]
	ldr	w0, [x8]
	mov	w1, #2
	bl	_pci_resource_len
                                        ; kill: def $w0 killed $w0 def $x0
	sxtw	x8, w0
	stp	x23, x8, [sp]
Lloh46:
	adrp	x1, l_.str.12@PAGE
Lloh47:
	add	x1, x1, l_.str.12@PAGEOFF
	mov	x0, x22
	bl	_mlx4_err
Lloh48:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh49:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
Lloh50:
	ldr	w8, [x8]
	cbz	w8, LBB0_41
; %bb.29:
	neg	w23, w8
	mov	x0, x22
	bl	_mlx4_slave_destroy_special_qp_cap
	b	LBB0_6
LBB0_30:
	ldr	w8, [x19, #48]
Lloh51:
	adrp	x9, _MLX4_DEV_CAP_64B_EQE_ENABLED@GOTPAGE
Lloh52:
	ldr	x9, [x9, _MLX4_DEV_CAP_64B_EQE_ENABLED@GOTPAGEOFF]
Lloh53:
	ldr	w9, [x9]
	tst	w9, w8
	cset	w9, ne
	mov	w11, #64
	mov	w10, #32
	csel	w11, w10, w11, eq
	stp	w11, w9, [x22, #60]
Lloh54:
	adrp	x9, _MLX4_DEV_CAP_64B_CQE_ENABLED@GOTPAGE
Lloh55:
	ldr	x9, [x9, _MLX4_DEV_CAP_64B_CQE_ENABLED@GOTPAGEOFF]
Lloh56:
	ldr	w11, [x9]
Lloh57:
	adrp	x9, _MLX4_USER_DEV_CAP_LARGE_CQE@GOTPAGE
Lloh58:
	ldr	x9, [x9, _MLX4_USER_DEV_CAP_LARGE_CQE@GOTPAGEOFF]
	tst	w11, w8
	b.eq	LBB0_32
; %bb.31:
	ldr	w10, [x9]
	ldr	w11, [x22, #92]
	orr	w10, w11, w10
	str	w10, [x22, #92]
	mov	w10, #64
LBB0_32:
	str	w10, [x22, #68]
Lloh59:
	adrp	x10, _MLX4_DEV_CAP_EQE_STRIDE_ENABLED@GOTPAGE
Lloh60:
	ldr	x10, [x10, _MLX4_DEV_CAP_EQE_STRIDE_ENABLED@GOTPAGEOFF]
Lloh61:
	ldr	w10, [x10]
	tst	w10, w8
	b.eq	LBB0_34
; %bb.33:
	ldr	w10, [x19, #52]
	stp	w10, wzr, [x22, #60]
LBB0_34:
Lloh62:
	adrp	x10, _MLX4_DEV_CAP_CQE_STRIDE_ENABLED@GOTPAGE
Lloh63:
	ldr	x10, [x10, _MLX4_DEV_CAP_CQE_STRIDE_ENABLED@GOTPAGEOFF]
Lloh64:
	ldr	w10, [x10]
	tst	w10, w8
	b.eq	LBB0_36
; %bb.35:
	ldr	w8, [x19, #56]
	str	w8, [x22, #68]
	ldr	w8, [x9]
	ldr	w9, [x22, #92]
	orr	w8, w9, w8
	str	w8, [x22, #92]
LBB0_36:
Lloh65:
	adrp	x8, _MLX4_DEV_CAP_FLAG2_TS@GOTPAGE
Lloh66:
	ldr	x8, [x8, _MLX4_DEV_CAP_FLAG2_TS@GOTPAGEOFF]
Lloh67:
	ldr	w8, [x8]
	ldr	w9, [x22, #88]
	bic	w8, w9, w8
	str	w8, [x22, #88]
Lloh68:
	adrp	x1, l_.str.13@PAGE
Lloh69:
	add	x1, x1, l_.str.13@PAGEOFF
	mov	x0, x22
	bl	_mlx4_warn
Lloh70:
	adrp	x8, _MLX4_DEV_CAP_FLAG2_USER_MAC_EN@GOTPAGE
Lloh71:
	ldr	x8, [x8, _MLX4_DEV_CAP_FLAG2_USER_MAC_EN@GOTPAGEOFF]
Lloh72:
	ldr	w8, [x8]
	ldr	w9, [x22, #88]
	bic	w8, w9, w8
	str	w8, [x22, #88]
Lloh73:
	adrp	x1, l_.str.14@PAGE
Lloh74:
	add	x1, x1, l_.str.14@PAGEOFF
	mov	x0, x22
	bl	_mlx4_dbg
	mov	x0, x22
	mov	x1, x21
	mov	x2, x19
	bl	_slave_adjust_steering_mode
	ldr	x8, [x19, #64]
Lloh75:
	adrp	x9, l_.str.16@PAGE
Lloh76:
	add	x9, x9, l_.str.16@PAGEOFF
Lloh77:
	adrp	x10, l_.str.17@PAGE
Lloh78:
	add	x10, x10, l_.str.17@PAGEOFF
	cmp	x8, #0
	csel	x8, x10, x9, eq
	str	x8, [sp]
Lloh79:
	adrp	x1, l_.str.15@PAGE
Lloh80:
	add	x1, x1, l_.str.15@PAGEOFF
	mov	x0, x22
	bl	_mlx4_dbg
	ldr	w8, [x20, #60]
Lloh81:
	adrp	x9, _MLX4_QUERY_FUNC_FLAGS_BF_RES_QP@GOTPAGE
Lloh82:
	ldr	x9, [x9, _MLX4_QUERY_FUNC_FLAGS_BF_RES_QP@GOTPAGEOFF]
Lloh83:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_39
; %bb.37:
	ldr	x9, [x22, #80]
	cbz	x9, LBB0_39
; %bb.38:
Lloh84:
	adrp	x9, _MLX4_RESERVE_ETH_BF_QP@GOTPAGE
Lloh85:
	ldr	x9, [x9, _MLX4_RESERVE_ETH_BF_QP@GOTPAGEOFF]
Lloh86:
	ldr	w9, [x9]
	ldr	w10, [x22, #72]
	orr	w9, w10, w9
	str	w9, [x22, #72]
LBB0_39:
Lloh87:
	adrp	x9, _MLX4_QUERY_FUNC_FLAGS_A0_RES_QP@GOTPAGE
Lloh88:
	ldr	x9, [x9, _MLX4_QUERY_FUNC_FLAGS_A0_RES_QP@GOTPAGEOFF]
Lloh89:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_41
; %bb.40:
	mov	w23, #0
Lloh90:
	adrp	x8, _MLX4_RESERVE_A0_QP@GOTPAGE
Lloh91:
	ldr	x8, [x8, _MLX4_RESERVE_A0_QP@GOTPAGEOFF]
Lloh92:
	ldr	w8, [x8]
	ldr	w9, [x22, #72]
	orr	w8, w9, w8
	str	w8, [x22, #72]
	b	LBB0_6
LBB0_41:
	mov	w23, #0
	b	LBB0_6
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh4, Lloh5
	.loh AdrpAdd	Lloh2, Lloh3
	.loh AdrpAdd	Lloh6, Lloh7
	.loh AdrpAdd	Lloh8, Lloh9
	.loh AdrpLdrGot	Lloh10, Lloh11
	.loh AdrpAdd	Lloh12, Lloh13
	.loh AdrpAdd	Lloh14, Lloh15
	.loh AdrpLdrGot	Lloh18, Lloh19
	.loh AdrpAdd	Lloh16, Lloh17
	.loh AdrpAdd	Lloh20, Lloh21
	.loh AdrpLdrGotLdr	Lloh22, Lloh23, Lloh24
	.loh AdrpAdd	Lloh25, Lloh26
	.loh AdrpLdrGot	Lloh27, Lloh28
	.loh AdrpAdd	Lloh29, Lloh30
	.loh AdrpLdrGotLdr	Lloh31, Lloh32, Lloh33
	.loh AdrpLdrGotLdr	Lloh37, Lloh38, Lloh39
	.loh AdrpLdrGotLdr	Lloh34, Lloh35, Lloh36
	.loh AdrpAdd	Lloh40, Lloh41
	.loh AdrpAdd	Lloh42, Lloh43
	.loh AdrpAdd	Lloh44, Lloh45
	.loh AdrpLdrGotLdr	Lloh48, Lloh49, Lloh50
	.loh AdrpAdd	Lloh46, Lloh47
	.loh AdrpLdrGot	Lloh57, Lloh58
	.loh AdrpLdrGotLdr	Lloh54, Lloh55, Lloh56
	.loh AdrpLdrGotLdr	Lloh51, Lloh52, Lloh53
	.loh AdrpLdrGotLdr	Lloh59, Lloh60, Lloh61
	.loh AdrpLdrGotLdr	Lloh62, Lloh63, Lloh64
	.loh AdrpLdrGotLdr	Lloh81, Lloh82, Lloh83
	.loh AdrpAdd	Lloh79, Lloh80
	.loh AdrpAdd	Lloh77, Lloh78
	.loh AdrpAdd	Lloh75, Lloh76
	.loh AdrpAdd	Lloh73, Lloh74
	.loh AdrpLdrGotLdr	Lloh70, Lloh71, Lloh72
	.loh AdrpAdd	Lloh68, Lloh69
	.loh AdrpLdrGotLdr	Lloh65, Lloh66, Lloh67
	.loh AdrpLdrGotLdr	Lloh84, Lloh85, Lloh86
	.loh AdrpLdrGotLdr	Lloh87, Lloh88, Lloh89
	.loh AdrpLdrGotLdr	Lloh90, Lloh91, Lloh92
	.cfi_endproc
                                        ; -- End function
	.comm	_GFP_KERNEL,4,2                 ; @GFP_KERNEL
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Failed to allocate memory for slave_cap\n"

	.comm	_ENOMEM,4,2                     ; @ENOMEM
l_.str.1:                               ; @.str.1
	.asciz	"QUERY_HCA command failed, aborting\n"

l_.str.2:                               ; @.str.2
	.asciz	"Unknown hca global capabilities\n"

	.comm	_EINVAL,4,2                     ; @EINVAL
l_.str.3:                               ; @.str.3
	.asciz	"QUERY_DEV_CAP command failed, aborting\n"

l_.str.4:                               ; @.str.4
	.asciz	"QUERY_FW command failed: could not get FW version\n"

l_.str.5:                               ; @.str.5
	.asciz	"HCA minimum page size:%d\n"

	.comm	_PAGE_SIZE,8,3                  ; @PAGE_SIZE
l_.str.6:                               ; @.str.6
	.asciz	"HCA minimum page size of %d bigger than kernel PAGE_SIZE of %ld, aborting\n"

	.comm	_ENODEV,4,2                     ; @ENODEV
	.comm	_PAGE_SHIFT,8,3                 ; @PAGE_SHIFT
l_.str.7:                               ; @.str.7
	.asciz	"Invalid configuration: uar page size is larger than system page size\n"

l_.str.8:                               ; @.str.8
	.asciz	"QUERY_FUNC_CAP general command failed, aborting (%d)\n"

	.comm	_PF_CONTEXT_BEHAVIOUR_MASK,8,3  ; @PF_CONTEXT_BEHAVIOUR_MASK
l_.str.9:                               ; @.str.9
	.asciz	"Unknown pf context behaviour %x known flags %x\n"

	.comm	_MLX4_NUM_PDS,4,2               ; @MLX4_NUM_PDS
	.comm	_MLX4_MAX_PORTS,8,3             ; @MLX4_MAX_PORTS
l_.str.10:                              ; @.str.10
	.asciz	"HCA has %d ports, but we only support %d, aborting\n"

l_.str.11:                              ; @.str.11
	.asciz	"Set special QP caps failed. aborting\n"

l_.str.12:                              ; @.str.12
	.asciz	"HCA reported UAR region size of 0x%x bigger than PCI resource 2 size of 0x%llx, aborting\n"

	.comm	_MLX4_DEV_CAP_64B_EQE_ENABLED,4,2 ; @MLX4_DEV_CAP_64B_EQE_ENABLED
	.comm	_MLX4_DEV_CAP_64B_CQE_ENABLED,4,2 ; @MLX4_DEV_CAP_64B_CQE_ENABLED
	.comm	_MLX4_USER_DEV_CAP_LARGE_CQE,4,2 ; @MLX4_USER_DEV_CAP_LARGE_CQE
	.comm	_MLX4_DEV_CAP_EQE_STRIDE_ENABLED,4,2 ; @MLX4_DEV_CAP_EQE_STRIDE_ENABLED
	.comm	_MLX4_DEV_CAP_CQE_STRIDE_ENABLED,4,2 ; @MLX4_DEV_CAP_CQE_STRIDE_ENABLED
	.comm	_MLX4_DEV_CAP_FLAG2_TS,4,2      ; @MLX4_DEV_CAP_FLAG2_TS
l_.str.13:                              ; @.str.13
	.asciz	"Timestamping is not supported in slave mode\n"

	.comm	_MLX4_DEV_CAP_FLAG2_USER_MAC_EN,4,2 ; @MLX4_DEV_CAP_FLAG2_USER_MAC_EN
l_.str.14:                              ; @.str.14
	.asciz	"User MAC FW update is not supported in slave mode\n"

l_.str.15:                              ; @.str.15
	.asciz	"RSS support for IP fragments is %s\n"

l_.str.16:                              ; @.str.16
	.asciz	"on"

l_.str.17:                              ; @.str.17
	.asciz	"off"

	.comm	_MLX4_QUERY_FUNC_FLAGS_BF_RES_QP,4,2 ; @MLX4_QUERY_FUNC_FLAGS_BF_RES_QP
	.comm	_MLX4_RESERVE_ETH_BF_QP,4,2     ; @MLX4_RESERVE_ETH_BF_QP
	.comm	_MLX4_QUERY_FUNC_FLAGS_A0_RES_QP,4,2 ; @MLX4_QUERY_FUNC_FLAGS_A0_RES_QP
	.comm	_MLX4_RESERVE_A0_QP,4,2         ; @MLX4_RESERVE_A0_QP
	.no_dead_strip	_mlx4_slave_cap
.subsections_via_symbols
