	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function brcmf_msgbuf_flowring_create_worker
_brcmf_msgbuf_flowring_create_worker:   ## @brcmf_msgbuf_flowring_create_worker
	.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
	movq	%rsi, %rax
	movq	%rdi, %r14
	movq	32(%rdi), %r12
	movq	_BRCMF_H2D_TXFLOWRING_MAX_ITEM@GOTPCREL(%rip), %rbx
	movq	_BRCMF_H2D_TXFLOWRING_ITEMSIZE@GOTPCREL(%rip), %r15
	movq	(%r15), %rsi
	imulq	(%rbx), %rsi
	movq	%rax, -64(%rbp)                 ## 8-byte Spill
	movq	(%rax), %r13
	movq	(%r12), %rax
	movl	(%rax), %edi
	leaq	(,%r13,8), %rdx
	addq	(%r14), %rdx
	movq	_GFP_KERNEL@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	callq	_dma_alloc_coherent
	testq	%rax, %rax
	je	LBB0_1
## %bb.2:
	movq	24(%r14), %rcx
	movl	(%rcx,%r13,4), %edi
	movq	(%rbx), %rsi
	movq	(%r15), %rdx
	movq	%rax, %rcx
	callq	_brcmf_commonring_config
	movq	16(%r14), %rax
	movq	_BRCMF_H2D_MSGRING_CONTROL_SUBMIT@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rcx
	movq	(%rax,%rcx,8), %rbx
	movq	%rbx, %rdi
	callq	_brcmf_commonring_lock
	movq	%rbx, -48(%rbp)                 ## 8-byte Spill
	movq	%rbx, %rdi
	callq	_brcmf_commonring_reserve_for_write
	testq	%rax, %rax
	je	LBB0_3
## %bb.4:
	movq	%rax, %r15
	movq	%r12, -56(%rbp)                 ## 8-byte Spill
	movq	_MSGBUF_TYPE_FLOW_RING_CREATE@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 68(%r15)
	movq	-64(%rbp), %rbx                 ## 8-byte Reload
	movl	8(%rbx), %eax
	movl	%eax, 64(%r15)
	movq	$0, 56(%r15)
	movl	8(%r14), %edi
	movq	%r13, %rsi
	callq	_brcmf_flowring_tid
	movl	%eax, (%r15)
	movq	_BRCMF_H2D_MSGRING_FLOWRING_IDSTART@GOTPCREL(%rip), %rax
	movq	(%rax), %rdi
	addq	%r13, %rdi
	callq	_cpu_to_le16
	movq	%rax, 48(%r15)
	movl	44(%r15), %edi
	movl	16(%rbx), %esi
	movq	_ETH_ALEN@GOTPCREL(%rip), %r12
	movl	(%r12), %edx
	callq	_memcpy
	movl	40(%r15), %edi
	movl	12(%rbx), %esi
	movl	(%r12), %edx
	callq	_memcpy
	movq	(%r14), %rax
	movl	(%rax,%r13,8), %r12d
	callq	_cpu_to_le32
	movq	%rax, 32(%r15)
	movl	%r12d, %edi
	callq	_cpu_to_le32
	movq	%rax, 24(%r15)
	movq	_BRCMF_H2D_TXFLOWRING_MAX_ITEM@GOTPCREL(%rip), %rax
	movq	(%rax), %rdi
	callq	_cpu_to_le16
	movq	%rax, 16(%r15)
	movq	_BRCMF_H2D_TXFLOWRING_ITEMSIZE@GOTPCREL(%rip), %rax
	movq	(%rax), %rdi
	callq	_cpu_to_le16
	movq	%rax, 8(%r15)
	movq	_MSGBUF@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movl	8(%rbx), %r9d
	movl	12(%rbx), %ecx
	movl	(%r15), %r8d
	leaq	L_.str.2(%rip), %rsi
	movq	%r13, %rdx
	callq	_brcmf_dbg
	movq	-48(%rbp), %rbx                 ## 8-byte Reload
	movq	%rbx, %rdi
	callq	_brcmf_commonring_write_complete
	movl	%eax, %r15d
	movq	%rbx, %rdi
	callq	_brcmf_commonring_unlock
	testl	%r15d, %r15d
	je	LBB0_8
