	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function ocelot_setup_tc_block
_ocelot_setup_tc_block:                 ## @ocelot_setup_tc_block
	.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, %r12
	movq	%rdi, %r14
	movl	4(%rdi), %edi
	movl	(%rsi), %edx
	movq	8(%rsi), %rcx
	leaq	L_.str(%rip), %rsi
	callq	_netdev_dbg
	movq	8(%r12), %rax
	movq	_FLOW_BLOCK_BINDER_TYPE_CLSACT_INGRESS@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_2
## %bb.1:
	movq	_ocelot_setup_tc_block_cb_ig@GOTPCREL(%rip), %rax
	movq	(%rax), %r15
	movl	32(%r12), %eax
	movl	%eax, (%r14)
	jmp	LBB0_4
LBB0_2:
	movq	_FLOW_BLOCK_BINDER_TYPE_CLSACT_EGRESS@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_15
## %bb.3:
	movq	_ocelot_setup_tc_block_cb_eg@GOTPCREL(%rip), %rax
	movq	(%rax), %r15
LBB0_4:
	movq	_ocelot_block_cb_list@GOTPCREL(%rip), %rax
	movq	%rax, 24(%r12)
	movl	(%r12), %eax
	cmpl	$128, %eax
	je	LBB0_12
## %bb.5:
	cmpl	$129, %eax
	jne	LBB0_15
## %bb.6:
	movq	_ocelot_block_cb_list@GOTPCREL(%rip), %rdx
	movq	%r15, %rdi
	movq	%r14, %rsi
	callq	_flow_block_cb_is_busy
	testl	%eax, %eax
	je	LBB0_8
## %bb.7:
	movq	_EBUSY@GOTPCREL(%rip), %rax
	jmp	LBB0_16
LBB0_15:
	movq	_EOPNOTSUPP@GOTPCREL(%rip), %rax
LBB0_16:
	xorl	%ebx, %ebx
	subl	(%rax), %ebx
LBB0_17:
	movl	%ebx, %eax
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_12:
	movl	16(%r12), %edi
	movq	%r15, %rsi
	movq	%r14, %rdx
	callq	_flow_block_cb_lookup
	testq	%rax, %rax
	je	LBB0_13
## %bb.14:
	movq	%rax, %rbx
	movq	%r14, %rdi
	movq	%r12, %rsi
	callq	_ocelot_setup_tc_block_flower_unbind
	movq	%rbx, %rdi
	movq	%r12, %rsi
	callq	_flow_block_cb_remove
	movq	%rbx, %rdi
	callq	_list_del
	xorl	%ebx, %ebx
	jmp	LBB0_17
LBB0_8:
	movq	%r15, %rdi
	movq	%r14, %rsi
	movq	%r14, %rdx
	xorl	%ecx, %ecx
	callq	_flow_block_cb_alloc
	movq	%rax, %r15
	movq	%rax, %rdi
	callq	_IS_ERR
	testl	%eax, %eax
	je	LBB0_9
## %bb.18:
	movq	%r15, %rdi
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_PTR_ERR                        ## TAILCALL
LBB0_13:
	movq	_ENOENT@GOTPCREL(%rip), %rax
	jmp	LBB0_16
LBB0_9:
	movq	%r14, %rdi
	movq	%r12, %rsi
	callq	_ocelot_setup_tc_block_flower_bind
	testl	%eax, %eax
	js	LBB0_10
## %bb.11:
	movq	%r15, %rdi
	movq	%r12, %rsi
	callq	_flow_block_cb_add
	movq	24(%r12), %rsi
	movq	%r15, %rdi
	callq	_list_add_tail
	xorl	%ebx, %ebx
	jmp	LBB0_17
