	.file	"extr_s3c-hsotg.c_s3c_hsotg_process_control.c"
	.intel_syntax noprefix
	.text
	.section	.rodata.str1.8,"aMS",@progbits,1
	.align 8
.LC0:
	.string	"ctrl Req=%02x, Type=%02x, V=%04x, L=%04x\n"
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC1:
	.string	"ctrl: dir_in=%d\n"
.LC2:
	.string	"new address %d\n"
.LC3:
	.string	"driver->setup() ret %d\n"
.LC4:
	.string	"ep0 stall (dir=%d)\n"
	.section	.rodata.str1.8
	.align 8
.LC5:
	.string	"writen DxEPCTL=0x%08x to %08x (DxEPCTL=0x%08x)\n"
	.text
	.p2align 4
	.type	s3c_hsotg_process_control, @function
s3c_hsotg_process_control:
.LFB0:
	.cfi_startproc
	endbr64
	push	r14
	.cfi_def_cfa_offset 16
	.cfi_offset 14, -16
	xor	eax, eax
	push	r13
	.cfi_def_cfa_offset 24
	.cfi_offset 13, -24
	push	r12
	.cfi_def_cfa_offset 32
	.cfi_offset 12, -32
	mov	r12, rdi
	push	rbp
	.cfi_def_cfa_offset 40
	.cfi_offset 6, -40
	mov	rbp, rsi
	sub	rsp, 8
	.cfi_def_cfa_offset 48
	mov	r13, QWORD PTR 24[rdi]
	mov	ecx, DWORD PTR 4[rsi]
	mov	r9, QWORD PTR 16[rsi]
	mov	r8d, DWORD PTR 8[rsi]
	mov	edx, DWORD PTR [rsi]
	mov	edi, DWORD PTR 4[rdi]
	lea	rsi, .LC0[rip]
	mov	QWORD PTR 8[r13], 0
	call	dev_dbg@PLT
	mov	eax, DWORD PTR 4[rbp]
	xor	edx, edx
	test	DWORD PTR USB_DIR_IN[rip], eax
	setne	dl
	mov	edi, DWORD PTR 4[r12]
	xor	eax, eax
	lea	rsi, .LC1[rip]
	mov	DWORD PTR 0[r13], edx
	call	dev_dbg@PLT
	cmp	QWORD PTR 16[rbp], 0
	jne	.L2
	mov	DWORD PTR 0[r13], 1
.L2:
	mov	eax, DWORD PTR 4[rbp]
	and	eax, DWORD PTR USB_TYPE_MASK[rip]
	cmp	eax, DWORD PTR USB_TYPE_STANDARD[rip]
	je	.L3
.L30:
	mov	rax, QWORD PTR 16[r12]
	test	rax, rax
	je	.L1
	lea	rdi, 8[r12]
	mov	rsi, rbp
	call	[QWORD PTR [rax]]
	test	eax, eax
	js	.L32
	je	.L1
	mov	edx, DWORD PTR 0[r13]
	test	edx, edx
	je	.L33
.L1:
	add	rsp, 8
	.cfi_remember_state
	.cfi_def_cfa_offset 40
	pop	rbp
	.cfi_def_cfa_offset 32
	pop	r12
	.cfi_def_cfa_offset 24
	pop	r13
	.cfi_def_cfa_offset 16
	pop	r14
	.cfi_def_cfa_offset 8
	ret
	.p2align 4,,10
	.p2align 3
.L3:
	.cfi_restore_state
	mov	eax, DWORD PTR 0[rbp]
	cmp	eax, 130
	je	.L6
	jg	.L7
	cmp	eax, 128
	je	.L8
	cmp	eax, 129
	jne	.L30
	mov	edi, DWORD PTR S3C_DCFG[rip]
	add	edi, DWORD PTR [r12]
	call	readl@PLT
	mov	edi, DWORD PTR S3C_DCFG_DevAddr_MASK[rip]
	mov	ecx, DWORD PTR S3C_DCFG_DevAddr_SHIFT[rip]
	mov	esi, DWORD PTR S3C_DCFG[rip]
	add	esi, DWORD PTR [r12]
	not	edi
	and	eax, edi
	mov	edi, DWORD PTR 8[rbp]
	sal	edi, cl
	or	edi, eax
	call	writel@PLT
	mov	edx, DWORD PTR 8[rbp]
	mov	edi, DWORD PTR 4[r12]
	lea	rsi, .LC2[rip]
	call	dev_info@PLT
	add	rsp, 8
	.cfi_remember_state
	.cfi_def_cfa_offset 40
	mov	rsi, r13
	mov	rdi, r12
	pop	rbp
	.cfi_def_cfa_offset 32
	xor	ecx, ecx
	pop	r12
	.cfi_def_cfa_offset 24
	xor	edx, edx
	pop	r13
	.cfi_def_cfa_offset 16
	pop	r14
	.cfi_def_cfa_offset 8
	jmp	s3c_hsotg_send_reply@PLT
	.p2align 4,,10
	.p2align 3
.L7:
	.cfi_restore_state
	cmp	eax, 131
	jne	.L30
