	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function bcm_fb_attach
_bcm_fb_attach:                         ## @bcm_fb_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
	subq	$2072, %rsp                     ## imm = 0x818
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%edi, %ebx
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -48(%rbp)
	callq	_device_get_softc
	movq	%rax, %r14
	movl	%ebx, 4(%rax)
	movl	$0, (%rax)
	leaq	L_.str(%rip), %rdi
	callq	_OF_finddevice
	cmpl	$-1, %eax
	je	LBB0_10
## %bb.1:
	leaq	L_.str.1(%rip), %rsi
	leaq	-2096(%rbp), %rbx
	movl	%eax, %edi
	movq	%rbx, %rdx
	movl	$2048, %ecx                     ## imm = 0x800
	callq	_OF_getprop
	testq	%rax, %rax
	jle	LBB0_10
## %bb.2:
	movq	%rbx, -2112(%rbp)
	leaq	L_.str.2(%rip), %rsi
	leaq	-2112(%rbp), %rdi
	callq	_strsep
	movq	%rax, -2104(%rbp)
	testq	%rax, %rax
	je	LBB0_10
## %bb.3:
	leaq	L_.str.2(%rip), %r15
	leaq	-2112(%rbp), %rbx
	leaq	-2104(%rbp), %r13
	leaq	L_.str.4(%rip), %r12
	jmp	LBB0_4
	.p2align	4, 0x90
LBB0_9:                                 ##   in Loop: Header=BB0_4 Depth=1
	movq	%rbx, %rdi
	movq	%r15, %rsi
	callq	_strsep
	movq	%rax, -2104(%rbp)
	testq	%rax, %rax
	je	LBB0_10
LBB0_4:                                 ## =>This Inner Loop Header: Depth=1
	cmpb	$0, (%rax)
	je	LBB0_9
## %bb.5:                               ##   in Loop: Header=BB0_4 Depth=1
	movq	%r13, %rdi
	leaq	L_.str.3(%rip), %rsi
	callq	_strsep
	movq	%rax, %rdi
	movq	%r12, %rsi
	callq	_strcmp
	testq	%rax, %rax
	jne	LBB0_9
## %bb.6:                               ##   in Loop: Header=BB0_4 Depth=1
	movq	-2104(%rbp), %rax
	testq	%rax, %rax
	je	LBB0_9
## %bb.7:                               ##   in Loop: Header=BB0_4 Depth=1
	cmpb	$49, (%rax)
	jne	LBB0_9
## %bb.8:                               ##   in Loop: Header=BB0_4 Depth=1
	movl	$1, (%r14)
	jmp	LBB0_9
LBB0_10:
	movq	%r14, %rdi
	callq	_bcm_fb_sysctl_init
	movq	%r14, %rdi
	callq	_bcm_fb_setup_fbd
	movq	___stack_chk_guard@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rcx
	cmpq	-48(%rbp), %rcx
	jne	LBB0_12
## %bb.11:
	addq	$2072, %rsp                     ## imm = 0x818
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_12:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"/chosen"

L_.str.1:                               ## @.str.1
	.asciz	"bootargs"

L_.str.2:                               ## @.str.2
	.asciz	" "

L_.str.3:                               ## @.str.3
	.asciz	"="

L_.str.4:                               ## @.str.4
	.asciz	"bcm2708_fb.fbswap"

	.no_dead_strip	_bcm_fb_attach
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function bcm_fb_attach
_bcm_fb_attach:                         ; @bcm_fb_attach
	.cfi_startproc
; %bb.0:
	stp	x24, x23, [sp, #-64]!           ; 16-byte Folded Spill
	.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
	.cfi_offset w23, -56
	.cfi_offset w24, -64
	sub	sp, sp, #2080
	mov	x20, x0
Lloh0:
	adrp	x8, ___stack_chk_guard@GOTPAGE
Lloh1:
	ldr	x8, [x8, ___stack_chk_guard@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	stur	x8, [x29, #-56]
	bl	_device_get_softc
	mov	x19, x0
	stp	wzr, w20, [x0]
Lloh3:
	adrp	x0, l_.str@PAGE
Lloh4:
	add	x0, x0, l_.str@PAGEOFF
	bl	_OF_finddevice
	cmn	w0, #1
	b.eq	LBB0_9
; %bb.1:
Lloh5:
	adrp	x1, l_.str.1@PAGE
Lloh6:
	add	x1, x1, l_.str.1@PAGEOFF
	add	x20, sp, #24
	add	x2, sp, #24
	mov	w3, #2048
	bl	_OF_getprop
	cmp	x0, #1
	b.lt	LBB0_9
; %bb.2:
	str	x20, [sp, #16]
Lloh7:
	adrp	x1, l_.str.2@PAGE
Lloh8:
	add	x1, x1, l_.str.2@PAGEOFF
	add	x0, sp, #16
	bl	_strsep
	str	x0, [sp, #8]
	cbz	x0, LBB0_9
; %bb.3:
Lloh9:
	adrp	x20, l_.str.2@PAGE
Lloh10:
	add	x20, x20, l_.str.2@PAGEOFF
Lloh11:
	adrp	x21, l_.str.3@PAGE
Lloh12:
	add	x21, x21, l_.str.3@PAGEOFF
	mov	w23, #1
Lloh13:
	adrp	x22, l_.str.4@PAGE
Lloh14:
	add	x22, x22, l_.str.4@PAGEOFF
	b	LBB0_5
LBB0_4:                                 ;   in Loop: Header=BB0_5 Depth=1
	add	x0, sp, #16
	mov	x1, x20
	bl	_strsep
	str	x0, [sp, #8]
	cbz	x0, LBB0_9
LBB0_5:                                 ; =>This Inner Loop Header: Depth=1
	ldrb	w8, [x0]
	cbz	w8, LBB0_4
; %bb.6:                                ;   in Loop: Header=BB0_5 Depth=1
	add	x0, sp, #8
	mov	x1, x21
	bl	_strsep
	mov	x1, x22
	bl	_strcmp
	ldr	x8, [sp, #8]
	cmp	x0, #0
	ccmp	x8, #0, #4, eq
	b.eq	LBB0_4
; %bb.7:                                ;   in Loop: Header=BB0_5 Depth=1
	ldrb	w8, [x8]
	cmp	w8, #49
	b.ne	LBB0_4
; %bb.8:                                ;   in Loop: Header=BB0_5 Depth=1
	str	w23, [x19]
	b	LBB0_4
LBB0_9:
	mov	x0, x19
	bl	_bcm_fb_sysctl_init
	mov	x0, x19
	bl	_bcm_fb_setup_fbd
	ldur	x8, [x29, #-56]
Lloh15:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh16:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh17:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_11
; %bb.10:
	add	sp, sp, #2080
	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
	ldp	x24, x23, [sp], #64             ; 16-byte Folded Reload
	ret
LBB0_11:
	bl	___stack_chk_fail
	.loh AdrpAdd	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh5, Lloh6
	.loh AdrpAdd	Lloh7, Lloh8
	.loh AdrpAdd	Lloh13, Lloh14
	.loh AdrpAdd	Lloh11, Lloh12
	.loh AdrpAdd	Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"/chosen"

l_.str.1:                               ; @.str.1
	.asciz	"bootargs"

l_.str.2:                               ; @.str.2
	.asciz	" "

l_.str.3:                               ; @.str.3
	.asciz	"="

l_.str.4:                               ; @.str.4
	.asciz	"bcm2708_fb.fbswap"

	.no_dead_strip	_bcm_fb_attach
.subsections_via_symbols
