	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function add_numbered_child
_add_numbered_child:                    ## @add_numbered_child
	.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
	movl	%r9d, %r12d
	movl	%r8d, -68(%rbp)                 ## 4-byte Spill
	movq	%rcx, %rbx
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -48(%rbp)
	movq	_twl4030_modules@GOTPCREL(%rip), %rax
	movq	(%rax), %r13
	movl	%edi, %r14d
	movq	%rsi, -80(%rbp)                 ## 8-byte Spill
	movq	%rsi, %rdi
	movl	%edx, %esi
	callq	_platform_device_alloc
	movq	%rax, %r15
	testq	%rax, %rax
	je	LBB0_1
## %bb.2:
	movq	%r15, %rdi
	movl	%r12d, %esi
	callq	_device_init_wakeup
	movq	(%r13,%r14,8), %rax
	movq	%rax, (%r15)
	testq	%rbx, %rbx
	je	LBB0_6
## %bb.3:
	movq	%r15, %rdi
	movq	%rbx, %rsi
	movl	-68(%rbp), %edx                 ## 4-byte Reload
	callq	_platform_device_add_data
	testl	%eax, %eax
	js	LBB0_4
LBB0_6:
	movl	16(%rbp), %eax
	testl	%eax, %eax
	je	LBB0_9
## %bb.7:
	movl	24(%rbp), %ecx
	movl	%eax, -64(%rbp)
	movq	_IORESOURCE_IRQ@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, -60(%rbp)
	movl	%ecx, -56(%rbp)
	movl	%eax, -52(%rbp)
	cmpl	$1, %ecx
	movl	$2, %edx
	sbbl	$0, %edx
	leaq	-64(%rbp), %rsi
	movq	%r15, %rdi
	callq	_platform_device_add_resources
	testl	%eax, %eax
	js	LBB0_8
LBB0_9:
	movq	%r15, %rdi
	callq	_platform_device_add
	movl	%eax, %ebx
	testl	%ebx, %ebx
	jns	LBB0_12
	jmp	LBB0_11
LBB0_1:
	movq	(%r13,%r14,8), %rdi
	leaq	L_.str(%rip), %rsi
	callq	_dev_dbg
	movq	_ENOMEM@GOTPCREL(%rip), %rax
	xorl	%ebx, %ebx
	subl	(%rax), %ebx
	testl	%ebx, %ebx
	jns	LBB0_12
	jmp	LBB0_11
LBB0_4:
	movl	%eax, %ebx
	leaq	L_.str.1(%rip), %rsi
	jmp	LBB0_5
LBB0_8:
	movl	%eax, %ebx
	leaq	L_.str.2(%rip), %rsi
LBB0_5:
	movq	%r15, %rdi
	callq	_dev_dbg
LBB0_11:
	movq	%r15, %rdi
	callq	_platform_device_put
	movq	(%r13,%r14,8), %rdi
	leaq	L_.str.3(%rip), %rsi
	movq	-80(%rbp), %rdx                 ## 8-byte Reload
	callq	_dev_err
	movl	%ebx, %edi
	callq	_ERR_PTR
	movq	%rax, %r15
LBB0_12:
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-48(%rbp), %rax
	jne	LBB0_14
## %bb.13:
	movq	%r15, %rax
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_14:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.comm	_twl4030_modules,8,3            ## @twl4030_modules
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"can't alloc dev\n"

	.comm	_ENOMEM,4,2                     ## @ENOMEM
L_.str.1:                               ## @.str.1
	.asciz	"can't add platform_data\n"

	.comm	_IORESOURCE_IRQ,4,2             ## @IORESOURCE_IRQ
L_.str.2:                               ## @.str.2
	.asciz	"can't add irqs\n"