## %bb.5:
	leaq	L_.str.3(%rip), %rsi
	movq	-56(%rbp), %rdi                 ## 8-byte Reload
	callq	_bphy_err
	jmp	LBB0_6
LBB0_1:
	leaq	L_.str(%rip), %rsi
	movq	%r12, %rdi
	callq	_bphy_err
	movl	8(%r14), %edi
	movq	%r13, %rsi
	callq	_brcmf_flowring_delete
	jmp	LBB0_7
LBB0_3:
	leaq	L_.str.1(%rip), %rsi
	movq	%r12, %rdi
	callq	_bphy_err
	movq	-48(%rbp), %rdi                 ## 8-byte Reload
	callq	_brcmf_commonring_unlock
LBB0_6:
	movq	%r14, %rdi
	movq	%r13, %rsi
	callq	_brcmf_msgbuf_remove_flowring
LBB0_7:
	movq	_BRCMF_FLOWRING_INVALID_ID@GOTPCREL(%rip), %rax
	movq	(%rax), %r13
LBB0_8:
	movq	%r13, %rax
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_BRCMF_H2D_TXFLOWRING_MAX_ITEM,8,3 ## @BRCMF_H2D_TXFLOWRING_MAX_ITEM
	.comm	_BRCMF_H2D_TXFLOWRING_ITEMSIZE,8,3 ## @BRCMF_H2D_TXFLOWRING_ITEMSIZE
	.comm	_GFP_KERNEL,4,2                 ## @GFP_KERNEL
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"dma_alloc_coherent failed\n"

	.comm	_BRCMF_FLOWRING_INVALID_ID,8,3  ## @BRCMF_FLOWRING_INVALID_ID
	.comm	_BRCMF_H2D_MSGRING_CONTROL_SUBMIT,8,3 ## @BRCMF_H2D_MSGRING_CONTROL_SUBMIT
L_.str.1:                               ## @.str.1
	.asciz	"Failed to reserve space in commonring\n"

	.comm	_MSGBUF_TYPE_FLOW_RING_CREATE,4,2 ## @MSGBUF_TYPE_FLOW_RING_CREATE
	.comm	_BRCMF_H2D_MSGRING_FLOWRING_IDSTART,8,3 ## @BRCMF_H2D_MSGRING_FLOWRING_IDSTART
	.comm	_ETH_ALEN,4,2                   ## @ETH_ALEN
	.comm	_MSGBUF,4,2                     ## @MSGBUF
L_.str.2:                               ## @.str.2
	.asciz	"Send Flow Create Req flow ID %d for peer %pM prio %d ifindex %d\n"

L_.str.3:                               ## @.str.3
	.asciz	"Failed to write commonring\n"

	.no_dead_strip	_brcmf_msgbuf_flowring_create_worker
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function brcmf_msgbuf_flowring_create_worker
_brcmf_msgbuf_flowring_create_worker:   ; @brcmf_msgbuf_flowring_create_worker
	.cfi_startproc
