	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function sony_remove
_sony_remove:                           ## @sony_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, %r14
	callq	_hid_get_drvdata
	movq	%rax, %rbx
	movq	%r14, %rdi
	callq	_hid_hw_close
	movq	_DUALSHOCK4_CONTROLLER_BT@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	testl	%eax, (%rbx)
	je	LBB0_2
## %bb.1:
	movq	8(%rbx), %rdi
	movq	_dev_attr_bt_poll_interval@GOTPCREL(%rip), %rsi
	callq	_device_remove_file
LBB0_2:
	cmpq	$0, 24(%rbx)
	je	LBB0_4
## %bb.3:
	movq	8(%rbx), %rdi
	movq	_dev_attr_firmware_version@GOTPCREL(%rip), %rsi
	callq	_device_remove_file
LBB0_4:
	cmpq	$0, 16(%rbx)
	je	LBB0_6
## %bb.5:
	movq	8(%rbx), %rdi
	movq	_dev_attr_hardware_version@GOTPCREL(%rip), %rsi
	callq	_device_remove_file
LBB0_6:
	movq	%rbx, %rdi
	callq	_sony_cancel_work_sync
	movq	%rbx, %rdi
	callq	_sony_remove_dev_list
	movq	%rbx, %rdi
	callq	_sony_release_device_id
	movq	%r14, %rdi
	popq	%rbx
	popq	%r14
	popq	%rbp
	jmp	_hid_hw_stop                    ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_DUALSHOCK4_CONTROLLER_BT,4,2   ## @DUALSHOCK4_CONTROLLER_BT
	.comm	_dev_attr_bt_poll_interval,4,2  ## @dev_attr_bt_poll_interval
	.comm	_dev_attr_firmware_version,4,2  ## @dev_attr_firmware_version
	.comm	_dev_attr_hardware_version,4,2  ## @dev_attr_hardware_version
	.no_dead_strip	_sony_remove
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function sony_remove
_sony_remove:                           ; @sony_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
	mov	x20, x0
	mov	x0, x19
	bl	_hid_hw_close
	ldr	w8, [x20]
Lloh0:
	adrp	x9, _DUALSHOCK4_CONTROLLER_BT@GOTPAGE
Lloh1:
	ldr	x9, [x9, _DUALSHOCK4_CONTROLLER_BT@GOTPAGEOFF]
Lloh2:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_2
; %bb.1:
	ldr	x0, [x20, #8]
Lloh3:
	adrp	x1, _dev_attr_bt_poll_interval@GOTPAGE
Lloh4:
	ldr	x1, [x1, _dev_attr_bt_poll_interval@GOTPAGEOFF]
	bl	_device_remove_file
LBB0_2:
	ldr	x8, [x20, #24]
	cbz	x8, LBB0_4
; %bb.3:
	ldr	x0, [x20, #8]
Lloh5:
	adrp	x1, _dev_attr_firmware_version@GOTPAGE
Lloh6:
	ldr	x1, [x1, _dev_attr_firmware_version@GOTPAGEOFF]
	bl	_device_remove_file
LBB0_4:
	ldr	x8, [x20, #16]
	cbz	x8, LBB0_6
; %bb.5:
	ldr	x0, [x20, #8]
Lloh7:
	adrp	x1, _dev_attr_hardware_version@GOTPAGE
Lloh8:
	ldr	x1, [x1, _dev_attr_hardware_version@GOTPAGEOFF]
	bl	_device_remove_file
LBB0_6:
	mov	x0, x20
	bl	_sony_cancel_work_sync
	mov	x0, x20
	bl	_sony_remove_dev_list
	mov	x0, x20
	bl	_sony_release_device_id
	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
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpLdrGot	Lloh7, Lloh8
	.cfi_endproc
                                        ; -- End function
	.comm	_DUALSHOCK4_CONTROLLER_BT,4,2   ; @DUALSHOCK4_CONTROLLER_BT
	.comm	_dev_attr_bt_poll_interval,4,2  ; @dev_attr_bt_poll_interval
	.comm	_dev_attr_firmware_version,4,2  ; @dev_attr_firmware_version
	.comm	_dev_attr_hardware_version,4,2  ; @dev_attr_hardware_version
	.no_dead_strip	_sony_remove
.subsections_via_symbols
