	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function bcm_dma_intr
_bcm_dma_intr:                          ## @bcm_dma_intr
	.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
	pushq	%rax
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %r15
	movq	_bcm_dma_sc@GOTPCREL(%rip), %rax
	movq	(%rax), %r13
	movl	4(%r13), %ebx
	movl	8(%rdi), %edi
	callq	_BCM_DMA_CS
	movl	%ebx, %edi
	movl	%eax, %esi
	callq	_bus_read_4
	movl	%eax, %r14d
	movq	_BCM_DMA_CH_USED@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	testl	%eax, (%r15)
	je	LBB0_6
## %bb.1:
	movq	_CS_INT@GOTPCREL(%rip), %rbx
	movl	(%rbx), %eax
	movq	_CS_ERR@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	movl	%ecx, %edx
	orl	%eax, %edx
	testl	%r14d, %edx
	je	LBB0_6
## %bb.2:
	testl	%r14d, %ecx
	je	LBB0_4
## %bb.3:
	movl	4(%r13), %r12d
	movl	8(%r15), %edi
	callq	_BCM_DMA_DEBUG
	movl	%r12d, %edi
	movl	%eax, %esi
	callq	_bus_read_4
	movl	%eax, %r12d
	movl	8(%r13), %edi
	movq	_DEBUG_ERROR_MASK@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	andl	%r12d, %edx
	movl	8(%r15), %ecx
	leaq	L_.str(%rip), %rsi
	callq	_device_printf
	movl	4(%r13), %ebx
	movl	8(%r15), %edi
	callq	_BCM_DMA_DEBUG
	movq	_DEBUG_ERROR_MASK@GOTPCREL(%rip), %rcx
	andl	(%rcx), %r12d
	movl	%ebx, %edi
	movq	_CS_INT@GOTPCREL(%rip), %rbx
	movl	%eax, %esi
	movl	%r12d, %edx
	callq	_bus_write_4
	movl	8(%r13), %edi
	movl	8(%r15), %esi
	callq	_bcm_dma_reset
	movl	(%rbx), %eax
LBB0_4:
	testl	%r14d, %eax
	je	LBB0_6
## %bb.5:
	movl	4(%r13), %r14d
	movl	8(%r15), %edi
	callq	_BCM_DMA_CS
	movq	_CS_END@GOTPCREL(%rip), %rcx
	movl	(%rcx), %edx
	orl	(%rbx), %edx
	movl	%r14d, %edi
	movl	%eax, %esi
	callq	_bus_write_4
	movl	(%r13), %edi
	movl	24(%r15), %esi
	movq	_BUS_DMASYNC_POSTWRITE@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	callq	_bus_dmamap_sync
	movq	16(%r15), %rax
	testq	%rax, %rax
	je	LBB0_6
## %bb.7:
	movl	4(%r15), %esi
	movl	8(%r15), %edi
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmpq	*%rax                           ## TAILCALL
LBB0_6:
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_bcm_dma_sc,8,3                 ## @bcm_dma_sc
	.comm	_BCM_DMA_CH_USED,4,2            ## @BCM_DMA_CH_USED
	.comm	_CS_INT,4,2                     ## @CS_INT
	.comm	_CS_ERR,4,2                     ## @CS_ERR
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"DMA error %d on CH%d\n"

	.comm	_DEBUG_ERROR_MASK,4,2           ## @DEBUG_ERROR_MASK
	.comm	_CS_END,4,2                     ## @CS_END
	.comm	_BUS_DMASYNC_POSTWRITE,4,2      ## @BUS_DMASYNC_POSTWRITE
	.no_dead_strip	_bcm_dma_intr
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function bcm_dma_intr
_bcm_dma_intr:                          ; @bcm_dma_intr
	.cfi_startproc
