	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_mmal_connection_enable         ## -- Begin function mmal_connection_enable
	.p2align	4, 0x90
_mmal_connection_enable:                ## @mmal_connection_enable
	.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
	pushq	%rax
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %rbx
	movq	48(%rdi), %r15
	movq	40(%rdi), %r14
	movl	32(%rdi), %edx
	leaq	L_.str(%rip), %rdi
	movq	%rbx, %rsi
	callq	_LOG_TRACE
	cmpl	$0, (%rbx)
	je	LBB0_2
## %bb.1:
	movq	_MMAL_SUCCESS@GOTPCREL(%rip), %rax
	movq	(%rax), %r12
	jmp	LBB0_34
LBB0_2:
	xorl	%eax, %eax
	callq	_vcos_getmicrosecs
	movq	%rax, 8(%rbx)
	movl	16(%rbx), %eax
	movq	_MMAL_CONNECTION_FLAG_KEEP_BUFFER_REQUIREMENTS@GOTPCREL(%rip), %rcx
	testl	%eax, (%rcx)
	jne	LBB0_11
## %bb.3:
	movq	40(%r14), %rcx
	testq	%rcx, %rcx
	je	LBB0_5
## %bb.4:
	movq	%rcx, 24(%r14)
LBB0_5:
	movq	32(%r14), %rcx
	testq	%rcx, %rcx
	je	LBB0_7
## %bb.6:
	movq	%rcx, 16(%r14)
LBB0_7:
	movq	40(%r15), %rcx
	testq	%rcx, %rcx
	je	LBB0_9
## %bb.8:
	movq	%rcx, 24(%r15)
LBB0_9:
	movq	32(%r15), %rcx
	testq	%rcx, %rcx
	je	LBB0_11
## %bb.10:
	movq	%rcx, 16(%r15)
LBB0_11:
	movq	_MMAL_CONNECTION_FLAG_TUNNELLING@GOTPCREL(%rip), %rcx
	testl	%eax, (%rcx)
	je	LBB0_14
## %bb.12:
	xorl	%r12d, %r12d
	movq	%r14, %rdi
	xorl	%esi, %esi
	callq	_mmal_port_enable
	testq	%rax, %rax
	je	LBB0_33
## %bb.13:
	movq	%rax, %r14
	leaq	L_.str.1(%rip), %rdi
	callq	_LOG_ERROR
	movq	%r14, %r12
	jmp	LBB0_33
LBB0_14:
	movq	24(%r14), %rdi
	movq	24(%r15), %rsi
	callq	_MMAL_MAX
	movq	%rax, %r12
	movq	16(%r14), %rdi
	movq	16(%r15), %rsi
	callq	_MMAL_MAX
	movq	%r12, 24(%r15)
	movq	%r12, 24(%r14)
	movq	%rax, 16(%r15)
	movq	%rax, 16(%r14)
	movq	_MMAL_PORT_CAPABILITY_PASSTHROUGH@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	xorl	%edx, %edx
	andl	(%r14), %ecx
	cmoveq	%rax, %rdx
	movq	24(%rbx), %rdi
	movq	%r12, %rsi
	callq	_mmal_pool_resize
	movq	%rax, %r12
	movq	_MMAL_SUCCESS@GOTPCREL(%rip), %rax
	cmpq	(%rax), %r12
	jne	LBB0_17
## %bb.15:
	movq	8(%r14), %rax
	movq	_MMAL_PORT_TYPE_CLOCK@GOTPCREL(%rip), %r13
	cmpq	(%r13), %rax
	jne	LBB0_18
## %bb.16:
	movq	_mmal_connection_bh_clock_cb@GOTPCREL(%rip), %rax
	jmp	LBB0_19
LBB0_17:
	leaq	L_.str.2(%rip), %rdi
	callq	_LOG_ERROR
	jmp	LBB0_33
LBB0_18:
	movq	_mmal_connection_bh_out_cb@GOTPCREL(%rip), %rax
LBB0_19:
	movq	(%rax), %rsi
	movq	%r14, %rdi
	callq	_mmal_port_enable
	testq	%rax, %rax
	je	LBB0_21
## %bb.20:
	movq	%rax, %r12
	leaq	L_.str.1(%rip), %rdi
	callq	_LOG_ERROR
	jmp	LBB0_33
LBB0_21:
	movq	8(%r15), %rax
	cmpq	(%r13), %rax
	jne	LBB0_23
