V4L/DVB (11555): Siano: core - move and update the main core structure declaration
authorUri Shkolnik <uris@siano-ms.com>
Sun, 5 Apr 2009 08:21:23 +0000 (05:21 -0300)
committerMauro Carvalho Chehab <mchehab@redhat.com>
Tue, 16 Jun 2009 22:14:20 +0000 (19:14 -0300)
smscoreapi - move the main core structure declaration
to the header, in order to enable other components
(such as IR) to use it.

Signed-off-by: Uri Shkolnik <uris@siano-ms.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
drivers/media/dvb/siano/smscoreapi.c
drivers/media/dvb/siano/smscoreapi.h

index 7bd4d1d..f3e1cc7 100644 (file)
@@ -58,42 +58,6 @@ struct smscore_client_t {
        onremove_t              onremove_handler;
 };
 
-struct smscore_device_t {
-       struct list_head entry;
-
-       struct list_head clients;
-       struct list_head subclients;
-       spinlock_t              clientslock;
-
-       struct list_head buffers;
-       spinlock_t              bufferslock;
-       int                             num_buffers;
-
-       void                    *common_buffer;
-       int                             common_buffer_size;
-       dma_addr_t              common_buffer_phys;
-
-       void                    *context;
-       struct device   *device;
-
-       char                    devpath[32];
-       unsigned long   device_flags;
-
-       setmode_t               setmode_handler;
-       detectmode_t    detectmode_handler;
-       sendrequest_t   sendrequest_handler;
-       preload_t               preload_handler;
-       postload_t              postload_handler;
-
-       int                             mode, modes_supported;
-
-       struct completion version_ex_done, data_download_done, trigger_done;
-       struct completion init_device_done, reload_start_done, resume_done;
-
-       int board_id;
-       int led_state;
-};
-
 void smscore_set_board_id(struct smscore_device_t *core, int id)
 {
        core->board_id = id;
index 26749b0..bb52d87 100644 (file)
@@ -121,6 +121,60 @@ struct smsclient_params_t {
        void                    *context;
 };
 
+struct smscore_device_t {
+       struct list_head entry;
+
+       struct list_head clients;
+       struct list_head subclients;
+       spinlock_t clientslock;
+
+       struct list_head buffers;
+       spinlock_t bufferslock;
+       int num_buffers;
+
+       void *common_buffer;
+       int common_buffer_size;
+       dma_addr_t common_buffer_phys;
+
+       void *context;
+       struct device *device;
+
+       char devpath[32];
+       unsigned long device_flags;
+
+       setmode_t setmode_handler;
+       detectmode_t detectmode_handler;
+       sendrequest_t sendrequest_handler;
+       preload_t preload_handler;
+       postload_t postload_handler;
+
+       int mode, modes_supported;
+
+       /* host <--> device messages */
+       struct completion version_ex_done, data_download_done, trigger_done;
+       struct completion init_device_done, reload_start_done, resume_done;
+       struct completion gpio_configuration_done, gpio_set_level_done;
+       struct completion gpio_get_level_done, ir_init_done;
+
+       /* Buffer management */
+       wait_queue_head_t buffer_mng_waitq;
+
+       /* GPIO */
+       int gpio_get_res;
+
+       /* Target hardware board */
+       int board_id;
+
+       /* Firmware */
+       u8 *fw_buf;
+       u32 fw_buf_size;
+
+       /* Infrared (IR) */
+       /* struct ir_t ir; */
+
+       int led_state;
+};
+
 /* GPIO definitions for antenna frequency domain control (SMS8021) */
 #define SMS_ANTENNA_GPIO_0                                     1
 #define SMS_ANTENNA_GPIO_1                                     0