	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function db8500_prcmu_probe
_db8500_prcmu_probe:                    ## @db8500_prcmu_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	%r12
	pushq	%rbx
	subq	$16, %rsp
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %r14
	movq	(%rdi), %r15
	movq	_IORESOURCE_MEM@GOTPCREL(%rip), %r12
	movl	(%r12), %esi
	leaq	L_.str(%rip), %rdx
	callq	_platform_get_resource_byname
	testq	%rax, %rax
	je	LBB0_9
## %bb.1:
	movl	(%rax), %ebx
	movq	%rax, %rdi
	callq	_resource_size
	movq	%r14, %rdi
	movl	%ebx, %esi
	movl	%eax, %edx
	callq	_devm_ioremap
	movq	_prcmu_base@GOTPCREL(%rip), %rcx
	movq	%rax, (%rcx)
	testq	%rax, %rax
	je	LBB0_10
## %bb.2:
	xorl	%ebx, %ebx
	xorl	%eax, %eax
	callq	_init_prcm_registers
	movq	_DB8500_PRCMU_FW_VERSION_OFFSET@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r14, %rdi
	callq	_dbx500_fw_version_init
	movl	(%r12), %esi
	leaq	L_.str.3(%rip), %rdx
	movq	%r14, %rdi
	callq	_platform_get_resource_byname
	testq	%rax, %rax
	je	LBB0_11
## %bb.3:
	movl	(%rax), %ebx
	movq	%rax, %rdi
	callq	_resource_size
	movq	%r14, %rdi
	movl	%ebx, %esi
	movl	%eax, %edx
	callq	_devm_ioremap
	movq	_tcdm_base@GOTPCREL(%rip), %rcx
	movq	%rax, (%rcx)
	testq	%rax, %rax
	je	LBB0_12
## %bb.4:
	movq	_ALL_MBOX_BITS@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	_PRCM_ARM_IT1_CLR@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_writel
	movq	%r14, %rdi
	xorl	%esi, %esi
	callq	_platform_get_irq
	movl	%eax, %ebx
	testl	%eax, %eax
	jle	LBB0_16
## %bb.5:
	movq	_prcmu_irq_handler@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_prcmu_irq_thread_fn@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	_IRQF_NO_SUSPEND@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	leaq	L_.str(%rip), %r8
	movl	%ebx, %edi
	xorl	%r9d, %r9d
	callq	_request_threaded_irq
	testl	%eax, %eax
	js	LBB0_17
## %bb.6:
	movq	%r15, %rdi
	callq	_db8500_irq_init
	movq	_ESRAM0_DEEP_SLEEP_STATE_RET@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_prcmu_config_esram0_deep_sleep
	movq	_common_prcmu_devs@GOTPCREL(%rip), %rax
	movl	(%rax), %ebx
	movl	%ebx, %edi
	callq	_ARRAY_SIZE
	movq	_db8500_irq_domain@GOTPCREL(%rip), %r15
	movl	(%r15), %ecx
	movl	%ecx, (%rsp)
	movq	%r14, %rdi
	xorl	%esi, %esi
	movl	%ebx, %edx
	movl	%eax, %ecx
	xorl	%r8d, %r8d
	xorl	%r9d, %r9d
	callq	_mfd_add_devices
	testl	%eax, %eax
	je	LBB0_18
## %bb.7:
	movl	%eax, %ebx
LBB0_8:
	leaq	L_.str.7(%rip), %rdi
	callq	_pr_err
	jmp	LBB0_16
LBB0_9:
	leaq	L_.str.1(%rip), %rsi
	movq	%r14, %rdi
	callq	_dev_err
	movq	_EINVAL@GOTPCREL(%rip), %rax
	jmp	LBB0_14
LBB0_10:
	leaq	L_.str.2(%rip), %rsi
	jmp	LBB0_13
LBB0_11:
	leaq	L_.str.4(%rip), %rsi
	movq	%r14, %rdi
	callq	_dev_err
	movq	_EINVAL@GOTPCREL(%rip), %rax
	jmp	LBB0_15
LBB0_12:
	leaq	L_.str.5(%rip), %rsi
LBB0_13:
	movq	%r14, %rdi
	callq	_dev_err
	movq	_ENOMEM@GOTPCREL(%rip), %rax
