	.file	"extr_t3_hw.c_chan_init_hw.c"
	.intel_syntax noprefix
	.text
	.p2align 4
	.type	chan_init_hw, @function
chan_init_hw:
.LFB0:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rdi
	push	rbx
	.cfi_def_cfa_offset 24
	.cfi_offset 3, -24
	mov	ebx, esi
	sub	rsp, 8
	.cfi_def_cfa_offset 32
	mov	edx, DWORD PTR F_ROUND_ROBIN[rip]
	mov	esi, DWORD PTR A_ULPRX_CTL[rip]
	cmp	ebx, 3
	je	.L2
	xor	ecx, ecx
	call	t3_set_reg_field@PLT
	mov	edx, DWORD PTR F_CFG_RR_ARB[rip]
	xor	ecx, ecx
	mov	rdi, rbp
	mov	esi, DWORD PTR A_ULPTX_CONFIG[rip]
	call	t3_set_reg_field@PLT
	mov	edx, DWORD PTR F_TPRXPORTEN[rip]
	or	edx, DWORD PTR F_ENFORCEPKT[rip]
	cmp	ebx, 1
	je	.L9
	mov	eax, DWORD PTR F_TPTXPORT1EN[rip]
	or	eax, DWORD PTR F_PORT1ACTIVE[rip]
.L4:
	mov	esi, DWORD PTR A_MPS_CFG[rip]
	or	edx, eax
	mov	rdi, rbp
	call	t3_write_reg@PLT
	xor	edx, edx
	cmp	ebx, 1
	mov	esi, DWORD PTR A_PM1_TX_CFG[rip]
	sete	dl
	add	rsp, 8
	.cfi_remember_state
	.cfi_def_cfa_offset 24
	mov	rdi, rbp
	pop	rbx
	.cfi_def_cfa_offset 16
	neg	edx
	pop	rbp
	.cfi_def_cfa_offset 8
	jmp	t3_write_reg@PLT
	.p2align 4,,10
	.p2align 3
.L9:
	.cfi_restore_state
	mov	eax, DWORD PTR F_TPTXPORT0EN[rip]
	or	eax, DWORD PTR F_PORT0ACTIVE[rip]
	jmp	.L4
	.p2align 4,,10
	.p2align 3
.L2:
	mov	ecx, edx
	xor	edx, edx
	call	t3_set_reg_field@PLT
	mov	ecx, DWORD PTR F_CFG_RR_ARB[rip]
	xor	edx, edx
	mov	rdi, rbp
	mov	esi, DWORD PTR A_ULPTX_CONFIG[rip]
	call	t3_set_reg_field@PLT
	mov	edi, 16
	call	V_D1_WEIGHT@PLT
	mov	edi, 16
	mov	ebx, eax
	call	V_D0_WEIGHT@PLT
	mov	esi, DWORD PTR A_ULPTX_DMA_WEIGHT[rip]
	mov	rdi, rbp
	or	ebx, eax
	mov	edx, ebx
	xor	ebx, ebx
	call	t3_write_reg@PLT
	mov	esi, DWORD PTR A_MPS_CFG[rip]
	mov	edx, DWORD PTR F_TPTXPORT0EN[rip]
	mov	rdi, rbp
	or	edx, DWORD PTR F_TPTXPORT1EN[rip]
	or	edx, DWORD PTR F_TPRXPORTEN[rip]
	or	edx, DWORD PTR F_PORT0ACTIVE[rip]
	or	edx, DWORD PTR F_PORT1ACTIVE[rip]
	or	edx, DWORD PTR F_ENFORCEPKT[rip]
	call	t3_write_reg@PLT
	mov	esi, DWORD PTR A_PM1_TX_CFG[rip]
	mov	edx, -2147450880
	mov	rdi, rbp
	call	t3_write_reg@PLT
	mov	ecx, DWORD PTR F_TXTOSQUEUEMAPMODE[rip]
	xor	edx, edx
	mov	rdi, rbp
	mov	esi, DWORD PTR A_TP_PC_CONFIG[rip]
	call	t3_set_reg_field@PLT
	mov	edi, 170
	call	V_TX_MOD_QUEUE_REQ_MAP@PLT
	mov	esi, DWORD PTR A_TP_TX_MOD_QUEUE_REQ_MAP[rip]
	mov	rdi, rbp
	mov	edx, eax
	call	t3_write_reg@PLT
	.p2align 4,,10
	.p2align 3
