	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function hw_card_init
_hw_card_init:                          ## @hw_card_init
	.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	%r12
	pushq	%rbx
	subq	$64, %rsp
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rsi, %r14
	movq	%rdi, %rbx
	movq	$0, -64(%rbp)
	xorps	%xmm0, %xmm0
	movaps	%xmm0, -96(%rbp)
	movq	$0, -80(%rbp)
	movq	$0, -56(%rbp)
	movq	$0, -48(%rbp)
	callq	_hw_card_start
	testl	%eax, %eax
	je	LBB0_1
LBB0_10:
	addq	$64, %rsp
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_1:
	movl	8(%r14), %esi
	movq	%rbx, %rdi
	callq	_hw_pll_init
	testl	%eax, %eax
	js	LBB0_10
## %bb.2:
	movq	%rbx, %rdi
	callq	_hw_auto_init
	testl	%eax, %eax
	js	LBB0_10
## %bb.3:
	movq	_GCTL@GOTPCREL(%rip), %r12
	movl	(%r12), %esi
	movq	%rbx, %rdi
	callq	_hw_read_20kx
	movl	%eax, -36(%rbp)
	movq	_GCTL_EAC@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	-36(%rbp), %r15
	movq	%r15, %rdi
	movl	$1, %edx
	callq	_set_field
	movq	_GCTL_DBP@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r15, %rdi
	movl	$1, %edx
	callq	_set_field
	movq	_GCTL_TBP@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r15, %rdi
	movl	$1, %edx
	callq	_set_field
	movq	_GCTL_FBP@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r15, %rdi
	movl	$1, %edx
	callq	_set_field
	movq	_GCTL_ET@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r15, %rdi
	movl	$1, %edx
	callq	_set_field
	movl	(%r12), %esi
	movl	-36(%rbp), %edx
	movq	%rbx, %rdi
	callq	_hw_write_20kx
	movl	$10, %edi
	callq	_mdelay
	movq	_GIE@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%rbx, %rdi
	xorl	%edx, %edx
	callq	_hw_write_20kx
	movq	_SRCIP@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%rbx, %rdi
	xorl	%edx, %edx
	callq	_hw_write_20kx
	movl	$30, %edi
	callq	_mdelay
	movl	(%rbx), %eax
	addl	$-128, %eax
	movl	$486, %edx                      ## imm = 0x1E6
	cmpl	$2, %eax
	ja	LBB0_5
## %bb.4:
	cltq
	leaq	l_switch.table.hw_card_init(%rip), %rcx
	movl	(%rcx,%rax,4), %edx
LBB0_5:
	movq	_GPIOCTL@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%rbx, %rdi
	callq	_hw_write_20kx
	movl	4(%r14), %eax
	movl	%eax, -48(%rbp)
	leaq	-48(%rbp), %rsi
	movq	%rbx, %rdi
	callq	_hw_trn_init
	testl	%eax, %eax
	js	LBB0_10
## %bb.6:
	movl	(%r14), %eax
	movl	%eax, -56(%rbp)
	leaq	-56(%rbp), %rsi
	movq	%rbx, %rdi
	callq	_hw_daio_init
	testl	%eax, %eax
	js	LBB0_10
## %bb.7:
	movl	(%r14), %eax
	movl	%eax, -64(%rbp)
	leaq	-64(%rbp), %rsi
	movq	%rbx, %rdi
	callq	_hw_dac_init
	testl	%eax, %eax
	js	LBB0_10
## %bb.8:
	movl	(%r14), %eax
	movl	%eax, -84(%rbp)
	movq	_ADC_LINEIN@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, -88(%rbp)
	movq	$0, -96(%rbp)
	leaq	-96(%rbp), %rsi
	movq	%rbx, %rdi
	callq	_hw_adc_init
	testl	%eax, %eax
	js	LBB0_10
