	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function hdsp_check_for_iobox
_hdsp_check_for_iobox:                  ## @hdsp_check_for_iobox
	.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	(%rdi), %rax
	movq	_H9652@GOTPCREL(%rip), %rcx
	xorl	%ebx, %ebx
	cmpq	(%rcx), %rax
	je	LBB0_4
## %bb.1:
	movq	_H9632@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	je	LBB0_4
## %bb.2:
	movq	%rdi, %r14
	movq	_HDSP_statusRegister@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_hdsp_read
	movq	_HDSP_ConfigError@GOTPCREL(%rip), %rcx
	testl	%eax, (%rcx)
	je	LBB0_4
## %bb.3:
	leaq	L_.str(%rip), %rdi
	callq	_snd_printk
	movq	_HDSP_FirmwareLoaded@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	notl	%eax
	andl	%eax, 8(%r14)
	movq	_EIO@GOTPCREL(%rip), %rax
	xorl	%ebx, %ebx
	subl	(%rax), %ebx
LBB0_4:
	movl	%ebx, %eax
	popq	%rbx
	popq	%r14
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_H9652,8,3                      ## @H9652
	.comm	_H9632,8,3                      ## @H9632
	.comm	_HDSP_statusRegister,4,2        ## @HDSP_statusRegister
	.comm	_HDSP_ConfigError,4,2           ## @HDSP_ConfigError
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Hammerfall-DSP: no Digiface or Multiface connected!\n"

	.comm	_HDSP_FirmwareLoaded,4,2        ## @HDSP_FirmwareLoaded
	.comm	_EIO,4,2                        ## @EIO
	.no_dead_strip	_hdsp_check_for_iobox
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function hdsp_check_for_iobox
_hdsp_check_for_iobox:                  ; @hdsp_check_for_iobox
	.cfi_startproc
; %bb.0:
	stp	x20, x19, [sp, #-32]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 32
	stp	x29, x30, [sp, #16]             ; 16-byte Folded Spill
	add	x29, sp, #16
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	ldr	x8, [x0]
Lloh0:
	adrp	x9, _H9652@GOTPAGE
Lloh1:
	ldr	x9, [x9, _H9652@GOTPAGEOFF]
Lloh2:
	ldr	x9, [x9]
Lloh3:
	adrp	x10, _H9632@GOTPAGE
Lloh4:
	ldr	x10, [x10, _H9632@GOTPAGEOFF]
Lloh5:
	ldr	x10, [x10]
	cmp	x8, x9
	ccmp	x8, x10, #4, ne
	b.eq	LBB0_3
; %bb.1:
	mov	x19, x0
Lloh6:
	adrp	x8, _HDSP_statusRegister@GOTPAGE
Lloh7:
	ldr	x8, [x8, _HDSP_statusRegister@GOTPAGEOFF]
Lloh8:
	ldr	w1, [x8]
	bl	_hdsp_read
Lloh9:
	adrp	x8, _HDSP_ConfigError@GOTPAGE
Lloh10:
	ldr	x8, [x8, _HDSP_ConfigError@GOTPAGEOFF]
Lloh11:
	ldr	w8, [x8]
	tst	w8, w0
	b.eq	LBB0_3
; %bb.2:
Lloh12:
	adrp	x0, l_.str@PAGE
Lloh13:
	add	x0, x0, l_.str@PAGEOFF
	bl	_snd_printk
Lloh14:
	adrp	x8, _HDSP_FirmwareLoaded@GOTPAGE
Lloh15:
	ldr	x8, [x8, _HDSP_FirmwareLoaded@GOTPAGEOFF]
Lloh16:
	ldr	w8, [x8]
	ldr	w9, [x19, #8]
	bic	w8, w9, w8
	str	w8, [x19, #8]
Lloh17:
	adrp	x8, _EIO@GOTPAGE
Lloh18:
	ldr	x8, [x8, _EIO@GOTPAGEOFF]
Lloh19:
	ldr	w8, [x8]
	neg	w0, w8
	b	LBB0_4
LBB0_3:
	mov	w0, #0
LBB0_4:
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh17, Lloh18, Lloh19
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpAdd	Lloh12, Lloh13
	.cfi_endproc
                                        ; -- End function
	.comm	_H9652,8,3                      ; @H9652
	.comm	_H9632,8,3                      ; @H9632
	.comm	_HDSP_statusRegister,4,2        ; @HDSP_statusRegister
	.comm	_HDSP_ConfigError,4,2           ; @HDSP_ConfigError
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Hammerfall-DSP: no Digiface or Multiface connected!\n"

	.comm	_HDSP_FirmwareLoaded,4,2        ; @HDSP_FirmwareLoaded
	.comm	_EIO,4,2                        ; @EIO
	.no_dead_strip	_hdsp_check_for_iobox
.subsections_via_symbols
