	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function i40e_check_vf_permission
_i40e_check_vf_permission:              ## @i40e_check_vf_permission
	.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, %r12
	movq	%rdi, %r14
	movq	32(%rdi), %rbx
	movq	_I40E_VIRTCHNL_VF_CAP_PRIVILEGE@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	24(%r14), %r15
	movq	%r15, %rsi
	callq	_test_bit
	testl	%eax, %eax
	je	LBB0_7
## %bb.1:
	movl	(%r12), %eax
	jmp	LBB0_2
LBB0_7:
	movslq	(%r12), %rax
	movq	%rax, %rcx
	addq	(%r14), %rcx
	movq	_I40E_VC_MAX_MAC_ADDR_PER_VF@GOTPCREL(%rip), %rdx
	cmpq	(%rdx), %rcx
	jle	LBB0_2
## %bb.8:
	movq	(%rbx), %rdi
	leaq	L_.str(%rip), %rsi
LBB0_9:
	xorl	%ebx, %ebx
	xorl	%eax, %eax
	callq	_dev_err
	movq	_EPERM@GOTPCREL(%rip), %rax
	subl	(%rax), %ebx
	jmp	LBB0_17
LBB0_2:
	testl	%eax, %eax
	jle	LBB0_16
## %bb.3:
	movq	%rbx, -48(%rbp)                 ## 8-byte Spill
	xorl	%r13d, %r13d
	jmp	LBB0_4
	.p2align	4, 0x90
LBB0_15:                                ##   in Loop: Header=BB0_4 Depth=1
	incq	%r13
	movslq	(%r12), %rax
	cmpq	%rax, %r13
	jge	LBB0_16
LBB0_4:                                 ## =>This Inner Loop Header: Depth=1
	movq	8(%r12), %rax
	movq	(%rax,%r13,8), %rbx
	movq	%rbx, %rdi
	callq	_is_broadcast_ether_addr
	testq	%rax, %rax
	jne	LBB0_6
## %bb.5:                               ##   in Loop: Header=BB0_4 Depth=1
	movq	%rbx, %rdi
	callq	_is_zero_ether_addr
	testq	%rax, %rax
	jne	LBB0_6
## %bb.10:                              ##   in Loop: Header=BB0_4 Depth=1
	movq	_I40E_VIRTCHNL_VF_CAP_PRIVILEGE@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	%r15, %rsi
	callq	_test_bit
	testl	%eax, %eax
	jne	LBB0_15
## %bb.11:                              ##   in Loop: Header=BB0_4 Depth=1
	movq	%rbx, %rdi
	callq	_is_multicast_ether_addr
	testl	%eax, %eax
	jne	LBB0_15
## %bb.12:                              ##   in Loop: Header=BB0_4 Depth=1
	cmpq	$0, 16(%r14)
	je	LBB0_15
## %bb.13:                              ##   in Loop: Header=BB0_4 Depth=1
	movl	8(%r14), %esi
	movq	%rbx, %rdi
	callq	_ether_addr_equal
	testl	%eax, %eax
	jne	LBB0_15
## %bb.14:
	movq	-48(%rbp), %rax                 ## 8-byte Reload
	movq	(%rax), %rdi
	leaq	L_.str.2(%rip), %rsi
	jmp	LBB0_9
LBB0_16:
	xorl	%ebx, %ebx
	jmp	LBB0_17
LBB0_6:
	movq	-48(%rbp), %rax                 ## 8-byte Reload
	movq	(%rax), %rdi
	leaq	L_.str.1(%rip), %rsi
	movq	%rbx, %rdx
	xorl	%eax, %eax
	callq	_dev_err
	movq	_I40E_ERR_INVALID_MAC_ADDR@GOTPCREL(%rip), %rax
	movl	(%rax), %ebx
LBB0_17:
	movl	%ebx, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_I40E_VIRTCHNL_VF_CAP_PRIVILEGE,4,2 ## @I40E_VIRTCHNL_VF_CAP_PRIVILEGE
	.comm	_I40E_VC_MAX_MAC_ADDR_PER_VF,8,3 ## @I40E_VC_MAX_MAC_ADDR_PER_VF
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Cannot add more MAC addresses, VF is not trusted, switch the VF to trusted to add more functionality\n"

	.comm	_EPERM,4,2                      ## @EPERM
L_.str.1:                               ## @.str.1
	.asciz	"invalid VF MAC addr %pM\n"

	.comm	_I40E_ERR_INVALID_MAC_ADDR,4,2  ## @I40E_ERR_INVALID_MAC_ADDR
