	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function zd1201_get_encode
_zd1201_get_encode:                     ## @zd1201_get_encode
	.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	%rbx
	pushq	%rax
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rcx, %r14
	movq	%rdx, %r15
	callq	_netdev_priv
	movq	%rax, %rbx
	cmpq	$0, 24(%rax)
	jne	LBB0_1
## %bb.2:
	movq	_IW_ENCODE_DISABLED@GOTPCREL(%rip), %rax
	jmp	LBB0_3
LBB0_1:
	movq	_IW_ENCODE_ENABLED@GOTPCREL(%rip), %rax
LBB0_3:
	movl	(%rax), %eax
	movl	%eax, (%r15)
	cmpq	$0, 16(%rbx)
	jne	LBB0_4
## %bb.5:
	movq	_IW_ENCODE_OPEN@GOTPCREL(%rip), %rcx
	jmp	LBB0_6
LBB0_4:
	movq	_IW_ENCODE_RESTRICTED@GOTPCREL(%rip), %rcx
LBB0_6:
	orl	(%rcx), %eax
	movl	%eax, (%r15)
	movq	_IW_ENCODE_INDEX@GOTPCREL(%rip), %rcx
	andl	(%rcx), %eax
	subw	$1, %ax
	movw	%ax, -26(%rbp)
	jae	LBB0_9
## %bb.7:
	movq	_ZD1201_RID_CNFDEFAULTKEYID@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	-26(%rbp), %rdx
	movq	%rbx, %rdi
	callq	_zd1201_getconfig16
	testl	%eax, %eax
	jne	LBB0_13
## %bb.8:
	movzwl	-26(%rbp), %eax
LBB0_9:
	testw	%ax, %ax
	js	LBB0_11
## %bb.10:
	movq	_ZD1201_NUMKEYS@GOTPCREL(%rip), %rcx
	cmpw	(%rcx), %ax
	jge	LBB0_11
## %bb.12:
	movzwl	%ax, %eax
	leal	1(%rax), %ecx
	orl	%ecx, (%r15)
	movq	8(%rbx), %rcx
	movl	(%rcx,%rax,4), %edx
	movl	%edx, 4(%r15)
	movq	(%rbx), %rcx
	movl	(%rcx,%rax,4), %esi
	movq	%r14, %rdi
	callq	_memcpy
	xorl	%eax, %eax
	jmp	LBB0_13
LBB0_11:
	movq	_EINVAL@GOTPCREL(%rip), %rcx
	xorl	%eax, %eax
	subl	(%rcx), %eax
