	.file	"extr_mtpav.c_translate_hwport_to_subdevice.c"
	.intel_syntax noprefix
	.text
	.p2align 4
	.type	translate_hwport_to_subdevice, @function
translate_hwport_to_subdevice:
.LFB0:
	.cfi_startproc
	endbr64
	mov	edx, DWORD PTR [rdi]
	test	esi, esi
	jle	.L8
	cmp	esi, 8
	jle	.L9
	cmp	esi, 16
	jle	.L10
	mov	eax, DWORD PTR MTPAV_PIDX_ADAT[rip]
	add	eax, edx
	cmp	esi, 17
	je	.L11
	ret
	.p2align 4,,10
	.p2align 3
.L9:
	lea	eax, -1[rsi]
	cmp	eax, edx
	mov	edx, 0
	cmovge	eax, edx
	ret
	.p2align 4,,10
	.p2align 3
.L8:
	mov	eax, DWORD PTR MTPAV_PIDX_BROADCAST[rip]
	add	eax, edx
	ret
	.p2align 4,,10
	.p2align 3
.L11:
	mov	eax, DWORD PTR MTPAV_PIDX_COMPUTER[rip]
	add	eax, edx
	ret
	.p2align 4,,10
	.p2align 3
.L10:
	lea	eax, -9[rdx+rsi]
	lea	ecx, [rdx+rdx]
	cmp	ecx, eax
	cmovle	eax, edx
	ret
	.cfi_endproc
.LFE0:
	.size	translate_hwport_to_subdevice, .-translate_hwport_to_subdevice
	.comm	MTPAV_PIDX_COMPUTER,4,4
	.comm	MTPAV_PIDX_BROADCAST,4,4
	.comm	MTPAV_PIDX_ADAT,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_mtpav.c_translate_hwport_to_subdevice.c"
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	translate_hwport_to_subdevice, %function
translate_hwport_to_subdevice:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 0, uses_anonymous_args = 0
	@ link register save eliminated.
	cmp	r1, #0
	ldr	r3, [r0]
	ble	.L8
	cmp	r1, #8
	ble	.L9
	cmp	r1, #16
	ble	.L10
	cmp	r1, #17
	ldreq	r2, .L11
	ldrne	r2, .L11+4
	ldr	r0, [r2]
	add	r0, r3, r0
	bx	lr
.L9:
	sub	r0, r1, #1
	cmp	r0, r3
	movge	r0, #0
	bx	lr
.L8:
	ldr	r2, .L11+8
	ldr	r0, [r2]
	add	r0, r3, r0
	bx	lr
.L10:
	sub	r0, r1, #9
	add	r0, r0, r3
	cmp	r0, r3, lsl #1
	movge	r0, r3
	bx	lr
.L12:
	.align	2
.L11:
	.word	MTPAV_PIDX_COMPUTER
	.word	MTPAV_PIDX_ADAT
	.word	MTPAV_PIDX_BROADCAST
	.size	translate_hwport_to_subdevice, .-translate_hwport_to_subdevice
	.comm	MTPAV_PIDX_COMPUTER,4,4
	.comm	MTPAV_PIDX_BROADCAST,4,4
	.comm	MTPAV_PIDX_ADAT,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
