	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_byd_init                       ## -- Begin function byd_init
	.p2align	4, 0x90
_byd_init:                              ## @byd_init
	.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	%r13
	pushq	%r12
	pushq	%rbx
	pushq	%rax
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %rbx
	movq	40(%rdi), %r14
	callq	_psmouse_reset
	testq	%rax, %rax
	jne	LBB0_1
## %bb.3:
	movq	%rbx, %rdi
	callq	_byd_reset_touchpad
	testq	%rax, %rax
	je	LBB0_4
LBB0_1:
	movq	_EIO@GOTPCREL(%rip), %rax
LBB0_2:
	xorl	%r15d, %r15d
	subl	(%rax), %r15d
LBB0_7:
	movl	%r15d, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_4:
	movq	_GFP_KERNEL@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	$16, %edi
	callq	_kzalloc
	testq	%rax, %rax
	je	LBB0_5
## %bb.6:
	movq	%rax, %r12
	movq	%rbx, 8(%rax)
	movq	_byd_clear_touch@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	xorl	%r15d, %r15d
	movq	%r12, %rdi
	xorl	%edx, %edx
	callq	_timer_setup
	movq	%r12, 32(%rbx)
	movq	_byd_disconnect@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 24(%rbx)
	movq	_byd_reconnect@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 20(%rbx)
	movq	_byd_process_byte@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 16(%rbx)
	movl	$4, (%rbx)
	movq	$0, 8(%rbx)
	movq	_INPUT_PROP_POINTER@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movl	12(%r14), %esi
	callq	___set_bit
	movq	_BTN_TOUCH@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movl	8(%r14), %esi
	callq	___set_bit
	movq	_BTN_TOOL_FINGER@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movl	8(%r14), %esi
	callq	___set_bit
	movq	_BTN_LEFT@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movl	8(%r14), %esi
	callq	___set_bit
	movq	_BTN_RIGHT@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movl	8(%r14), %esi
	callq	___set_bit
	movq	_BTN_MIDDLE@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movl	8(%r14), %esi
	callq	___clear_bit
	movq	_EV_ABS@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movl	4(%r14), %esi
	callq	___set_bit
	movq	_ABS_X@GOTPCREL(%rip), %r12
	movl	(%r12), %esi
	movq	_BYD_PAD_WIDTH@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	movq	%r14, %rdi
	xorl	%edx, %edx
	xorl	%r8d, %r8d
	xorl	%r9d, %r9d
	callq	_input_set_abs_params
	movq	_ABS_Y@GOTPCREL(%rip), %r13
	movl	(%r13), %esi
	movq	_BYD_PAD_HEIGHT@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	movq	%r14, %rdi
	xorl	%edx, %edx
	xorl	%r8d, %r8d
	xorl	%r9d, %r9d
	callq	_input_set_abs_params
	movl	(%r12), %esi
	movq	_BYD_PAD_RESOLUTION@GOTPCREL(%rip), %rbx
	movl	(%rbx), %edx
	movq	%r14, %rdi
	callq	_input_abs_set_res
	movl	(%r13), %esi
	movl	(%rbx), %edx
	movq	%r14, %rdi
	callq	_input_abs_set_res
	movq	_EV_REL@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movl	4(%r14), %esi
	callq	___clear_bit
	movq	_REL_X@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movl	(%r14), %esi
	callq	___clear_bit
	movq	_REL_Y@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movl	(%r14), %esi
	callq	___clear_bit
	jmp	LBB0_7
