	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_carl9170_register              ## -- Begin function carl9170_register
	.p2align	4, 0x90
_carl9170_register:                     ## @carl9170_register
	.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	%rdi, %r15
	movl	40(%rdi), %edi
	callq	_WARN_ON
	testq	%rax, %rax
	je	LBB0_3
## %bb.1:
	movq	_EINVAL@GOTPCREL(%rip), %rax
LBB0_2:
	xorl	%ebx, %ebx
	subl	(%rax), %ebx
LBB0_23:
	movl	%ebx, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_3:
	movl	36(%r15), %edi
	movq	_BITS_PER_LONG@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_roundup
	movq	_GFP_KERNEL@GOTPCREL(%rip), %rcx
	movl	(%rcx), %edx
	movl	%eax, %edi
	movl	$8, %esi
	callq	_kcalloc
	movl	%eax, 40(%r15)
	testl	%eax, %eax
	je	LBB0_4
## %bb.5:
	movq	%r15, %rdi
	callq	_carl9170_read_eeprom
	movl	%eax, %ebx
	testl	%eax, %eax
	jne	LBB0_23
## %bb.6:
	movq	%r15, %rdi
	callq	_carl9170_parse_eeprom
	movl	%eax, %ebx
	testl	%eax, %eax
	jne	LBB0_23
## %bb.7:
	leaq	44(%r15), %r14
	movq	8(%r15), %rax
	movl	(%rax), %esi
	movq	_carl9170_reg_notifier@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%r14, %rdi
	callq	_ath_regd_init
	movl	%eax, %ebx
	testl	%eax, %eax
	jne	LBB0_23
## %bb.8:
	movq	_modparam_noht@GOTPCREL(%rip), %rax
	cmpq	$0, (%rax)
	je	LBB0_10
## %bb.9:
	movq	_carl9170_band_2GHz@GOTPCREL(%rip), %rax
	movl	$0, (%rax)
	movq	_carl9170_band_5GHz@GOTPCREL(%rip), %rax
	movl	$0, (%rax)
LBB0_10:
	movl	32(%r15), %eax
	testl	%eax, %eax
	jle	LBB0_17
## %bb.11:
	movq	24(%r15), %rcx
	cmpl	$1, %eax
	jne	LBB0_13
## %bb.12:
	xorl	%edx, %edx
	jmp	LBB0_15
LBB0_4:
	movq	_ENOMEM@GOTPCREL(%rip), %rax
	jmp	LBB0_2
LBB0_13:
	movl	%eax, %esi
	andl	$-2, %esi
	leaq	24(%rcx), %rdi
	xorl	%edx, %edx
LBB0_14:                                ## =>This Inner Loop Header: Depth=1
	movl	%edx, -24(%rdi)
	movq	$0, -16(%rdi)
	leal	1(%rdx), %ebx
	movl	%ebx, -8(%rdi)
	movq	$0, (%rdi)
	addq	$2, %rdx
	addq	$32, %rdi
	cmpq	%rsi, %rdx
	jne	LBB0_14
LBB0_15:
	testb	$1, %al
	je	LBB0_17
## %bb.16:
	movq	%rdx, %rax
	shlq	$4, %rax
	movl	%edx, (%rcx,%rax)
	movq	$0, 8(%rcx,%rax)
LBB0_17:
	movq	8(%r15), %rdi
	callq	_ieee80211_register_hw
	movl	%eax, %ebx
	testl	%eax, %eax
	jne	LBB0_23
## %bb.18:
	movl	$1, (%r15)
	movq	%r14, %rdi
	callq	_ath_is_world_regd
	testl	%eax, %eax
	jne	LBB0_20
## %bb.19:
	movq	8(%r15), %rax
	movl	(%rax), %edi
	movl	44(%r15), %esi
	callq	_regulatory_hint
LBB0_20:
	movq	%r15, %rdi
	callq	_carl9170_led_init
	testl	%eax, %eax
	je	LBB0_21
