	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function _mlx5_eswitch_set_vepa_locked
__mlx5_eswitch_set_vepa_locked:         ## @_mlx5_eswitch_set_vepa_locked
	.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	%rdi, %rbx
	xorps	%xmm0, %xmm0
	movaps	%xmm0, -80(%rbp)
	movq	$0, -64(%rbp)
	testl	%esi, %esi
	je	LBB0_7
## %bb.1:
	xorl	%r14d, %r14d
	cmpq	$0, 16(%rbx)
	jne	LBB0_9
## %bb.2:
	movq	_GFP_KERNEL@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	$24, %edi
	callq	_kvzalloc
	testq	%rax, %rax
	je	LBB0_10
## %bb.3:
	movq	%rax, %r15
	movq	_fte_match_param@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movl	20(%r15), %esi
	movq	_misc_parameters@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	callq	_MLX5_ADDR_OF
	movq	_fte_match_set_misc@GOTPCREL(%rip), %r12
	movl	(%r12), %edi
	movq	_source_port@GOTPCREL(%rip), %r13
	movl	(%r13), %edx
	movq	_MLX5_VPORT_UPLINK@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	movq	%rax, %rsi
	callq	_MLX5_SET
	movq	_fte_match_param@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movl	16(%r15), %esi
	movq	_misc_parameters@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	callq	_MLX5_ADDR_OF
	movl	(%r12), %edi
	movl	(%r13), %edx
	movq	%rax, %rsi
	callq	_MLX5_SET_TO_ONES
	movq	_MLX5_MATCH_MISC_PARAMETERS@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 12(%r15)
	movq	_MLX5_FLOW_DESTINATION_TYPE_FLOW_TABLE@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, -76(%rbp)
	movl	24(%rbx), %eax
	movl	%eax, -72(%rbp)
	movq	_MLX5_FLOW_CONTEXT_ACTION_FWD_DEST@GOTPCREL(%rip), %r13
	movq	(%r13), %rax
	movq	%rax, -48(%rbp)
	movl	8(%rbx), %edi
	leaq	-48(%rbp), %rdx
	leaq	-80(%rbp), %rcx
	movq	%r15, %rsi
	movl	$1, %r8d
	callq	_mlx5_add_flow_rules
	movq	%rax, %r12
	movq	%rax, %rdi
	callq	_IS_ERR
	testq	%rax, %rax
	jne	LBB0_5
## %bb.4:
	movq	%r12, 16(%rbx)
	movq	%r15, %rdi
	xorl	%esi, %esi
	movl	$24, %edx
	callq	_memset
	leaq	-80(%rbp), %r12
	movq	%r12, %rdi
	xorl	%esi, %esi
	movl	$24, %edx
	callq	_memset
	movq	_MLX5_FLOW_DESTINATION_TYPE_VPORT@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, -76(%rbp)
	movq	_MLX5_VPORT_UPLINK@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, -80(%rbp)
	movq	(%r13), %rax
	movq	%rax, -48(%rbp)
	movl	8(%rbx), %edi
	leaq	-48(%rbp), %rdx
	movq	%r15, %rsi
	movq	%r12, %rcx
	movl	$1, %r8d
	callq	_mlx5_add_flow_rules
	movq	%rax, %r12
	movq	%rax, %rdi
	callq	_IS_ERR
	testq	%rax, %rax
	je	LBB0_11
LBB0_5:
	movq	%r12, %rdi
	callq	_PTR_ERR
	movl	%eax, %r12d
	movq	%r15, %rdi
	callq	_kvfree
	testl	%r12d, %r12d
	je	LBB0_9
## %bb.6:
	movq	%rbx, %rdi
	callq	_esw_cleanup_vepa_rules
	movl	%r12d, %r14d
	jmp	LBB0_9
LBB0_7:
	movq	%rbx, %rdi
	callq	_esw_cleanup_vepa_rules
LBB0_8:
	xorl	%r14d, %r14d
LBB0_9:
	movl	%r14d, %eax
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_10:
	movq	_ENOMEM@GOTPCREL(%rip), %rax
	xorl	%r14d, %r14d
	subl	(%rax), %r14d
	jmp	LBB0_9
