	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_pvr2_hdw_cpureset_assert       ## -- Begin function pvr2_hdw_cpureset_assert
	.p2align	4, 0x90
_pvr2_hdw_cpureset_assert:              ## @pvr2_hdw_cpureset_assert
	.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
	cmpl	$0, (%rdi)
	je	LBB0_5
## %bb.1:
	movl	%esi, %r14d
	movq	%rdi, %rbx
	movq	_GFP_KERNEL@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	$16, %edi
	callq	_kmalloc
	testq	%rax, %rax
	je	LBB0_6
## %bb.2:
	movq	%rax, %r15
	movq	_PVR2_TRACE_INIT@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	L_.str.1(%rip), %rsi
	movl	%r14d, %edx
	xorl	%eax, %eax
	callq	_pvr2_trace
	testl	%r14d, %r14d
	setne	(%r15)
	movl	(%rbx), %edi
	xorl	%esi, %esi
	callq	_usb_sndctrlpipe
	movl	(%rbx), %edi
	movq	_HZ@GOTPCREL(%rip), %rcx
	movl	(%rcx), %r10d
	subq	$8, %rsp
	movl	%eax, %esi
	movl	$160, %edx
	movl	$64, %ecx
	movl	$58880, %r8d                    ## imm = 0xE600
	xorl	%r9d, %r9d
	pushq	%r10
	pushq	$1
	pushq	%r15
	callq	_usb_control_msg
	addq	$32, %rsp
	testl	%eax, %eax
	jns	LBB0_4
## %bb.3:
	movq	_PVR2_TRACE_ERROR_LEGS@GOTPCREL(%rip), %rcx
	movl	(%rcx), %edi
	leaq	L_.str.2(%rip), %rsi
	movl	%r14d, %edx
	movl	%eax, %ecx
	xorl	%eax, %eax
	callq	_pvr2_trace
	movq	%rbx, %rdi
	callq	_pvr2_hdw_render_useless
LBB0_4:
	movq	%r15, %rdi
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_kfree                          ## TAILCALL
LBB0_5:
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_6:
	movq	_PVR2_TRACE_ERROR_LEGS@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	L_.str(%rip), %rsi
	xorl	%eax, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_pvr2_trace                     ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_GFP_KERNEL,4,2                 ## @GFP_KERNEL
	.comm	_PVR2_TRACE_ERROR_LEGS,4,2      ## @PVR2_TRACE_ERROR_LEGS
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Unable to allocate memory to control CPU reset"

	.comm	_PVR2_TRACE_INIT,4,2            ## @PVR2_TRACE_INIT
L_.str.1:                               ## @.str.1
	.asciz	"cpureset_assert(%d)"

	.comm	_HZ,4,2                         ## @HZ
L_.str.2:                               ## @.str.2
	.asciz	"cpureset_assert(%d) error=%d"

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_pvr2_hdw_cpureset_assert       ; -- Begin function pvr2_hdw_cpureset_assert
	.p2align	2
_pvr2_hdw_cpureset_assert:              ; @pvr2_hdw_cpureset_assert
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #64
	.cfi_def_cfa_offset 64
	stp	x22, x21, [sp, #16]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #32]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #48]             ; 16-byte Folded Spill
	add	x29, sp, #48
	.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
	ldr	w8, [x0]
	cbz	w8, LBB0_5
; %bb.1:
	mov	x21, x1
	mov	x19, x0
Lloh0:
	adrp	x8, _GFP_KERNEL@GOTPAGE
Lloh1:
	ldr	x8, [x8, _GFP_KERNEL@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
	mov	w0, #16
	bl	_kmalloc
	cbz	x0, LBB0_6
; %bb.2:
	mov	x20, x0
Lloh3:
	adrp	x8, _PVR2_TRACE_INIT@GOTPAGE
Lloh4:
	ldr	x8, [x8, _PVR2_TRACE_INIT@GOTPAGEOFF]
Lloh5:
	ldr	w0, [x8]
	str	x21, [sp]
Lloh6:
	adrp	x1, l_.str.1@PAGE
Lloh7:
	add	x1, x1, l_.str.1@PAGEOFF
	bl	_pvr2_trace
	cmp	w21, #0
	cset	w8, ne
	strb	w8, [x20]
	ldr	w0, [x19]
	mov	w1, #0
	bl	_usb_sndctrlpipe
	mov	x1, x0
	ldr	w0, [x19]
Lloh8:
	adrp	x8, _HZ@GOTPAGE
Lloh9:
	ldr	x8, [x8, _HZ@GOTPAGEOFF]
Lloh10:
	ldr	w8, [x8]
	str	w8, [sp]
	mov	w2, #160
	mov	w3, #64
	mov	w4, #58880
	mov	w5, #0
	mov	x6, x20
	mov	w7, #1
	bl	_usb_control_msg
                                        ; kill: def $w0 killed $w0 def $x0
	tbz	w0, #31, LBB0_4
; %bb.3:
Lloh11:
	adrp	x8, _PVR2_TRACE_ERROR_LEGS@GOTPAGE
Lloh12:
	ldr	x8, [x8, _PVR2_TRACE_ERROR_LEGS@GOTPAGEOFF]
Lloh13:
	ldr	w8, [x8]
                                        ; kill: def $w21 killed $w21 killed $x21 def $x21
	stp	x21, x0, [sp]
Lloh14:
	adrp	x1, l_.str.2@PAGE
Lloh15:
	add	x1, x1, l_.str.2@PAGEOFF
	mov	x0, x8
	bl	_pvr2_trace
	mov	x0, x19
	bl	_pvr2_hdw_render_useless
LBB0_4:
	mov	x0, x20
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #64
	b	_kfree
LBB0_5:
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #64
	ret
LBB0_6:
Lloh16:
	adrp	x8, _PVR2_TRACE_ERROR_LEGS@GOTPAGE
Lloh17:
	ldr	x8, [x8, _PVR2_TRACE_ERROR_LEGS@GOTPAGEOFF]
Lloh18:
	ldr	w0, [x8]
Lloh19:
	adrp	x1, l_.str@PAGE
Lloh20:
	add	x1, x1, l_.str@PAGEOFF
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #64
	b	_pvr2_trace
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpAdd	Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpAdd	Lloh14, Lloh15
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpAdd	Lloh19, Lloh20
	.loh AdrpLdrGotLdr	Lloh16, Lloh17, Lloh18
	.cfi_endproc
                                        ; -- End function
	.comm	_GFP_KERNEL,4,2                 ; @GFP_KERNEL
	.comm	_PVR2_TRACE_ERROR_LEGS,4,2      ; @PVR2_TRACE_ERROR_LEGS
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Unable to allocate memory to control CPU reset"

	.comm	_PVR2_TRACE_INIT,4,2            ; @PVR2_TRACE_INIT
l_.str.1:                               ; @.str.1
	.asciz	"cpureset_assert(%d)"

	.comm	_HZ,4,2                         ; @HZ
l_.str.2:                               ; @.str.2
	.asciz	"cpureset_assert(%d) error=%d"

.subsections_via_symbols
