	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function enic_udp_tunnel_add
_enic_udp_tunnel_add:                   ## @enic_udp_tunnel_add
	.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	%rsi, %rbx
	movq	%rdi, %r15
	callq	_netdev_priv
	movq	%rax, %r14
	movl	8(%rbx), %r12d
	movq	%rax, %rdi
	callq	_spin_lock_bh
	movl	(%rbx), %eax
	movq	_UDP_TUNNEL_TYPE_VXLAN@GOTPCREL(%rip), %rcx
	cmpl	(%rcx), %eax
	jne	LBB0_1
## %bb.3:
	movl	4(%rbx), %eax
	cmpl	$129, %eax
	je	LBB0_7
## %bb.4:
	cmpl	$128, %eax
	jne	LBB0_10
## %bb.5:
	movq	_ENIC_VXLAN_OUTER_IPV6@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	testl	%eax, 8(%r14)
	je	LBB0_6
LBB0_7:
	cmpl	$0, 12(%r14)
	je	LBB0_12
## %bb.8:
	movl	%r12d, %edi
	callq	_ntohs
	cmpl	12(%r14), %eax
	jne	LBB0_11
## %bb.9:
	leaq	L_.str.2(%rip), %rsi
	movq	%r15, %rdi
	callq	_netdev_warn
	jmp	LBB0_10
LBB0_1:
	leaq	L_.str(%rip), %rsi
LBB0_2:
	movq	%r15, %rdi
	xorl	%eax, %eax
	callq	_netdev_info
LBB0_10:
	movl	%r12d, %edi
	callq	_ntohs
	movl	(%rbx), %r8d
	movl	4(%rbx), %ecx
	leaq	L_.str.6(%rip), %rsi
	movq	%r15, %rdi
	movl	%eax, %edx
LBB0_18:
	xorl	%eax, %eax
	callq	_netdev_info
	movq	%r14, %rdi
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_spin_unlock_bh                 ## TAILCALL
LBB0_12:
	movl	24(%r14), %edi
	movq	_RES_TYPE_WQ@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_vnic_dev_get_res_count
	cmpl	$1, %eax
	je	LBB0_15
## %bb.13:
	movq	_ENIC_VXLAN_MULTI_WQ@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	testl	%eax, 8(%r14)
	je	LBB0_14
LBB0_15:
	movl	24(%r14), %eax
	movl	%eax, -44(%rbp)                 ## 4-byte Spill
	movq	_OVERLAY_CFG_VXLAN_PORT_UPDATE@GOTPCREL(%rip), %rax
	movl	(%rax), %r13d
	movl	%r12d, %edi
	callq	_ntohs
	movl	-44(%rbp), %edi                 ## 4-byte Reload
	movl	%r13d, %esi
	movl	%eax, %edx
	callq	_vnic_dev_overlay_offload_cfg
	testl	%eax, %eax
	jne	LBB0_10
## %bb.16:
	movl	24(%r14), %edi
	movq	_OVERLAY_FEATURE_VXLAN@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	16(%r14), %rdx
	callq	_vnic_dev_overlay_offload_ctrl
	testl	%eax, %eax
	jne	LBB0_10
## %bb.17:
	movl	%r12d, %edi
	callq	_ntohs
	movl	%eax, 12(%r14)
	movl	16(%r14), %r13d
	movl	%r12d, %edi
	callq	_ntohs
	movl	4(%rbx), %r8d
	leaq	L_.str.5(%rip), %rsi
	movq	%r15, %rdi
	movl	%r13d, %edx
	movl	%eax, %ecx
	jmp	LBB0_18
LBB0_11:
	leaq	L_.str.3(%rip), %rsi
	jmp	LBB0_2
LBB0_6:
	leaq	L_.str.1(%rip), %rsi
	jmp	LBB0_2
LBB0_14:
	leaq	L_.str.4(%rip), %rsi
	jmp	LBB0_2
	.cfi_endproc
                                        ## -- End function
	.comm	_UDP_TUNNEL_TYPE_VXLAN,4,2      ## @UDP_TUNNEL_TYPE_VXLAN
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"udp_tnl: only vxlan tunnel offload supported"

	.comm	_ENIC_VXLAN_OUTER_IPV6,4,2      ## @ENIC_VXLAN_OUTER_IPV6
L_.str.1:                               ## @.str.1
	.asciz	"vxlan: only IPv4 offload supported"

L_.str.2:                               ## @.str.2
	.asciz	"vxlan: udp port already offloaded"

