	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function _iwl_trans_pcie_stop_device
__iwl_trans_pcie_stop_device:           ## @_iwl_trans_pcie_stop_device
	.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, %rbx
	callq	_IWL_TRANS_GET_PCIE_TRANS
	movq	%rax, %r14
	leaq	4(%rax), %rdi
	callq	_lockdep_assert_held
	cmpl	$0, (%r14)
	je	LBB0_1
## %bb.5:
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_1:
	movl	$1, (%r14)
	movq	%rbx, %rdi
	callq	_iwl_disable_interrupts
	movq	%rbx, %rdi
	callq	_iwl_pcie_disable_ict
	movq	_STATUS_DEVICE_ENABLED@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	%rbx, %rsi
	callq	_test_and_clear_bit
	testq	%rax, %rax
	je	LBB0_4
## %bb.2:
	leaq	L_.str(%rip), %rsi
	movq	%rbx, %rdi
	callq	_IWL_DEBUG_INFO
	movq	%rbx, %rdi
	callq	_iwl_pcie_tx_stop
	movq	%rbx, %rdi
	callq	_iwl_pcie_rx_stop
	movq	16(%rbx), %rax
	cmpl	$0, (%rax)
	jne	LBB0_4
## %bb.3:
	movq	_APMG_CLK_DIS_REG@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_APMG_CLK_VAL_DMA_CLK_RQT@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%rbx, %rdi
	callq	_iwl_write_prph
	movl	$5, %edi
	callq	_udelay
LBB0_4:
	movq	_CSR_GP_CNTRL@GOTPCREL(%rip), %rax
	movl	(%rax), %r15d
	movq	8(%rbx), %rax
	movq	(%rax), %rax
	movl	(%rax), %edi
	callq	_BIT
	movq	%rbx, %rdi
	movl	%r15d, %esi
	movl	%eax, %edx
	callq	_iwl_clear_bit
	movq	%rbx, %rdi
	xorl	%esi, %esi
	callq	_iwl_pcie_apm_stop
	movq	%rbx, %rdi
	callq	_iwl_trans_pcie_sw_reset
	movq	%r14, %rdi
	callq	_iwl_pcie_conf_msix_hw
	movq	%rbx, %rdi
	callq	_iwl_disable_interrupts
	movq	_STATUS_SYNC_HCMD_ACTIVE@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	%rbx, %rsi
	callq	_clear_bit
	movq	_STATUS_INT_ENABLED@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	%rbx, %rsi
	callq	_clear_bit
	movq	_STATUS_TPOWER_PMI@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	%rbx, %rsi
	callq	_clear_bit
	movq	%rbx, %rdi
	callq	_iwl_enable_rfkill_int
	movq	%rbx, %rdi
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_iwl_pcie_prepare_card_hw       ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_STATUS_DEVICE_ENABLED,4,2      ## @STATUS_DEVICE_ENABLED
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"DEVICE_ENABLED bit was set and is now cleared\n"

	.comm	_APMG_CLK_DIS_REG,4,2           ## @APMG_CLK_DIS_REG
	.comm	_APMG_CLK_VAL_DMA_CLK_RQT,4,2   ## @APMG_CLK_VAL_DMA_CLK_RQT
	.comm	_CSR_GP_CNTRL,4,2               ## @CSR_GP_CNTRL
	.comm	_STATUS_SYNC_HCMD_ACTIVE,4,2    ## @STATUS_SYNC_HCMD_ACTIVE
	.comm	_STATUS_INT_ENABLED,4,2         ## @STATUS_INT_ENABLED
	.comm	_STATUS_TPOWER_PMI,4,2          ## @STATUS_TPOWER_PMI
	.no_dead_strip	__iwl_trans_pcie_stop_device
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function _iwl_trans_pcie_stop_device
__iwl_trans_pcie_stop_device:           ; @_iwl_trans_pcie_stop_device
	.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
	bl	_IWL_TRANS_GET_PCIE_TRANS
	mov	x20, x0
	add	x0, x0, #4
	bl	_lockdep_assert_held
	ldr	w8, [x20]
	cbz	w8, LBB0_2
; %bb.1:
	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_2:
	mov	w8, #1
	str	w8, [x20]
	mov	x0, x19
	bl	_iwl_disable_interrupts
	mov	x0, x19
	bl	_iwl_pcie_disable_ict
Lloh0:
	adrp	x8, _STATUS_DEVICE_ENABLED@GOTPAGE
