summaryrefslogtreecommitdiffstats
path: root/drivers/media/dvb-core/dvb_ca_en50221.h
diff options
context:
space:
mode:
authorRalph Metzler2017-06-25 23:37:07 +0200
committerMauro Carvalho Chehab2017-06-26 13:15:32 +0200
commitf894165cb57922361a8cbe339e29b8c78ad4036a (patch)
treef7ed69230ef0b39f038ba33f4d153a34141d7ad4 /drivers/media/dvb-core/dvb_ca_en50221.h
parentmedia: dvb_ca_en50221: Increase timeout for link init (diff)
downloadkernel-qcow2-linux-f894165cb57922361a8cbe339e29b8c78ad4036a.tar.gz
kernel-qcow2-linux-f894165cb57922361a8cbe339e29b8c78ad4036a.tar.xz
kernel-qcow2-linux-f894165cb57922361a8cbe339e29b8c78ad4036a.zip
media: dvb_ca_en50221: Add block read/write functions
Some lower level drivers may work better when sending blocks of data instead byte per byte. For this we need new function pointers in the dvb_ca_en50221 protocol structure (read_data, write_data) and the protocol needs to execute them, if they are defined. Block data transmission is done in all states except LINKINIT. Original code change by Ralph Metzler, modified by Jasmin Jessich and Daniel Scheller to match Kernel code style. Signed-off-by: Ralph Metzler <rjkm@metzlerbros.de> Signed-off-by: Daniel Scheller <d.scheller@gmx.net> Signed-off-by: Jasmin Jessich <jasmin@anw.at> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
Diffstat (limited to 'drivers/media/dvb-core/dvb_ca_en50221.h')
-rw-r--r--drivers/media/dvb-core/dvb_ca_en50221.h7
1 files changed, 7 insertions, 0 deletions
diff --git a/drivers/media/dvb-core/dvb_ca_en50221.h b/drivers/media/dvb-core/dvb_ca_en50221.h
index 1e4bbbd34d91..82617bac0875 100644
--- a/drivers/media/dvb-core/dvb_ca_en50221.h
+++ b/drivers/media/dvb-core/dvb_ca_en50221.h
@@ -41,6 +41,8 @@
* @write_attribute_mem: function for writing attribute memory on the CAM
* @read_cam_control: function for reading the control interface on the CAM
* @write_cam_control: function for reading the control interface on the CAM
+ * @read_data: function for reading data (block mode)
+ * @write_data: function for writing data (block mode)
* @slot_reset: function to reset the CAM slot
* @slot_shutdown: function to shutdown a CAM slot
* @slot_ts_enable: function to enable the Transport Stream on a CAM slot
@@ -66,6 +68,11 @@ struct dvb_ca_en50221 {
int (*write_cam_control)(struct dvb_ca_en50221 *ca,
int slot, u8 address, u8 value);
+ int (*read_data)(struct dvb_ca_en50221 *ca,
+ int slot, u8 *ebuf, int ecount);
+ int (*write_data)(struct dvb_ca_en50221 *ca,
+ int slot, u8 *ebuf, int ecount);
+
int (*slot_reset)(struct dvb_ca_en50221 *ca, int slot);
int (*slot_shutdown)(struct dvb_ca_en50221 *ca, int slot);
int (*slot_ts_enable)(struct dvb_ca_en50221 *ca, int slot);