	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_rt2x00leds_led_quality         ## -- Begin function rt2x00leds_led_quality
	.p2align	4, 0x90
_rt2x00leds_led_quality:                ## @rt2x00leds_led_quality
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%r14
	pushq	%rbx
	.cfi_offset %rbx, -32
	.cfi_offset %r14, -24
	movq	8(%rdi), %rax
	movq	_LED_TYPE_QUALITY@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_9
## %bb.1:
	movq	%rdi, %r14
	movq	_LED_REGISTERED@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	testl	%eax, 16(%rdi)
	je	LBB0_9
## %bb.2:
	addl	(%r14), %esi
	xorl	%eax, %eax
	cmpl	$31, %esi
	jl	LBB0_7
## %bb.3:
	movl	$1, %eax
	cmpl	$40, %esi
	jb	LBB0_7
## %bb.4:
	movl	$2, %eax
	cmpl	$50, %esi
	jb	LBB0_7
## %bb.5:
	movl	$3, %eax
	cmpl	$54, %esi
	jb	LBB0_7
## %bb.6:
	cmpl	$64, %esi
	movl	$5, %eax
	sbbl	$0, %eax
LBB0_7:
	movq	_LED_FULL@GOTPCREL(%rip), %rcx
	movslq	(%rcx), %rcx
	imulq	$715827883, %rcx, %rbx          ## imm = 0x2AAAAAAB
	movq	%rbx, %rcx
	shrq	$63, %rcx
	shrq	$32, %rbx
	addl	%ecx, %ebx
	imull	%eax, %ebx
	incl	%ebx
	cmpl	24(%r14), %ebx
	je	LBB0_9
## %bb.8:
	leaq	24(%r14), %rdi
	movl	%ebx, %esi
	callq	*32(%r14)
	movl	%ebx, 24(%r14)
LBB0_9:
	popq	%rbx
	popq	%r14
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_LED_TYPE_QUALITY,8,3           ## @LED_TYPE_QUALITY
	.comm	_LED_REGISTERED,4,2             ## @LED_REGISTERED
	.comm	_LED_FULL,4,2                   ## @LED_FULL
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_rt2x00leds_led_quality         ; -- Begin function rt2x00leds_led_quality
	.p2align	2
_rt2x00leds_led_quality:                ; @rt2x00leds_led_quality
	.cfi_startproc
; %bb.0:
	stp	x20, x19, [sp, #-32]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 32
	stp	x29, x30, [sp, #16]             ; 16-byte Folded Spill
	add	x29, sp, #16
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	ldr	x8, [x0, #8]
Lloh0:
	adrp	x9, _LED_TYPE_QUALITY@GOTPAGE
Lloh1:
	ldr	x9, [x9, _LED_TYPE_QUALITY@GOTPAGEOFF]
Lloh2:
	ldr	x9, [x9]
	cmp	x8, x9
	b.ne	LBB0_4
; %bb.1:
	mov	x19, x0
	ldr	w8, [x0, #16]
Lloh3:
	adrp	x9, _LED_REGISTERED@GOTPAGE
Lloh4:
	ldr	x9, [x9, _LED_REGISTERED@GOTPAGEOFF]
Lloh5:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_4
; %bb.2:
	ldr	w8, [x19]
	add	w8, w8, w1
	mov	w9, #1
	mov	w10, #2
	mov	w11, #3
	cmp	w8, #64
	mov	w12, #4
	cinc	w12, w12, hs
	cmp	w8, #54
	csel	w11, w11, w12, lo
	cmp	w8, #50
	csel	w10, w10, w11, lo
	cmp	w8, #40
	csel	w9, w9, w10, lo
	cmp	w8, #31
	csel	w8, wzr, w9, lt
Lloh6:
	adrp	x9, _LED_FULL@GOTPAGE
Lloh7:
	ldr	x9, [x9, _LED_FULL@GOTPAGEOFF]
Lloh8:
	ldrsw	x9, [x9]
	mov	w10, #43691
	movk	w10, #10922, lsl #16
	mul	x9, x9, x10
	lsr	x10, x9, #63
	lsr	x9, x9, #32
	add	w9, w9, w10
	orr	w10, wzr, #0x1
	madd	w20, w9, w8, w10
	mov	x0, x19
	ldr	w8, [x0, #24]!
	cmp	w20, w8
	b.eq	LBB0_4
; %bb.3:
	ldr	x8, [x19, #32]
	mov	x1, x20
	blr	x8
	str	w20, [x19, #24]
LBB0_4:
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.cfi_endproc
                                        ; -- End function
	.comm	_LED_TYPE_QUALITY,8,3           ; @LED_TYPE_QUALITY
	.comm	_LED_REGISTERED,4,2             ; @LED_REGISTERED
	.comm	_LED_FULL,4,2                   ; @LED_FULL
.subsections_via_symbols
