	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function gigaset_suspend
_gigaset_suspend:                       ## @gigaset_suspend
	.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
	callq	_usb_get_intfdata
	movq	%rax, %r14
	movq	8(%rax), %r15
	movq	_BS_SUSPEND@GOTPCREL(%rip), %rbx
	movl	(%rbx), %esi
	xorl	%r12d, %r12d
	movq	%r15, %rdi
	xorl	%edx, %edx
	callq	_update_basstate
	testl	%eax, (%rbx)
	je	LBB0_2
## %bb.1:
	movq	_DEBUG_SUSPEND@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	L_.str(%rip), %rsi
LBB0_17:
	xorl	%eax, %eax
	callq	_gig_dbg
	jmp	LBB0_18
LBB0_2:
	movq	_BS_B1OPEN@GOTPCREL(%rip), %rbx
	movq	_BS_B2OPEN@GOTPCREL(%rip), %r12
	movl	(%r12), %eax
	orl	(%rbx), %eax
	movq	_BS_ATRDPEND@GOTPCREL(%rip), %rcx
	orl	(%rcx), %eax
	movq	_BS_ATWRPEND@GOTPCREL(%rip), %r13
	orl	(%r13), %eax
	xorl	%esi, %esi
	andl	(%r15), %eax
	movl	20(%r15), %edi
	sete	%sil
	movq	_BAS_TIMEOUT@GOTPCREL(%rip), %rcx
	movq	_HZ@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	imull	(%rcx), %eax
	cltq
	imulq	$1717986919, %rax, %rdx         ## imm = 0x66666667
	movq	%rdx, %rax
	shrq	$63, %rax
	sarq	$34, %rdx
	addl	%eax, %edx
                                        ## kill: def $edx killed $edx killed $rdx
	callq	_wait_event_timeout
	movq	_DEBUG_SUSPEND@GOTPCREL(%rip), %rcx
	movl	(%rcx), %edi
	leaq	L_.str.1(%rip), %rsi
	movl	%eax, %edx
	xorl	%eax, %eax
	callq	_gig_dbg
	movl	(%r12), %ecx
	orl	(%rbx), %ecx
	movq	_BS_ATRDPEND@GOTPCREL(%rip), %rax
	orl	(%rax), %ecx
	movl	(%r15), %eax
	orl	(%r13), %ecx
	testl	%eax, %ecx
	je	LBB0_12
## %bb.3:
	movl	4(%r14), %edi
	leaq	L_.str.2(%rip), %rsi
	callq	_dev_warn
	movl	(%r15), %eax
	testl	%eax, (%rbx)
	je	LBB0_5
## %bb.4:
	movl	4(%r14), %edi
	leaq	L_.str.3(%rip), %rsi
	callq	_dev_warn
	movl	(%r15), %eax
LBB0_5:
	movq	_BS_B2OPEN@GOTPCREL(%rip), %rcx
	testl	%eax, (%rcx)
	movq	_BS_SUSPEND@GOTPCREL(%rip), %rbx
	je	LBB0_7
## %bb.6:
	movl	4(%r14), %edi
	leaq	L_.str.4(%rip), %rsi
	callq	_dev_warn
	movl	(%r15), %eax
LBB0_7:
	movq	_BS_ATRDPEND@GOTPCREL(%rip), %rcx
	testl	%eax, (%rcx)
	je	LBB0_9
## %bb.8:
	movl	4(%r14), %edi
	leaq	L_.str.5(%rip), %rsi
	callq	_dev_warn
	movl	(%r15), %eax
LBB0_9:
	movq	_BS_ATWRPEND@GOTPCREL(%rip), %rcx
	testl	%eax, (%rcx)
	je	LBB0_11
## %bb.10:
	movl	4(%r14), %edi
	leaq	L_.str.6(%rip), %rsi
	callq	_dev_warn
