	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function tca8418_keypad_probe
_tca8418_keypad_probe:                  ## @tca8418_keypad_probe
	.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
	subq	$40, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %r15
	leaq	16(%rdi), %r14
	movq	$0, -56(%rbp)
	movq	$0, -48(%rbp)
	movq	8(%rdi), %rdi
	movq	_I2C_FUNC_SMBUS_BYTE@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_i2c_check_functionality
	testl	%eax, %eax
	je	LBB0_9
## %bb.1:
	leaq	-56(%rbp), %rsi
	leaq	-48(%rbp), %rdx
	movq	%r14, %rdi
	callq	_matrix_keypad_parse_properties
	movl	%eax, %ebx
	testl	%eax, %eax
	jne	LBB0_19
## %bb.2:
	movq	-56(%rbp), %rax
	testq	%rax, %rax
	je	LBB0_10
## %bb.3:
	movq	_TCA8418_MAX_ROWS@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jg	LBB0_10
## %bb.4:
	movq	-48(%rbp), %rdi
	testq	%rdi, %rdi
	je	LBB0_11
## %bb.5:
	movq	_TCA8418_MAX_COLS@GOTPCREL(%rip), %rax
	cmpq	(%rax), %rdi
	jg	LBB0_11
## %bb.6:
	callq	_get_count_order
	movl	%eax, %ebx
	movq	_GFP_KERNEL@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%r14, %rdi
	movl	$24, %esi
	callq	_devm_kzalloc
	testq	%rax, %rax
	je	LBB0_16
## %bb.7:
	movq	%rax, %r12
	movq	%r15, 16(%rax)
	movl	%ebx, (%rax)
	movq	_REG_KEY_LCK_EC@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	-60(%rbp), %rdx
	movq	%r12, %rdi
	callq	_tca8418_read_byte
	testl	%eax, %eax
	je	LBB0_13
## %bb.8:
	movq	_ENODEV@GOTPCREL(%rip), %rax
	jmp	LBB0_17
LBB0_9:
	movq	8(%r15), %rdi
	callq	_dev_driver_string
	leaq	L_.str(%rip), %rsi
	xorl	%ebx, %ebx
	movq	%r14, %rdi
	movl	%eax, %edx
	xorl	%eax, %eax
	callq	_dev_err
	movq	_ENODEV@GOTPCREL(%rip), %rax
	jmp	LBB0_18
LBB0_10:
	leaq	L_.str.1(%rip), %rsi
	jmp	LBB0_12
LBB0_11:
	leaq	L_.str.2(%rip), %rsi
LBB0_12:
	xorl	%ebx, %ebx
	movq	%r14, %rdi
	xorl	%eax, %eax
	callq	_dev_err
	movq	_EINVAL@GOTPCREL(%rip), %rax
	jmp	LBB0_18
LBB0_13:
	movq	%r14, %rdi
	callq	_devm_input_allocate_device
	testq	%rax, %rax
	je	LBB0_16
## %bb.14:
	movq	%rax, %r13
	movq	%rax, 8(%r12)
	movl	4(%r15), %eax
	movl	%eax, 20(%r13)
	movq	_BUS_I2C@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 16(%r13)
	movabsq	$4294967297, %rax               ## imm = 0x100000001
	movq	%rax, 4(%r13)
	movl	$1, 12(%r13)
	movq	-56(%rbp), %rdx
	movq	-48(%rbp), %rcx
	xorl	%edi, %edi
	xorl	%esi, %esi
	xorl	%r8d, %r8d
	movq	%r13, %r9
	callq	_matrix_keypad_build_keymap
	testl	%eax, %eax
	je	LBB0_20
## %bb.15:
	movl	%eax, %ebx
	leaq	L_.str.3(%rip), %rsi
	movq	%r14, %rdi
	xorl	%eax, %eax
	callq	_dev_err
	jmp	LBB0_19
LBB0_16:
	movq	_ENOMEM@GOTPCREL(%rip), %rax
