	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function nfp_flower_add_offload
_nfp_flower_add_offload:                ## @nfp_flower_add_offload
	.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	$72, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdx, %r13
	movq	%rsi, %rbx
	movq	%rdi, %r12
	movq	_NFP_FL_TUNNEL_NONE@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, -44(%rbp)
	movq	(%rdi), %r15
	movq	8(%rdx), %r14
	movq	%rsi, %rdi
	callq	_nfp_netdev_is_nfp_repr
	testq	%rax, %rax
	je	LBB0_1
## %bb.2:
	movq	%rbx, %rdi
	callq	_nfp_port_from_netdev
	jmp	LBB0_3
LBB0_1:
	xorl	%eax, %eax
LBB0_3:
	movq	%rax, -96(%rbp)                 ## 8-byte Spill
	movq	_GFP_KERNEL@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	$56, %edi
	callq	_kmalloc
	testq	%rax, %rax
	je	LBB0_4
## %bb.5:
	movq	%r15, -88(%rbp)                 ## 8-byte Spill
	leaq	-44(%rbp), %r8
	movq	%r12, %rdi
	movq	%rbx, %rsi
	movq	%rax, %rdx
	movq	%r13, %rcx
	movq	%r14, %r9
	movq	%r13, -64(%rbp)                 ## 8-byte Spill
	movq	%rbx, -104(%rbp)                ## 8-byte Spill
	movq	%rax, %r13
	callq	_nfp_flower_calculate_key_layers
	movl	%eax, %r15d
	testl	%eax, %eax
	jne	LBB0_25
## %bb.6:
	movq	%r12, %rbx
	movq	-104(%rbp), %r12                ## 8-byte Reload
	movq	-64(%rbp), %r15                 ## 8-byte Reload
	movq	%r14, -80(%rbp)                 ## 8-byte Spill
	movq	%rbx, -56(%rbp)                 ## 8-byte Spill
	movq	%r13, %rdi
	callq	_nfp_flower_allocate_new
	testq	%rax, %rax
	je	LBB0_7
## %bb.8:
	movq	%rax, %rbx
	movl	-44(%rbp), %r9d
	movq	-80(%rbp), %rax                 ## 8-byte Reload
	movq	%rax, (%rsp)
	movq	-56(%rbp), %r14                 ## 8-byte Reload
	movq	%r14, %rdi
	movq	%r15, %rsi
	movq	%r13, -72(%rbp)                 ## 8-byte Spill
	movq	%r13, %rdx
	movq	%rax, %r13
	movq	%r12, %rcx
	movq	%rbx, %r8
	callq	_nfp_flower_compile_flow_match
	movl	%eax, %r15d
	testl	%eax, %eax
	jne	LBB0_24
## %bb.9:
	movq	%r14, %rdi
	movq	-64(%rbp), %rsi                 ## 8-byte Reload
	movq	%r12, %rdx
	movq	%rbx, %rcx
	movq	%r13, %r8
	callq	_nfp_flower_compile_action
	movl	%eax, %r15d
	testl	%eax, %eax
	je	LBB0_10
LBB0_24:
	movq	24(%rbx), %rdi
	callq	_kfree
	movq	16(%rbx), %rdi
	callq	_kfree
	movq	8(%rbx), %rdi
	callq	_kfree
	movq	%rbx, %rdi
	callq	_kfree
	movq	-72(%rbp), %r13                 ## 8-byte Reload
	jmp	LBB0_25
LBB0_4:
	movq	_ENOMEM@GOTPCREL(%rip), %rax
	xorl	%r15d, %r15d
	subl	(%rax), %r15d
	jmp	LBB0_26
LBB0_7:
	movq	_ENOMEM@GOTPCREL(%rip), %rax
	xorl	%r15d, %r15d
	subl	(%rax), %r15d
LBB0_25:
	movq	%r13, %rdi
	callq	_kfree
LBB0_26:
	movl	%r15d, %eax
	addq	$72, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_10:
	cmpq	$0, 40(%rbx)
	je	LBB0_12
## %bb.11:
	movq	%r14, %rdi
	movq	%rbx, %rsi
	movq	%r13, %rdx
	callq	_nfp_flower_validate_pre_tun_rule
	movl	%eax, %r15d
	testl	%eax, %eax
	jne	LBB0_24
LBB0_12:
	movq	%r14, %rdi
	movq	-64(%rbp), %rsi                 ## 8-byte Reload
	movq	%rbx, %rdx
	movq	%r12, %rcx
	movq	%r13, %r8
	callq	_nfp_compile_flow_metadata
	movl	%eax, %r15d
	testl	%eax, %eax
	jne	LBB0_24