LBB0_11:
	movl	(%rbx), %edx
	xorl	%r12d, %r12d
	movq	%r15, %rdi
	xorl	%esi, %esi
	callq	_update_basstate
	movq	_EBUSY@GOTPCREL(%rip), %rax
	subl	(%rax), %r12d
LBB0_18:
	movl	%r12d, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_12:
	movq	_HZ@GOTPCREL(%rip), %rbx
	movq	_BS_ATOPEN@GOTPCREL(%rip), %rcx
	testl	%eax, (%rcx)
	movq	_DEBUG_SUSPEND@GOTPCREL(%rip), %r13
	je	LBB0_16
## %bb.13:
	movl	(%r13), %edi
	leaq	L_.str.7(%rip), %rsi
	xorl	%eax, %eax
	callq	_gig_dbg
	movl	(%r14), %edi
	movq	_HD_CLOSE_ATCHANNEL@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	xorl	%edx, %edx
	xorl	%ecx, %ecx
	callq	_req_submit
	testl	%eax, %eax
	je	LBB0_15
## %bb.14:
	movl	%eax, %r12d
	movq	_BS_SUSPEND@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%r15, %rdi
	xorl	%esi, %esi
	callq	_update_basstate
	jmp	LBB0_18
LBB0_15:
	movl	20(%r15), %edi
	xorl	%esi, %esi
	cmpl	$0, 16(%r15)
	sete	%sil
	movl	(%rbx), %eax
	movq	_BAS_TIMEOUT@GOTPCREL(%rip), %rcx
	imull	(%rcx), %eax
	cltq
	imulq	$1717986919, %rax, %rdx         ## imm = 0x66666667
	movq	%rdx, %rax
	shrq	$63, %rax
	sarq	$34, %rdx
	addl	%eax, %edx
                                        ## kill: def $edx killed $edx killed $rdx
	callq	_wait_event_timeout
LBB0_16:
	movl	12(%r15), %edi
	callq	_usb_kill_urb
	movl	8(%r15), %edi
	callq	_usb_kill_urb
	addq	$4, %r15
	movq	%r15, %rdi
	callq	_del_timer_sync
	movl	(%r13), %edi
	leaq	L_.str.8(%rip), %rsi
	xorl	%r12d, %r12d
	jmp	LBB0_17
	.cfi_endproc
                                        ## -- End function
	.comm	_BS_SUSPEND,4,2                 ## @BS_SUSPEND
	.comm	_DEBUG_SUSPEND,4,2              ## @DEBUG_SUSPEND
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"already suspended"

	.comm	_BS_B1OPEN,4,2                  ## @BS_B1OPEN
	.comm	_BS_B2OPEN,4,2                  ## @BS_B2OPEN
	.comm	_BS_ATRDPEND,4,2                ## @BS_ATRDPEND
	.comm	_BS_ATWRPEND,4,2                ## @BS_ATWRPEND
	.comm	_BAS_TIMEOUT,4,2                ## @BAS_TIMEOUT
	.comm	_HZ,4,2                         ## @HZ
L_.str.1:                               ## @.str.1
	.asciz	"wait_event_timeout() -> %d"

L_.str.2:                               ## @.str.2
	.asciz	"cannot suspend:\n"

L_.str.3:                               ## @.str.3
	.asciz	" B channel 1 open\n"

L_.str.4:                               ## @.str.4
	.asciz	" B channel 2 open\n"

L_.str.5:                               ## @.str.5
	.asciz	" receiving AT reply\n"

L_.str.6:                               ## @.str.6
	.asciz	" sending AT command\n"

	.comm	_EBUSY,4,2                      ## @EBUSY
	.comm	_BS_ATOPEN,4,2                  ## @BS_ATOPEN
L_.str.7:                               ## @.str.7
	.asciz	"closing AT channel"

	.comm	_HD_CLOSE_ATCHANNEL,4,2         ## @HD_CLOSE_ATCHANNEL
