	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_s5p_cec_copy_packet            ## -- Begin function s5p_cec_copy_packet
	.p2align	4, 0x90
_s5p_cec_copy_packet:                   ## @s5p_cec_copy_packet
	.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
	movl	%ecx, -44(%rbp)                 ## 4-byte Spill
	movq	%rsi, %r15
	movq	%rdi, %r13
	testq	%rdx, %rdx
	movq	%rdx, -56(%rbp)                 ## 8-byte Spill
	je	LBB0_3
## %bb.1:
	xorl	%ebx, %ebx
	movq	_S5P_CEC_TX_BUFF0@GOTPCREL(%rip), %r12
	xorl	%r14d, %r14d
	.p2align	4, 0x90
LBB0_2:                                 ## =>This Inner Loop Header: Depth=1
	movsbl	(%r15,%r14), %edi
	movq	8(%r13), %rsi
	addq	(%r12), %rsi
	addq	%rbx, %rsi
	callq	_writeb
	movq	-56(%rbp), %rdx                 ## 8-byte Reload
	incq	%r14
	addq	$4, %rbx
	cmpq	%r14, %rdx
	jne	LBB0_2
LBB0_3:
	movq	_S5P_CEC_TX_BYTES@GOTPCREL(%rip), %rax
	movq	(%rax), %rsi
	addq	8(%r13), %rsi
	movl	%edx, %edi
	callq	_writeb
	movq	_S5P_CEC_TX_CTRL@GOTPCREL(%rip), %r14
	movq	(%r14), %rdi
	addq	8(%r13), %rdi
	callq	_readb
	movq	_S5P_CEC_TX_CTRL_START@GOTPCREL(%rip), %rcx
	orl	(%rcx), %eax
	andl	$-113, %eax
	movl	-44(%rbp), %ebx                 ## 4-byte Reload
	shll	$4, %ebx
	orl	%eax, %ebx
	movq	_CEC_MESSAGE_BROADCAST_MASK@GOTPCREL(%rip), %rax
	movb	(%rax), %al
	andb	(%r15), %al
	movq	_CEC_MESSAGE_BROADCAST@GOTPCREL(%rip), %rcx
	movl	(%r13), %edi
	cmpb	(%rcx), %al
	jne	LBB0_5
## %bb.4:
	leaq	L_.str(%rip), %rsi
	xorl	%eax, %eax
	callq	_dev_dbg
	movq	_S5P_CEC_TX_CTRL_BCAST@GOTPCREL(%rip), %rax
	orl	(%rax), %ebx
	jmp	LBB0_6
LBB0_5:
	leaq	L_.str.1(%rip), %rsi
	xorl	%eax, %eax
	callq	_dev_dbg
	movq	_S5P_CEC_TX_CTRL_BCAST@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	notl	%eax
	andl	%eax, %ebx
LBB0_6:
	movq	(%r14), %rsi
	addq	8(%r13), %rsi
	movl	%ebx, %edi
	callq	_writeb
	movl	(%r13), %edi
	leaq	L_.str.2(%rip), %rsi
	movq	-56(%rbp), %rcx                 ## 8-byte Reload
	movq	%rcx, %rdx
                                        ## kill: def $ecx killed $ecx killed $rcx
	movq	%r15, %r8
	xorl	%eax, %eax
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_dev_dbg                        ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_S5P_CEC_TX_BUFF0,8,3           ## @S5P_CEC_TX_BUFF0
	.comm	_S5P_CEC_TX_BYTES,8,3           ## @S5P_CEC_TX_BYTES
	.comm	_S5P_CEC_TX_CTRL,8,3            ## @S5P_CEC_TX_CTRL
	.comm	_S5P_CEC_TX_CTRL_START,4,2      ## @S5P_CEC_TX_CTRL_START
	.comm	_CEC_MESSAGE_BROADCAST_MASK,1,0 ## @CEC_MESSAGE_BROADCAST_MASK
	.comm	_CEC_MESSAGE_BROADCAST,1,0      ## @CEC_MESSAGE_BROADCAST
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Broadcast"

	.comm	_S5P_CEC_TX_CTRL_BCAST,4,2      ## @S5P_CEC_TX_CTRL_BCAST
L_.str.1:                               ## @.str.1
	.asciz	"No Broadcast"

L_.str.2:                               ## @.str.2
	.asciz	"cec-tx: cec count (%zu): %*ph"

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_s5p_cec_copy_packet            ; -- Begin function s5p_cec_copy_packet
	.p2align	2