## %bb.13:
	movq	-64(%rbp), %rax                 ## 8-byte Reload
	movl	(%rax), %eax
	movl	%eax, 48(%rbx)
	movq	%rbx, %r12
	addq	$32, %r12
	movq	_nfp_flower_table_params@GOTPCREL(%rip), %r13
	movl	(%r13), %edx
	movq	-88(%rbp), %rdi                 ## 8-byte Reload
	movq	%r12, %rsi
	callq	_rhashtable_insert_fast
	testl	%eax, %eax
	je	LBB0_15
## %bb.14:
	movl	%eax, %r15d
	leaq	L_.str(%rip), %rsi
	movq	-80(%rbp), %rdi                 ## 8-byte Reload
	callq	_NL_SET_ERR_MSG_MOD
	jmp	LBB0_23
LBB0_15:
	cmpq	$0, 40(%rbx)
	movq	%rbx, %rsi
	je	LBB0_17
## %bb.16:
	movq	-56(%rbp), %rdi                 ## 8-byte Reload
	movq	%rsi, %rbx
	callq	_nfp_flower_xmit_pre_tun_flow
	jmp	LBB0_18
LBB0_17:
	movq	_NFP_FLOWER_CMSG_TYPE_FLOW_ADD@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	-56(%rbp), %rdi                 ## 8-byte Reload
	movq	%rsi, %rbx
	callq	_nfp_flower_xmit_flow
LBB0_18:
	movl	%eax, %r15d
	testl	%eax, %eax
	je	LBB0_19
## %bb.22:
	movl	(%r13), %edx
	movq	-88(%rbp), %rdi                 ## 8-byte Reload
	movq	%r12, %rsi
	callq	_rhashtable_remove_fast
	movl	%eax, %edi
	callq	_WARN_ON_ONCE
LBB0_23:
	movq	-56(%rbp), %rdi                 ## 8-byte Reload
	movq	%rbx, %rsi
	callq	_nfp_modify_flow_metadata
	jmp	LBB0_24
LBB0_19:
	movq	-96(%rbp), %rax                 ## 8-byte Reload
	testq	%rax, %rax
	je	LBB0_21
## %bb.20:
	incl	(%rax)
LBB0_21:
	movl	$1, (%rbx)
	movq	-72(%rbp), %rdi                 ## 8-byte Reload
	callq	_kfree
	xorl	%r15d, %r15d
	jmp	LBB0_26
	.cfi_endproc
                                        ## -- End function
	.comm	_NFP_FL_TUNNEL_NONE,4,2         ## @NFP_FL_TUNNEL_NONE
	.comm	_GFP_KERNEL,4,2                 ## @GFP_KERNEL
	.comm	_ENOMEM,4,2                     ## @ENOMEM
	.comm	_nfp_flower_table_params,4,2    ## @nfp_flower_table_params
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"invalid entry: cannot insert flow into tables for offloads"

	.comm	_NFP_FLOWER_CMSG_TYPE_FLOW_ADD,4,2 ## @NFP_FLOWER_CMSG_TYPE_FLOW_ADD
	.no_dead_strip	_nfp_flower_add_offload
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function nfp_flower_add_offload
_nfp_flower_add_offload:                ; @nfp_flower_add_offload
	.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	x25, x2
	mov	x26, x1
	mov	x20, x0
Lloh0:
	adrp	x8, _NFP_FL_TUNNEL_NONE@GOTPAGE
