	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_cx88_i2c_init_ir               ## -- Begin function cx88_i2c_init_ir
	.p2align	4, 0x90
_cx88_i2c_init_ir:                      ## @cx88_i2c_init_ir
	.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	$56, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	cmpq	$0, (%rdi)
	jne	LBB0_11
## %bb.1:
	movq	%rdi, %rbx
	leaq	-88(%rbp), %rdi
	xorl	%esi, %esi
	movl	$48, %edx
	callq	_memset
	movl	-88(%rbp), %edi
	movq	_I2C_NAME_SIZE@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	leaq	L_.str(%rip), %rsi
	callq	_strscpy
	cmpl	$129, 8(%rbx)
	jne	LBB0_2
## %bb.3:
	leaq	L_.str.1(%rip), %rax
	movq	%rax, 24(%rbx)
	movq	_RC_PROTO_BIT_UNKNOWN@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 16(%rbx)
	movq	_get_key_pvr2000@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 56(%rbx)
	movq	_RC_MAP_EMPTY@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 52(%rbx)
	leaq	_cx88_i2c_init_ir.pvr2000_addr_list(%rip), %r13
	jmp	LBB0_4
LBB0_2:
	leaq	_cx88_i2c_init_ir.default_addr_list(%rip), %r13
LBB0_4:
	movzwl	(%r13), %eax
	cmpl	$128, %eax
	je	LBB0_11
## %bb.5:
	leaq	16(%rbx), %r15
	leaq	12(%rbx), %r14
	movq	_I2C_SMBUS_QUICK@GOTPCREL(%rip), %r12
	.p2align	4, 0x90
LBB0_6:                                 ## =>This Inner Loop Header: Depth=1
	movq	$0, -64(%rbp)
	movq	%r15, %rdi
	xorl	%esi, %esi
	movl	$48, %edx
	callq	_memset
	movzwl	(%r13), %eax
	cmpw	$113, %ax
	jne	LBB0_8
## %bb.7:                               ##   in Loop: Header=BB0_6 Depth=1
	movl	-88(%rbp), %edi
	movq	_I2C_NAME_SIZE@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	leaq	L_.str.2(%rip), %rsi
	callq	_strscpy
	movq	64(%rbx), %rax
	movq	%rax, 24(%rbx)
	movq	_RC_MAP_HAUPPAUGE@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 52(%rbx)
	movq	_RC_PROTO_BIT_RC6_MCE@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movq	_RC_PROTO_BIT_RC5@GOTPCREL(%rip), %rcx
	orl	(%rcx), %eax
	movq	_RC_PROTO_BIT_RC6_6A_32@GOTPCREL(%rip), %rcx
	orl	(%rcx), %eax
	movl	%eax, 16(%rbx)
	movq	_IR_KBD_GET_KEY_HAUP_XVR@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 48(%rbx)
	movq	%r15, -64(%rbp)
	movzwl	(%r13), %eax
LBB0_8:                                 ##   in Loop: Header=BB0_6 Depth=1
	movq	_I2C_SMBUS_READ@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	movl	(%r12), %r9d
	movq	$0, (%rsp)
	movzwl	%ax, %esi
	movq	%r14, %rdi
	xorl	%edx, %edx
	xorl	%r8d, %r8d
	callq	_i2c_smbus_xfer
	testq	%rax, %rax
	jns	LBB0_9
## %bb.10:                              ##   in Loop: Header=BB0_6 Depth=1
	movzwl	2(%r13), %eax
	addq	$2, %r13
	cmpl	$128, %eax
	jne	LBB0_6
	jmp	LBB0_11
LBB0_9:
	movzwl	(%r13), %eax
	movw	%ax, -72(%rbp)
	leaq	-88(%rbp), %rsi
	movq	%r14, %rdi
	callq	_i2c_new_device
LBB0_11:
	addq	$56, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__const
	.p2align	1                               ## @cx88_i2c_init_ir.default_addr_list