L_.str.2:                               ## @.str.2
	.asciz	"VF attempting to override administratively set MAC address, bring down and up the VF interface to resume normal operation\n"

	.no_dead_strip	_i40e_check_vf_permission
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function i40e_check_vf_permission
_i40e_check_vf_permission:              ; @i40e_check_vf_permission
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #96
	.cfi_def_cfa_offset 96
	stp	x26, x25, [sp, #16]             ; 16-byte Folded Spill
	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
	.cfi_offset w25, -72
	.cfi_offset w26, -80
	mov	x19, x1
	mov	x20, x0
	ldr	x23, [x0, #32]
Lloh0:
	adrp	x24, _I40E_VIRTCHNL_VF_CAP_PRIVILEGE@GOTPAGE
Lloh1:
	ldr	x24, [x24, _I40E_VIRTCHNL_VF_CAP_PRIVILEGE@GOTPAGEOFF]
	ldr	w0, [x24]
	add	x21, x20, #24
	mov	x1, x21
	bl	_test_bit
	cbz	w0, LBB0_2
; %bb.1:
	ldr	w8, [x19]
	b	LBB0_5
LBB0_2:
	ldr	x9, [x20]
	ldrsw	x8, [x19]
Lloh2:
	adrp	x10, _I40E_VC_MAX_MAC_ADDR_PER_VF@GOTPAGE
Lloh3:
	ldr	x10, [x10, _I40E_VC_MAX_MAC_ADDR_PER_VF@GOTPAGEOFF]
Lloh4:
	ldr	x10, [x10]
	add	x9, x9, x8
	cmp	x9, x10
	b.le	LBB0_5
; %bb.3:
	ldr	x0, [x23]
Lloh5:
	adrp	x1, l_.str@PAGE
Lloh6:
	add	x1, x1, l_.str@PAGEOFF
LBB0_4:
	bl	_dev_err
Lloh7:
	adrp	x8, _EPERM@GOTPAGE
Lloh8:
	ldr	x8, [x8, _EPERM@GOTPAGEOFF]
Lloh9:
	ldr	w8, [x8]
	neg	w0, w8
	b	LBB0_17
LBB0_5:
	cmp	w8, #1
	b.lt	LBB0_15
; %bb.6:
	mov	x25, #0
	b	LBB0_8
LBB0_7:                                 ;   in Loop: Header=BB0_8 Depth=1
	add	x25, x25, #1
	ldrsw	x8, [x19]
	cmp	x25, x8
	b.ge	LBB0_15
LBB0_8:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x8, [x19, #8]
	ldr	x22, [x8, x25, lsl #3]
	mov	x0, x22
	bl	_is_broadcast_ether_addr
	cbnz	x0, LBB0_16
; %bb.9:                                ;   in Loop: Header=BB0_8 Depth=1
	mov	x0, x22
	bl	_is_zero_ether_addr
	cbnz	x0, LBB0_16
; %bb.10:                               ;   in Loop: Header=BB0_8 Depth=1
	ldr	w0, [x24]
	mov	x1, x21
	bl	_test_bit
	cbnz	w0, LBB0_7
; %bb.11:                               ;   in Loop: Header=BB0_8 Depth=1
	mov	x0, x22
	bl	_is_multicast_ether_addr
	cbnz	w0, LBB0_7
; %bb.12:                               ;   in Loop: Header=BB0_8 Depth=1
	ldr	x8, [x20, #16]
	cbz	x8, LBB0_7
; %bb.13:                               ;   in Loop: Header=BB0_8 Depth=1
	ldr	w1, [x20, #8]
	mov	x0, x22
	bl	_ether_addr_equal
	cbnz	w0, LBB0_7
; %bb.14:
	ldr	x0, [x23]
Lloh10:
	adrp	x1, l_.str.2@PAGE
Lloh11:
	add	x1, x1, l_.str.2@PAGEOFF
	b	LBB0_4
LBB0_15:
	mov	w0, #0
	b	LBB0_17
LBB0_16:
	ldr	x0, [x23]
	str	x22, [sp]
Lloh12:
	adrp	x1, l_.str.1@PAGE
Lloh13:
	add	x1, x1, l_.str.1@PAGEOFF
	bl	_dev_err
Lloh14:
	adrp	x8, _I40E_ERR_INVALID_MAC_ADDR@GOTPAGE
Lloh15:
	ldr	x8, [x8, _I40E_ERR_INVALID_MAC_ADDR@GOTPAGEOFF]
Lloh16:
	ldr	w0, [x8]
LBB0_17:
	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
	ldp	x26, x25, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #96
	ret
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpAdd	Lloh5, Lloh6
	.loh AdrpLdrGotLdr	Lloh7, Lloh8, Lloh9
	.loh AdrpAdd	Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpAdd	Lloh12, Lloh13
	.cfi_endproc
                                        ; -- End function
	.comm	_I40E_VIRTCHNL_VF_CAP_PRIVILEGE,4,2 ; @I40E_VIRTCHNL_VF_CAP_PRIVILEGE
	.comm	_I40E_VC_MAX_MAC_ADDR_PER_VF,8,3 ; @I40E_VC_MAX_MAC_ADDR_PER_VF
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Cannot add more MAC addresses, VF is not trusted, switch the VF to trusted to add more functionality\n"

	.comm	_EPERM,4,2                      ; @EPERM
l_.str.1:                               ; @.str.1
	.asciz	"invalid VF MAC addr %pM\n"

	.comm	_I40E_ERR_INVALID_MAC_ADDR,4,2  ; @I40E_ERR_INVALID_MAC_ADDR
l_.str.2:                               ; @.str.2
	.asciz	"VF attempting to override administratively set MAC address, bring down and up the VF interface to resume normal operation\n"

	.no_dead_strip	_i40e_check_vf_permission
.subsections_via_symbols