## %bb.22:
	movq	_mmal_connection_bh_clock_cb@GOTPCREL(%rip), %rax
	jmp	LBB0_24
LBB0_23:
	movq	_mmal_connection_bh_in_cb@GOTPCREL(%rip), %rax
LBB0_24:
	movq	(%rax), %rsi
	movq	%r15, %rdi
	callq	_mmal_port_enable
	testq	%rax, %rax
	je	LBB0_26
## %bb.25:
	movq	%rax, %r12
	leaq	L_.str.3(%rip), %rdi
	callq	_LOG_ERROR
	movq	%r14, %rdi
	callq	_mmal_port_disable
	jmp	LBB0_33
LBB0_26:
	movq	8(%r14), %rax
	cmpq	(%r13), %rax
	jne	LBB0_32
## %bb.27:
	cmpq	%rax, 8(%r15)
	jne	LBB0_32
## %bb.28:
	movq	24(%rbx), %rax
	movl	(%rax), %edi
	callq	_mmal_queue_get
	xorl	%r12d, %r12d
	testq	%rax, %rax
	je	LBB0_33
LBB0_29:                                ## =>This Inner Loop Header: Depth=1
	movq	%r14, %rdi
	movq	%rax, %rsi
	callq	_mmal_port_send_buffer
	movq	24(%rbx), %rax
	movl	(%rax), %edi
	callq	_mmal_queue_get
	testq	%rax, %rax
	je	LBB0_33
## %bb.30:                              ##   in Loop: Header=BB0_29 Depth=1
	movq	%r15, %rdi
	movq	%rax, %rsi
	callq	_mmal_port_send_buffer
	movq	24(%rbx), %rax
	movl	(%rax), %edi
	callq	_mmal_queue_get
	testq	%rax, %rax
	jne	LBB0_29
	jmp	LBB0_33
LBB0_32:
	xorl	%r12d, %r12d
LBB0_33:
	xorl	%eax, %eax
	callq	_vcos_getmicrosecs
	subq	8(%rbx), %rax
	movq	%rax, 8(%rbx)
	movq	_MMAL_SUCCESS@GOTPCREL(%rip), %rax
	xorl	%ecx, %ecx
	cmpq	(%rax), %r12
	sete	%cl
	movl	%ecx, (%rbx)
LBB0_34:
	movq	%r12, %rax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"%p, %s"

	.comm	_MMAL_SUCCESS,8,3               ## @MMAL_SUCCESS
	.comm	_MMAL_CONNECTION_FLAG_KEEP_BUFFER_REQUIREMENTS,4,2 ## @MMAL_CONNECTION_FLAG_KEEP_BUFFER_REQUIREMENTS
	.comm	_MMAL_CONNECTION_FLAG_TUNNELLING,4,2 ## @MMAL_CONNECTION_FLAG_TUNNELLING
L_.str.1:                               ## @.str.1
	.asciz	"output port couldn't be enabled"

	.comm	_MMAL_PORT_CAPABILITY_PASSTHROUGH,4,2 ## @MMAL_PORT_CAPABILITY_PASSTHROUGH
L_.str.2:                               ## @.str.2
	.asciz	"couldn't resize pool"

	.comm	_MMAL_PORT_TYPE_CLOCK,8,3       ## @MMAL_PORT_TYPE_CLOCK
	.comm	_mmal_connection_bh_clock_cb,8,3 ## @mmal_connection_bh_clock_cb
	.comm	_mmal_connection_bh_out_cb,8,3  ## @mmal_connection_bh_out_cb
	.comm	_mmal_connection_bh_in_cb,8,3   ## @mmal_connection_bh_in_cb
L_.str.3:                               ## @.str.3
	.asciz	"input port couldn't be enabled"

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_mmal_connection_enable         ; -- Begin function mmal_connection_enable
	.p2align	2
