	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function dev_set_promiscuous
_dev_set_promiscuous:                   ## @dev_set_promiscuous
	.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
	cmpl	%ecx, (%rsi)
	jne	LBB0_1
LBB0_8:
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_1:
	movl	%ecx, %ebx
	movq	%rdx, %r14
	movq	%rsi, %r12
	movq	%rdi, %r15
	movl	(%rdx), %eax
	xorl	%esi, %esi
	cmpl	$1, %ecx
	sbbl	%esi, %esi
	orl	$1, %esi
	addl	%eax, %esi
	movl	%esi, (%rdx)
	movl	%ecx, (%r12)
	cmpl	$1, %eax
	jg	LBB0_4
## %bb.2:
	cmpl	$1, %esi
	jg	LBB0_4
## %bb.3:
	movq	%r14, %rdi
	callq	_hw_set_promiscuous
LBB0_4:
	testl	%ebx, %ebx
	jne	LBB0_8
## %bb.5:
	movq	_STP_SUPPORT@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	andl	4(%r14), %eax
	je	LBB0_8
## %bb.6:
	movq	_IFF_BRIDGE_PORT@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	testl	%eax, (%r15)
	je	LBB0_8
## %bb.7:
	movq	8(%r14), %r15
	movl	4(%r12), %ebx
	movq	_STP_STATE_DISABLED@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%r14, %rdi
	movl	%ebx, %esi
	callq	_port_set_stp_state
	movl	$1, %eax
	movl	%ebx, %ecx
	shll	%cl, %eax
	movl	(%r15), %ecx
	btl	%ebx, %ecx
	jae	LBB0_8
## %bb.9:
	notl	%eax
	andl	%eax, %ecx
	movl	%ecx, (%r15)
	movq	%r14, %rdi
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_bridge_change                  ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_STP_SUPPORT,4,2                ## @STP_SUPPORT
	.comm	_IFF_BRIDGE_PORT,4,2            ## @IFF_BRIDGE_PORT
	.comm	_STP_STATE_DISABLED,4,2         ## @STP_STATE_DISABLED
	.no_dead_strip	_dev_set_promiscuous
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function dev_set_promiscuous
_dev_set_promiscuous:                   ; @dev_set_promiscuous
	.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
	ldr	w8, [x1]
	cmp	w8, w3
	b.ne	LBB0_2
LBB0_1:
	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_2:
	mov	x22, x3
	mov	x19, x2
	mov	x20, x1
	mov	x21, x0
	ldr	w8, [x2]
	subs	w9, w8, #1
	cmp	w3, #0
	csinc	w1, w9, w8, eq
	cmp	w8, #1
	str	w1, [x2]
	str	w3, [x20]
	ccmp	w1, #1, #0, le
	b.gt	LBB0_4
; %bb.3:
	mov	x0, x19
	bl	_hw_set_promiscuous
LBB0_4:
	cbnz	w22, LBB0_1
; %bb.5:
	ldr	w8, [x19, #4]
Lloh0:
	adrp	x9, _STP_SUPPORT@GOTPAGE
Lloh1:
	ldr	x9, [x9, _STP_SUPPORT@GOTPAGEOFF]
Lloh2:
	ldr	w9, [x9]
	and	w8, w9, w8
	cbz	w8, LBB0_1
; %bb.6:
	ldr	w8, [x21]
Lloh3:
	adrp	x9, _IFF_BRIDGE_PORT@GOTPAGE
Lloh4:
	ldr	x9, [x9, _IFF_BRIDGE_PORT@GOTPAGEOFF]
Lloh5:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_1
; %bb.7:
	ldr	x21, [x19, #8]
	ldr	w20, [x20, #4]
Lloh6:
	adrp	x8, _STP_STATE_DISABLED@GOTPAGE
Lloh7:
	ldr	x8, [x8, _STP_STATE_DISABLED@GOTPAGEOFF]
Lloh8:
	ldr	w2, [x8]
	mov	x0, x19
	mov	x1, x20
	bl	_port_set_stp_state
	mov	w8, #1
	lsl	w8, w8, w20
	ldr	w9, [x21]
	tst	w9, w8
	b.eq	LBB0_1
; %bb.8:
	bic	w8, w9, w8
	str	w8, [x21]
	mov	x0, x19
	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	_bridge_change
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.cfi_endproc
                                        ; -- End function
	.comm	_STP_SUPPORT,4,2                ; @STP_SUPPORT
	.comm	_IFF_BRIDGE_PORT,4,2            ; @IFF_BRIDGE_PORT
	.comm	_STP_STATE_DISABLED,4,2         ; @STP_STATE_DISABLED
	.no_dead_strip	_dev_set_promiscuous
.subsections_via_symbols
