	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function ad714x_hw_init
_ad714x_hw_init:                        ## @ad714x_hw_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	%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, %rbx
	movq	_STAGE_NUM@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	testl	%ecx, %ecx
	jle	LBB0_7
## %bb.1:
	movq	_STAGE_CFGREG_NUM@GOTPCREL(%rip), %r15
	movl	(%r15), %eax
	xorl	%r12d, %r12d
	jmp	LBB0_2
	.p2align	4, 0x90
LBB0_6:                                 ##   in Loop: Header=BB0_2 Depth=1
	incq	%r12
	movslq	%ecx, %rdx
	cmpq	%rdx, %r12
	jge	LBB0_7
LBB0_2:                                 ## =>This Loop Header: Depth=1
                                        ##     Child Loop BB0_4 Depth 2
	testl	%eax, %eax
	jle	LBB0_6
## %bb.3:                               ##   in Loop: Header=BB0_2 Depth=1
	imull	%r12d, %eax
	movq	_AD714X_STAGECFG_REG@GOTPCREL(%rip), %rcx
	addw	(%rcx), %ax
	movzwl	%ax, %r14d
	xorl	%r13d, %r13d
	.p2align	4, 0x90
LBB0_4:                                 ##   Parent Loop BB0_2 Depth=1
                                        ## =>  This Inner Loop Header: Depth=2
	movq	24(%rbx), %rax
	movq	(%rax), %rax
	movq	(%rax,%r12,8), %rax
	movl	(%rax,%r13,4), %edx
	leal	(%r14,%r13), %esi
	movq	%rbx, %rdi
	callq	*16(%rbx)
	incq	%r13
	movslq	(%r15), %rax
	cmpq	%rax, %r13
	jl	LBB0_4
## %bb.5:                               ##   in Loop: Header=BB0_2 Depth=1
	movq	_STAGE_NUM@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	jmp	LBB0_6
LBB0_7:
	movq	_SYS_CFGREG_NUM@GOTPCREL(%rip), %r15
	cmpl	$0, (%r15)
	jle	LBB0_13
## %bb.8:
	xorl	%r14d, %r14d
	movq	_AD714X_SYSCFG_REG@GOTPCREL(%rip), %r12
	.p2align	4, 0x90
LBB0_9:                                 ## =>This Inner Loop Header: Depth=1
	movl	(%r12), %esi
	addl	%r14d, %esi
	movq	24(%rbx), %rax
	movq	8(%rax), %rax
	movl	(%rax,%r14,4), %edx
	movq	%rbx, %rdi
	callq	*16(%rbx)
	incq	%r14
	movslq	(%r15), %rax
	cmpq	%rax, %r14
	jl	LBB0_9
## %bb.10:
	testl	%eax, %eax
	jle	LBB0_13
## %bb.11:
	xorl	%r13d, %r13d
	leaq	-42(%rbp), %r14
	.p2align	4, 0x90
LBB0_12:                                ## =>This Inner Loop Header: Depth=1
	movl	(%r12), %esi
	addl	%r13d, %esi
	movq	%rbx, %rdi
	movq	%r14, %rdx
	movl	$1, %ecx
	callq	*8(%rbx)
	incl	%r13d
	cmpl	(%r15), %r13d
	jl	LBB0_12
LBB0_13:
	movq	_AD714X_STG_CAL_EN_REG@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%rbx, %rdi
	movl	$4095, %edx                     ## imm = 0xFFF
	callq	*16(%rbx)
	movq	_STG_LOW_INT_STA_REG@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%rbx, %rdi
	movq	%rbx, %rdx
	movl	$3, %ecx
	callq	*8(%rbx)
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_STAGE_NUM,4,2                  ## @STAGE_NUM
	.comm	_AD714X_STAGECFG_REG,4,2        ## @AD714X_STAGECFG_REG
	.comm	_STAGE_CFGREG_NUM,4,2           ## @STAGE_CFGREG_NUM
	.comm	_SYS_CFGREG_NUM,4,2             ## @SYS_CFGREG_NUM
	.comm	_AD714X_SYSCFG_REG,4,2          ## @AD714X_SYSCFG_REG
	.comm	_AD714X_STG_CAL_EN_REG,4,2      ## @AD714X_STG_CAL_EN_REG
	.comm	_STG_LOW_INT_STA_REG,4,2        ## @STG_LOW_INT_STA_REG
	.no_dead_strip	_ad714x_hw_init
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function ad714x_hw_init
_ad714x_hw_init:                        ; @ad714x_hw_init
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #96
	.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
	mov	x19, x0
Lloh0:
	adrp	x20, _STAGE_NUM@GOTPAGE
Lloh1:
	ldr	x20, [x20, _STAGE_NUM@GOTPAGEOFF]
	ldr	w9, [x20]
	cmp	w9, #1
	b.lt	LBB0_7
; %bb.1:
	mov	x21, #0
Lloh2:
	adrp	x22, _STAGE_CFGREG_NUM@GOTPAGE
