	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function bcm_gpio_intr_attach
_bcm_gpio_intr_attach:                  ## @bcm_gpio_intr_attach
	.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
	movl	%edi, %r14d
	callq	_device_get_softc
	movq	%rax, %rbx
	movq	8(%rax), %rax
	movl	$-1, %r15d
	cmpq	$0, 8(%rax)
	je	LBB0_6
## %bb.1:
	cmpq	$0, 16(%rax)
	je	LBB0_6
## %bb.2:
	movq	%rbx, %rdi
	callq	_bcm_gpio_pic_attach
	testq	%rax, %rax
	je	LBB0_4
## %bb.3:
	leaq	L_.str(%rip), %rsi
	movl	%r14d, %edi
	callq	_device_printf
	jmp	LBB0_6
LBB0_4:
	movq	(%rbx), %rax
	movq	8(%rbx), %rcx
	movq	8(%rcx), %rsi
	movq	_INTR_TYPE_MISC@GOTPCREL(%rip), %rcx
	movq	_INTR_MPSAFE@GOTPCREL(%rip), %r13
	movl	(%r13), %edx
	orl	(%rcx), %edx
	movq	_bcm_gpio_intr_bank0@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	movq	%rax, (%rsp)
	xorl	%r12d, %r12d
	movl	%r14d, %edi
	xorl	%r8d, %r8d
	movq	%rbx, %r9
	callq	_bus_setup_intr
	testq	%rax, %rax
	jne	LBB0_6
## %bb.5:
	movq	(%rbx), %rax
	movq	8(%rbx), %rcx
	movl	(%r13), %edx
	movq	_INTR_TYPE_MISC@GOTPCREL(%rip), %rsi
	orl	(%rsi), %edx
	movq	16(%rcx), %rsi
	movq	_bcm_gpio_intr_bank1@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	addq	$4, %rax
	movq	%rax, (%rsp)
	movl	%r14d, %edi
	xorl	%r8d, %r8d
	movq	%rbx, %r9
	callq	_bus_setup_intr
	negq	%rax
	sbbl	%r12d, %r12d
	movl	%r12d, %r15d
LBB0_6:
	movl	%r15d, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"unable to attach PIC\n"

	.comm	_INTR_TYPE_MISC,4,2             ## @INTR_TYPE_MISC
	.comm	_INTR_MPSAFE,4,2                ## @INTR_MPSAFE
	.comm	_bcm_gpio_intr_bank0,4,2        ## @bcm_gpio_intr_bank0
	.comm	_bcm_gpio_intr_bank1,4,2        ## @bcm_gpio_intr_bank1
	.no_dead_strip	_bcm_gpio_intr_attach
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function bcm_gpio_intr_attach
_bcm_gpio_intr_attach:                  ; @bcm_gpio_intr_attach
	.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
	bl	_device_get_softc
	ldr	x8, [x0, #8]
	ldr	x9, [x8, #8]
	cbz	x9, LBB0_5
; %bb.1:
	ldr	x8, [x8, #16]
	cbz	x8, LBB0_5
; %bb.2:
	mov	x20, x0
	bl	_bcm_gpio_pic_attach
	cbz	x0, LBB0_4
; %bb.3:
Lloh0:
	adrp	x1, l_.str@PAGE
Lloh1:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x19
	bl	_device_printf
	b	LBB0_5
LBB0_4:
	ldp	x6, x8, [x20]
	ldr	x1, [x8, #8]
Lloh2:
	adrp	x21, _INTR_TYPE_MISC@GOTPAGE
Lloh3:
	ldr	x21, [x21, _INTR_TYPE_MISC@GOTPAGEOFF]
Lloh4:
	adrp	x22, _INTR_MPSAFE@GOTPAGE
Lloh5:
	ldr	x22, [x22, _INTR_MPSAFE@GOTPAGEOFF]
	ldr	w8, [x21]
	ldr	w9, [x22]
	orr	w2, w9, w8
Lloh6:
	adrp	x8, _bcm_gpio_intr_bank0@GOTPAGE
Lloh7:
	ldr	x8, [x8, _bcm_gpio_intr_bank0@GOTPAGEOFF]
Lloh8:
	ldr	w3, [x8]
	mov	x0, x19
	mov	x4, #0
	mov	x5, x20
	bl	_bus_setup_intr
	cbz	x0, LBB0_7
LBB0_5:
	mov	w0, #-1
LBB0_6:
	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_7:
	ldp	x9, x8, [x20]
	ldr	x1, [x8, #16]
	ldr	w8, [x21]
	ldr	w10, [x22]
	orr	w2, w10, w8
Lloh9:
	adrp	x8, _bcm_gpio_intr_bank1@GOTPAGE
Lloh10:
	ldr	x8, [x8, _bcm_gpio_intr_bank1@GOTPAGEOFF]
Lloh11:
	ldr	w3, [x8]
	add	x6, x9, #4
	mov	x0, x19
	mov	x4, #0
	mov	x5, x20
	bl	_bus_setup_intr
	cmp	x0, #0
	csetm	w0, ne
	b	LBB0_6
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGot	Lloh4, Lloh5
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"unable to attach PIC\n"

	.comm	_INTR_TYPE_MISC,4,2             ; @INTR_TYPE_MISC
	.comm	_INTR_MPSAFE,4,2                ; @INTR_MPSAFE
	.comm	_bcm_gpio_intr_bank0,4,2        ; @bcm_gpio_intr_bank0
	.comm	_bcm_gpio_intr_bank1,4,2        ; @bcm_gpio_intr_bank1
	.no_dead_strip	_bcm_gpio_intr_attach
.subsections_via_symbols