; %bb.0:
	stp	x26, x25, [sp, #-80]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 80
	stp	x24, x23, [sp, #16]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #32]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #48]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #64]             ; 16-byte Folded Spill
	add	x29, sp, #64
	.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
	mov	x19, x0
Lloh0:
	adrp	x8, _bcm_dma_sc@GOTPAGE
Lloh1:
	ldr	x8, [x8, _bcm_dma_sc@GOTPAGEOFF]
Lloh2:
	ldr	x23, [x8]
	ldr	w20, [x23, #4]
	ldr	w0, [x0, #8]
	bl	_BCM_DMA_CS
	mov	x1, x0
	mov	x0, x20
	bl	_bus_read_4
	ldr	w8, [x19]
Lloh3:
	adrp	x9, _BCM_DMA_CH_USED@GOTPAGE
Lloh4:
	ldr	x9, [x9, _BCM_DMA_CH_USED@GOTPAGEOFF]
Lloh5:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_7
; %bb.1:
	mov	x20, x0
Lloh6:
	adrp	x24, _CS_INT@GOTPAGE
Lloh7:
	ldr	x24, [x24, _CS_INT@GOTPAGEOFF]
	ldr	w8, [x24]
Lloh8:
	adrp	x9, _CS_ERR@GOTPAGE
Lloh9:
	ldr	x9, [x9, _CS_ERR@GOTPAGEOFF]
Lloh10:
	ldr	w9, [x9]
	orr	w10, w9, w8
	tst	w10, w0
	b.eq	LBB0_7
; %bb.2:
	tst	w9, w20
	b.eq	LBB0_4
; %bb.3:
	ldr	w21, [x23, #4]
	ldr	w0, [x19, #8]
	bl	_BCM_DMA_DEBUG
	mov	x1, x0
	mov	x0, x21
	bl	_bus_read_4
	mov	x21, x0
	ldr	w0, [x23, #8]
Lloh11:
	adrp	x25, _DEBUG_ERROR_MASK@GOTPAGE
Lloh12:
	ldr	x25, [x25, _DEBUG_ERROR_MASK@GOTPAGEOFF]
	ldr	w8, [x25]
	and	w2, w8, w21
	ldr	w3, [x19, #8]
Lloh13:
	adrp	x1, l_.str@PAGE
Lloh14:
	add	x1, x1, l_.str@PAGEOFF
	bl	_device_printf
	ldr	w22, [x23, #4]
	ldr	w0, [x19, #8]
	bl	_BCM_DMA_DEBUG
	mov	x1, x0
	ldr	w8, [x25]
	and	w2, w8, w21
	mov	x0, x22
	bl	_bus_write_4
	ldr	w0, [x23, #8]
	ldr	w1, [x19, #8]
	bl	_bcm_dma_reset
	ldr	w8, [x24]
LBB0_4:
	tst	w8, w20
	b.eq	LBB0_7
; %bb.5:
	ldr	w20, [x23, #4]
	ldr	w0, [x19, #8]
	bl	_BCM_DMA_CS
	mov	x1, x0
	ldr	w8, [x24]
Lloh15:
	adrp	x9, _CS_END@GOTPAGE
Lloh16:
	ldr	x9, [x9, _CS_END@GOTPAGEOFF]
Lloh17:
	ldr	w9, [x9]
	orr	w2, w9, w8
	mov	x0, x20
	bl	_bus_write_4
	ldr	w0, [x23]
	ldr	w1, [x19, #24]
Lloh18:
	adrp	x8, _BUS_DMASYNC_POSTWRITE@GOTPAGE
Lloh19:
	ldr	x8, [x8, _BUS_DMASYNC_POSTWRITE@GOTPAGEOFF]
Lloh20:
	ldr	w2, [x8]
	bl	_bus_dmamap_sync
	ldr	x2, [x19, #16]
	cbz	x2, LBB0_7
; %bb.6:
	ldp	w1, w0, [x19, #4]
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #32]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp], #80             ; 16-byte Folded Reload
	br	x2
LBB0_7:
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #32]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp], #80             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpAdd	Lloh13, Lloh14
	.loh AdrpLdrGot	Lloh11, Lloh12
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.cfi_endproc
                                        ; -- End function
	.comm	_bcm_dma_sc,8,3                 ; @bcm_dma_sc
	.comm	_BCM_DMA_CH_USED,4,2            ; @BCM_DMA_CH_USED
	.comm	_CS_INT,4,2                     ; @CS_INT
	.comm	_CS_ERR,4,2                     ; @CS_ERR
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"DMA error %d on CH%d\n"

	.comm	_DEBUG_ERROR_MASK,4,2           ; @DEBUG_ERROR_MASK
	.comm	_CS_END,4,2                     ; @CS_END
	.comm	_BUS_DMASYNC_POSTWRITE,4,2      ; @BUS_DMASYNC_POSTWRITE
	.no_dead_strip	_bcm_dma_intr
.subsections_via_symbols
