	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function ql_wait_for_drvr_lock
_ql_wait_for_drvr_lock:                 ## @ql_wait_for_drvr_lock
	.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
	movq	%rdi, %r14
	movl	$10, %ebx
	movq	_QL_DRVR_SEM_MASK@GOTPCREL(%rip), %r15
	movq	_QL_RESOURCE_BITS_BASE_CODE@GOTPCREL(%rip), %r12
	.p2align	4, 0x90
LBB0_1:                                 ## =>This Inner Loop Header: Depth=1
	movl	(%r15), %esi
	movl	(%r12), %edx
	movl	(%r14), %eax
	shll	$2, %eax
	addl	%edx, %edx
	orl	%eax, %edx
	movq	%r14, %rdi
	callq	_ql_sem_lock
	testq	%rax, %rax
	jne	LBB0_2
## %bb.3:                               ##   in Loop: Header=BB0_1 Depth=1
	movl	$1, %edi
	callq	_ssleep
	decl	%ebx
	jne	LBB0_1
## %bb.4:
	movl	4(%r14), %edi
	leaq	L_.str.1(%rip), %rsi
	callq	_netdev_err
	xorl	%eax, %eax
	jmp	LBB0_5
LBB0_2:
	movq	_KERN_DEBUG@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movl	4(%r14), %esi
	leaq	L_.str(%rip), %rdx
	callq	_netdev_printk
	movl	$1, %eax
LBB0_5:
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_QL_DRVR_SEM_MASK,4,2           ## @QL_DRVR_SEM_MASK
	.comm	_QL_RESOURCE_BITS_BASE_CODE,4,2 ## @QL_RESOURCE_BITS_BASE_CODE
	.comm	_KERN_DEBUG,4,2                 ## @KERN_DEBUG
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"driver lock acquired\n"

L_.str.1:                               ## @.str.1
	.asciz	"Timed out waiting for driver lock...\n"

	.no_dead_strip	_ql_wait_for_drvr_lock
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function ql_wait_for_drvr_lock
_ql_wait_for_drvr_lock:                 ; @ql_wait_for_drvr_lock
	.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
	mov	w20, #10
Lloh0:
	adrp	x21, _QL_DRVR_SEM_MASK@GOTPAGE
Lloh1:
	ldr	x21, [x21, _QL_DRVR_SEM_MASK@GOTPAGEOFF]
Lloh2:
	adrp	x22, _QL_RESOURCE_BITS_BASE_CODE@GOTPAGE
Lloh3:
	ldr	x22, [x22, _QL_RESOURCE_BITS_BASE_CODE@GOTPAGEOFF]
LBB0_1:                                 ; =>This Inner Loop Header: Depth=1
	ldr	w1, [x21]
	ldr	w8, [x22]
	ldr	w9, [x19]
	lsl	w9, w9, #2
	orr	w2, w9, w8, lsl #1
	mov	x0, x19
	bl	_ql_sem_lock
	cbnz	x0, LBB0_4
; %bb.2:                                ;   in Loop: Header=BB0_1 Depth=1
	mov	w0, #1
	bl	_ssleep
	subs	w20, w20, #1
	b.ne	LBB0_1
; %bb.3:
	ldr	w0, [x19, #4]
Lloh4:
	adrp	x1, l_.str.1@PAGE
Lloh5:
	add	x1, x1, l_.str.1@PAGEOFF
	bl	_netdev_err
	mov	w0, #0
	b	LBB0_5
LBB0_4:
Lloh6:
	adrp	x8, _KERN_DEBUG@GOTPAGE
Lloh7:
	ldr	x8, [x8, _KERN_DEBUG@GOTPAGEOFF]
Lloh8:
	ldr	w0, [x8]
	ldr	w1, [x19, #4]
Lloh9:
	adrp	x2, l_.str@PAGE
Lloh10:
	add	x2, x2, l_.str@PAGEOFF
	bl	_netdev_printk
	mov	w0, #1
LBB0_5:
	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 AdrpAdd	Lloh4, Lloh5
	.loh AdrpAdd	Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.cfi_endproc
                                        ; -- End function
	.comm	_QL_DRVR_SEM_MASK,4,2           ; @QL_DRVR_SEM_MASK
	.comm	_QL_RESOURCE_BITS_BASE_CODE,4,2 ; @QL_RESOURCE_BITS_BASE_CODE
	.comm	_KERN_DEBUG,4,2                 ; @KERN_DEBUG
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"driver lock acquired\n"

l_.str.1:                               ; @.str.1
	.asciz	"Timed out waiting for driver lock...\n"

	.no_dead_strip	_ql_wait_for_drvr_lock
.subsections_via_symbols
