	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function ipw2100_adapter_setup
_ipw2100_adapter_setup:                 ## @ipw2100_adapter_setup
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%r14
	pushq	%rbx
	.cfi_offset %rbx, -32
	.cfi_offset %r14, -24
	movq	%rdi, %rbx
	leaq	L_.str(%rip), %rdi
	callq	_IPW_DEBUG_INFO
	movq	%rbx, %rdi
	callq	_ipw2100_disable_adapter
	testl	%eax, %eax
	jne	LBB0_24
## %bb.1:
	movq	%rbx, %rdi
	callq	_ipw2100_read_mac_address
	testl	%eax, %eax
	je	LBB0_3
## %bb.2:
	movq	_EIO@GOTPCREL(%rip), %rcx
	xorl	%eax, %eax
	subl	(%rcx), %eax
	jmp	LBB0_24
LBB0_3:
	movq	%rbx, %rdi
	movl	$1, %esi
	callq	_ipw2100_set_mac_address
	testl	%eax, %eax
	jne	LBB0_24
## %bb.4:
	movq	16(%rbx), %rax
	movq	(%rax), %rsi
	movq	%rbx, %rdi
	movl	$1, %edx
	callq	_ipw2100_set_port_type
	testl	%eax, %eax
	jne	LBB0_24
## %bb.5:
	movq	16(%rbx), %rax
	movq	(%rax), %rax
	movq	_IW_MODE_ADHOC@GOTPCREL(%rip), %r14
	cmpq	(%r14), %rax
	jne	LBB0_7
## %bb.6:
	movl	56(%rbx), %esi
	movq	%rbx, %rdi
	movl	$1, %edx
	callq	_ipw2100_set_channel
	testl	%eax, %eax
	jne	LBB0_24
LBB0_7:
	movq	%rbx, %rdi
	movl	$1, %esi
	callq	_ipw2100_system_config
	testl	%eax, %eax
	jne	LBB0_24
## %bb.8:
	movl	52(%rbx), %esi
	movq	%rbx, %rdi
	movl	$1, %edx
	callq	_ipw2100_set_tx_rates
	testl	%eax, %eax
	jne	LBB0_24
## %bb.9:
	movq	_IPW_POWER_MODE_CAM@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%rbx, %rdi
	callq	_ipw2100_set_power_mode
	testl	%eax, %eax
	jne	LBB0_24
## %bb.10:
	movl	48(%rbx), %esi
	movq	%rbx, %rdi
	callq	_ipw2100_set_rts_threshold
	testl	%eax, %eax
	jne	LBB0_24
## %bb.11:
	movq	_CFG_STATIC_BSSID@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	testl	%eax, (%rbx)
	je	LBB0_12
## %bb.13:
	movq	40(%rbx), %rsi
	jmp	LBB0_14
LBB0_12:
	xorl	%esi, %esi
LBB0_14:
	movq	%rbx, %rdi
	movl	$1, %edx
	callq	_ipw2100_set_mandatory_bssid
	testl	%eax, %eax
	jne	LBB0_24
## %bb.15:
	movq	_CFG_STATIC_ESSID@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	testl	%eax, (%rbx)
	je	LBB0_17
## %bb.16:
	movq	32(%rbx), %rsi
	movl	24(%rbx), %edx
	movq	%rbx, %rdi
	jmp	LBB0_18
LBB0_17:
	movq	%rbx, %rdi
	xorl	%esi, %esi
	xorl	%edx, %edx
LBB0_18:
	movl	$1, %ecx
	callq	_ipw2100_set_essid
	testl	%eax, %eax
	jne	LBB0_24
## %bb.19:
	movq	%rbx, %rdi
	movl	$1, %esi
	callq	_ipw2100_configure_security
	testl	%eax, %eax
	jne	LBB0_24
## %bb.20:
	movq	16(%rbx), %rax
	movq	(%rax), %rax
	cmpq	(%r14), %rax
	jne	LBB0_23
## %bb.21:
	movl	8(%rbx), %esi
	movq	%rbx, %rdi
	movl	$1, %edx
	callq	_ipw2100_set_ibss_beacon_interval
	testl	%eax, %eax
	jne	LBB0_24
## %bb.22:
	movl	4(%rbx), %esi
	movq	%rbx, %rdi
	callq	_ipw2100_set_tx_power
	testl	%eax, %eax
	jne	LBB0_24
LBB0_23:
	leaq	L_.str.1(%rip), %rdi
	callq	_IPW_DEBUG_INFO
	xorl	%eax, %eax
LBB0_24:
	popq	%rbx
	popq	%r14
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"enter\n"

	.comm	_EIO,4,2                        ## @EIO
	.comm	_IW_MODE_ADHOC,8,3              ## @IW_MODE_ADHOC
	.comm	_IPW_POWER_MODE_CAM,4,2         ## @IPW_POWER_MODE_CAM
	.comm	_CFG_STATIC_BSSID,4,2           ## @CFG_STATIC_BSSID
	.comm	_CFG_STATIC_ESSID,4,2           ## @CFG_STATIC_ESSID
L_.str.1:                               ## @.str.1
	.asciz	"exit\n"

	.comm	_IW_MODE_MONITOR,8,3            ## @IW_MODE_MONITOR
	.no_dead_strip	_ipw2100_adapter_setup
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function ipw2100_adapter_setup
_ipw2100_adapter_setup:                 ; @ipw2100_adapter_setup
	.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
	mov	x19, x0
Lloh0:
	adrp	x0, l_.str@PAGE
