	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function wl1251_event_ps_report
_wl1251_event_ps_report:                ## @wl1251_event_ps_report
	.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
	.cfi_offset %rbx, -32
	.cfi_offset %r14, -24
	movq	%rsi, %rbx
	movq	%rdi, %r14
	movq	_DEBUG_EVENT@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movl	(%rsi), %edx
	leaq	L_.str(%rip), %rsi
	xorl	%eax, %eax
	callq	_wl1251_debug
	cmpl	$131, (%rbx)
	jne	LBB0_5
## %bb.1:
	movq	_DEBUG_PSM@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	L_.str.1(%rip), %rsi
	xorl	%eax, %eax
	callq	_wl1251_debug
	movl	4(%r14), %ecx
	movq	_STATION_POWER_SAVE_MODE@GOTPCREL(%rip), %rax
	cmpl	(%rax), %ecx
	jne	LBB0_5
## %bb.2:
	movl	(%r14), %ecx
	movq	_WL1251_PSM_ENTRY_RETRIES@GOTPCREL(%rip), %rdx
	cmpl	(%rdx), %ecx
	jge	LBB0_4
## %bb.3:
	incl	%ecx
	movl	%ecx, (%r14)
	movl	(%rax), %esi
	movq	%r14, %rdi
	callq	_wl1251_ps_set_mode
	jmp	LBB0_6
LBB0_4:
	leaq	L_.str.2(%rip), %rdi
	callq	_wl1251_error
LBB0_5:
	movl	$0, (%r14)
LBB0_6:
	xorl	%eax, %eax
	popq	%rbx
	popq	%r14
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_DEBUG_EVENT,4,2                ## @DEBUG_EVENT
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"ps status: %x"

	.comm	_DEBUG_PSM,4,2                  ## @DEBUG_PSM
L_.str.1:                               ## @.str.1
	.asciz	"PSM entry failed"

	.comm	_STATION_POWER_SAVE_MODE,4,2    ## @STATION_POWER_SAVE_MODE
	.comm	_WL1251_PSM_ENTRY_RETRIES,4,2   ## @WL1251_PSM_ENTRY_RETRIES
L_.str.2:                               ## @.str.2
	.asciz	"Power save entry failed, giving up"

	.no_dead_strip	_wl1251_event_ps_report
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function wl1251_event_ps_report
_wl1251_event_ps_report:                ; @wl1251_event_ps_report
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #48
	.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
	mov	x20, x1
	mov	x19, x0
Lloh0:
	adrp	x8, _DEBUG_EVENT@GOTPAGE
Lloh1:
	ldr	x8, [x8, _DEBUG_EVENT@GOTPAGEOFF]
Lloh2:
	ldr	w0, [x8]
	ldr	w8, [x1]
	str	x8, [sp]
Lloh3:
	adrp	x1, l_.str@PAGE
Lloh4:
	add	x1, x1, l_.str@PAGEOFF
	bl	_wl1251_debug
	ldr	w8, [x20]
	cmp	w8, #131
	b.ne	LBB0_5
; %bb.1:
Lloh5:
	adrp	x8, _DEBUG_PSM@GOTPAGE
Lloh6:
	ldr	x8, [x8, _DEBUG_PSM@GOTPAGEOFF]
Lloh7:
	ldr	w0, [x8]
Lloh8:
	adrp	x1, l_.str.1@PAGE
Lloh9:
	add	x1, x1, l_.str.1@PAGEOFF
	bl	_wl1251_debug
	ldr	w9, [x19, #4]
Lloh10:
	adrp	x8, _STATION_POWER_SAVE_MODE@GOTPAGE
Lloh11:
	ldr	x8, [x8, _STATION_POWER_SAVE_MODE@GOTPAGEOFF]
	ldr	w10, [x8]
	cmp	w9, w10
	b.ne	LBB0_5
; %bb.2:
	ldr	w9, [x19]
Lloh12:
	adrp	x10, _WL1251_PSM_ENTRY_RETRIES@GOTPAGE
Lloh13:
	ldr	x10, [x10, _WL1251_PSM_ENTRY_RETRIES@GOTPAGEOFF]
Lloh14:
	ldr	w10, [x10]
	cmp	w9, w10
	b.ge	LBB0_4
; %bb.3:
	add	w9, w9, #1
	str	w9, [x19]
	ldr	w1, [x8]
	mov	x0, x19
	bl	_wl1251_ps_set_mode
	b	LBB0_6
LBB0_4:
Lloh15:
	adrp	x0, l_.str.2@PAGE
Lloh16:
	add	x0, x0, l_.str.2@PAGEOFF
	bl	_wl1251_error
LBB0_5:
	str	wzr, [x19]
LBB0_6:
	mov	w0, #0
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #48
	ret
	.loh AdrpAdd	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh10, Lloh11
	.loh AdrpAdd	Lloh8, Lloh9
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpAdd	Lloh15, Lloh16
	.cfi_endproc
                                        ; -- End function
	.comm	_DEBUG_EVENT,4,2                ; @DEBUG_EVENT
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"ps status: %x"

	.comm	_DEBUG_PSM,4,2                  ; @DEBUG_PSM
l_.str.1:                               ; @.str.1
	.asciz	"PSM entry failed"

	.comm	_STATION_POWER_SAVE_MODE,4,2    ; @STATION_POWER_SAVE_MODE
	.comm	_WL1251_PSM_ENTRY_RETRIES,4,2   ; @WL1251_PSM_ENTRY_RETRIES
l_.str.2:                               ; @.str.2
	.asciz	"Power save entry failed, giving up"

	.no_dead_strip	_wl1251_event_ps_report
.subsections_via_symbols
