	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function au0828_get_key_au8522
_au0828_get_key_au8522:                 ## @au0828_get_key_au8522
	.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	$72, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %rbx
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -48(%rbp)
	movq	$0, -104(%rbp)
	movq	_DEV_DISCONNECTED@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	8(%rbx), %rsi
	callq	_test_bit
	xorl	%r14d, %r14d
	testq	%rax, %rax
	jne	LBB0_20
## %bb.1:
	leaq	-96(%rbp), %rcx
	movq	%rbx, %rdi
	movl	$225, %esi
	movl	$-1, %edx
	movl	$1, %r8d
	callq	_au8522_rc_read
	testl	%eax, %eax
	js	LBB0_3
## %bb.2:
	testb	$16, -96(%rbp)
	jne	LBB0_4
LBB0_3:
	movq	%rbx, %rdi
	movl	$224, %esi
	movl	$16, %edx
	callq	_au8522_rc_set
	jmp	LBB0_20
LBB0_4:
	leaq	-96(%rbp), %rcx
	movq	%rbx, %rdi
	movl	$227, %esi
	movl	$17, %edx
	movl	$40, %r8d
	callq	_au8522_rc_read
	testl	%eax, %eax
	js	LBB0_5
## %bb.6:
	movq	%rbx, %rdi
	movl	$224, %esi
	movl	$16, %edx
	callq	_au8522_rc_clear
	movq	%rbx, -112(%rbp)                ## 8-byte Spill
	movq	%rbx, %rdi
	movl	$224, %esi
	movl	$16, %edx
	callq	_au8522_rc_set
	leaq	L_.str(%rip), %rsi
	leaq	-96(%rbp), %rcx
	movl	$16, %edi
	movl	$40, %edx
	xorl	%eax, %eax
	callq	_dprintk
	movzbl	-96(%rbp), %r15d
	shrl	$7, %r15d
	movl	$1, %ecx
	xorl	%r12d, %r12d
	xorl	%ebx, %ebx
	jmp	LBB0_7
	.p2align	4, 0x90
LBB0_18:                                ##   in Loop: Header=BB0_7 Depth=1
	incq	%r12
	cmpq	$40, %r12
	je	LBB0_19
LBB0_7:                                 ## =>This Loop Header: Depth=1
                                        ##     Child Loop BB0_8 Depth 2
	movl	$7, %r14d
	jmp	LBB0_8
	.p2align	4, 0x90
LBB0_9:                                 ##   in Loop: Header=BB0_8 Depth=2
	incl	%ebx
	addl	$-1, %r14d
	jae	LBB0_18
LBB0_8:                                 ##   Parent Loop BB0_7 Depth=1
                                        ## =>  This Inner Loop Header: Depth=2
	movzbl	-96(%rbp,%r12), %eax
	xorl	%r13d, %r13d
	btl	%r14d, %eax
	setb	%r13b
	cmpl	%r15d, %r13d
	je	LBB0_9
## %bb.10:                              ##   in Loop: Header=BB0_8 Depth=2
	testl	%ecx, %ecx
	je	LBB0_16
## %bb.11:                              ##   in Loop: Header=BB0_8 Depth=2
	movl	$1, -104(%rbp)
	movq	_NEC_START_SPACE@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	leal	-2(%rax), %ecx
	cmpl	%ecx, %ebx
	jle	LBB0_14
## %bb.12:                              ##   in Loop: Header=BB0_8 Depth=2
	addl	$2, %eax
	cmpl	%eax, %ebx
	jge	LBB0_14
## %bb.13:                              ##   in Loop: Header=BB0_8 Depth=2
	movq	_NEC_START_PULSE@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	movl	%ecx, -100(%rbp)
	movl	$16, %edi
	leaq	L_.str.1(%rip), %rsi
	jmp	LBB0_15
LBB0_14:                                ##   in Loop: Header=BB0_8 Depth=2
	movq	_RC5_START_PULSE@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	movl	%ecx, -100(%rbp)
	movl	$16, %edi
	leaq	L_.str.4(%rip), %rsi
LBB0_15:                                ##   in Loop: Header=BB0_8 Depth=2
	leaq	L_.str.2(%rip), %rdx
	xorl	%eax, %eax
	callq	_dprintk
	movq	-112(%rbp), %rax                ## 8-byte Reload
	movl	(%rax), %edi
	leaq	-104(%rbp), %rsi
	callq	_ir_raw_event_store
