	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function snd_pcm_oss_open
_snd_pcm_oss_open:                      ## @snd_pcm_oss_open
	.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	$72, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rsi, %r14
	movq	%rdi, %rbx
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -48(%rbp)
	callq	_nonseekable_open
	testl	%eax, %eax
	js	LBB0_11
## %bb.1:
	movq	%rbx, %rdi
	callq	_iminor
	movq	_SNDRV_OSS_DEVICE_TYPE_PCM@GOTPCREL(%rip), %rcx
	movl	(%rcx), %esi
	movl	%eax, %edi
	callq	_snd_lookup_oss_minor_data
	testq	%rax, %rax
	je	LBB0_12
## %bb.2:
	movq	%rax, %r15
	movq	(%rax), %rdi
	movq	%r14, %rsi
	callq	_snd_card_file_add
	testl	%eax, %eax
	js	LBB0_11
## %bb.3:
	movq	(%r15), %rax
	movl	(%rax), %edi
	callq	_try_module_get
	testl	%eax, %eax
	je	LBB0_14
## %bb.4:
	movq	_current@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	-80(%rbp), %rsi
	movl	$32, %edx
	callq	_snd_task_name
	testq	%rax, %rax
	js	LBB0_15
## %bb.5:
	leaq	-88(%rbp), %rdi
	xorl	%esi, %esi
	movl	$8, %edx
	callq	_memset
	movl	(%r14), %eax
	movq	_FMODE_WRITE@GOTPCREL(%rip), %rcx
	testl	%eax, (%rcx)
	je	LBB0_7
## %bb.6:
	movq	_SNDRV_PCM_STREAM_PLAYBACK@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	-80(%rbp), %rdx
	leaq	-88(%rbp), %rcx
	movq	%r15, %rdi
	callq	_snd_pcm_oss_look_for_setup
	movl	(%r14), %eax
LBB0_7:
	movq	_FMODE_READ@GOTPCREL(%rip), %rcx
	testl	%eax, (%rcx)
	je	LBB0_9
## %bb.8:
	movq	_SNDRV_PCM_STREAM_CAPTURE@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	-84(%rbp), %rcx
	leaq	-80(%rbp), %rdx
	movq	%r15, %rdi
	callq	_snd_pcm_oss_look_for_setup
LBB0_9:
	movq	_O_NONBLOCK@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	xorl	%ecx, %ecx
	andl	4(%r14), %eax
	setne	%al
	jne	LBB0_16
## %bb.10:
	movq	_nonblock_open@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, -92(%rbp)                 ## 4-byte Spill
	jmp	LBB0_17
LBB0_11:
	movl	%eax, %r12d
	jmp	LBB0_30
LBB0_12:
	movq	_ENODEV@GOTPCREL(%rip), %rax
	xorl	%r12d, %r12d
	subl	(%rax), %r12d
	jmp	LBB0_30
LBB0_14:
	movq	_EFAULT@GOTPCREL(%rip), %rax
	xorl	%r12d, %r12d
	subl	(%rax), %r12d
	jmp	LBB0_29
LBB0_15:
	movq	_EFAULT@GOTPCREL(%rip), %rax
	xorl	%r12d, %r12d
	subl	(%rax), %r12d
	jmp	LBB0_28
LBB0_16:
	movb	%al, %cl
	movl	%ecx, -92(%rbp)                 ## 4-byte Spill
LBB0_17:
	movq	_current@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	-96(%rbp), %r12
	movq	%r12, %rdi
	callq	_init_waitqueue_entry
	leaq	12(%r15), %rdi
	movq	%rdi, -104(%rbp)                ## 8-byte Spill
	movq	%r12, %rsi
	callq	_add_wait_queue
	movq	%r15, %r13
	addq	$8, %r13
	movq	%r13, %rdi
	callq	_mutex_lock
	.p2align	4, 0x90
LBB0_18:                                ## =>This Inner Loop Header: Depth=1
	movq	%rbx, %rdi
	callq	_iminor
	movq	%r14, %rdi
	movq	%r15, %rsi
	leaq	-112(%rbp), %rdx
	movl	%eax, %ecx
	leaq	-88(%rbp), %r8
	callq	_snd_pcm_oss_open_file
	movl	%eax, %r12d
	testl	%eax, %eax
	jns	LBB0_27
## %bb.19:                              ##   in Loop: Header=BB0_18 Depth=1
	movq	_EAGAIN@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	addl	%r12d, %eax
	jne	LBB0_27
## %bb.20:                              ##   in Loop: Header=BB0_18 Depth=1
	cmpl	$0, -92(%rbp)                   ## 4-byte Folded Reload
	jne	LBB0_24
