	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_bcma_core_set_clockmode        ## -- Begin function bcma_core_set_clockmode
	.p2align	4, 0x90
_bcma_core_set_clockmode:               ## @bcma_core_set_clockmode
	.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
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %r15
	movq	8(%rdi), %rax
	movq	_BCMA_CORE_CHIPCOMMON@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	setne	%cl
	movq	_BCMA_CORE_PCIE@GOTPCREL(%rip), %rdx
	cmpq	(%rdx), %rax
	setne	%dl
	andb	%cl, %dl
	movq	_BCMA_CORE_80211@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	movl	%esi, %r14d
	setne	%al
	andb	%dl, %al
	movzbl	%al, %edi
	callq	_WARN_ON
	cmpl	$129, %r14d
	je	LBB0_6
## %bb.1:
	cmpl	$128, %r14d
	jne	LBB0_7
## %bb.2:
	movq	_BCMA_CLKCTLST@GOTPCREL(%rip), %r14
	movl	(%r14), %esi
	movq	_BCMA_CLKCTLST_FORCEHT@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%r15, %rdi
	callq	_bcma_set32
	movl	$64, %edi
	movl	$300, %esi                      ## imm = 0x12C
	callq	_usleep_range
	movl	$1500, %ebx                     ## imm = 0x5DC
	movq	_BCMA_CLKCTLST_HAVEHT@GOTPCREL(%rip), %r12
	.p2align	4, 0x90
LBB0_3:                                 ## =>This Inner Loop Header: Depth=1
	movl	(%r14), %esi
	movq	%r15, %rdi
	callq	_bcma_read32
	testl	%eax, (%r12)
	jne	LBB0_7
## %bb.4:                               ##   in Loop: Header=BB0_3 Depth=1
	movl	$10, %edi
	callq	_udelay
	decl	%ebx
	jne	LBB0_3
## %bb.5:
	movl	(%r15), %edi
	leaq	L_.str(%rip), %rsi
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_bcma_err                       ## TAILCALL
LBB0_7:
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_6:
	movq	_BCMA_CLKCTLST@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_BCMA_CLKCTLST_FORCEHT@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	notl	%edx
	movq	%r15, %rdi
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_bcma_set32                     ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_BCMA_CORE_CHIPCOMMON,8,3       ## @BCMA_CORE_CHIPCOMMON
	.comm	_BCMA_CORE_PCIE,8,3             ## @BCMA_CORE_PCIE
	.comm	_BCMA_CORE_80211,8,3            ## @BCMA_CORE_80211
	.comm	_BCMA_CLKCTLST,4,2              ## @BCMA_CLKCTLST
	.comm	_BCMA_CLKCTLST_FORCEHT,4,2      ## @BCMA_CLKCTLST_FORCEHT
	.comm	_BCMA_CLKCTLST_HAVEHT,4,2       ## @BCMA_CLKCTLST_HAVEHT
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"HT force timeout\n"

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_bcma_core_set_clockmode        ; -- Begin function bcma_core_set_clockmode
	.p2align	2
_bcma_core_set_clockmode:               ; @bcma_core_set_clockmode
	.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
	mov	x20, x1
	mov	x19, x0
Lloh0:
	adrp	x8, _BCMA_CORE_CHIPCOMMON@GOTPAGE
Lloh1:
	ldr	x8, [x8, _BCMA_CORE_CHIPCOMMON@GOTPAGEOFF]
	ldr	x9, [x0, #8]
Lloh2:
	ldr	x8, [x8]
	cmp	x9, x8
Lloh3:
	adrp	x8, _BCMA_CORE_PCIE@GOTPAGE
Lloh4:
	ldr	x8, [x8, _BCMA_CORE_PCIE@GOTPAGEOFF]
Lloh5:
	ldr	x8, [x8]
	ccmp	x9, x8, #4, ne
Lloh6:
	adrp	x8, _BCMA_CORE_80211@GOTPAGE
Lloh7:
	ldr	x8, [x8, _BCMA_CORE_80211@GOTPAGEOFF]
Lloh8:
	ldr	x8, [x8]
	ccmp	x9, x8, #4, ne
	cset	w0, ne
	bl	_WARN_ON
	cmp	w20, #129
	b.eq	LBB0_7
; %bb.1:
	cmp	w20, #128
	b.ne	LBB0_6
; %bb.2:
Lloh9:
	adrp	x20, _BCMA_CLKCTLST@GOTPAGE
Lloh10:
	ldr	x20, [x20, _BCMA_CLKCTLST@GOTPAGEOFF]
	ldr	w1, [x20]
Lloh11:
	adrp	x8, _BCMA_CLKCTLST_FORCEHT@GOTPAGE
Lloh12:
	ldr	x8, [x8, _BCMA_CLKCTLST_FORCEHT@GOTPAGEOFF]
Lloh13:
	ldr	w2, [x8]
	mov	x0, x19
	bl	_bcma_set32
	mov	w0, #64
	mov	w1, #300
	bl	_usleep_range
	mov	w21, #1500
Lloh14:
	adrp	x22, _BCMA_CLKCTLST_HAVEHT@GOTPAGE
Lloh15:
	ldr	x22, [x22, _BCMA_CLKCTLST_HAVEHT@GOTPAGEOFF]
LBB0_3:                                 ; =>This Inner Loop Header: Depth=1
	ldr	w1, [x20]
	mov	x0, x19
	bl	_bcma_read32
	ldr	w8, [x22]
	tst	w8, w0
	b.ne	LBB0_6
; %bb.4:                                ;   in Loop: Header=BB0_3 Depth=1
	mov	w0, #10
	bl	_udelay
	subs	w21, w21, #1
	b.ne	LBB0_3
; %bb.5:
	ldr	w0, [x19]
Lloh16:
	adrp	x1, l_.str@PAGE
Lloh17:
	add	x1, x1, l_.str@PAGEOFF
	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
	b	_bcma_err
LBB0_6:
	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
LBB0_7:
Lloh18:
	adrp	x8, _BCMA_CLKCTLST@GOTPAGE
Lloh19:
	ldr	x8, [x8, _BCMA_CLKCTLST@GOTPAGEOFF]
Lloh20:
	adrp	x9, _BCMA_CLKCTLST_FORCEHT@GOTPAGE
Lloh21:
	ldr	x9, [x9, _BCMA_CLKCTLST_FORCEHT@GOTPAGEOFF]
Lloh22:
	ldr	w1, [x8]
Lloh23:
	ldr	w8, [x9]
	mvn	w2, w8
	mov	x0, x19
	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
	b	_bcma_set32
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh14, Lloh15
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpLdrGot	Lloh9, Lloh10
	.loh AdrpAdd	Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh20, Lloh21, Lloh23
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh22
	.cfi_endproc
                                        ; -- End function
	.comm	_BCMA_CORE_CHIPCOMMON,8,3       ; @BCMA_CORE_CHIPCOMMON
	.comm	_BCMA_CORE_PCIE,8,3             ; @BCMA_CORE_PCIE
	.comm	_BCMA_CORE_80211,8,3            ; @BCMA_CORE_80211
	.comm	_BCMA_CLKCTLST,4,2              ; @BCMA_CLKCTLST
	.comm	_BCMA_CLKCTLST_FORCEHT,4,2      ; @BCMA_CLKCTLST_FORCEHT
	.comm	_BCMA_CLKCTLST_HAVEHT,4,2       ; @BCMA_CLKCTLST_HAVEHT
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"HT force timeout\n"

.subsections_via_symbols
