	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_goya_armcp_info_get            ## -- Begin function goya_armcp_info_get
	.p2align	4, 0x90
_goya_armcp_info_get:                   ## @goya_armcp_info_get
	.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	%rbx
	pushq	%rax
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	40(%rdi), %rax
	movq	_HW_CAP_CPU_Q@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	testl	%ecx, (%rax)
	je	LBB0_9
## %bb.1:
	movq	%rdi, %rbx
	callq	_hl_fw_armcp_info_get
	testl	%eax, %eax
	jne	LBB0_10
## %bb.2:
	movl	20(%rbx), %edi
	callq	_le64_to_cpu
	testq	%rax, %rax
	je	LBB0_7
## %bb.3:
	movq	%rax, %r14
	movq	%rax, %rdi
	callq	_is_power_of_2
	movq	_DRAM_PHYS_DEFAULT_SIZE@GOTPCREL(%rip), %r15
	testl	%eax, %eax
	je	LBB0_5
## %bb.4:
	cmpq	(%r15), %r14
	jge	LBB0_6
LBB0_5:
	movl	(%rbx), %edi
	leaq	L_.str(%rip), %rsi
	movq	%r14, %rdx
	callq	_dev_err
	movq	(%r15), %r14
LBB0_6:
	movq	%r14, 32(%rbx)
	addq	8(%rbx), %r14
	movq	%r14, 24(%rbx)
LBB0_7:
	movl	16(%rbx), %edi
	callq	_strlen
	testl	%eax, %eax
	jne	LBB0_9
## %bb.8:
	movl	16(%rbx), %edi
	movq	_GOYA_DEFAULT_CARD_NAME@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_CARD_NAME_MAX_LEN@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	callq	_strncpy
LBB0_9:
	xorl	%eax, %eax
LBB0_10:
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_HW_CAP_CPU_Q,4,2               ## @HW_CAP_CPU_Q
	.comm	_DRAM_PHYS_DEFAULT_SIZE,8,3     ## @DRAM_PHYS_DEFAULT_SIZE
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"F/W reported invalid DRAM size %llu. Trying to use default size\n"

	.comm	_GOYA_DEFAULT_CARD_NAME,4,2     ## @GOYA_DEFAULT_CARD_NAME
	.comm	_CARD_NAME_MAX_LEN,4,2          ## @CARD_NAME_MAX_LEN
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_goya_armcp_info_get            ; -- Begin function goya_armcp_info_get
	.p2align	2
_goya_armcp_info_get:                   ; @goya_armcp_info_get
	.cfi_startproc
; %bb.0:
	stp	x22, x21, [sp, #-48]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 48
	stp	x20, x19, [sp, #16]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #32]             ; 16-byte Folded Spill
	add	x29, sp, #32
	.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
	ldr	x8, [x0, #40]
	ldr	w8, [x8]
Lloh0:
	adrp	x9, _HW_CAP_CPU_Q@GOTPAGE
Lloh1:
	ldr	x9, [x9, _HW_CAP_CPU_Q@GOTPAGEOFF]
Lloh2:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_9
; %bb.1:
	mov	x19, x0
	bl	_hl_fw_armcp_info_get
	cbnz	w0, LBB0_10
; %bb.2:
	ldr	w0, [x19, #20]
	bl	_le64_to_cpu
	cbz	x0, LBB0_7
; %bb.3:
	mov	x20, x0
	bl	_is_power_of_2
Lloh3:
	adrp	x21, _DRAM_PHYS_DEFAULT_SIZE@GOTPAGE
Lloh4:
	ldr	x21, [x21, _DRAM_PHYS_DEFAULT_SIZE@GOTPAGEOFF]
	cbz	w0, LBB0_5
; %bb.4:
	ldr	x8, [x21]
	cmp	x20, x8
	b.ge	LBB0_6
LBB0_5:
	ldr	w0, [x19]
Lloh5:
	adrp	x1, l_.str@PAGE
Lloh6:
	add	x1, x1, l_.str@PAGEOFF
	mov	x2, x20
	bl	_dev_err
	ldr	x20, [x21]
LBB0_6:
	ldr	x8, [x19, #8]
	add	x8, x8, x20
	stp	x8, x20, [x19, #24]
LBB0_7:
	ldr	w0, [x19, #16]
	bl	_strlen
	cbnz	w0, LBB0_9
; %bb.8:
	ldr	w0, [x19, #16]
Lloh7:
	adrp	x8, _GOYA_DEFAULT_CARD_NAME@GOTPAGE
Lloh8:
	ldr	x8, [x8, _GOYA_DEFAULT_CARD_NAME@GOTPAGEOFF]
Lloh9:
	ldr	w1, [x8]
Lloh10:
	adrp	x8, _CARD_NAME_MAX_LEN@GOTPAGE
Lloh11:
	ldr	x8, [x8, _CARD_NAME_MAX_LEN@GOTPAGEOFF]
Lloh12:
	ldr	w2, [x8]
	bl	_strncpy
LBB0_9:
	mov	w0, #0
LBB0_10:
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp], #48             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpAdd	Lloh5, Lloh6
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh12
	.loh AdrpLdrGotLdr	Lloh7, Lloh8, Lloh9
	.cfi_endproc
                                        ; -- End function
	.comm	_HW_CAP_CPU_Q,4,2               ; @HW_CAP_CPU_Q
	.comm	_DRAM_PHYS_DEFAULT_SIZE,8,3     ; @DRAM_PHYS_DEFAULT_SIZE
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"F/W reported invalid DRAM size %llu. Trying to use default size\n"

	.comm	_GOYA_DEFAULT_CARD_NAME,4,2     ; @GOYA_DEFAULT_CARD_NAME
	.comm	_CARD_NAME_MAX_LEN,4,2          ; @CARD_NAME_MAX_LEN
.subsections_via_symbols