Lloh1:
	ldr	x8, [x8, _NFP_FL_TUNNEL_NONE@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
	str	w8, [sp, #12]
	ldr	x21, [x0]
	ldr	x24, [x2, #8]
	mov	x0, x1
	bl	_nfp_netdev_is_nfp_repr
	cbz	x0, LBB0_2
; %bb.1:
	mov	x0, x26
	bl	_nfp_port_from_netdev
	mov	x23, x0
	b	LBB0_3
LBB0_2:
	mov	x23, #0
LBB0_3:
Lloh3:
	adrp	x8, _GFP_KERNEL@GOTPAGE
Lloh4:
	ldr	x8, [x8, _GFP_KERNEL@GOTPAGEOFF]
Lloh5:
	ldr	w1, [x8]
	mov	w0, #56
	bl	_kmalloc
	cbz	x0, LBB0_9
; %bb.4:
	mov	x19, x0
	add	x4, sp, #12
	mov	x0, x20
	mov	x1, x26
	mov	x2, x19
	mov	x3, x25
	mov	x5, x24
	bl	_nfp_flower_calculate_key_layers
	mov	x27, x0
	cbnz	w0, LBB0_11
; %bb.5:
	mov	x0, x19
	bl	_nfp_flower_allocate_new
	cbz	x0, LBB0_10
; %bb.6:
	mov	x22, x0
	ldr	w5, [sp, #12]
	mov	x0, x20
	mov	x1, x25
	mov	x2, x19
	mov	x3, x26
	mov	x4, x22
	mov	x6, x24
	bl	_nfp_flower_compile_flow_match
	mov	x27, x0
	cbnz	w0, LBB0_8
; %bb.7:
	mov	x0, x20
	mov	x1, x25
	mov	x2, x26
	mov	x3, x22
	mov	x4, x24
	bl	_nfp_flower_compile_action
	mov	x27, x0
	cbz	w0, LBB0_13
LBB0_8:
	ldr	x0, [x22, #24]
	bl	_kfree
	ldr	x0, [x22, #16]
	bl	_kfree
	ldr	x0, [x22, #8]
	bl	_kfree
	mov	x0, x22
	bl	_kfree
	b	LBB0_11
LBB0_9:
Lloh6:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh7:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
Lloh8:
	ldr	w8, [x8]
	neg	w27, w8
	b	LBB0_12
LBB0_10:
Lloh9:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh10:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
Lloh11:
	ldr	w8, [x8]
	neg	w27, w8
LBB0_11:
	mov	x0, x19
	bl	_kfree
LBB0_12:
	mov	x0, x27
	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_13:
	ldr	x8, [x22, #40]
	cbz	x8, LBB0_15
; %bb.14:
	mov	x0, x20
	mov	x1, x22
	mov	x2, x24
	bl	_nfp_flower_validate_pre_tun_rule
	mov	x27, x0
	cbnz	w0, LBB0_8
LBB0_15:
	mov	x0, x20
	mov	x1, x25
	mov	x2, x22
	mov	x3, x26
	mov	x4, x24
	bl	_nfp_compile_flow_metadata
	mov	x27, x0
	cbnz	w0, LBB0_8
; %bb.16:
	ldr	w8, [x25]
	str	w8, [x22, #48]
	add	x25, x22, #32
Lloh12:
	adrp	x26, _nfp_flower_table_params@GOTPAGE
Lloh13:
	ldr	x26, [x26, _nfp_flower_table_params@GOTPAGEOFF]
	ldr	w2, [x26]
	mov	x0, x21
	mov	x1, x25
	bl	_rhashtable_insert_fast
	cbz	w0, LBB0_18
; %bb.17:
	mov	x27, x0
Lloh14:
	adrp	x1, l_.str@PAGE
Lloh15:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x24
	bl	_NL_SET_ERR_MSG_MOD
	b	LBB0_23
LBB0_18:
	ldr	x8, [x22, #40]
	cbz	x8, LBB0_20
; %bb.19:
	mov	x0, x20
	mov	x1, x22
	bl	_nfp_flower_xmit_pre_tun_flow
	b	LBB0_21
LBB0_20:
Lloh16:
	adrp	x8, _NFP_FLOWER_CMSG_TYPE_FLOW_ADD@GOTPAGE
Lloh17:
	ldr	x8, [x8, _NFP_FLOWER_CMSG_TYPE_FLOW_ADD@GOTPAGEOFF]
Lloh18:
	ldr	w2, [x8]
	mov	x0, x20
	mov	x1, x22
	bl	_nfp_flower_xmit_flow
LBB0_21:
	mov	x27, x0
	cbz	w0, LBB0_24
; %bb.22:
	ldr	w2, [x26]
	mov	x0, x21
	mov	x1, x25
	bl	_rhashtable_remove_fast
	bl	_WARN_ON_ONCE
LBB0_23:
	mov	x0, x20
	mov	x1, x22
	bl	_nfp_modify_flow_metadata
	b	LBB0_8
LBB0_24:
	cbz	x23, LBB0_26
; %bb.25:
	ldr	w8, [x23]
	add	w8, w8, #1
	str	w8, [x23]
LBB0_26:
	mov	w8, #1
	str	w8, [x22]
	mov	x0, x19
	bl	_kfree
	mov	w27, #0
	b	LBB0_12
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGot	Lloh12, Lloh13
	.loh AdrpAdd	Lloh14, Lloh15
	.loh AdrpLdrGotLdr	Lloh16, Lloh17, Lloh18
	.cfi_endproc
                                        ; -- End function
	.comm	_NFP_FL_TUNNEL_NONE,4,2         ; @NFP_FL_TUNNEL_NONE
	.comm	_GFP_KERNEL,4,2                 ; @GFP_KERNEL
	.comm	_ENOMEM,4,2                     ; @ENOMEM
	.comm	_nfp_flower_table_params,4,2    ; @nfp_flower_table_params
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"invalid entry: cannot insert flow into tables for offloads"

	.comm	_NFP_FLOWER_CMSG_TYPE_FLOW_ADD,4,2 ; @NFP_FLOWER_CMSG_TYPE_FLOW_ADD
	.no_dead_strip	_nfp_flower_add_offload
.subsections_via_symbols
