	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function init_caps
_init_caps:                             ## @init_caps
	.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	%r12
	pushq	%rbx
	subq	$16, %rsp
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rsi, %r14
	movl	%edi, %r15d
	xorl	%eax, %eax
	callq	_cap_init
	testq	%rax, %rax
	je	LBB0_1
## %bb.3:
	movq	%rax, %rbx
	movq	_CAP_PREAD@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_CAP_WRITE@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	_CAP_IOCTL@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	leaq	-36(%rbp), %r12
	movq	%r12, %rdi
	callq	_cap_rights_init
	movq	_checkfor@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	_keep@GOTPCREL(%rip), %rcx
	orq	(%rcx), %rax
	je	LBB0_4
## %bb.5:
	movq	_O_RDONLY@GOTPCREL(%rip), %rax
	jmp	LBB0_6
LBB0_4:
	movq	_O_RDWR@GOTPCREL(%rip), %rax
LBB0_6:
	movl	(%rax), %edx
	movq	_FA_OPEN@GOTPCREL(%rip), %rax
	movl	(%rax), %r9d
	movl	%r15d, %edi
	movq	%r14, %rsi
	xorl	%ecx, %ecx
	movq	%r12, %r8
	callq	_fileargs_init
	movq	_capfa@GOTPCREL(%rip), %rcx
	movq	%rax, (%rcx)
	testq	%rax, %rax
	je	LBB0_7
## %bb.8:
	xorl	%eax, %eax
	callq	_caph_cache_catpages
	xorl	%eax, %eax
	callq	_caph_cache_tzdata
	xorl	%eax, %eax
	callq	_caph_enter_casper
	testq	%rax, %rax
	jne	LBB0_9
## %bb.10:
	leaq	L_.str.3(%rip), %rsi
	movq	%rbx, %rdi
	callq	_cap_service_open
	movq	_capsyslog@GOTPCREL(%rip), %rcx
	movq	%rax, (%rcx)
	testq	%rax, %rax
	je	LBB0_11
## %bb.12:
	movq	%rbx, %rdi
	callq	_cap_close
	addq	$16, %rsp
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_1:
	movq	_LOG_ERR@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	L_.str(%rip), %rsi
	jmp	LBB0_2
LBB0_7:
	movq	_LOG_ERR@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	L_.str.1(%rip), %rsi
	jmp	LBB0_2
LBB0_9:
	movq	_LOG_ERR@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	L_.str.2(%rip), %rsi
	jmp	LBB0_2
LBB0_11:
	movq	_LOG_ERR@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	L_.str.4(%rip), %rsi
LBB0_2:
	callq	_logmsg
	movl	$1, %edi
	callq	_exit
	.cfi_endproc
                                        ## -- End function
	.comm	_LOG_ERR,4,2                    ## @LOG_ERR
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"cap_init(): %m"

	.comm	_CAP_PREAD,4,2                  ## @CAP_PREAD
	.comm	_CAP_WRITE,4,2                  ## @CAP_WRITE
	.comm	_CAP_IOCTL,4,2                  ## @CAP_IOCTL
	.comm	_checkfor,8,3                   ## @checkfor
	.comm	_keep,8,3                       ## @keep
	.comm	_O_RDONLY,4,2                   ## @O_RDONLY
	.comm	_O_RDWR,4,2                     ## @O_RDWR
	.comm	_FA_OPEN,4,2                    ## @FA_OPEN
	.comm	_capfa,8,3                      ## @capfa
L_.str.1:                               ## @.str.1
	.asciz	"fileargs_init(): %m"

L_.str.2:                               ## @.str.2
	.asciz	"caph_enter_casper(): %m"

L_.str.3:                               ## @.str.3
	.asciz	"system.syslog"

	.comm	_capsyslog,8,3                  ## @capsyslog
L_.str.4:                               ## @.str.4
	.asciz	"cap_service_open(system.syslog): %m"

	.no_dead_strip	_init_caps
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function init_caps
_init_caps:                             ; @init_caps
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #64
	.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
	mov	x20, x1
	mov	x21, x0
	bl	_cap_init
	cbz	x0, LBB0_5
; %bb.1:
	mov	x19, x0
Lloh0:
	adrp	x8, _CAP_PREAD@GOTPAGE
