	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function mt76_init_beacon_offsets
_mt76_init_beacon_offsets:              ## @mt76_init_beacon_offsets
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%r14
	pushq	%rbx
	subq	$32, %rsp
	.cfi_offset %rbx, -32
	.cfi_offset %r14, -24
	movq	%rdi, %r14
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -24(%rbp)
	movq	_MT_BEACON_BASE@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	xorps	%xmm0, %xmm0
	movaps	%xmm0, -48(%rbp)
	movq	(%rdi), %rdx
	xorl	%esi, %esi
	xorl	%edi, %edi
	.p2align	4, 0x90
LBB0_1:                                 ## =>This Inner Loop Header: Depth=1
	movl	(%rdx,%rdi,4), %ecx
	subl	%eax, %ecx
	leal	63(%rcx), %ebx
	testl	%ecx, %ecx
	cmovnsl	%ecx, %ebx
	sarl	$6, %ebx
	movl	%esi, %ecx
	andb	$24, %cl
	shll	%cl, %ebx
	movl	%edi, %ecx
	andl	$-4, %ecx
	orl	%ebx, -48(%rbp,%rcx)
	incq	%rdi
	addl	$8, %esi
	cmpq	$16, %rdi
	jne	LBB0_1
## %bb.2:
	xorl	%edi, %edi
	callq	_MT_BCN_OFFSET
	movl	-48(%rbp), %edx
	movq	%r14, %rdi
	movl	%eax, %esi
	callq	_mt7601u_wr
	movl	$1, %edi
	callq	_MT_BCN_OFFSET
	movl	-44(%rbp), %edx
	movq	%r14, %rdi
	movl	%eax, %esi
	callq	_mt7601u_wr
	movl	$2, %edi
	callq	_MT_BCN_OFFSET
	movl	-40(%rbp), %edx
	movq	%r14, %rdi
	movl	%eax, %esi
	callq	_mt7601u_wr
	movl	$3, %edi
	callq	_MT_BCN_OFFSET
	movl	-36(%rbp), %edx
	movq	___stack_chk_guard@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rcx
	cmpq	-24(%rbp), %rcx
	jne	LBB0_3
## %bb.4:
	movq	%r14, %rdi
	movl	%eax, %esi
	addq	$32, %rsp
	popq	%rbx
	popq	%r14
	popq	%rbp
	jmp	_mt7601u_wr                     ## TAILCALL
LBB0_3:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.comm	_MT_BEACON_BASE,4,2             ## @MT_BEACON_BASE
	.no_dead_strip	_mt76_init_beacon_offsets
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function mt76_init_beacon_offsets
_mt76_init_beacon_offsets:              ; @mt76_init_beacon_offsets
	.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
	mov	x19, x0
	mov	w8, #0
	mov	x9, #0
Lloh0:
	adrp	x10, ___stack_chk_guard@GOTPAGE
Lloh1:
	ldr	x10, [x10, ___stack_chk_guard@GOTPAGEOFF]
Lloh2:
	ldr	x10, [x10]
Lloh3:
	adrp	x11, _MT_BEACON_BASE@GOTPAGE
Lloh4:
	ldr	x11, [x11, _MT_BEACON_BASE@GOTPAGEOFF]
	str	x10, [sp, #24]
Lloh5:
	ldr	w10, [x11]
	stp	xzr, xzr, [sp, #8]
	ldr	x11, [x0]
	add	x12, sp, #8
LBB0_1:                                 ; =>This Inner Loop Header: Depth=1
	ldr	w13, [x11, x9, lsl #2]
	sub	w13, w13, w10
	add	w14, w13, #63
	cmp	w13, #0
	csel	w13, w14, w13, lt
	asr	w13, w13, #6
	and	w14, w8, #0x18
	lsl	w13, w13, w14
	ubfx	x14, x9, #2, #30
	lsl	x14, x14, #2
	ldr	w15, [x12, x14]
	orr	w13, w13, w15
	str	w13, [x12, x14]
	add	x9, x9, #1
	add	w8, w8, #8
	cmp	x9, #16
	b.ne	LBB0_1
; %bb.2:
	mov	w0, #0
	bl	_MT_BCN_OFFSET
	mov	x1, x0
	ldr	w2, [sp, #8]
	mov	x0, x19
	bl	_mt7601u_wr
	mov	w0, #1
	bl	_MT_BCN_OFFSET
	mov	x1, x0
	ldr	w2, [sp, #12]
	mov	x0, x19
	bl	_mt7601u_wr
	mov	w0, #2
	bl	_MT_BCN_OFFSET
	mov	x1, x0
	ldr	w2, [sp, #16]
	mov	x0, x19
	bl	_mt7601u_wr
	mov	w0, #3
	bl	_MT_BCN_OFFSET
	ldr	w2, [sp, #20]
	ldr	x8, [sp, #24]
Lloh6:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh7:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh8:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_4
; %bb.3:
	mov	x1, x0
	mov	x0, x19
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	add	sp, sp, #64
	b	_mt7601u_wr
LBB0_4:
	bl	___stack_chk_fail
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.cfi_endproc
                                        ; -- End function
	.comm	_MT_BEACON_BASE,4,2             ; @MT_BEACON_BASE
	.no_dead_strip	_mt76_init_beacon_offsets
.subsections_via_symbols
