mtk_dp_hdcp.h 1.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566
  1. /*
  2. * Copyright (c) 2020 MediaTek Inc.
  3. *
  4. * This program is free software; you can redistribute it and/or modify
  5. * it under the terms of the GNU General Public License version 2 as
  6. * published by the Free Software Foundation.
  7. *
  8. * This program is distributed in the hope that it will be useful,
  9. * but WITHOUT ANY WARRANTY; without even the implied warranty of
  10. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  11. * GNU General Public License for more details.
  12. */
  13. #ifndef __MTK_HDCP_H__
  14. #define __MTK_HDCP_H__
  15. #include <linux/types.h>
  16. #ifdef DPTX_HDCP_ENABLE
  17. struct HDCP1X_INFO {
  18. int MainStates;
  19. int SubStates;
  20. unsigned char uRetryCount;
  21. bool bEnable:1;
  22. bool bRepeater:1;
  23. bool bR0Read:1;
  24. bool bKSV_READY:1;
  25. bool bMAX_CASCADE:1;
  26. bool bMAX_DEVS:1;
  27. unsigned char ubBstatus;
  28. unsigned char ubBksv[5];
  29. unsigned char ubAksv[5];
  30. unsigned char ubV[20];
  31. unsigned char ubBinfo[2];
  32. unsigned char ubKSVFIFO[5*127];
  33. unsigned char ubDEVICE_COUNT;
  34. };
  35. struct HDCP2_INFO {
  36. bool bEnable:1;
  37. bool bRepeater:1;
  38. bool bReadcertrx:1;
  39. bool bReadHprime:1;
  40. bool bReadPairing:1;
  41. bool bReadLprime:1;
  42. bool bksExchangeDone:1;
  43. bool bReadVprime:1;
  44. uint8_t uRetryCount;
  45. uint8_t uDeviceCount;
  46. uint8_t uStreamIDType;
  47. };
  48. enum HDCP_RESULT {
  49. AUTH_ZERO = 0,
  50. AUTH_INIT = 1,
  51. AUTH_PASS = 2,
  52. AUTH_FAIL = 3,
  53. };
  54. #endif
  55. #endif