	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function elan_query_device_parameters
_elan_query_device_parameters:          ## @elan_query_device_parameters
	.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
	subq	$32, %rsp
	.cfi_offset %rbx, -32
	.cfi_offset %r14, -24
	movq	%rdi, %rbx
	movq	32(%rdi), %r14
	leaq	L_.str(%rip), %rsi
	movq	%r14, %rdi
	movq	%rbx, %rdx
	callq	_device_property_read_u32
	testq	%rax, %rax
	jne	LBB0_2
## %bb.1:
	leaq	4(%rbx), %rdx
	leaq	L_.str.1(%rip), %rsi
	movq	%r14, %rdi
	callq	_device_property_read_u32
	testq	%rax, %rax
	je	LBB0_3
LBB0_2:
	movq	32(%rbx), %rdi
	movq	40(%rbx), %rax
	leaq	4(%rbx), %rdx
	movq	%rbx, %rsi
	callq	*(%rax)
	testl	%eax, %eax
	jne	LBB0_16
	jmp	LBB0_4
LBB0_3:
	decl	(%rbx)
	decl	4(%rbx)
LBB0_4:
	leaq	L_.str.2(%rip), %rsi
	leaq	-24(%rbp), %rdx
	movq	%r14, %rdi
	callq	_device_property_read_u32
	testq	%rax, %rax
	jne	LBB0_6
## %bb.5:
	leaq	L_.str.3(%rip), %rsi
	leaq	-20(%rbp), %rdx
	movq	%r14, %rdi
	callq	_device_property_read_u32
	testq	%rax, %rax
	je	LBB0_7
LBB0_6:
	movq	32(%rbx), %rdi
	movq	40(%rbx), %rax
	leaq	-24(%rbp), %rsi
	leaq	-20(%rbp), %rdx
	callq	*8(%rax)
	testl	%eax, %eax
	jne	LBB0_16
LBB0_7:
	movl	(%rbx), %eax
	movl	4(%rbx), %ecx
	xorl	%edx, %edx
	divl	-24(%rbp)
	movl	%eax, 8(%rbx)
	movl	%ecx, %eax
	xorl	%edx, %edx
	divl	-20(%rbp)
	movl	%eax, 12(%rbx)
	leaq	L_.str.4(%rip), %rsi
	leaq	-40(%rbp), %rdx
	movq	%r14, %rdi
	callq	_device_property_read_u32
	testq	%rax, %rax
	jne	LBB0_9
## %bb.8:
	leaq	L_.str.5(%rip), %rsi
	leaq	-36(%rbp), %rdx
	movq	%r14, %rdi
	callq	_device_property_read_u32
	testq	%rax, %rax
	je	LBB0_11
LBB0_9:
	movq	32(%rbx), %rdi
	movq	40(%rbx), %rax
	leaq	-32(%rbp), %rsi
	leaq	-28(%rbp), %rdx
	callq	*16(%rax)
	testl	%eax, %eax
	jne	LBB0_16
## %bb.10:
	movl	-32(%rbp), %edi
	callq	_elan_convert_resolution
	movl	%eax, 16(%rbx)
	movl	-28(%rbp), %edi
	callq	_elan_convert_resolution
	jmp	LBB0_12
LBB0_11:
	movl	(%rbx), %eax
	movl	4(%rbx), %ecx
	incl	%eax
	xorl	%edx, %edx
	divl	-40(%rbp)
	movl	%eax, 16(%rbx)
	incl	%ecx
	movl	%ecx, %eax
	xorl	%edx, %edx
	divl	-36(%rbp)
                                        ## kill: def $eax killed $eax def $rax
LBB0_12:
	movl	%eax, 20(%rbx)
	leaq	L_.str.6(%rip), %rsi
	movq	%r14, %rdi
	callq	_device_property_read_bool
	testq	%rax, %rax
	je	LBB0_14
## %bb.13:
	movl	$1, 24(%rbx)
LBB0_14:
	leaq	L_.str.7(%rip), %rsi
	movq	%r14, %rdi
	callq	_device_property_read_bool
	movq	%rax, %rcx
	xorl	%eax, %eax
	testq	%rcx, %rcx
	je	LBB0_16
## %bb.15:
	movl	$1, 28(%rbx)
LBB0_16:
	addq	$32, %rsp
	popq	%rbx
	popq	%r14
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"touchscreen-size-x"

L_.str.1:                               ## @.str.1
	.asciz	"touchscreen-size-y"

L_.str.2:                               ## @.str.2
	.asciz	"elan,x_traces"

L_.str.3:                               ## @.str.3
	.asciz	"elan,y_traces"

L_.str.4:                               ## @.str.4
	.asciz	"touchscreen-x-mm"

L_.str.5:                               ## @.str.5
	.asciz	"touchscreen-y-mm"

L_.str.6:                               ## @.str.6
	.asciz	"elan,clickpad"