## %bb.21:                              ##   in Loop: Header=BB0_18 Depth=1
	movq	_TASK_INTERRUPTIBLE@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_set_current_state
	movq	%r13, %rdi
	callq	_mutex_unlock
	xorl	%eax, %eax
	callq	_schedule
	movq	%r13, %rdi
	callq	_mutex_lock
	movq	(%r15), %rax
	cmpq	$0, 8(%rax)
	jne	LBB0_25
## %bb.22:                              ##   in Loop: Header=BB0_18 Depth=1
	movq	_current@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_signal_pending
	testq	%rax, %rax
	je	LBB0_18
## %bb.23:
	movq	_ERESTARTSYS@GOTPCREL(%rip), %rax
	jmp	LBB0_26
LBB0_24:
	movq	_EBUSY@GOTPCREL(%rip), %rax
	jmp	LBB0_26
LBB0_25:
	movq	_ENODEV@GOTPCREL(%rip), %rax
LBB0_26:
	xorl	%r12d, %r12d
	subl	(%rax), %r12d
LBB0_27:
	leaq	-96(%rbp), %rsi
	movq	-104(%rbp), %rdi                ## 8-byte Reload
	callq	_remove_wait_queue
	movq	%r13, %rdi
	callq	_mutex_unlock
	testl	%r12d, %r12d
	jns	LBB0_30
LBB0_28:
	movq	(%r15), %rax
	movl	(%rax), %edi
	callq	_module_put
LBB0_29:
	movq	(%r15), %rdi
	movq	%r14, %rsi
	callq	_snd_card_file_remove
LBB0_30:
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-48(%rbp), %rax
	jne	LBB0_32
