	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function process_single_tx_qlock
_process_single_tx_qlock:               ## @process_single_tx_qlock
	.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	$232, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%edx, %r15d
	movq	%rsi, %r13
	movq	%rdi, %r14
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -48(%rbp)
	leaq	-256(%rbp), %rdi
	xorl	%esi, %esi
	movl	$12, %edx
	callq	_memset
	movq	(%r13), %rax
	movq	_DRM_DP_SIDEBAND_TX_QUEUED@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_2
## %bb.1:
	movl	$-1, 8(%r13)
	movq	_DRM_DP_SIDEBAND_TX_START_SEND@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, (%r13)
LBB0_2:
	leaq	-256(%rbp), %rdi
	movq	%r13, %rsi
	callq	_set_hdr_from_dst_qlock
	testl	%eax, %eax
	js	LBB0_3
## %bb.4:
	movq	%r14, -264(%rbp)                ## 8-byte Spill
	movl	12(%r13), %r14d
	subl	16(%r13), %r14d
	leaq	-256(%rbp), %rdi
	callq	_drm_dp_calc_sb_hdr_size
	movl	$47, %ebx
	subl	%eax, %ebx
	movl	%r14d, %edi
	movl	%ebx, %esi
	callq	_min
	movl	%eax, %r12d
	cmpl	12(%r13), %r14d
	jne	LBB0_6
## %bb.5:
	movl	$1, -256(%rbp)
LBB0_6:
	cmpl	%r14d, %ebx
	jl	LBB0_8
## %bb.7:
	movl	$1, -252(%rbp)
LBB0_8:
	movl	%r12d, %ebx
	incl	%ebx
	movl	%ebx, -248(%rbp)
	leaq	-256(%rbp), %rdi
	leaq	-240(%rbp), %r14
	leaq	-244(%rbp), %rdx
	movq	%r14, %rsi
	callq	_drm_dp_encode_sideband_msg_hdr
	movslq	-244(%rbp), %rax
	leaq	-240(,%rax,4), %rdi
	addq	%rbp, %rdi
	movslq	16(%r13), %rsi
	shlq	$2, %rsi
	addq	24(%r13), %rsi
	movl	%r12d, %edx
	callq	_memcpy
	movslq	-244(%rbp), %rax
	leaq	-240(,%rax,4), %rdi
	addq	%rbp, %rdi
	movl	%r12d, %esi
	callq	_drm_dp_crc_sideband_chunk_req
	addl	-244(%rbp), %ebx
	movl	%ebx, -244(%rbp)
	movq	-264(%rbp), %rdi                ## 8-byte Reload
	movl	%r15d, %esi
	movq	%r14, %rdx
	movl	%ebx, %ecx
	callq	_drm_dp_send_sideband_msg
	testl	%eax, %eax
	je	LBB0_10
## %bb.9:
	movl	%eax, %ebx
	leaq	L_.str(%rip), %rdi
	callq	_DRM_DEBUG_KMS
	jmp	LBB0_12
LBB0_3:
	movl	%eax, %ebx
	jmp	LBB0_12
LBB0_10:
	movl	16(%r13), %eax
	addl	%r12d, %eax
	movl	%eax, 16(%r13)
	xorl	%ebx, %ebx
	cmpl	12(%r13), %eax
	jne	LBB0_12
## %bb.11:
	movq	_DRM_DP_SIDEBAND_TX_SENT@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, (%r13)
	movl	$1, %ebx
LBB0_12:
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-48(%rbp), %rax
	jne	LBB0_14