_cx88_i2c_init_ir.default_addr_list:
	.short	24                              ## 0x18
	.short	107                             ## 0x6b
	.short	113                             ## 0x71
	.short	128                             ## 0x80

	.p2align	1                               ## @cx88_i2c_init_ir.pvr2000_addr_list
_cx88_i2c_init_ir.pvr2000_addr_list:
	.short	24                              ## 0x18
	.short	26                              ## 0x1a
	.short	128                             ## 0x80

	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"ir_video"

	.comm	_I2C_NAME_SIZE,4,2              ## @I2C_NAME_SIZE
L_.str.1:                               ## @.str.1
	.asciz	"cx88 Leadtek PVR 2000 remote"

	.comm	_RC_PROTO_BIT_UNKNOWN,4,2       ## @RC_PROTO_BIT_UNKNOWN
	.comm	_get_key_pvr2000,4,2            ## @get_key_pvr2000
	.comm	_RC_MAP_EMPTY,4,2               ## @RC_MAP_EMPTY
L_.str.2:                               ## @.str.2
	.asciz	"ir_z8f0811_haup"

	.comm	_RC_MAP_HAUPPAUGE,4,2           ## @RC_MAP_HAUPPAUGE
	.comm	_RC_PROTO_BIT_RC5,4,2           ## @RC_PROTO_BIT_RC5
	.comm	_RC_PROTO_BIT_RC6_MCE,4,2       ## @RC_PROTO_BIT_RC6_MCE
	.comm	_RC_PROTO_BIT_RC6_6A_32,4,2     ## @RC_PROTO_BIT_RC6_6A_32
	.comm	_IR_KBD_GET_KEY_HAUP_XVR,4,2    ## @IR_KBD_GET_KEY_HAUP_XVR
	.comm	_I2C_SMBUS_READ,4,2             ## @I2C_SMBUS_READ
	.comm	_I2C_SMBUS_QUICK,4,2            ## @I2C_SMBUS_QUICK
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_cx88_i2c_init_ir               ; -- Begin function cx88_i2c_init_ir
	.p2align	2