LBB0_5:
	movq	_ENOMEM@GOTPCREL(%rip), %rax
	jmp	LBB0_2
	.cfi_endproc
                                        ## -- End function
	.comm	_EIO,4,2                        ## @EIO
	.comm	_GFP_KERNEL,4,2                 ## @GFP_KERNEL
	.comm	_ENOMEM,4,2                     ## @ENOMEM
	.comm	_byd_clear_touch,4,2            ## @byd_clear_touch
	.comm	_byd_disconnect,4,2             ## @byd_disconnect
	.comm	_byd_reconnect,4,2              ## @byd_reconnect
	.comm	_byd_process_byte,4,2           ## @byd_process_byte
	.comm	_INPUT_PROP_POINTER,4,2         ## @INPUT_PROP_POINTER
	.comm	_BTN_TOUCH,4,2                  ## @BTN_TOUCH
	.comm	_BTN_TOOL_FINGER,4,2            ## @BTN_TOOL_FINGER
	.comm	_BTN_LEFT,4,2                   ## @BTN_LEFT
	.comm	_BTN_RIGHT,4,2                  ## @BTN_RIGHT
	.comm	_BTN_MIDDLE,4,2                 ## @BTN_MIDDLE
	.comm	_EV_ABS,4,2                     ## @EV_ABS
	.comm	_ABS_X,4,2                      ## @ABS_X
	.comm	_BYD_PAD_WIDTH,4,2              ## @BYD_PAD_WIDTH
	.comm	_ABS_Y,4,2                      ## @ABS_Y
	.comm	_BYD_PAD_HEIGHT,4,2             ## @BYD_PAD_HEIGHT
	.comm	_BYD_PAD_RESOLUTION,4,2         ## @BYD_PAD_RESOLUTION
	.comm	_EV_REL,4,2                     ## @EV_REL
	.comm	_REL_X,4,2                      ## @REL_X
	.comm	_REL_Y,4,2                      ## @REL_Y
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_byd_init                       ; -- Begin function byd_init
	.p2align	2