.L5:
	mov	edx, ebx
	mov	esi, DWORD PTR A_TP_TX_MOD_QUE_TABLE[rip]
	mov	rdi, rbp
	add	ebx, 65536
	or	edx, 4112
	call	t3_write_reg@PLT
	cmp	ebx, 1048576
	jne	.L5
	add	rsp, 8
	.cfi_def_cfa_offset 24
	pop	rbx
	.cfi_def_cfa_offset 16
	pop	rbp
	.cfi_def_cfa_offset 8
	ret
	.cfi_endproc
.LFE0:
	.size	chan_init_hw, .-chan_init_hw
	.comm	F_TXTOSQUEUEMAPMODE,4,4
	.comm	F_TPTXPORT1EN,4,4
	.comm	F_TPTXPORT0EN,4,4
	.comm	F_TPRXPORTEN,4,4
	.comm	F_ROUND_ROBIN,4,4
	.comm	F_PORT1ACTIVE,4,4
	.comm	F_PORT0ACTIVE,4,4
	.comm	F_ENFORCEPKT,4,4
	.comm	F_CFG_RR_ARB,4,4
	.comm	A_ULPTX_DMA_WEIGHT,4,4
	.comm	A_ULPTX_CONFIG,4,4
	.comm	A_ULPRX_CTL,4,4
	.comm	A_TP_TX_MOD_QUE_TABLE,4,4
	.comm	A_TP_TX_MOD_QUEUE_REQ_MAP,4,4
	.comm	A_TP_PC_CONFIG,4,4
	.comm	A_PM1_TX_CFG,4,4
	.comm	A_MPS_CFG,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_t3_hw.c_chan_init_hw.c"
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	chan_init_hw, %function
chan_init_hw:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 0, uses_anonymous_args = 0
	ldr	r2, .L10
	ldr	r3, .L10+4
	cmp	r1, #3
	push	{r4, r5, r6, r7, r8, lr}
	mov	r4, r1
	mov	r5, r0
	ldr	r1, [r2]
	ldr	r2, [r3]
	beq	.L2
	mov	r3, #0
	bl	t3_set_reg_field
	ldr	r3, .L10+8
	ldr	r2, .L10+12
	ldr	r1, [r3]
	mov	r0, r5
	mov	r3, #0
	ldr	r2, [r2]
	bl	t3_set_reg_field
	ldr	r3, .L10+16
	ldr	r2, .L10+20
	ldr	r3, [r3]
	ldr	r2, [r2]
	cmp	r4, #1
	orr	r3, r3, r2
	ldreq	r0, .L10+24
	ldreq	r2, .L10+28
	ldrne	r2, .L10+32
	ldrne	r0, .L10+36
	ldr	r2, [r2]
	ldr	r0, [r0]
	ldr	r1, .L10+40
	orr	r2, r2, r0
	orr	r2, r3, r2
	mov	r0, r5
	ldr	r1, [r1]
	bl	t3_write_reg
	ldr	r3, .L10+44
	cmp	r4, #1
	mov	r0, r5
	pop	{r4, r5, r6, r7, r8, lr}
	movne	r2, #0
	mvneq	r2, #0
	ldr	r1, [r3]
	b	t3_write_reg
