user: Translate the below assembly code into C programming language:

```asm
<USBDevEndpointConfigGet>:
  endbr64
  push   %rbp
  mov    %rsp,%rbp
  mov    %rdi,-0x18(%rbp)
  mov    %rsi,-0x20(%rbp)
  mov    %rdx,-0x28(%rbp)
  mov    %rcx,-0x30(%rbp)
  mov    -0x30(%rbp),%rax
  mov    (%rax),%rax
  and    $0x2000,%eax
  test   %rax,%rax
  je     L71
  mov    -0x30(%rbp),%rax
  movq   $0x2000,(%rax)
  mov    -0x20(%rbp),%rdx
  mov    -0x18(%rbp),%rax
  add    %rdx,%rax
  add    $0x100,%rax
  movzwl (%rax),%eax
  movzwl %ax,%edx
  mov    -0x28(%rbp),%rax
  mov    %rdx,(%rax)
  mov    -0x20(%rbp),%rdx
  mov    -0x18(%rbp),%rax
  add    %rdx,%rax
  add    $0x103,%rax
  movzbl (%rax),%eax
  movzbl %al,%eax
  mov    %rax,-0x8(%rbp)
  mov    -0x8(%rbp),%rax
  and    $0x80,%eax
  test   %rax,%rax
  je     L122
  mov    -0x30(%rbp),%rax
  mov    (%rax),%rax
  or     $0x1,%rax
  mov    %rax,%rdx
  mov    -0x30(%rbp),%rax
  mov    %rdx,(%rax)
L122:
  mov    -0x8(%rbp),%rax
  and    $0x10,%eax
  test   %rax,%rax
  je     L72
  mov    -0x8(%rbp),%rax
  and    $0x4,%eax
  test   %rax,%rax
  je     L33
  mov    -0x30(%rbp),%rax
  mov    (%rax),%rax
  or     $0x10,%rax
  mov    %rax,%rdx
  mov    -0x30(%rbp),%rax
  mov    %rdx,(%rax)
  jmp    L72
L33:
  mov    -0x30(%rbp),%rax
  mov    (%rax),%rax
  or     $0x8,%rax
  mov    %rax,%rdx
  mov    -0x30(%rbp),%rax
  mov    %rdx,(%rax)
L72:
  mov    -0x8(%rbp),%rax
  and    $0x40,%eax
  test   %rax,%rax
  je     L19
  mov    -0x30(%rbp),%rax
  mov    (%rax),%rdx
  mov    -0x30(%rbp),%rax
  mov    %rdx,(%rax)
  jmp    L41
L19:
  mov    -0x30(%rbp),%rax
  mov    (%rax),%rax
  or     $0x1,%ah
  mov    %rax,%rdx
  mov    -0x30(%rbp),%rax
  mov    %rdx,(%rax)
  jmp    L41
L71:
  mov    -0x30(%rbp),%rax
  movq   $0x0,(%rax)
  mov    -0x20(%rbp),%rdx
  mov    -0x18(%rbp),%rax
  add    %rdx,%rax
  add    $0x104,%rax
  movzwl (%rax),%eax
  movzwl %ax,%edx
  mov    -0x28(%rbp),%rax
  mov    %rdx,(%rax)
  mov    -0x20(%rbp),%rdx
  mov    -0x18(%rbp),%rax
  add    %rdx,%rax
  add    $0x107,%rax
  movzbl (%rax),%eax
  movzbl %al,%eax
  mov    %rax,-0x8(%rbp)
  mov    -0x8(%rbp),%rax
  and    $0x80,%eax
  test   %rax,%rax
  je     L47
  mov    -0x30(%rbp),%rax
  mov    (%rax),%rax
  or     $0x4,%rax
  mov    %rax,%rdx
  mov    -0x30(%rbp),%rax
  mov    %rdx,(%rax)
L47:
  mov    -0x8(%rbp),%rax
  and    $0x20,%eax
  test   %rax,%rax
  je     L6
  mov    -0x8(%rbp),%rax
  and    $0x8,%eax
  test   %rax,%rax
  je     L58
  mov    -0x30(%rbp),%rax
  mov    (%rax),%rax
  or     $0x10,%rax
  mov    %rax,%rdx
  mov    -0x30(%rbp),%rax
  mov    %rdx,(%rax)
  jmp    L6
L58:
  mov    -0x30(%rbp),%rax
  mov    (%rax),%rax
  or     $0x8,%rax
  mov    %rax,%rdx
  mov    -0x30(%rbp),%rax
  mov    %rdx,(%rax)
L6:
  mov    -0x8(%rbp),%rax
  and    $0x40,%eax
  test   %rax,%rax
  je     L117
  mov    -0x30(%rbp),%rax
  mov    (%rax),%rdx
  mov    -0x30(%rbp),%rax
  mov    %rdx,(%rax)
  jmp    L41
L117:
  mov    -0x30(%rbp),%rax
  mov    (%rax),%rax
  or     $0x1,%ah
  mov    %rax,%rdx
  mov    -0x30(%rbp),%rax
  mov    %rdx,(%rax)
L41:
  nop
  pop    %rbp
  ret
```

assistant: ```c
void USBDevEndpointConfigGet(unsigned long ulBase, unsigned long ulEndpoint, unsigned long *pulMaxPacketSize, unsigned long *pulFlags) {
  unsigned long ulRegister;
  ;
  ;

  ;
  if (*pulFlags & 0x00002000) {
    *pulFlags = 0x00002000;
    *pulMaxPacketSize = (unsigned long)(*((volatile unsigned short *)(ulBase + (ulEndpoint - 0x10) + 0x00000110)));
    ulRegister = (unsigned long)(*((volatile unsigned char *)(ulBase + (ulEndpoint - 0x10) + 0x00000113)));
    if (ulRegister & 0x00000080) {
      *pulFlags |= 0x00000001;
    }
    if (ulRegister & 0x00000010) {
      if (ulRegister & 0x00000004) {
        *pulFlags |= 0x00000010;
      } else {
        *pulFlags |= 0x00000008;
      }
    }
    if (ulRegister & 0x00000040) {
      *pulFlags |= 0x00000000;
    } else {
      *pulFlags |= 0x00000100;
    }
  } else {
    *pulFlags = 0x00000000;
    *pulMaxPacketSize = (unsigned long)(*((volatile unsigned short *)(ulBase + (ulEndpoint - 0x10) + 0x00000114)));
    ulRegister = (unsigned long)(*((volatile unsigned char *)(ulBase + (ulEndpoint - 0x10) + 0x00000117)));
    if (ulRegister & 0x00000080) {
      *pulFlags |= 0x00000004;
    }
    if (ulRegister & 0x00000020) {
      if (ulRegister & 0x00000008) {
        *pulFlags |= 0x00000010;
      } else {
        *pulFlags |= 0x00000008;
      }
    }
    if (ulRegister & 0x00000040) {
      *pulFlags |= 0x00000000;
    } else {
      *pulFlags |= 0x00000100;
    }
  }
}
```