; %bb.0:
	stp	x28, x27, [sp, #-96]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 96
	stp	x26, x25, [sp, #16]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #32]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #48]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #64]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #80]             ; 16-byte Folded Spill
	add	x29, sp, #80
	.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
	.cfi_offset w25, -72
	.cfi_offset w26, -80
	.cfi_offset w27, -88
	.cfi_offset w28, -96
	mov	x22, x1
	mov	x20, x0
	ldr	x21, [x0, #32]
	ldr	x19, [x1]
Lloh0:
	adrp	x27, _BRCMF_H2D_TXFLOWRING_MAX_ITEM@GOTPAGE
Lloh1:
	ldr	x27, [x27, _BRCMF_H2D_TXFLOWRING_MAX_ITEM@GOTPAGEOFF]
	ldr	x8, [x27]
Lloh2:
	adrp	x26, _BRCMF_H2D_TXFLOWRING_ITEMSIZE@GOTPAGE
Lloh3:
	ldr	x26, [x26, _BRCMF_H2D_TXFLOWRING_ITEMSIZE@GOTPAGEOFF]
	ldr	x9, [x26]
	mul	x1, x9, x8
	ldr	x8, [x21]
	ldr	w0, [x8]
	ldr	x8, [x20]
	add	x2, x8, x19, lsl #3
Lloh4:
	adrp	x8, _GFP_KERNEL@GOTPAGE
Lloh5:
	ldr	x8, [x8, _GFP_KERNEL@GOTPAGEOFF]
Lloh6:
	ldr	w3, [x8]
	bl	_dma_alloc_coherent
	cbz	x0, LBB0_4
; %bb.1:
	mov	x3, x0
	ldr	x8, [x20, #24]
	ldr	w0, [x8, x19, lsl #2]
	ldr	x1, [x27]
	ldr	x2, [x26]
	bl	_brcmf_commonring_config
	ldr	x8, [x20, #16]
Lloh7:
	adrp	x9, _BRCMF_H2D_MSGRING_CONTROL_SUBMIT@GOTPAGE
Lloh8:
	ldr	x9, [x9, _BRCMF_H2D_MSGRING_CONTROL_SUBMIT@GOTPAGEOFF]
Lloh9:
	ldr	x9, [x9]
	ldr	x23, [x8, x9, lsl #3]
	mov	x0, x23
	bl	_brcmf_commonring_lock
	mov	x0, x23
	bl	_brcmf_commonring_reserve_for_write
	cbz	x0, LBB0_5
; %bb.2:
	mov	x24, x0
Lloh10:
	adrp	x8, _MSGBUF_TYPE_FLOW_RING_CREATE@GOTPAGE
Lloh11:
	ldr	x8, [x8, _MSGBUF_TYPE_FLOW_RING_CREATE@GOTPAGEOFF]
Lloh12:
	ldr	w8, [x8]
	ldr	w9, [x22, #8]
	stp	w9, w8, [x0, #64]
	str	xzr, [x0, #56]
	ldr	w0, [x20, #8]
	mov	x1, x19
	bl	_brcmf_flowring_tid
	str	w0, [x24]
Lloh13:
	adrp	x8, _BRCMF_H2D_MSGRING_FLOWRING_IDSTART@GOTPAGE
Lloh14:
	ldr	x8, [x8, _BRCMF_H2D_MSGRING_FLOWRING_IDSTART@GOTPAGEOFF]
Lloh15:
	ldr	x8, [x8]
	add	x0, x8, x19
	bl	_cpu_to_le16
	str	x0, [x24, #48]
	ldr	w0, [x24, #44]
	ldr	w1, [x22, #16]
Lloh16:
	adrp	x25, _ETH_ALEN@GOTPAGE
Lloh17:
	ldr	x25, [x25, _ETH_ALEN@GOTPAGEOFF]
	ldr	w2, [x25]
	bl	_memcpy
	ldr	w0, [x24, #40]
	ldr	w1, [x22, #12]
	ldr	w2, [x25]
	bl	_memcpy
	ldr	x8, [x20]
	ldr	x25, [x8, x19, lsl #3]
	bl	_cpu_to_le32
	str	x0, [x24, #32]
	mov	x0, x25
	bl	_cpu_to_le32
	str	x0, [x24, #24]
	ldr	x0, [x27]
	bl	_cpu_to_le16
	str	x0, [x24, #16]
	ldr	x0, [x26]
	bl	_cpu_to_le16
	str	x0, [x24, #8]
Lloh18:
	adrp	x8, _MSGBUF@GOTPAGE
Lloh19:
	ldr	x8, [x8, _MSGBUF@GOTPAGEOFF]
Lloh20:
	ldr	w0, [x8]
	ldr	w4, [x24]
	ldp	w5, w3, [x22, #8]
Lloh21:
	adrp	x1, l_.str.2@PAGE
Lloh22:
	add	x1, x1, l_.str.2@PAGEOFF
	mov	x2, x19
	bl	_brcmf_dbg
	mov	x0, x23
	bl	_brcmf_commonring_write_complete
	mov	x22, x0
	mov	x0, x23
	bl	_brcmf_commonring_unlock
	cbz	w22, LBB0_8
; %bb.3:
Lloh23:
	adrp	x1, l_.str.3@PAGE
Lloh24:
	add	x1, x1, l_.str.3@PAGEOFF
	mov	x0, x21
	bl	_bphy_err
	b	LBB0_6
LBB0_4:
Lloh25:
	adrp	x1, l_.str@PAGE
Lloh26:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x21
	bl	_bphy_err
	ldr	w0, [x20, #8]
	mov	x1, x19
	bl	_brcmf_flowring_delete
	b	LBB0_7
LBB0_5:
Lloh27:
	adrp	x1, l_.str.1@PAGE
Lloh28:
	add	x1, x1, l_.str.1@PAGEOFF
	mov	x0, x21
	bl	_bphy_err
	mov	x0, x23
	bl	_brcmf_commonring_unlock
LBB0_6:
	mov	x0, x20
	mov	x1, x19
	bl	_brcmf_msgbuf_remove_flowring
LBB0_7:
Lloh29:
	adrp	x8, _BRCMF_FLOWRING_INVALID_ID@GOTPAGE
Lloh30:
	ldr	x8, [x8, _BRCMF_FLOWRING_INVALID_ID@GOTPAGEOFF]
Lloh31:
	ldr	x19, [x8]
LBB0_8:
	mov	x0, x19
	ldp	x29, x30, [sp, #80]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #64]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #48]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #32]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #16]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp], #96             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh4, Lloh5, Lloh6
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh7, Lloh8, Lloh9
	.loh AdrpAdd	Lloh21, Lloh22
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.loh AdrpLdrGot	Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh13, Lloh14, Lloh15
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh12
	.loh AdrpAdd	Lloh23, Lloh24
	.loh AdrpAdd	Lloh25, Lloh26
	.loh AdrpAdd	Lloh27, Lloh28
	.loh AdrpLdrGotLdr	Lloh29, Lloh30, Lloh31
	.cfi_endproc
                                        ; -- End function
	.comm	_BRCMF_H2D_TXFLOWRING_MAX_ITEM,8,3 ; @BRCMF_H2D_TXFLOWRING_MAX_ITEM
	.comm	_BRCMF_H2D_TXFLOWRING_ITEMSIZE,8,3 ; @BRCMF_H2D_TXFLOWRING_ITEMSIZE
	.comm	_GFP_KERNEL,4,2                 ; @GFP_KERNEL
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"dma_alloc_coherent failed\n"

	.comm	_BRCMF_FLOWRING_INVALID_ID,8,3  ; @BRCMF_FLOWRING_INVALID_ID
	.comm	_BRCMF_H2D_MSGRING_CONTROL_SUBMIT,8,3 ; @BRCMF_H2D_MSGRING_CONTROL_SUBMIT
l_.str.1:                               ; @.str.1
	.asciz	"Failed to reserve space in commonring\n"

	.comm	_MSGBUF_TYPE_FLOW_RING_CREATE,4,2 ; @MSGBUF_TYPE_FLOW_RING_CREATE
	.comm	_BRCMF_H2D_MSGRING_FLOWRING_IDSTART,8,3 ; @BRCMF_H2D_MSGRING_FLOWRING_IDSTART
	.comm	_ETH_ALEN,4,2                   ; @ETH_ALEN
	.comm	_MSGBUF,4,2                     ; @MSGBUF
l_.str.2:                               ; @.str.2
	.asciz	"Send Flow Create Req flow ID %d for peer %pM prio %d ifindex %d\n"

l_.str.3:                               ; @.str.3
	.asciz	"Failed to write commonring\n"

	.no_dead_strip	_brcmf_msgbuf_flowring_create_worker
.subsections_via_symbols