## %bb.13:
	movl	%ebx, %eax
	addq	$232, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_14:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.comm	_DRM_DP_SIDEBAND_TX_QUEUED,8,3  ## @DRM_DP_SIDEBAND_TX_QUEUED
	.comm	_DRM_DP_SIDEBAND_TX_START_SEND,8,3 ## @DRM_DP_SIDEBAND_TX_START_SEND
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"sideband msg failed to send\n"

	.comm	_DRM_DP_SIDEBAND_TX_SENT,8,3    ## @DRM_DP_SIDEBAND_TX_SENT
	.no_dead_strip	_process_single_tx_qlock
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function process_single_tx_qlock
_process_single_tx_qlock:               ; @process_single_tx_qlock
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #304
	.cfi_def_cfa_offset 304
	stp	x28, x27, [sp, #224]            ; 16-byte Folded Spill
	stp	x24, x23, [sp, #240]            ; 16-byte Folded Spill
	stp	x22, x21, [sp, #256]            ; 16-byte Folded Spill
	stp	x20, x19, [sp, #272]            ; 16-byte Folded Spill
	stp	x29, x30, [sp, #288]            ; 16-byte Folded Spill
	add	x29, sp, #288
	.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 w27, -72
	.cfi_offset w28, -80
	mov	x20, x2
	mov	x19, x1
	mov	x21, x0
Lloh0:
	adrp	x8, ___stack_chk_guard@GOTPAGE
Lloh1:
	ldr	x8, [x8, ___stack_chk_guard@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	stur	x8, [x29, #-72]
	add	x0, sp, #8
	mov	w1, #0
	mov	w2, #12
	bl	_memset
	ldr	x8, [x19]
Lloh3:
	adrp	x9, _DRM_DP_SIDEBAND_TX_QUEUED@GOTPAGE
Lloh4:
	ldr	x9, [x9, _DRM_DP_SIDEBAND_TX_QUEUED@GOTPAGEOFF]
Lloh5:
	ldr	x9, [x9]
	cmp	x8, x9
	b.ne	LBB0_2
; %bb.1:
	mov	w8, #-1
	str	w8, [x19, #8]
Lloh6:
	adrp	x8, _DRM_DP_SIDEBAND_TX_START_SEND@GOTPAGE
Lloh7:
	ldr	x8, [x8, _DRM_DP_SIDEBAND_TX_START_SEND@GOTPAGEOFF]
Lloh8:
	ldr	x8, [x8]
	str	x8, [x19]
LBB0_2:
	add	x0, sp, #8
	mov	x1, x19
	bl	_set_hdr_from_dst_qlock
	tbnz	w0, #31, LBB0_9
; %bb.3:
	ldp	w8, w9, [x19, #12]
	sub	w23, w8, w9
	add	x0, sp, #8
	bl	_drm_dp_calc_sb_hdr_size
	mov	w8, #47
	sub	w24, w8, w0
	mov	x0, x23
	mov	x1, x24
	bl	_min
	mov	x22, x0
	ldr	w8, [x19, #12]
	cmp	w23, w8
	b.ne	LBB0_5
; %bb.4:
	mov	w8, #1
	str	w8, [sp, #8]
LBB0_5:
	cmp	w24, w23
	b.lt	LBB0_7
; %bb.6:
	mov	w8, #1
	str	w8, [sp, #12]
LBB0_7:
	add	w23, w22, #1
	str	w23, [sp, #16]
	add	x24, sp, #24
	add	x0, sp, #8
	add	x1, sp, #24
	add	x2, sp, #4
	bl	_drm_dp_encode_sideband_msg_hdr
	ldrsw	x8, [sp, #4]
	add	x0, x24, x8, lsl #2
	ldr	x8, [x19, #24]
	ldrsw	x9, [x19, #16]
	add	x1, x8, x9, lsl #2
	mov	x2, x22
	bl	_memcpy
	ldrsw	x8, [sp, #4]
	add	x0, x24, x8, lsl #2
	mov	x1, x22
	bl	_drm_dp_crc_sideband_chunk_req
	ldr	w8, [sp, #4]
	add	w3, w8, w23
	str	w3, [sp, #4]
	add	x2, sp, #24
	mov	x0, x21
	mov	x1, x20
	bl	_drm_dp_send_sideband_msg
	cbz	w0, LBB0_10
; %bb.8:
	mov	x23, x0
Lloh9:
	adrp	x0, l_.str@PAGE
Lloh10:
	add	x0, x0, l_.str@PAGEOFF
	bl	_DRM_DEBUG_KMS
	b	LBB0_13
LBB0_9:
	mov	x23, x0
	b	LBB0_13
LBB0_10:
	ldp	w9, w8, [x19, #12]
	add	w8, w8, w22
	cmp	w8, w9
	str	w8, [x19, #16]
	b.ne	LBB0_12
; %bb.11:
Lloh11:
	adrp	x8, _DRM_DP_SIDEBAND_TX_SENT@GOTPAGE
Lloh12:
	ldr	x8, [x8, _DRM_DP_SIDEBAND_TX_SENT@GOTPAGEOFF]
Lloh13:
	ldr	x8, [x8]
	str	x8, [x19]
	mov	w23, #1
	b	LBB0_13
LBB0_12:
	mov	w23, #0
LBB0_13:
	ldur	x8, [x29, #-72]
Lloh14:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh15:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh16:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_15
; %bb.14:
	mov	x0, x23
	ldp	x29, x30, [sp, #288]            ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #272]            ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #256]            ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #240]            ; 16-byte Folded Reload
	ldp	x28, x27, [sp, #224]            ; 16-byte Folded Reload
	add	sp, sp, #304
	ret
LBB0_15:
	bl	___stack_chk_fail
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpAdd	Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.cfi_endproc
                                        ; -- End function
	.comm	_DRM_DP_SIDEBAND_TX_QUEUED,8,3  ; @DRM_DP_SIDEBAND_TX_QUEUED
	.comm	_DRM_DP_SIDEBAND_TX_START_SEND,8,3 ; @DRM_DP_SIDEBAND_TX_START_SEND
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"sideband msg failed to send\n"

	.comm	_DRM_DP_SIDEBAND_TX_SENT,8,3    ; @DRM_DP_SIDEBAND_TX_SENT
	.no_dead_strip	_process_single_tx_qlock
.subsections_via_symbols