LBB0_11:
	movq	%r12, (%rbx)
	movq	%r15, %rdi
	callq	_kvfree
	jmp	LBB0_8
	.cfi_endproc
                                        ## -- End function
	.comm	_GFP_KERNEL,4,2                 ## @GFP_KERNEL
	.comm	_ENOMEM,4,2                     ## @ENOMEM
	.comm	_fte_match_param,4,2            ## @fte_match_param
	.comm	_misc_parameters,4,2            ## @misc_parameters
	.comm	_fte_match_set_misc,4,2         ## @fte_match_set_misc
	.comm	_source_port,4,2                ## @source_port
	.comm	_MLX5_VPORT_UPLINK,4,2          ## @MLX5_VPORT_UPLINK
	.comm	_MLX5_MATCH_MISC_PARAMETERS,4,2 ## @MLX5_MATCH_MISC_PARAMETERS
	.comm	_MLX5_FLOW_DESTINATION_TYPE_FLOW_TABLE,4,2 ## @MLX5_FLOW_DESTINATION_TYPE_FLOW_TABLE
	.comm	_MLX5_FLOW_CONTEXT_ACTION_FWD_DEST,8,3 ## @MLX5_FLOW_CONTEXT_ACTION_FWD_DEST
	.comm	_MLX5_FLOW_DESTINATION_TYPE_VPORT,4,2 ## @MLX5_FLOW_DESTINATION_TYPE_VPORT
	.no_dead_strip	__mlx5_eswitch_set_vepa_locked
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function _mlx5_eswitch_set_vepa_locked
__mlx5_eswitch_set_vepa_locked:         ; @_mlx5_eswitch_set_vepa_locked
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #112
	.cfi_def_cfa_offset 112
	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
	mov	x19, x0
	stp	xzr, xzr, [sp, #8]
	str	xzr, [sp, #24]
	cbz	w1, LBB0_7
; %bb.1:
	ldr	x8, [x19, #16]
	cbnz	x8, LBB0_8
; %bb.2:
Lloh0:
	adrp	x8, _GFP_KERNEL@GOTPAGE
Lloh1:
	ldr	x8, [x8, _GFP_KERNEL@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
	mov	w0, #24
	bl	_kvzalloc
	cbz	x0, LBB0_10
; %bb.3:
	mov	x20, x0
Lloh3:
	adrp	x21, _fte_match_param@GOTPAGE
Lloh4:
	ldr	x21, [x21, _fte_match_param@GOTPAGEOFF]
	ldr	w0, [x21]
	ldr	w1, [x20, #20]
Lloh5:
	adrp	x23, _misc_parameters@GOTPAGE
Lloh6:
	ldr	x23, [x23, _misc_parameters@GOTPAGEOFF]
	ldr	w2, [x23]
	bl	_MLX5_ADDR_OF
	mov	x1, x0
Lloh7:
	adrp	x24, _fte_match_set_misc@GOTPAGE
Lloh8:
	ldr	x24, [x24, _fte_match_set_misc@GOTPAGEOFF]
	ldr	w0, [x24]
Lloh9:
	adrp	x25, _source_port@GOTPAGE
Lloh10:
	ldr	x25, [x25, _source_port@GOTPAGEOFF]
	ldr	w2, [x25]
Lloh11:
	adrp	x22, _MLX5_VPORT_UPLINK@GOTPAGE
Lloh12:
	ldr	x22, [x22, _MLX5_VPORT_UPLINK@GOTPAGEOFF]
	ldr	w3, [x22]
	bl	_MLX5_SET
	ldr	w0, [x21]
	ldr	w1, [x20, #16]
	ldr	w2, [x23]
	bl	_MLX5_ADDR_OF
	mov	x1, x0
	ldr	w0, [x24]
	ldr	w2, [x25]
	bl	_MLX5_SET_TO_ONES
Lloh13:
	adrp	x8, _MLX5_MATCH_MISC_PARAMETERS@GOTPAGE
Lloh14:
	ldr	x8, [x8, _MLX5_MATCH_MISC_PARAMETERS@GOTPAGEOFF]
Lloh15:
	ldr	w8, [x8]
	str	w8, [x20, #12]
Lloh16:
	adrp	x8, _MLX5_FLOW_DESTINATION_TYPE_FLOW_TABLE@GOTPAGE
Lloh17:
	ldr	x8, [x8, _MLX5_FLOW_DESTINATION_TYPE_FLOW_TABLE@GOTPAGEOFF]
Lloh18:
	ldr	w8, [x8]
	ldr	w9, [x19, #24]
	stp	w8, w9, [sp, #12]
Lloh19:
	adrp	x23, _MLX5_FLOW_CONTEXT_ACTION_FWD_DEST@GOTPAGE
Lloh20:
	ldr	x23, [x23, _MLX5_FLOW_CONTEXT_ACTION_FWD_DEST@GOTPAGEOFF]
	ldr	x8, [x23]
	str	x8, [sp]
	ldr	w0, [x19, #8]
	mov	x2, sp
	add	x3, sp, #8
	mov	x1, x20
	mov	w4, #1
	bl	_mlx5_add_flow_rules
	mov	x21, x0
	bl	_IS_ERR
	cbnz	x0, LBB0_5
; %bb.4:
	str	x21, [x19, #16]
	mov	x0, x20
	mov	w1, #0
	mov	w2, #24
	bl	_memset
	add	x0, sp, #8
	mov	w1, #0
	mov	w2, #24
	bl	_memset
Lloh21:
	adrp	x8, _MLX5_FLOW_DESTINATION_TYPE_VPORT@GOTPAGE
Lloh22:
	ldr	x8, [x8, _MLX5_FLOW_DESTINATION_TYPE_VPORT@GOTPAGEOFF]
Lloh23:
	ldr	w8, [x8]
	ldr	w9, [x22]
	stp	w9, w8, [sp, #8]
	ldr	x8, [x23]
	str	x8, [sp]
	ldr	w0, [x19, #8]
	mov	x2, sp
	add	x3, sp, #8
	mov	x1, x20
	mov	w4, #1
	bl	_mlx5_add_flow_rules
	mov	x21, x0
	bl	_IS_ERR
	cbz	x0, LBB0_11
LBB0_5:
	mov	x0, x21
	bl	_PTR_ERR
	mov	x21, x0
	mov	x0, x20
	bl	_kvfree
	cbz	w21, LBB0_9
; %bb.6:
	mov	x0, x19
	bl	_esw_cleanup_vepa_rules
	b	LBB0_9
LBB0_7:
	mov	x0, x19
	bl	_esw_cleanup_vepa_rules
LBB0_8:
	mov	w21, #0
LBB0_9:
	mov	x0, x21
	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
	add	sp, sp, #112
	ret
LBB0_10:
Lloh24:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh25:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
Lloh26:
	ldr	w8, [x8]
	neg	w21, w8
	b	LBB0_9
LBB0_11:
	str	x21, [x19]
	mov	x0, x20
	bl	_kvfree
	b	LBB0_8
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh19, Lloh20
	.loh AdrpLdrGotLdr	Lloh16, Lloh17, Lloh18
	.loh AdrpLdrGotLdr	Lloh13, Lloh14, Lloh15
	.loh AdrpLdrGot	Lloh11, Lloh12
	.loh AdrpLdrGot	Lloh9, Lloh10
	.loh AdrpLdrGot	Lloh7, Lloh8
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh21, Lloh22, Lloh23
	.loh AdrpLdrGotLdr	Lloh24, Lloh25, Lloh26
	.cfi_endproc
                                        ; -- End function
	.comm	_GFP_KERNEL,4,2                 ; @GFP_KERNEL
	.comm	_ENOMEM,4,2                     ; @ENOMEM
	.comm	_fte_match_param,4,2            ; @fte_match_param
	.comm	_misc_parameters,4,2            ; @misc_parameters
	.comm	_fte_match_set_misc,4,2         ; @fte_match_set_misc
	.comm	_source_port,4,2                ; @source_port
	.comm	_MLX5_VPORT_UPLINK,4,2          ; @MLX5_VPORT_UPLINK
	.comm	_MLX5_MATCH_MISC_PARAMETERS,4,2 ; @MLX5_MATCH_MISC_PARAMETERS
	.comm	_MLX5_FLOW_DESTINATION_TYPE_FLOW_TABLE,4,2 ; @MLX5_FLOW_DESTINATION_TYPE_FLOW_TABLE
	.comm	_MLX5_FLOW_CONTEXT_ACTION_FWD_DEST,8,3 ; @MLX5_FLOW_CONTEXT_ACTION_FWD_DEST
	.comm	_MLX5_FLOW_DESTINATION_TYPE_VPORT,4,2 ; @MLX5_FLOW_DESTINATION_TYPE_VPORT
	.no_dead_strip	__mlx5_eswitch_set_vepa_locked
.subsections_via_symbols
