	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function esw_offloads_start
_esw_offloads_start:                    ## @esw_offloads_start
	.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	%r12
	pushq	%rbx
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rsi, %r14
	movq	%rdi, %rbx
	movq	(%rdi), %rax
	movq	_MLX5_ESWITCH_LEGACY@GOTPCREL(%rip), %r12
	cmpq	(%r12), %rax
	je	LBB0_3
## %bb.1:
	movq	16(%rbx), %rdi
	callq	_mlx5_core_is_ecpf_esw_manager
	testl	%eax, %eax
	je	LBB0_2
LBB0_3:
	movq	%rbx, %rdi
	callq	_mlx5_eswitch_disable
	movq	16(%rbx), %rax
	movl	(%rax), %esi
	movq	%rbx, %rdi
	callq	_mlx5_eswitch_update_num_of_vfs
	movq	_MLX5_ESWITCH_OFFLOADS@GOTPCREL(%rip), %rax
	movq	(%rax), %rsi
	movq	%rbx, %rdi
	callq	_mlx5_eswitch_enable
	movl	%eax, %r15d
	testl	%eax, %eax
	je	LBB0_6
## %bb.4:
	leaq	L_.str.1(%rip), %rsi
	movq	%r14, %rdi
	callq	_NL_SET_ERR_MSG_MOD
	movq	(%r12), %rsi
	movq	%rbx, %rdi
	callq	_mlx5_eswitch_enable
	testl	%eax, %eax
	je	LBB0_6
## %bb.5:
	leaq	L_.str.2(%rip), %rsi
	movq	%r14, %rdi
	callq	_NL_SET_ERR_MSG_MOD
LBB0_6:
	movq	8(%rbx), %rax
	movq	_MLX5_INLINE_MODE_NONE@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_9
## %bb.7:
	leaq	8(%rbx), %r12
	movq	%rbx, %rdi
	movq	%r12, %rsi
	callq	_mlx5_eswitch_inline_mode_get
	testq	%rax, %rax
	je	LBB0_9
## %bb.8:
	movq	_MLX5_INLINE_MODE_L2@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, (%r12)
	leaq	L_.str.3(%rip), %rsi
	movq	%r14, %rdi
	callq	_NL_SET_ERR_MSG_MOD
	jmp	LBB0_9
LBB0_2:
	leaq	L_.str(%rip), %rsi
	movq	%r14, %rdi
	callq	_NL_SET_ERR_MSG_MOD
	movq	_EINVAL@GOTPCREL(%rip), %rax
	xorl	%r15d, %r15d
	subl	(%rax), %r15d
LBB0_9:
	movl	%r15d, %eax
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_MLX5_ESWITCH_LEGACY,8,3        ## @MLX5_ESWITCH_LEGACY
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Can't set offloads mode, SRIOV legacy not enabled"

	.comm	_EINVAL,4,2                     ## @EINVAL
	.comm	_MLX5_ESWITCH_OFFLOADS,8,3      ## @MLX5_ESWITCH_OFFLOADS
L_.str.1:                               ## @.str.1
	.asciz	"Failed setting eswitch to offloads"

L_.str.2:                               ## @.str.2
	.asciz	"Failed setting eswitch back to legacy"

	.comm	_MLX5_INLINE_MODE_NONE,8,3      ## @MLX5_INLINE_MODE_NONE
	.comm	_MLX5_INLINE_MODE_L2,8,3        ## @MLX5_INLINE_MODE_L2
L_.str.3:                               ## @.str.3
	.asciz	"Inline mode is different between vports"

	.no_dead_strip	_esw_offloads_start
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function esw_offloads_start
_esw_offloads_start:                    ; @esw_offloads_start
	.cfi_startproc
