	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function hsc_probe
_hsc_probe:                             ## @hsc_probe
	.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	$40, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %r14
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -48(%rbp)
	movabsq	$8241983569076515688, %rax      ## imm = 0x726168635F697368
	movq	%rax, -64(%rbp)
	movb	$0, -56(%rbp)
	callq	_to_hsi_client
	movq	%rax, %r13
	movq	_GFP_KERNEL@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	$32, %edi
	callq	_kzalloc
	testq	%rax, %rax
	je	LBB0_1
## %bb.2:
	movq	%rax, %r15
	movq	%r13, %rdi
	callq	_hsi_id
	movl	%eax, %ebx
	movq	%r13, %rdi
	callq	_hsi_port_id
	movl	%ebx, %edi
	movl	%eax, %esi
	callq	_HSC_BASEMINOR
	movq	_hsc_major@GOTPCREL(%rip), %rbx
	movq	(%rbx), %rdi
	testq	%rdi, %rdi
	je	LBB0_3
## %bb.10:
	movl	%eax, %esi
	callq	_MKDEV
	movl	%eax, -68(%rbp)
	movq	_HSC_DEVS@GOTPCREL(%rip), %rcx
	movl	(%rcx), %esi
	leaq	-64(%rbp), %rdx
	movl	%eax, %edi
	callq	_register_chrdev_region
	movl	%eax, %r12d
	jmp	LBB0_11
LBB0_1:
	movq	_ENOMEM@GOTPCREL(%rip), %rax
	xorl	%r12d, %r12d
	subl	(%rax), %r12d
	jmp	LBB0_15
LBB0_3:
	movq	_HSC_DEVS@GOTPCREL(%rip), %rcx
	movl	(%rcx), %edx
	leaq	-68(%rbp), %rdi
	leaq	-64(%rbp), %rcx
	movl	%eax, %esi
	callq	_alloc_chrdev_region
	movl	%eax, %r12d
	testl	%eax, %eax
	je	LBB0_4
LBB0_11:
	testl	%r12d, %r12d
	jns	LBB0_5
## %bb.12:
	cmpq	$0, (%rbx)
	leaq	L_.str.2(%rip), %rax
	leaq	L_.str.1(%rip), %rdx
	cmoveq	%rax, %rdx
	leaq	L_.str(%rip), %rsi
	movq	%r14, %rdi
	movl	%r12d, %ecx
	xorl	%eax, %eax
	callq	_dev_err
	jmp	LBB0_14
LBB0_4:
	movl	-68(%rbp), %edi
	callq	_MAJOR
	movq	%rax, (%rbx)
LBB0_5:
	movq	%r14, -80(%rbp)                 ## 8-byte Spill
	movq	%r15, %rdi
	addq	$24, %rdi
	callq	_mutex_init
	movq	%r13, %rdi
	movq	%r15, %rsi
	callq	_hsi_client_set_drvdata
	movq	_hsc_fops@GOTPCREL(%rip), %rsi
	movq	%r15, %rdi
	callq	_cdev_init
	movq	_THIS_MODULE@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, (%r15)
	movq	%r13, 16(%r15)
	movq	_HSC_DEVS@GOTPCREL(%rip), %r14
	movl	(%r14), %edx
	testl	%edx, %edx
	jle	LBB0_8
## %bb.6:
	movq	8(%r15), %rbx
	xorl	%r12d, %r12d
	.p2align	4, 0x90
LBB0_7:                                 ## =>This Inner Loop Header: Depth=1
	movq	%rbx, %rdi
	callq	_hsc_channel_init
	movl	%r12d, (%rbx)
	movq	%r13, 16(%rbx)
	movq	%r15, 8(%rbx)
	incl	%r12d
	movl	(%r14), %edx
	addq	$24, %rbx
	cmpl	%edx, %r12d
	jl	LBB0_7
LBB0_8:
	movl	-68(%rbp), %esi
	movq	%r15, %rdi
	callq	_cdev_add
	testl	%eax, %eax
	je	LBB0_9
## %bb.13:
	movl	%eax, %r12d
	leaq	L_.str.3(%rip), %rsi
	movq	-80(%rbp), %rdi                 ## 8-byte Reload
	movl	%eax, %edx
	xorl	%eax, %eax
	callq	_dev_err
	movl	-68(%rbp), %edi
	movl	(%r14), %esi
	callq	_unregister_chrdev_region