.L8:
	mov	rsi, rbp
	mov	rdi, r12
	call	s3c_hsotg_process_req_feature@PLT
.L12:
	test	eax, eax
	je	.L30
	jle	.L16
	mov	edx, DWORD PTR 0[r13]
	test	edx, edx
	jne	.L1
.L33:
	xor	ecx, ecx
	xor	edx, edx
	mov	rsi, r13
	mov	rdi, r12
	call	s3c_hsotg_send_reply@PLT
.L16:
	test	eax, eax
	jns	.L1
.L15:
	mov	edi, DWORD PTR 4[r12]
	mov	edx, DWORD PTR 0[r13]
	lea	rsi, .LC4[rip]
	xor	eax, eax
	call	dev_dbg@PLT
	mov	eax, DWORD PTR 0[r13]
	mov	r14d, DWORD PTR S3C_DOEPCTL0[rip]
	test	eax, eax
	je	.L18
	mov	r14d, DWORD PTR S3C_DIEPCTL0[rip]
.L18:
	mov	edi, DWORD PTR [r12]
	add	edi, r14d
	call	readl@PLT
	mov	esi, DWORD PTR [r12]
	mov	r13d, DWORD PTR S3C_DxEPCTL_Stall[rip]
	or	r13d, DWORD PTR S3C_DxEPCTL_CNAK[rip]
	or	r13d, eax
	add	esi, r14d
	mov	edi, r13d
	call	writel@PLT
	mov	edi, DWORD PTR [r12]
	add	edi, r14d
	call	readl@PLT
	mov	edi, DWORD PTR 4[r12]
	mov	ecx, r14d
	mov	edx, r13d
	add	rsp, 8
	.cfi_remember_state
	.cfi_def_cfa_offset 40
	mov	r8d, eax
	lea	rsi, .LC5[rip]
	xor	eax, eax
	pop	rbp
	.cfi_def_cfa_offset 32
	pop	r12
	.cfi_def_cfa_offset 24
	pop	r13
	.cfi_def_cfa_offset 16
	pop	r14
	.cfi_def_cfa_offset 8
	jmp	dev_dbg@PLT
	.p2align 4,,10
	.p2align 3
.L32:
	.cfi_restore_state
	mov	edi, DWORD PTR 4[r12]
	mov	edx, eax
	lea	rsi, .LC3[rip]
	xor	eax, eax
	call	dev_dbg@PLT
	jmp	.L15
	.p2align 4,,10
	.p2align 3
.L6:
	mov	rsi, rbp
	mov	rdi, r12
	call	s3c_hsotg_process_req_status@PLT
	jmp	.L12
	.cfi_endproc
.LFE0:
	.size	s3c_hsotg_process_control, .-s3c_hsotg_process_control
	.comm	USB_TYPE_STANDARD,4,4
	.comm	USB_TYPE_MASK,4,4
	.comm	USB_DIR_IN,4,4
	.comm	S3C_DxEPCTL_Stall,4,4
	.comm	S3C_DxEPCTL_CNAK,4,4
	.comm	S3C_DOEPCTL0,4,4
	.comm	S3C_DIEPCTL0,4,4
	.comm	S3C_DCFG_DevAddr_SHIFT,4,4
	.comm	S3C_DCFG_DevAddr_MASK,4,4
	.comm	S3C_DCFG,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_s3c-hsotg.c_s3c_hsotg_process_control.c"
	.text
	.section	.rodata.str1.4,"aMS",%progbits,1
	.align	2
.LC0:
	.ascii	"ctrl Req=%02x, Type=%02x, V=%04x, L=%04x\012\000"
	.align	2
.LC1:
	.ascii	"ctrl: dir_in=%d\012\000"
	.align	2
.LC2:
	.ascii	"new address %d\012\000"
	.align	2
.LC3:
	.ascii	"driver->setup() ret %d\012\000"
	.align	2
.LC4:
	.ascii	"ep0 stall (dir=%d)\012\000"
	.align	2
