	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function tpacpi_brightness_set_ucmsstep
_tpacpi_brightness_set_ucmsstep:        ## @tpacpi_brightness_set_ucmsstep
	.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	%r12
	pushq	%rbx
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%edi, %r15d
	xorl	%r14d, %r14d
	xorl	%eax, %eax
	callq	_tpacpi_brightness_nvram_get
	movl	%eax, %ebx
	subl	%r15d, %ebx
	je	LBB0_8
## %bb.1:
	setb	%al
	jae	LBB0_2
## %bb.3:
	movq	_TP_CMOS_BRIGHTNESS_UP@GOTPCREL(%rip), %rcx
	jmp	LBB0_4
LBB0_2:
	movq	_TP_CMOS_BRIGHTNESS_DOWN@GOTPCREL(%rip), %rcx
LBB0_4:
	movl	(%rcx), %r15d
	movzbl	%al, %eax
	leal	(%rax,%rax), %r12d
	decl	%r12d
	.p2align	4, 0x90
LBB0_6:                                 ## =>This Inner Loop Header: Depth=1
	movl	%r15d, %edi
	callq	_issue_thinkpad_cmos_command
	testq	%rax, %rax
	jne	LBB0_7
## %bb.5:                               ##   in Loop: Header=BB0_6 Depth=1
	addl	%r12d, %ebx
	jne	LBB0_6
	jmp	LBB0_8
LBB0_7:
	movq	_EIO@GOTPCREL(%rip), %rax
	xorl	%r14d, %r14d
	subl	(%rax), %r14d
LBB0_8:
	movl	%r14d, %eax
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_TP_CMOS_BRIGHTNESS_UP,4,2      ## @TP_CMOS_BRIGHTNESS_UP
	.comm	_TP_CMOS_BRIGHTNESS_DOWN,4,2    ## @TP_CMOS_BRIGHTNESS_DOWN
	.comm	_EIO,4,2                        ## @EIO
	.no_dead_strip	_tpacpi_brightness_set_ucmsstep
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function tpacpi_brightness_set_ucmsstep
_tpacpi_brightness_set_ucmsstep:        ; @tpacpi_brightness_set_ucmsstep
	.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	_tpacpi_brightness_nvram_get
	subs	w20, w0, w19
	b.eq	LBB0_4
; %bb.1:
Lloh0:
	adrp	x8, _TP_CMOS_BRIGHTNESS_UP@GOTPAGE
Lloh1:
	ldr	x8, [x8, _TP_CMOS_BRIGHTNESS_UP@GOTPAGEOFF]
Lloh2:
	adrp	x9, _TP_CMOS_BRIGHTNESS_DOWN@GOTPAGE
Lloh3:
	ldr	x9, [x9, _TP_CMOS_BRIGHTNESS_DOWN@GOTPAGEOFF]
	csel	x8, x8, x9, lo
	ldr	w19, [x8]
	mov	w8, #1
	cneg	w21, w8, hs
LBB0_2:                                 ; =>This Inner Loop Header: Depth=1
	mov	x0, x19
	bl	_issue_thinkpad_cmos_command
	cbnz	x0, LBB0_5
; %bb.3:                                ;   in Loop: Header=BB0_2 Depth=1
	adds	w20, w20, w21
	b.ne	LBB0_2
LBB0_4:
	mov	w0, #0
	b	LBB0_6
LBB0_5:
Lloh4:
	adrp	x8, _EIO@GOTPAGE
Lloh5:
	ldr	x8, [x8, _EIO@GOTPAGEOFF]
Lloh6:
	ldr	w8, [x8]
	neg	w0, w8
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
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh4, Lloh5, Lloh6
	.cfi_endproc
                                        ; -- End function
	.comm	_TP_CMOS_BRIGHTNESS_UP,4,2      ; @TP_CMOS_BRIGHTNESS_UP
	.comm	_TP_CMOS_BRIGHTNESS_DOWN,4,2    ; @TP_CMOS_BRIGHTNESS_DOWN
	.comm	_EIO,4,2                        ; @EIO
	.no_dead_strip	_tpacpi_brightness_set_ucmsstep
.subsections_via_symbols
