	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_mux_chip_alloc                 ## -- Begin function mux_chip_alloc
	.p2align	4, 0x90
_mux_chip_alloc:                        ## @mux_chip_alloc
	.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	%rdx, %rbx
	movl	%esi, %r14d
	movq	%rdi, %r12
	testq	%rdi, %rdi
	sete	%al
	testl	%esi, %esi
	sete	%cl
	orb	%al, %cl
	movzbl	%cl, %edi
	callq	_WARN_ON
	testq	%rax, %rax
	je	LBB0_4
## %bb.1:
	movq	_EINVAL@GOTPCREL(%rip), %rax
LBB0_2:
	xorl	%edi, %edi
	subl	(%rax), %edi
LBB0_3:
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_ERR_PTR                        ## TAILCALL
LBB0_4:
	leal	(%r14,%r14,2), %eax
	leal	(%rbx,%rax,8), %edi
	addl	$56, %edi
	movq	_GFP_KERNEL@GOTPCREL(%rip), %r13
	movl	(%r13), %esi
	callq	_kzalloc
	testq	%rax, %rax
	je	LBB0_5
## %bb.6:
	movq	%rax, %r15
	addq	$56, %rax
	movq	%rax, 48(%r15)
	movq	%r15, %rbx
	addq	$16, %rbx
	movq	_mux_class@GOTPCREL(%rip), %rax
	movq	%rax, 40(%r15)
	movq	_mux_type@GOTPCREL(%rip), %rax
	movq	%rax, 32(%r15)
	movq	%r12, 24(%r15)
	movl	(%r12), %eax
	movl	%eax, 16(%r15)
	movq	%rbx, %rdi
	movq	%r15, %rsi
	callq	_dev_set_drvdata
	movl	(%r13), %ecx
	movq	_mux_ida@GOTPCREL(%rip), %rdi
	xorl	%esi, %esi
	xorl	%edx, %edx
	callq	_ida_simple_get
	movq	%rax, %r12
	movq	%rax, (%r15)
	testq	%rax, %rax
	js	LBB0_7
## %bb.8:
	leaq	L_.str.1(%rip), %rsi
	movq	%rbx, -48(%rbp)                 ## 8-byte Spill
	movq	%rbx, %rdi
	movl	%r12d, %edx
	callq	_dev_set_name
	movl	%r14d, 8(%r15)
	testl	%r14d, %r14d
	je	LBB0_11
## %bb.9:
	movl	%r14d, %eax
	shlq	$3, %rax
	leaq	(%rax,%rax,2), %r14
	xorl	%ebx, %ebx
	movq	_MUX_IDLE_AS_IS@GOTPCREL(%rip), %r13
	.p2align	4, 0x90
LBB0_10:                                ## =>This Inner Loop Header: Depth=1
	movq	48(%r15), %r12
	movq	%r15, 16(%r12,%rbx)
	leaq	(%r12,%rbx), %rdi
	addq	$8, %rdi
	movl	$1, %esi
	callq	_sema_init
	movq	_MUX_CACHE_UNKNOWN@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 4(%r12,%rbx)
	movl	(%r13), %eax
	movl	%eax, (%r12,%rbx)
	addq	$24, %rbx
	cmpq	%rbx, %r14
	jne	LBB0_10
LBB0_11:
	movq	-48(%rbp), %rdi                 ## 8-byte Reload
	callq	_device_initialize
	movq	%r15, %rax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_5:
	movq	_ENOMEM@GOTPCREL(%rip), %rax
	jmp	LBB0_2
LBB0_7:
	leaq	L_.str(%rip), %rdi
	callq	_pr_err
	movq	%r15, %rdi
	callq	_kfree
	movl	%r12d, %edi
	jmp	LBB0_3
	.cfi_endproc
                                        ## -- End function
	.comm	_EINVAL,4,2                     ## @EINVAL
	.comm	_GFP_KERNEL,4,2                 ## @GFP_KERNEL
	.comm	_ENOMEM,4,2                     ## @ENOMEM
	.comm	_mux_class,4,2                  ## @mux_class
	.comm	_mux_type,4,2                   ## @mux_type
	.comm	_mux_ida,4,2                    ## @mux_ida
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"muxchipX failed to get a device id\n"

L_.str.1:                               ## @.str.1
	.asciz	"muxchip%d"

	.comm	_MUX_CACHE_UNKNOWN,4,2          ## @MUX_CACHE_UNKNOWN
	.comm	_MUX_IDLE_AS_IS,4,2             ## @MUX_IDLE_AS_IS
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_mux_chip_alloc                 ; -- Begin function mux_chip_alloc
	.p2align	2
_mux_chip_alloc:                        ; @mux_chip_alloc
	.cfi_startproc
