	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_mlx5_query_hca_vport_gid       ## -- Begin function mlx5_query_hca_vport_gid
	.p2align	4, 0x90
_mlx5_query_hca_vport_gid:              ## @mlx5_query_hca_vport_gid
	.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
	subq	$40, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%r9, -80(%rbp)                  ## 8-byte Spill
	movl	%r8d, %ebx
	movl	%ecx, %r15d
	movl	%edx, -56(%rbp)                 ## 4-byte Spill
	movl	%esi, -44(%rbp)                 ## 4-byte Spill
	movq	%rdi, %r13
	movq	_query_hca_vport_gid_in@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_MLX5_ST_SZ_BYTES
	movl	%eax, -48(%rbp)                 ## 4-byte Spill
	movq	_query_hca_vport_gid_out@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_MLX5_ST_SZ_BYTES
	movl	%eax, %r14d
	movq	_vport_group_manager@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r13, %rdi
	callq	_MLX5_CAP_GEN
	movl	%eax, -60(%rbp)                 ## 4-byte Spill
	movq	_gid_table_size@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r13, %rdi
	callq	_MLX5_CAP_GEN
	movl	%eax, %edi
	callq	_mlx5_get_gid_table_len
	movl	%eax, %r12d
	leaq	L_.str(%rip), %rsi
	movq	%r13, %rdi
	movl	%r15d, -52(%rbp)                ## 4-byte Spill
	movl	%r15d, %edx
	movl	%ebx, %ecx
	movl	%eax, %r8d
	callq	_mlx5_core_dbg
	cmpl	$65535, %ebx                    ## imm = 0xFFFF
	je	LBB0_3
## %bb.1:
	cmpl	%ebx, %r12d
	jge	LBB0_3
## %bb.2:
	movq	_EINVAL@GOTPCREL(%rip), %rax
	xorl	%ebx, %ebx
	subl	(%rax), %ebx
	jmp	LBB0_14
LBB0_3:
	shll	$3, %r12d
	cmpl	$65535, %ebx                    ## imm = 0xFFFF
	movl	$8, %r15d
	cmovel	%r12d, %r15d
	addl	%r14d, %r15d
	movq	_GFP_KERNEL@GOTPCREL(%rip), %r12
	movl	(%r12), %esi
	movl	-48(%rbp), %edi                 ## 4-byte Reload
	callq	_kzalloc
	movq	%rax, %r14
	movl	(%r12), %esi
	movl	%r15d, %edi
	callq	_kzalloc
	movq	%rax, %r12
	testq	%r14, %r14
	je	LBB0_5
## %bb.4:
	testq	%r12, %r12
	je	LBB0_5
## %bb.6:
	movq	%r12, -72(%rbp)                 ## 8-byte Spill
	movq	_query_hca_vport_gid_in@GOTPCREL(%rip), %r12
	movl	(%r12), %edi
	movq	_opcode@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	_MLX5_CMD_OP_QUERY_HCA_VPORT_GID@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	movq	%r14, %rsi
	callq	_MLX5_SET
	cmpl	$0, -44(%rbp)                   ## 4-byte Folded Reload
	je	LBB0_9
## %bb.7:
	cmpl	$0, -60(%rbp)                   ## 4-byte Folded Reload
	je	LBB0_15
## %bb.8:
	movl	(%r12), %edi
	movq	_vport_number@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%r14, %rsi
	movl	-52(%rbp), %ecx                 ## 4-byte Reload
	callq	_MLX5_SET
	movl	(%r12), %edi
	movq	%r14, %rsi
	movl	-44(%rbp), %edx                 ## 4-byte Reload
	movl	$1, %ecx
	callq	_MLX5_SET
LBB0_9:
	movl	(%r12), %edi
	movq	%r14, %rsi
	movl	%ebx, %edx
	movl	%ebx, %ecx
	callq	_MLX5_SET
	movq	_num_ports@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r13, %rdi
	callq	_MLX5_CAP_GEN
	cmpl	$2, %eax
	jne	LBB0_11
