	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_bcma_core_chipcommon_early_init ## -- Begin function bcma_core_chipcommon_early_init
	.p2align	4, 0x90
_bcma_core_chipcommon_early_init:       ## @bcma_core_chipcommon_early_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	%rbx
	pushq	%rax
	.cfi_offset %rbx, -24
	cmpl	$0, (%rdi)
	jne	LBB0_8
## %bb.1:
	movq	%rdi, %rbx
	addq	$32, %rdi
	callq	_spin_lock_init
	movq	16(%rbx), %rax
	cmpl	$11, (%rax)
	jl	LBB0_3
## %bb.2:
	movq	_BCMA_CC_CHIPSTAT@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%rbx, %rdi
	callq	_bcma_cc_read32
	movq	%rax, 24(%rbx)
LBB0_3:
	movq	_BCMA_CC_CAP@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%rbx, %rdi
	callq	_bcma_cc_read32
	movl	%eax, 4(%rbx)
	movq	16(%rbx), %rcx
	cmpl	$35, (%rcx)
	jl	LBB0_5
## %bb.4:
	movq	_BCMA_CC_CAP_EXT@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%rbx, %rdi
	callq	_bcma_cc_read32
	movq	%rax, 8(%rbx)
	movl	4(%rbx), %eax
LBB0_5:
	movq	_BCMA_CC_CAP_PMU@GOTPCREL(%rip), %rcx
	testl	%eax, (%rcx)
	je	LBB0_7
## %bb.6:
	movq	%rbx, %rdi
	callq	_bcma_pmu_early_init
LBB0_7:
	movl	$1, (%rbx)
LBB0_8:
	addq	$8, %rsp
	popq	%rbx
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_BCMA_CC_CHIPSTAT,4,2           ## @BCMA_CC_CHIPSTAT
	.comm	_BCMA_CC_CAP,4,2                ## @BCMA_CC_CAP
	.comm	_BCMA_CC_CAP_EXT,4,2            ## @BCMA_CC_CAP_EXT
	.comm	_BCMA_CC_CAP_PMU,4,2            ## @BCMA_CC_CAP_PMU
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_bcma_core_chipcommon_early_init ; -- Begin function bcma_core_chipcommon_early_init
	.p2align	2
_bcma_core_chipcommon_early_init:       ; @bcma_core_chipcommon_early_init
	.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	w8, [x0]
	cbnz	w8, LBB0_8
; %bb.1:
	mov	x19, x0
	add	x0, x0, #32
	bl	_spin_lock_init
	ldr	x8, [x19, #16]
	ldr	w8, [x8]
	cmp	w8, #11
	b.lt	LBB0_3
; %bb.2:
Lloh0:
	adrp	x8, _BCMA_CC_CHIPSTAT@GOTPAGE
Lloh1:
	ldr	x8, [x8, _BCMA_CC_CHIPSTAT@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
	mov	x0, x19
	bl	_bcma_cc_read32
	str	x0, [x19, #24]
LBB0_3:
Lloh3:
	adrp	x8, _BCMA_CC_CAP@GOTPAGE
Lloh4:
	ldr	x8, [x8, _BCMA_CC_CAP@GOTPAGEOFF]
Lloh5:
	ldr	w1, [x8]
	mov	x0, x19
	bl	_bcma_cc_read32
	str	w0, [x19, #4]
	ldr	x8, [x19, #16]
	ldr	w8, [x8]
	cmp	w8, #35
	b.lt	LBB0_5
; %bb.4:
Lloh6:
	adrp	x8, _BCMA_CC_CAP_EXT@GOTPAGE
Lloh7:
	ldr	x8, [x8, _BCMA_CC_CAP_EXT@GOTPAGEOFF]
Lloh8:
	ldr	w1, [x8]
	mov	x0, x19
	bl	_bcma_cc_read32
	str	x0, [x19, #8]
	ldr	w0, [x19, #4]
LBB0_5:
Lloh9:
	adrp	x8, _BCMA_CC_CAP_PMU@GOTPAGE
Lloh10:
	ldr	x8, [x8, _BCMA_CC_CAP_PMU@GOTPAGEOFF]
Lloh11:
	ldr	w8, [x8]
	tst	w8, w0
	b.eq	LBB0_7
; %bb.6:
	mov	x0, x19
	bl	_bcma_pmu_early_init
LBB0_7:
	mov	w8, #1
	str	w8, [x19]
LBB0_8:
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.cfi_endproc
                                        ; -- End function
	.comm	_BCMA_CC_CHIPSTAT,4,2           ; @BCMA_CC_CHIPSTAT
	.comm	_BCMA_CC_CAP,4,2                ; @BCMA_CC_CAP
	.comm	_BCMA_CC_CAP_EXT,4,2            ; @BCMA_CC_CAP_EXT
	.comm	_BCMA_CC_CAP_PMU,4,2            ; @BCMA_CC_CAP_PMU
.subsections_via_symbols