LBB0_10:
	movl	%eax, %ebx
	movq	%r15, %rdi
	callq	_flow_block_cb_free
	jmp	LBB0_17
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"tc_block command %d, binder_type %d\n"

	.comm	_FLOW_BLOCK_BINDER_TYPE_CLSACT_INGRESS,8,3 ## @FLOW_BLOCK_BINDER_TYPE_CLSACT_INGRESS
	.comm	_ocelot_setup_tc_block_cb_ig,8,3 ## @ocelot_setup_tc_block_cb_ig
	.comm	_FLOW_BLOCK_BINDER_TYPE_CLSACT_EGRESS,8,3 ## @FLOW_BLOCK_BINDER_TYPE_CLSACT_EGRESS
	.comm	_ocelot_setup_tc_block_cb_eg,8,3 ## @ocelot_setup_tc_block_cb_eg
	.comm	_EOPNOTSUPP,4,2                 ## @EOPNOTSUPP
	.comm	_ocelot_block_cb_list,4,2       ## @ocelot_block_cb_list
	.comm	_EBUSY,4,2                      ## @EBUSY
	.comm	_ENOENT,4,2                     ## @ENOENT
	.no_dead_strip	_ocelot_setup_tc_block
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function ocelot_setup_tc_block
_ocelot_setup_tc_block:                 ; @ocelot_setup_tc_block
	.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	w0, [x0, #4]
	ldr	w2, [x1]
	ldr	x3, [x1, #8]
Lloh0:
	adrp	x1, l_.str@PAGE
Lloh1:
	add	x1, x1, l_.str@PAGEOFF
	bl	_netdev_dbg
	ldr	x8, [x19, #8]
Lloh2:
	adrp	x9, _FLOW_BLOCK_BINDER_TYPE_CLSACT_INGRESS@GOTPAGE
Lloh3:
	ldr	x9, [x9, _FLOW_BLOCK_BINDER_TYPE_CLSACT_INGRESS@GOTPAGEOFF]
Lloh4:
	ldr	x9, [x9]
	cmp	x8, x9
	b.ne	LBB0_2
; %bb.1:
Lloh5:
	adrp	x8, _ocelot_setup_tc_block_cb_ig@GOTPAGE
Lloh6:
	ldr	x8, [x8, _ocelot_setup_tc_block_cb_ig@GOTPAGEOFF]
Lloh7:
	ldr	x21, [x8]
	ldr	w8, [x19, #32]
	str	w8, [x20]
	b	LBB0_4
LBB0_2:
Lloh8:
	adrp	x9, _FLOW_BLOCK_BINDER_TYPE_CLSACT_EGRESS@GOTPAGE
Lloh9:
	ldr	x9, [x9, _FLOW_BLOCK_BINDER_TYPE_CLSACT_EGRESS@GOTPAGEOFF]
Lloh10:
	ldr	x9, [x9]
	cmp	x8, x9
	b.ne	LBB0_8
; %bb.3:
Lloh11:
	adrp	x8, _ocelot_setup_tc_block_cb_eg@GOTPAGE
Lloh12:
	ldr	x8, [x8, _ocelot_setup_tc_block_cb_eg@GOTPAGEOFF]
Lloh13:
	ldr	x21, [x8]
LBB0_4:
Lloh14:
	adrp	x8, _ocelot_block_cb_list@GOTPAGE
Lloh15:
	ldr	x8, [x8, _ocelot_block_cb_list@GOTPAGEOFF]
	str	x8, [x19, #24]
	ldr	w8, [x19]
	cmp	w8, #128
	b.eq	LBB0_11
; %bb.5:
	cmp	w8, #129
	b.ne	LBB0_8
; %bb.6:
Lloh16:
	adrp	x2, _ocelot_block_cb_list@GOTPAGE
Lloh17:
	ldr	x2, [x2, _ocelot_block_cb_list@GOTPAGEOFF]
	mov	x0, x21
	mov	x1, x20
	bl	_flow_block_cb_is_busy
	cbz	w0, LBB0_13
; %bb.7:
Lloh18:
	adrp	x8, _EBUSY@GOTPAGE
Lloh19:
	ldr	x8, [x8, _EBUSY@GOTPAGEOFF]
	b	LBB0_9
LBB0_8:
Lloh20:
	adrp	x8, _EOPNOTSUPP@GOTPAGE
Lloh21:
	ldr	x8, [x8, _EOPNOTSUPP@GOTPAGEOFF]
LBB0_9:
	ldr	w8, [x8]
	neg	w20, w8
LBB0_10:
	mov	x0, x20
	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
LBB0_11:
	ldr	w0, [x19, #16]
	mov	x1, x21
	mov	x2, x20
	bl	_flow_block_cb_lookup
	cbz	x0, LBB0_15
; %bb.12:
	mov	x21, x0
	mov	x0, x20
	mov	x1, x19
	bl	_ocelot_setup_tc_block_flower_unbind
	mov	x0, x21
	mov	x1, x19
	bl	_flow_block_cb_remove
	mov	x0, x21
	bl	_list_del
	mov	w20, #0
	b	LBB0_10
LBB0_13:
	mov	x0, x21
	mov	x1, x20
	mov	x2, x20
	mov	x3, #0
	bl	_flow_block_cb_alloc
	mov	x21, x0
	bl	_IS_ERR
	cbz	w0, LBB0_16
; %bb.14:
	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
	b	_PTR_ERR
LBB0_15:
Lloh22:
	adrp	x8, _ENOENT@GOTPAGE
Lloh23:
	ldr	x8, [x8, _ENOENT@GOTPAGEOFF]
	b	LBB0_9
LBB0_16:
	mov	x0, x20
	mov	x1, x19
	bl	_ocelot_setup_tc_block_flower_bind
	tbnz	w0, #31, LBB0_18
; %bb.17:
	mov	x0, x21
	mov	x1, x19
	bl	_flow_block_cb_add
	ldr	x1, [x19, #24]
	mov	x0, x21
	bl	_list_add_tail
	mov	w20, #0
	b	LBB0_10
LBB0_18:
	mov	x20, x0
	mov	x0, x21
	bl	_flow_block_cb_free
	b	LBB0_10
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpLdrGot	Lloh14, Lloh15
	.loh AdrpLdrGot	Lloh16, Lloh17
	.loh AdrpLdrGot	Lloh18, Lloh19
	.loh AdrpLdrGot	Lloh20, Lloh21
	.loh AdrpLdrGot	Lloh22, Lloh23
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"tc_block command %d, binder_type %d\n"

	.comm	_FLOW_BLOCK_BINDER_TYPE_CLSACT_INGRESS,8,3 ; @FLOW_BLOCK_BINDER_TYPE_CLSACT_INGRESS
	.comm	_ocelot_setup_tc_block_cb_ig,8,3 ; @ocelot_setup_tc_block_cb_ig
	.comm	_FLOW_BLOCK_BINDER_TYPE_CLSACT_EGRESS,8,3 ; @FLOW_BLOCK_BINDER_TYPE_CLSACT_EGRESS
	.comm	_ocelot_setup_tc_block_cb_eg,8,3 ; @ocelot_setup_tc_block_cb_eg
	.comm	_EOPNOTSUPP,4,2                 ; @EOPNOTSUPP
	.comm	_ocelot_block_cb_list,4,2       ; @ocelot_block_cb_list
	.comm	_EBUSY,4,2                      ; @EBUSY
	.comm	_ENOENT,4,2                     ; @ENOENT
	.no_dead_strip	_ocelot_setup_tc_block
.subsections_via_symbols