Lloh3:
	ldr	x22, [x22, _STAGE_CFGREG_NUM@GOTPAGEOFF]
	ldr	w8, [x22]
Lloh4:
	adrp	x23, _AD714X_STAGECFG_REG@GOTPAGE
Lloh5:
	ldr	x23, [x23, _AD714X_STAGECFG_REG@GOTPAGEOFF]
	b	LBB0_3
LBB0_2:                                 ;   in Loop: Header=BB0_3 Depth=1
	add	x21, x21, #1
	cmp	x21, w9, sxtw
	b.ge	LBB0_7
LBB0_3:                                 ; =>This Loop Header: Depth=1
                                        ;     Child Loop BB0_5 Depth 2
	cmp	w8, #1
	b.lt	LBB0_2
; %bb.4:                                ;   in Loop: Header=BB0_3 Depth=1
	mov	x24, #0
	ldrh	w9, [x23]
	madd	w8, w21, w8, w9
	and	x25, x8, #0xffff
LBB0_5:                                 ;   Parent Loop BB0_3 Depth=1
                                        ; =>  This Inner Loop Header: Depth=2
	ldp	x8, x9, [x19, #16]
	ldr	x9, [x9]
	ldr	x9, [x9, x21, lsl #3]
	ldr	w2, [x9, x24, lsl #2]
	add	w1, w25, w24
	mov	x0, x19
	blr	x8
	add	x24, x24, #1
	ldrsw	x8, [x22]
	cmp	x24, x8
	b.lt	LBB0_5
; %bb.6:                                ;   in Loop: Header=BB0_3 Depth=1
	ldr	w9, [x20]
	b	LBB0_2
LBB0_7:
Lloh6:
	adrp	x20, _SYS_CFGREG_NUM@GOTPAGE
Lloh7:
	ldr	x20, [x20, _SYS_CFGREG_NUM@GOTPAGEOFF]
	ldr	w8, [x20]
	cmp	w8, #1
	b.lt	LBB0_13
; %bb.8:
	mov	x22, #0
Lloh8:
	adrp	x21, _AD714X_SYSCFG_REG@GOTPAGE
Lloh9:
	ldr	x21, [x21, _AD714X_SYSCFG_REG@GOTPAGEOFF]
LBB0_9:                                 ; =>This Inner Loop Header: Depth=1
	ldr	w8, [x21]
	add	w1, w22, w8
	ldp	x8, x9, [x19, #16]
	ldr	x9, [x9, #8]
	ldr	w2, [x9, x22, lsl #2]
	mov	x0, x19
	blr	x8
	add	x22, x22, #1
	ldrsw	x8, [x20]
	cmp	x22, x8
	b.lt	LBB0_9
; %bb.10:
	cmp	w8, #1
	b.lt	LBB0_13
; %bb.11:
	mov	w22, #0
LBB0_12:                                ; =>This Inner Loop Header: Depth=1
	ldr	x8, [x19, #8]
	ldr	w9, [x21]
	add	w1, w22, w9
	add	x2, sp, #14
	mov	x0, x19
	mov	w3, #1
	blr	x8
	add	w22, w22, #1
	ldr	w8, [x20]
	cmp	w22, w8
	b.lt	LBB0_12
LBB0_13:
	ldr	x8, [x19, #16]
Lloh10:
	adrp	x9, _AD714X_STG_CAL_EN_REG@GOTPAGE
Lloh11:
	ldr	x9, [x9, _AD714X_STG_CAL_EN_REG@GOTPAGEOFF]
Lloh12:
	ldr	w1, [x9]
	mov	x0, x19
	mov	w2, #4095
	blr	x8
	ldr	x8, [x19, #8]
Lloh13:
	adrp	x9, _STG_LOW_INT_STA_REG@GOTPAGE
Lloh14:
	ldr	x9, [x9, _STG_LOW_INT_STA_REG@GOTPAGEOFF]
Lloh15:
	ldr	w1, [x9]
	mov	x0, x19
	mov	x2, x19
	mov	w3, #3
	blr	x8
	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
	add	sp, sp, #96
	ret
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh4, Lloh5
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh8, Lloh9
	.loh AdrpLdrGotLdr	Lloh13, Lloh14, Lloh15
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh12
	.cfi_endproc
                                        ; -- End function
	.comm	_STAGE_NUM,4,2                  ; @STAGE_NUM
	.comm	_AD714X_STAGECFG_REG,4,2        ; @AD714X_STAGECFG_REG
	.comm	_STAGE_CFGREG_NUM,4,2           ; @STAGE_CFGREG_NUM
	.comm	_SYS_CFGREG_NUM,4,2             ; @SYS_CFGREG_NUM
	.comm	_AD714X_SYSCFG_REG,4,2          ; @AD714X_SYSCFG_REG
	.comm	_AD714X_STG_CAL_EN_REG,4,2      ; @AD714X_STG_CAL_EN_REG
	.comm	_STG_LOW_INT_STA_REG,4,2        ; @STG_LOW_INT_STA_REG
	.no_dead_strip	_ad714x_hw_init
.subsections_via_symbols
