	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_brcmf_sdiod_intr_register      ## -- Begin function brcmf_sdiod_intr_register
	.p2align	4, 0x90
_brcmf_sdiod_intr_register:             ## @brcmf_sdiod_intr_register
	.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	48(%rdi), %r12
	cmpq	$0, 8(%r12)
	movq	_SDIO@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	je	LBB0_11
## %bb.1:
	movl	4(%r12), %edx
	leaq	L_.str(%rip), %rsi
	xorl	%eax, %eax
	callq	_brcmf_dbg
	leaq	40(%r14), %rdi
	callq	_spin_lock_init
	movl	$1, (%r14)
	movl	(%r12), %edx
	movl	4(%r12), %edi
	movq	_brcmf_sdiod_oob_irqhandler@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	16(%r14), %r8
	leaq	L_.str.1(%rip), %rcx
	callq	_request_irq
	testl	%eax, %eax
	je	LBB0_4
## %bb.2:
	movl	%eax, %ebx
	leaq	L_.str.2(%rip), %rdi
	jmp	LBB0_3
LBB0_11:
	leaq	L_.str.4(%rip), %rsi
	xorl	%ebx, %ebx
	xorl	%eax, %eax
	callq	_brcmf_dbg
	movq	16(%r14), %rdi
	callq	_sdio_claim_host
	movq	16(%r14), %rdi
	movq	_brcmf_sdiod_ib_irqhandler@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_sdio_claim_irq
	movq	24(%r14), %rdi
	movq	_brcmf_sdiod_dummy_irqhandler@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_sdio_claim_irq
	movq	16(%r14), %rdi
	callq	_sdio_release_host
	movl	$1, 12(%r14)
	jmp	LBB0_12
LBB0_4:
	movl	$1, 4(%r14)
	movl	4(%r12), %edi
	callq	_enable_irq_wake
	movl	%eax, -36(%rbp)
	testl	%eax, %eax
	je	LBB0_6
## %bb.5:
	movl	%eax, %ebx
	leaq	L_.str.3(%rip), %rdi
LBB0_3:
	movl	%ebx, %esi
	callq	_brcmf_err
LBB0_12:
	movl	%ebx, %eax
	addq	$16, %rsp
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_6:
	movl	$1, 8(%r14)
	movq	16(%r14), %rdi
	callq	_sdio_claim_host
	movq	32(%r14), %rax
	movq	(%rax), %rax
	movq	_BRCM_CC_43362_CHIP_ID@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_8
## %bb.7:
	movq	_SI_ENUM_BASE@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_CORE_CC_REG
	movl	%eax, %ebx
	leaq	-36(%rbp), %r15
	movq	%r14, %rdi
	movl	%eax, %esi
	movq	%r15, %rdx
	callq	_brcmf_sdiod_readl
	orl	$2, %eax
	movq	%r14, %rdi
	movl	%ebx, %esi
	movl	%eax, %edx
	movq	%r15, %rcx
	callq	_brcmf_sdiod_writel
	movq	_SBSDIO_GPIO_SELECT@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r14, %rdi
	movl	$15, %edx
	movq	%r15, %rcx
	callq	_brcmf_sdiod_writeb
	movq	_SBSDIO_GPIO_OUT@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r14, %rdi
	xorl	%edx, %edx
	movq	%r15, %rcx
	callq	_brcmf_sdiod_writeb
	movq	_SBSDIO_GPIO_EN@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r14, %rdi
	movl	$2, %edx
	movq	%r15, %rcx
	callq	_brcmf_sdiod_writeb
LBB0_8:
	movq	_SDIO_CCCR_IENx@GOTPCREL(%rip), %rbx
	movl	(%rbx), %esi
	leaq	-36(%rbp), %r15
	movq	%r14, %rdi
	movq	%r15, %rdx
	callq	_brcmf_sdiod_func0_rb
	movq	_SDIO_CCCR_IEN_FUNC1@GOTPCREL(%rip), %rcx
	movq	_SDIO_CCCR_IEN_FUNC2@GOTPCREL(%rip), %rdx
	orl	(%rcx), %eax
	orl	(%rdx), %eax
	movq	_SDIO_CCCR_IEN_FUNC0@GOTPCREL(%rip), %rcx
	orl	(%rcx), %eax
	movl	(%rbx), %esi
	movq	%r14, %rdi
	movl	%eax, %edx
	movq	%r15, %rcx
	callq	_brcmf_sdiod_func0_wb
	movq	_SDIO_CCCR_BRCM_SEPINT_MASK@GOTPCREL(%rip), %rax
	movq	_SDIO_CCCR_BRCM_SEPINT_OE@GOTPCREL(%rip), %rcx
	movl	(%rcx), %edx
	orl	(%rax), %edx
	movq	_IRQF_TRIGGER_HIGH@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	andl	(%r12), %eax
	je	LBB0_10