; %bb.0:
	stp	x26, x25, [sp, #-80]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 80
	stp	x24, x23, [sp, #16]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #32]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #48]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #64]             ; 16-byte Folded Spill
	add	x29, sp, #64
	.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	x19, x2
	mov	x21, x1
	mov	x22, x0
	cmp	x0, #0
	ccmp	w1, #0, #4, ne
	cset	w0, eq
	bl	_WARN_ON
	cbz	x0, LBB0_4
; %bb.1:
Lloh0:
	adrp	x8, _EINVAL@GOTPAGE
Lloh1:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
LBB0_2:
	ldr	w8, [x8]
	neg	w0, w8
LBB0_3:
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #32]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp], #80             ; 16-byte Folded Reload
	b	_ERR_PTR
LBB0_4:
	mov	w8, #24
	madd	w8, w21, w8, w19
	add	w0, w8, #56
Lloh2:
	adrp	x23, _GFP_KERNEL@GOTPAGE
Lloh3:
	ldr	x23, [x23, _GFP_KERNEL@GOTPAGEOFF]
	ldr	w1, [x23]
	bl	_kzalloc
	cbz	x0, LBB0_10
; %bb.5:
	mov	x19, x0
	add	x8, x0, #56
	ldr	w9, [x22]
	mov	x20, x0
	str	w9, [x20, #16]!
Lloh4:
	adrp	x9, _mux_class@GOTPAGE
Lloh5:
	ldr	x9, [x9, _mux_class@GOTPAGEOFF]
	stp	x9, x8, [x0, #40]
Lloh6:
	adrp	x8, _mux_type@GOTPAGE
Lloh7:
	ldr	x8, [x8, _mux_type@GOTPAGEOFF]
	stp	x22, x8, [x0, #24]
	mov	x0, x20
	mov	x1, x19
	bl	_dev_set_drvdata
	ldr	w3, [x23]
Lloh8:
	adrp	x0, _mux_ida@GOTPAGE
Lloh9:
	ldr	x0, [x0, _mux_ida@GOTPAGEOFF]
	mov	w1, #0
	mov	w2, #0
	bl	_ida_simple_get
	mov	x22, x0
	str	x0, [x19]
	tbnz	x0, #63, LBB0_11
; %bb.6:
Lloh10:
	adrp	x1, l_.str.1@PAGE
Lloh11:
	add	x1, x1, l_.str.1@PAGEOFF
	mov	x0, x20
	mov	x2, x22
	bl	_dev_set_name
	str	w21, [x19, #8]
	cbz	w21, LBB0_9
; %bb.7:
	mov	x22, #0
	mov	w8, w21
	add	x8, x8, x8, lsl #1
	lsl	x21, x8, #3
Lloh12:
	adrp	x23, _MUX_CACHE_UNKNOWN@GOTPAGE
Lloh13:
	ldr	x23, [x23, _MUX_CACHE_UNKNOWN@GOTPAGEOFF]
Lloh14:
	adrp	x24, _MUX_IDLE_AS_IS@GOTPAGE
Lloh15:
	ldr	x24, [x24, _MUX_IDLE_AS_IS@GOTPAGEOFF]
LBB0_8:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x8, [x19, #48]
	add	x25, x8, x22
	str	x19, [x25, #16]
	add	x0, x25, #8
	mov	w1, #1
	bl	_sema_init
	ldr	w8, [x23]
	str	w8, [x25, #4]
	ldr	w8, [x24]
	str	w8, [x25]
	add	x22, x22, #24
	cmp	x21, x22
	b.ne	LBB0_8
LBB0_9:
	mov	x0, x20
	bl	_device_initialize
	mov	x0, x19
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #32]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp], #80             ; 16-byte Folded Reload
	ret
LBB0_10:
Lloh16:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh17:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
	b	LBB0_2
LBB0_11:
Lloh18:
	adrp	x0, l_.str@PAGE
Lloh19:
	add	x0, x0, l_.str@PAGEOFF
	bl	_pr_err
	mov	x0, x19
	bl	_kfree
	mov	x0, x22
	b	LBB0_3
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh8, Lloh9
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh4, Lloh5
	.loh AdrpAdd	Lloh10, Lloh11
	.loh AdrpLdrGot	Lloh14, Lloh15
	.loh AdrpLdrGot	Lloh12, Lloh13
	.loh AdrpLdrGot	Lloh16, Lloh17
	.loh AdrpAdd	Lloh18, Lloh19
	.cfi_endproc
                                        ; -- End function
	.comm	_EINVAL,4,2                     ; @EINVAL
	.comm	_GFP_KERNEL,4,2                 ; @GFP_KERNEL
	.comm	_ENOMEM,4,2                     ; @ENOMEM
	.comm	_mux_class,4,2                  ; @mux_class
	.comm	_mux_type,4,2                   ; @mux_type
	.comm	_mux_ida,4,2                    ; @mux_ida
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"muxchipX failed to get a device id\n"

l_.str.1:                               ; @.str.1
	.asciz	"muxchip%d"

	.comm	_MUX_CACHE_UNKNOWN,4,2          ; @MUX_CACHE_UNKNOWN
	.comm	_MUX_IDLE_AS_IS,4,2             ; @MUX_IDLE_AS_IS
.subsections_via_symbols
