	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function twl4030_kp_probe
_twl4030_kp_probe:                      ## @twl4030_kp_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	$24, %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	4(%rdi), %r12
	movq	%r12, %rdi
	callq	_dev_get_platdata
	movq	%rax, %rbx
	movq	_GFP_KERNEL@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%r12, %rdi
	movl	$48, %esi
	callq	_devm_kzalloc
	testq	%rax, %rax
	je	LBB0_1
## %bb.2:
	movq	%rax, %r14
	movq	%r12, %rdi
	callq	_devm_input_allocate_device
	testq	%rax, %rax
	je	LBB0_1
## %bb.3:
	movq	%rax, %r13
	movq	%r12, 24(%r14)
	movq	%rax, 40(%r14)
	leaq	L_.str(%rip), %rax
	movq	%rax, (%r13)
	leaq	L_.str.1(%rip), %rax
	movq	%rax, 8(%r13)
	movq	_BUS_HOST@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 32(%r13)
	movabsq	$4294967297, %rax               ## imm = 0x100000001
	movq	%rax, 20(%r13)
	movl	$3, 28(%r13)
	testq	%rbx, %rbx
	je	LBB0_10
## %bb.4:
	movq	(%rbx), %rax
	testq	%rax, %rax
	je	LBB0_7
## %bb.5:
	movq	8(%rbx), %rcx
	testq	%rcx, %rcx
	je	LBB0_7
## %bb.6:
	movq	24(%rbx), %rdx
	testq	%rdx, %rdx
	je	LBB0_7
## %bb.9:
	movq	%rax, (%r14)
	movq	%rcx, 8(%r14)
	movl	16(%rbx), %ecx
	movl	%ecx, 16(%r14)
	jmp	LBB0_12
LBB0_1:
	movq	_ENOMEM@GOTPCREL(%rip), %rax
	jmp	LBB0_28
LBB0_7:
	leaq	L_.str.2(%rip), %rsi
	jmp	LBB0_8
LBB0_10:
	movq	%r14, %rdx
	addq	$8, %rdx
	movq	%r12, %rdi
	movq	%r14, %rsi
	callq	_matrix_keypad_parse_properties
	movl	%eax, %ebx
	testl	%eax, %eax
	jne	LBB0_30
## %bb.11:
	movl	$1, 16(%r14)
	movq	(%r14), %rax
	xorl	%edx, %edx
LBB0_12:
	movq	_TWL4030_MAX_ROWS@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jg	LBB0_14
## %bb.13:
	movq	8(%r14), %rax
	movq	_TWL4030_MAX_COLS@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jle	LBB0_15
LBB0_14:
	leaq	L_.str.3(%rip), %rsi
LBB0_8:
	movq	%r12, %rdi
	callq	_dev_err
	movq	_EINVAL@GOTPCREL(%rip), %rax
LBB0_28:
	xorl	%ebx, %ebx
LBB0_29:
	subl	(%rax), %ebx
LBB0_30:
	movl	%ebx, %eax
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_15:
	movq	%rdx, -48(%rbp)                 ## 8-byte Spill
	xorl	%ebx, %ebx
	movq	%r15, %rdi
	xorl	%esi, %esi
	callq	_platform_get_irq
	movl	%eax, 20(%r14)
	testl	%eax, %eax
	je	LBB0_16
## %bb.17:
	movq	_TWL4030_MAX_ROWS@GOTPCREL(%rip), %rax
	movq	(%rax), %rdx
	movq	_TWL4030_ROW_SHIFT@GOTPCREL(%rip), %rax
	movb	(%rax), %cl
	movl	$1, %eax
	shll	%cl, %eax
	movl	32(%r14), %r8d
	movq	-48(%rbp), %rdi                 ## 8-byte Reload
	xorl	%esi, %esi
	movl	%eax, %ecx
	movq	%r13, %r9
	callq	_matrix_keypad_build_keymap
	testl	%eax, %eax
	je	LBB0_19
## %bb.18:
	movl	%eax, %ebx
	movq	24(%r14), %rdi
	leaq	L_.str.5(%rip), %rsi
	callq	_dev_err
	jmp	LBB0_30
LBB0_16:
	leaq	L_.str.4(%rip), %rsi
	movq	%r12, %rdi
	callq	_dev_err
	movq	_EINVAL@GOTPCREL(%rip), %rax
	jmp	LBB0_29
