	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function pxav2_mmc_set_bus_width
_pxav2_mmc_set_bus_width:               ## @pxav2_mmc_set_bus_width
	.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	%esi, %r15d
	movq	%rdi, %rbx
	movq	_SDHCI_HOST_CONTROL@GOTPCREL(%rip), %r12
	movq	(%r12), %rdi
	addq	(%rbx), %rdi
	callq	_readb
	movl	%eax, %r14d
	movq	_SD_CE_ATA_2@GOTPCREL(%rip), %r13
	movq	(%r13), %rdi
	addq	(%rbx), %rdi
	callq	_readw
	movq	_MMC_BUS_WIDTH_8@GOTPCREL(%rip), %rcx
	cmpl	%r15d, (%rcx)
	jne	LBB0_2
## %bb.1:
	movq	_SDHCI_CTRL_4BITBUS@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	notl	%ecx
	andl	%ecx, %r14d
	movq	_MMC_CARD@GOTPCREL(%rip), %rcx
	movq	_MMC_WIDTH@GOTPCREL(%rip), %rdx
	orl	(%rcx), %eax
	orl	(%rdx), %eax
	jmp	LBB0_5
LBB0_2:
	movq	_MMC_CARD@GOTPCREL(%rip), %rcx
	movq	_MMC_WIDTH@GOTPCREL(%rip), %rdx
	movl	(%rdx), %edx
	orl	(%rcx), %edx
	notl	%edx
	andl	%edx, %eax
	movq	_MMC_BUS_WIDTH_4@GOTPCREL(%rip), %rdx
	movq	_SDHCI_CTRL_4BITBUS@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	cmpl	%r15d, (%rdx)
	jne	LBB0_4
## %bb.3:
	orl	%ecx, %r14d
	jmp	LBB0_5
LBB0_4:
	notl	%ecx
	andl	%ecx, %r14d
LBB0_5:
	movq	(%r13), %rsi
	addq	(%rbx), %rsi
	movl	%eax, %edi
	callq	_writew
	movq	(%r12), %rsi
	addq	(%rbx), %rsi
	movl	%r14d, %edi
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_writeb                         ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_SDHCI_HOST_CONTROL,8,3         ## @SDHCI_HOST_CONTROL
	.comm	_SD_CE_ATA_2,8,3                ## @SD_CE_ATA_2
	.comm	_MMC_BUS_WIDTH_8,4,2            ## @MMC_BUS_WIDTH_8
	.comm	_SDHCI_CTRL_4BITBUS,4,2         ## @SDHCI_CTRL_4BITBUS
	.comm	_MMC_CARD,4,2                   ## @MMC_CARD
	.comm	_MMC_WIDTH,4,2                  ## @MMC_WIDTH
	.comm	_MMC_BUS_WIDTH_4,4,2            ## @MMC_BUS_WIDTH_4
	.no_dead_strip	_pxav2_mmc_set_bus_width
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function pxav2_mmc_set_bus_width
_pxav2_mmc_set_bus_width:               ; @pxav2_mmc_set_bus_width
	.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
	mov	x20, x1
	mov	x19, x0
	ldr	x8, [x0]
Lloh0:
	adrp	x22, _SDHCI_HOST_CONTROL@GOTPAGE
Lloh1:
	ldr	x22, [x22, _SDHCI_HOST_CONTROL@GOTPAGEOFF]
	ldr	x9, [x22]
	add	x0, x9, x8
	bl	_readb
	mov	x21, x0
	ldr	x8, [x19]
Lloh2:
	adrp	x23, _SD_CE_ATA_2@GOTPAGE
Lloh3:
	ldr	x23, [x23, _SD_CE_ATA_2@GOTPAGEOFF]
	ldr	x9, [x23]
	add	x0, x9, x8
	bl	_readw
Lloh4:
	adrp	x8, _MMC_BUS_WIDTH_8@GOTPAGE
Lloh5:
	ldr	x8, [x8, _MMC_BUS_WIDTH_8@GOTPAGEOFF]