## %bb.9:
	movq	_SDIO_CCCR_BRCM_SEPINT_ACT_HI@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
LBB0_10:
	orl	%eax, %edx
	movq	_SDIO_CCCR_BRCM_SEPINT@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r14, %rdi
	movq	%r15, %rcx
	callq	_brcmf_sdiod_func0_wb
	movq	16(%r14), %rdi
	callq	_sdio_release_host
	xorl	%ebx, %ebx
	jmp	LBB0_12
	.cfi_endproc
                                        ## -- End function
	.comm	_SDIO,4,2                       ## @SDIO
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Enter, register OOB IRQ %d\n"

	.comm	_brcmf_sdiod_oob_irqhandler,4,2 ## @brcmf_sdiod_oob_irqhandler
L_.str.1:                               ## @.str.1
	.asciz	"brcmf_oob_intr"

L_.str.2:                               ## @.str.2
	.asciz	"request_irq failed %d\n"

L_.str.3:                               ## @.str.3
	.asciz	"enable_irq_wake failed %d\n"

	.comm	_BRCM_CC_43362_CHIP_ID,8,3      ## @BRCM_CC_43362_CHIP_ID
	.comm	_SI_ENUM_BASE,4,2               ## @SI_ENUM_BASE
	.comm	_SBSDIO_GPIO_SELECT,4,2         ## @SBSDIO_GPIO_SELECT
	.comm	_SBSDIO_GPIO_OUT,4,2            ## @SBSDIO_GPIO_OUT
	.comm	_SBSDIO_GPIO_EN,4,2             ## @SBSDIO_GPIO_EN
	.comm	_SDIO_CCCR_IENx,4,2             ## @SDIO_CCCR_IENx
	.comm	_SDIO_CCCR_IEN_FUNC1,4,2        ## @SDIO_CCCR_IEN_FUNC1
	.comm	_SDIO_CCCR_IEN_FUNC2,4,2        ## @SDIO_CCCR_IEN_FUNC2
	.comm	_SDIO_CCCR_IEN_FUNC0,4,2        ## @SDIO_CCCR_IEN_FUNC0
	.comm	_SDIO_CCCR_BRCM_SEPINT_MASK,4,2 ## @SDIO_CCCR_BRCM_SEPINT_MASK
	.comm	_SDIO_CCCR_BRCM_SEPINT_OE,4,2   ## @SDIO_CCCR_BRCM_SEPINT_OE
	.comm	_IRQF_TRIGGER_HIGH,4,2          ## @IRQF_TRIGGER_HIGH
	.comm	_SDIO_CCCR_BRCM_SEPINT_ACT_HI,4,2 ## @SDIO_CCCR_BRCM_SEPINT_ACT_HI
	.comm	_SDIO_CCCR_BRCM_SEPINT,4,2      ## @SDIO_CCCR_BRCM_SEPINT
L_.str.4:                               ## @.str.4
	.asciz	"Entering\n"

	.comm	_brcmf_sdiod_ib_irqhandler,4,2  ## @brcmf_sdiod_ib_irqhandler
	.comm	_brcmf_sdiod_dummy_irqhandler,4,2 ## @brcmf_sdiod_dummy_irqhandler
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_brcmf_sdiod_intr_register      ; -- Begin function brcmf_sdiod_intr_register
	.p2align	2