LBB0_14:
	xorl	%ebx, %ebx
LBB0_15:
	subl	(%rax), %ebx
LBB0_16:
	movl	%ebx, %eax
	addq	$16, %rsp
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_17:
	movl	%eax, %ebx
	leaq	L_.str.6(%rip), %rdi
	callq	_pr_err
	jmp	LBB0_16
LBB0_18:
	leaq	L_.str.8(%rip), %rdi
	callq	_of_machine_is_compatible
	testl	%eax, %eax
	je	LBB0_21
LBB0_19:
	movq	%r14, %rdi
	callq	_db8500_prcmu_register_ab8500
	testl	%eax, %eax
	je	LBB0_23
## %bb.20:
	movl	%eax, %ebx
	movq	%r14, %rdi
	callq	_mfd_remove_devices
	leaq	L_.str.9(%rip), %rdi
	callq	_pr_err
	jmp	LBB0_16
LBB0_21:
	movq	_db8500_prcmu_devs@GOTPCREL(%rip), %rax
	movl	(%rax), %ebx
	movl	%ebx, %edi
	callq	_ARRAY_SIZE
	movl	(%r15), %ecx
	movl	%ecx, (%rsp)
	movq	%r14, %rdi
	xorl	%esi, %esi
	movl	%ebx, %edx
	movl	%eax, %ecx
	xorl	%r8d, %r8d
	xorl	%r9d, %r9d
	callq	_mfd_add_devices
	testl	%eax, %eax
	je	LBB0_19
## %bb.22:
	movl	%eax, %ebx
	movq	%r14, %rdi
	callq	_mfd_remove_devices
	jmp	LBB0_8
LBB0_23:
	leaq	L_.str.10(%rip), %rdi
	callq	_pr_info
	xorl	%ebx, %ebx
	jmp	LBB0_16
	.cfi_endproc
                                        ## -- End function
	.comm	_IORESOURCE_MEM,4,2             ## @IORESOURCE_MEM
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"prcmu"

L_.str.1:                               ## @.str.1
	.asciz	"no prcmu memory region provided\n"

	.comm	_EINVAL,4,2                     ## @EINVAL
	.comm	_prcmu_base,8,3                 ## @prcmu_base
L_.str.2:                               ## @.str.2
	.asciz	"failed to ioremap prcmu register memory\n"

	.comm	_ENOMEM,4,2                     ## @ENOMEM
	.comm	_DB8500_PRCMU_FW_VERSION_OFFSET,4,2 ## @DB8500_PRCMU_FW_VERSION_OFFSET
L_.str.3:                               ## @.str.3
	.asciz	"prcmu-tcdm"

L_.str.4:                               ## @.str.4
	.asciz	"no prcmu tcdm region provided\n"

	.comm	_tcdm_base,8,3                  ## @tcdm_base
L_.str.5:                               ## @.str.5
	.asciz	"failed to ioremap prcmu-tcdm register memory\n"

	.comm	_ALL_MBOX_BITS,4,2              ## @ALL_MBOX_BITS
	.comm	_PRCM_ARM_IT1_CLR,4,2           ## @PRCM_ARM_IT1_CLR
	.comm	_prcmu_irq_handler,4,2          ## @prcmu_irq_handler
	.comm	_prcmu_irq_thread_fn,4,2        ## @prcmu_irq_thread_fn
	.comm	_IRQF_NO_SUSPEND,4,2            ## @IRQF_NO_SUSPEND
L_.str.6:                               ## @.str.6
	.asciz	"prcmu: Failed to allocate IRQ_DB8500_PRCMU1.\n"

	.comm	_ESRAM0_DEEP_SLEEP_STATE_RET,4,2 ## @ESRAM0_DEEP_SLEEP_STATE_RET
	.comm	_common_prcmu_devs,4,2          ## @common_prcmu_devs
	.comm	_db8500_irq_domain,4,2          ## @db8500_irq_domain
L_.str.7:                               ## @.str.7
	.asciz	"prcmu: Failed to add subdevices\n"

L_.str.8:                               ## @.str.8
	.asciz	"st-ericsson,u8540"

	.comm	_db8500_prcmu_devs,4,2          ## @db8500_prcmu_devs
L_.str.9:                               ## @.str.9
	.asciz	"prcmu: Failed to add ab8500 subdevice\n"

