	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_iio_device_alloc               ## -- Begin function iio_device_alloc
	.p2align	4, 0x90
_iio_device_alloc:                      ## @iio_device_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	%rbx
	pushq	%rax
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	testl	%edi, %edi
	je	LBB0_2
## %bb.1:
	movl	%edi, %ebx
	movq	_IIO_ALIGN@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	$56, %edi
	callq	_ALIGN
	movslq	%ebx, %rcx
	addq	%rax, %rcx
	jmp	LBB0_3
LBB0_2:
	movl	$56, %ecx
LBB0_3:
	movq	_IIO_ALIGN@GOTPCREL(%rip), %rax
	movslq	(%rax), %rax
	leaq	(%rax,%rcx), %rdi
	decq	%rdi
	movq	_GFP_KERNEL@GOTPCREL(%rip), %r15
	movl	(%r15), %esi
	callq	_kzalloc
	testq	%rax, %rax
	je	LBB0_8
## %bb.4:
	movq	%rax, %rbx
	movl	52(%rax), %eax
	leaq	16(%rbx), %r14
	movl	%eax, 32(%rbx)
	movq	_iio_device_type@GOTPCREL(%rip), %rax
	movq	%rax, 24(%rbx)
	movq	_iio_bus_type@GOTPCREL(%rip), %rax
	movq	%rax, 16(%rbx)
	movq	%r14, %rdi
	callq	_device_initialize
	movq	%r14, %rdi
	movq	%rbx, %rsi
	callq	_dev_set_drvdata
	leaq	48(%rbx), %rdi
	callq	_mutex_init
	leaq	44(%rbx), %rdi
	callq	_mutex_init
	leaq	40(%rbx), %rdi
	callq	_INIT_LIST_HEAD
	movl	(%r15), %ecx
	movq	_iio_ida@GOTPCREL(%rip), %rdi
	xorl	%esi, %esi
	xorl	%edx, %edx
	callq	_ida_simple_get
	movq	%rax, (%rbx)
	testq	%rax, %rax
	js	LBB0_7
## %bb.5:
	leaq	L_.str.1(%rip), %rsi
	movq	%r14, %rdi
	movq	%rax, %rdx
	callq	_dev_set_name
	movq	%rbx, %rdi
	addq	$8, %rdi
	callq	_INIT_LIST_HEAD
	jmp	LBB0_9
LBB0_7:
	leaq	L_.str(%rip), %rdi
	callq	_pr_err
	movq	%rbx, %rdi
	callq	_kfree
LBB0_8:
	xorl	%ebx, %ebx
LBB0_9:
	movq	%rbx, %rax
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_IIO_ALIGN,4,2                  ## @IIO_ALIGN
	.comm	_GFP_KERNEL,4,2                 ## @GFP_KERNEL
	.comm	_iio_device_type,4,2            ## @iio_device_type
	.comm	_iio_bus_type,4,2               ## @iio_bus_type
	.comm	_iio_ida,4,2                    ## @iio_ida
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"failed to get device id\n"

L_.str.1:                               ## @.str.1
	.asciz	"iio:device%d"

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_iio_device_alloc               ; -- Begin function iio_device_alloc
	.p2align	2
_iio_device_alloc:                      ; @iio_device_alloc
	.cfi_startproc
; %bb.0:
	stp	x22, x21, [sp, #-48]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 48
	stp	x20, x19, [sp, #16]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #32]             ; 16-byte Folded Spill
	add	x29, sp, #32
	.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
Lloh0:
	adrp	x20, _IIO_ALIGN@GOTPAGE
Lloh1:
	ldr	x20, [x20, _IIO_ALIGN@GOTPAGEOFF]
	cbz	w0, LBB0_2
; %bb.1:
	mov	x19, x0
	ldr	w1, [x20]
	mov	w0, #56
	bl	_ALIGN
	add	x8, x0, w19, sxtw
	b	LBB0_3
LBB0_2:
	mov	w8, #56
LBB0_3:
	ldrsw	x9, [x20]
	add	x8, x9, x8
	sub	x0, x8, #1
Lloh2:
	adrp	x21, _GFP_KERNEL@GOTPAGE
Lloh3:
	ldr	x21, [x21, _GFP_KERNEL@GOTPAGEOFF]
	ldr	w1, [x21]
	bl	_kzalloc
	mov	x19, x0
	cbz	x0, LBB0_7
; %bb.4:
	ldr	w8, [x19, #52]
Lloh4:
	adrp	x9, _iio_bus_type@GOTPAGE
Lloh5:
	ldr	x9, [x9, _iio_bus_type@GOTPAGEOFF]
	mov	x20, x19
	str	x9, [x20, #16]!
	str	w8, [x19, #32]
Lloh6:
	adrp	x8, _iio_device_type@GOTPAGE
Lloh7:
	ldr	x8, [x8, _iio_device_type@GOTPAGEOFF]
	str	x8, [x19, #24]
	mov	x0, x20
	bl	_device_initialize
	mov	x0, x20
	mov	x1, x19
	bl	_dev_set_drvdata
	add	x0, x19, #48
	bl	_mutex_init
	add	x0, x19, #44
	bl	_mutex_init
	add	x0, x19, #40
	bl	_INIT_LIST_HEAD
	ldr	w3, [x21]
Lloh8:
	adrp	x0, _iio_ida@GOTPAGE
Lloh9:
	ldr	x0, [x0, _iio_ida@GOTPAGEOFF]
	mov	w1, #0
	mov	w2, #0
	bl	_ida_simple_get
	str	x0, [x19]
	tbnz	x0, #63, LBB0_6
; %bb.5:
	mov	x2, x0
Lloh10:
	adrp	x1, l_.str.1@PAGE
Lloh11:
	add	x1, x1, l_.str.1@PAGEOFF
	mov	x0, x20
	bl	_dev_set_name
	add	x0, x19, #8
	bl	_INIT_LIST_HEAD
	b	LBB0_7
LBB0_6:
Lloh12:
	adrp	x0, l_.str@PAGE
Lloh13:
	add	x0, x0, l_.str@PAGEOFF
	bl	_pr_err
	mov	x0, x19
	bl	_kfree
	mov	x19, #0
LBB0_7:
	mov	x0, x19
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp], #48             ; 16-byte Folded Reload
	ret
	.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 AdrpAdd	Lloh12, Lloh13
	.cfi_endproc
                                        ; -- End function
	.comm	_IIO_ALIGN,4,2                  ; @IIO_ALIGN
	.comm	_GFP_KERNEL,4,2                 ; @GFP_KERNEL
	.comm	_iio_device_type,4,2            ; @iio_device_type
	.comm	_iio_bus_type,4,2               ; @iio_bus_type
	.comm	_iio_ida,4,2                    ; @iio_ida
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"failed to get device id\n"

l_.str.1:                               ; @.str.1
	.asciz	"iio:device%d"

.subsections_via_symbols