LBB0_14:
	movq	%r15, %rdi
	callq	_kfree
	jmp	LBB0_15
LBB0_9:
	xorl	%r12d, %r12d
LBB0_15:
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-48(%rbp), %rax
	jne	LBB0_17
## %bb.16:
	movl	%r12d, %eax
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_17:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L___const.hsc_probe.devname:            ## @__const.hsc_probe.devname
	.asciz	"hsi_char"

	.comm	_GFP_KERNEL,4,2                 ## @GFP_KERNEL
	.comm	_ENOMEM,4,2                     ## @ENOMEM
	.comm	_hsc_major,8,3                  ## @hsc_major
	.comm	_HSC_DEVS,4,2                   ## @HSC_DEVS
L_.str:                                 ## @.str
	.asciz	"Device %s allocation failed %d\n"

L_.str.1:                               ## @.str.1
	.asciz	"minor"

L_.str.2:                               ## @.str.2
	.asciz	"major"

	.comm	_hsc_fops,4,2                   ## @hsc_fops
	.comm	_THIS_MODULE,4,2                ## @THIS_MODULE
L_.str.3:                               ## @.str.3
	.asciz	"Could not add char device %d\n"

	.no_dead_strip	_hsc_probe
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function hsc_probe
_hsc_probe:                             ; @hsc_probe
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #112
	.cfi_def_cfa_offset 112
	stp	x24, x23, [sp, #48]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #64]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #80]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #96]             ; 16-byte Folded Spill
	add	x29, sp, #96
	.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
Lloh0:
	adrp	x8, ___stack_chk_guard@GOTPAGE
Lloh1:
	ldr	x8, [x8, ___stack_chk_guard@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	str	x8, [sp, #40]
Lloh3:
	adrp	x8, l___const.hsc_probe.devname@PAGE
Lloh4:
	add	x8, x8, l___const.hsc_probe.devname@PAGEOFF
Lloh5:
	ldr	x8, [x8]
	str	x8, [sp, #24]
	strb	wzr, [sp, #32]
	bl	_to_hsi_client
	mov	x21, x0
Lloh6:
	adrp	x8, _GFP_KERNEL@GOTPAGE
Lloh7:
	ldr	x8, [x8, _GFP_KERNEL@GOTPAGEOFF]
Lloh8:
	ldr	w1, [x8]
	mov	w0, #32
	bl	_kzalloc
	cbz	x0, LBB0_3
; %bb.1:
	mov	x20, x0
	mov	x0, x21
	bl	_hsi_id
	mov	x22, x0
	mov	x0, x21
	bl	_hsi_port_id
	mov	x1, x0
	mov	x0, x22
	bl	_HSC_BASEMINOR
	mov	x1, x0
Lloh9:
	adrp	x24, _hsc_major@GOTPAGE
Lloh10:
	ldr	x24, [x24, _hsc_major@GOTPAGEOFF]
	ldr	x0, [x24]
Lloh11:
	adrp	x23, _HSC_DEVS@GOTPAGE
Lloh12:
	ldr	x23, [x23, _HSC_DEVS@GOTPAGEOFF]
	cbz	x0, LBB0_4
; %bb.2:
	bl	_MKDEV
	str	w0, [sp, #20]
	ldr	w1, [x23]
	add	x2, sp, #24
	bl	_register_chrdev_region
	mov	x22, x0
	b	LBB0_5
LBB0_3:
Lloh13:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh14:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
Lloh15:
	ldr	w8, [x8]
	neg	w22, w8
	b	LBB0_14
LBB0_4:
	ldr	w2, [x23]
	add	x0, sp, #20
	add	x3, sp, #24
	bl	_alloc_chrdev_region
	mov	x22, x0
	cbz	w0, LBB0_7
LBB0_5:
	tbz	w22, #31, LBB0_8
; %bb.6:
	ldr	x8, [x24]
Lloh16:
	adrp	x9, l_.str.1@PAGE
Lloh17:
	add	x9, x9, l_.str.1@PAGEOFF
Lloh18:
	adrp	x10, l_.str.2@PAGE
Lloh19:
	add	x10, x10, l_.str.2@PAGEOFF
	cmp	x8, #0
	csel	x8, x10, x9, eq
	stp	x8, x22, [sp]
Lloh20:
	adrp	x1, l_.str@PAGE
Lloh21:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x19
	bl	_dev_err
	b	LBB0_13
LBB0_7:
	ldr	w0, [sp, #20]
	bl	_MAJOR
	str	x0, [x24]
LBB0_8:
	add	x0, x20, #24
	bl	_mutex_init
	mov	x0, x21
	mov	x1, x20
	bl	_hsi_client_set_drvdata
Lloh22:
	adrp	x1, _hsc_fops@GOTPAGE
Lloh23:
	ldr	x1, [x1, _hsc_fops@GOTPAGEOFF]
	mov	x0, x20
	bl	_cdev_init
Lloh24:
	adrp	x8, _THIS_MODULE@GOTPAGE
Lloh25:
	ldr	x8, [x8, _THIS_MODULE@GOTPAGEOFF]
Lloh26:
	ldr	w8, [x8]
	str	w8, [x20]
	str	x21, [x20, #16]
	ldr	w2, [x23]
	cmp	w2, #1
	b.lt	LBB0_11
; %bb.9:
	mov	w24, #0
	ldr	x22, [x20, #8]
LBB0_10:                                ; =>This Inner Loop Header: Depth=1
	mov	x0, x22
	bl	_hsc_channel_init
	str	w24, [x22]
	stp	x20, x21, [x22, #8]
	add	w24, w24, #1
	ldr	w2, [x23]
	add	x22, x22, #24
	cmp	w24, w2
	b.lt	LBB0_10
LBB0_11:
	ldr	w1, [sp, #20]
	mov	x0, x20
	bl	_cdev_add
	mov	x22, x0
	cbz	w0, LBB0_14
; %bb.12:
	str	x22, [sp]
Lloh27:
	adrp	x1, l_.str.3@PAGE
Lloh28:
	add	x1, x1, l_.str.3@PAGEOFF
	mov	x0, x19
	bl	_dev_err
	ldr	w0, [sp, #20]
	ldr	w1, [x23]
	bl	_unregister_chrdev_region
                                        ; kill: def $w22 killed $w22 killed $x22 def $x22
LBB0_13:
	mov	x0, x20
	bl	_kfree
LBB0_14:
	ldr	x8, [sp, #40]
Lloh29:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh30:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh31:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_16
; %bb.15:
	mov	x0, x22
	ldp	x29, x30, [sp, #96]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #80]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #64]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #48]             ; 16-byte Folded Reload
	add	sp, sp, #112
	ret
LBB0_16:
	bl	___stack_chk_fail
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpAddLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh11, Lloh12
	.loh AdrpLdrGot	Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh13, Lloh14, Lloh15
	.loh AdrpAdd	Lloh20, Lloh21
	.loh AdrpAdd	Lloh18, Lloh19
	.loh AdrpAdd	Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh24, Lloh25, Lloh26
	.loh AdrpLdrGot	Lloh22, Lloh23
	.loh AdrpAdd	Lloh27, Lloh28
	.loh AdrpLdrGotLdr	Lloh29, Lloh30, Lloh31
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l___const.hsc_probe.devname:            ; @__const.hsc_probe.devname
	.asciz	"hsi_char"

	.comm	_GFP_KERNEL,4,2                 ; @GFP_KERNEL
	.comm	_ENOMEM,4,2                     ; @ENOMEM
	.comm	_hsc_major,8,3                  ; @hsc_major
	.comm	_HSC_DEVS,4,2                   ; @HSC_DEVS
l_.str:                                 ; @.str
	.asciz	"Device %s allocation failed %d\n"

l_.str.1:                               ; @.str.1
	.asciz	"minor"

l_.str.2:                               ; @.str.2
	.asciz	"major"

	.comm	_hsc_fops,4,2                   ; @hsc_fops
	.comm	_THIS_MODULE,4,2                ; @THIS_MODULE
l_.str.3:                               ; @.str.3
	.asciz	"Could not add char device %d\n"

	.no_dead_strip	_hsc_probe
.subsections_via_symbols