Lloh6:
	ldr	w8, [x8]
	cmp	w8, w20
	b.ne	LBB0_2
; %bb.1:
Lloh7:
	adrp	x8, _SDHCI_CTRL_4BITBUS@GOTPAGE
Lloh8:
	ldr	x8, [x8, _SDHCI_CTRL_4BITBUS@GOTPAGEOFF]
Lloh9:
	ldr	w8, [x8]
	bic	w20, w21, w8
Lloh10:
	adrp	x8, _MMC_CARD@GOTPAGE
Lloh11:
	ldr	x8, [x8, _MMC_CARD@GOTPAGEOFF]
Lloh12:
	ldr	w8, [x8]
Lloh13:
	adrp	x9, _MMC_WIDTH@GOTPAGE
Lloh14:
	ldr	x9, [x9, _MMC_WIDTH@GOTPAGEOFF]
Lloh15:
	ldr	w9, [x9]
	orr	w8, w8, w0
	orr	w0, w8, w9
	b	LBB0_3
LBB0_2:
Lloh16:
	adrp	x8, _MMC_CARD@GOTPAGE
Lloh17:
	ldr	x8, [x8, _MMC_CARD@GOTPAGEOFF]
Lloh18:
	ldr	w8, [x8]
Lloh19:
	adrp	x9, _MMC_WIDTH@GOTPAGE
Lloh20:
	ldr	x9, [x9, _MMC_WIDTH@GOTPAGEOFF]
Lloh21:
	ldr	w9, [x9]
	orr	w8, w9, w8
	bic	w0, w0, w8
Lloh22:
	adrp	x8, _MMC_BUS_WIDTH_4@GOTPAGE
Lloh23:
	ldr	x8, [x8, _MMC_BUS_WIDTH_4@GOTPAGEOFF]
Lloh24:
	adrp	x9, _SDHCI_CTRL_4BITBUS@GOTPAGE
Lloh25:
	ldr	x9, [x9, _SDHCI_CTRL_4BITBUS@GOTPAGEOFF]
Lloh26:
	ldr	w8, [x8]
Lloh27:
	ldr	w9, [x9]
	bic	w10, w21, w9
	orr	w9, w9, w21
	cmp	w8, w20
	csel	w20, w10, w9, ne
LBB0_3:
	ldr	x8, [x19]
	ldr	x9, [x23]
	add	x1, x9, x8
	bl	_writew
	ldr	x8, [x19]
	ldr	x9, [x22]
	add	x1, x9, x8
	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
	ldp	x24, x23, [sp], #64             ; 16-byte Folded Reload
	b	_writeb
	.loh AdrpLdrGotLdr	Lloh4, Lloh5, Lloh6
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh13, Lloh14, Lloh15
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh12
	.loh AdrpLdrGotLdr	Lloh7, Lloh8, Lloh9
	.loh AdrpLdrGotLdr	Lloh24, Lloh25, Lloh27
	.loh AdrpLdrGotLdr	Lloh22, Lloh23, Lloh26
	.loh AdrpLdrGotLdr	Lloh19, Lloh20, Lloh21
	.loh AdrpLdrGotLdr	Lloh16, Lloh17, Lloh18
	.cfi_endproc
                                        ; -- End function
	.comm	_SDHCI_HOST_CONTROL,8,3         ; @SDHCI_HOST_CONTROL
	.comm	_SD_CE_ATA_2,8,3                ; @SD_CE_ATA_2
	.comm	_MMC_BUS_WIDTH_8,4,2            ; @MMC_BUS_WIDTH_8
	.comm	_SDHCI_CTRL_4BITBUS,4,2         ; @SDHCI_CTRL_4BITBUS
	.comm	_MMC_CARD,4,2                   ; @MMC_CARD
	.comm	_MMC_WIDTH,4,2                  ; @MMC_WIDTH
	.comm	_MMC_BUS_WIDTH_4,4,2            ; @MMC_BUS_WIDTH_4
	.no_dead_strip	_pxav2_mmc_set_bus_width
.subsections_via_symbols