; %bb.0:
	stp	x22, x21, [sp, #-48]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 48
	stp	x20, x19, [sp, #16]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #32]             ; 16-byte Folded Spill
	add	x29, sp, #32
	.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
	mov	x19, x1
	mov	x20, x0
	ldr	x8, [x0]
Lloh0:
	adrp	x22, _MLX5_ESWITCH_LEGACY@GOTPAGE
Lloh1:
	ldr	x22, [x22, _MLX5_ESWITCH_LEGACY@GOTPAGEOFF]
	ldr	x9, [x22]
	cmp	x8, x9
	b.eq	LBB0_2
; %bb.1:
	ldr	x0, [x20, #16]
	bl	_mlx5_core_is_ecpf_esw_manager
	cbz	w0, LBB0_8
LBB0_2:
	mov	x0, x20
	bl	_mlx5_eswitch_disable
	ldr	x8, [x20, #16]
	ldr	w1, [x8]
	mov	x0, x20
	bl	_mlx5_eswitch_update_num_of_vfs
Lloh2:
	adrp	x8, _MLX5_ESWITCH_OFFLOADS@GOTPAGE
Lloh3:
	ldr	x8, [x8, _MLX5_ESWITCH_OFFLOADS@GOTPAGEOFF]
Lloh4:
	ldr	x1, [x8]
	mov	x0, x20
	bl	_mlx5_eswitch_enable
	mov	x21, x0
	cbz	w0, LBB0_5
; %bb.3:
Lloh5:
	adrp	x1, l_.str.1@PAGE
Lloh6:
	add	x1, x1, l_.str.1@PAGEOFF
	mov	x0, x19
	bl	_NL_SET_ERR_MSG_MOD
	ldr	x1, [x22]
	mov	x0, x20
	bl	_mlx5_eswitch_enable
	cbz	w0, LBB0_5
; %bb.4:
Lloh7:
	adrp	x1, l_.str.2@PAGE
Lloh8:
	add	x1, x1, l_.str.2@PAGEOFF
	mov	x0, x19
	bl	_NL_SET_ERR_MSG_MOD
LBB0_5:
	mov	x22, x20
	ldr	x8, [x22, #8]!
Lloh9:
	adrp	x9, _MLX5_INLINE_MODE_NONE@GOTPAGE
Lloh10:
	ldr	x9, [x9, _MLX5_INLINE_MODE_NONE@GOTPAGEOFF]
Lloh11:
	ldr	x9, [x9]
	cmp	x8, x9
	b.ne	LBB0_9
; %bb.6:
	mov	x0, x20
	mov	x1, x22
	bl	_mlx5_eswitch_inline_mode_get
	cbz	x0, LBB0_9
; %bb.7:
Lloh12:
	adrp	x8, _MLX5_INLINE_MODE_L2@GOTPAGE
Lloh13:
	ldr	x8, [x8, _MLX5_INLINE_MODE_L2@GOTPAGEOFF]
Lloh14:
	ldr	x8, [x8]
	str	x8, [x22]
Lloh15:
	adrp	x1, l_.str.3@PAGE
Lloh16:
	add	x1, x1, l_.str.3@PAGEOFF
	mov	x0, x19
	bl	_NL_SET_ERR_MSG_MOD
	b	LBB0_9
LBB0_8:
Lloh17:
	adrp	x1, l_.str@PAGE
Lloh18:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x19
	bl	_NL_SET_ERR_MSG_MOD
Lloh19:
	adrp	x8, _EINVAL@GOTPAGE
Lloh20:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh21:
	ldr	w8, [x8]
	neg	w21, w8
LBB0_9:
	mov	x0, x21
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp], #48             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpAdd	Lloh5, Lloh6
	.loh AdrpAdd	Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpAdd	Lloh15, Lloh16
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh19, Lloh20, Lloh21
	.loh AdrpAdd	Lloh17, Lloh18
	.cfi_endproc
                                        ; -- End function
	.comm	_MLX5_ESWITCH_LEGACY,8,3        ; @MLX5_ESWITCH_LEGACY
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Can't set offloads mode, SRIOV legacy not enabled"

	.comm	_EINVAL,4,2                     ; @EINVAL
	.comm	_MLX5_ESWITCH_OFFLOADS,8,3      ; @MLX5_ESWITCH_OFFLOADS
l_.str.1:                               ; @.str.1
	.asciz	"Failed setting eswitch to offloads"

l_.str.2:                               ; @.str.2
	.asciz	"Failed setting eswitch back to legacy"

	.comm	_MLX5_INLINE_MODE_NONE,8,3      ; @MLX5_INLINE_MODE_NONE
	.comm	_MLX5_INLINE_MODE_L2,8,3        ; @MLX5_INLINE_MODE_L2
l_.str.3:                               ; @.str.3
	.asciz	"Inline mode is different between vports"

	.no_dead_strip	_esw_offloads_start
.subsections_via_symbols