## %bb.22:
	movl	%eax, %ebx
	movq	%r15, %rdi
	callq	_carl9170_unregister
	jmp	LBB0_23
LBB0_21:
	movq	8(%r15), %rax
	movq	16(%r15), %rbx
	movl	(%rax), %edi
	callq	_wiphy_name
	leaq	L_.str(%rip), %rsi
	movq	%rbx, %rdi
	movl	%eax, %edx
	callq	_dev_info
	xorl	%ebx, %ebx
	jmp	LBB0_23
	.cfi_endproc
                                        ## -- End function
	.comm	_EINVAL,4,2                     ## @EINVAL
	.comm	_BITS_PER_LONG,4,2              ## @BITS_PER_LONG
	.comm	_GFP_KERNEL,4,2                 ## @GFP_KERNEL
	.comm	_ENOMEM,4,2                     ## @ENOMEM
	.comm	_carl9170_reg_notifier,4,2      ## @carl9170_reg_notifier
	.comm	_modparam_noht,8,3              ## @modparam_noht
	.comm	_carl9170_band_2GHz,4,2         ## @carl9170_band_2GHz
	.comm	_carl9170_band_5GHz,4,2         ## @carl9170_band_5GHz
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Atheros AR9170 is registered as '%s'\n"

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_carl9170_register              ; -- Begin function carl9170_register
	.p2align	2