Lloh1:
	ldr	x8, [x8, _CAP_PREAD@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
Lloh3:
	adrp	x8, _CAP_WRITE@GOTPAGE
Lloh4:
	ldr	x8, [x8, _CAP_WRITE@GOTPAGEOFF]
Lloh5:
	ldr	w2, [x8]
Lloh6:
	adrp	x8, _CAP_IOCTL@GOTPAGE
Lloh7:
	ldr	x8, [x8, _CAP_IOCTL@GOTPAGEOFF]
Lloh8:
	ldr	w3, [x8]
	add	x0, sp, #12
	bl	_cap_rights_init
Lloh9:
	adrp	x8, _checkfor@GOTPAGE
Lloh10:
	ldr	x8, [x8, _checkfor@GOTPAGEOFF]
Lloh11:
	ldr	x8, [x8]
Lloh12:
	adrp	x9, _keep@GOTPAGE
Lloh13:
	ldr	x9, [x9, _keep@GOTPAGEOFF]
Lloh14:
	ldr	x9, [x9]
	orr	x8, x8, x9
Lloh15:
	adrp	x9, _O_RDONLY@GOTPAGE
Lloh16:
	ldr	x9, [x9, _O_RDONLY@GOTPAGEOFF]
Lloh17:
	adrp	x10, _O_RDWR@GOTPAGE
Lloh18:
	ldr	x10, [x10, _O_RDWR@GOTPAGEOFF]
	cmp	x8, #0
	csel	x8, x9, x10, ne
	ldr	w2, [x8]
Lloh19:
	adrp	x8, _FA_OPEN@GOTPAGE
Lloh20:
	ldr	x8, [x8, _FA_OPEN@GOTPAGEOFF]
Lloh21:
	ldr	w5, [x8]
	add	x4, sp, #12
	mov	x0, x21
	mov	x1, x20
	mov	w3, #0
	bl	_fileargs_init
Lloh22:
	adrp	x8, _capfa@GOTPAGE
Lloh23:
	ldr	x8, [x8, _capfa@GOTPAGEOFF]
Lloh24:
	str	x0, [x8]
	cbz	x0, LBB0_6
; %bb.2:
	bl	_caph_cache_catpages
	bl	_caph_cache_tzdata
	bl	_caph_enter_casper
	cbnz	x0, LBB0_7
; %bb.3:
Lloh25:
	adrp	x1, l_.str.3@PAGE
Lloh26:
	add	x1, x1, l_.str.3@PAGEOFF
	mov	x0, x19
	bl	_cap_service_open
Lloh27:
	adrp	x8, _capsyslog@GOTPAGE
Lloh28:
	ldr	x8, [x8, _capsyslog@GOTPAGEOFF]
Lloh29:
	str	x0, [x8]
	cbz	x0, LBB0_8
; %bb.4:
	mov	x0, x19
	bl	_cap_close
	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
	add	sp, sp, #64
	ret
LBB0_5:
Lloh30:
	adrp	x8, _LOG_ERR@GOTPAGE
Lloh31:
	ldr	x8, [x8, _LOG_ERR@GOTPAGEOFF]
Lloh32:
	ldr	w0, [x8]
Lloh33:
	adrp	x1, l_.str@PAGE
Lloh34:
	add	x1, x1, l_.str@PAGEOFF
	b	LBB0_9
LBB0_6:
Lloh35:
	adrp	x8, _LOG_ERR@GOTPAGE
Lloh36:
	ldr	x8, [x8, _LOG_ERR@GOTPAGEOFF]
Lloh37:
	ldr	w0, [x8]
Lloh38:
	adrp	x1, l_.str.1@PAGE
Lloh39:
	add	x1, x1, l_.str.1@PAGEOFF
	b	LBB0_9
LBB0_7:
Lloh40:
	adrp	x8, _LOG_ERR@GOTPAGE
Lloh41:
	ldr	x8, [x8, _LOG_ERR@GOTPAGEOFF]
Lloh42:
	ldr	w0, [x8]
Lloh43:
	adrp	x1, l_.str.2@PAGE
Lloh44:
	add	x1, x1, l_.str.2@PAGEOFF
	b	LBB0_9
LBB0_8:
Lloh45:
	adrp	x8, _LOG_ERR@GOTPAGE
Lloh46:
	ldr	x8, [x8, _LOG_ERR@GOTPAGEOFF]
Lloh47:
	ldr	w0, [x8]
Lloh48:
	adrp	x1, l_.str.4@PAGE
Lloh49:
	add	x1, x1, l_.str.4@PAGEOFF
LBB0_9:
	bl	_logmsg
	mov	w0, #1
	bl	_exit
	.loh AdrpLdrGotStr	Lloh22, Lloh23, Lloh24
	.loh AdrpLdrGotLdr	Lloh19, Lloh20, Lloh21
	.loh AdrpLdrGot	Lloh17, Lloh18
	.loh AdrpLdrGot	Lloh15, Lloh16
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotStr	Lloh27, Lloh28, Lloh29
	.loh AdrpAdd	Lloh25, Lloh26
	.loh AdrpAdd	Lloh33, Lloh34
	.loh AdrpLdrGotLdr	Lloh30, Lloh31, Lloh32
	.loh AdrpAdd	Lloh38, Lloh39
	.loh AdrpLdrGotLdr	Lloh35, Lloh36, Lloh37
	.loh AdrpAdd	Lloh43, Lloh44
	.loh AdrpLdrGotLdr	Lloh40, Lloh41, Lloh42
	.loh AdrpAdd	Lloh48, Lloh49
	.loh AdrpLdrGotLdr	Lloh45, Lloh46, Lloh47
	.cfi_endproc
                                        ; -- End function
	.comm	_LOG_ERR,4,2                    ; @LOG_ERR
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"cap_init(): %m"

	.comm	_CAP_PREAD,4,2                  ; @CAP_PREAD
	.comm	_CAP_WRITE,4,2                  ; @CAP_WRITE
	.comm	_CAP_IOCTL,4,2                  ; @CAP_IOCTL
	.comm	_checkfor,8,3                   ; @checkfor
	.comm	_keep,8,3                       ; @keep
	.comm	_O_RDONLY,4,2                   ; @O_RDONLY
	.comm	_O_RDWR,4,2                     ; @O_RDWR
	.comm	_FA_OPEN,4,2                    ; @FA_OPEN
	.comm	_capfa,8,3                      ; @capfa
l_.str.1:                               ; @.str.1
	.asciz	"fileargs_init(): %m"

l_.str.2:                               ; @.str.2
	.asciz	"caph_enter_casper(): %m"

l_.str.3:                               ; @.str.3
	.asciz	"system.syslog"

	.comm	_capsyslog,8,3                  ; @capsyslog
l_.str.4:                               ; @.str.4
	.asciz	"cap_service_open(system.syslog): %m"

	.no_dead_strip	_init_caps
.subsections_via_symbols