## %bb.10:
	movl	(%r12), %edi
	movq	%r14, %rsi
	movl	-56(%rbp), %ecx                 ## 4-byte Reload
	movl	%ecx, %edx
	callq	_MLX5_SET
LBB0_11:
	movq	%r13, %rdi
	movq	%r14, %rsi
	movl	-48(%rbp), %edx                 ## 4-byte Reload
	movq	-72(%rbp), %r12                 ## 8-byte Reload
	movq	%r12, %rcx
	movl	%r15d, %r8d
	callq	_mlx5_cmd_exec
	movl	%eax, %ebx
	testl	%eax, %eax
	jne	LBB0_13
## %bb.12:
	movq	_query_hca_vport_gid_out@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_MLX5_ST_SZ_BYTES
	cltq
	movl	4(%r12,%rax), %ecx
	movq	-80(%rbp), %rdx                 ## 8-byte Reload
	movl	%ecx, 4(%rdx)
	movl	(%r12,%rax), %eax
	movl	%eax, (%rdx)
	xorl	%ebx, %ebx
	jmp	LBB0_13
LBB0_5:
	movq	_ENOMEM@GOTPCREL(%rip), %rax
	xorl	%ebx, %ebx
	subl	(%rax), %ebx
LBB0_13:
	movq	%r14, %rdi
	callq	_kfree
	movq	%r12, %rdi
	callq	_kfree
LBB0_14:
	movl	%ebx, %eax
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_15:
	movq	_EPERM@GOTPCREL(%rip), %rax
	xorl	%ebx, %ebx
	subl	(%rax), %ebx
	movq	-72(%rbp), %r12                 ## 8-byte Reload
	jmp	LBB0_13
	.cfi_endproc
                                        ## -- End function
	.comm	_query_hca_vport_gid_in,4,2     ## @query_hca_vport_gid_in
	.comm	_query_hca_vport_gid_out,4,2    ## @query_hca_vport_gid_out
	.comm	_vport_group_manager,4,2        ## @vport_group_manager
	.comm	_gid_table_size,4,2             ## @gid_table_size
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"vf_num %d, index %d, gid_table_size %d\n"

	.comm	_EINVAL,4,2                     ## @EINVAL
	.comm	_GFP_KERNEL,4,2                 ## @GFP_KERNEL
	.comm	_ENOMEM,4,2                     ## @ENOMEM
	.comm	_opcode,4,2                     ## @opcode
	.comm	_MLX5_CMD_OP_QUERY_HCA_VPORT_GID,4,2 ## @MLX5_CMD_OP_QUERY_HCA_VPORT_GID
	.comm	_vport_number,4,2               ## @vport_number
	.comm	_EPERM,4,2                      ## @EPERM
	.comm	_num_ports,4,2                  ## @num_ports
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_mlx5_query_hca_vport_gid       ; -- Begin function mlx5_query_hca_vport_gid
	.p2align	2