LBB0_19:
	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
	cmpl	$0, 16(%r14)
	je	LBB0_21
## %bb.20:
	movq	_EV_REP@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movl	16(%r13), %esi
	callq	___set_bit
LBB0_21:
	movq	%r13, %rdi
	callq	_input_register_device
	testl	%eax, %eax
	je	LBB0_23
## %bb.22:
	movl	%eax, %ebx
	movq	24(%r14), %rdi
	leaq	L_.str.6(%rip), %rsi
	callq	_dev_err
	jmp	LBB0_30
LBB0_23:
	movq	%r14, %rdi
	callq	_twl4030_kp_program
	movl	%eax, %ebx
	testl	%eax, %eax
	jne	LBB0_30
## %bb.24:
	movl	20(%r14), %esi
	movq	_do_kp_irq@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	movl	(%r15), %r9d
	movq	%r14, (%rsp)
	xorl	%ebx, %ebx
	movq	%r12, %rdi
	xorl	%edx, %edx
	xorl	%r8d, %r8d
	callq	_devm_request_threaded_irq
	testl	%eax, %eax
	je	LBB0_26
## %bb.25:
	movl	%eax, %r15d
	movq	24(%r14), %rdi
	movl	20(%r14), %edx
	leaq	L_.str.7(%rip), %rsi
	movl	%eax, %ecx
	callq	_dev_info
	movl	%r15d, %ebx
	jmp	LBB0_30
LBB0_26:
	movq	_KEYP_IMR1_KP@GOTPCREL(%rip), %rax
	movq	_KEYP_IMR1_TO@GOTPCREL(%rip), %rcx
	movl	(%rcx), %esi
	orl	(%rax), %esi
	notl	%esi
	movq	_KEYP_IMR1@GOTPCREL(%rip), %r15
	movl	(%r15), %edx
	movq	%r14, %rdi
	callq	_twl4030_kpwrite_u8
	testq	%rax, %rax
	je	LBB0_30
## %bb.27:
	movl	(%r15), %edx
	movq	%r14, %rdi
	movl	$255, %esi
	callq	_twl4030_kpwrite_u8
	movq	_EIO@GOTPCREL(%rip), %rax
	jmp	LBB0_28
	.cfi_endproc
                                        ## -- End function
	.comm	_GFP_KERNEL,4,2                 ## @GFP_KERNEL
	.comm	_ENOMEM,4,2                     ## @ENOMEM
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"TWL4030 Keypad"

L_.str.1:                               ## @.str.1
	.asciz	"twl4030_keypad/input0"

	.comm	_BUS_HOST,4,2                   ## @BUS_HOST
L_.str.2:                               ## @.str.2
	.asciz	"Missing platform_data\n"

	.comm	_EINVAL,4,2                     ## @EINVAL
	.comm	_TWL4030_MAX_ROWS,8,3           ## @TWL4030_MAX_ROWS
	.comm	_TWL4030_MAX_COLS,8,3           ## @TWL4030_MAX_COLS
L_.str.3:                               ## @.str.3
	.asciz	"Invalid rows/cols amount specified in platform/devicetree data\n"

L_.str.4:                               ## @.str.4
	.asciz	"no keyboard irq assigned\n"

	.comm	_TWL4030_ROW_SHIFT,4,2          ## @TWL4030_ROW_SHIFT
L_.str.5:                               ## @.str.5
	.asciz	"Failed to build keymap\n"

	.comm	_EV_MSC,4,2                     ## @EV_MSC
	.comm	_MSC_SCAN,4,2                   ## @MSC_SCAN
	.comm	_EV_REP,4,2                     ## @EV_REP
L_.str.6:                               ## @.str.6
	.asciz	"Unable to register twl4030 keypad device\n"

	.comm	_do_kp_irq,4,2                  ## @do_kp_irq
L_.str.7:                               ## @.str.7
	.asciz	"request_irq failed for irq no=%d: %d\n"

	.comm	_KEYP_IMR1_KP,4,2               ## @KEYP_IMR1_KP
	.comm	_KEYP_IMR1_TO,4,2               ## @KEYP_IMR1_TO
	.comm	_KEYP_IMR1,4,2                  ## @KEYP_IMR1
	.comm	_EIO,4,2                        ## @EIO
	.no_dead_strip	_twl4030_kp_probe
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function twl4030_kp_probe
_twl4030_kp_probe:                      ; @twl4030_kp_probe
	.cfi_startproc
