	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_gnss_allocate_device           ## -- Begin function gnss_allocate_device
	.p2align	4, 0x90
_gnss_allocate_device:                  ## @gnss_allocate_device
	.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, %r15
	movq	_GFP_KERNEL@GOTPCREL(%rip), %r13
	movl	(%r13), %esi
	movl	$72, %edi
	callq	_kzalloc
	testq	%rax, %rax
	je	LBB0_7
## %bb.1:
	movq	%rax, %rbx
	movq	_GNSS_MINORS@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movl	(%r13), %ecx
	movq	_gnss_minors@GOTPCREL(%rip), %rdi
	xorl	%esi, %esi
	callq	_ida_simple_get
	testl	%eax, %eax
	js	LBB0_2
## %bb.3:
	movl	%eax, %r12d
	movl	%eax, (%rbx)
	leaq	40(%rbx), %r14
	movq	%r14, %rdi
	callq	_device_initialize
	movq	_gnss_first@GOTPCREL(%rip), %rax
	movl	%r12d, %ecx
	addq	(%rax), %rcx
	movq	%rcx, 64(%rbx)
	movq	_gnss_class@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 56(%rbx)
	movq	%r15, 48(%rbx)
	movq	_gnss_device_release@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 40(%rbx)
	movq	%r14, %rdi
	movq	%rbx, %rsi
	callq	_dev_set_drvdata
	leaq	L_.str(%rip), %rsi
	movq	%r14, %rdi
	movl	%r12d, %edx
	callq	_dev_set_name
	leaq	32(%rbx), %rdi
	callq	_init_rwsem
	leaq	28(%rbx), %rdi
	callq	_mutex_init
	leaq	24(%rbx), %rdi
	callq	_mutex_init
	leaq	20(%rbx), %rdi
	callq	_init_waitqueue_head
	leaq	16(%rbx), %rdi
	movq	_GNSS_READ_FIFO_SIZE@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	(%r13), %edx
	callq	_kfifo_alloc
	testl	%eax, %eax
	je	LBB0_4
LBB0_6:
	movq	%r14, %rdi
	callq	_put_device
	jmp	LBB0_7
LBB0_2:
	movq	%rbx, %rdi
	callq	_kfree
LBB0_7:
	xorl	%ebx, %ebx
LBB0_8:
	movq	%rbx, %rax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_4:
	movq	_GNSS_WRITE_BUF_SIZE@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movl	(%r13), %esi
	callq	_kzalloc
	movq	%rax, 8(%rbx)
	testq	%rax, %rax
	je	LBB0_6
## %bb.5:
	movq	%rbx, %rdi
	addq	$4, %rdi
	movq	_gnss_fops@GOTPCREL(%rip), %rsi
	callq	_cdev_init
	movq	_THIS_MODULE@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 4(%rbx)
	jmp	LBB0_8
	.cfi_endproc
                                        ## -- End function
	.comm	_GFP_KERNEL,4,2                 ## @GFP_KERNEL
	.comm	_gnss_minors,4,2                ## @gnss_minors
	.comm	_GNSS_MINORS,4,2                ## @GNSS_MINORS
	.comm	_gnss_first,8,3                 ## @gnss_first
	.comm	_gnss_class,4,2                 ## @gnss_class
	.comm	_gnss_device_release,4,2        ## @gnss_device_release
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"gnss%d"

	.comm	_GNSS_READ_FIFO_SIZE,4,2        ## @GNSS_READ_FIFO_SIZE
	.comm	_GNSS_WRITE_BUF_SIZE,4,2        ## @GNSS_WRITE_BUF_SIZE
	.comm	_gnss_fops,4,2                  ## @gnss_fops
	.comm	_THIS_MODULE,4,2                ## @THIS_MODULE
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_gnss_allocate_device           ; -- Begin function gnss_allocate_device
	.p2align	2
_gnss_allocate_device:                  ; @gnss_allocate_device
	.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	x21, x0
Lloh0:
	adrp	x23, _GFP_KERNEL@GOTPAGE
Lloh1:
	ldr	x23, [x23, _GFP_KERNEL@GOTPAGEOFF]
	ldr	w1, [x23]
	mov	w0, #72
	bl	_kzalloc
	mov	x19, x0
	cbz	x0, LBB0_6
; %bb.1:
Lloh2:
	adrp	x8, _GNSS_MINORS@GOTPAGE
Lloh3:
	ldr	x8, [x8, _GNSS_MINORS@GOTPAGEOFF]
Lloh4:
	ldr	w2, [x8]
	ldr	w3, [x23]
Lloh5:
	adrp	x0, _gnss_minors@GOTPAGE