L_.str.8:                               ## @.str.8
	.asciz	"suspend complete"

	.no_dead_strip	_gigaset_suspend
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function gigaset_suspend
_gigaset_suspend:                       ; @gigaset_suspend
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #112
	.cfi_def_cfa_offset 112
	stp	x28, x27, [sp, #16]             ; 16-byte Folded Spill
	stp	x26, x25, [sp, #32]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #48]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #64]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #80]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #96]             ; 16-byte Folded Spill
	add	x29, sp, #96
	.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
	.cfi_offset w25, -72
	.cfi_offset w26, -80
	.cfi_offset w27, -88
	.cfi_offset w28, -96
	bl	_usb_get_intfdata
	mov	x20, x0
	ldr	x19, [x0, #8]
Lloh0:
	adrp	x21, _BS_SUSPEND@GOTPAGE
Lloh1:
	ldr	x21, [x21, _BS_SUSPEND@GOTPAGEOFF]
	ldr	w1, [x21]
	mov	x0, x19
	mov	w2, #0
	bl	_update_basstate
	ldr	w8, [x21]
	tst	w8, w0
	b.eq	LBB0_3
; %bb.1:
Lloh2:
	adrp	x8, _DEBUG_SUSPEND@GOTPAGE
Lloh3:
	ldr	x8, [x8, _DEBUG_SUSPEND@GOTPAGEOFF]
Lloh4:
	ldr	w0, [x8]
Lloh5:
	adrp	x1, l_.str@PAGE
Lloh6:
	add	x1, x1, l_.str@PAGEOFF
LBB0_2:
	bl	_gig_dbg
	mov	w20, #0
	b	LBB0_13
LBB0_3:
	ldr	w0, [x19, #20]
	ldr	w8, [x19]
Lloh7:
	adrp	x28, _BS_B1OPEN@GOTPAGE
Lloh8:
	ldr	x28, [x28, _BS_B1OPEN@GOTPAGEOFF]
	ldr	w9, [x28]
Lloh9:
	adrp	x25, _BS_B2OPEN@GOTPAGE
Lloh10:
	ldr	x25, [x25, _BS_B2OPEN@GOTPAGEOFF]
	ldr	w10, [x25]
	orr	w9, w10, w9
Lloh11:
	adrp	x23, _BS_ATRDPEND@GOTPAGE
Lloh12:
	ldr	x23, [x23, _BS_ATRDPEND@GOTPAGEOFF]
	ldr	w10, [x23]
	orr	w9, w9, w10
Lloh13:
	adrp	x22, _BS_ATWRPEND@GOTPAGE
Lloh14:
	ldr	x22, [x22, _BS_ATWRPEND@GOTPAGEOFF]
	ldr	w10, [x22]
	orr	w9, w9, w10
	tst	w9, w8
	cset	w1, eq
Lloh15:
	adrp	x26, _BAS_TIMEOUT@GOTPAGE
Lloh16:
	ldr	x26, [x26, _BAS_TIMEOUT@GOTPAGEOFF]
	ldr	w8, [x26]
Lloh17:
	adrp	x27, _HZ@GOTPAGE
Lloh18:
	ldr	x27, [x27, _HZ@GOTPAGEOFF]
	ldr	w9, [x27]
	mul	w8, w9, w8
	mov	w9, #26215
	movk	w9, #26214, lsl #16
	smull	x8, w8, w9
	lsr	x9, x8, #63
	asr	x8, x8, #34
	add	w2, w8, w9
	bl	_wait_event_timeout
                                        ; kill: def $w0 killed $w0 def $x0
Lloh19:
	adrp	x24, _DEBUG_SUSPEND@GOTPAGE
Lloh20:
	ldr	x24, [x24, _DEBUG_SUSPEND@GOTPAGEOFF]
	ldr	w8, [x24]
	str	x0, [sp]
Lloh21:
	adrp	x1, l_.str.1@PAGE
Lloh22:
	add	x1, x1, l_.str.1@PAGEOFF
	mov	x0, x8
	bl	_gig_dbg
	ldr	w8, [x19]
	ldr	w9, [x28]
	ldr	w10, [x25]
	orr	w9, w10, w9
	ldr	w10, [x23]
	orr	w9, w9, w10
	ldr	w10, [x22]
	orr	w9, w9, w10
	tst	w9, w8
	b.eq	LBB0_14
; %bb.4:
	ldr	w0, [x20, #4]
Lloh23:
	adrp	x1, l_.str.2@PAGE
Lloh24:
	add	x1, x1, l_.str.2@PAGEOFF
	bl	_dev_warn
	ldr	w8, [x19]
	ldr	w9, [x28]
	tst	w9, w8
	b.eq	LBB0_6
; %bb.5:
	ldr	w0, [x20, #4]
Lloh25:
	adrp	x1, l_.str.3@PAGE
Lloh26:
	add	x1, x1, l_.str.3@PAGEOFF
	bl	_dev_warn
	ldr	w8, [x19]
LBB0_6:
	ldr	w9, [x25]
	tst	w9, w8
	b.eq	LBB0_8
; %bb.7:
	ldr	w0, [x20, #4]
Lloh27:
	adrp	x1, l_.str.4@PAGE
Lloh28:
	add	x1, x1, l_.str.4@PAGEOFF
	bl	_dev_warn
	ldr	w8, [x19]
LBB0_8:
	ldr	w9, [x23]
	tst	w9, w8
	b.eq	LBB0_10
; %bb.9:
	ldr	w0, [x20, #4]
Lloh29:
	adrp	x1, l_.str.5@PAGE
Lloh30:
	add	x1, x1, l_.str.5@PAGEOFF
	bl	_dev_warn
	ldr	w8, [x19]
LBB0_10:
	ldr	w9, [x22]
	tst	w9, w8
	b.eq	LBB0_12
; %bb.11:
	ldr	w0, [x20, #4]
Lloh31:
	adrp	x1, l_.str.6@PAGE
Lloh32:
	add	x1, x1, l_.str.6@PAGEOFF
	bl	_dev_warn
LBB0_12:
	ldr	w2, [x21]
	mov	x0, x19
	mov	w1, #0
	bl	_update_basstate
Lloh33:
	adrp	x8, _EBUSY@GOTPAGE
Lloh34:
	ldr	x8, [x8, _EBUSY@GOTPAGEOFF]
Lloh35:
	ldr	w8, [x8]
	neg	w20, w8
LBB0_13:
	mov	x0, x20
	ldp	x29, x30, [sp, #96]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #80]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #64]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #48]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #32]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #112
	ret
LBB0_14:
Lloh36:
	adrp	x9, _BS_ATOPEN@GOTPAGE
Lloh37:
	ldr	x9, [x9, _BS_ATOPEN@GOTPAGEOFF]
Lloh38:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_18
; %bb.15:
	ldr	w0, [x24]
Lloh39:
	adrp	x1, l_.str.7@PAGE
Lloh40:
	add	x1, x1, l_.str.7@PAGEOFF
	bl	_gig_dbg
	ldr	w0, [x20]
Lloh41:
	adrp	x8, _HD_CLOSE_ATCHANNEL@GOTPAGE
Lloh42:
	ldr	x8, [x8, _HD_CLOSE_ATCHANNEL@GOTPAGEOFF]
Lloh43:
	ldr	w1, [x8]
	mov	w2, #0
	mov	w3, #0
	bl	_req_submit
	cbz	w0, LBB0_17
; %bb.16:
	mov	x20, x0
	ldr	w2, [x21]
	mov	x0, x19
	mov	w1, #0
	bl	_update_basstate
	b	LBB0_13
LBB0_17:
	ldp	w8, w0, [x19, #16]
	cmp	w8, #0
	cset	w1, eq
	ldr	w8, [x26]
	ldr	w9, [x27]
	mul	w8, w9, w8
	mov	w9, #26215
	movk	w9, #26214, lsl #16
	smull	x8, w8, w9
	lsr	x9, x8, #63
	asr	x8, x8, #34
	add	w2, w8, w9
	bl	_wait_event_timeout
LBB0_18:
	ldr	w0, [x19, #12]
	bl	_usb_kill_urb
	ldr	w0, [x19, #8]
	bl	_usb_kill_urb
	add	x0, x19, #4
	bl	_del_timer_sync
	ldr	w0, [x24]
Lloh44:
	adrp	x1, l_.str.8@PAGE
Lloh45:
	add	x1, x1, l_.str.8@PAGEOFF
	b	LBB0_2
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpAdd	Lloh5, Lloh6
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpAdd	Lloh21, Lloh22
	.loh AdrpLdrGot	Lloh19, Lloh20
	.loh AdrpLdrGot	Lloh17, Lloh18
	.loh AdrpLdrGot	Lloh15, Lloh16
	.loh AdrpLdrGot	Lloh13, Lloh14
	.loh AdrpLdrGot	Lloh11, Lloh12
	.loh AdrpLdrGot	Lloh9, Lloh10
	.loh AdrpLdrGot	Lloh7, Lloh8
	.loh AdrpAdd	Lloh23, Lloh24
	.loh AdrpAdd	Lloh25, Lloh26
	.loh AdrpAdd	Lloh27, Lloh28
	.loh AdrpAdd	Lloh29, Lloh30
	.loh AdrpAdd	Lloh31, Lloh32
	.loh AdrpLdrGotLdr	Lloh33, Lloh34, Lloh35
	.loh AdrpLdrGotLdr	Lloh36, Lloh37, Lloh38
	.loh AdrpLdrGotLdr	Lloh41, Lloh42, Lloh43
	.loh AdrpAdd	Lloh39, Lloh40
	.loh AdrpAdd	Lloh44, Lloh45
	.cfi_endproc
                                        ; -- End function
	.comm	_BS_SUSPEND,4,2                 ; @BS_SUSPEND
	.comm	_DEBUG_SUSPEND,4,2              ; @DEBUG_SUSPEND
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"already suspended"

	.comm	_BS_B1OPEN,4,2                  ; @BS_B1OPEN
	.comm	_BS_B2OPEN,4,2                  ; @BS_B2OPEN
	.comm	_BS_ATRDPEND,4,2                ; @BS_ATRDPEND
	.comm	_BS_ATWRPEND,4,2                ; @BS_ATWRPEND
	.comm	_BAS_TIMEOUT,4,2                ; @BAS_TIMEOUT
	.comm	_HZ,4,2                         ; @HZ
l_.str.1:                               ; @.str.1
	.asciz	"wait_event_timeout() -> %d"

l_.str.2:                               ; @.str.2
	.asciz	"cannot suspend:\n"

l_.str.3:                               ; @.str.3
	.asciz	" B channel 1 open\n"

l_.str.4:                               ; @.str.4
	.asciz	" B channel 2 open\n"

l_.str.5:                               ; @.str.5
	.asciz	" receiving AT reply\n"

l_.str.6:                               ; @.str.6
	.asciz	" sending AT command\n"

	.comm	_EBUSY,4,2                      ; @EBUSY
	.comm	_BS_ATOPEN,4,2                  ; @BS_ATOPEN
l_.str.7:                               ; @.str.7
	.asciz	"closing AT channel"

	.comm	_HD_CLOSE_ATCHANNEL,4,2         ; @HD_CLOSE_ATCHANNEL
l_.str.8:                               ; @.str.8
	.asciz	"suspend complete"

	.no_dead_strip	_gigaset_suspend
.subsections_via_symbols