L_.str.3:                               ## @.str.3
	.asciz	"vxlan: offload supported for only one UDP port"

	.comm	_RES_TYPE_WQ,4,2                ## @RES_TYPE_WQ
	.comm	_ENIC_VXLAN_MULTI_WQ,4,2        ## @ENIC_VXLAN_MULTI_WQ
L_.str.4:                               ## @.str.4
	.asciz	"vxlan: vxlan offload with multi wq not supported on this adapter"

	.comm	_OVERLAY_CFG_VXLAN_PORT_UPDATE,4,2 ## @OVERLAY_CFG_VXLAN_PORT_UPDATE
	.comm	_OVERLAY_FEATURE_VXLAN,4,2      ## @OVERLAY_FEATURE_VXLAN
L_.str.5:                               ## @.str.5
	.asciz	"vxlan fw-vers-%d: offload enabled for udp port: %d, sa_family: %d "

L_.str.6:                               ## @.str.6
	.asciz	"failed to offload udp port: %d, sa_family: %d, type: %d"

	.no_dead_strip	_enic_udp_tunnel_add
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function enic_udp_tunnel_add
_enic_udp_tunnel_add:                   ; @enic_udp_tunnel_add
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #96
	.cfi_def_cfa_offset 96
	stp	x24, x23, [sp, #32]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #48]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #64]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #80]             ; 16-byte Folded Spill
	add	x29, sp, #80
	.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	x21, x1
	mov	x20, x0
	bl	_netdev_priv
	mov	x19, x0
	ldr	w22, [x21, #8]
	bl	_spin_lock_bh
	ldr	w8, [x21]
Lloh0:
	adrp	x9, _UDP_TUNNEL_TYPE_VXLAN@GOTPAGE
Lloh1:
	ldr	x9, [x9, _UDP_TUNNEL_TYPE_VXLAN@GOTPAGEOFF]
Lloh2:
	ldr	w9, [x9]
	cmp	w8, w9
	b.ne	LBB0_7
; %bb.1:
	ldr	w8, [x21, #4]
	cmp	w8, #129
	b.eq	LBB0_4
; %bb.2:
	cmp	w8, #128
	b.ne	LBB0_9
; %bb.3:
	ldr	w8, [x19, #8]
Lloh3:
	adrp	x9, _ENIC_VXLAN_OUTER_IPV6@GOTPAGE
Lloh4:
	ldr	x9, [x9, _ENIC_VXLAN_OUTER_IPV6@GOTPAGEOFF]
Lloh5:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_17
LBB0_4:
	ldr	w8, [x19, #12]
	cbz	w8, LBB0_11
; %bb.5:
	mov	x0, x22
	bl	_ntohs
	ldr	w8, [x19, #12]
	cmp	w0, w8
	b.ne	LBB0_16
; %bb.6:
Lloh6:
	adrp	x1, l_.str.2@PAGE
Lloh7:
	add	x1, x1, l_.str.2@PAGEOFF
	mov	x0, x20
	bl	_netdev_warn
	b	LBB0_9
LBB0_7:
Lloh8:
	adrp	x1, l_.str@PAGE
Lloh9:
	add	x1, x1, l_.str@PAGEOFF
LBB0_8:
	mov	x0, x20
	bl	_netdev_info
LBB0_9:
	mov	x0, x22
	bl	_ntohs
                                        ; kill: def $w0 killed $w0 def $x0
	ldp	w9, w8, [x21]
	stp	x8, x9, [sp, #8]
	str	x0, [sp]
Lloh10:
	adrp	x1, l_.str.6@PAGE
Lloh11:
	add	x1, x1, l_.str.6@PAGEOFF
LBB0_10:
	mov	x0, x20
	bl	_netdev_info
	mov	x0, x19
	ldp	x29, x30, [sp, #80]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #64]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #48]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #32]             ; 16-byte Folded Reload
	add	sp, sp, #96
	b	_spin_unlock_bh
LBB0_11:
	ldr	w0, [x19, #24]
Lloh12:
	adrp	x8, _RES_TYPE_WQ@GOTPAGE
Lloh13:
	ldr	x8, [x8, _RES_TYPE_WQ@GOTPAGEOFF]
Lloh14:
	ldr	w1, [x8]
	bl	_vnic_dev_get_res_count
	cmp	w0, #1
	b.eq	LBB0_13
; %bb.12:
	ldr	w8, [x19, #8]
Lloh15:
	adrp	x9, _ENIC_VXLAN_MULTI_WQ@GOTPAGE
Lloh16:
	ldr	x9, [x9, _ENIC_VXLAN_MULTI_WQ@GOTPAGEOFF]
Lloh17:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_18
LBB0_13:
	ldr	w23, [x19, #24]
Lloh18:
	adrp	x8, _OVERLAY_CFG_VXLAN_PORT_UPDATE@GOTPAGE
Lloh19:
	ldr	x8, [x8, _OVERLAY_CFG_VXLAN_PORT_UPDATE@GOTPAGEOFF]
Lloh20:
	ldr	w24, [x8]
	mov	x0, x22
	bl	_ntohs
	mov	x2, x0
	mov	x0, x23
	mov	x1, x24
	bl	_vnic_dev_overlay_offload_cfg
	cbnz	w0, LBB0_9
; %bb.14:
	ldr	w0, [x19, #24]
Lloh21:
	adrp	x8, _OVERLAY_FEATURE_VXLAN@GOTPAGE
Lloh22:
	ldr	x8, [x8, _OVERLAY_FEATURE_VXLAN@GOTPAGEOFF]
Lloh23:
	ldr	w1, [x8]
	ldr	x2, [x19, #16]
	bl	_vnic_dev_overlay_offload_ctrl
	cbnz	w0, LBB0_9
; %bb.15:
	mov	x0, x22
	bl	_ntohs
	str	w0, [x19, #12]
	ldr	x23, [x19, #16]
	mov	x0, x22
	bl	_ntohs
                                        ; kill: def $w0 killed $w0 def $x0
	ldr	w8, [x21, #4]
	stp	x0, x8, [sp, #8]
	str	x23, [sp]
Lloh24:
	adrp	x1, l_.str.5@PAGE
Lloh25:
	add	x1, x1, l_.str.5@PAGEOFF
	b	LBB0_10
LBB0_16:
Lloh26:
	adrp	x1, l_.str.3@PAGE
Lloh27:
	add	x1, x1, l_.str.3@PAGEOFF
	b	LBB0_8
LBB0_17:
Lloh28:
	adrp	x1, l_.str.1@PAGE
Lloh29:
	add	x1, x1, l_.str.1@PAGEOFF
	b	LBB0_8
LBB0_18:
Lloh30:
	adrp	x1, l_.str.4@PAGE
Lloh31:
	add	x1, x1, l_.str.4@PAGEOFF
	b	LBB0_8
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpAdd	Lloh6, Lloh7
	.loh AdrpAdd	Lloh8, Lloh9
	.loh AdrpAdd	Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.loh AdrpLdrGotLdr	Lloh21, Lloh22, Lloh23
	.loh AdrpAdd	Lloh24, Lloh25
	.loh AdrpAdd	Lloh26, Lloh27
	.loh AdrpAdd	Lloh28, Lloh29
	.loh AdrpAdd	Lloh30, Lloh31
	.cfi_endproc
                                        ; -- End function
	.comm	_UDP_TUNNEL_TYPE_VXLAN,4,2      ; @UDP_TUNNEL_TYPE_VXLAN
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"udp_tnl: only vxlan tunnel offload supported"

	.comm	_ENIC_VXLAN_OUTER_IPV6,4,2      ; @ENIC_VXLAN_OUTER_IPV6
l_.str.1:                               ; @.str.1
	.asciz	"vxlan: only IPv4 offload supported"

l_.str.2:                               ; @.str.2
	.asciz	"vxlan: udp port already offloaded"

l_.str.3:                               ; @.str.3
	.asciz	"vxlan: offload supported for only one UDP port"

	.comm	_RES_TYPE_WQ,4,2                ; @RES_TYPE_WQ
	.comm	_ENIC_VXLAN_MULTI_WQ,4,2        ; @ENIC_VXLAN_MULTI_WQ
l_.str.4:                               ; @.str.4
	.asciz	"vxlan: vxlan offload with multi wq not supported on this adapter"

	.comm	_OVERLAY_CFG_VXLAN_PORT_UPDATE,4,2 ; @OVERLAY_CFG_VXLAN_PORT_UPDATE
	.comm	_OVERLAY_FEATURE_VXLAN,4,2      ; @OVERLAY_FEATURE_VXLAN
l_.str.5:                               ; @.str.5
	.asciz	"vxlan fw-vers-%d: offload enabled for udp port: %d, sa_family: %d "

l_.str.6:                               ; @.str.6
	.asciz	"failed to offload udp port: %d, sa_family: %d, type: %d"

	.no_dead_strip	_enic_udp_tunnel_add
.subsections_via_symbols