Lloh6:
	ldr	x0, [x0, _gnss_minors@GOTPAGEOFF]
	mov	w1, #0
	bl	_ida_simple_get
	tbnz	w0, #31, LBB0_4
; %bb.2:
	mov	x22, x0
	str	w0, [x19]
	add	x20, x19, #40
	mov	x0, x20
	bl	_device_initialize
Lloh7:
	adrp	x8, _gnss_first@GOTPAGE
Lloh8:
	ldr	x8, [x8, _gnss_first@GOTPAGEOFF]
Lloh9:
	ldr	x8, [x8]
	add	x8, x8, w22, uxtw
	str	x8, [x19, #64]
Lloh10:
	adrp	x8, _gnss_class@GOTPAGE
Lloh11:
	ldr	x8, [x8, _gnss_class@GOTPAGEOFF]
Lloh12:
	ldr	w8, [x8]
	str	w8, [x19, #56]
	str	x21, [x19, #48]
Lloh13:
	adrp	x8, _gnss_device_release@GOTPAGE
Lloh14:
	ldr	x8, [x8, _gnss_device_release@GOTPAGEOFF]
Lloh15:
	ldr	w8, [x8]
	str	w8, [x19, #40]
	mov	x0, x20
	mov	x1, x19
	bl	_dev_set_drvdata
Lloh16:
	adrp	x1, l_.str@PAGE
Lloh17:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x20
	mov	x2, x22
	bl	_dev_set_name
	add	x0, x19, #32
	bl	_init_rwsem
	add	x0, x19, #28
	bl	_mutex_init
	add	x0, x19, #24
	bl	_mutex_init
	add	x0, x19, #20
	bl	_init_waitqueue_head
	add	x0, x19, #16
Lloh18:
	adrp	x8, _GNSS_READ_FIFO_SIZE@GOTPAGE
Lloh19:
	ldr	x8, [x8, _GNSS_READ_FIFO_SIZE@GOTPAGEOFF]
Lloh20:
	ldr	w1, [x8]
	ldr	w2, [x23]
	bl	_kfifo_alloc
	cbz	w0, LBB0_7
LBB0_3:
	mov	x0, x20
	bl	_put_device
	b	LBB0_5
LBB0_4:
	mov	x0, x19
	bl	_kfree
LBB0_5:
	mov	x19, #0
LBB0_6:
	mov	x0, x19
	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_7:
Lloh21:
	adrp	x8, _GNSS_WRITE_BUF_SIZE@GOTPAGE
Lloh22:
	ldr	x8, [x8, _GNSS_WRITE_BUF_SIZE@GOTPAGEOFF]
Lloh23:
	ldr	w0, [x8]
	ldr	w1, [x23]
	bl	_kzalloc
	str	x0, [x19, #8]
	cbz	x0, LBB0_3
; %bb.8:
	add	x0, x19, #4
Lloh24:
	adrp	x1, _gnss_fops@GOTPAGE
Lloh25:
	ldr	x1, [x1, _gnss_fops@GOTPAGEOFF]
	bl	_cdev_init
Lloh26:
	adrp	x8, _THIS_MODULE@GOTPAGE
Lloh27:
	ldr	x8, [x8, _THIS_MODULE@GOTPAGEOFF]
Lloh28:
	ldr	w8, [x8]
	str	w8, [x19, #4]
	b	LBB0_6
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.loh AdrpAdd	Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh13, Lloh14, Lloh15
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh12
	.loh AdrpLdrGotLdr	Lloh7, Lloh8, Lloh9
	.loh AdrpLdrGotLdr	Lloh21, Lloh22, Lloh23
	.loh AdrpLdrGotLdr	Lloh26, Lloh27, Lloh28
	.loh AdrpLdrGot	Lloh24, Lloh25
	.cfi_endproc
                                        ; -- End function
	.comm	_GFP_KERNEL,4,2                 ; @GFP_KERNEL
	.comm	_gnss_minors,4,2                ; @gnss_minors
	.comm	_GNSS_MINORS,4,2                ; @GNSS_MINORS
	.comm	_gnss_first,8,3                 ; @gnss_first
	.comm	_gnss_class,4,2                 ; @gnss_class
	.comm	_gnss_device_release,4,2        ; @gnss_device_release
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"gnss%d"

	.comm	_GNSS_READ_FIFO_SIZE,4,2        ; @GNSS_READ_FIFO_SIZE
	.comm	_GNSS_WRITE_BUF_SIZE,4,2        ; @GNSS_WRITE_BUF_SIZE
	.comm	_gnss_fops,4,2                  ; @gnss_fops
	.comm	_THIS_MODULE,4,2                ; @THIS_MODULE
.subsections_via_symbols