L_.str.10:                              ## @.str.10
	.asciz	"DB8500 PRCMU initialized\n"

	.no_dead_strip	_db8500_prcmu_probe
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function db8500_prcmu_probe
_db8500_prcmu_probe:                    ; @db8500_prcmu_probe
	.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
	mov	x19, x0
	ldr	x20, [x0]
Lloh0:
	adrp	x22, _IORESOURCE_MEM@GOTPAGE
Lloh1:
	ldr	x22, [x22, _IORESOURCE_MEM@GOTPAGEOFF]
	ldr	w1, [x22]
Lloh2:
	adrp	x2, l_.str@PAGE
Lloh3:
	add	x2, x2, l_.str@PAGEOFF
	bl	_platform_get_resource_byname
	cbz	x0, LBB0_9
; %bb.1:
	ldr	w21, [x0]
	bl	_resource_size
	mov	x2, x0
	mov	x0, x19
	mov	x1, x21
	bl	_devm_ioremap
Lloh4:
	adrp	x8, _prcmu_base@GOTPAGE
Lloh5:
	ldr	x8, [x8, _prcmu_base@GOTPAGEOFF]
Lloh6:
	str	x0, [x8]
	cbz	x0, LBB0_10
; %bb.2:
	bl	_init_prcm_registers
Lloh7:
	adrp	x8, _DB8500_PRCMU_FW_VERSION_OFFSET@GOTPAGE
Lloh8:
	ldr	x8, [x8, _DB8500_PRCMU_FW_VERSION_OFFSET@GOTPAGEOFF]
Lloh9:
	ldr	w1, [x8]
	mov	x0, x19
	bl	_dbx500_fw_version_init
	ldr	w1, [x22]
Lloh10:
	adrp	x2, l_.str.3@PAGE
Lloh11:
	add	x2, x2, l_.str.3@PAGEOFF
	mov	x0, x19
	bl	_platform_get_resource_byname
	cbz	x0, LBB0_11
; %bb.3:
	ldr	w21, [x0]
	bl	_resource_size
	mov	x2, x0
	mov	x0, x19
	mov	x1, x21
	bl	_devm_ioremap
Lloh12:
	adrp	x8, _tcdm_base@GOTPAGE
Lloh13:
	ldr	x8, [x8, _tcdm_base@GOTPAGEOFF]
Lloh14:
	str	x0, [x8]
	cbz	x0, LBB0_13
; %bb.4:
Lloh15:
	adrp	x8, _ALL_MBOX_BITS@GOTPAGE
Lloh16:
	ldr	x8, [x8, _ALL_MBOX_BITS@GOTPAGEOFF]
Lloh17:
	ldr	w0, [x8]
Lloh18:
	adrp	x8, _PRCM_ARM_IT1_CLR@GOTPAGE
Lloh19:
	ldr	x8, [x8, _PRCM_ARM_IT1_CLR@GOTPAGEOFF]
Lloh20:
	ldr	w1, [x8]
	bl	_writel
	mov	x0, x19
	mov	w1, #0
	bl	_platform_get_irq
	mov	x21, x0
	cmp	w0, #1
	b.lt	LBB0_16
; %bb.5:
Lloh21:
	adrp	x8, _prcmu_irq_handler@GOTPAGE
Lloh22:
	ldr	x8, [x8, _prcmu_irq_handler@GOTPAGEOFF]
Lloh23:
	ldr	w1, [x8]
Lloh24:
	adrp	x8, _prcmu_irq_thread_fn@GOTPAGE
Lloh25:
	ldr	x8, [x8, _prcmu_irq_thread_fn@GOTPAGEOFF]
Lloh26:
	ldr	w2, [x8]
Lloh27:
	adrp	x8, _IRQF_NO_SUSPEND@GOTPAGE
Lloh28:
	ldr	x8, [x8, _IRQF_NO_SUSPEND@GOTPAGEOFF]
Lloh29:
	ldr	w3, [x8]
Lloh30:
	adrp	x4, l_.str@PAGE
Lloh31:
	add	x4, x4, l_.str@PAGEOFF
	mov	x0, x21
	mov	x5, #0
	bl	_request_threaded_irq
	tbnz	w0, #31, LBB0_17
; %bb.6:
	mov	x0, x20
	bl	_db8500_irq_init