LBB0_16:                                ##   in Loop: Header=BB0_8 Depth=2
	movq	_AU8522_UNIT@GOTPCREL(%rip), %rax
	imull	(%rax), %ebx
	xorl	%eax, %eax
	testl	%r15d, %r15d
	sete	%al
	movl	%eax, -104(%rbp)
	movl	%ebx, -100(%rbp)
	leaq	L_.str.3(%rip), %rdx
	leaq	L_.str.2(%rip), %rax
	cmoveq	%rax, %rdx
	movl	$16, %edi
	leaq	L_.str.5(%rip), %rsi
	movl	%ebx, %ecx
	xorl	%eax, %eax
	callq	_dprintk
	movq	-112(%rbp), %rax                ## 8-byte Reload
	movl	(%rax), %edi
	leaq	-104(%rbp), %rsi
	callq	_ir_raw_event_store
	xorl	%ecx, %ecx
	movl	$1, %ebx
	movl	%r13d, %r15d
	addl	$-1, %r14d
	jb	LBB0_8
	jmp	LBB0_18
LBB0_19:
	movq	_AU8522_UNIT@GOTPCREL(%rip), %rax
	imull	(%rax), %ebx
	xorl	%eax, %eax
	testl	%r15d, %r15d
	sete	%al
	movl	%eax, -104(%rbp)
	movl	%ebx, -100(%rbp)
	leaq	L_.str.3(%rip), %rdx
	leaq	L_.str.2(%rip), %rax
	cmoveq	%rax, %rdx
	leaq	L_.str.6(%rip), %rsi
	movl	$16, %edi
	movl	%ebx, %ecx
	xorl	%eax, %eax
	callq	_dprintk
	movq	-112(%rbp), %rbx                ## 8-byte Reload
	movl	(%rbx), %edi
	leaq	-104(%rbp), %rsi
	callq	_ir_raw_event_store
	movl	(%rbx), %edi
	callq	_ir_raw_event_handle
	movl	$1, %r14d
	jmp	LBB0_20
LBB0_5:
	movl	%eax, %r14d
LBB0_20:
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-48(%rbp), %rax
	jne	LBB0_22
## %bb.21:
	movl	%r14d, %eax
	addq	$72, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_22:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.comm	_DEV_DISCONNECTED,4,2           ## @DEV_DISCONNECTED
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"RC data received: %*ph\n"

	.comm	_NEC_START_SPACE,4,2            ## @NEC_START_SPACE
	.comm	_NEC_START_PULSE,4,2            ## @NEC_START_PULSE
L_.str.1:                               ## @.str.1
	.asciz	"Storing NEC start %s with duration %d"

L_.str.2:                               ## @.str.2
	.asciz	"pulse"

L_.str.3:                               ## @.str.3
	.asciz	"space"

	.comm	_RC5_START_PULSE,4,2            ## @RC5_START_PULSE
L_.str.4:                               ## @.str.4
	.asciz	"Storing RC5 start %s with duration %d"

	.comm	_AU8522_UNIT,4,2                ## @AU8522_UNIT
L_.str.5:                               ## @.str.5
	.asciz	"Storing %s with duration %d"