L_.str.7:                               ## @.str.7
	.asciz	"elan,middle-button"

	.no_dead_strip	_elan_query_device_parameters
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function elan_query_device_parameters
_elan_query_device_parameters:          ; @elan_query_device_parameters
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #64
	.cfi_def_cfa_offset 64
	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
	mov	x19, x0
	ldr	x20, [x0, #32]
Lloh0:
	adrp	x1, l_.str@PAGE
Lloh1:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x20
	mov	x2, x19
	bl	_device_property_read_u32
	cbnz	x0, LBB0_2
; %bb.1:
	add	x2, x19, #4
Lloh2:
	adrp	x1, l_.str.1@PAGE
Lloh3:
	add	x1, x1, l_.str.1@PAGEOFF
	mov	x0, x20
	bl	_device_property_read_u32
	cbz	x0, LBB0_3
LBB0_2:
	ldp	x0, x8, [x19, #32]
	ldr	x8, [x8]
	add	x2, x19, #4
	mov	x1, x19
	blr	x8
	cbnz	w0, LBB0_16
	b	LBB0_4
LBB0_3:
	ldr	d0, [x19]
	movi.2d	v1, #0xffffffffffffffff
	add.2s	v0, v0, v1
	str	d0, [x19]
LBB0_4:
Lloh4:
	adrp	x1, l_.str.2@PAGE
Lloh5:
	add	x1, x1, l_.str.2@PAGEOFF
	sub	x2, x29, #20
	mov	x0, x20
	bl	_device_property_read_u32
	cbnz	x0, LBB0_6
; %bb.5:
Lloh6:
	adrp	x1, l_.str.3@PAGE
Lloh7:
	add	x1, x1, l_.str.3@PAGEOFF
	add	x2, sp, #24
	mov	x0, x20
	bl	_device_property_read_u32
	cbz	x0, LBB0_7
LBB0_6:
	ldp	x0, x8, [x19, #32]
	ldr	x8, [x8, #8]
	sub	x1, x29, #20
	add	x2, sp, #24
	blr	x8
	cbnz	w0, LBB0_16
LBB0_7:
	ldur	w8, [x29, #-20]
	ldp	w9, w10, [x19]
	udiv	w8, w9, w8
	ldr	w9, [sp, #24]
	udiv	w9, w10, w9
	stp	w8, w9, [x19, #8]
Lloh8:
	adrp	x1, l_.str.4@PAGE
Lloh9:
	add	x1, x1, l_.str.4@PAGEOFF
	add	x2, sp, #20
	mov	x0, x20
	bl	_device_property_read_u32
	cbnz	x0, LBB0_9
; %bb.8:
Lloh10:
	adrp	x1, l_.str.5@PAGE
Lloh11:
	add	x1, x1, l_.str.5@PAGEOFF
	add	x2, sp, #16
	mov	x0, x20
	bl	_device_property_read_u32
	cbz	x0, LBB0_11
LBB0_9:
	ldp	x0, x8, [x19, #32]
	ldr	x8, [x8, #16]
	add	x1, sp, #12
	add	x2, sp, #8
	blr	x8
	cbnz	w0, LBB0_16
; %bb.10:
	ldr	w0, [sp, #12]
	bl	_elan_convert_resolution
	str	w0, [x19, #16]
	ldr	w0, [sp, #8]
	bl	_elan_convert_resolution
	b	LBB0_12
LBB0_11:
	ldp	w8, w9, [x19]
	add	w8, w8, #1
	ldr	w10, [sp, #20]
	udiv	w8, w8, w10
	str	w8, [x19, #16]
	add	w8, w9, #1
	ldr	w9, [sp, #16]
	udiv	w0, w8, w9
LBB0_12:
	str	w0, [x19, #20]
Lloh12:
	adrp	x1, l_.str.6@PAGE
Lloh13:
	add	x1, x1, l_.str.6@PAGEOFF
	mov	x0, x20
	bl	_device_property_read_bool
	cbz	x0, LBB0_14
; %bb.13:
	mov	w8, #1
	str	w8, [x19, #24]
LBB0_14:
Lloh14:
	adrp	x1, l_.str.7@PAGE
Lloh15:
	add	x1, x1, l_.str.7@PAGEOFF
	mov	x0, x20
	bl	_device_property_read_bool
	cbz	x0, LBB0_16
; %bb.15:
	mov	w0, #0
	mov	w8, #1
	str	w8, [x19, #28]
LBB0_16:
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	add	sp, sp, #64
	ret
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpAdd	Lloh2, Lloh3
	.loh AdrpAdd	Lloh4, Lloh5
	.loh AdrpAdd	Lloh6, Lloh7
	.loh AdrpAdd	Lloh8, Lloh9
	.loh AdrpAdd	Lloh10, Lloh11
	.loh AdrpAdd	Lloh12, Lloh13
	.loh AdrpAdd	Lloh14, Lloh15
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"touchscreen-size-x"

l_.str.1:                               ; @.str.1
	.asciz	"touchscreen-size-y"

l_.str.2:                               ; @.str.2
	.asciz	"elan,x_traces"

l_.str.3:                               ; @.str.3
	.asciz	"elan,y_traces"

l_.str.4:                               ; @.str.4
	.asciz	"touchscreen-x-mm"

l_.str.5:                               ; @.str.5
	.asciz	"touchscreen-y-mm"

l_.str.6:                               ; @.str.6
	.asciz	"elan,clickpad"

l_.str.7:                               ; @.str.7
	.asciz	"elan,middle-button"

	.no_dead_strip	_elan_query_device_parameters
.subsections_via_symbols
