	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function tx4939ide_set_pio_mode
_tx4939ide_set_pio_mode:                ## @tx4939ide_set_pio_mode
	.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	%rbx
	pushq	%rax
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%esi, %ebx
	movq	8(%rdi), %r14
	movl	(%rdi), %r15d
	callq	_ide_get_pair_dev
	movq	%rax, %rdi
	movl	%ebx, %eax
	testq	%rdi, %rdi
	je	LBB0_2
## %bb.1:
	movl	$255, %esi
	movl	$4, %edx
	callq	_ide_get_best_pio_mode
	movl	%ebx, %edi
	movl	%eax, %esi
	callq	_min
LBB0_2:
	shll	$8, %eax
	shll	$4, %ebx
	orl	%eax, %ebx
	testl	%r15d, %r15d
	setne	%cl
	movl	$-2033, %eax                    ## imm = 0xF80F
	movl	$-133169153, %edx               ## imm = 0xF80FFFFF
	cmovel	%eax, %edx
	shlb	$4, %cl
	shll	%cl, %ebx
	andl	(%r14), %edx
	orl	%ebx, %edx
	movl	%edx, (%r14)
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.no_dead_strip	_tx4939ide_set_pio_mode
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function tx4939ide_set_pio_mode
_tx4939ide_set_pio_mode:                ; @tx4939ide_set_pio_mode
	.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, x1
	ldr	x20, [x0, #8]
	ldr	w21, [x0]
	bl	_ide_get_pair_dev
	mov	x8, x0
	mov	x0, x19
	cbz	x8, LBB0_2
; %bb.1:
	mov	x0, x8
	mov	w1, #255
	mov	w2, #4
	bl	_ide_get_best_pio_mode
	mov	x1, x0
	mov	x0, x19
	bl	_min
LBB0_2:
	mov	w8, #-133169153
	mov	w9, #-2033
	cmp	w21, #0
	csel	w8, w9, w8, eq
	cset	w9, ne
	lsl	w10, w0, #8
	orr	w10, w10, w19, lsl #4
	lsl	x9, x9, #4
	lsl	w9, w10, w9
	ldr	w10, [x20]
	and	w8, w10, w8
	orr	w8, w9, w8
	str	w8, [x20]
	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
	.cfi_endproc
                                        ; -- End function
	.no_dead_strip	_tx4939ide_set_pio_mode
.subsections_via_symbols