.L2:
	mov	r3, r2
	mov	r2, #0
	bl	t3_set_reg_field
	ldr	r2, .L10+8
	ldr	r3, .L10+12
	ldr	r1, [r2]
	ldr	r3, [r3]
	mov	r2, #0
	mov	r0, r5
	bl	t3_set_reg_field
	ldr	r3, .L10+48
	mov	r0, #16
	ldr	r6, [r3]
	bl	V_D1_WEIGHT
	mov	r4, r0
	mov	r0, #16
	bl	V_D0_WEIGHT
	mov	r1, r6
	orr	r2, r4, r0
	mov	r0, r5
	bl	t3_write_reg
	ldr	r2, .L10+32
	ldr	r3, .L10+28
	ldr	r0, .L10+16
	ldr	r1, [r2]
	ldr	r3, [r3]
	ldr	r2, .L10+24
	ldr	ip, [r0]
	ldr	r0, .L10+36
	orr	r3, r3, r1
	ldr	r1, [r2]
	ldr	r2, .L10+20
	orr	r3, r3, ip
	ldr	r0, [r0]
	ldr	r2, [r2]
	orr	r3, r3, r1
	ldr	r1, .L10+40
	orr	r3, r3, r0
	orr	r2, r3, r2
	ldr	r1, [r1]
	mov	r0, r5
	bl	t3_write_reg
	ldr	r3, .L10+44
	ldr	r2, .L10+52
	ldr	r1, [r3]
	mov	r0, r5
	bl	t3_write_reg
	ldr	r2, .L10+56
	ldr	r3, .L10+60
	ldr	r1, [r2]
	ldr	r3, [r3]
	mov	r2, #0
	mov	r0, r5
	bl	t3_set_reg_field
	ldr	r3, .L10+64
	mov	r0, #170
	ldr	r4, [r3]
	bl	V_TX_MOD_QUEUE_REQ_MAP
	mov	r1, r4
	mov	r2, r0
	mov	r0, r5
	bl	t3_write_reg
	mov	r4, #0
	ldr	r7, .L10+68
	ldr	r6, .L10+72
.L5:
	orr	r2, r4, r6
	mov	r0, r5
	ldr	r1, [r7]
	add	r4, r4, #65536
	bl	t3_write_reg
	cmp	r4, #1048576
	bne	.L5
	pop	{r4, r5, r6, r7, r8, pc}
.L11:
	.align	2
.L10:
	.word	A_ULPRX_CTL
	.word	F_ROUND_ROBIN
	.word	A_ULPTX_CONFIG
	.word	F_CFG_RR_ARB
	.word	F_TPRXPORTEN
	.word	F_ENFORCEPKT
	.word	F_PORT0ACTIVE
	.word	F_TPTXPORT0EN
	.word	F_TPTXPORT1EN
	.word	F_PORT1ACTIVE
	.word	A_MPS_CFG
	.word	A_PM1_TX_CFG
	.word	A_ULPTX_DMA_WEIGHT
	.word	-2147450880
	.word	A_TP_PC_CONFIG
	.word	F_TXTOSQUEUEMAPMODE
	.word	A_TP_TX_MOD_QUEUE_REQ_MAP
	.word	A_TP_TX_MOD_QUE_TABLE
	.word	4112
	.size	chan_init_hw, .-chan_init_hw
	.comm	F_TXTOSQUEUEMAPMODE,4,4
	.comm	F_TPTXPORT1EN,4,4
	.comm	F_TPTXPORT0EN,4,4
	.comm	F_TPRXPORTEN,4,4
	.comm	F_ROUND_ROBIN,4,4
	.comm	F_PORT1ACTIVE,4,4
	.comm	F_PORT0ACTIVE,4,4
	.comm	F_ENFORCEPKT,4,4
	.comm	F_CFG_RR_ARB,4,4
	.comm	A_ULPTX_DMA_WEIGHT,4,4
	.comm	A_ULPTX_CONFIG,4,4
	.comm	A_ULPRX_CTL,4,4
	.comm	A_TP_TX_MOD_QUE_TABLE,4,4
	.comm	A_TP_TX_MOD_QUEUE_REQ_MAP,4,4
	.comm	A_TP_PC_CONFIG,4,4
	.comm	A_PM1_TX_CFG,4,4
	.comm	A_MPS_CFG,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