## %bb.9:
	movq	_SRCMCTL@GOTPCREL(%rip), %r14
	movl	(%r14), %esi
	movq	%rbx, %rdi
	callq	_hw_read_20kx
	orl	$1, %eax
	movl	(%r14), %esi
	movq	%rbx, %rdi
	movl	%eax, %edx
	callq	_hw_write_20kx
	xorl	%eax, %eax
	jmp	LBB0_10
	.cfi_endproc
                                        ## -- End function
	.comm	_GCTL,4,2                       ## @GCTL
	.comm	_GCTL_EAC,4,2                   ## @GCTL_EAC
	.comm	_GCTL_DBP,4,2                   ## @GCTL_DBP
	.comm	_GCTL_TBP,4,2                   ## @GCTL_TBP
	.comm	_GCTL_FBP,4,2                   ## @GCTL_FBP
	.comm	_GCTL_ET,4,2                    ## @GCTL_ET
	.comm	_GIE,4,2                        ## @GIE
	.comm	_SRCIP,4,2                      ## @SRCIP
	.comm	_GPIOCTL,4,2                    ## @GPIOCTL
	.comm	_ADC_LINEIN,4,2                 ## @ADC_LINEIN
	.comm	_SRCMCTL,4,2                    ## @SRCMCTL
	.no_dead_strip	_hw_card_init
	.section	__TEXT,__const
	.p2align	2                               ## @switch.table.hw_card_init
