	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_wps_er_ap_add                  ## -- Begin function wps_er_ap_add
	.p2align	4, 0x90
_wps_er_ap_add:                         ## @wps_er_ap_add
	.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
	subq	$24, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%r8d, %r14d
	movq	%rcx, -64(%rbp)                 ## 8-byte Spill
	movq	%rdx, %r12
	movq	%rsi, %r13
	movq	%rdi, %r15
	movq	%rdx, %rsi
	movq	%r13, %rdx
	xorl	%ecx, %ecx
	callq	_wps_er_ap_get
	testq	%rax, %rax
	je	LBB0_1
## %bb.5:
	movq	%rax, %rbx
	movl	%r14d, %r12d
	movq	_wps_er_ap_timeout@GOTPCREL(%rip), %r14
	movl	(%r14), %edi
	movq	%r15, %rsi
	movq	%rax, %rdx
	callq	_eloop_cancel_timeout
	movl	(%r14), %edx
	movl	%r12d, %edi
	xorl	%esi, %esi
	movq	%r15, %rcx
	movq	%rbx, %r8
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_eloop_register_timeout         ## TAILCALL
LBB0_1:
	movq	%r13, -56(%rbp)                 ## 8-byte Spill
	movq	-64(%rbp), %rbx                 ## 8-byte Reload
	movl	%r14d, -44(%rbp)                ## 4-byte Spill
	movl	$48, %edi
	callq	_os_zalloc
	testq	%rax, %rax
	je	LBB0_4
## %bb.2:
	movq	%rax, %r14
	leaq	40(%rax), %rdi
	callq	_dl_list_init
	movq	%r15, 32(%r14)
	movq	8(%r15), %rax
	incq	%rax
	movq	%rax, 8(%r15)
	movq	%rax, 24(%r14)
	movq	%rbx, %rdi
	callq	_os_strdup
	movq	%rax, (%r14)
	testq	%rax, %rax
	je	LBB0_6
## %bb.3:
	movq	%r14, %rsi
	addq	$20, %rsi
	movq	%r15, %rdi
	callq	_dl_list_add
	movl	(%r12), %eax
	movl	%eax, 12(%r14)
	movl	16(%r14), %edi
	movq	_WPS_UUID_LEN@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	-56(%rbp), %rsi                 ## 8-byte Reload
	callq	_os_memcpy
	movq	_wps_er_ap_timeout@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movl	-44(%rbp), %edi                 ## 4-byte Reload
	xorl	%esi, %esi
	movq	%r15, %rcx
	movq	%r14, %r8
	callq	_eloop_register_timeout
	movq	_MSG_DEBUG@GOTPCREL(%rip), %rax
	movl	(%rax), %ebx
	movl	12(%r14), %edi
	callq	_inet_ntoa
	movq	(%r14), %rcx
	leaq	L_.str(%rip), %rsi
	movl	%ebx, %edi
	movl	%eax, %edx
	callq	_wpa_printf
	movq	(%r14), %rdi
	movq	_wps_er_http_dev_desc_cb@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	xorl	%esi, %esi
	movl	$10000, %edx                    ## imm = 0x2710
	movq	%r14, %r8
	callq	_http_client_url
	movl	%eax, 8(%r14)
LBB0_4:
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_6:
	movq	%r14, %rdi
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_os_free                        ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_wps_er_ap_timeout,4,2          ## @wps_er_ap_timeout
	.comm	_WPS_UUID_LEN,4,2               ## @WPS_UUID_LEN
	.comm	_MSG_DEBUG,4,2                  ## @MSG_DEBUG
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"WPS ER: Added AP entry for %s (%s)"

	.comm	_wps_er_http_dev_desc_cb,4,2    ## @wps_er_http_dev_desc_cb
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_wps_er_ap_add                  ; -- Begin function wps_er_ap_add
	.p2align	2
_wps_er_ap_add:                         ; @wps_er_ap_add
	.cfi_startproc