_byd_init:                              ; @byd_init
	.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	x20, x0
	ldr	x19, [x0, #40]
	bl	_psmouse_reset
	cbnz	x0, LBB0_2
; %bb.1:
	mov	x0, x20
	bl	_byd_reset_touchpad
	cbz	x0, LBB0_5
LBB0_2:
Lloh0:
	adrp	x8, _EIO@GOTPAGE
Lloh1:
	ldr	x8, [x8, _EIO@GOTPAGEOFF]
LBB0_3:
	ldr	w8, [x8]
	neg	w0, w8
LBB0_4:
	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_5:
Lloh2:
	adrp	x8, _GFP_KERNEL@GOTPAGE
Lloh3:
	ldr	x8, [x8, _GFP_KERNEL@GOTPAGEOFF]
Lloh4:
	ldr	w1, [x8]
	mov	w0, #16
	bl	_kzalloc
	cbz	x0, LBB0_7
; %bb.6:
	mov	x21, x0
	str	x20, [x0, #8]
Lloh5:
	adrp	x8, _byd_clear_touch@GOTPAGE
Lloh6:
	ldr	x8, [x8, _byd_clear_touch@GOTPAGEOFF]
Lloh7:
	ldr	w1, [x8]
	mov	w2, #0
	bl	_timer_setup
Lloh8:
	adrp	x8, _byd_disconnect@GOTPAGE
Lloh9:
	ldr	x8, [x8, _byd_disconnect@GOTPAGEOFF]
	str	x21, [x20, #32]
Lloh10:
	ldr	w8, [x8]
	str	w8, [x20, #24]
Lloh11:
	adrp	x8, _byd_reconnect@GOTPAGE
Lloh12:
	ldr	x8, [x8, _byd_reconnect@GOTPAGEOFF]
Lloh13:
	ldr	w8, [x8]
Lloh14:
	adrp	x9, _byd_process_byte@GOTPAGE
Lloh15:
	ldr	x9, [x9, _byd_process_byte@GOTPAGEOFF]
Lloh16:
	ldr	w9, [x9]
	stp	w9, w8, [x20, #16]
	mov	w8, #4
	str	w8, [x20]
	str	xzr, [x20, #8]
Lloh17:
	adrp	x8, _INPUT_PROP_POINTER@GOTPAGE
Lloh18:
	ldr	x8, [x8, _INPUT_PROP_POINTER@GOTPAGEOFF]
Lloh19:
	ldr	w0, [x8]
	ldr	w1, [x19, #12]
	bl	___set_bit
Lloh20:
	adrp	x8, _BTN_TOUCH@GOTPAGE
Lloh21:
	ldr	x8, [x8, _BTN_TOUCH@GOTPAGEOFF]
Lloh22:
	ldr	w0, [x8]
	ldr	w1, [x19, #8]
	bl	___set_bit
Lloh23:
	adrp	x8, _BTN_TOOL_FINGER@GOTPAGE
Lloh24:
	ldr	x8, [x8, _BTN_TOOL_FINGER@GOTPAGEOFF]
Lloh25:
	ldr	w0, [x8]
	ldr	w1, [x19, #8]
	bl	___set_bit
Lloh26:
	adrp	x8, _BTN_LEFT@GOTPAGE
Lloh27:
	ldr	x8, [x8, _BTN_LEFT@GOTPAGEOFF]
Lloh28:
	ldr	w0, [x8]
	ldr	w1, [x19, #8]
	bl	___set_bit
Lloh29:
	adrp	x8, _BTN_RIGHT@GOTPAGE
Lloh30:
	ldr	x8, [x8, _BTN_RIGHT@GOTPAGEOFF]
Lloh31:
	ldr	w0, [x8]
	ldr	w1, [x19, #8]
	bl	___set_bit
Lloh32:
	adrp	x8, _BTN_MIDDLE@GOTPAGE
Lloh33:
	ldr	x8, [x8, _BTN_MIDDLE@GOTPAGEOFF]
Lloh34:
	ldr	w0, [x8]
	ldr	w1, [x19, #8]
	bl	___clear_bit
Lloh35:
	adrp	x8, _EV_ABS@GOTPAGE
Lloh36:
	ldr	x8, [x8, _EV_ABS@GOTPAGEOFF]
Lloh37:
	ldr	w0, [x8]
	ldr	w1, [x19, #4]
	bl	___set_bit
Lloh38:
	adrp	x20, _ABS_X@GOTPAGE
Lloh39:
	ldr	x20, [x20, _ABS_X@GOTPAGEOFF]
	ldr	w1, [x20]
Lloh40:
	adrp	x8, _BYD_PAD_WIDTH@GOTPAGE
Lloh41:
	ldr	x8, [x8, _BYD_PAD_WIDTH@GOTPAGEOFF]
Lloh42:
	ldr	w3, [x8]
	mov	x0, x19
	mov	w2, #0
	mov	w4, #0
	mov	w5, #0
	bl	_input_set_abs_params
Lloh43:
	adrp	x21, _ABS_Y@GOTPAGE
Lloh44:
	ldr	x21, [x21, _ABS_Y@GOTPAGEOFF]
	ldr	w1, [x21]
Lloh45:
	adrp	x8, _BYD_PAD_HEIGHT@GOTPAGE
Lloh46:
	ldr	x8, [x8, _BYD_PAD_HEIGHT@GOTPAGEOFF]
Lloh47:
	ldr	w3, [x8]
	mov	x0, x19
	mov	w2, #0
	mov	w4, #0
	mov	w5, #0
	bl	_input_set_abs_params
	ldr	w1, [x20]
Lloh48:
	adrp	x20, _BYD_PAD_RESOLUTION@GOTPAGE
Lloh49:
	ldr	x20, [x20, _BYD_PAD_RESOLUTION@GOTPAGEOFF]
	ldr	w2, [x20]
	mov	x0, x19
	bl	_input_abs_set_res
	ldr	w1, [x21]
	ldr	w2, [x20]
	mov	x0, x19
	bl	_input_abs_set_res
Lloh50:
	adrp	x8, _EV_REL@GOTPAGE
Lloh51:
	ldr	x8, [x8, _EV_REL@GOTPAGEOFF]
Lloh52:
	ldr	w0, [x8]
	ldr	w1, [x19, #4]
	bl	___clear_bit
Lloh53:
	adrp	x8, _REL_X@GOTPAGE
Lloh54:
	ldr	x8, [x8, _REL_X@GOTPAGEOFF]
Lloh55:
	ldr	w0, [x8]
	ldr	w1, [x19]
	bl	___clear_bit
Lloh56:
	adrp	x8, _REL_Y@GOTPAGE
Lloh57:
	ldr	x8, [x8, _REL_Y@GOTPAGEOFF]
Lloh58:
	ldr	w0, [x8]
	ldr	w1, [x19]
	bl	___clear_bit
	mov	w0, #0
	b	LBB0_4
LBB0_7:
Lloh59:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh60:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
	b	LBB0_3
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh56, Lloh57, Lloh58
	.loh AdrpLdrGotLdr	Lloh53, Lloh54, Lloh55
	.loh AdrpLdrGotLdr	Lloh50, Lloh51, Lloh52
	.loh AdrpLdrGot	Lloh48, Lloh49
	.loh AdrpLdrGotLdr	Lloh45, Lloh46, Lloh47
	.loh AdrpLdrGot	Lloh43, Lloh44
	.loh AdrpLdrGotLdr	Lloh40, Lloh41, Lloh42
	.loh AdrpLdrGot	Lloh38, Lloh39
	.loh AdrpLdrGotLdr	Lloh35, Lloh36, Lloh37
	.loh AdrpLdrGotLdr	Lloh32, Lloh33, Lloh34
	.loh AdrpLdrGotLdr	Lloh29, Lloh30, Lloh31
	.loh AdrpLdrGotLdr	Lloh26, Lloh27, Lloh28
	.loh AdrpLdrGotLdr	Lloh23, Lloh24, Lloh25
	.loh AdrpLdrGotLdr	Lloh20, Lloh21, Lloh22
	.loh AdrpLdrGotLdr	Lloh17, Lloh18, Lloh19
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh59, Lloh60
	.cfi_endproc
                                        ; -- End function
	.comm	_EIO,4,2                        ; @EIO
	.comm	_GFP_KERNEL,4,2                 ; @GFP_KERNEL
	.comm	_ENOMEM,4,2                     ; @ENOMEM
	.comm	_byd_clear_touch,4,2            ; @byd_clear_touch
	.comm	_byd_disconnect,4,2             ; @byd_disconnect
	.comm	_byd_reconnect,4,2              ; @byd_reconnect
	.comm	_byd_process_byte,4,2           ; @byd_process_byte
	.comm	_INPUT_PROP_POINTER,4,2         ; @INPUT_PROP_POINTER
	.comm	_BTN_TOUCH,4,2                  ; @BTN_TOUCH
	.comm	_BTN_TOOL_FINGER,4,2            ; @BTN_TOOL_FINGER
	.comm	_BTN_LEFT,4,2                   ; @BTN_LEFT
	.comm	_BTN_RIGHT,4,2                  ; @BTN_RIGHT
	.comm	_BTN_MIDDLE,4,2                 ; @BTN_MIDDLE
	.comm	_EV_ABS,4,2                     ; @EV_ABS
	.comm	_ABS_X,4,2                      ; @ABS_X
	.comm	_BYD_PAD_WIDTH,4,2              ; @BYD_PAD_WIDTH
	.comm	_ABS_Y,4,2                      ; @ABS_Y
	.comm	_BYD_PAD_HEIGHT,4,2             ; @BYD_PAD_HEIGHT
	.comm	_BYD_PAD_RESOLUTION,4,2         ; @BYD_PAD_RESOLUTION
	.comm	_EV_REL,4,2                     ; @EV_REL
	.comm	_REL_X,4,2                      ; @REL_X
	.comm	_REL_Y,4,2                      ; @REL_Y
.subsections_via_symbols