l_switch.table.hw_card_init:
	.long	194                             ## 0xc2
	.long	230                             ## 0xe6
	.long	5118                            ## 0x13fe

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function hw_card_init
_hw_card_init:                          ; @hw_card_init
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #112
	.cfi_def_cfa_offset 112
	stp	x22, x21, [sp, #64]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #80]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #96]             ; 16-byte Folded Spill
	add	x29, sp, #96
	.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, x1
	mov	x19, x0
	stp	xzr, xzr, [sp, #40]
	stp	xzr, xzr, [sp, #24]
	stp	xzr, xzr, [sp, #8]
	bl	_hw_card_start
	cbz	w0, LBB0_2
LBB0_1:
	ldp	x29, x30, [sp, #96]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #80]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #64]             ; 16-byte Folded Reload
	add	sp, sp, #112
	ret
LBB0_2:
	ldr	w1, [x20, #8]
	mov	x0, x19
	bl	_hw_pll_init
	tbnz	w0, #31, LBB0_1
; %bb.3:
	mov	x0, x19
	bl	_hw_auto_init
	tbnz	w0, #31, LBB0_1
; %bb.4:
Lloh0:
	adrp	x21, _GCTL@GOTPAGE
Lloh1:
	ldr	x21, [x21, _GCTL@GOTPAGEOFF]
	ldr	w1, [x21]
	mov	x0, x19
	bl	_hw_read_20kx
	stur	w0, [x29, #-36]
Lloh2:
	adrp	x8, _GCTL_EAC@GOTPAGE
Lloh3:
	ldr	x8, [x8, _GCTL_EAC@GOTPAGEOFF]
Lloh4:
	ldr	w1, [x8]
	sub	x0, x29, #36
	mov	w2, #1
	bl	_set_field
Lloh5:
	adrp	x8, _GCTL_DBP@GOTPAGE
Lloh6:
	ldr	x8, [x8, _GCTL_DBP@GOTPAGEOFF]
Lloh7:
	ldr	w1, [x8]
	sub	x0, x29, #36
	mov	w2, #1
	bl	_set_field
Lloh8:
	adrp	x8, _GCTL_TBP@GOTPAGE
Lloh9:
	ldr	x8, [x8, _GCTL_TBP@GOTPAGEOFF]
Lloh10:
	ldr	w1, [x8]
	sub	x0, x29, #36
	mov	w2, #1
	bl	_set_field
Lloh11:
	adrp	x8, _GCTL_FBP@GOTPAGE
Lloh12:
	ldr	x8, [x8, _GCTL_FBP@GOTPAGEOFF]
Lloh13:
	ldr	w1, [x8]
	sub	x0, x29, #36
	mov	w2, #1
	bl	_set_field
Lloh14:
	adrp	x8, _GCTL_ET@GOTPAGE
Lloh15:
	ldr	x8, [x8, _GCTL_ET@GOTPAGEOFF]
Lloh16:
	ldr	w1, [x8]
	sub	x0, x29, #36
	mov	w2, #1
	bl	_set_field
	ldr	w1, [x21]
	ldur	w2, [x29, #-36]
	mov	x0, x19
	bl	_hw_write_20kx
	mov	w0, #10
	bl	_mdelay
Lloh17:
	adrp	x8, _GIE@GOTPAGE
Lloh18:
	ldr	x8, [x8, _GIE@GOTPAGEOFF]
Lloh19:
	ldr	w1, [x8]
	mov	x0, x19
	mov	w2, #0
	bl	_hw_write_20kx
Lloh20:
	adrp	x8, _SRCIP@GOTPAGE
Lloh21:
	ldr	x8, [x8, _SRCIP@GOTPAGEOFF]
Lloh22:
	ldr	w1, [x8]
	mov	x0, x19
	mov	w2, #0
	bl	_hw_write_20kx
	mov	w0, #30
	bl	_mdelay
	ldr	w8, [x19]
	sub	w8, w8, #128
	cmp	w8, #2
	b.hi	LBB0_6
; %bb.5:
Lloh23:
	adrp	x9, l_switch.table.hw_card_init@PAGE
Lloh24:
	add	x9, x9, l_switch.table.hw_card_init@PAGEOFF
	ldr	w2, [x9, w8, sxtw #2]
	b	LBB0_7
LBB0_6:
	mov	w2, #486
LBB0_7:
Lloh25:
	adrp	x8, _GPIOCTL@GOTPAGE
Lloh26:
	ldr	x8, [x8, _GPIOCTL@GOTPAGEOFF]
Lloh27:
	ldr	w1, [x8]
	mov	x0, x19
	bl	_hw_write_20kx
	ldr	w8, [x20, #4]
	str	w8, [sp, #8]
	add	x1, sp, #8
	mov	x0, x19
	bl	_hw_trn_init
	tbnz	w0, #31, LBB0_1
; %bb.8:
	ldr	w8, [x20]
	str	w8, [sp, #16]
	add	x1, sp, #16
	mov	x0, x19
	bl	_hw_daio_init
	tbnz	w0, #31, LBB0_1
; %bb.9:
	ldr	w8, [x20]
	str	w8, [sp, #48]
	add	x1, sp, #48
	mov	x0, x19
	bl	_hw_dac_init
	tbnz	w0, #31, LBB0_1
; %bb.10:
	ldr	w8, [x20]
Lloh28:
	adrp	x9, _ADC_LINEIN@GOTPAGE
Lloh29:
	ldr	x9, [x9, _ADC_LINEIN@GOTPAGEOFF]
Lloh30:
	ldr	w9, [x9]
	stp	w9, w8, [sp, #32]
	str	xzr, [sp, #24]
	add	x1, sp, #24
	mov	x0, x19
	bl	_hw_adc_init
	tbnz	w0, #31, LBB0_1
; %bb.11:
Lloh31:
	adrp	x20, _SRCMCTL@GOTPAGE
Lloh32:
	ldr	x20, [x20, _SRCMCTL@GOTPAGEOFF]
	ldr	w1, [x20]
	mov	x0, x19
	bl	_hw_read_20kx
	orr	w2, w0, #0x1
	ldr	w1, [x20]
	mov	x0, x19
	bl	_hw_write_20kx
	mov	w0, #0
	b	LBB0_1
	.loh AdrpLdrGotLdr	Lloh20, Lloh21, Lloh22
	.loh AdrpLdrGotLdr	Lloh17, Lloh18, Lloh19
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpAdd	Lloh23, Lloh24
	.loh AdrpLdrGotLdr	Lloh25, Lloh26, Lloh27
	.loh AdrpLdrGotLdr	Lloh28, Lloh29, Lloh30
	.loh AdrpLdrGot	Lloh31, Lloh32
	.cfi_endproc
                                        ; -- End function
	.comm	_GCTL,4,2                       ; @GCTL
	.comm	_GCTL_EAC,4,2                   ; @GCTL_EAC
	.comm	_GCTL_DBP,4,2                   ; @GCTL_DBP
	.comm	_GCTL_TBP,4,2                   ; @GCTL_TBP
	.comm	_GCTL_FBP,4,2                   ; @GCTL_FBP
	.comm	_GCTL_ET,4,2                    ; @GCTL_ET
	.comm	_GIE,4,2                        ; @GIE
	.comm	_SRCIP,4,2                      ; @SRCIP
	.comm	_GPIOCTL,4,2                    ; @GPIOCTL
	.comm	_ADC_LINEIN,4,2                 ; @ADC_LINEIN
	.comm	_SRCMCTL,4,2                    ; @SRCMCTL
	.no_dead_strip	_hw_card_init
	.section	__TEXT,__const
	.p2align	2                               ; @switch.table.hw_card_init
l_switch.table.hw_card_init:
	.long	194                             ; 0xc2
	.long	230                             ; 0xe6
	.long	5118                            ; 0x13fe

.subsections_via_symbols