; %bb.0:
	stp	x24, x23, [sp, #-64]!           ; 16-byte Folded Spill
	.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
	.cfi_offset w23, -56
	.cfi_offset w24, -64
	mov	x21, x4
	mov	x24, x3
	mov	x23, x2
	mov	x22, x1
	mov	x20, x0
	mov	x1, x2
	mov	x2, x22
	mov	x3, #0
	bl	_wps_er_ap_get
	cbz	x0, LBB0_2
; %bb.1:
	mov	x19, x0
Lloh0:
	adrp	x22, _wps_er_ap_timeout@GOTPAGE
Lloh1:
	ldr	x22, [x22, _wps_er_ap_timeout@GOTPAGEOFF]
	ldr	w0, [x22]
	mov	x1, x20
	mov	x2, x19
	bl	_eloop_cancel_timeout
	ldr	w2, [x22]
	mov	x0, x21
	mov	w1, #0
	mov	x3, x20
	mov	x4, x19
	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
	ldp	x24, x23, [sp], #64             ; 16-byte Folded Reload
	b	_eloop_register_timeout
LBB0_2:
	mov	w0, #48
	bl	_os_zalloc
	cbz	x0, LBB0_5
; %bb.3:
	mov	x19, x0
	add	x0, x0, #40
	bl	_dl_list_init
	ldr	x8, [x20, #8]
	add	x8, x8, #1
	str	x8, [x20, #8]
	stp	x8, x20, [x19, #24]
	mov	x0, x24
	bl	_os_strdup
	str	x0, [x19]
	cbz	x0, LBB0_6
; %bb.4:
	add	x1, x19, #20
	mov	x0, x20
	bl	_dl_list_add
	ldr	w8, [x23]
	str	w8, [x19, #12]
	ldr	w0, [x19, #16]
Lloh2:
	adrp	x8, _WPS_UUID_LEN@GOTPAGE
Lloh3:
	ldr	x8, [x8, _WPS_UUID_LEN@GOTPAGEOFF]
Lloh4:
	ldr	w2, [x8]
	mov	x1, x22
	bl	_os_memcpy
Lloh5:
	adrp	x8, _wps_er_ap_timeout@GOTPAGE
Lloh6:
	ldr	x8, [x8, _wps_er_ap_timeout@GOTPAGEOFF]
Lloh7:
	ldr	w2, [x8]
	mov	x0, x21
	mov	w1, #0
	mov	x3, x20
	mov	x4, x19
	bl	_eloop_register_timeout
Lloh8:
	adrp	x8, _MSG_DEBUG@GOTPAGE
Lloh9:
	ldr	x8, [x8, _MSG_DEBUG@GOTPAGEOFF]
Lloh10:
	ldr	w20, [x8]
	ldr	w0, [x19, #12]
	bl	_inet_ntoa
	mov	x2, x0
	ldr	x3, [x19]
Lloh11:
	adrp	x1, l_.str@PAGE
Lloh12:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x20
	bl	_wpa_printf
	ldr	x0, [x19]
Lloh13:
	adrp	x8, _wps_er_http_dev_desc_cb@GOTPAGE
Lloh14:
	ldr	x8, [x8, _wps_er_http_dev_desc_cb@GOTPAGEOFF]
Lloh15:
	ldr	w3, [x8]
	mov	x1, #0
	mov	w2, #10000
	mov	x4, x19
	bl	_http_client_url
	str	w0, [x19, #8]
LBB0_5:
	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
	ldp	x24, x23, [sp], #64             ; 16-byte Folded Reload
	ret
LBB0_6:
	mov	x0, x19
	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
	ldp	x24, x23, [sp], #64             ; 16-byte Folded Reload
	b	_os_free
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh13, Lloh14, Lloh15
	.loh AdrpAdd	Lloh11, Lloh12
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.cfi_endproc
                                        ; -- End function
	.comm	_wps_er_ap_timeout,4,2          ; @wps_er_ap_timeout
	.comm	_WPS_UUID_LEN,4,2               ; @WPS_UUID_LEN
	.comm	_MSG_DEBUG,4,2                  ; @MSG_DEBUG
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"WPS ER: Added AP entry for %s (%s)"

	.comm	_wps_er_http_dev_desc_cb,4,2    ; @wps_er_http_dev_desc_cb
.subsections_via_symbols
