	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function lib80211_wep_build_iv
_lib80211_wep_build_iv:                 ## @lib80211_wep_build_iv
	.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	%r8, %r15
	movl	%esi, %r12d
	movq	%rdi, %rbx
	callq	_skb_headroom
	movl	%eax, %ecx
	movl	$-1, %eax
	cmpl	$4, %ecx
	jl	LBB0_7
## %bb.1:
	cmpl	%r12d, (%rbx)
	jl	LBB0_7
## %bb.2:
	movq	%rbx, %rdi
	movl	$4, %esi
	callq	_skb_push
	movq	%rax, %r14
	leaq	16(%rax), %rsi
	movq	%rax, %rdi
	movl	%r12d, %edx
	callq	_memmove
	movslq	%r12d, %rax
	movl	(%r15), %esi
	movl	4(%r15), %edx
	leal	1(%rdx), %ecx
	movl	%ecx, 4(%r15)
	movl	%ecx, %edi
	notl	%edi
	testl	$65280, %edi                    ## imm = 0xFF00
	jne	LBB0_6
## %bb.3:
	movl	%ecx, %edi
	shrl	$16, %edi
	movzbl	%dil, %edi
	cmpl	$3, %edi
	jb	LBB0_6
## %bb.4:
	addl	$3, %esi
	cmpl	%esi, %edi
	jge	LBB0_6
## %bb.5:
	addl	$257, %edx                      ## imm = 0x101
	movl	%edx, 4(%r15)
	movl	%edx, %ecx
LBB0_6:
	shrl	$16, %ecx
	movzbl	%cl, %ecx
	movl	%ecx, (%r14,%rax,4)
	movzbl	5(%r15), %ecx
	movl	%ecx, 4(%r14,%rax,4)
	movzbl	4(%r15), %ecx
	movl	%ecx, 8(%r14,%rax,4)
	movl	8(%r15), %ecx
	shll	$6, %ecx
	movl	%ecx, 12(%r14,%rax,4)
	xorl	%eax, %eax
LBB0_7:
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.no_dead_strip	_lib80211_wep_build_iv
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function lib80211_wep_build_iv
_lib80211_wep_build_iv:                 ; @lib80211_wep_build_iv
	.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, x4
	mov	x20, x1
	mov	x21, x0
	bl	_skb_headroom
	cmp	w0, #4
	b.lt	LBB0_2
; %bb.1:
	ldr	w8, [x21]
	cmp	w8, w20
	b.ge	LBB0_3
LBB0_2:
	mov	w0, #-1
	b	LBB0_6
LBB0_3:
	mov	x0, x21
	mov	w1, #4
	bl	_skb_push
	mov	x21, x0
	add	x1, x0, #16
	mov	x2, x20
	bl	_memmove
	add	x8, x21, w20, sxtw #2
	ldp	w11, w10, [x19]
	add	w9, w10, #1
	mvn	w12, w9
	str	w9, [x19, #4]
	and	w12, w12, #0xff00
	cmp	w12, #0
	add	w11, w11, #3
	ubfx	w12, w9, #16, #8
	ccmp	w12, #3, #0, eq
	ccmp	w12, w11, #0, hs
	b.ge	LBB0_5
; %bb.4:
	add	w9, w10, #257
	str	w9, [x19, #4]
LBB0_5:
	mov	w0, #0
	ubfx	w9, w9, #16, #8
	str	w9, [x8]
	ldrb	w9, [x19, #5]
	str	w9, [x8, #4]
	ldrb	w9, [x19, #4]
	str	w9, [x8, #8]
	ldr	w9, [x19, #8]
	lsl	w9, w9, #6
	str	w9, [x8, #12]
LBB0_6:
	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
	.cfi_endproc
                                        ; -- End function
	.no_dead_strip	_lib80211_wep_build_iv
.subsections_via_symbols