; %bb.0:
	stp	x24, x23, [sp, #-64]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 64
	stp	x22, x21, [sp, #16]             ; 16-byte Folded Spill
	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
	.cfi_offset w21, -40
	.cfi_offset w22, -48
	.cfi_offset w23, -56
	.cfi_offset w24, -64
	mov	x21, x0
	add	x20, x0, #4
	mov	x0, x20
	bl	_dev_get_platdata
	mov	x24, x0
Lloh0:
	adrp	x8, _GFP_KERNEL@GOTPAGE
Lloh1:
	ldr	x8, [x8, _GFP_KERNEL@GOTPAGEOFF]
Lloh2:
	ldr	w2, [x8]
	mov	x0, x20
	mov	w1, #48
	bl	_devm_kzalloc
	cbz	x0, LBB0_7
; %bb.1:
	mov	x19, x0
	mov	x0, x20
	bl	_devm_input_allocate_device
	cbz	x0, LBB0_7
; %bb.2:
	mov	x22, x0
	str	x20, [x19, #24]
	str	x0, [x19, #40]
Lloh3:
	adrp	x8, l_.str@PAGE
Lloh4:
	add	x8, x8, l_.str@PAGEOFF
Lloh5:
	adrp	x9, l_.str.1@PAGE
Lloh6:
	add	x9, x9, l_.str.1@PAGEOFF
	stp	x8, x9, [x0]
Lloh7:
	adrp	x8, _BUS_HOST@GOTPAGE
Lloh8:
	ldr	x8, [x8, _BUS_HOST@GOTPAGEOFF]
Lloh9:
	ldr	w8, [x8]
	movi.2s	v0, #1
	stur	d0, [x0, #20]
	mov	w9, #3
	stp	w9, w8, [x0, #28]
	cbz	x24, LBB0_9
; %bb.3:
	ldr	x8, [x24]
	cbz	x8, LBB0_8
; %bb.4:
	ldr	x9, [x24, #8]
	cbz	x9, LBB0_8
; %bb.5:
	ldr	x23, [x24, #24]
	cbz	x23, LBB0_8
; %bb.6:
	stp	x8, x9, [x19]
	ldr	w9, [x24, #16]
	str	w9, [x19, #16]
	b	LBB0_11
LBB0_7:
Lloh10:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh11:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
	b	LBB0_15
LBB0_8:
Lloh12:
	adrp	x1, l_.str.2@PAGE
Lloh13:
	add	x1, x1, l_.str.2@PAGEOFF
	b	LBB0_14
LBB0_9:
	add	x2, x19, #8
	mov	x0, x20
	mov	x1, x19
	bl	_matrix_keypad_parse_properties
	mov	x23, x0
	cbnz	w0, LBB0_16
; %bb.10:
	mov	x23, #0
	mov	w8, #1
	str	w8, [x19, #16]
	ldr	x8, [x19]
LBB0_11:
Lloh14:
	adrp	x24, _TWL4030_MAX_ROWS@GOTPAGE
Lloh15:
	ldr	x24, [x24, _TWL4030_MAX_ROWS@GOTPAGEOFF]
	ldr	x9, [x24]
	cmp	x8, x9
	b.gt	LBB0_13
; %bb.12:
	ldr	x8, [x19, #8]
Lloh16:
	adrp	x9, _TWL4030_MAX_COLS@GOTPAGE
Lloh17:
	ldr	x9, [x9, _TWL4030_MAX_COLS@GOTPAGEOFF]
Lloh18:
	ldr	x9, [x9]
	cmp	x8, x9
	b.le	LBB0_17
LBB0_13:
Lloh19:
	adrp	x1, l_.str.3@PAGE
Lloh20:
	add	x1, x1, l_.str.3@PAGEOFF
LBB0_14:
	mov	x0, x20
	bl	_dev_err
Lloh21:
	adrp	x8, _EINVAL@GOTPAGE
Lloh22:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
LBB0_15:
	ldr	w8, [x8]
	neg	w23, w8
LBB0_16:
	mov	x0, x23
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp], #64             ; 16-byte Folded Reload
	ret
LBB0_17:
	mov	x0, x21
	mov	w1, #0
	bl	_platform_get_irq
	str	w0, [x19, #20]
	cbz	w0, LBB0_20
; %bb.18:
	ldr	x2, [x24]
Lloh23:
	adrp	x8, _TWL4030_ROW_SHIFT@GOTPAGE
Lloh24:
	ldr	x8, [x8, _TWL4030_ROW_SHIFT@GOTPAGEOFF]
Lloh25:
	ldr	w8, [x8]
	mov	w9, #1
	lsl	w3, w9, w8
	ldr	w4, [x19, #32]
	mov	x0, x23
	mov	x1, #0
	mov	x5, x22
	bl	_matrix_keypad_build_keymap
	cbz	w0, LBB0_21
; %bb.19:
	mov	x23, x0
	ldr	x0, [x19, #24]
Lloh26:
	adrp	x1, l_.str.5@PAGE
Lloh27:
	add	x1, x1, l_.str.5@PAGEOFF
	bl	_dev_err
	b	LBB0_16
LBB0_20:
Lloh28:
	adrp	x1, l_.str.4@PAGE
Lloh29:
	add	x1, x1, l_.str.4@PAGEOFF
	b	LBB0_14
LBB0_21:
Lloh30:
	adrp	x8, _EV_MSC@GOTPAGE
Lloh31:
	ldr	x8, [x8, _EV_MSC@GOTPAGEOFF]
Lloh32:
	ldr	w1, [x8]
Lloh33:
	adrp	x8, _MSC_SCAN@GOTPAGE
Lloh34:
	ldr	x8, [x8, _MSC_SCAN@GOTPAGEOFF]
Lloh35:
	ldr	w2, [x8]
	mov	x0, x22
	bl	_input_set_capability
	ldr	w8, [x19, #16]
	cbz	w8, LBB0_23
; %bb.22:
Lloh36:
	adrp	x8, _EV_REP@GOTPAGE
Lloh37:
	ldr	x8, [x8, _EV_REP@GOTPAGEOFF]
Lloh38:
	ldr	w0, [x8]
	ldr	w1, [x22, #16]
	bl	___set_bit
LBB0_23:
	mov	x0, x22
	bl	_input_register_device
	cbz	w0, LBB0_25
; %bb.24:
	mov	x23, x0
	ldr	x0, [x19, #24]
Lloh39:
	adrp	x1, l_.str.6@PAGE
Lloh40:
	add	x1, x1, l_.str.6@PAGEOFF
	bl	_dev_err
	b	LBB0_16
LBB0_25:
	mov	x0, x19
	bl	_twl4030_kp_program
	mov	x23, x0
	cbnz	w0, LBB0_16
; %bb.26:
	ldr	w1, [x19, #20]
Lloh41:
	adrp	x8, _do_kp_irq@GOTPAGE
Lloh42:
	ldr	x8, [x8, _do_kp_irq@GOTPAGEOFF]
Lloh43:
	ldr	w3, [x8]
	ldr	w5, [x21]
	mov	x0, x20
	mov	x2, #0
	mov	w4, #0
	mov	x6, x19
	bl	_devm_request_threaded_irq
	cbz	w0, LBB0_28
; %bb.27:
	mov	x23, x0
	ldr	x0, [x19, #24]
	ldr	w2, [x19, #20]
Lloh44:
	adrp	x1, l_.str.7@PAGE
Lloh45:
	add	x1, x1, l_.str.7@PAGEOFF
	mov	x3, x23
	bl	_dev_info
	b	LBB0_16
LBB0_28:
Lloh46:
	adrp	x8, _KEYP_IMR1_KP@GOTPAGE
Lloh47:
	ldr	x8, [x8, _KEYP_IMR1_KP@GOTPAGEOFF]
Lloh48:
	ldr	w8, [x8]
Lloh49:
	adrp	x9, _KEYP_IMR1_TO@GOTPAGE
Lloh50:
	ldr	x9, [x9, _KEYP_IMR1_TO@GOTPAGEOFF]
Lloh51:
	ldr	w9, [x9]
	orr	w8, w9, w8
	mvn	w1, w8
Lloh52:
	adrp	x20, _KEYP_IMR1@GOTPAGE
Lloh53:
	ldr	x20, [x20, _KEYP_IMR1@GOTPAGEOFF]
	ldr	w2, [x20]
	mov	x0, x19
	bl	_twl4030_kpwrite_u8
	cbz	x0, LBB0_30
; %bb.29:
	ldr	w2, [x20]
	mov	x0, x19
	mov	w1, #255
	bl	_twl4030_kpwrite_u8
Lloh54:
	adrp	x8, _EIO@GOTPAGE
Lloh55:
	ldr	x8, [x8, _EIO@GOTPAGEOFF]
	b	LBB0_15
LBB0_30:
	mov	w23, #0
	b	LBB0_16
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh7, Lloh8, Lloh9
	.loh AdrpAdd	Lloh5, Lloh6
	.loh AdrpAdd	Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh10, Lloh11
	.loh AdrpAdd	Lloh12, Lloh13
	.loh AdrpLdrGot	Lloh14, Lloh15
	.loh AdrpLdrGotLdr	Lloh16, Lloh17, Lloh18
	.loh AdrpAdd	Lloh19, Lloh20
	.loh AdrpLdrGot	Lloh21, Lloh22
	.loh AdrpLdrGotLdr	Lloh23, Lloh24, Lloh25
	.loh AdrpAdd	Lloh26, Lloh27
	.loh AdrpAdd	Lloh28, Lloh29
	.loh AdrpLdrGotLdr	Lloh33, Lloh34, Lloh35
	.loh AdrpLdrGotLdr	Lloh30, Lloh31, Lloh32
	.loh AdrpLdrGotLdr	Lloh36, Lloh37, Lloh38
	.loh AdrpAdd	Lloh39, Lloh40
	.loh AdrpLdrGotLdr	Lloh41, Lloh42, Lloh43
	.loh AdrpAdd	Lloh44, Lloh45
	.loh AdrpLdrGot	Lloh52, Lloh53
	.loh AdrpLdrGotLdr	Lloh49, Lloh50, Lloh51
	.loh AdrpLdrGotLdr	Lloh46, Lloh47, Lloh48
	.loh AdrpLdrGot	Lloh54, Lloh55
	.cfi_endproc
                                        ; -- End function
	.comm	_GFP_KERNEL,4,2                 ; @GFP_KERNEL
	.comm	_ENOMEM,4,2                     ; @ENOMEM
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"TWL4030 Keypad"

l_.str.1:                               ; @.str.1
	.asciz	"twl4030_keypad/input0"

	.comm	_BUS_HOST,4,2                   ; @BUS_HOST
l_.str.2:                               ; @.str.2
	.asciz	"Missing platform_data\n"

	.comm	_EINVAL,4,2                     ; @EINVAL
	.comm	_TWL4030_MAX_ROWS,8,3           ; @TWL4030_MAX_ROWS
	.comm	_TWL4030_MAX_COLS,8,3           ; @TWL4030_MAX_COLS
l_.str.3:                               ; @.str.3
	.asciz	"Invalid rows/cols amount specified in platform/devicetree data\n"

l_.str.4:                               ; @.str.4
	.asciz	"no keyboard irq assigned\n"

	.comm	_TWL4030_ROW_SHIFT,4,2          ; @TWL4030_ROW_SHIFT
l_.str.5:                               ; @.str.5
	.asciz	"Failed to build keymap\n"

	.comm	_EV_MSC,4,2                     ; @EV_MSC
	.comm	_MSC_SCAN,4,2                   ; @MSC_SCAN
	.comm	_EV_REP,4,2                     ; @EV_REP
l_.str.6:                               ; @.str.6
	.asciz	"Unable to register twl4030 keypad device\n"

	.comm	_do_kp_irq,4,2                  ; @do_kp_irq
l_.str.7:                               ; @.str.7
	.asciz	"request_irq failed for irq no=%d: %d\n"

	.comm	_KEYP_IMR1_KP,4,2               ; @KEYP_IMR1_KP
	.comm	_KEYP_IMR1_TO,4,2               ; @KEYP_IMR1_TO
	.comm	_KEYP_IMR1,4,2                  ; @KEYP_IMR1
	.comm	_EIO,4,2                        ; @EIO
	.no_dead_strip	_twl4030_kp_probe
.subsections_via_symbols
