	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function hdpvr_disconnect
_hdpvr_disconnect:                      ## @hdpvr_disconnect
	.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
	callq	_usb_get_intfdata
	movl	%eax, %edi
	callq	_to_hdpvr_dev
	movq	%rax, %rbx
	leaq	16(%rax), %r15
	movl	(%rax), %edi
	callq	_video_device_node_name
	leaq	L_.str(%rip), %rsi
	movq	%r15, %rdi
	movl	%eax, %edx
	callq	_v4l2_info
	leaq	8(%rbx), %r14
	movq	%r14, %rdi
	callq	_mutex_lock
	movq	_STATUS_DISCONNECTED@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 28(%rbx)
	leaq	24(%rbx), %rdi
	callq	_wake_up_interruptible
	leaq	20(%rbx), %rdi
	callq	_wake_up_interruptible
	movq	%r14, %rdi
	callq	_mutex_unlock
	movq	%r15, %rdi
	callq	_v4l2_device_disconnect
	movl	$100, %edi
	callq	_msleep
	movl	12(%rbx), %edi
	callq	_flush_workqueue
	movq	%r14, %rdi
	callq	_mutex_lock
	movq	%rbx, %rdi
	callq	_hdpvr_cancel_queue
	movq	%r14, %rdi
	callq	_mutex_unlock
	movl	(%rbx), %edi
	callq	_video_unregister_device
	movq	_dev_nr@GOTPCREL(%rip), %rdi
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_atomic_dec                     ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"device %s disconnected\n"

	.comm	_STATUS_DISCONNECTED,4,2        ## @STATUS_DISCONNECTED
	.comm	_dev_nr,4,2                     ## @dev_nr
	.no_dead_strip	_hdpvr_disconnect
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function hdpvr_disconnect
_hdpvr_disconnect:                      ; @hdpvr_disconnect
	.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
	bl	_usb_get_intfdata
	bl	_to_hdpvr_dev
	mov	x19, x0
	add	x20, x0, #16
	ldr	w0, [x0]
	bl	_video_device_node_name
	mov	x2, x0
Lloh0:
	adrp	x1, l_.str@PAGE
Lloh1:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x20
	bl	_v4l2_info
	add	x21, x19, #8
	mov	x0, x21
	bl	_mutex_lock
Lloh2:
	adrp	x8, _STATUS_DISCONNECTED@GOTPAGE
Lloh3:
	ldr	x8, [x8, _STATUS_DISCONNECTED@GOTPAGEOFF]
Lloh4:
	ldr	w8, [x8]
	str	w8, [x19, #28]
	add	x0, x19, #24
	bl	_wake_up_interruptible
	add	x0, x19, #20
	bl	_wake_up_interruptible
	mov	x0, x21
	bl	_mutex_unlock
	mov	x0, x20
	bl	_v4l2_device_disconnect
	mov	w0, #100
	bl	_msleep
	ldr	w0, [x19, #12]
	bl	_flush_workqueue
	mov	x0, x21
	bl	_mutex_lock
	mov	x0, x19
	bl	_hdpvr_cancel_queue
	mov	x0, x21
	bl	_mutex_unlock
	ldr	w0, [x19]
	bl	_video_unregister_device
Lloh5:
	adrp	x0, _dev_nr@GOTPAGE
Lloh6:
	ldr	x0, [x0, _dev_nr@GOTPAGEOFF]
	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	_atomic_dec
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpAdd	Lloh0, Lloh1
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"device %s disconnected\n"

	.comm	_STATUS_DISCONNECTED,4,2        ; @STATUS_DISCONNECTED
	.comm	_dev_nr,4,2                     ; @dev_nr
	.no_dead_strip	_hdpvr_disconnect
.subsections_via_symbols