_cx88_i2c_init_ir:                      ; @cx88_i2c_init_ir
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #144
	.cfi_def_cfa_offset 144
	stp	x28, x27, [sp, #48]             ; 16-byte Folded Spill
	stp	x26, x25, [sp, #64]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #80]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #96]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #112]            ; 16-byte Folded Spill
	stp	x29, x30, [sp, #128]            ; 16-byte Folded Spill
	add	x29, sp, #128
	.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
	ldr	x8, [x0]
	cbnz	x8, LBB0_11
; %bb.1:
	mov	x19, x0
	mov	x0, sp
	mov	w1, #0
	mov	w2, #48
	bl	_memset
	ldr	w0, [sp]
Lloh0:
	adrp	x8, _I2C_NAME_SIZE@GOTPAGE
Lloh1:
	ldr	x8, [x8, _I2C_NAME_SIZE@GOTPAGEOFF]
Lloh2:
	ldr	w2, [x8]
Lloh3:
	adrp	x1, l_.str@PAGE
Lloh4:
	add	x1, x1, l_.str@PAGEOFF
	bl	_strscpy
	ldr	w8, [x19, #8]
	cmp	w8, #129
	b.ne	LBB0_3
; %bb.2:
Lloh5:
	adrp	x8, l_.str.1@PAGE
Lloh6:
	add	x8, x8, l_.str.1@PAGEOFF
	str	x8, [x19, #24]
Lloh7:
	adrp	x8, _RC_PROTO_BIT_UNKNOWN@GOTPAGE
Lloh8:
	ldr	x8, [x8, _RC_PROTO_BIT_UNKNOWN@GOTPAGEOFF]
Lloh9:
	ldr	w8, [x8]
	str	w8, [x19, #16]
Lloh10:
	adrp	x8, _get_key_pvr2000@GOTPAGE
Lloh11:
	ldr	x8, [x8, _get_key_pvr2000@GOTPAGEOFF]
Lloh12:
	adrp	x9, _RC_MAP_EMPTY@GOTPAGE
Lloh13:
	ldr	x9, [x9, _RC_MAP_EMPTY@GOTPAGEOFF]
Lloh14:
	ldr	w8, [x8]
Lloh15:
	ldr	w9, [x9]
	stp	w9, w8, [x19, #52]
Lloh16:
	adrp	x24, _cx88_i2c_init_ir.pvr2000_addr_list@PAGE
Lloh17:
	add	x24, x24, _cx88_i2c_init_ir.pvr2000_addr_list@PAGEOFF
	b	LBB0_4
LBB0_3:
Lloh18:
	adrp	x24, _cx88_i2c_init_ir.default_addr_list@PAGE
Lloh19:
	add	x24, x24, _cx88_i2c_init_ir.default_addr_list@PAGEOFF
LBB0_4:
	ldrh	w8, [x24]
	cmp	w8, #128
	b.eq	LBB0_11
; %bb.5:
	add	x21, x19, #16
	add	x20, x19, #12
Lloh20:
	adrp	x27, _RC_PROTO_BIT_RC6_MCE@GOTPAGE
Lloh21:
	ldr	x27, [x27, _RC_PROTO_BIT_RC6_MCE@GOTPAGEOFF]
Lloh22:
	adrp	x22, l_.str.2@PAGE
Lloh23:
	add	x22, x22, l_.str.2@PAGEOFF
Lloh24:
	adrp	x28, _RC_PROTO_BIT_RC6_6A_32@GOTPAGE
Lloh25:
	ldr	x28, [x28, _RC_PROTO_BIT_RC6_6A_32@GOTPAGEOFF]
Lloh26:
	adrp	x23, _IR_KBD_GET_KEY_HAUP_XVR@GOTPAGE
Lloh27:
	ldr	x23, [x23, _IR_KBD_GET_KEY_HAUP_XVR@GOTPAGEOFF]
Lloh28:
	adrp	x25, _I2C_SMBUS_READ@GOTPAGE
Lloh29:
	ldr	x25, [x25, _I2C_SMBUS_READ@GOTPAGEOFF]
Lloh30:
	adrp	x26, _I2C_SMBUS_QUICK@GOTPAGE
Lloh31:
	ldr	x26, [x26, _I2C_SMBUS_QUICK@GOTPAGEOFF]
LBB0_6:                                 ; =>This Inner Loop Header: Depth=1
	str	xzr, [sp, #24]
	mov	x0, x21
	mov	w1, #0
	mov	w2, #48
	bl	_memset
	ldrh	w1, [x24]
	cmp	w1, #113
	b.ne	LBB0_8
; %bb.7:                                ;   in Loop: Header=BB0_6 Depth=1
	ldr	w0, [sp]
Lloh32:
	adrp	x8, _I2C_NAME_SIZE@GOTPAGE
Lloh33:
	ldr	x8, [x8, _I2C_NAME_SIZE@GOTPAGEOFF]
Lloh34:
	ldr	w2, [x8]
	mov	x1, x22
	bl	_strscpy
	ldr	x8, [x19, #64]
	str	x8, [x19, #24]
Lloh35:
	adrp	x8, _RC_MAP_HAUPPAUGE@GOTPAGE
Lloh36:
	ldr	x8, [x8, _RC_MAP_HAUPPAUGE@GOTPAGEOFF]
Lloh37:
	ldr	w8, [x8]
Lloh38:
	adrp	x9, _RC_PROTO_BIT_RC5@GOTPAGE
Lloh39:
	ldr	x9, [x9, _RC_PROTO_BIT_RC5@GOTPAGEOFF]
Lloh40:
	ldr	w9, [x9]
	ldr	w10, [x27]
	orr	w9, w10, w9
	ldr	w10, [x28]
	orr	w9, w9, w10
	str	w9, [x19, #16]
	ldr	w9, [x23]
	stp	w9, w8, [x19, #48]
	str	x21, [sp, #24]
	ldrh	w1, [x24]
LBB0_8:                                 ;   in Loop: Header=BB0_6 Depth=1
	ldr	w3, [x25]
	ldr	w5, [x26]
	mov	x0, x20
	mov	w2, #0
	mov	w4, #0
	mov	x6, #0
	bl	_i2c_smbus_xfer
	tbz	x0, #63, LBB0_10
; %bb.9:                                ;   in Loop: Header=BB0_6 Depth=1
	ldrh	w8, [x24, #2]!
	cmp	w8, #128
	b.ne	LBB0_6
	b	LBB0_11
LBB0_10:
	ldrh	w8, [x24]
	strh	w8, [sp, #16]
	mov	x1, sp
	mov	x0, x20
	bl	_i2c_new_device
LBB0_11:
	ldp	x29, x30, [sp, #128]            ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #112]            ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #96]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #80]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #64]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp, #48]             ; 16-byte Folded Reload
	add	sp, sp, #144
	ret
	.loh AdrpAdd	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh15
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh14
	.loh AdrpLdrGotLdr	Lloh7, Lloh8, Lloh9
	.loh AdrpAdd	Lloh5, Lloh6
	.loh AdrpAdd	Lloh18, Lloh19
	.loh AdrpLdrGot	Lloh30, Lloh31
	.loh AdrpLdrGot	Lloh28, Lloh29
	.loh AdrpLdrGot	Lloh26, Lloh27
	.loh AdrpLdrGot	Lloh24, Lloh25
	.loh AdrpAdd	Lloh22, Lloh23
	.loh AdrpLdrGot	Lloh20, Lloh21
	.loh AdrpLdrGotLdr	Lloh38, Lloh39, Lloh40
	.loh AdrpLdrGotLdr	Lloh35, Lloh36, Lloh37
	.loh AdrpLdrGotLdr	Lloh32, Lloh33, Lloh34
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__const
	.p2align	1                               ; @cx88_i2c_init_ir.default_addr_list
_cx88_i2c_init_ir.default_addr_list:
	.short	24                              ; 0x18
	.short	107                             ; 0x6b
	.short	113                             ; 0x71
	.short	128                             ; 0x80

	.p2align	1                               ; @cx88_i2c_init_ir.pvr2000_addr_list
_cx88_i2c_init_ir.pvr2000_addr_list:
	.short	24                              ; 0x18
	.short	26                              ; 0x1a
	.short	128                             ; 0x80

	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"ir_video"

	.comm	_I2C_NAME_SIZE,4,2              ; @I2C_NAME_SIZE
l_.str.1:                               ; @.str.1
	.asciz	"cx88 Leadtek PVR 2000 remote"

	.comm	_RC_PROTO_BIT_UNKNOWN,4,2       ; @RC_PROTO_BIT_UNKNOWN
	.comm	_get_key_pvr2000,4,2            ; @get_key_pvr2000
	.comm	_RC_MAP_EMPTY,4,2               ; @RC_MAP_EMPTY
l_.str.2:                               ; @.str.2
	.asciz	"ir_z8f0811_haup"

	.comm	_RC_MAP_HAUPPAUGE,4,2           ; @RC_MAP_HAUPPAUGE
	.comm	_RC_PROTO_BIT_RC5,4,2           ; @RC_PROTO_BIT_RC5
	.comm	_RC_PROTO_BIT_RC6_MCE,4,2       ; @RC_PROTO_BIT_RC6_MCE
	.comm	_RC_PROTO_BIT_RC6_6A_32,4,2     ; @RC_PROTO_BIT_RC6_6A_32
	.comm	_IR_KBD_GET_KEY_HAUP_XVR,4,2    ; @IR_KBD_GET_KEY_HAUP_XVR
	.comm	_I2C_SMBUS_READ,4,2             ; @I2C_SMBUS_READ
	.comm	_I2C_SMBUS_QUICK,4,2            ; @I2C_SMBUS_QUICK
.subsections_via_symbols
