	.file	"extr_lcs.c_lcs_alloc_card.c"
	.intel_syntax noprefix
	.text
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC0:
	.string	"alloclcs"
.LC1:
	.string	"iccwerr"
	.text
	.p2align 4
	.type	lcs_alloc_card, @function
lcs_alloc_card:
.LFB0:
	.cfi_startproc
	endbr64
	sub	rsp, 24
	.cfi_def_cfa_offset 32
	mov	esi, DWORD PTR setup[rip]
	lea	rdx, .LC0[rip]
	mov	edi, 2
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR 8[rsp], rax
	xor	eax, eax
	call	LCS_DBF_TEXT@PLT
	mov	esi, DWORD PTR GFP_KERNEL[rip]
	mov	edi, 32
	or	esi, DWORD PTR GFP_DMA[rip]
	call	kzalloc@PLT
	mov	QWORD PTR [rsp], rax
	test	rax, rax
	je	.L1
	mov	edx, DWORD PTR LCS_FRAME_TYPE_AUTO[rip]
	mov	QWORD PTR 16[rax], 0
	lea	rdi, 4[rax]
	mov	DWORD PTR 24[rax], edx
	mov	edx, DWORD PTR LCS_LANCMD_TIMEOUT_DEFAULT[rip]
	mov	DWORD PTR 12[rax], edx
	call	lcs_alloc_channel@PLT
	test	eax, eax
	jne	.L11
	mov	rax, QWORD PTR [rsp]
	lea	rdi, 8[rax]
	call	lcs_alloc_channel@PLT
	test	eax, eax
	jne	.L12
	mov	esi, DWORD PTR setup[rip]
	mov	rdx, rsp
	mov	ecx, 8
	mov	edi, 2
	call	LCS_DBF_HEX@PLT
	mov	rax, QWORD PTR [rsp]
.L1:
	mov	rcx, QWORD PTR 8[rsp]
	xor	rcx, QWORD PTR fs:40
	jne	.L13
	add	rsp, 24
	.cfi_remember_state
	.cfi_def_cfa_offset 8
	ret
	.p2align 4,,10
	.p2align 3
.L11:
	.cfi_restore_state
	mov	esi, DWORD PTR setup[rip]
	lea	rdx, .LC1[rip]
	mov	edi, 2
	call	LCS_DBF_TEXT@PLT
	mov	rdi, QWORD PTR [rsp]
	call	lcs_free_card@PLT
	xor	eax, eax
	jmp	.L1
	.p2align 4,,10
	.p2align 3
.L12:
	mov	esi, DWORD PTR setup[rip]
	lea	rdx, .LC1[rip]
	mov	edi, 2
	call	LCS_DBF_TEXT@PLT
	mov	rax, QWORD PTR [rsp]
	lea	rdi, 4[rax]
	call	lcs_cleanup_channel@PLT
	mov	rdi, QWORD PTR [rsp]
	call	lcs_free_card@PLT
	xor	eax, eax
	jmp	.L1
.L13:
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE0:
	.size	lcs_alloc_card, .-lcs_alloc_card
	.comm	setup,4,4
	.comm	LCS_LANCMD_TIMEOUT_DEFAULT,4,4
	.comm	LCS_FRAME_TYPE_AUTO,4,4
	.comm	GFP_KERNEL,4,4
	.comm	GFP_DMA,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",@progbits
	.section	.note.gnu.property,"a"
	.align 8
	.long	 1f - 0f
	.long	 4f - 1f
	.long	 5
0:
	.string	 "GNU"
1:
	.align 8
	.long	 0xc0000002
	.long	 3f - 2f
2:
	.long	 0x3
3:
	.align 8
4:

	.arch armv5t
	.eabi_attribute 20, 1
	.eabi_attribute 21, 1
	.eabi_attribute 23, 3
	.eabi_attribute 24, 1
	.eabi_attribute 25, 1
	.eabi_attribute 26, 2
	.eabi_attribute 30, 2
	.eabi_attribute 34, 0
	.eabi_attribute 18, 4
	.file	"extr_lcs.c_lcs_alloc_card.c"
	.text
	.section	.rodata.str1.4,"aMS",%progbits,1
	.align	2
.LC0:
	.ascii	"alloclcs\000"
	.align	2
.LC1:
	.ascii	"iccwerr\000"
	.section	.rodata.cst4,"aM",%progbits,4
	.align	2
.LC2:
	.word	__stack_chk_guard
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	lcs_alloc_card, %function
lcs_alloc_card:
	@ args = 0, pretend = 0, frame = 8
	@ frame_needed = 0, uses_anonymous_args = 0
	push	{r4, r5, r6, lr}
	ldr	r5, .L14
	ldr	r3, .L14+4
	sub	sp, sp, #8
	ldr	r2, .L14+8
	ldr	r1, [r5]
	mov	r0, #2
	ldr	r3, [r3]
	str	r3, [sp, #4]
	mov	r3,#0
	bl	LCS_DBF_TEXT
	ldr	r2, .L14+12
	ldr	r3, .L14+16
	ldr	r1, [r2]
	ldr	r3, [r3]
	mov	r0, #24
	orr	r1, r1, r3
	bl	kzalloc
	cmp	r0, #0
	str	r0, [sp]
	beq	.L1
	mov	r6, #0
	ldr	r2, .L14+20
	ldr	r3, .L14+24
	ldr	r2, [r2]
	ldr	r3, [r3]
	str	r2, [r0, #20]
	str	r3, [r0, #12]
	str	r6, [r0, #16]
	add	r0, r0, #4
	bl	lcs_alloc_channel
	subs	r4, r0, #0
	bne	.L11
	ldr	r0, [sp]
	add	r0, r0, #8
	bl	lcs_alloc_channel
	cmp	r0, #0
	ldr	r1, [r5]
	bne	.L12
	mov	r3, #4
	mov	r2, sp
	mov	r0, #2
	bl	LCS_DBF_HEX
	ldr	r0, [sp]
.L1:
	ldr	r3, .L14+4
	ldr	r2, [r3]
	ldr	r3, [sp, #4]
	eors	r2, r3, r2
	mov	r3, #0
	bne	.L13
	add	sp, sp, #8
	@ sp needed
	pop	{r4, r5, r6, pc}
.L11:
	ldr	r1, [r5]
	ldr	r2, .L14+28
	mov	r0, #2
	bl	LCS_DBF_TEXT
	ldr	r0, [sp]
	bl	lcs_free_card
	mov	r0, r6
	b	.L1
.L12:
	ldr	r2, .L14+28
	mov	r0, #2
	bl	LCS_DBF_TEXT
	ldr	r0, [sp]
	add	r0, r0, #4
	bl	lcs_cleanup_channel
	ldr	r0, [sp]
	bl	lcs_free_card
	mov	r0, r4
	b	.L1
.L13:
	bl	__stack_chk_fail
.L15:
	.align	2
.L14:
	.word	setup
	.word	.LC2
	.word	.LC0
	.word	GFP_KERNEL
	.word	GFP_DMA
	.word	LCS_FRAME_TYPE_AUTO
	.word	LCS_LANCMD_TIMEOUT_DEFAULT
	.word	.LC1
	.size	lcs_alloc_card, .-lcs_alloc_card
	.comm	setup,4,4
	.comm	LCS_LANCMD_TIMEOUT_DEFAULT,4,4
	.comm	LCS_FRAME_TYPE_AUTO,4,4
	.comm	GFP_KERNEL,4,4
	.comm	GFP_DMA,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