L_.str.6:                               ## @.str.6
	.asciz	"Storing end %s with duration %d"

	.no_dead_strip	_au0828_get_key_au8522
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function au0828_get_key_au8522
_au0828_get_key_au8522:                 ; @au0828_get_key_au8522
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #176
	.cfi_def_cfa_offset 176
	stp	x28, x27, [sp, #80]             ; 16-byte Folded Spill
	stp	x26, x25, [sp, #96]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #112]            ; 16-byte Folded Spill
	stp	x22, x21, [sp, #128]            ; 16-byte Folded Spill
	stp	x20, x19, [sp, #144]            ; 16-byte Folded Spill
	stp	x29, x30, [sp, #160]            ; 16-byte Folded Spill
	add	x29, sp, #160
	.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
	.cfi_offset w25, -72
	.cfi_offset w26, -80
	.cfi_offset w27, -88
	.cfi_offset w28, -96
	mov	x19, x0
Lloh0:
	adrp	x8, ___stack_chk_guard@GOTPAGE
Lloh1:
	ldr	x8, [x8, ___stack_chk_guard@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	str	x8, [sp, #72]
	str	xzr, [sp, #24]
Lloh3:
	adrp	x8, _DEV_DISCONNECTED@GOTPAGE
Lloh4:
	ldr	x8, [x8, _DEV_DISCONNECTED@GOTPAGEOFF]
Lloh5:
	ldr	w0, [x8]
	ldr	x1, [x19, #8]
	bl	_test_bit
	cbz	x0, LBB0_2
; %bb.1:
	mov	w0, #0
	b	LBB0_19
LBB0_2:
	add	x3, sp, #32
	mov	x0, x19
	mov	w1, #225
	mov	w2, #-1
	mov	w4, #1
	bl	_au8522_rc_read
	tbnz	w0, #31, LBB0_4
; %bb.3:
	ldrb	w8, [sp, #32]
	tbnz	w8, #4, LBB0_5
LBB0_4:
	mov	x0, x19
	mov	w1, #224
	mov	w2, #16
	bl	_au8522_rc_set
	mov	w0, #0
	b	LBB0_19
LBB0_5:
	add	x23, sp, #32
	add	x3, sp, #32
	mov	x0, x19
	mov	w1, #227
	mov	w2, #17
	mov	w4, #40
	bl	_au8522_rc_read
	tbnz	w0, #31, LBB0_19
; %bb.6:
	mov	x0, x19
	mov	w1, #224
	mov	w2, #16
	bl	_au8522_rc_clear
	mov	x0, x19
	mov	w1, #224
	mov	w2, #16
	bl	_au8522_rc_set
	mov	w8, #40
	stp	x8, x23, [sp]
Lloh6:
	adrp	x1, l_.str@PAGE
Lloh7:
	add	x1, x1, l_.str@PAGEOFF
	mov	w0, #16
	bl	_dprintk
	mov	x24, #0
	mov	w21, #0
	ldrb	w8, [sp, #32]
	lsr	w25, w8, #7
Lloh8:
	adrp	x27, _AU8522_UNIT@GOTPAGE
Lloh9:
	ldr	x27, [x27, _AU8522_UNIT@GOTPAGEOFF]
Lloh10:
	adrp	x26, l_.str.2@PAGE
Lloh11:
	add	x26, x26, l_.str.2@PAGEOFF
Lloh12:
	adrp	x20, l_.str.5@PAGE
Lloh13:
	add	x20, x20, l_.str.5@PAGEOFF
	mov	w8, #1
	b	LBB0_8
LBB0_7:                                 ;   in Loop: Header=BB0_8 Depth=1
	add	x24, x24, #1
	cmp	x24, #40
	b.eq	LBB0_18
LBB0_8:                                 ; =>This Loop Header: Depth=1
                                        ;     Child Loop BB0_11 Depth 2
	mov	w22, #7
	b	LBB0_11
LBB0_9:                                 ;   in Loop: Header=BB0_11 Depth=2
	add	w21, w21, #1
LBB0_10:                                ;   in Loop: Header=BB0_11 Depth=2
	sub	w22, w22, #1
	cmn	w22, #1
	b.eq	LBB0_7
LBB0_11:                                ;   Parent Loop BB0_8 Depth=1
                                        ; =>  This Inner Loop Header: Depth=2
	ldrb	w9, [x23, x24]
	lsr	w9, w9, w22
	and	w28, w9, #0x1
	cmp	w28, w25
	b.eq	LBB0_9
; %bb.12:                               ;   in Loop: Header=BB0_11 Depth=2
	cbz	w8, LBB0_17
; %bb.13:                               ;   in Loop: Header=BB0_11 Depth=2
	mov	w8, #1
	str	w8, [sp, #24]
Lloh14:
	adrp	x8, _NEC_START_SPACE@GOTPAGE
Lloh15:
	ldr	x8, [x8, _NEC_START_SPACE@GOTPAGEOFF]
Lloh16:
	ldr	w8, [x8]
	sub	w9, w8, #2
	add	w8, w8, #2
	cmp	w21, w9
	ccmp	w21, w8, #0, gt
	b.lt	LBB0_15
; %bb.14:                               ;   in Loop: Header=BB0_11 Depth=2
Lloh17:
	adrp	x8, _RC5_START_PULSE@GOTPAGE
Lloh18:
	ldr	x8, [x8, _RC5_START_PULSE@GOTPAGEOFF]
Lloh19:
	ldr	w8, [x8]
	str	w8, [sp, #28]
	stp	x26, x8, [sp]
	mov	w0, #16
Lloh20:
	adrp	x1, l_.str.4@PAGE
Lloh21:
	add	x1, x1, l_.str.4@PAGEOFF
	b	LBB0_16
LBB0_15:                                ;   in Loop: Header=BB0_11 Depth=2
Lloh22:
	adrp	x8, _NEC_START_PULSE@GOTPAGE
Lloh23:
	ldr	x8, [x8, _NEC_START_PULSE@GOTPAGEOFF]
Lloh24:
	ldr	w8, [x8]
	str	w8, [sp, #28]
	stp	x26, x8, [sp]
	mov	w0, #16
Lloh25:
	adrp	x1, l_.str.1@PAGE
Lloh26:
	add	x1, x1, l_.str.1@PAGEOFF
LBB0_16:                                ;   in Loop: Header=BB0_11 Depth=2
	bl	_dprintk
	ldr	w0, [x19]
	add	x1, sp, #24
	bl	_ir_raw_event_store
LBB0_17:                                ;   in Loop: Header=BB0_11 Depth=2
	cmp	w25, #0
	cset	w8, eq
	ldr	w9, [x27]
	mul	w9, w9, w21
	stp	w8, w9, [sp, #24]
Lloh27:
	adrp	x8, l_.str.3@PAGE
Lloh28:
	add	x8, x8, l_.str.3@PAGEOFF
	csel	x8, x26, x8, eq
	stp	x8, x9, [sp]
	mov	w0, #16
	mov	x1, x20
	bl	_dprintk
	ldr	w0, [x19]
	add	x1, sp, #24
	bl	_ir_raw_event_store
	mov	w8, #0
	mov	w21, #1
	mov	x25, x28
	b	LBB0_10
LBB0_18:
	cmp	w25, #0
	cset	w8, eq
	ldr	w9, [x27]
	mul	w9, w9, w21
	stp	w8, w9, [sp, #24]
Lloh29:
	adrp	x8, l_.str.3@PAGE
Lloh30:
	add	x8, x8, l_.str.3@PAGEOFF
	csel	x8, x26, x8, eq
	stp	x8, x9, [sp]
Lloh31:
	adrp	x1, l_.str.6@PAGE
Lloh32:
	add	x1, x1, l_.str.6@PAGEOFF
	mov	w0, #16
	bl	_dprintk
	ldr	w0, [x19]
	add	x1, sp, #24
	bl	_ir_raw_event_store
	ldr	w0, [x19]
	bl	_ir_raw_event_handle
	mov	w0, #1
LBB0_19:
	ldr	x8, [sp, #72]
Lloh33:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh34:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh35:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_21
; %bb.20:
	ldp	x29, x30, [sp, #160]            ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #144]            ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #128]            ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #112]            ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #96]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp, #80]             ; 16-byte Folded Reload
	add	sp, sp, #176
	ret
LBB0_21:
	bl	___stack_chk_fail
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh12, Lloh13
	.loh AdrpAdd	Lloh10, Lloh11
	.loh AdrpLdrGot	Lloh8, Lloh9
	.loh AdrpAdd	Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpAdd	Lloh20, Lloh21
	.loh AdrpLdrGotLdr	Lloh17, Lloh18, Lloh19
	.loh AdrpAdd	Lloh25, Lloh26
	.loh AdrpLdrGotLdr	Lloh22, Lloh23, Lloh24
	.loh AdrpAdd	Lloh27, Lloh28
	.loh AdrpAdd	Lloh31, Lloh32
	.loh AdrpAdd	Lloh29, Lloh30
	.loh AdrpLdrGotLdr	Lloh33, Lloh34, Lloh35
	.cfi_endproc
                                        ; -- End function
	.comm	_DEV_DISCONNECTED,4,2           ; @DEV_DISCONNECTED
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"RC data received: %*ph\n"

	.comm	_NEC_START_SPACE,4,2            ; @NEC_START_SPACE
	.comm	_NEC_START_PULSE,4,2            ; @NEC_START_PULSE
l_.str.1:                               ; @.str.1
	.asciz	"Storing NEC start %s with duration %d"

l_.str.2:                               ; @.str.2
	.asciz	"pulse"

l_.str.3:                               ; @.str.3
	.asciz	"space"

	.comm	_RC5_START_PULSE,4,2            ; @RC5_START_PULSE
l_.str.4:                               ; @.str.4
	.asciz	"Storing RC5 start %s with duration %d"

	.comm	_AU8522_UNIT,4,2                ; @AU8522_UNIT
l_.str.5:                               ; @.str.5
	.asciz	"Storing %s with duration %d"

l_.str.6:                               ; @.str.6
	.asciz	"Storing end %s with duration %d"

	.no_dead_strip	_au0828_get_key_au8522
.subsections_via_symbols
