tdx-cfg-block.h 1.2 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667
  1. /* SPDX-License-Identifier: GPL-2.0+ */
  2. /*
  3. * Copyright (c) 2016 Toradex, Inc.
  4. */
  5. #ifndef _TDX_CFG_BLOCK_H
  6. #define _TDX_CFG_BLOCK_H
  7. #include "tdx-common.h"
  8. struct toradex_hw {
  9. u16 ver_major;
  10. u16 ver_minor;
  11. u16 ver_assembly;
  12. u16 prodid;
  13. };
  14. struct toradex_eth_addr {
  15. u32 oui:24;
  16. u32 nic:24;
  17. } __attribute__((__packed__));
  18. enum {
  19. COLIBRI_PXA270_V1_312MHZ = 1,
  20. COLIBRI_PXA270_V1_520MHZ,
  21. COLIBRI_PXA320,
  22. COLIBRI_PXA300,
  23. COLIBRI_PXA310,
  24. COLIBRI_PXA320_IT,
  25. COLIBRI_PXA300_XT,
  26. COLIBRI_PXA270_312MHZ,
  27. COLIBRI_PXA270_520MHZ,
  28. COLIBRI_VF50, /* not currently on sale */
  29. COLIBRI_VF61,
  30. COLIBRI_VF61_IT,
  31. COLIBRI_VF50_IT,
  32. COLIBRI_IMX6S,
  33. COLIBRI_IMX6DL,
  34. COLIBRI_IMX6S_IT,
  35. COLIBRI_IMX6DL_IT,
  36. COLIBRI_T20_256MB = 20,
  37. COLIBRI_T20_512MB,
  38. COLIBRI_T20_512MB_IT,
  39. COLIBRI_T30,
  40. COLIBRI_T20_256MB_IT,
  41. APALIS_T30_2GB,
  42. APALIS_T30_1GB,
  43. APALIS_IMX6Q,
  44. APALIS_IMX6Q_IT,
  45. APALIS_IMX6D,
  46. COLIBRI_T30_IT,
  47. APALIS_T30_IT,
  48. COLIBRI_IMX7S,
  49. COLIBRI_IMX7D,
  50. APALIS_TK1_2GB,
  51. APALIS_IMX6D_IT,
  52. };
  53. extern const char * const toradex_modules[];
  54. extern bool valid_cfgblock;
  55. extern struct toradex_hw tdx_hw_tag;
  56. extern struct toradex_eth_addr tdx_eth_addr;
  57. extern u32 tdx_serial;
  58. int read_tdx_cfg_block(void);
  59. #endif /* _TDX_CFG_BLOCK_H */