.LC5:
	.ascii	"writen DxEPCTL=0x%08x to %08x (DxEPCTL=0x%08x)\012\000"
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	s3c_hsotg_process_control, %function
s3c_hsotg_process_control:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 0, uses_anonymous_args = 0
	push	{r4, r5, r6, r7, lr}
	mov	r4, r1
	mov	r3, #0
	ldr	r6, [r0, #16]
	ldr	r1, [r1, #12]
	ldr	r2, [r4, #8]
	sub	sp, sp, #12
	str	r3, [r6, #4]
	ldr	r3, [r4, #4]
	str	r1, [sp, #4]
	str	r2, [sp]
	mov	r5, r0
	ldr	r2, [r4]
	ldr	r1, .L28
	ldr	r0, [r0, #4]
	bl	dev_dbg
	ldr	r3, .L28+4
	ldr	r2, [r4, #4]
	ldr	r3, [r3]
	ldr	r0, [r5, #4]
	tst	r2, r3
	movne	r2, #1
	moveq	r2, #0
	ldr	r1, .L28+8
	str	r2, [r6]
	bl	dev_dbg
	ldr	r3, [r4, #12]
	ldr	r2, .L28+12
	cmp	r3, #0
	moveq	r3, #1
	streq	r3, [r6]
	ldr	r3, .L28+16
	ldr	r2, [r2]
	ldr	r1, [r3]
	ldr	r3, [r4, #4]
	and	r3, r3, r1
	cmp	r3, r2
	beq	.L3
.L24:
	ldr	r3, [r5, #12]
	cmp	r3, #0
	beq	.L1
	mov	r1, r4
	ldr	r3, [r3]
	add	r0, r5, #8
	blx	r3
	subs	r2, r0, #0
	blt	.L26
	beq	.L1
.L19:
	ldr	r3, [r6]
	cmp	r3, #0
	beq	.L27
.L1:
	add	sp, sp, #12
	@ sp needed
	pop	{r4, r5, r6, r7, pc}
.L3:
	ldr	r3, [r4]
	sub	r3, r3, #128
	cmp	r3, #3
	ldrls	pc, [pc, r3, asl #2]
	b	.L24
.L8:
	.word	.L7
	.word	.L10
	.word	.L9
	.word	.L7
.L27:
	mov	r2, r3
	mov	r1, r6
	mov	r0, r5
	bl	s3c_hsotg_send_reply
.L16:
	cmp	r0, #0
	bge	.L1
.L15:
	ldr	r2, [r6]
	ldr	r1, .L28+20
	ldr	r0, [r5, #4]
	bl	dev_dbg
	ldr	r3, [r6]
	ldr	r0, [r5]
	cmp	r3, #0
	ldrne	r3, .L28+24
	ldreq	r3, .L28+28
	ldr	r6, [r3]
	add	r0, r6, r0
	bl	readl
	ldr	r3, .L28+32
	ldr	r2, .L28+36
	ldr	r1, [r5]
	ldr	r4, [r2]
	ldr	r2, [r3]
	add	r1, r6, r1
	orr	r4, r4, r2
	orr	r4, r4, r0
	mov	r0, r4
	bl	writel
	ldm	r5, {r0, r5}
	add	r0, r6, r0
	bl	readl
	mov	r2, r4
	str	r0, [sp]
	mov	r3, r6
	mov	r0, r5
	ldr	r1, .L28+40
	bl	dev_dbg
	add	sp, sp, #12
	@ sp needed
	pop	{r4, r5, r6, r7, pc}
.L7:
	mov	r1, r4
	mov	r0, r5
	bl	s3c_hsotg_process_req_feature
.L12:
	cmp	r0, #0
	beq	.L24
	bgt	.L19
	b	.L16
.L26:
	ldr	r1, .L28+44
	ldr	r0, [r5, #4]
	bl	dev_dbg
	b	.L15
.L9:
	mov	r1, r4
	mov	r0, r5
	bl	s3c_hsotg_process_req_status
	b	.L12
.L10:
	ldr	r7, .L28+48
	ldr	r0, [r5]
	ldr	r3, [r7]
	add	r0, r0, r3
	bl	readl
	ldr	r3, .L28+52
	ldr	r2, .L28+56
	ldr	r3, [r3]
	ldr	ip, [r5]
	bic	r3, r0, r3
	ldr	r1, [r7]
	ldr	r2, [r2]
	ldr	r0, [r4, #8]
	add	r1, ip, r1
	orr	r0, r3, r0, lsl r2
	bl	writel
	ldr	r2, [r4, #8]
	ldr	r1, .L28+60
	ldr	r0, [r5, #4]
	bl	dev_info
	mov	r3, #0
	mov	r1, r6
	mov	r0, r5
	mov	r2, r3
	add	sp, sp, #12
	@ sp needed
	pop	{r4, r5, r6, r7, lr}
	b	s3c_hsotg_send_reply
.L29:
	.align	2
.L28:
	.word	.LC0
	.word	USB_DIR_IN
	.word	.LC1
	.word	USB_TYPE_STANDARD
	.word	USB_TYPE_MASK
	.word	.LC4
	.word	S3C_DIEPCTL0
	.word	S3C_DOEPCTL0
	.word	S3C_DxEPCTL_CNAK
	.word	S3C_DxEPCTL_Stall
	.word	.LC5
	.word	.LC3
	.word	S3C_DCFG
	.word	S3C_DCFG_DevAddr_MASK
	.word	S3C_DCFG_DevAddr_SHIFT
	.word	.LC2
	.size	s3c_hsotg_process_control, .-s3c_hsotg_process_control
	.comm	USB_TYPE_STANDARD,4,4
	.comm	USB_TYPE_MASK,4,4
	.comm	USB_DIR_IN,4,4
	.comm	S3C_DxEPCTL_Stall,4,4
	.comm	S3C_DxEPCTL_CNAK,4,4
	.comm	S3C_DOEPCTL0,4,4
	.comm	S3C_DIEPCTL0,4,4
	.comm	S3C_DCFG_DevAddr_SHIFT,4,4
	.comm	S3C_DCFG_DevAddr_MASK,4,4
	.comm	S3C_DCFG,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