Lloh32:
	adrp	x8, _ESRAM0_DEEP_SLEEP_STATE_RET@GOTPAGE
Lloh33:
	ldr	x8, [x8, _ESRAM0_DEEP_SLEEP_STATE_RET@GOTPAGEOFF]
Lloh34:
	ldr	w0, [x8]
	bl	_prcmu_config_esram0_deep_sleep
Lloh35:
	adrp	x8, _common_prcmu_devs@GOTPAGE
Lloh36:
	ldr	x8, [x8, _common_prcmu_devs@GOTPAGEOFF]
Lloh37:
	ldr	w20, [x8]
	mov	x0, x20
	bl	_ARRAY_SIZE
	mov	x3, x0
Lloh38:
	adrp	x22, _db8500_irq_domain@GOTPAGE
Lloh39:
	ldr	x22, [x22, _db8500_irq_domain@GOTPAGEOFF]
	ldr	w6, [x22]
	mov	x0, x19
	mov	w1, #0
	mov	x2, x20
	mov	x4, #0
	mov	w5, #0
	bl	_mfd_add_devices
	cbz	w0, LBB0_18
; %bb.7:
	mov	x21, x0
LBB0_8:
Lloh40:
	adrp	x0, l_.str.7@PAGE
Lloh41:
	add	x0, x0, l_.str.7@PAGEOFF
	bl	_pr_err
	b	LBB0_16
LBB0_9:
Lloh42:
	adrp	x1, l_.str.1@PAGE
Lloh43:
	add	x1, x1, l_.str.1@PAGEOFF
	b	LBB0_12
LBB0_10:
Lloh44:
	adrp	x1, l_.str.2@PAGE
Lloh45:
	add	x1, x1, l_.str.2@PAGEOFF
	b	LBB0_14
LBB0_11:
Lloh46:
	adrp	x1, l_.str.4@PAGE
Lloh47:
	add	x1, x1, l_.str.4@PAGEOFF
LBB0_12:
	mov	x0, x19
	bl	_dev_err
Lloh48:
	adrp	x8, _EINVAL@GOTPAGE
Lloh49:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
	b	LBB0_15
LBB0_13:
Lloh50:
	adrp	x1, l_.str.5@PAGE
Lloh51:
	add	x1, x1, l_.str.5@PAGEOFF
LBB0_14:
	mov	x0, x19
	bl	_dev_err
Lloh52:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh53:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
LBB0_15:
	ldr	w8, [x8]
	neg	w21, w8
LBB0_16:
	mov	x0, x21
	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
LBB0_17:
	mov	x21, x0
Lloh54:
	adrp	x0, l_.str.6@PAGE
Lloh55:
	add	x0, x0, l_.str.6@PAGEOFF
	bl	_pr_err
	b	LBB0_16
LBB0_18:
Lloh56:
	adrp	x0, l_.str.8@PAGE
Lloh57:
	add	x0, x0, l_.str.8@PAGEOFF
	bl	_of_machine_is_compatible
	cbz	w0, LBB0_21
LBB0_19:
	mov	x0, x19
	bl	_db8500_prcmu_register_ab8500
	mov	x21, x0
	cbz	w0, LBB0_23
; %bb.20:
	mov	x0, x19
	bl	_mfd_remove_devices
Lloh58:
	adrp	x0, l_.str.9@PAGE
Lloh59:
	add	x0, x0, l_.str.9@PAGEOFF
	bl	_pr_err
	b	LBB0_16
LBB0_21:
Lloh60:
	adrp	x8, _db8500_prcmu_devs@GOTPAGE
Lloh61:
	ldr	x8, [x8, _db8500_prcmu_devs@GOTPAGEOFF]
Lloh62:
	ldr	w20, [x8]
	mov	x0, x20
	bl	_ARRAY_SIZE
	mov	x3, x0
	ldr	w6, [x22]
	mov	x0, x19
	mov	w1, #0
	mov	x2, x20
	mov	x4, #0
	mov	w5, #0
	bl	_mfd_add_devices
	cbz	w0, LBB0_19
; %bb.22:
	mov	x21, x0
	mov	x0, x19
	bl	_mfd_remove_devices
	b	LBB0_8
LBB0_23:
Lloh63:
	adrp	x0, l_.str.10@PAGE