L_.str.3:                               ## @.str.3
	.asciz	"can't add %s dev\n"

	.no_dead_strip	_add_numbered_child
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function add_numbered_child
_add_numbered_child:                    ; @add_numbered_child
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #128
	.cfi_def_cfa_offset 128
	stp	x28, x27, [sp, #32]             ; 16-byte Folded Spill
	stp	x26, x25, [sp, #48]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #64]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #80]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #96]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #112]            ; 16-byte Folded Spill
	add	x29, sp, #112
	.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	x21, x7
	mov	x23, x6
	mov	x25, x5
	mov	x22, x4
	mov	x24, x3
	mov	x19, x1
Lloh0:
	adrp	x8, ___stack_chk_guard@GOTPAGE
Lloh1:
	ldr	x8, [x8, ___stack_chk_guard@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	str	x8, [sp, #24]
Lloh3:
	adrp	x8, _twl4030_modules@GOTPAGE
Lloh4:
	ldr	x8, [x8, _twl4030_modules@GOTPAGEOFF]
Lloh5:
	ldr	x26, [x8]
	mov	w27, w0
	mov	x0, x1
	mov	x1, x2
	bl	_platform_device_alloc
	mov	x20, x0
	cbz	x0, LBB0_6
; %bb.1:
	mov	x0, x20
	mov	x1, x25
	bl	_device_init_wakeup
	ldr	x8, [x26, x27, lsl #3]
	str	x8, [x20]
	cbz	x24, LBB0_3
; %bb.2:
	mov	x0, x20
	mov	x1, x24
	mov	x2, x22
	bl	_platform_device_add_data
	tbnz	w0, #31, LBB0_7
LBB0_3:
	cbz	w23, LBB0_5
; %bb.4:
Lloh6:
	adrp	x8, _IORESOURCE_IRQ@GOTPAGE
Lloh7:
	ldr	x8, [x8, _IORESOURCE_IRQ@GOTPAGEOFF]
Lloh8:
	ldr	w8, [x8]
	stp	w23, w8, [sp, #8]
	stp	w21, w8, [sp, #16]
	cmp	w21, #0
	mov	w8, #1
	cinc	w2, w8, ne
	add	x1, sp, #8
	mov	x0, x20
	bl	_platform_device_add_resources
	tbnz	w0, #31, LBB0_8
LBB0_5:
	mov	x0, x20
	bl	_platform_device_add
	mov	x22, x0
	tbz	w22, #31, LBB0_11
	b	LBB0_10
LBB0_6:
	ldr	x0, [x26, x27, lsl #3]
Lloh9:
	adrp	x1, l_.str@PAGE
Lloh10:
	add	x1, x1, l_.str@PAGEOFF
	bl	_dev_dbg
Lloh11:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh12:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
Lloh13:
	ldr	w8, [x8]
	neg	w22, w8
	tbz	w22, #31, LBB0_11
	b	LBB0_10
LBB0_7:
	mov	x22, x0
Lloh14:
	adrp	x1, l_.str.1@PAGE
Lloh15:
	add	x1, x1, l_.str.1@PAGEOFF
	b	LBB0_9
LBB0_8:
	mov	x22, x0
Lloh16:
	adrp	x1, l_.str.2@PAGE
Lloh17:
	add	x1, x1, l_.str.2@PAGEOFF
LBB0_9:
	mov	x0, x20
	bl	_dev_dbg
LBB0_10:
	mov	x0, x20
	bl	_platform_device_put
	ldr	x0, [x26, x27, lsl #3]
Lloh18:
	adrp	x1, l_.str.3@PAGE
Lloh19:
	add	x1, x1, l_.str.3@PAGEOFF
	mov	x2, x19
	bl	_dev_err
	mov	x0, x22
	bl	_ERR_PTR
	mov	x20, x0
LBB0_11:
	ldr	x8, [sp, #24]
Lloh20:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh21:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh22:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_13
; %bb.12:
	mov	x0, x20
	ldp	x29, x30, [sp, #112]            ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #96]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #80]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #64]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #48]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp, #32]             ; 16-byte Folded Reload
	add	sp, sp, #128
	ret
LBB0_13:
	bl	___stack_chk_fail
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpAdd	Lloh9, Lloh10
	.loh AdrpAdd	Lloh14, Lloh15
	.loh AdrpAdd	Lloh16, Lloh17
	.loh AdrpAdd	Lloh18, Lloh19
	.loh AdrpLdrGotLdr	Lloh20, Lloh21, Lloh22
	.cfi_endproc
                                        ; -- End function
	.comm	_twl4030_modules,8,3            ; @twl4030_modules
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"can't alloc dev\n"

	.comm	_ENOMEM,4,2                     ; @ENOMEM
l_.str.1:                               ; @.str.1
	.asciz	"can't add platform_data\n"

	.comm	_IORESOURCE_IRQ,4,2             ; @IORESOURCE_IRQ
l_.str.2:                               ; @.str.2
	.asciz	"can't add irqs\n"

l_.str.3:                               ; @.str.3
	.asciz	"can't add %s dev\n"

	.no_dead_strip	_add_numbered_child
.subsections_via_symbols
