	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_hostapd_update_time_adv        ## -- Begin function hostapd_update_time_adv
	.p2align	4, 0x90
_hostapd_update_time_adv:               ## @hostapd_update_time_adv
	.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
	subq	$40, %rsp
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	16(%rdi), %rax
	xorl	%ebx, %ebx
	cmpl	$2, (%rax)
	jne	LBB0_8
## %bb.1:
	movq	%rdi, %r14
	leaq	-32(%rbp), %rdi
	callq	_os_get_time
	movl	$-1, %ebx
	testq	%rax, %rax
	js	LBB0_8
## %bb.2:
	movl	-32(%rbp), %edi
	leaq	-56(%rbp), %rsi
	callq	_os_gmtime
	testq	%rax, %rax
	js	LBB0_8
## %bb.3:
	movq	8(%r14), %rdi
	testq	%rdi, %rdi
	je	LBB0_4
## %bb.6:
	callq	_wpabuf_mhead_u8
	jmp	LBB0_7
LBB0_4:
	movl	$19, %edi
	callq	_wpabuf_alloc
	movq	%rax, 8(%r14)
	testq	%rax, %rax
	je	LBB0_8
## %bb.5:
	movq	%rax, %rdi
	movl	$19, %esi
	callq	_wpabuf_put
LBB0_7:
	movq	%rax, %r15
	movq	_WLAN_EID_TIME_ADVERTISEMENT@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, (%r15)
	movabsq	$8589934609, %rax               ## imm = 0x200000011
	movq	%rax, 4(%r15)
	leaq	12(%r15), %rdi
	movl	-36(%rbp), %esi
	callq	_WPA_PUT_LE16
	movdqu	-52(%rbp), %xmm0
	pshufd	$27, %xmm0, %xmm0               ## xmm0 = xmm0[3,2,1,0]
	movdqu	%xmm0, 20(%r15)
	movl	-56(%rbp), %eax
	leaq	40(%r15), %rdi
	movl	%eax, 36(%r15)
	xorl	%ebx, %ebx
	xorl	%esi, %esi
	callq	_WPA_PUT_LE16
	pxor	%xmm0, %xmm0
	movdqu	%xmm0, 48(%r15)
	movq	$0, 64(%r15)
	movl	(%r14), %eax
	leal	1(%rax), %ecx
	movl	%ecx, (%r14)
	movl	%eax, 72(%r15)
LBB0_8:
	movl	%ebx, %eax
	addq	$40, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_WLAN_EID_TIME_ADVERTISEMENT,4,2 ## @WLAN_EID_TIME_ADVERTISEMENT
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.section	__TEXT,__literal8,8byte_literals
	.p2align	3                               ; -- Begin function hostapd_update_time_adv
lCPI0_0:
	.long	17                              ; 0x11
	.long	2                               ; 0x2
	.section	__TEXT,__text,regular,pure_instructions
	.globl	_hostapd_update_time_adv
	.p2align	2
_hostapd_update_time_adv:               ; @hostapd_update_time_adv
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #64
	.cfi_def_cfa_offset 64
	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
	ldr	x8, [x0, #16]
	ldr	w8, [x8]
	cmp	w8, #2
	b.ne	LBB0_5
; %bb.1:
	mov	x19, x0
	add	x0, sp, #24
	bl	_os_get_time
	tbnz	x0, #63, LBB0_9
; %bb.2:
	ldr	w0, [sp, #24]
	mov	x1, sp
	bl	_os_gmtime
	tbnz	x0, #63, LBB0_9
; %bb.3:
	ldr	x0, [x19, #8]
	cbz	x0, LBB0_6
; %bb.4:
	bl	_wpabuf_mhead_u8
	b	LBB0_8
LBB0_5:
	mov	w0, #0
	b	LBB0_10
LBB0_6:
	mov	w0, #19
	bl	_wpabuf_alloc
	str	x0, [x19, #8]
	cbz	x0, LBB0_9
; %bb.7:
	mov	w1, #19
	bl	_wpabuf_put
LBB0_8:
	mov	x20, x0
Lloh0:
	adrp	x8, _WLAN_EID_TIME_ADVERTISEMENT@GOTPAGE
Lloh1:
	ldr	x8, [x8, _WLAN_EID_TIME_ADVERTISEMENT@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
	str	w8, [x0], #12
Lloh3:
	adrp	x8, lCPI0_0@PAGE
Lloh4:
	ldr	d0, [x8, lCPI0_0@PAGEOFF]
	stur	d0, [x20, #4]
	ldr	w1, [sp, #20]
	bl	_WPA_PUT_LE16
	ldur	q0, [sp, #4]
	rev64.4s	v0, v0
	ext.16b	v0, v0, v0, #8
	stur	q0, [x20, #20]
	ldr	w8, [sp]
	add	x0, x20, #40
	str	w8, [x20, #36]
	mov	w1, #0
	bl	_WPA_PUT_LE16
	mov	w0, #0
	stp	xzr, xzr, [x20, #56]
	str	xzr, [x20, #48]
	ldr	w8, [x19]
	add	w9, w8, #1
	str	w9, [x19]
	str	w8, [x20, #72]
	b	LBB0_10
LBB0_9:
	mov	w0, #-1
LBB0_10:
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	add	sp, sp, #64
	ret
	.loh AdrpLdr	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.cfi_endproc
                                        ; -- End function
	.comm	_WLAN_EID_TIME_ADVERTISEMENT,4,2 ; @WLAN_EID_TIME_ADVERTISEMENT
.subsections_via_symbols