_mlx5_query_hca_vport_gid:              ; @mlx5_query_hca_vport_gid
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #112
	.cfi_def_cfa_offset 112
	stp	x28, x27, [sp, #16]             ; 16-byte Folded Spill
	stp	x26, x25, [sp, #32]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #48]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #64]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #80]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #96]             ; 16-byte Folded Spill
	add	x29, sp, #96
	.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
	.cfi_offset w25, -72
	.cfi_offset w26, -80
	.cfi_offset w27, -88
	.cfi_offset w28, -96
	mov	x28, x5
	mov	x24, x4
	mov	x27, x3
	str	w2, [sp, #12]                   ; 4-byte Folded Spill
	mov	x26, x1
	mov	x20, x0
Lloh0:
	adrp	x21, _query_hca_vport_gid_in@GOTPAGE
Lloh1:
	ldr	x21, [x21, _query_hca_vport_gid_in@GOTPAGEOFF]
	ldr	w0, [x21]
	bl	_MLX5_ST_SZ_BYTES
	mov	x22, x0
Lloh2:
	adrp	x8, _query_hca_vport_gid_out@GOTPAGE
Lloh3:
	ldr	x8, [x8, _query_hca_vport_gid_out@GOTPAGEOFF]
Lloh4:
	ldr	w0, [x8]
	bl	_MLX5_ST_SZ_BYTES
	mov	x23, x0
Lloh5:
	adrp	x8, _vport_group_manager@GOTPAGE
Lloh6:
	ldr	x8, [x8, _vport_group_manager@GOTPAGEOFF]
Lloh7:
	ldr	w1, [x8]
	mov	x0, x20
	bl	_MLX5_CAP_GEN
	mov	x19, x0
Lloh8:
	adrp	x8, _gid_table_size@GOTPAGE
Lloh9:
	ldr	x8, [x8, _gid_table_size@GOTPAGEOFF]
Lloh10:
	ldr	w1, [x8]
	mov	x0, x20
	bl	_MLX5_CAP_GEN
	bl	_mlx5_get_gid_table_len
	mov	x25, x0
Lloh11:
	adrp	x1, l_.str@PAGE
Lloh12:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x20
	mov	x2, x27
	mov	x3, x24
	mov	x4, x25
	bl	_mlx5_core_dbg
	mov	w8, #65535
	cmp	w24, w8
	b.eq	LBB0_3
; %bb.1:
	cmp	w25, w24
	b.ge	LBB0_3
; %bb.2:
Lloh13:
	adrp	x8, _EINVAL@GOTPAGE
Lloh14:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh15:
	ldr	w8, [x8]
	neg	w19, w8
	b	LBB0_14
LBB0_3:
	str	x28, [sp]                       ; 8-byte Folded Spill
	lsl	w9, w25, #3
	mov	w10, #8
	cmp	w24, w8
	csel	w8, w9, w10, eq
	add	w28, w8, w23
Lloh16:
	adrp	x25, _GFP_KERNEL@GOTPAGE
Lloh17:
	ldr	x25, [x25, _GFP_KERNEL@GOTPAGEOFF]
	ldr	w1, [x25]
	mov	x0, x22
	bl	_kzalloc
	mov	x23, x0
	ldr	w1, [x25]
	mov	x0, x28
	bl	_kzalloc
	mov	x25, x0
	cmp	x23, #0
	ccmp	x0, #0, #4, ne
	b.ne	LBB0_6
; %bb.4:
Lloh18:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh19:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
LBB0_5:
	ldr	w8, [x8]
	neg	w19, w8
	b	LBB0_13
LBB0_6:
	ldr	w0, [x21]
Lloh20:
	adrp	x8, _opcode@GOTPAGE
Lloh21:
	ldr	x8, [x8, _opcode@GOTPAGEOFF]
Lloh22:
	ldr	w2, [x8]
Lloh23:
	adrp	x8, _MLX5_CMD_OP_QUERY_HCA_VPORT_GID@GOTPAGE
Lloh24:
	ldr	x8, [x8, _MLX5_CMD_OP_QUERY_HCA_VPORT_GID@GOTPAGEOFF]
Lloh25:
	ldr	w3, [x8]
	mov	x1, x23
	bl	_MLX5_SET
	cbz	w26, LBB0_9
; %bb.7:
	cbz	w19, LBB0_15
; %bb.8:
	ldr	w0, [x21]
Lloh26:
	adrp	x8, _vport_number@GOTPAGE
Lloh27:
	ldr	x8, [x8, _vport_number@GOTPAGEOFF]
Lloh28:
	ldr	w2, [x8]
	mov	x1, x23
	mov	x3, x27
	bl	_MLX5_SET
	ldr	w0, [x21]
	mov	x1, x23
	mov	x2, x26
	mov	w3, #1
	bl	_MLX5_SET
LBB0_9:
	ldr	w0, [x21]
	mov	x1, x23
	mov	x2, x24
	mov	x3, x24
	bl	_MLX5_SET
Lloh29:
	adrp	x8, _num_ports@GOTPAGE
Lloh30:
	ldr	x8, [x8, _num_ports@GOTPAGEOFF]
Lloh31:
	ldr	w1, [x8]
	mov	x0, x20
	bl	_MLX5_CAP_GEN
	cmp	w0, #2
	b.ne	LBB0_11
; %bb.10:
	ldr	w0, [x21]
	mov	x1, x23
	ldr	w2, [sp, #12]                   ; 4-byte Folded Reload
	mov	x3, x2
	bl	_MLX5_SET
LBB0_11:
	mov	x0, x20
	mov	x1, x23
	mov	x2, x22
	mov	x3, x25
	mov	x4, x28
	bl	_mlx5_cmd_exec
	mov	x19, x0
	cbnz	w0, LBB0_13
; %bb.12:
Lloh32:
	adrp	x8, _query_hca_vport_gid_out@GOTPAGE
Lloh33:
	ldr	x8, [x8, _query_hca_vport_gid_out@GOTPAGEOFF]
Lloh34:
	ldr	w0, [x8]
	bl	_MLX5_ST_SZ_BYTES
	add	x8, x25, w0, sxtw
	ldr	w9, [x8, #4]
	ldr	x10, [sp]                       ; 8-byte Folded Reload
	str	w9, [x10, #4]
	ldr	w8, [x8]
	str	w8, [x10]
LBB0_13:
	mov	x0, x23
	bl	_kfree
	mov	x0, x25
	bl	_kfree
LBB0_14:
	mov	x0, x19
	ldp	x29, x30, [sp, #96]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #80]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #64]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #48]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #32]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #112
	ret
LBB0_15:
Lloh35:
	adrp	x8, _EPERM@GOTPAGE
Lloh36:
	ldr	x8, [x8, _EPERM@GOTPAGEOFF]
	b	LBB0_5
	.loh AdrpAdd	Lloh11, Lloh12
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh13, Lloh14, Lloh15
	.loh AdrpLdrGot	Lloh16, Lloh17
	.loh AdrpLdrGot	Lloh18, Lloh19
	.loh AdrpLdrGotLdr	Lloh23, Lloh24, Lloh25
	.loh AdrpLdrGotLdr	Lloh20, Lloh21, Lloh22
	.loh AdrpLdrGotLdr	Lloh26, Lloh27, Lloh28
	.loh AdrpLdrGotLdr	Lloh29, Lloh30, Lloh31
	.loh AdrpLdrGotLdr	Lloh32, Lloh33, Lloh34
	.loh AdrpLdrGot	Lloh35, Lloh36
	.cfi_endproc
                                        ; -- End function
	.comm	_query_hca_vport_gid_in,4,2     ; @query_hca_vport_gid_in
	.comm	_query_hca_vport_gid_out,4,2    ; @query_hca_vport_gid_out
	.comm	_vport_group_manager,4,2        ; @vport_group_manager
	.comm	_gid_table_size,4,2             ; @gid_table_size
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"vf_num %d, index %d, gid_table_size %d\n"

	.comm	_EINVAL,4,2                     ; @EINVAL
	.comm	_GFP_KERNEL,4,2                 ; @GFP_KERNEL
	.comm	_ENOMEM,4,2                     ; @ENOMEM
	.comm	_opcode,4,2                     ; @opcode
	.comm	_MLX5_CMD_OP_QUERY_HCA_VPORT_GID,4,2 ; @MLX5_CMD_OP_QUERY_HCA_VPORT_GID
	.comm	_vport_number,4,2               ; @vport_number
	.comm	_EPERM,4,2                      ; @EPERM
	.comm	_num_ports,4,2                  ; @num_ports
.subsections_via_symbols