LBB0_17:
	xorl	%ebx, %ebx
LBB0_18:
	subl	(%rax), %ebx
LBB0_19:
	movl	%ebx, %eax
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_20:
	leaq	L_.str.4(%rip), %rsi
	movq	%r14, %rdi
	callq	_device_property_read_bool
	testq	%rax, %rax
	je	LBB0_22
## %bb.21:
	movq	_EV_REP@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movl	(%r13), %esi
	callq	___set_bit
LBB0_22:
	movq	_EV_MSC@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_MSC_SCAN@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%r13, %rdi
	callq	_input_set_capability
	movq	_tca8418_irq_handler@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	movq	_IRQF_SHARED@GOTPCREL(%rip), %rax
	movq	_IRQF_ONESHOT@GOTPCREL(%rip), %rdx
	movl	(%rdx), %r8d
	orl	(%rax), %r8d
	movl	(%r15), %esi
	movl	4(%r15), %r9d
	movq	%r12, (%rsp)
	movq	%r14, %rdi
	xorl	%edx, %edx
	callq	_devm_request_threaded_irq
	testl	%eax, %eax
	je	LBB0_24
## %bb.23:
	movl	%eax, %ebx
	movl	(%r15), %edx
	leaq	L_.str.5(%rip), %rsi
	movq	%r14, %rdi
	movl	%eax, %ecx
	xorl	%eax, %eax
	callq	_dev_err
	jmp	LBB0_19
LBB0_24:
	movq	-56(%rbp), %rsi
	movq	-48(%rbp), %rdx
	movq	%r12, %rdi
	callq	_tca8418_configure
	testl	%eax, %eax
	js	LBB0_27
## %bb.25:
	movq	%r13, %rdi
	callq	_input_register_device
	testl	%eax, %eax
	je	LBB0_28
## %bb.26:
	movl	%eax, %ebx
	leaq	L_.str.6(%rip), %rsi
	movq	%r14, %rdi
	movl	%eax, %edx
	xorl	%eax, %eax
	callq	_dev_err
	jmp	LBB0_19
LBB0_27:
	movl	%eax, %ebx
	jmp	LBB0_19
LBB0_28:
	xorl	%ebx, %ebx
	jmp	LBB0_19
	.cfi_endproc
                                        ## -- End function
	.comm	_I2C_FUNC_SMBUS_BYTE,4,2        ## @I2C_FUNC_SMBUS_BYTE
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"%s adapter not supported\n"

	.comm	_ENODEV,4,2                     ## @ENODEV
	.comm	_TCA8418_MAX_ROWS,8,3           ## @TCA8418_MAX_ROWS
L_.str.1:                               ## @.str.1
	.asciz	"invalid rows\n"

	.comm	_EINVAL,4,2                     ## @EINVAL
	.comm	_TCA8418_MAX_COLS,8,3           ## @TCA8418_MAX_COLS
L_.str.2:                               ## @.str.2
	.asciz	"invalid columns\n"

	.comm	_GFP_KERNEL,4,2                 ## @GFP_KERNEL
	.comm	_ENOMEM,4,2                     ## @ENOMEM
	.comm	_REG_KEY_LCK_EC,4,2             ## @REG_KEY_LCK_EC
	.comm	_BUS_I2C,4,2                    ## @BUS_I2C
L_.str.3:                               ## @.str.3
	.asciz	"Failed to build keymap\n"

L_.str.4:                               ## @.str.4
	.asciz	"keypad,autorepeat"

	.comm	_EV_REP,4,2                     ## @EV_REP
	.comm	_EV_MSC,4,2                     ## @EV_MSC
	.comm	_MSC_SCAN,4,2                   ## @MSC_SCAN
	.comm	_tca8418_irq_handler,4,2        ## @tca8418_irq_handler
	.comm	_IRQF_SHARED,4,2                ## @IRQF_SHARED
	.comm	_IRQF_ONESHOT,4,2               ## @IRQF_ONESHOT