_s5p_cec_copy_packet:                   ; @s5p_cec_copy_packet
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #112
	.cfi_def_cfa_offset 112
	stp	x26, x25, [sp, #32]             ; 16-byte Folded Spill
	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
	.cfi_offset w25, -72
	.cfi_offset w26, -80
	mov	x22, x3
	mov	x19, x2
	mov	x20, x1
	mov	x21, x0
	cbz	x2, LBB0_3
; %bb.1:
	mov	x23, #0
Lloh0:
	adrp	x24, _S5P_CEC_TX_BUFF0@GOTPAGE
Lloh1:
	ldr	x24, [x24, _S5P_CEC_TX_BUFF0@GOTPAGEOFF]
	mov	x25, x19
	mov	x26, x20
LBB0_2:                                 ; =>This Inner Loop Header: Depth=1
	ldrsb	w0, [x26], #1
	ldr	x8, [x21, #8]
	ldr	x9, [x24]
	add	x8, x8, x9
	add	x1, x23, x8
	bl	_writeb
	add	x23, x23, #4
	subs	x25, x25, #1
	b.ne	LBB0_2
LBB0_3:
	ldr	x8, [x21, #8]
Lloh2:
	adrp	x9, _S5P_CEC_TX_BYTES@GOTPAGE
Lloh3:
	ldr	x9, [x9, _S5P_CEC_TX_BYTES@GOTPAGEOFF]
Lloh4:
	ldr	x9, [x9]
	add	x1, x9, x8
	mov	x0, x19
	bl	_writeb
	ldr	x8, [x21, #8]
Lloh5:
	adrp	x23, _S5P_CEC_TX_CTRL@GOTPAGE
Lloh6:
	ldr	x23, [x23, _S5P_CEC_TX_CTRL@GOTPAGEOFF]
	ldr	x9, [x23]
	add	x0, x9, x8
	bl	_readb
Lloh7:
	adrp	x8, _S5P_CEC_TX_CTRL_START@GOTPAGE
Lloh8:
	ldr	x8, [x8, _S5P_CEC_TX_CTRL_START@GOTPAGEOFF]
Lloh9:
	ldr	w8, [x8]
	orr	w8, w8, w0
	and	w8, w8, #0xffffff8f
	orr	w22, w8, w22, lsl #4
	ldrb	w8, [x20]
Lloh10:
	adrp	x9, _CEC_MESSAGE_BROADCAST_MASK@GOTPAGE
Lloh11:
	ldr	x9, [x9, _CEC_MESSAGE_BROADCAST_MASK@GOTPAGEOFF]
	ldrb	w9, [x9]
	and	w8, w9, w8
Lloh12:
	adrp	x9, _CEC_MESSAGE_BROADCAST@GOTPAGE
Lloh13:
	ldr	x9, [x9, _CEC_MESSAGE_BROADCAST@GOTPAGEOFF]
	ldrb	w9, [x9]
	ldr	w0, [x21]
	cmp	w8, w9
	b.ne	LBB0_5
; %bb.4:
Lloh14:
	adrp	x1, l_.str@PAGE
Lloh15:
	add	x1, x1, l_.str@PAGEOFF
	bl	_dev_dbg
Lloh16:
	adrp	x8, _S5P_CEC_TX_CTRL_BCAST@GOTPAGE
Lloh17:
	ldr	x8, [x8, _S5P_CEC_TX_CTRL_BCAST@GOTPAGEOFF]
Lloh18:
	ldr	w8, [x8]
	orr	w0, w8, w22
	b	LBB0_6
LBB0_5:
Lloh19:
	adrp	x1, l_.str.1@PAGE
Lloh20:
	add	x1, x1, l_.str.1@PAGEOFF
	bl	_dev_dbg
Lloh21:
	adrp	x8, _S5P_CEC_TX_CTRL_BCAST@GOTPAGE
Lloh22:
	ldr	x8, [x8, _S5P_CEC_TX_CTRL_BCAST@GOTPAGEOFF]
Lloh23:
	ldr	w8, [x8]
	bic	w0, w22, w8
LBB0_6:
	ldr	x8, [x21, #8]
	ldr	x9, [x23]
	add	x1, x9, x8
	bl	_writeb
	ldr	w0, [x21]
	mov	x8, x19
	stp	x8, x20, [sp, #8]
	str	x19, [sp]
Lloh24:
	adrp	x1, l_.str.2@PAGE
Lloh25:
	add	x1, x1, l_.str.2@PAGEOFF
	bl	_dev_dbg
	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
	ldp	x26, x25, [sp, #32]             ; 16-byte Folded Reload
	add	sp, sp, #112
	ret
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh12, Lloh13
	.loh AdrpLdrGot	Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh7, Lloh8, Lloh9
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh16, Lloh17, Lloh18
	.loh AdrpAdd	Lloh14, Lloh15
	.loh AdrpLdrGotLdr	Lloh21, Lloh22, Lloh23
	.loh AdrpAdd	Lloh19, Lloh20
	.loh AdrpAdd	Lloh24, Lloh25
	.cfi_endproc
                                        ; -- End function
	.comm	_S5P_CEC_TX_BUFF0,8,3           ; @S5P_CEC_TX_BUFF0
	.comm	_S5P_CEC_TX_BYTES,8,3           ; @S5P_CEC_TX_BYTES
	.comm	_S5P_CEC_TX_CTRL,8,3            ; @S5P_CEC_TX_CTRL
	.comm	_S5P_CEC_TX_CTRL_START,4,2      ; @S5P_CEC_TX_CTRL_START
	.comm	_CEC_MESSAGE_BROADCAST_MASK,1,0 ; @CEC_MESSAGE_BROADCAST_MASK
	.comm	_CEC_MESSAGE_BROADCAST,1,0      ; @CEC_MESSAGE_BROADCAST
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Broadcast"

	.comm	_S5P_CEC_TX_CTRL_BCAST,4,2      ; @S5P_CEC_TX_CTRL_BCAST
l_.str.1:                               ; @.str.1
	.asciz	"No Broadcast"

l_.str.2:                               ; @.str.2
	.asciz	"cec-tx: cec count (%zu): %*ph"

.subsections_via_symbols
