	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_wl1251_acx_mem_cfg             ## -- Begin function wl1251_acx_mem_cfg
	.p2align	4, 0x90
_wl1251_acx_mem_cfg:                    ## @wl1251_acx_mem_cfg
	.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	%rdi, %r14
	movq	_DEBUG_ACX@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	L_.str(%rip), %rsi
	callq	_wl1251_debug
	movq	_GFP_KERNEL@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	$72, %edi
	callq	_kzalloc
	testq	%rax, %rax
	je	LBB0_1
## %bb.2:
	movq	%rax, %r15
	movq	_DEFAULT_NUM_STATIONS@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_cpu_to_le16
	movq	%rax, 64(%r15)
	movabsq	$274877906979, %rax             ## imm = 0x4000000023
	movq	%rax, 32(%r15)
	movq	_MAX_TX_QUEUES@GOTPCREL(%rip), %rbx
	movl	(%rbx), %eax
	movl	%eax, 40(%r15)
	movq	_HOSTIF_PKT_RING@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 56(%r15)
	movl	$1, 44(%r15)
	movq	_TRACE_BUFFER_MAX_SIZE@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_cpu_to_le16
	movq	%rax, 48(%r15)
	movq	$0, 24(%r15)
	movq	_ACX_RX_DESC_DEF@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 16(%r15)
	movq	_DEFAULT_RXQ_PRIORITY@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 12(%r15)
	movq	_DEFAULT_RXQ_TYPE@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 8(%r15)
	cmpl	$0, (%rbx)
	jle	LBB0_5
## %bb.3:
	movq	(%r15), %rax
	xorl	%ecx, %ecx
	movq	_ACX_TX_DESC_DEF@GOTPCREL(%rip), %rdx
	.p2align	4, 0x90
LBB0_4:                                 ## =>This Inner Loop Header: Depth=1
	movl	(%rdx), %esi
	movl	%esi, 4(%rax,%rcx,8)
	movl	%ecx, (%rax,%rcx,8)
	incq	%rcx
	movslq	(%rbx), %rsi
	cmpq	%rsi, %rcx
	jl	LBB0_4
LBB0_5:
	movq	_ACX_MEM_CFG@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r14, %rdi
	movq	%r15, %rdx
	movl	$72, %ecx
	callq	_wl1251_cmd_configure
	movl	%eax, %r14d
	testl	%eax, %eax
	jns	LBB0_7
## %bb.6:
	leaq	L_.str.1(%rip), %rdi
	movl	%r14d, %esi
	callq	_wl1251_warning
LBB0_7:
	movq	%r15, %rdi
	callq	_kfree
	jmp	LBB0_8
LBB0_1:
	movq	_ENOMEM@GOTPCREL(%rip), %rax
	xorl	%r14d, %r14d
	subl	(%rax), %r14d
LBB0_8:
	movl	%r14d, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_DEBUG_ACX,4,2                  ## @DEBUG_ACX
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"acx mem cfg"

	.comm	_GFP_KERNEL,4,2                 ## @GFP_KERNEL
	.comm	_ENOMEM,4,2                     ## @ENOMEM
	.comm	_DEFAULT_NUM_STATIONS,4,2       ## @DEFAULT_NUM_STATIONS
	.comm	_MAX_TX_QUEUES,4,2              ## @MAX_TX_QUEUES
	.comm	_HOSTIF_PKT_RING,4,2            ## @HOSTIF_PKT_RING
	.comm	_TRACE_BUFFER_MAX_SIZE,4,2      ## @TRACE_BUFFER_MAX_SIZE
	.comm	_ACX_RX_DESC_DEF,4,2            ## @ACX_RX_DESC_DEF
	.comm	_DEFAULT_RXQ_PRIORITY,4,2       ## @DEFAULT_RXQ_PRIORITY
	.comm	_DEFAULT_RXQ_TYPE,4,2           ## @DEFAULT_RXQ_TYPE
	.comm	_ACX_TX_DESC_DEF,4,2            ## @ACX_TX_DESC_DEF
	.comm	_ACX_MEM_CFG,4,2                ## @ACX_MEM_CFG
