io_edgeport.h 2.0 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061
  1. /* SPDX-License-Identifier: GPL-2.0+ */
  2. /************************************************************************
  3. *
  4. * io_edgeport.h Edgeport Linux Interface definitions
  5. *
  6. * Copyright (C) 2000 Inside Out Networks, Inc.
  7. *
  8. ************************************************************************/
  9. #if !defined(_IO_EDGEPORT_H_)
  10. #define _IO_EDGEPORT_H_
  11. #define MAX_RS232_PORTS 8 /* Max # of RS-232 ports per device */
  12. /* typedefs that the insideout headers need */
  13. #ifndef LOW8
  14. #define LOW8(a) ((unsigned char)(a & 0xff))
  15. #endif
  16. #ifndef HIGH8
  17. #define HIGH8(a) ((unsigned char)((a & 0xff00) >> 8))
  18. #endif
  19. #include "io_usbvend.h"
  20. /*
  21. * Product information read from the Edgeport
  22. */
  23. struct edgeport_product_info {
  24. __u16 ProductId; /* Product Identifier */
  25. __u8 NumPorts; /* Number of ports on edgeport */
  26. __u8 ProdInfoVer; /* What version of structure is this? */
  27. __u32 IsServer :1; /* Set if Server */
  28. __u32 IsRS232 :1; /* Set if RS-232 ports exist */
  29. __u32 IsRS422 :1; /* Set if RS-422 ports exist */
  30. __u32 IsRS485 :1; /* Set if RS-485 ports exist */
  31. __u32 IsReserved :28; /* Reserved for later expansion */
  32. __u8 RomSize; /* Size of ROM/E2PROM in K */
  33. __u8 RamSize; /* Size of external RAM in K */
  34. __u8 CpuRev; /* CPU revision level (chg only if s/w visible) */
  35. __u8 BoardRev; /* PCB revision level (chg only if s/w visible) */
  36. __u8 BootMajorVersion; /* Boot Firmware version: xx. */
  37. __u8 BootMinorVersion; /* yy. */
  38. __le16 BootBuildNumber; /* zzzz (LE format) */
  39. __u8 FirmwareMajorVersion; /* Operational Firmware version:xx. */
  40. __u8 FirmwareMinorVersion; /* yy. */
  41. __le16 FirmwareBuildNumber; /* zzzz (LE format) */
  42. __u8 ManufactureDescDate[3]; /* MM/DD/YY when descriptor template was compiled */
  43. __u8 HardwareType;
  44. __u8 iDownloadFile; /* What to download to EPiC device */
  45. __u8 EpicVer; /* What version of EPiC spec this device supports */
  46. struct edge_compatibility_bits Epic;
  47. };
  48. #endif