Lloh1:
	ldr	x8, [x8, _STATUS_DEVICE_ENABLED@GOTPAGEOFF]
Lloh2:
	ldr	w0, [x8]
	mov	x1, x19
	bl	_test_and_clear_bit
	cbz	x0, LBB0_5
; %bb.3:
Lloh3:
	adrp	x1, l_.str@PAGE
Lloh4:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x19
	bl	_IWL_DEBUG_INFO
	mov	x0, x19
	bl	_iwl_pcie_tx_stop
	mov	x0, x19
	bl	_iwl_pcie_rx_stop
	ldr	x8, [x19, #16]
	ldr	w8, [x8]
	cbnz	w8, LBB0_5
; %bb.4:
Lloh5:
	adrp	x8, _APMG_CLK_DIS_REG@GOTPAGE
Lloh6:
	ldr	x8, [x8, _APMG_CLK_DIS_REG@GOTPAGEOFF]
Lloh7:
	ldr	w1, [x8]
Lloh8:
	adrp	x8, _APMG_CLK_VAL_DMA_CLK_RQT@GOTPAGE
Lloh9:
	ldr	x8, [x8, _APMG_CLK_VAL_DMA_CLK_RQT@GOTPAGEOFF]
Lloh10:
	ldr	w2, [x8]
	mov	x0, x19
	bl	_iwl_write_prph
	mov	w0, #5
	bl	_udelay
LBB0_5:
Lloh11:
	adrp	x8, _CSR_GP_CNTRL@GOTPAGE
Lloh12:
	ldr	x8, [x8, _CSR_GP_CNTRL@GOTPAGEOFF]
Lloh13:
	ldr	w21, [x8]
	ldr	x8, [x19, #8]
	ldr	x8, [x8]
	ldr	w0, [x8]
	bl	_BIT
	mov	x2, x0
	mov	x0, x19
	mov	x1, x21
	bl	_iwl_clear_bit
	mov	x0, x19
	mov	w1, #0
	bl	_iwl_pcie_apm_stop
	mov	x0, x19
	bl	_iwl_trans_pcie_sw_reset
	mov	x0, x20
	bl	_iwl_pcie_conf_msix_hw
	mov	x0, x19
	bl	_iwl_disable_interrupts
Lloh14:
	adrp	x8, _STATUS_SYNC_HCMD_ACTIVE@GOTPAGE
Lloh15:
	ldr	x8, [x8, _STATUS_SYNC_HCMD_ACTIVE@GOTPAGEOFF]
Lloh16:
	ldr	w0, [x8]
	mov	x1, x19
	bl	_clear_bit
Lloh17:
	adrp	x8, _STATUS_INT_ENABLED@GOTPAGE
Lloh18:
	ldr	x8, [x8, _STATUS_INT_ENABLED@GOTPAGEOFF]
Lloh19:
	ldr	w0, [x8]
	mov	x1, x19
	bl	_clear_bit
Lloh20:
	adrp	x8, _STATUS_TPOWER_PMI@GOTPAGE
Lloh21:
	ldr	x8, [x8, _STATUS_TPOWER_PMI@GOTPAGEOFF]
Lloh22:
	ldr	w0, [x8]
	mov	x1, x19
	bl	_clear_bit
	mov	x0, x19
	bl	_iwl_enable_rfkill_int
	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	_iwl_pcie_prepare_card_hw
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh20, Lloh21, Lloh22
	.loh AdrpLdrGotLdr	Lloh17, Lloh18, Lloh19
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.cfi_endproc
                                        ; -- End function
	.comm	_STATUS_DEVICE_ENABLED,4,2      ; @STATUS_DEVICE_ENABLED
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"DEVICE_ENABLED bit was set and is now cleared\n"

	.comm	_APMG_CLK_DIS_REG,4,2           ; @APMG_CLK_DIS_REG
	.comm	_APMG_CLK_VAL_DMA_CLK_RQT,4,2   ; @APMG_CLK_VAL_DMA_CLK_RQT
	.comm	_CSR_GP_CNTRL,4,2               ; @CSR_GP_CNTRL
	.comm	_STATUS_SYNC_HCMD_ACTIVE,4,2    ; @STATUS_SYNC_HCMD_ACTIVE
	.comm	_STATUS_INT_ENABLED,4,2         ; @STATUS_INT_ENABLED
	.comm	_STATUS_TPOWER_PMI,4,2          ; @STATUS_TPOWER_PMI
	.no_dead_strip	__iwl_trans_pcie_stop_device
.subsections_via_symbols