Lloh64:
	add	x0, x0, l_.str.10@PAGEOFF
	bl	_pr_info
	b	LBB0_16
	.loh AdrpAdd	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotStr	Lloh4, Lloh5, Lloh6
	.loh AdrpAdd	Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh7, Lloh8, Lloh9
	.loh AdrpLdrGotStr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpAdd	Lloh30, Lloh31
	.loh AdrpLdrGotLdr	Lloh27, Lloh28, Lloh29
	.loh AdrpLdrGotLdr	Lloh24, Lloh25, Lloh26
	.loh AdrpLdrGotLdr	Lloh21, Lloh22, Lloh23
	.loh AdrpLdrGot	Lloh38, Lloh39
	.loh AdrpLdrGotLdr	Lloh35, Lloh36, Lloh37
	.loh AdrpLdrGotLdr	Lloh32, Lloh33, Lloh34
	.loh AdrpAdd	Lloh40, Lloh41
	.loh AdrpAdd	Lloh42, Lloh43
	.loh AdrpAdd	Lloh44, Lloh45
	.loh AdrpAdd	Lloh46, Lloh47
	.loh AdrpLdrGot	Lloh48, Lloh49
	.loh AdrpAdd	Lloh50, Lloh51
	.loh AdrpLdrGot	Lloh52, Lloh53
	.loh AdrpAdd	Lloh54, Lloh55
	.loh AdrpAdd	Lloh56, Lloh57
	.loh AdrpAdd	Lloh58, Lloh59
	.loh AdrpLdrGotLdr	Lloh60, Lloh61, Lloh62
	.loh AdrpAdd	Lloh63, Lloh64
	.cfi_endproc
                                        ; -- End function
	.comm	_IORESOURCE_MEM,4,2             ; @IORESOURCE_MEM
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"prcmu"

l_.str.1:                               ; @.str.1
	.asciz	"no prcmu memory region provided\n"

	.comm	_EINVAL,4,2                     ; @EINVAL
	.comm	_prcmu_base,8,3                 ; @prcmu_base
l_.str.2:                               ; @.str.2
	.asciz	"failed to ioremap prcmu register memory\n"

	.comm	_ENOMEM,4,2                     ; @ENOMEM
	.comm	_DB8500_PRCMU_FW_VERSION_OFFSET,4,2 ; @DB8500_PRCMU_FW_VERSION_OFFSET
l_.str.3:                               ; @.str.3
	.asciz	"prcmu-tcdm"

l_.str.4:                               ; @.str.4
	.asciz	"no prcmu tcdm region provided\n"

	.comm	_tcdm_base,8,3                  ; @tcdm_base
l_.str.5:                               ; @.str.5
	.asciz	"failed to ioremap prcmu-tcdm register memory\n"

	.comm	_ALL_MBOX_BITS,4,2              ; @ALL_MBOX_BITS
	.comm	_PRCM_ARM_IT1_CLR,4,2           ; @PRCM_ARM_IT1_CLR
	.comm	_prcmu_irq_handler,4,2          ; @prcmu_irq_handler
	.comm	_prcmu_irq_thread_fn,4,2        ; @prcmu_irq_thread_fn
	.comm	_IRQF_NO_SUSPEND,4,2            ; @IRQF_NO_SUSPEND
l_.str.6:                               ; @.str.6
	.asciz	"prcmu: Failed to allocate IRQ_DB8500_PRCMU1.\n"

	.comm	_ESRAM0_DEEP_SLEEP_STATE_RET,4,2 ; @ESRAM0_DEEP_SLEEP_STATE_RET
	.comm	_common_prcmu_devs,4,2          ; @common_prcmu_devs
	.comm	_db8500_irq_domain,4,2          ; @db8500_irq_domain
l_.str.7:                               ; @.str.7
	.asciz	"prcmu: Failed to add subdevices\n"

l_.str.8:                               ; @.str.8
	.asciz	"st-ericsson,u8540"

	.comm	_db8500_prcmu_devs,4,2          ; @db8500_prcmu_devs
l_.str.9:                               ; @.str.9
	.asciz	"prcmu: Failed to add ab8500 subdevice\n"

l_.str.10:                              ; @.str.10
	.asciz	"DB8500 PRCMU initialized\n"

	.no_dead_strip	_db8500_prcmu_probe
.subsections_via_symbols