L_.str.5:                               ## @.str.5
	.asciz	"Unable to claim irq %d; error %d\n"

L_.str.6:                               ## @.str.6
	.asciz	"Unable to register input device, error: %d\n"

	.no_dead_strip	_tca8418_keypad_probe
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function tca8418_keypad_probe
_tca8418_keypad_probe:                  ; @tca8418_keypad_probe
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #112
	.cfi_def_cfa_offset 112
	stp	x24, x23, [sp, #48]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #64]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #80]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #96]             ; 16-byte Folded Spill
	add	x29, sp, #96
	.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
	.cfi_offset w23, -56
	.cfi_offset w24, -64
	mov	x20, x0
	add	x19, x0, #16
	stp	xzr, xzr, [sp, #32]
	ldr	x0, [x0, #8]
Lloh0:
	adrp	x8, _I2C_FUNC_SMBUS_BYTE@GOTPAGE
Lloh1:
	ldr	x8, [x8, _I2C_FUNC_SMBUS_BYTE@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
	bl	_i2c_check_functionality
	cbz	w0, LBB0_11
; %bb.1:
	add	x1, sp, #40
	add	x2, sp, #32
	mov	x0, x19
	bl	_matrix_keypad_parse_properties
	mov	x23, x0
	cbnz	w0, LBB0_17
; %bb.2:
	ldr	x8, [sp, #40]
	cbz	x8, LBB0_13
; %bb.3:
Lloh3:
	adrp	x9, _TCA8418_MAX_ROWS@GOTPAGE
Lloh4:
	ldr	x9, [x9, _TCA8418_MAX_ROWS@GOTPAGEOFF]
Lloh5:
	ldr	x9, [x9]
	cmp	x8, x9
	b.gt	LBB0_13
; %bb.4:
	ldr	x0, [sp, #32]
	cbz	x0, LBB0_14
; %bb.5:
Lloh6:
	adrp	x8, _TCA8418_MAX_COLS@GOTPAGE
Lloh7:
	ldr	x8, [x8, _TCA8418_MAX_COLS@GOTPAGEOFF]
Lloh8:
	ldr	x8, [x8]
	cmp	x0, x8
	b.gt	LBB0_14
; %bb.6:
	bl	_get_count_order
	mov	x22, x0
Lloh9:
	adrp	x8, _GFP_KERNEL@GOTPAGE
Lloh10:
	ldr	x8, [x8, _GFP_KERNEL@GOTPAGEOFF]
Lloh11:
	ldr	w2, [x8]
	mov	x0, x19
	mov	w1, #24
	bl	_devm_kzalloc
	cbz	x0, LBB0_18
; %bb.7:
	mov	x21, x0
	str	x20, [x0, #16]
	str	w22, [x0]
Lloh12:
	adrp	x8, _REG_KEY_LCK_EC@GOTPAGE
Lloh13:
	ldr	x8, [x8, _REG_KEY_LCK_EC@GOTPAGEOFF]
Lloh14:
	ldr	w1, [x8]
	add	x2, sp, #28
	bl	_tca8418_read_byte
	cbnz	w0, LBB0_12
; %bb.8:
	mov	x0, x19
	bl	_devm_input_allocate_device
	cbz	x0, LBB0_18
; %bb.9:
	mov	x22, x0
	str	x0, [x21, #8]
	ldr	w8, [x20, #4]
	str	w8, [x0, #20]
Lloh15:
	adrp	x8, _BUS_I2C@GOTPAGE
Lloh16:
	ldr	x8, [x8, _BUS_I2C@GOTPAGEOFF]
Lloh17:
	ldr	w8, [x8]
	movi.2s	v0, #1
	stur	d0, [x0, #4]
	mov	w9, #1
	stp	w9, w8, [x0, #12]
	ldp	x3, x2, [sp, #32]
	mov	x0, #0
	mov	x1, #0
	mov	x4, #0
	mov	x5, x22
	bl	_matrix_keypad_build_keymap
	cbz	w0, LBB0_19
; %bb.10:
	mov	x23, x0
Lloh18:
	adrp	x1, l_.str.3@PAGE
Lloh19:
	add	x1, x1, l_.str.3@PAGEOFF
	b	LBB0_23
LBB0_11:
	ldr	x0, [x20, #8]
	bl	_dev_driver_string
                                        ; kill: def $w0 killed $w0 def $x0
	str	x0, [sp]
Lloh20:
	adrp	x1, l_.str@PAGE
Lloh21:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x19
	bl	_dev_err
LBB0_12:
Lloh22:
	adrp	x8, _ENODEV@GOTPAGE
Lloh23:
	ldr	x8, [x8, _ENODEV@GOTPAGEOFF]
	b	LBB0_16
LBB0_13:
Lloh24:
	adrp	x1, l_.str.1@PAGE
Lloh25:
	add	x1, x1, l_.str.1@PAGEOFF
	b	LBB0_15
LBB0_14:
Lloh26:
	adrp	x1, l_.str.2@PAGE
Lloh27:
	add	x1, x1, l_.str.2@PAGEOFF
LBB0_15:
	mov	x0, x19
	bl	_dev_err
Lloh28:
	adrp	x8, _EINVAL@GOTPAGE
Lloh29:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
LBB0_16:
	ldr	w8, [x8]
	neg	w23, w8
LBB0_17:
	mov	x0, x23
	ldp	x29, x30, [sp, #96]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #80]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #64]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #48]             ; 16-byte Folded Reload
	add	sp, sp, #112
	ret
LBB0_18:
Lloh30:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh31:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
	b	LBB0_16
LBB0_19:
Lloh32:
	adrp	x1, l_.str.4@PAGE
Lloh33:
	add	x1, x1, l_.str.4@PAGEOFF
	mov	x0, x19
	bl	_device_property_read_bool
	cbz	x0, LBB0_21
; %bb.20:
Lloh34:
	adrp	x8, _EV_REP@GOTPAGE
Lloh35:
	ldr	x8, [x8, _EV_REP@GOTPAGEOFF]
Lloh36:
	ldr	w0, [x8]
	ldr	w1, [x22]
	bl	___set_bit
LBB0_21:
Lloh37:
	adrp	x8, _EV_MSC@GOTPAGE
Lloh38:
	ldr	x8, [x8, _EV_MSC@GOTPAGEOFF]
Lloh39:
	ldr	w1, [x8]
Lloh40:
	adrp	x8, _MSC_SCAN@GOTPAGE
Lloh41:
	ldr	x8, [x8, _MSC_SCAN@GOTPAGEOFF]
Lloh42:
	ldr	w2, [x8]
	mov	x0, x22
	bl	_input_set_capability
Lloh43:
	adrp	x8, _tca8418_irq_handler@GOTPAGE
Lloh44:
	ldr	x8, [x8, _tca8418_irq_handler@GOTPAGEOFF]
Lloh45:
	ldr	w3, [x8]
Lloh46:
	adrp	x8, _IRQF_SHARED@GOTPAGE
Lloh47:
	ldr	x8, [x8, _IRQF_SHARED@GOTPAGEOFF]
Lloh48:
	ldr	w8, [x8]
Lloh49:
	adrp	x9, _IRQF_ONESHOT@GOTPAGE
Lloh50:
	ldr	x9, [x9, _IRQF_ONESHOT@GOTPAGEOFF]
Lloh51:
	ldr	w9, [x9]
	orr	w4, w9, w8
	ldp	w1, w5, [x20]
	mov	x0, x19
	mov	x2, #0
	mov	x6, x21
	bl	_devm_request_threaded_irq
	cbz	w0, LBB0_24
; %bb.22:
	mov	x23, x0
	ldr	w8, [x20]
	stp	x8, x23, [sp]
Lloh52:
	adrp	x1, l_.str.5@PAGE
Lloh53:
	add	x1, x1, l_.str.5@PAGEOFF
LBB0_23:
	mov	x0, x19
	bl	_dev_err
	b	LBB0_17
LBB0_24:
	ldp	x2, x1, [sp, #32]
	mov	x0, x21
	bl	_tca8418_configure
	tbnz	w0, #31, LBB0_27
; %bb.25:
	mov	x0, x22
	bl	_input_register_device
	mov	x23, x0
	cbz	w0, LBB0_17
; %bb.26:
	str	x23, [sp]
Lloh54:
	adrp	x1, l_.str.6@PAGE
Lloh55:
	add	x1, x1, l_.str.6@PAGEOFF
	mov	x0, x19
	bl	_dev_err
                                        ; kill: def $w23 killed $w23 killed $x23 def $x23
	b	LBB0_17
LBB0_27:
	mov	x23, x0
	b	LBB0_17
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpAdd	Lloh18, Lloh19
	.loh AdrpAdd	Lloh20, Lloh21
	.loh AdrpLdrGot	Lloh22, Lloh23
	.loh AdrpAdd	Lloh24, Lloh25
	.loh AdrpAdd	Lloh26, Lloh27
	.loh AdrpLdrGot	Lloh28, Lloh29
	.loh AdrpLdrGot	Lloh30, Lloh31
	.loh AdrpAdd	Lloh32, Lloh33
	.loh AdrpLdrGotLdr	Lloh34, Lloh35, Lloh36
	.loh AdrpLdrGotLdr	Lloh49, Lloh50, Lloh51
	.loh AdrpLdrGotLdr	Lloh46, Lloh47, Lloh48
	.loh AdrpLdrGotLdr	Lloh43, Lloh44, Lloh45
	.loh AdrpLdrGotLdr	Lloh40, Lloh41, Lloh42
	.loh AdrpLdrGotLdr	Lloh37, Lloh38, Lloh39
	.loh AdrpAdd	Lloh52, Lloh53
	.loh AdrpAdd	Lloh54, Lloh55
	.cfi_endproc
                                        ; -- End function
	.comm	_I2C_FUNC_SMBUS_BYTE,4,2        ; @I2C_FUNC_SMBUS_BYTE
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"%s adapter not supported\n"

	.comm	_ENODEV,4,2                     ; @ENODEV
	.comm	_TCA8418_MAX_ROWS,8,3           ; @TCA8418_MAX_ROWS
l_.str.1:                               ; @.str.1
	.asciz	"invalid rows\n"

	.comm	_EINVAL,4,2                     ; @EINVAL
	.comm	_TCA8418_MAX_COLS,8,3           ; @TCA8418_MAX_COLS
l_.str.2:                               ; @.str.2
	.asciz	"invalid columns\n"

	.comm	_GFP_KERNEL,4,2                 ; @GFP_KERNEL
	.comm	_ENOMEM,4,2                     ; @ENOMEM
	.comm	_REG_KEY_LCK_EC,4,2             ; @REG_KEY_LCK_EC
	.comm	_BUS_I2C,4,2                    ; @BUS_I2C
l_.str.3:                               ; @.str.3
	.asciz	"Failed to build keymap\n"

l_.str.4:                               ; @.str.4
	.asciz	"keypad,autorepeat"

	.comm	_EV_REP,4,2                     ; @EV_REP
	.comm	_EV_MSC,4,2                     ; @EV_MSC
	.comm	_MSC_SCAN,4,2                   ; @MSC_SCAN
	.comm	_tca8418_irq_handler,4,2        ; @tca8418_irq_handler
	.comm	_IRQF_SHARED,4,2                ; @IRQF_SHARED
	.comm	_IRQF_ONESHOT,4,2               ; @IRQF_ONESHOT
l_.str.5:                               ; @.str.5
	.asciz	"Unable to claim irq %d; error %d\n"

l_.str.6:                               ; @.str.6
	.asciz	"Unable to register input device, error: %d\n"

	.no_dead_strip	_tca8418_keypad_probe
.subsections_via_symbols