_mmal_connection_enable:                ; @mmal_connection_enable
	.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	x19, x0
	ldp	x20, x21, [x0, #40]
	ldr	w2, [x0, #32]
Lloh0:
	adrp	x0, l_.str@PAGE
Lloh1:
	add	x0, x0, l_.str@PAGEOFF
	mov	x1, x19
	bl	_LOG_TRACE
	ldr	w8, [x19]
	cbz	w8, LBB0_2
; %bb.1:
Lloh2:
	adrp	x8, _MMAL_SUCCESS@GOTPAGE
Lloh3:
	ldr	x8, [x8, _MMAL_SUCCESS@GOTPAGEOFF]
Lloh4:
	ldr	x22, [x8]
	b	LBB0_20
LBB0_2:
	bl	_vcos_getmicrosecs
	str	x0, [x19, #8]
	ldr	w8, [x19, #16]
Lloh5:
	adrp	x9, _MMAL_CONNECTION_FLAG_KEEP_BUFFER_REQUIREMENTS@GOTPAGE
Lloh6:
	ldr	x9, [x9, _MMAL_CONNECTION_FLAG_KEEP_BUFFER_REQUIREMENTS@GOTPAGEOFF]
Lloh7:
	ldr	w9, [x9]
	tst	w9, w8
	b.ne	LBB0_11
; %bb.3:
	ldr	x9, [x20, #40]
	cbz	x9, LBB0_5
; %bb.4:
	str	x9, [x20, #24]
LBB0_5:
	ldr	x9, [x20, #32]
	cbz	x9, LBB0_7
; %bb.6:
	str	x9, [x20, #16]
LBB0_7:
	ldr	x9, [x21, #40]
	cbz	x9, LBB0_9
; %bb.8:
	str	x9, [x21, #24]
LBB0_9:
	ldr	x9, [x21, #32]
	cbz	x9, LBB0_11
; %bb.10:
	str	x9, [x21, #16]
LBB0_11:
Lloh8:
	adrp	x9, _MMAL_CONNECTION_FLAG_TUNNELLING@GOTPAGE
Lloh9:
	ldr	x9, [x9, _MMAL_CONNECTION_FLAG_TUNNELLING@GOTPAGEOFF]
Lloh10:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_13
; %bb.12:
	mov	x0, x20
	mov	x1, #0
	bl	_mmal_port_enable
	mov	x22, x0
	cbnz	x0, LBB0_16
	b	LBB0_19
LBB0_13:
	ldr	x0, [x20, #24]
	ldr	x1, [x21, #24]
	bl	_MMAL_MAX
	mov	x22, x0
	ldr	x0, [x20, #16]
	ldr	x1, [x21, #16]
	bl	_MMAL_MAX
	stp	x0, x22, [x21, #16]
	stp	x0, x22, [x20, #16]
	ldr	w8, [x20]
Lloh11:
	adrp	x9, _MMAL_PORT_CAPABILITY_PASSTHROUGH@GOTPAGE
Lloh12:
	ldr	x9, [x9, _MMAL_PORT_CAPABILITY_PASSTHROUGH@GOTPAGEOFF]
Lloh13:
	ldr	w9, [x9]
	tst	w9, w8
	csel	x2, x0, xzr, eq
	ldr	x0, [x19, #24]
	mov	x1, x22
	bl	_mmal_pool_resize
Lloh14:
	adrp	x8, _MMAL_SUCCESS@GOTPAGE
Lloh15:
	ldr	x8, [x8, _MMAL_SUCCESS@GOTPAGEOFF]
Lloh16:
	ldr	x8, [x8]
	cmp	x0, x8
	b.ne	LBB0_17
; %bb.14:
	ldr	x8, [x20, #8]
Lloh17:
	adrp	x23, _MMAL_PORT_TYPE_CLOCK@GOTPAGE
Lloh18:
	ldr	x23, [x23, _MMAL_PORT_TYPE_CLOCK@GOTPAGEOFF]
Lloh19:
	adrp	x24, _mmal_connection_bh_clock_cb@GOTPAGE
Lloh20:
	ldr	x24, [x24, _mmal_connection_bh_clock_cb@GOTPAGEOFF]
	ldr	x9, [x23]
Lloh21:
	adrp	x10, _mmal_connection_bh_out_cb@GOTPAGE
Lloh22:
	ldr	x10, [x10, _mmal_connection_bh_out_cb@GOTPAGEOFF]
	cmp	x8, x9
	csel	x8, x24, x10, eq
	ldr	x1, [x8]
	mov	x0, x20
	bl	_mmal_port_enable
	cbz	x0, LBB0_21
; %bb.15:
	mov	x22, x0
LBB0_16:
Lloh23:
	adrp	x0, l_.str.1@PAGE
Lloh24:
	add	x0, x0, l_.str.1@PAGEOFF
	b	LBB0_18
LBB0_17:
	mov	x22, x0
Lloh25:
	adrp	x0, l_.str.2@PAGE
Lloh26:
	add	x0, x0, l_.str.2@PAGEOFF
LBB0_18:
	bl	_LOG_ERROR
LBB0_19:
	bl	_vcos_getmicrosecs
	ldr	x8, [x19, #8]
	sub	x8, x0, x8
	str	x8, [x19, #8]
Lloh27:
	adrp	x8, _MMAL_SUCCESS@GOTPAGE
Lloh28:
	ldr	x8, [x8, _MMAL_SUCCESS@GOTPAGEOFF]
Lloh29:
	ldr	x8, [x8]
	cmp	x22, x8
	cset	w8, eq
	str	w8, [x19]
LBB0_20:
	mov	x0, x22
	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_21:
	ldr	x8, [x21, #8]
	ldr	x9, [x23]
Lloh30:
	adrp	x10, _mmal_connection_bh_in_cb@GOTPAGE
Lloh31:
	ldr	x10, [x10, _mmal_connection_bh_in_cb@GOTPAGEOFF]
	cmp	x8, x9
	csel	x8, x24, x10, eq
	ldr	x1, [x8]
	mov	x0, x21
	bl	_mmal_port_enable
	cbz	x0, LBB0_23
; %bb.22:
	mov	x22, x0
Lloh32:
	adrp	x0, l_.str.3@PAGE
Lloh33:
	add	x0, x0, l_.str.3@PAGEOFF
	bl	_LOG_ERROR
	mov	x0, x20
	bl	_mmal_port_disable
	b	LBB0_19
LBB0_23:
	ldr	x8, [x20, #8]
	ldr	x9, [x23]
	cmp	x8, x9
	b.ne	LBB0_29
; %bb.24:
	ldr	x9, [x21, #8]
	cmp	x9, x8
	b.ne	LBB0_29
; %bb.25:
	ldr	x8, [x19, #24]
	ldr	w0, [x8]
	bl	_mmal_queue_get
	cbz	x0, LBB0_29
; %bb.26:
	mov	x1, x0
LBB0_27:                                ; =>This Inner Loop Header: Depth=1
	mov	x0, x20
	bl	_mmal_port_send_buffer
	ldr	x8, [x19, #24]
	ldr	w0, [x8]
	bl	_mmal_queue_get
	cbz	x0, LBB0_29
; %bb.28:                               ;   in Loop: Header=BB0_27 Depth=1
	mov	x1, x0
	mov	x0, x21
	bl	_mmal_port_send_buffer
	ldr	x8, [x19, #24]
	ldr	w0, [x8]
	bl	_mmal_queue_get
	mov	x1, x0
	mov	x22, #0
	cbnz	x0, LBB0_27
	b	LBB0_19
LBB0_29:
	mov	x22, #0
	b	LBB0_19
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpLdrGot	Lloh21, Lloh22
	.loh AdrpLdrGot	Lloh19, Lloh20
	.loh AdrpLdrGot	Lloh17, Lloh18
	.loh AdrpAdd	Lloh23, Lloh24
	.loh AdrpAdd	Lloh25, Lloh26
	.loh AdrpLdrGotLdr	Lloh27, Lloh28, Lloh29
	.loh AdrpLdrGot	Lloh30, Lloh31
	.loh AdrpAdd	Lloh32, Lloh33
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"%p, %s"

	.comm	_MMAL_SUCCESS,8,3               ; @MMAL_SUCCESS
	.comm	_MMAL_CONNECTION_FLAG_KEEP_BUFFER_REQUIREMENTS,4,2 ; @MMAL_CONNECTION_FLAG_KEEP_BUFFER_REQUIREMENTS
	.comm	_MMAL_CONNECTION_FLAG_TUNNELLING,4,2 ; @MMAL_CONNECTION_FLAG_TUNNELLING
l_.str.1:                               ; @.str.1
	.asciz	"output port couldn't be enabled"

	.comm	_MMAL_PORT_CAPABILITY_PASSTHROUGH,4,2 ; @MMAL_PORT_CAPABILITY_PASSTHROUGH
l_.str.2:                               ; @.str.2
	.asciz	"couldn't resize pool"

	.comm	_MMAL_PORT_TYPE_CLOCK,8,3       ; @MMAL_PORT_TYPE_CLOCK
	.comm	_mmal_connection_bh_clock_cb,8,3 ; @mmal_connection_bh_clock_cb
	.comm	_mmal_connection_bh_out_cb,8,3  ; @mmal_connection_bh_out_cb
	.comm	_mmal_connection_bh_in_cb,8,3   ; @mmal_connection_bh_in_cb
l_.str.3:                               ; @.str.3
	.asciz	"input port couldn't be enabled"

.subsections_via_symbols