LBB0_13:
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_IW_ENCODE_ENABLED,4,2          ## @IW_ENCODE_ENABLED
	.comm	_IW_ENCODE_DISABLED,4,2         ## @IW_ENCODE_DISABLED
	.comm	_IW_ENCODE_RESTRICTED,4,2       ## @IW_ENCODE_RESTRICTED
	.comm	_IW_ENCODE_OPEN,4,2             ## @IW_ENCODE_OPEN
	.comm	_IW_ENCODE_INDEX,4,2            ## @IW_ENCODE_INDEX
	.comm	_ZD1201_RID_CNFDEFAULTKEYID,4,2 ## @ZD1201_RID_CNFDEFAULTKEYID
	.comm	_ZD1201_NUMKEYS,2,1             ## @ZD1201_NUMKEYS
	.comm	_EINVAL,4,2                     ## @EINVAL
	.no_dead_strip	_zd1201_get_encode
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function zd1201_get_encode
_zd1201_get_encode:                     ; @zd1201_get_encode
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #64
	.cfi_def_cfa_offset 64
	stp	x22, x21, [sp, #16]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #32]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #48]             ; 16-byte Folded Spill
	add	x29, sp, #48
	.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, x3
	mov	x20, x2
	bl	_netdev_priv
	mov	x21, x0
Lloh0:
	adrp	x8, _IW_ENCODE_DISABLED@GOTPAGE
Lloh1:
	ldr	x8, [x8, _IW_ENCODE_DISABLED@GOTPAGEOFF]
	ldr	x9, [x0, #24]
Lloh2:
	adrp	x10, _IW_ENCODE_ENABLED@GOTPAGE
Lloh3:
	ldr	x10, [x10, _IW_ENCODE_ENABLED@GOTPAGEOFF]
	cmp	x9, #0
	csel	x8, x8, x10, eq
	ldr	w8, [x8]
	str	w8, [x20]
	ldr	x9, [x0, #16]
Lloh4:
	adrp	x10, _IW_ENCODE_OPEN@GOTPAGE
Lloh5:
	ldr	x10, [x10, _IW_ENCODE_OPEN@GOTPAGEOFF]
Lloh6:
	adrp	x11, _IW_ENCODE_RESTRICTED@GOTPAGE
Lloh7:
	ldr	x11, [x11, _IW_ENCODE_RESTRICTED@GOTPAGEOFF]
	cmp	x9, #0
	csel	x9, x10, x11, eq
	ldr	w9, [x9]
	orr	w8, w8, w9
Lloh8:
	adrp	x9, _IW_ENCODE_INDEX@GOTPAGE
Lloh9:
	ldr	x9, [x9, _IW_ENCODE_INDEX@GOTPAGEOFF]
	str	w8, [x20]
Lloh10:
	ldr	w9, [x9]
	and	w9, w9, w8
	sub	w8, w9, #1
	strh	w8, [sp, #14]
	and	w9, w9, #0xffff
	cbz	w9, LBB0_4
; %bb.1:
	tbnz	w8, #15, LBB0_6
LBB0_2:
Lloh11:
	adrp	x9, _ZD1201_NUMKEYS@GOTPAGE
Lloh12:
	ldr	x9, [x9, _ZD1201_NUMKEYS@GOTPAGEOFF]
Lloh13:
	ldrsh	w9, [x9]
	cmp	w9, w8, sxth
	b.le	LBB0_6
; %bb.3:
	and	w9, w8, #0xffff
	add	w9, w9, #1
	ldr	w10, [x20]
	orr	w9, w10, w9
	str	w9, [x20]
	and	x8, x8, #0xffff
	lsl	x8, x8, #2
	ldp	x10, x9, [x21]
	ldr	w2, [x9, x8]
	str	w2, [x20, #4]
	ldr	w1, [x10, x8]
	mov	x0, x19
	bl	_memcpy
	mov	w0, #0
	b	LBB0_7
LBB0_4:
Lloh14:
	adrp	x8, _ZD1201_RID_CNFDEFAULTKEYID@GOTPAGE
Lloh15:
	ldr	x8, [x8, _ZD1201_RID_CNFDEFAULTKEYID@GOTPAGEOFF]
Lloh16:
	ldr	w1, [x8]
	add	x2, sp, #14
	mov	x0, x21
	bl	_zd1201_getconfig16
	cbnz	w0, LBB0_7
; %bb.5:
	ldrh	w8, [sp, #14]
	tbz	w8, #15, LBB0_2
LBB0_6:
Lloh17:
	adrp	x8, _EINVAL@GOTPAGE
Lloh18:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh19:
	ldr	w8, [x8]
	neg	w0, w8
LBB0_7:
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #64
	ret
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh4, Lloh5
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpLdrGotLdr	Lloh17, Lloh18, Lloh19
	.cfi_endproc
                                        ; -- End function
	.comm	_IW_ENCODE_ENABLED,4,2          ; @IW_ENCODE_ENABLED
	.comm	_IW_ENCODE_DISABLED,4,2         ; @IW_ENCODE_DISABLED
	.comm	_IW_ENCODE_RESTRICTED,4,2       ; @IW_ENCODE_RESTRICTED
	.comm	_IW_ENCODE_OPEN,4,2             ; @IW_ENCODE_OPEN
	.comm	_IW_ENCODE_INDEX,4,2            ; @IW_ENCODE_INDEX
	.comm	_ZD1201_RID_CNFDEFAULTKEYID,4,2 ; @ZD1201_RID_CNFDEFAULTKEYID
	.comm	_ZD1201_NUMKEYS,2,1             ; @ZD1201_NUMKEYS
	.comm	_EINVAL,4,2                     ; @EINVAL
	.no_dead_strip	_zd1201_get_encode
.subsections_via_symbols