_carl9170_register:                     ; @carl9170_register
	.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	x19, x0
	ldr	w0, [x0, #40]
	bl	_WARN_ON
	cbz	x0, LBB0_4
; %bb.1:
Lloh0:
	adrp	x8, _EINVAL@GOTPAGE
Lloh1:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
LBB0_2:
	ldr	w8, [x8]
	neg	w21, w8
LBB0_3:
	mov	x0, x21
	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_4:
	ldr	w0, [x19, #36]
Lloh2:
	adrp	x8, _BITS_PER_LONG@GOTPAGE
Lloh3:
	ldr	x8, [x8, _BITS_PER_LONG@GOTPAGEOFF]
Lloh4:
	ldr	w1, [x8]
	bl	_roundup
Lloh5:
	adrp	x8, _GFP_KERNEL@GOTPAGE
Lloh6:
	ldr	x8, [x8, _GFP_KERNEL@GOTPAGEOFF]
Lloh7:
	ldr	w2, [x8]
	mov	w1, #8
	bl	_kcalloc
	str	w0, [x19, #40]
	cbz	w0, LBB0_13
; %bb.5:
	mov	x0, x19
	bl	_carl9170_read_eeprom
	mov	x21, x0
	cbnz	w0, LBB0_3
; %bb.6:
	mov	x0, x19
	bl	_carl9170_parse_eeprom
	mov	x21, x0
	cbnz	w0, LBB0_3
; %bb.7:
	add	x20, x19, #44
	ldr	x8, [x19, #8]
	ldr	w1, [x8]
Lloh8:
	adrp	x8, _carl9170_reg_notifier@GOTPAGE
Lloh9:
	ldr	x8, [x8, _carl9170_reg_notifier@GOTPAGEOFF]
Lloh10:
	ldr	w2, [x8]
	mov	x0, x20
	bl	_ath_regd_init
	mov	x21, x0
	cbnz	w0, LBB0_3
; %bb.8:
Lloh11:
	adrp	x8, _modparam_noht@GOTPAGE
Lloh12:
	ldr	x8, [x8, _modparam_noht@GOTPAGEOFF]
Lloh13:
	ldr	x8, [x8]
	cbz	x8, LBB0_10
; %bb.9:
Lloh14:
	adrp	x8, _carl9170_band_2GHz@GOTPAGE
Lloh15:
	ldr	x8, [x8, _carl9170_band_2GHz@GOTPAGEOFF]
Lloh16:
	str	wzr, [x8]
Lloh17:
	adrp	x8, _carl9170_band_5GHz@GOTPAGE
Lloh18:
	ldr	x8, [x8, _carl9170_band_5GHz@GOTPAGEOFF]
Lloh19:
	str	wzr, [x8]
LBB0_10:
	ldr	w8, [x19, #32]
	cmp	w8, #1
	b.lt	LBB0_19
; %bb.11:
	ldr	x10, [x19, #24]
	cmp	w8, #4
	b.hs	LBB0_14
; %bb.12:
	mov	x9, #0
	b	LBB0_17
LBB0_13:
Lloh20:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh21:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
	b	LBB0_2
LBB0_14:
	mov	x11, #0
	and	x9, x8, #0xfffffffc
	add	x12, x10, #32
LBB0_15:                                ; =>This Inner Loop Header: Depth=1
	add	w13, w11, #1
	stur	w11, [x12, #-32]
	add	w14, w11, #2
	add	w15, w11, #3
	stur	w13, [x12, #-16]
	str	w14, [x12]
	str	w15, [x12, #16]
	stur	xzr, [x12, #-24]
	stur	xzr, [x12, #-8]
	add	x11, x11, #4
	str	xzr, [x12, #8]
	str	xzr, [x12, #24]
	add	x12, x12, #64
	cmp	x9, x11
	b.ne	LBB0_15
; %bb.16:
	cmp	x9, x8
	b.eq	LBB0_19
LBB0_17:
	add	x10, x10, x9, lsl #4
	add	x10, x10, #8
LBB0_18:                                ; =>This Inner Loop Header: Depth=1
	stur	w9, [x10, #-8]
	str	xzr, [x10], #16
	add	x9, x9, #1
	cmp	x8, x9
	b.ne	LBB0_18
LBB0_19:
	ldr	x0, [x19, #8]
	bl	_ieee80211_register_hw
	mov	x21, x0
	cbnz	w0, LBB0_3
; %bb.20:
	mov	w8, #1
	str	w8, [x19]
	mov	x0, x20
	bl	_ath_is_world_regd
	cbnz	w0, LBB0_22
; %bb.21:
	ldr	x8, [x19, #8]
	ldr	w0, [x8]
	ldr	w1, [x19, #44]
	bl	_regulatory_hint
LBB0_22:
	mov	x0, x19
	bl	_carl9170_led_init
	mov	x21, x0
	cbz	w0, LBB0_24
; %bb.23:
	mov	x0, x19
	bl	_carl9170_unregister
	b	LBB0_3
LBB0_24:
	ldp	x8, x20, [x19, #8]
	ldr	w0, [x8]
	bl	_wiphy_name
	mov	x2, x0
Lloh22:
	adrp	x1, l_.str@PAGE
Lloh23:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x20
	bl	_dev_info
	b	LBB0_3
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpLdrGotStr	Lloh17, Lloh18, Lloh19
	.loh AdrpLdrGotStr	Lloh14, Lloh15, Lloh16
	.loh AdrpLdrGot	Lloh20, Lloh21
	.loh AdrpAdd	Lloh22, Lloh23
	.cfi_endproc
                                        ; -- End function
	.comm	_EINVAL,4,2                     ; @EINVAL
	.comm	_BITS_PER_LONG,4,2              ; @BITS_PER_LONG
	.comm	_GFP_KERNEL,4,2                 ; @GFP_KERNEL
	.comm	_ENOMEM,4,2                     ; @ENOMEM
	.comm	_carl9170_reg_notifier,4,2      ; @carl9170_reg_notifier
	.comm	_modparam_noht,8,3              ; @modparam_noht
	.comm	_carl9170_band_2GHz,4,2         ; @carl9170_band_2GHz
	.comm	_carl9170_band_5GHz,4,2         ; @carl9170_band_5GHz
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Atheros AR9170 is registered as '%s'\n"

.subsections_via_symbols