_brcmf_sdiod_intr_register:             ; @brcmf_sdiod_intr_register
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #64
	.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
	mov	x19, x0
	ldr	x21, [x0, #48]
	ldr	x8, [x21, #8]
Lloh0:
	adrp	x9, _SDIO@GOTPAGE
Lloh1:
	ldr	x9, [x9, _SDIO@GOTPAGEOFF]
Lloh2:
	ldr	w0, [x9]
	cbz	x8, LBB0_3
; %bb.1:
	ldr	w8, [x21, #4]
	str	x8, [sp]
Lloh3:
	adrp	x1, l_.str@PAGE
Lloh4:
	add	x1, x1, l_.str@PAGEOFF
	bl	_brcmf_dbg
	add	x0, x19, #40
	bl	_spin_lock_init
	mov	w22, #1
	str	w22, [x19]
Lloh5:
	adrp	x8, _brcmf_sdiod_oob_irqhandler@GOTPAGE
Lloh6:
	ldr	x8, [x8, _brcmf_sdiod_oob_irqhandler@GOTPAGEOFF]
Lloh7:
	ldr	w1, [x8]
	ldp	w2, w0, [x21]
	ldr	x4, [x19, #16]
Lloh8:
	adrp	x3, l_.str.1@PAGE
Lloh9:
	add	x3, x3, l_.str.1@PAGEOFF
	bl	_request_irq
	cbz	w0, LBB0_4
; %bb.2:
	mov	x20, x0
Lloh10:
	adrp	x0, l_.str.2@PAGE
Lloh11:
	add	x0, x0, l_.str.2@PAGEOFF
	b	LBB0_6
LBB0_3:
Lloh12:
	adrp	x1, l_.str.4@PAGE
Lloh13:
	add	x1, x1, l_.str.4@PAGEOFF
	bl	_brcmf_dbg
	ldr	x0, [x19, #16]
	bl	_sdio_claim_host
	ldr	x0, [x19, #16]
Lloh14:
	adrp	x8, _brcmf_sdiod_ib_irqhandler@GOTPAGE
Lloh15:
	ldr	x8, [x8, _brcmf_sdiod_ib_irqhandler@GOTPAGEOFF]
Lloh16:
	ldr	w1, [x8]
	bl	_sdio_claim_irq
	ldr	x0, [x19, #24]
Lloh17:
	adrp	x8, _brcmf_sdiod_dummy_irqhandler@GOTPAGE
Lloh18:
	ldr	x8, [x8, _brcmf_sdiod_dummy_irqhandler@GOTPAGEOFF]
Lloh19:
	ldr	w1, [x8]
	bl	_sdio_claim_irq
	ldr	x0, [x19, #16]
	bl	_sdio_release_host
	mov	w20, #0
	mov	w8, #1
	str	w8, [x19, #12]
	b	LBB0_7
LBB0_4:
	str	w22, [x19, #4]
	ldr	w0, [x21, #4]
	bl	_enable_irq_wake
	str	w0, [sp, #12]
	cbz	w0, LBB0_8
; %bb.5:
	mov	x20, x0
Lloh20:
	adrp	x0, l_.str.3@PAGE
Lloh21:
	add	x0, x0, l_.str.3@PAGEOFF
LBB0_6:
	mov	x1, x20
	bl	_brcmf_err
LBB0_7:
	mov	x0, x20
	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
	add	sp, sp, #64
	ret
LBB0_8:
	mov	w8, #1
	str	w8, [x19, #8]
	ldr	x0, [x19, #16]
	bl	_sdio_claim_host
	ldr	x8, [x19, #32]
	ldr	x8, [x8]
Lloh22:
	adrp	x9, _BRCM_CC_43362_CHIP_ID@GOTPAGE
Lloh23:
	ldr	x9, [x9, _BRCM_CC_43362_CHIP_ID@GOTPAGEOFF]
Lloh24:
	ldr	x9, [x9]
	cmp	x8, x9
	b.ne	LBB0_10
; %bb.9:
Lloh25:
	adrp	x8, _SI_ENUM_BASE@GOTPAGE
Lloh26:
	ldr	x8, [x8, _SI_ENUM_BASE@GOTPAGEOFF]
Lloh27:
	ldr	w0, [x8]
	bl	_CORE_CC_REG
	mov	x20, x0
	add	x2, sp, #12
	mov	x0, x19
	mov	x1, x20
	bl	_brcmf_sdiod_readl
	orr	w2, w0, #0x2
	add	x3, sp, #12
	mov	x0, x19
	mov	x1, x20
	bl	_brcmf_sdiod_writel
Lloh28:
	adrp	x8, _SBSDIO_GPIO_SELECT@GOTPAGE
Lloh29:
	ldr	x8, [x8, _SBSDIO_GPIO_SELECT@GOTPAGEOFF]
Lloh30:
	ldr	w1, [x8]
	add	x3, sp, #12
	mov	x0, x19
	mov	w2, #15
	bl	_brcmf_sdiod_writeb
Lloh31:
	adrp	x8, _SBSDIO_GPIO_OUT@GOTPAGE
Lloh32:
	ldr	x8, [x8, _SBSDIO_GPIO_OUT@GOTPAGEOFF]
Lloh33:
	ldr	w1, [x8]
	add	x3, sp, #12
	mov	x0, x19
	mov	w2, #0
	bl	_brcmf_sdiod_writeb
Lloh34:
	adrp	x8, _SBSDIO_GPIO_EN@GOTPAGE
Lloh35:
	ldr	x8, [x8, _SBSDIO_GPIO_EN@GOTPAGEOFF]
Lloh36:
	ldr	w1, [x8]
	add	x3, sp, #12
	mov	x0, x19
	mov	w2, #2
	bl	_brcmf_sdiod_writeb
LBB0_10:
Lloh37:
	adrp	x20, _SDIO_CCCR_IENx@GOTPAGE
Lloh38:
	ldr	x20, [x20, _SDIO_CCCR_IENx@GOTPAGEOFF]
	ldr	w1, [x20]
	add	x2, sp, #12
	mov	x0, x19
	bl	_brcmf_sdiod_func0_rb
Lloh39:
	adrp	x8, _SDIO_CCCR_IEN_FUNC1@GOTPAGE
Lloh40:
	ldr	x8, [x8, _SDIO_CCCR_IEN_FUNC1@GOTPAGEOFF]
Lloh41:
	ldr	w8, [x8]
Lloh42:
	adrp	x9, _SDIO_CCCR_IEN_FUNC2@GOTPAGE
Lloh43:
	ldr	x9, [x9, _SDIO_CCCR_IEN_FUNC2@GOTPAGEOFF]
Lloh44:
	adrp	x10, _SDIO_CCCR_IEN_FUNC0@GOTPAGE
Lloh45:
	ldr	x10, [x10, _SDIO_CCCR_IEN_FUNC0@GOTPAGEOFF]
Lloh46:
	ldr	w9, [x9]
Lloh47:
	ldr	w10, [x10]
	orr	w8, w8, w0
	orr	w8, w8, w9
	orr	w2, w8, w10
	ldr	w1, [x20]
	add	x3, sp, #12
	mov	x0, x19
	bl	_brcmf_sdiod_func0_wb
Lloh48:
	adrp	x8, _SDIO_CCCR_BRCM_SEPINT_MASK@GOTPAGE
Lloh49:
	ldr	x8, [x8, _SDIO_CCCR_BRCM_SEPINT_MASK@GOTPAGEOFF]
Lloh50:
	ldr	w8, [x8]
Lloh51:
	adrp	x9, _SDIO_CCCR_BRCM_SEPINT_OE@GOTPAGE
Lloh52:
	ldr	x9, [x9, _SDIO_CCCR_BRCM_SEPINT_OE@GOTPAGEOFF]
Lloh53:
	ldr	w9, [x9]
	orr	w8, w9, w8
	ldr	w9, [x21]
Lloh54:
	adrp	x10, _IRQF_TRIGGER_HIGH@GOTPAGE
Lloh55:
	ldr	x10, [x10, _IRQF_TRIGGER_HIGH@GOTPAGEOFF]
Lloh56:
	ldr	w10, [x10]
Lloh57:
	adrp	x11, _SDIO_CCCR_BRCM_SEPINT_ACT_HI@GOTPAGE
Lloh58:
	ldr	x11, [x11, _SDIO_CCCR_BRCM_SEPINT_ACT_HI@GOTPAGEOFF]
Lloh59:
	ldr	w11, [x11]
	tst	w10, w9
	csel	w9, wzr, w11, eq
	orr	w2, w8, w9
Lloh60:
	adrp	x8, _SDIO_CCCR_BRCM_SEPINT@GOTPAGE
Lloh61:
	ldr	x8, [x8, _SDIO_CCCR_BRCM_SEPINT@GOTPAGEOFF]
Lloh62:
	ldr	w1, [x8]
	add	x3, sp, #12
	mov	x0, x19
	bl	_brcmf_sdiod_func0_wb
	ldr	x0, [x19, #16]
	bl	_sdio_release_host
	mov	w20, #0
	b	LBB0_7
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh8, Lloh9
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpAdd	Lloh3, Lloh4
	.loh AdrpAdd	Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh17, Lloh18, Lloh19
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpAdd	Lloh12, Lloh13
	.loh AdrpAdd	Lloh20, Lloh21
	.loh AdrpLdrGotLdr	Lloh22, Lloh23, Lloh24
	.loh AdrpLdrGotLdr	Lloh34, Lloh35, Lloh36
	.loh AdrpLdrGotLdr	Lloh31, Lloh32, Lloh33
	.loh AdrpLdrGotLdr	Lloh28, Lloh29, Lloh30
	.loh AdrpLdrGotLdr	Lloh25, Lloh26, Lloh27
	.loh AdrpLdrGotLdr	Lloh60, Lloh61, Lloh62
	.loh AdrpLdrGotLdr	Lloh57, Lloh58, Lloh59
	.loh AdrpLdrGotLdr	Lloh54, Lloh55, Lloh56
	.loh AdrpLdrGotLdr	Lloh51, Lloh52, Lloh53
	.loh AdrpLdrGotLdr	Lloh48, Lloh49, Lloh50
	.loh AdrpLdrGotLdr	Lloh44, Lloh45, Lloh47
	.loh AdrpLdrGotLdr	Lloh42, Lloh43, Lloh46
	.loh AdrpLdrGotLdr	Lloh39, Lloh40, Lloh41
	.loh AdrpLdrGot	Lloh37, Lloh38
	.cfi_endproc
                                        ; -- End function
	.comm	_SDIO,4,2                       ; @SDIO
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Enter, register OOB IRQ %d\n"

	.comm	_brcmf_sdiod_oob_irqhandler,4,2 ; @brcmf_sdiod_oob_irqhandler
l_.str.1:                               ; @.str.1
	.asciz	"brcmf_oob_intr"

l_.str.2:                               ; @.str.2
	.asciz	"request_irq failed %d\n"

l_.str.3:                               ; @.str.3
	.asciz	"enable_irq_wake failed %d\n"

	.comm	_BRCM_CC_43362_CHIP_ID,8,3      ; @BRCM_CC_43362_CHIP_ID
	.comm	_SI_ENUM_BASE,4,2               ; @SI_ENUM_BASE
	.comm	_SBSDIO_GPIO_SELECT,4,2         ; @SBSDIO_GPIO_SELECT
	.comm	_SBSDIO_GPIO_OUT,4,2            ; @SBSDIO_GPIO_OUT
	.comm	_SBSDIO_GPIO_EN,4,2             ; @SBSDIO_GPIO_EN
	.comm	_SDIO_CCCR_IENx,4,2             ; @SDIO_CCCR_IENx
	.comm	_SDIO_CCCR_IEN_FUNC1,4,2        ; @SDIO_CCCR_IEN_FUNC1
	.comm	_SDIO_CCCR_IEN_FUNC2,4,2        ; @SDIO_CCCR_IEN_FUNC2
	.comm	_SDIO_CCCR_IEN_FUNC0,4,2        ; @SDIO_CCCR_IEN_FUNC0
	.comm	_SDIO_CCCR_BRCM_SEPINT_MASK,4,2 ; @SDIO_CCCR_BRCM_SEPINT_MASK
	.comm	_SDIO_CCCR_BRCM_SEPINT_OE,4,2   ; @SDIO_CCCR_BRCM_SEPINT_OE
	.comm	_IRQF_TRIGGER_HIGH,4,2          ; @IRQF_TRIGGER_HIGH
	.comm	_SDIO_CCCR_BRCM_SEPINT_ACT_HI,4,2 ; @SDIO_CCCR_BRCM_SEPINT_ACT_HI
	.comm	_SDIO_CCCR_BRCM_SEPINT,4,2      ; @SDIO_CCCR_BRCM_SEPINT
l_.str.4:                               ; @.str.4
	.asciz	"Entering\n"

	.comm	_brcmf_sdiod_ib_irqhandler,4,2  ; @brcmf_sdiod_ib_irqhandler
	.comm	_brcmf_sdiod_dummy_irqhandler,4,2 ; @brcmf_sdiod_dummy_irqhandler
.subsections_via_symbols