L_.str.1:                               ## @.str.1
	.asciz	"wl1251 mem config failed: %d"

.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 wl1251_acx_mem_cfg
lCPI0_0:
	.long	35                              ; 0x23
	.long	64                              ; 0x40
	.section	__TEXT,__text,regular,pure_instructions
	.globl	_wl1251_acx_mem_cfg
	.p2align	2
_wl1251_acx_mem_cfg:                    ; @wl1251_acx_mem_cfg
	.cfi_startproc
; %bb.0:
	stp	x22, x21, [sp, #-48]!           ; 16-byte Folded Spill
	.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
	.cfi_offset w21, -40
	.cfi_offset w22, -48
	mov	x20, x0
Lloh0:
	adrp	x8, _DEBUG_ACX@GOTPAGE
Lloh1:
	ldr	x8, [x8, _DEBUG_ACX@GOTPAGEOFF]
Lloh2:
	ldr	w0, [x8]
Lloh3:
	adrp	x1, l_.str@PAGE
Lloh4:
	add	x1, x1, l_.str@PAGEOFF
	bl	_wl1251_debug
Lloh5:
	adrp	x8, _GFP_KERNEL@GOTPAGE
Lloh6:
	ldr	x8, [x8, _GFP_KERNEL@GOTPAGEOFF]
Lloh7:
	ldr	w1, [x8]
	mov	w0, #72
	bl	_kzalloc
	cbz	x0, LBB0_7
; %bb.1:
	mov	x19, x0
Lloh8:
	adrp	x8, _DEFAULT_NUM_STATIONS@GOTPAGE
Lloh9:
	ldr	x8, [x8, _DEFAULT_NUM_STATIONS@GOTPAGEOFF]
Lloh10:
	ldr	w0, [x8]
	bl	_cpu_to_le16
	str	x0, [x19, #64]
Lloh11:
	adrp	x8, lCPI0_0@PAGE
Lloh12:
	ldr	d0, [x8, lCPI0_0@PAGEOFF]
Lloh13:
	adrp	x21, _MAX_TX_QUEUES@GOTPAGE
Lloh14:
	ldr	x21, [x21, _MAX_TX_QUEUES@GOTPAGEOFF]
	str	d0, [x19, #32]
	ldr	w8, [x21]
Lloh15:
	adrp	x9, _HOSTIF_PKT_RING@GOTPAGE
Lloh16:
	ldr	x9, [x9, _HOSTIF_PKT_RING@GOTPAGEOFF]
Lloh17:
	ldr	w9, [x9]
	str	w9, [x19, #56]
	mov	w9, #1
	stp	w8, w9, [x19, #40]
Lloh18:
	adrp	x8, _TRACE_BUFFER_MAX_SIZE@GOTPAGE
Lloh19:
	ldr	x8, [x8, _TRACE_BUFFER_MAX_SIZE@GOTPAGEOFF]
Lloh20:
	ldr	w0, [x8]
	bl	_cpu_to_le16
	str	x0, [x19, #48]
	str	xzr, [x19, #24]
Lloh21:
	adrp	x8, _ACX_RX_DESC_DEF@GOTPAGE
Lloh22:
	ldr	x8, [x8, _ACX_RX_DESC_DEF@GOTPAGEOFF]
Lloh23:
	ldr	w8, [x8]
	str	w8, [x19, #16]
Lloh24:
	adrp	x8, _DEFAULT_RXQ_PRIORITY@GOTPAGE
Lloh25:
	ldr	x8, [x8, _DEFAULT_RXQ_PRIORITY@GOTPAGEOFF]
Lloh26:
	adrp	x9, _DEFAULT_RXQ_TYPE@GOTPAGE
Lloh27:
	ldr	x9, [x9, _DEFAULT_RXQ_TYPE@GOTPAGEOFF]
Lloh28:
	ldr	w8, [x8]
Lloh29:
	ldr	w9, [x9]
	stp	w9, w8, [x19, #8]
	ldr	w8, [x21]
	cmp	w8, #1
	b.lt	LBB0_4
; %bb.2:
	mov	x8, #0
	ldr	x9, [x19]
	add	x9, x9, #4
Lloh30:
	adrp	x10, _ACX_TX_DESC_DEF@GOTPAGE
Lloh31:
	ldr	x10, [x10, _ACX_TX_DESC_DEF@GOTPAGEOFF]
LBB0_3:                                 ; =>This Inner Loop Header: Depth=1
	ldr	w11, [x10]
	stp	w8, w11, [x9, #-4]
	add	x8, x8, #1
	ldrsw	x11, [x21]
	add	x9, x9, #8
	cmp	x8, x11
	b.lt	LBB0_3
LBB0_4:
Lloh32:
	adrp	x8, _ACX_MEM_CFG@GOTPAGE
Lloh33:
	ldr	x8, [x8, _ACX_MEM_CFG@GOTPAGEOFF]
Lloh34:
	ldr	w1, [x8]
	mov	x0, x20
	mov	x2, x19
	mov	w3, #72
	bl	_wl1251_cmd_configure
	mov	x20, x0
	tbz	w0, #31, LBB0_6
; %bb.5:
Lloh35:
	adrp	x0, l_.str.1@PAGE
Lloh36:
	add	x0, x0, l_.str.1@PAGEOFF
	mov	x1, x20
	bl	_wl1251_warning
LBB0_6:
	mov	x0, x19
	bl	_kfree
	b	LBB0_8
LBB0_7:
Lloh37:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh38:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
Lloh39:
	ldr	w8, [x8]
	neg	w20, w8
LBB0_8:
	mov	x0, x20
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp], #48             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpAdd	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh26, Lloh27, Lloh29
	.loh AdrpLdrGotLdr	Lloh24, Lloh25, Lloh28
	.loh AdrpLdrGotLdr	Lloh21, Lloh22, Lloh23
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpLdrGot	Lloh13, Lloh14
	.loh AdrpLdr	Lloh11, Lloh12
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGot	Lloh30, Lloh31
	.loh AdrpLdrGotLdr	Lloh32, Lloh33, Lloh34
	.loh AdrpAdd	Lloh35, Lloh36
	.loh AdrpLdrGotLdr	Lloh37, Lloh38, Lloh39
	.cfi_endproc
                                        ; -- End function
	.comm	_DEBUG_ACX,4,2                  ; @DEBUG_ACX
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"acx mem cfg"

	.comm	_GFP_KERNEL,4,2                 ; @GFP_KERNEL
	.comm	_ENOMEM,4,2                     ; @ENOMEM
	.comm	_DEFAULT_NUM_STATIONS,4,2       ; @DEFAULT_NUM_STATIONS
	.comm	_MAX_TX_QUEUES,4,2              ; @MAX_TX_QUEUES
	.comm	_HOSTIF_PKT_RING,4,2            ; @HOSTIF_PKT_RING
	.comm	_TRACE_BUFFER_MAX_SIZE,4,2      ; @TRACE_BUFFER_MAX_SIZE
	.comm	_ACX_RX_DESC_DEF,4,2            ; @ACX_RX_DESC_DEF
	.comm	_DEFAULT_RXQ_PRIORITY,4,2       ; @DEFAULT_RXQ_PRIORITY
	.comm	_DEFAULT_RXQ_TYPE,4,2           ; @DEFAULT_RXQ_TYPE
	.comm	_ACX_TX_DESC_DEF,4,2            ; @ACX_TX_DESC_DEF
	.comm	_ACX_MEM_CFG,4,2                ; @ACX_MEM_CFG
l_.str.1:                               ; @.str.1
	.asciz	"wl1251 mem config failed: %d"

.subsections_via_symbols
