	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function steam_remove
_steam_remove:                          ## @steam_remove
	.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
	callq	_hid_get_drvdata
	testq	%rax, %rax
	je	LBB0_5
## %bb.1:
	movq	%rax, %r14
	movq	(%rbx), %rax
	movq	_HID_GROUP_STEAM@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_2
LBB0_5:
	movq	%rbx, %rdi
	popq	%rbx
	popq	%r14
	popq	%rbp
	jmp	_hid_hw_stop                    ## TAILCALL
LBB0_2:
	movl	12(%r14), %edi
	callq	_hid_destroy_device
	movl	$0, (%r14)
	movq	%r14, %rdi
	addq	$8, %rdi
	callq	_cancel_work_sync
	movq	_STEAM_QUIRK_WIRELESS@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	testl	%eax, 4(%r14)
	je	LBB0_4
## %bb.3:
	leaq	L_.str(%rip), %rsi
	movq	%rbx, %rdi
	callq	_hid_info
LBB0_4:
	movq	%rbx, %rdi
	callq	_hid_hw_close
	movq	%rbx, %rdi
	callq	_hid_hw_stop
	movq	%r14, %rdi
	popq	%rbx
	popq	%r14
	popq	%rbp
	jmp	_steam_unregister               ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_HID_GROUP_STEAM,8,3            ## @HID_GROUP_STEAM
	.comm	_STEAM_QUIRK_WIRELESS,4,2       ## @STEAM_QUIRK_WIRELESS
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Steam wireless receiver disconnected"

	.no_dead_strip	_steam_remove
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function steam_remove
_steam_remove:                          ; @steam_remove
	.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
	bl	_hid_get_drvdata
	cbz	x0, LBB0_2
; %bb.1:
	ldr	x8, [x19]
Lloh0:
	adrp	x9, _HID_GROUP_STEAM@GOTPAGE
Lloh1:
	ldr	x9, [x9, _HID_GROUP_STEAM@GOTPAGEOFF]
Lloh2:
	ldr	x9, [x9]
	cmp	x8, x9
	b.ne	LBB0_3
LBB0_2:
	mov	x0, x19
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	b	_hid_hw_stop
LBB0_3:
	mov	x20, x0
	ldr	w0, [x0, #12]
	bl	_hid_destroy_device
	str	wzr, [x20]
	add	x0, x20, #8
	bl	_cancel_work_sync
	ldr	w8, [x20, #4]
Lloh3:
	adrp	x9, _STEAM_QUIRK_WIRELESS@GOTPAGE
Lloh4:
	ldr	x9, [x9, _STEAM_QUIRK_WIRELESS@GOTPAGEOFF]
Lloh5:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_5
; %bb.4:
Lloh6:
	adrp	x1, l_.str@PAGE
Lloh7:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x19
	bl	_hid_info
LBB0_5:
	mov	x0, x19
	bl	_hid_hw_close
	mov	x0, x19
	bl	_hid_hw_stop
	mov	x0, x20
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	b	_steam_unregister
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpAdd	Lloh6, Lloh7
	.cfi_endproc
                                        ; -- End function
	.comm	_HID_GROUP_STEAM,8,3            ; @HID_GROUP_STEAM
	.comm	_STEAM_QUIRK_WIRELESS,4,2       ; @STEAM_QUIRK_WIRELESS
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Steam wireless receiver disconnected"

	.no_dead_strip	_steam_remove
.subsections_via_symbols
