dvr: adjust file & add note [1/1]
PD#SWPL-18817
Problem:
New feature
Solution:
adjust file arch & add note
Verify:
Android Q + AC214
Change-Id: Ia3313ee6fc7a59f3ef18a020289cca6cacf437f2
Signed-off-by: Pengfei Liu <pengfei.liu@amlogic.com>
diff --git a/include/dvr_crypto.h b/include/dvr_crypto.h
index 2948891..18d9107 100644
--- a/include/dvr_crypto.h
+++ b/include/dvr_crypto.h
@@ -5,21 +5,47 @@
extern "C" {
#endif
-typedef uint32_t DVR_CryptoDeviceHandle;
+typedef uint32_t DVR_CryptoDeviceHandle_t;
+
+typedef enum {
+ DVR_CRYPTO_VENDOR_AMLOGIC,
+ DVR_CRYPTO_VENDOR_IRDETO,
+ DVR_CRYPTO_VENDOR_VMX,
+ DVR_CRYPTO_VENDOR_NAGRA
+} DVR_CryptoVendorID_t;
+
+typedef struct {
+} DVR_CryptoIrdetoParams_t;
+
+typedef struct {
+} DVR_CryptoVmxParams_t;
+
+typedef struct {
+} DVR_CryptoAmlogicParams_t;
+
+typedef struct {
+} DVR_CryptoNagraParams_t;
typedef struct DVR_CryptoParams_s {
-} DVR_CryptoParams;
+ int vendor_id;
+ union {
+ DVR_CryptoIrdetoParams_t irdeto;
+ DVR_CryptoVmxParams_t vmx;
+ DVR_CryptoAmlogicParams_t amlogic;
+ DVR_CryptoNagraParams_t nagra;
+ };
+} DVR_CryptoParams_t;
-typedef int (*DVR_CryptoFunction) (DVR_CryptoParams params, void *userdata);
+typedef int (*DVR_CryptoFunction_t) (DVR_CryptoParams_t params_t, void *userdata);
-int dvr_crypto_device_open(DVR_CryptoDeviceHandle *p_handle);
+int dvr_crypto_device_open(DVR_CryptoDeviceHandle_t *p_handle);
-int dvr_crypto_device_run(DVR_CryptoDeviceHandle handle,
- uint8_t *buf_in, uint8_t *buf_out, DVR_CryptoParams *params);
+int dvr_crypto_device_run(DVR_CryptoDeviceHandle_t handle,
+ uint8_t *buf_in, uint8_t *buf_out, DVR_CryptoParams_t *params);
-int dvr_crypto_device_register(DVR_CryptoDeviceHandle handle, DVR_CryptoFunction cb, void *userdata, int is_enc);
+//int dvr_crypto_device_register(DVR_CryptoDeviceHandle_t handle, DVR_CryptoFunction cb, void *userdata, int is_enc);
-int dvr_crypto_device_close(DVR_CryptoDeviceHandle handle);
+int dvr_crypto_device_close(DVR_CryptoDeviceHandle_t handle);
#ifdef __cplusplus
}