## %bb.31:
	movl	%r12d, %eax
	addq	$72, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_32:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.comm	_SNDRV_OSS_DEVICE_TYPE_PCM,4,2  ## @SNDRV_OSS_DEVICE_TYPE_PCM
	.comm	_ENODEV,4,2                     ## @ENODEV
	.comm	_EFAULT,4,2                     ## @EFAULT
	.comm	_current,4,2                    ## @current
	.comm	_FMODE_WRITE,4,2                ## @FMODE_WRITE
	.comm	_SNDRV_PCM_STREAM_PLAYBACK,4,2  ## @SNDRV_PCM_STREAM_PLAYBACK
	.comm	_FMODE_READ,4,2                 ## @FMODE_READ
	.comm	_SNDRV_PCM_STREAM_CAPTURE,4,2   ## @SNDRV_PCM_STREAM_CAPTURE
	.comm	_O_NONBLOCK,4,2                 ## @O_NONBLOCK
	.comm	_nonblock_open,4,2              ## @nonblock_open
	.comm	_EAGAIN,4,2                     ## @EAGAIN
	.comm	_EBUSY,4,2                      ## @EBUSY
	.comm	_TASK_INTERRUPTIBLE,4,2         ## @TASK_INTERRUPTIBLE
	.comm	_ERESTARTSYS,4,2                ## @ERESTARTSYS
	.no_dead_strip	_snd_pcm_oss_open
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function snd_pcm_oss_open
_snd_pcm_oss_open:                      ; @snd_pcm_oss_open
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #160
	.cfi_def_cfa_offset 160
	stp	x28, x27, [sp, #64]             ; 16-byte Folded Spill
	stp	x26, x25, [sp, #80]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #96]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #112]            ; 16-byte Folded Spill
	stp	x20, x19, [sp, #128]            ; 16-byte Folded Spill
	stp	x29, x30, [sp, #144]            ; 16-byte Folded Spill
	add	x29, sp, #144
	.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
	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]
	str	x8, [sp, #56]
	bl	_nonseekable_open
	tbnz	w0, #31, LBB0_16
; %bb.1:
	mov	x0, x21
	bl	_iminor
Lloh3:
	adrp	x8, _SNDRV_OSS_DEVICE_TYPE_PCM@GOTPAGE
Lloh4:
	ldr	x8, [x8, _SNDRV_OSS_DEVICE_TYPE_PCM@GOTPAGEOFF]
Lloh5:
	ldr	w1, [x8]
	bl	_snd_lookup_oss_minor_data
	cbz	x0, LBB0_17
; %bb.2:
	mov	x20, x0
	ldr	x0, [x0]
	mov	x1, x19
	bl	_snd_card_file_add
	tbnz	w0, #31, LBB0_16
; %bb.3:
	ldr	x8, [x20]
	ldr	w0, [x8]
	bl	_try_module_get
	cbz	w0, LBB0_18
; %bb.4:
Lloh6:
	adrp	x25, _current@GOTPAGE
Lloh7:
	ldr	x25, [x25, _current@GOTPAGEOFF]
	ldr	w0, [x25]
	add	x1, sp, #24
	mov	w2, #32
	bl	_snd_task_name
	tbnz	x0, #63, LBB0_19
; %bb.5:
	add	x0, sp, #16
	mov	w1, #0
	mov	w2, #8
	bl	_memset
	ldr	w8, [x19]
Lloh8:
	adrp	x9, _FMODE_WRITE@GOTPAGE
Lloh9:
	ldr	x9, [x9, _FMODE_WRITE@GOTPAGEOFF]
Lloh10:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_7
; %bb.6:
Lloh11:
	adrp	x8, _SNDRV_PCM_STREAM_PLAYBACK@GOTPAGE
Lloh12:
	ldr	x8, [x8, _SNDRV_PCM_STREAM_PLAYBACK@GOTPAGEOFF]
Lloh13:
	ldr	w1, [x8]
	add	x2, sp, #24
	add	x3, sp, #16
	mov	x0, x20
	bl	_snd_pcm_oss_look_for_setup
	ldr	w8, [x19]
LBB0_7:
Lloh14:
	adrp	x9, _FMODE_READ@GOTPAGE
Lloh15:
	ldr	x9, [x9, _FMODE_READ@GOTPAGEOFF]
Lloh16:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_9
; %bb.8:
Lloh17:
	adrp	x8, _SNDRV_PCM_STREAM_CAPTURE@GOTPAGE
Lloh18:
	ldr	x8, [x8, _SNDRV_PCM_STREAM_CAPTURE@GOTPAGEOFF]
Lloh19:
	ldr	w1, [x8]
	add	x8, sp, #16
	orr	x3, x8, #0x4
	add	x2, sp, #24
	mov	x0, x20
	bl	_snd_pcm_oss_look_for_setup
LBB0_9:
	ldr	w8, [x19, #4]
Lloh20:
	adrp	x9, _O_NONBLOCK@GOTPAGE
Lloh21:
	ldr	x9, [x9, _O_NONBLOCK@GOTPAGEOFF]
Lloh22:
	ldr	w9, [x9]
	tst	w9, w8
	cset	w8, ne
Lloh23:
	adrp	x9, _nonblock_open@GOTPAGE
Lloh24:
	ldr	x9, [x9, _nonblock_open@GOTPAGEOFF]
Lloh25:
	ldr	w9, [x9]
	csel	w26, w8, w9, ne
	ldr	w1, [x25]
	add	x0, sp, #4
	bl	_init_waitqueue_entry
	add	x22, x20, #12
	add	x1, sp, #4
	mov	x0, x22
	bl	_add_wait_queue
	add	x23, x20, #8
	mov	x0, x23
	bl	_mutex_lock
Lloh26:
	adrp	x27, _EAGAIN@GOTPAGE
Lloh27:
	ldr	x27, [x27, _EAGAIN@GOTPAGEOFF]
Lloh28:
	adrp	x28, _TASK_INTERRUPTIBLE@GOTPAGE
Lloh29:
	ldr	x28, [x28, _TASK_INTERRUPTIBLE@GOTPAGEOFF]
LBB0_10:                                ; =>This Inner Loop Header: Depth=1
	mov	x0, x21
	bl	_iminor
	mov	x3, x0
	add	x2, sp, #8
	add	x4, sp, #16
	mov	x0, x19
	mov	x1, x20
	bl	_snd_pcm_oss_open_file
	mov	x24, x0
	tbz	w0, #31, LBB0_23
; %bb.11:                               ;   in Loop: Header=BB0_10 Depth=1
	ldr	w8, [x27]
	cmn	w24, w8
	b.ne	LBB0_23
; %bb.12:                               ;   in Loop: Header=BB0_10 Depth=1
	cbnz	w26, LBB0_20
; %bb.13:                               ;   in Loop: Header=BB0_10 Depth=1
	ldr	w0, [x28]
	bl	_set_current_state
	mov	x0, x23
	bl	_mutex_unlock
	bl	_schedule
	mov	x0, x23
	bl	_mutex_lock
	ldr	x8, [x20]
	ldr	x8, [x8, #8]
	cbnz	x8, LBB0_21
; %bb.14:                               ;   in Loop: Header=BB0_10 Depth=1
	ldr	w0, [x25]
	bl	_signal_pending
	cbz	x0, LBB0_10
; %bb.15:
Lloh30:
	adrp	x8, _ERESTARTSYS@GOTPAGE
Lloh31:
	ldr	x8, [x8, _ERESTARTSYS@GOTPAGEOFF]
	b	LBB0_22
LBB0_16:
	mov	x24, x0
	b	LBB0_26
LBB0_17:
Lloh32:
	adrp	x8, _ENODEV@GOTPAGE
Lloh33:
	ldr	x8, [x8, _ENODEV@GOTPAGEOFF]
Lloh34:
	ldr	w8, [x8]
	neg	w24, w8
	b	LBB0_26
LBB0_18:
Lloh35:
	adrp	x8, _EFAULT@GOTPAGE
Lloh36:
	ldr	x8, [x8, _EFAULT@GOTPAGEOFF]
Lloh37:
	ldr	w8, [x8]
	neg	w24, w8
	b	LBB0_25
LBB0_19:
Lloh38:
	adrp	x8, _EFAULT@GOTPAGE
Lloh39:
	ldr	x8, [x8, _EFAULT@GOTPAGEOFF]
Lloh40:
	ldr	w8, [x8]
	neg	w24, w8
	b	LBB0_24
LBB0_20:
Lloh41:
	adrp	x8, _EBUSY@GOTPAGE
Lloh42:
	ldr	x8, [x8, _EBUSY@GOTPAGEOFF]
	b	LBB0_22
LBB0_21:
Lloh43:
	adrp	x8, _ENODEV@GOTPAGE
Lloh44:
	ldr	x8, [x8, _ENODEV@GOTPAGEOFF]
LBB0_22:
	ldr	w8, [x8]
	neg	w24, w8
LBB0_23:
	add	x1, sp, #4
	mov	x0, x22
	bl	_remove_wait_queue
	mov	x0, x23
	bl	_mutex_unlock
	tbz	w24, #31, LBB0_26
LBB0_24:
	ldr	x8, [x20]
	ldr	w0, [x8]
	bl	_module_put
LBB0_25:
	ldr	x0, [x20]
	mov	x1, x19
	bl	_snd_card_file_remove
LBB0_26:
	ldr	x8, [sp, #56]
Lloh45:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh46:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh47:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_28
; %bb.27:
	mov	x0, x24
	ldp	x29, x30, [sp, #144]            ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #128]            ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #112]            ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #96]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #80]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp, #64]             ; 16-byte Folded Reload
	add	sp, sp, #160
	ret
LBB0_28:
	bl	___stack_chk_fail
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpLdrGotLdr	Lloh17, Lloh18, Lloh19
	.loh AdrpLdrGot	Lloh28, Lloh29
	.loh AdrpLdrGot	Lloh26, Lloh27
	.loh AdrpLdrGotLdr	Lloh23, Lloh24, Lloh25
	.loh AdrpLdrGotLdr	Lloh20, Lloh21, Lloh22
	.loh AdrpLdrGot	Lloh30, Lloh31
	.loh AdrpLdrGotLdr	Lloh32, Lloh33, Lloh34
	.loh AdrpLdrGotLdr	Lloh35, Lloh36, Lloh37
	.loh AdrpLdrGotLdr	Lloh38, Lloh39, Lloh40
	.loh AdrpLdrGot	Lloh41, Lloh42
	.loh AdrpLdrGot	Lloh43, Lloh44
	.loh AdrpLdrGotLdr	Lloh45, Lloh46, Lloh47
	.cfi_endproc
                                        ; -- End function
	.comm	_SNDRV_OSS_DEVICE_TYPE_PCM,4,2  ; @SNDRV_OSS_DEVICE_TYPE_PCM
	.comm	_ENODEV,4,2                     ; @ENODEV
	.comm	_EFAULT,4,2                     ; @EFAULT
	.comm	_current,4,2                    ; @current
	.comm	_FMODE_WRITE,4,2                ; @FMODE_WRITE
	.comm	_SNDRV_PCM_STREAM_PLAYBACK,4,2  ; @SNDRV_PCM_STREAM_PLAYBACK
	.comm	_FMODE_READ,4,2                 ; @FMODE_READ
	.comm	_SNDRV_PCM_STREAM_CAPTURE,4,2   ; @SNDRV_PCM_STREAM_CAPTURE
	.comm	_O_NONBLOCK,4,2                 ; @O_NONBLOCK
	.comm	_nonblock_open,4,2              ; @nonblock_open
	.comm	_EAGAIN,4,2                     ; @EAGAIN
	.comm	_EBUSY,4,2                      ; @EBUSY
	.comm	_TASK_INTERRUPTIBLE,4,2         ; @TASK_INTERRUPTIBLE
	.comm	_ERESTARTSYS,4,2                ; @ERESTARTSYS
	.no_dead_strip	_snd_pcm_oss_open
.subsections_via_symbols