Lloh1:
	add	x0, x0, l_.str@PAGEOFF
	bl	_IPW_DEBUG_INFO
	mov	x0, x19
	bl	_ipw2100_disable_adapter
	cbnz	w0, LBB0_24
; %bb.1:
	mov	x0, x19
	bl	_ipw2100_read_mac_address
	cbz	w0, LBB0_3
; %bb.2:
Lloh2:
	adrp	x8, _EIO@GOTPAGE
Lloh3:
	ldr	x8, [x8, _EIO@GOTPAGEOFF]
Lloh4:
	ldr	w8, [x8]
	neg	w0, w8
	b	LBB0_24
LBB0_3:
	mov	x0, x19
	mov	w1, #1
	bl	_ipw2100_set_mac_address
	cbnz	w0, LBB0_24
; %bb.4:
	ldr	x8, [x19, #16]
	ldr	x1, [x8]
	mov	x0, x19
	mov	w2, #1
	bl	_ipw2100_set_port_type
	cbnz	w0, LBB0_24
; %bb.5:
	ldr	x8, [x19, #16]
	ldr	x8, [x8]
Lloh5:
	adrp	x20, _IW_MODE_ADHOC@GOTPAGE
Lloh6:
	ldr	x20, [x20, _IW_MODE_ADHOC@GOTPAGEOFF]
	ldr	x9, [x20]
	cmp	x8, x9
	b.ne	LBB0_7
; %bb.6:
	ldr	w1, [x19, #56]
	mov	x0, x19
	mov	w2, #1
	bl	_ipw2100_set_channel
	cbnz	w0, LBB0_24
LBB0_7:
	mov	x0, x19
	mov	w1, #1
	bl	_ipw2100_system_config
	cbnz	w0, LBB0_24
; %bb.8:
	ldr	w1, [x19, #52]
	mov	x0, x19
	mov	w2, #1
	bl	_ipw2100_set_tx_rates
	cbnz	w0, LBB0_24
; %bb.9:
Lloh7:
	adrp	x8, _IPW_POWER_MODE_CAM@GOTPAGE
Lloh8:
	ldr	x8, [x8, _IPW_POWER_MODE_CAM@GOTPAGEOFF]
Lloh9:
	ldr	w1, [x8]
	mov	x0, x19
	bl	_ipw2100_set_power_mode
	cbnz	w0, LBB0_24
; %bb.10:
	ldr	w1, [x19, #48]
	mov	x0, x19
	bl	_ipw2100_set_rts_threshold
	cbnz	w0, LBB0_24
; %bb.11:
	ldr	w8, [x19]
Lloh10:
	adrp	x9, _CFG_STATIC_BSSID@GOTPAGE
Lloh11:
	ldr	x9, [x9, _CFG_STATIC_BSSID@GOTPAGEOFF]
Lloh12:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_13
; %bb.12:
	ldr	x1, [x19, #40]
	b	LBB0_14
LBB0_13:
	mov	x1, #0
LBB0_14:
	mov	x0, x19
	mov	w2, #1
	bl	_ipw2100_set_mandatory_bssid
	cbnz	w0, LBB0_24
; %bb.15:
	ldr	w8, [x19]
Lloh13:
	adrp	x9, _CFG_STATIC_ESSID@GOTPAGE
Lloh14:
	ldr	x9, [x9, _CFG_STATIC_ESSID@GOTPAGEOFF]
Lloh15:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_17
; %bb.16:
	ldr	x1, [x19, #32]
	ldr	w2, [x19, #24]
	mov	x0, x19
	b	LBB0_18
LBB0_17:
	mov	x0, x19
	mov	x1, #0
	mov	w2, #0
LBB0_18:
	mov	w3, #1
	bl	_ipw2100_set_essid
	cbnz	w0, LBB0_24
; %bb.19:
	mov	x0, x19
	mov	w1, #1
	bl	_ipw2100_configure_security
	cbnz	w0, LBB0_24
; %bb.20:
	ldr	x8, [x19, #16]
	ldr	x8, [x8]
	ldr	x9, [x20]
	cmp	x8, x9
	b.ne	LBB0_23
; %bb.21:
	ldr	w1, [x19, #8]
	mov	x0, x19
	mov	w2, #1
	bl	_ipw2100_set_ibss_beacon_interval
	cbnz	w0, LBB0_24
; %bb.22:
	ldr	w1, [x19, #4]
	mov	x0, x19
	bl	_ipw2100_set_tx_power
	cbnz	w0, LBB0_24
LBB0_23:
Lloh16:
	adrp	x0, l_.str.1@PAGE
Lloh17:
	add	x0, x0, l_.str.1@PAGEOFF
	bl	_IPW_DEBUG_INFO
	mov	w0, #0
LBB0_24:
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	ret
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpLdrGotLdr	Lloh7, Lloh8, Lloh9
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh12
	.loh AdrpLdrGotLdr	Lloh13, Lloh14, Lloh15
	.loh AdrpAdd	Lloh16, Lloh17
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"enter\n"

	.comm	_EIO,4,2                        ; @EIO
	.comm	_IW_MODE_ADHOC,8,3              ; @IW_MODE_ADHOC
	.comm	_IPW_POWER_MODE_CAM,4,2         ; @IPW_POWER_MODE_CAM
	.comm	_CFG_STATIC_BSSID,4,2           ; @CFG_STATIC_BSSID
	.comm	_CFG_STATIC_ESSID,4,2           ; @CFG_STATIC_ESSID
l_.str.1:                               ; @.str.1
	.asciz	"exit\n"

	.comm	_IW_MODE_MONITOR,8,3            ; @IW_MODE_MONITOR
	.no_dead_strip	_ipw2100_adapter_setup
.subsections_via_symbols
