aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/media/common/siano
diff options
context:
space:
mode:
authorMauro Carvalho Chehab <mchehab@redhat.com>2013-03-21 08:27:37 -0400
committerMauro Carvalho Chehab <mchehab@redhat.com>2013-03-21 09:03:45 -0400
commit28a59df4d7cb8f749ba92ad304df4063ccf108fd (patch)
treeee9ddcf3b3c50b66cb506a3b4e79ee15ebcd6f5f /drivers/media/common/siano
parent90414248bf23ba3c96811f48053b47bfc330fce3 (diff)
[media] siano: remove the remaining CamelCase compliants
Remove the remaining CamelCase checkpatch.pl compliants. There are still a few left, but those are due to USB and DVB APIs. Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'drivers/media/common/siano')
-rw-r--r--drivers/media/common/siano/sms-cards.c4
-rw-r--r--drivers/media/common/siano/smscoreapi.c256
-rw-r--r--drivers/media/common/siano/smscoreapi.h30
-rw-r--r--drivers/media/common/siano/smsdvb-debugfs.c68
-rw-r--r--drivers/media/common/siano/smsdvb-main.c124
-rw-r--r--drivers/media/common/siano/smsdvb.h2
-rw-r--r--drivers/media/common/siano/smsendian.c18
7 files changed, 251 insertions, 251 deletions
diff --git a/drivers/media/common/siano/sms-cards.c b/drivers/media/common/siano/sms-cards.c
index 9bd7aa1f43ec..82769993eeb7 100644
--- a/drivers/media/common/siano/sms-cards.c
+++ b/drivers/media/common/siano/sms-cards.c
@@ -179,9 +179,9 @@ static inline void sms_gpio_assign_11xx_default_led_config(
179int sms_board_event(struct smscore_device_t *coredev, 179int sms_board_event(struct smscore_device_t *coredev,
180 enum SMS_BOARD_EVENTS gevent) 180 enum SMS_BOARD_EVENTS gevent)
181{ 181{
182 struct smscore_config_gpio MyGpioConfig; 182 struct smscore_config_gpio my_gpio_config;
183 183
184 sms_gpio_assign_11xx_default_led_config(&MyGpioConfig); 184 sms_gpio_assign_11xx_default_led_config(&my_gpio_config);
185 185
186 switch (gevent) { 186 switch (gevent) {
187 case BOARD_EVENT_POWER_INIT: /* including hotplug */ 187 case BOARD_EVENT_POWER_INIT: /* including hotplug */
diff --git a/drivers/media/common/siano/smscoreapi.c b/drivers/media/common/siano/smscoreapi.c
index e5fa4056adb3..19e7a5fb4183 100644
--- a/drivers/media/common/siano/smscoreapi.c
+++ b/drivers/media/common/siano/smscoreapi.c
@@ -803,8 +803,8 @@ static int smscore_init_ir(struct smscore_device_t *coredev)
803 SMS_INIT_MSG(&msg->x_msg_header, 803 SMS_INIT_MSG(&msg->x_msg_header,
804 MSG_SMS_START_IR_REQ, 804 MSG_SMS_START_IR_REQ,
805 sizeof(struct sms_msg_data2)); 805 sizeof(struct sms_msg_data2));
806 msg->msgData[0] = coredev->ir.controller; 806 msg->msg_data[0] = coredev->ir.controller;
807 msg->msgData[1] = coredev->ir.timeout; 807 msg->msg_data[1] = coredev->ir.timeout;
808 808
809 rc = smscore_sendrequest_and_wait(coredev, msg, 809 rc = smscore_sendrequest_and_wait(coredev, msg,
810 msg->x_msg_header. msg_length, 810 msg->x_msg_header. msg_length,
@@ -840,31 +840,31 @@ int smscore_configure_board(struct smscore_device_t *coredev)
840 } 840 }
841 841
842 if (board->mtu) { 842 if (board->mtu) {
843 struct sms_msg_data MtuMsg; 843 struct sms_msg_data mtu_msg;
844 sms_debug("set max transmit unit %d", board->mtu); 844 sms_debug("set max transmit unit %d", board->mtu);
845 845
846 MtuMsg.x_msg_header.msg_src_id = 0; 846 mtu_msg.x_msg_header.msg_src_id = 0;
847 MtuMsg.x_msg_header.msg_dst_id = HIF_TASK; 847 mtu_msg.x_msg_header.msg_dst_id = HIF_TASK;
848 MtuMsg.x_msg_header.msg_flags = 0; 848 mtu_msg.x_msg_header.msg_flags = 0;
849 MtuMsg.x_msg_header.msg_type = MSG_SMS_SET_MAX_TX_MSG_LEN_REQ; 849 mtu_msg.x_msg_header.msg_type = MSG_SMS_SET_MAX_TX_MSG_LEN_REQ;
850 MtuMsg.x_msg_header.msg_length = sizeof(MtuMsg); 850 mtu_msg.x_msg_header.msg_length = sizeof(mtu_msg);
851 MtuMsg.msgData[0] = board->mtu; 851 mtu_msg.msg_data[0] = board->mtu;
852 852
853 coredev->sendrequest_handler(coredev->context, &MtuMsg, 853 coredev->sendrequest_handler(coredev->context, &mtu_msg,
854 sizeof(MtuMsg)); 854 sizeof(mtu_msg));
855 } 855 }
856 856
857 if (board->crystal) { 857 if (board->crystal) {
858 struct sms_msg_data CrysMsg; 858 struct sms_msg_data crys_msg;
859 sms_debug("set crystal value %d", board->crystal); 859 sms_debug("set crystal value %d", board->crystal);
860 860
861 SMS_INIT_MSG(&CrysMsg.x_msg_header, 861 SMS_INIT_MSG(&crys_msg.x_msg_header,
862 MSG_SMS_NEW_CRYSTAL_REQ, 862 MSG_SMS_NEW_CRYSTAL_REQ,
863 sizeof(CrysMsg)); 863 sizeof(crys_msg));
864 CrysMsg.msgData[0] = board->crystal; 864 crys_msg.msg_data[0] = board->crystal;
865 865
866 coredev->sendrequest_handler(coredev->context, &CrysMsg, 866 coredev->sendrequest_handler(coredev->context, &crys_msg,
867 sizeof(CrysMsg)); 867 sizeof(crys_msg));
868 } 868 }
869 869
870 return 0; 870 return 0;
@@ -959,7 +959,7 @@ static int smscore_load_firmware_family2(struct smscore_device_t *coredev,
959 calc_checksum += *ptr; 959 calc_checksum += *ptr;
960 960
961 while (size && rc >= 0) { 961 while (size && rc >= 0) {
962 struct sms_data_download *DataMsg = 962 struct sms_data_download *data_msg =
963 (struct sms_data_download *) msg; 963 (struct sms_data_download *) msg;
964 int payload_size = min((int) size, SMS_MAX_PAYLOAD_SIZE); 964 int payload_size = min((int) size, SMS_MAX_PAYLOAD_SIZE);
965 965
@@ -967,11 +967,11 @@ static int smscore_load_firmware_family2(struct smscore_device_t *coredev,
967 (u16)(sizeof(struct sms_msg_hdr) + 967 (u16)(sizeof(struct sms_msg_hdr) +
968 sizeof(u32) + payload_size)); 968 sizeof(u32) + payload_size));
969 969
970 DataMsg->mem_addr = mem_address; 970 data_msg->mem_addr = mem_address;
971 memcpy(DataMsg->payload, payload, payload_size); 971 memcpy(data_msg->payload, payload, payload_size);
972 972
973 rc = smscore_sendrequest_and_wait(coredev, DataMsg, 973 rc = smscore_sendrequest_and_wait(coredev, data_msg,
974 DataMsg->x_msg_header.msg_length, 974 data_msg->x_msg_header.msg_length,
975 &coredev->data_download_done); 975 &coredev->data_download_done);
976 976
977 payload += payload_size; 977 payload += payload_size;
@@ -987,10 +987,10 @@ static int smscore_load_firmware_family2(struct smscore_device_t *coredev,
987 SMS_INIT_MSG(&msg->x_msg_header, MSG_SMS_DATA_VALIDITY_REQ, 987 SMS_INIT_MSG(&msg->x_msg_header, MSG_SMS_DATA_VALIDITY_REQ,
988 sizeof(msg->x_msg_header) + 988 sizeof(msg->x_msg_header) +
989 sizeof(u32) * 3); 989 sizeof(u32) * 3);
990 msg->msgData[0] = firmware->start_address; 990 msg->msg_data[0] = firmware->start_address;
991 /* Entry point */ 991 /* Entry point */
992 msg->msgData[1] = firmware->length; 992 msg->msg_data[1] = firmware->length;
993 msg->msgData[2] = 0; /* Regular checksum*/ 993 msg->msg_data[2] = 0; /* Regular checksum*/
994 rc = smscore_sendrequest_and_wait(coredev, msg, 994 rc = smscore_sendrequest_and_wait(coredev, msg,
995 msg->x_msg_header.msg_length, 995 msg->x_msg_header.msg_length,
996 &coredev->data_validity_done); 996 &coredev->data_validity_done);
@@ -998,7 +998,7 @@ static int smscore_load_firmware_family2(struct smscore_device_t *coredev,
998 goto exit_fw_download; 998 goto exit_fw_download;
999 999
1000 if (coredev->mode == DEVICE_MODE_NONE) { 1000 if (coredev->mode == DEVICE_MODE_NONE) {
1001 struct sms_msg_data *TriggerMsg = 1001 struct sms_msg_data *trigger_msg =
1002 (struct sms_msg_data *) msg; 1002 (struct sms_msg_data *) msg;
1003 1003
1004 sms_debug("sending MSG_SMS_SWDOWNLOAD_TRIGGER_REQ"); 1004 sms_debug("sending MSG_SMS_SWDOWNLOAD_TRIGGER_REQ");
@@ -1007,15 +1007,15 @@ static int smscore_load_firmware_family2(struct smscore_device_t *coredev,
1007 sizeof(struct sms_msg_hdr) + 1007 sizeof(struct sms_msg_hdr) +
1008 sizeof(u32) * 5); 1008 sizeof(u32) * 5);
1009 1009
1010 TriggerMsg->msgData[0] = firmware->start_address; 1010 trigger_msg->msg_data[0] = firmware->start_address;
1011 /* Entry point */ 1011 /* Entry point */
1012 TriggerMsg->msgData[1] = 6; /* Priority */ 1012 trigger_msg->msg_data[1] = 6; /* Priority */
1013 TriggerMsg->msgData[2] = 0x200; /* Stack size */ 1013 trigger_msg->msg_data[2] = 0x200; /* Stack size */
1014 TriggerMsg->msgData[3] = 0; /* Parameter */ 1014 trigger_msg->msg_data[3] = 0; /* Parameter */
1015 TriggerMsg->msgData[4] = 4; /* Task ID */ 1015 trigger_msg->msg_data[4] = 4; /* Task ID */
1016 1016
1017 rc = smscore_sendrequest_and_wait(coredev, TriggerMsg, 1017 rc = smscore_sendrequest_and_wait(coredev, trigger_msg,
1018 TriggerMsg->x_msg_header.msg_length, 1018 trigger_msg->x_msg_header.msg_length,
1019 &coredev->trigger_done); 1019 &coredev->trigger_done);
1020 } else { 1020 } else {
1021 SMS_INIT_MSG(&msg->x_msg_header, MSG_SW_RELOAD_EXEC_REQ, 1021 SMS_INIT_MSG(&msg->x_msg_header, MSG_SW_RELOAD_EXEC_REQ,
@@ -1315,7 +1315,7 @@ int smscore_init_device(struct smscore_device_t *coredev, int mode)
1315 msg = (struct sms_msg_data *)SMS_ALIGN_ADDRESS(buffer); 1315 msg = (struct sms_msg_data *)SMS_ALIGN_ADDRESS(buffer);
1316 SMS_INIT_MSG(&msg->x_msg_header, MSG_SMS_INIT_DEVICE_REQ, 1316 SMS_INIT_MSG(&msg->x_msg_header, MSG_SMS_INIT_DEVICE_REQ,
1317 sizeof(struct sms_msg_data)); 1317 sizeof(struct sms_msg_data));
1318 msg->msgData[0] = mode; 1318 msg->msg_data[0] = mode;
1319 1319
1320 rc = smscore_sendrequest_and_wait(coredev, msg, 1320 rc = smscore_sendrequest_and_wait(coredev, msg,
1321 msg->x_msg_header. msg_length, 1321 msg->x_msg_header. msg_length,
@@ -1403,7 +1403,7 @@ int smscore_set_device_mode(struct smscore_device_t *coredev, int mode)
1403 1403
1404 SMS_INIT_MSG(&msg->x_msg_header, MSG_SMS_INIT_DEVICE_REQ, 1404 SMS_INIT_MSG(&msg->x_msg_header, MSG_SMS_INIT_DEVICE_REQ,
1405 sizeof(struct sms_msg_data)); 1405 sizeof(struct sms_msg_data));
1406 msg->msgData[0] = mode; 1406 msg->msg_data[0] = mode;
1407 1407
1408 rc = smscore_sendrequest_and_wait( 1408 rc = smscore_sendrequest_and_wait(
1409 coredev, msg, msg->x_msg_header.msg_length, 1409 coredev, msg, msg->x_msg_header.msg_length,
@@ -1563,7 +1563,7 @@ void smscore_onresponse(struct smscore_device_t *coredev,
1563 struct sms_msg_data *validity = (struct sms_msg_data *) phdr; 1563 struct sms_msg_data *validity = (struct sms_msg_data *) phdr;
1564 1564
1565 sms_err("MSG_SMS_DATA_VALIDITY_RES, checksum = 0x%x", 1565 sms_err("MSG_SMS_DATA_VALIDITY_RES, checksum = 0x%x",
1566 validity->msgData[0]); 1566 validity->msg_data[0]);
1567 complete(&coredev->data_validity_done); 1567 complete(&coredev->data_validity_done);
1568 break; 1568 break;
1569 } 1569 }
@@ -1897,52 +1897,52 @@ int smscore_set_gpio(struct smscore_device_t *coredev, u32 pin, int level)
1897} 1897}
1898 1898
1899/* new GPIO management implementation */ 1899/* new GPIO management implementation */
1900static int GetGpioPinParams(u32 pin_num, u32 *pTranslatedpin_num, 1900static int get_gpio_pin_params(u32 pin_num, u32 *p_translatedpin_num,
1901 u32 *pGroupNum, u32 *pGroupCfg) { 1901 u32 *p_group_num, u32 *p_group_cfg) {
1902 1902
1903 *pGroupCfg = 1; 1903 *p_group_cfg = 1;
1904 1904
1905 if (pin_num <= 1) { 1905 if (pin_num <= 1) {
1906 *pTranslatedpin_num = 0; 1906 *p_translatedpin_num = 0;
1907 *pGroupNum = 9; 1907 *p_group_num = 9;
1908 *pGroupCfg = 2; 1908 *p_group_cfg = 2;
1909 } else if (pin_num >= 2 && pin_num <= 6) { 1909 } else if (pin_num >= 2 && pin_num <= 6) {
1910 *pTranslatedpin_num = 2; 1910 *p_translatedpin_num = 2;
1911 *pGroupNum = 0; 1911 *p_group_num = 0;
1912 *pGroupCfg = 2; 1912 *p_group_cfg = 2;
1913 } else if (pin_num >= 7 && pin_num <= 11) { 1913 } else if (pin_num >= 7 && pin_num <= 11) {
1914 *pTranslatedpin_num = 7; 1914 *p_translatedpin_num = 7;
1915 *pGroupNum = 1; 1915 *p_group_num = 1;
1916 } else if (pin_num >= 12 && pin_num <= 15) { 1916 } else if (pin_num >= 12 && pin_num <= 15) {
1917 *pTranslatedpin_num = 12; 1917 *p_translatedpin_num = 12;
1918 *pGroupNum = 2; 1918 *p_group_num = 2;
1919 *pGroupCfg = 3; 1919 *p_group_cfg = 3;
1920 } else if (pin_num == 16) { 1920 } else if (pin_num == 16) {
1921 *pTranslatedpin_num = 16; 1921 *p_translatedpin_num = 16;
1922 *pGroupNum = 23; 1922 *p_group_num = 23;
1923 } else if (pin_num >= 17 && pin_num <= 24) { 1923 } else if (pin_num >= 17 && pin_num <= 24) {
1924 *pTranslatedpin_num = 17; 1924 *p_translatedpin_num = 17;
1925 *pGroupNum = 3; 1925 *p_group_num = 3;
1926 } else if (pin_num == 25) { 1926 } else if (pin_num == 25) {
1927 *pTranslatedpin_num = 25; 1927 *p_translatedpin_num = 25;
1928 *pGroupNum = 6; 1928 *p_group_num = 6;
1929 } else if (pin_num >= 26 && pin_num <= 28) { 1929 } else if (pin_num >= 26 && pin_num <= 28) {
1930 *pTranslatedpin_num = 26; 1930 *p_translatedpin_num = 26;
1931 *pGroupNum = 4; 1931 *p_group_num = 4;
1932 } else if (pin_num == 29) { 1932 } else if (pin_num == 29) {
1933 *pTranslatedpin_num = 29; 1933 *p_translatedpin_num = 29;
1934 *pGroupNum = 5; 1934 *p_group_num = 5;
1935 *pGroupCfg = 2; 1935 *p_group_cfg = 2;
1936 } else if (pin_num == 30) { 1936 } else if (pin_num == 30) {
1937 *pTranslatedpin_num = 30; 1937 *p_translatedpin_num = 30;
1938 *pGroupNum = 8; 1938 *p_group_num = 8;
1939 } else if (pin_num == 31) { 1939 } else if (pin_num == 31) {
1940 *pTranslatedpin_num = 31; 1940 *p_translatedpin_num = 31;
1941 *pGroupNum = 17; 1941 *p_group_num = 17;
1942 } else 1942 } else
1943 return -1; 1943 return -1;
1944 1944
1945 *pGroupCfg <<= 24; 1945 *p_group_cfg <<= 24;
1946 1946
1947 return 0; 1947 return 0;
1948} 1948}
@@ -1950,18 +1950,18 @@ static int GetGpioPinParams(u32 pin_num, u32 *pTranslatedpin_num,
1950int smscore_gpio_configure(struct smscore_device_t *coredev, u8 pin_num, 1950int smscore_gpio_configure(struct smscore_device_t *coredev, u8 pin_num,
1951 struct smscore_config_gpio *p_gpio_config) { 1951 struct smscore_config_gpio *p_gpio_config) {
1952 1952
1953 u32 totalLen; 1953 u32 total_len;
1954 u32 Translatedpin_num = 0; 1954 u32 translatedpin_num = 0;
1955 u32 GroupNum = 0; 1955 u32 group_num = 0;
1956 u32 ElectricChar; 1956 u32 electric_char;
1957 u32 groupCfg; 1957 u32 group_cfg;
1958 void *buffer; 1958 void *buffer;
1959 int rc; 1959 int rc;
1960 1960
1961 struct SetGpioMsg { 1961 struct set_gpio_msg {
1962 struct sms_msg_hdr x_msg_header; 1962 struct sms_msg_hdr x_msg_header;
1963 u32 msgData[6]; 1963 u32 msg_data[6];
1964 } *pMsg; 1964 } *p_msg;
1965 1965
1966 1966
1967 if (pin_num > MAX_GPIO_PIN_NUMBER) 1967 if (pin_num > MAX_GPIO_PIN_NUMBER)
@@ -1970,48 +1970,48 @@ int smscore_gpio_configure(struct smscore_device_t *coredev, u8 pin_num,
1970 if (p_gpio_config == NULL) 1970 if (p_gpio_config == NULL)
1971 return -EINVAL; 1971 return -EINVAL;
1972 1972
1973 totalLen = sizeof(struct sms_msg_hdr) + (sizeof(u32) * 6); 1973 total_len = sizeof(struct sms_msg_hdr) + (sizeof(u32) * 6);
1974 1974
1975 buffer = kmalloc(totalLen + SMS_DMA_ALIGNMENT, 1975 buffer = kmalloc(total_len + SMS_DMA_ALIGNMENT,
1976 GFP_KERNEL | GFP_DMA); 1976 GFP_KERNEL | GFP_DMA);
1977 if (!buffer) 1977 if (!buffer)
1978 return -ENOMEM; 1978 return -ENOMEM;
1979 1979
1980 pMsg = (struct SetGpioMsg *) SMS_ALIGN_ADDRESS(buffer); 1980 p_msg = (struct set_gpio_msg *) SMS_ALIGN_ADDRESS(buffer);
1981 1981
1982 pMsg->x_msg_header.msg_src_id = DVBT_BDA_CONTROL_MSG_ID; 1982 p_msg->x_msg_header.msg_src_id = DVBT_BDA_CONTROL_MSG_ID;
1983 pMsg->x_msg_header.msg_dst_id = HIF_TASK; 1983 p_msg->x_msg_header.msg_dst_id = HIF_TASK;
1984 pMsg->x_msg_header.msg_flags = 0; 1984 p_msg->x_msg_header.msg_flags = 0;
1985 pMsg->x_msg_header.msg_length = (u16) totalLen; 1985 p_msg->x_msg_header.msg_length = (u16) total_len;
1986 pMsg->msgData[0] = pin_num; 1986 p_msg->msg_data[0] = pin_num;
1987 1987
1988 if (!(coredev->device_flags & SMS_DEVICE_FAMILY2)) { 1988 if (!(coredev->device_flags & SMS_DEVICE_FAMILY2)) {
1989 pMsg->x_msg_header.msg_type = MSG_SMS_GPIO_CONFIG_REQ; 1989 p_msg->x_msg_header.msg_type = MSG_SMS_GPIO_CONFIG_REQ;
1990 if (GetGpioPinParams(pin_num, &Translatedpin_num, &GroupNum, 1990 if (get_gpio_pin_params(pin_num, &translatedpin_num, &group_num,
1991 &groupCfg) != 0) { 1991 &group_cfg) != 0) {
1992 rc = -EINVAL; 1992 rc = -EINVAL;
1993 goto free; 1993 goto free;
1994 } 1994 }
1995 1995
1996 pMsg->msgData[1] = Translatedpin_num; 1996 p_msg->msg_data[1] = translatedpin_num;
1997 pMsg->msgData[2] = GroupNum; 1997 p_msg->msg_data[2] = group_num;
1998 ElectricChar = (p_gpio_config->pullupdown) 1998 electric_char = (p_gpio_config->pullupdown)
1999 | (p_gpio_config->inputcharacteristics << 2) 1999 | (p_gpio_config->inputcharacteristics << 2)
2000 | (p_gpio_config->outputslewrate << 3) 2000 | (p_gpio_config->outputslewrate << 3)
2001 | (p_gpio_config->outputdriving << 4); 2001 | (p_gpio_config->outputdriving << 4);
2002 pMsg->msgData[3] = ElectricChar; 2002 p_msg->msg_data[3] = electric_char;
2003 pMsg->msgData[4] = p_gpio_config->direction; 2003 p_msg->msg_data[4] = p_gpio_config->direction;
2004 pMsg->msgData[5] = groupCfg; 2004 p_msg->msg_data[5] = group_cfg;
2005 } else { 2005 } else {
2006 pMsg->x_msg_header.msg_type = MSG_SMS_GPIO_CONFIG_EX_REQ; 2006 p_msg->x_msg_header.msg_type = MSG_SMS_GPIO_CONFIG_EX_REQ;
2007 pMsg->msgData[1] = p_gpio_config->pullupdown; 2007 p_msg->msg_data[1] = p_gpio_config->pullupdown;
2008 pMsg->msgData[2] = p_gpio_config->outputslewrate; 2008 p_msg->msg_data[2] = p_gpio_config->outputslewrate;
2009 pMsg->msgData[3] = p_gpio_config->outputdriving; 2009 p_msg->msg_data[3] = p_gpio_config->outputdriving;
2010 pMsg->msgData[4] = p_gpio_config->direction; 2010 p_msg->msg_data[4] = p_gpio_config->direction;
2011 pMsg->msgData[5] = 0; 2011 p_msg->msg_data[5] = 0;
2012 } 2012 }
2013 2013
2014 rc = smscore_sendrequest_and_wait(coredev, pMsg, totalLen, 2014 rc = smscore_sendrequest_and_wait(coredev, p_msg, total_len,
2015 &coredev->gpio_configuration_done); 2015 &coredev->gpio_configuration_done);
2016 2016
2017 if (rc != 0) { 2017 if (rc != 0) {
@@ -2029,38 +2029,38 @@ free:
2029int smscore_gpio_set_level(struct smscore_device_t *coredev, u8 pin_num, 2029int smscore_gpio_set_level(struct smscore_device_t *coredev, u8 pin_num,
2030 u8 new_level) { 2030 u8 new_level) {
2031 2031
2032 u32 totalLen; 2032 u32 total_len;
2033 int rc; 2033 int rc;
2034 void *buffer; 2034 void *buffer;
2035 2035
2036 struct SetGpioMsg { 2036 struct set_gpio_msg {
2037 struct sms_msg_hdr x_msg_header; 2037 struct sms_msg_hdr x_msg_header;
2038 u32 msgData[3]; /* keep it 3 ! */ 2038 u32 msg_data[3]; /* keep it 3 ! */
2039 } *pMsg; 2039 } *p_msg;
2040 2040
2041 if ((new_level > 1) || (pin_num > MAX_GPIO_PIN_NUMBER)) 2041 if ((new_level > 1) || (pin_num > MAX_GPIO_PIN_NUMBER))
2042 return -EINVAL; 2042 return -EINVAL;
2043 2043
2044 totalLen = sizeof(struct sms_msg_hdr) + 2044 total_len = sizeof(struct sms_msg_hdr) +
2045 (3 * sizeof(u32)); /* keep it 3 ! */ 2045 (3 * sizeof(u32)); /* keep it 3 ! */
2046 2046
2047 buffer = kmalloc(totalLen + SMS_DMA_ALIGNMENT, 2047 buffer = kmalloc(total_len + SMS_DMA_ALIGNMENT,
2048 GFP_KERNEL | GFP_DMA); 2048 GFP_KERNEL | GFP_DMA);
2049 if (!buffer) 2049 if (!buffer)
2050 return -ENOMEM; 2050 return -ENOMEM;
2051 2051
2052 pMsg = (struct SetGpioMsg *) SMS_ALIGN_ADDRESS(buffer); 2052 p_msg = (struct set_gpio_msg *) SMS_ALIGN_ADDRESS(buffer);
2053 2053
2054 pMsg->x_msg_header.msg_src_id = DVBT_BDA_CONTROL_MSG_ID; 2054 p_msg->x_msg_header.msg_src_id = DVBT_BDA_CONTROL_MSG_ID;
2055 pMsg->x_msg_header.msg_dst_id = HIF_TASK; 2055 p_msg->x_msg_header.msg_dst_id = HIF_TASK;
2056 pMsg->x_msg_header.msg_flags = 0; 2056 p_msg->x_msg_header.msg_flags = 0;
2057 pMsg->x_msg_header.msg_type = MSG_SMS_GPIO_SET_LEVEL_REQ; 2057 p_msg->x_msg_header.msg_type = MSG_SMS_GPIO_SET_LEVEL_REQ;
2058 pMsg->x_msg_header.msg_length = (u16) totalLen; 2058 p_msg->x_msg_header.msg_length = (u16) total_len;
2059 pMsg->msgData[0] = pin_num; 2059 p_msg->msg_data[0] = pin_num;
2060 pMsg->msgData[1] = new_level; 2060 p_msg->msg_data[1] = new_level;
2061 2061
2062 /* Send message to SMS */ 2062 /* Send message to SMS */
2063 rc = smscore_sendrequest_and_wait(coredev, pMsg, totalLen, 2063 rc = smscore_sendrequest_and_wait(coredev, p_msg, total_len,
2064 &coredev->gpio_set_level_done); 2064 &coredev->gpio_set_level_done);
2065 2065
2066 if (rc != 0) { 2066 if (rc != 0) {
@@ -2077,38 +2077,38 @@ int smscore_gpio_set_level(struct smscore_device_t *coredev, u8 pin_num,
2077int smscore_gpio_get_level(struct smscore_device_t *coredev, u8 pin_num, 2077int smscore_gpio_get_level(struct smscore_device_t *coredev, u8 pin_num,
2078 u8 *level) { 2078 u8 *level) {
2079 2079
2080 u32 totalLen; 2080 u32 total_len;
2081 int rc; 2081 int rc;
2082 void *buffer; 2082 void *buffer;
2083 2083
2084 struct SetGpioMsg { 2084 struct set_gpio_msg {
2085 struct sms_msg_hdr x_msg_header; 2085 struct sms_msg_hdr x_msg_header;
2086 u32 msgData[2]; 2086 u32 msg_data[2];
2087 } *pMsg; 2087 } *p_msg;
2088 2088
2089 2089
2090 if (pin_num > MAX_GPIO_PIN_NUMBER) 2090 if (pin_num > MAX_GPIO_PIN_NUMBER)
2091 return -EINVAL; 2091 return -EINVAL;
2092 2092
2093 totalLen = sizeof(struct sms_msg_hdr) + (2 * sizeof(u32)); 2093 total_len = sizeof(struct sms_msg_hdr) + (2 * sizeof(u32));
2094 2094
2095 buffer = kmalloc(totalLen + SMS_DMA_ALIGNMENT, 2095 buffer = kmalloc(total_len + SMS_DMA_ALIGNMENT,
2096 GFP_KERNEL | GFP_DMA); 2096 GFP_KERNEL | GFP_DMA);
2097 if (!buffer) 2097 if (!buffer)
2098 return -ENOMEM; 2098 return -ENOMEM;
2099 2099
2100 pMsg = (struct SetGpioMsg *) SMS_ALIGN_ADDRESS(buffer); 2100 p_msg = (struct set_gpio_msg *) SMS_ALIGN_ADDRESS(buffer);
2101 2101
2102 pMsg->x_msg_header.msg_src_id = DVBT_BDA_CONTROL_MSG_ID; 2102 p_msg->x_msg_header.msg_src_id = DVBT_BDA_CONTROL_MSG_ID;
2103 pMsg->x_msg_header.msg_dst_id = HIF_TASK; 2103 p_msg->x_msg_header.msg_dst_id = HIF_TASK;
2104 pMsg->x_msg_header.msg_flags = 0; 2104 p_msg->x_msg_header.msg_flags = 0;
2105 pMsg->x_msg_header.msg_type = MSG_SMS_GPIO_GET_LEVEL_REQ; 2105 p_msg->x_msg_header.msg_type = MSG_SMS_GPIO_GET_LEVEL_REQ;
2106 pMsg->x_msg_header.msg_length = (u16) totalLen; 2106 p_msg->x_msg_header.msg_length = (u16) total_len;
2107 pMsg->msgData[0] = pin_num; 2107 p_msg->msg_data[0] = pin_num;
2108 pMsg->msgData[1] = 0; 2108 p_msg->msg_data[1] = 0;
2109 2109
2110 /* Send message to SMS */ 2110 /* Send message to SMS */
2111 rc = smscore_sendrequest_and_wait(coredev, pMsg, totalLen, 2111 rc = smscore_sendrequest_and_wait(coredev, p_msg, total_len,
2112 &coredev->gpio_get_level_done); 2112 &coredev->gpio_get_level_done);
2113 2113
2114 if (rc != 0) { 2114 if (rc != 0) {
diff --git a/drivers/media/common/siano/smscoreapi.h b/drivers/media/common/siano/smscoreapi.h
index b0253d2d2091..d3e781fedbc9 100644
--- a/drivers/media/common/siano/smscoreapi.h
+++ b/drivers/media/common/siano/smscoreapi.h
@@ -624,17 +624,17 @@ struct sms_msg_hdr {
624 624
625struct sms_msg_data { 625struct sms_msg_data {
626 struct sms_msg_hdr x_msg_header; 626 struct sms_msg_hdr x_msg_header;
627 u32 msgData[1]; 627 u32 msg_data[1];
628}; 628};
629 629
630struct sms_msg_data2 { 630struct sms_msg_data2 {
631 struct sms_msg_hdr x_msg_header; 631 struct sms_msg_hdr x_msg_header;
632 u32 msgData[2]; 632 u32 msg_data[2];
633}; 633};
634 634
635struct sms_msg_data4 { 635struct sms_msg_data4 {
636 struct sms_msg_hdr x_msg_header; 636 struct sms_msg_hdr x_msg_header;
637 u32 msgData[4]; 637 u32 msg_data[4];
638}; 638};
639 639
640struct sms_data_download { 640struct sms_data_download {
@@ -689,9 +689,9 @@ struct sms_stats {
689 689
690 /* Reception quality */ 690 /* Reception quality */
691 s32 SNR; /* dB */ 691 s32 SNR; /* dB */
692 u32 BER; /* Post Viterbi BER [1E-5] */ 692 u32 ber; /* Post Viterbi ber [1E-5] */
693 u32 FIB_CRC; /* CRC errors percentage, valid only for DAB */ 693 u32 FIB_CRC; /* CRC errors percentage, valid only for DAB */
694 u32 TS_PER; /* Transport stream PER, 694 u32 ts_per; /* Transport stream PER,
695 0xFFFFFFFF indicate N/A, valid only for DVB-T/H */ 695 0xFFFFFFFF indicate N/A, valid only for DVB-T/H */
696 u32 MFER; /* DVB-H frame error rate in percentage, 696 u32 MFER; /* DVB-H frame error rate in percentage,
697 0xFFFFFFFF indicate N/A, valid only for DVB-H */ 697 0xFFFFFFFF indicate N/A, valid only for DVB-H */
@@ -749,7 +749,7 @@ struct sms_stats {
749 u32 sms_to_host_tx_errors; /* Total number of transmission errors. */ 749 u32 sms_to_host_tx_errors; /* Total number of transmission errors. */
750 750
751 /* DAB/T-DMB */ 751 /* DAB/T-DMB */
752 u32 pre_ber; /* DAB/T-DMB only: Pre Viterbi BER [1E-5] */ 752 u32 pre_ber; /* DAB/T-DMB only: Pre Viterbi ber [1E-5] */
753 753
754 /* DVB-H TPS parameters */ 754 /* DVB-H TPS parameters */
755 u32 cell_id; /* TPS Cell ID in bits 15..0, bits 31..16 zero; 755 u32 cell_id; /* TPS Cell ID in bits 15..0, bits 31..16 zero;
@@ -781,11 +781,11 @@ struct sms_isdbt_layer_stats {
781 * 255 means layer does not exist */ 781 * 255 means layer does not exist */
782 u32 constellation; /* constellation from SMSHOSTLIB_CONSTELLATION_ET, 782 u32 constellation; /* constellation from SMSHOSTLIB_CONSTELLATION_ET,
783 * 255 means layer does not exist */ 783 * 255 means layer does not exist */
784 u32 BER; /* Post Viterbi BER [1E-5], 0xFFFFFFFF indicate N/A */ 784 u32 ber; /* Post Viterbi ber [1E-5], 0xFFFFFFFF indicate N/A */
785 u32 ber_error_count; /* Post Viterbi Error Bits Count */ 785 u32 ber_error_count; /* Post Viterbi Error Bits Count */
786 u32 ber_bit_count; /* Post Viterbi Total Bits Count */ 786 u32 ber_bit_count; /* Post Viterbi Total Bits Count */
787 u32 pre_ber; /* Pre Viterbi BER [1E-5], 0xFFFFFFFF indicate N/A */ 787 u32 pre_ber; /* Pre Viterbi ber [1E-5], 0xFFFFFFFF indicate N/A */
788 u32 TS_PER; /* Transport stream PER [%], 0xFFFFFFFF indicate N/A */ 788 u32 ts_per; /* Transport stream PER [%], 0xFFFFFFFF indicate N/A */
789 u32 error_ts_packets; /* Number of erroneous transport-stream packets */ 789 u32 error_ts_packets; /* Number of erroneous transport-stream packets */
790 u32 total_ts_packets; /* Total number of transport-stream packets */ 790 u32 total_ts_packets; /* Total number of transport-stream packets */
791 u32 ti_ldepth_i; /* Time interleaver depth I parameter, 791 u32 ti_ldepth_i; /* Time interleaver depth I parameter,
@@ -830,7 +830,7 @@ struct sms_isdbt_stats {
830 830
831 /* Per-layer information */ 831 /* Per-layer information */
832 /* Layers A, B and C */ 832 /* Layers A, B and C */
833 struct sms_isdbt_layer_stats LayerInfo[3]; 833 struct sms_isdbt_layer_stats layer_info[3];
834 /* Per-layer statistics, see sms_isdbt_layer_stats */ 834 /* Per-layer statistics, see sms_isdbt_layer_stats */
835 835
836 /* Interface information */ 836 /* Interface information */
@@ -875,7 +875,7 @@ struct sms_isdbt_stats_ex {
875 875
876 /* Per-layer information */ 876 /* Per-layer information */
877 /* Layers A, B and C */ 877 /* Layers A, B and C */
878 struct sms_isdbt_layer_stats LayerInfo[3]; 878 struct sms_isdbt_layer_stats layer_info[3];
879 /* Per-layer statistics, see sms_isdbt_layer_stats */ 879 /* Per-layer statistics, see sms_isdbt_layer_stats */
880 880
881 /* Interface information */ 881 /* Interface information */
@@ -958,10 +958,10 @@ struct sms_rx_stats {
958 958
959 u32 modem_state; /* from SMSHOSTLIB_DVB_MODEM_STATE_ET */ 959 u32 modem_state; /* from SMSHOSTLIB_DVB_MODEM_STATE_ET */
960 s32 SNR; /* dB */ 960 s32 SNR; /* dB */
961 u32 BER; /* Post Viterbi BER [1E-5] */ 961 u32 ber; /* Post Viterbi ber [1E-5] */
962 u32 ber_error_count; /* Number of erronous SYNC bits. */ 962 u32 ber_error_count; /* Number of erronous SYNC bits. */
963 u32 ber_bit_count; /* Total number of SYNC bits. */ 963 u32 ber_bit_count; /* Total number of SYNC bits. */
964 u32 TS_PER; /* Transport stream PER, 964 u32 ts_per; /* Transport stream PER,
965 0xFFFFFFFF indicate N/A */ 965 0xFFFFFFFF indicate N/A */
966 u32 MFER; /* DVB-H frame error rate in percentage, 966 u32 MFER; /* DVB-H frame error rate in percentage,
967 0xFFFFFFFF indicate N/A, valid only for DVB-H */ 967 0xFFFFFFFF indicate N/A, valid only for DVB-H */
@@ -984,10 +984,10 @@ struct sms_rx_stats_ex {
984 984
985 u32 modem_state; /* from SMSHOSTLIB_DVB_MODEM_STATE_ET */ 985 u32 modem_state; /* from SMSHOSTLIB_DVB_MODEM_STATE_ET */
986 s32 SNR; /* dB */ 986 s32 SNR; /* dB */
987 u32 BER; /* Post Viterbi BER [1E-5] */ 987 u32 ber; /* Post Viterbi ber [1E-5] */
988 u32 ber_error_count; /* Number of erronous SYNC bits. */ 988 u32 ber_error_count; /* Number of erronous SYNC bits. */
989 u32 ber_bit_count; /* Total number of SYNC bits. */ 989 u32 ber_bit_count; /* Total number of SYNC bits. */
990 u32 TS_PER; /* Transport stream PER, 990 u32 ts_per; /* Transport stream PER,
991 0xFFFFFFFF indicate N/A */ 991 0xFFFFFFFF indicate N/A */
992 u32 MFER; /* DVB-H frame error rate in percentage, 992 u32 MFER; /* DVB-H frame error rate in percentage,
993 0xFFFFFFFF indicate N/A, valid only for DVB-H */ 993 0xFFFFFFFF indicate N/A, valid only for DVB-H */
diff --git a/drivers/media/common/siano/smsdvb-debugfs.c b/drivers/media/common/siano/smsdvb-debugfs.c
index f63121ccbd10..a881da548251 100644
--- a/drivers/media/common/siano/smsdvb-debugfs.c
+++ b/drivers/media/common/siano/smsdvb-debugfs.c
@@ -71,11 +71,11 @@ void smsdvb_print_dvb_stats(struct smsdvb_debugfs *debug_data,
71 n += snprintf(&buf[n], PAGE_SIZE - n, 71 n += snprintf(&buf[n], PAGE_SIZE - n,
72 "SNR = %d\n", p->SNR); 72 "SNR = %d\n", p->SNR);
73 n += snprintf(&buf[n], PAGE_SIZE - n, 73 n += snprintf(&buf[n], PAGE_SIZE - n,
74 "BER = %d\n", p->BER); 74 "ber = %d\n", p->ber);
75 n += snprintf(&buf[n], PAGE_SIZE - n, 75 n += snprintf(&buf[n], PAGE_SIZE - n,
76 "FIB_CRC = %d\n", p->FIB_CRC); 76 "FIB_CRC = %d\n", p->FIB_CRC);
77 n += snprintf(&buf[n], PAGE_SIZE - n, 77 n += snprintf(&buf[n], PAGE_SIZE - n,
78 "TS_PER = %d\n", p->TS_PER); 78 "ts_per = %d\n", p->ts_per);
79 n += snprintf(&buf[n], PAGE_SIZE - n, 79 n += snprintf(&buf[n], PAGE_SIZE - n,
80 "MFER = %d\n", p->MFER); 80 "MFER = %d\n", p->MFER);
81 n += snprintf(&buf[n], PAGE_SIZE - n, 81 n += snprintf(&buf[n], PAGE_SIZE - n,
@@ -204,36 +204,36 @@ void smsdvb_print_isdb_stats(struct smsdvb_debugfs *debug_data,
204 "sms_to_host_tx_errors = %d\n", p->sms_to_host_tx_errors); 204 "sms_to_host_tx_errors = %d\n", p->sms_to_host_tx_errors);
205 205
206 for (i = 0; i < 3; i++) { 206 for (i = 0; i < 3; i++) {
207 if (p->LayerInfo[i].number_of_segments < 1 || 207 if (p->layer_info[i].number_of_segments < 1 ||
208 p->LayerInfo[i].number_of_segments > 13) 208 p->layer_info[i].number_of_segments > 13)
209 continue; 209 continue;
210 210
211 n += snprintf(&buf[n], PAGE_SIZE - n, "\nLayer %d\n", i); 211 n += snprintf(&buf[n], PAGE_SIZE - n, "\nLayer %d\n", i);
212 n += snprintf(&buf[n], PAGE_SIZE - n, "\tcode_rate = %d\t", 212 n += snprintf(&buf[n], PAGE_SIZE - n, "\tcode_rate = %d\t",
213 p->LayerInfo[i].code_rate); 213 p->layer_info[i].code_rate);
214 n += snprintf(&buf[n], PAGE_SIZE - n, "constellation = %d\n", 214 n += snprintf(&buf[n], PAGE_SIZE - n, "constellation = %d\n",
215 p->LayerInfo[i].constellation); 215 p->layer_info[i].constellation);
216 n += snprintf(&buf[n], PAGE_SIZE - n, "\tBER = %-5d\t", 216 n += snprintf(&buf[n], PAGE_SIZE - n, "\tber = %-5d\t",
217 p->LayerInfo[i].BER); 217 p->layer_info[i].ber);
218 n += snprintf(&buf[n], PAGE_SIZE - n, "\tber_error_count = %-5d\t", 218 n += snprintf(&buf[n], PAGE_SIZE - n, "\tber_error_count = %-5d\t",
219 p->LayerInfo[i].ber_error_count); 219 p->layer_info[i].ber_error_count);
220 n += snprintf(&buf[n], PAGE_SIZE - n, "ber_bit_count = %-5d\n", 220 n += snprintf(&buf[n], PAGE_SIZE - n, "ber_bit_count = %-5d\n",
221 p->LayerInfo[i].ber_bit_count); 221 p->layer_info[i].ber_bit_count);
222 n += snprintf(&buf[n], PAGE_SIZE - n, "\tpre_ber = %-5d\t", 222 n += snprintf(&buf[n], PAGE_SIZE - n, "\tpre_ber = %-5d\t",
223 p->LayerInfo[i].pre_ber); 223 p->layer_info[i].pre_ber);
224 n += snprintf(&buf[n], PAGE_SIZE - n, "\tTS_PER = %-5d\n", 224 n += snprintf(&buf[n], PAGE_SIZE - n, "\tts_per = %-5d\n",
225 p->LayerInfo[i].TS_PER); 225 p->layer_info[i].ts_per);
226 n += snprintf(&buf[n], PAGE_SIZE - n, "\terror_ts_packets = %-5d\t", 226 n += snprintf(&buf[n], PAGE_SIZE - n, "\terror_ts_packets = %-5d\t",
227 p->LayerInfo[i].error_ts_packets); 227 p->layer_info[i].error_ts_packets);
228 n += snprintf(&buf[n], PAGE_SIZE - n, "total_ts_packets = %-5d\t", 228 n += snprintf(&buf[n], PAGE_SIZE - n, "total_ts_packets = %-5d\t",
229 p->LayerInfo[i].total_ts_packets); 229 p->layer_info[i].total_ts_packets);
230 n += snprintf(&buf[n], PAGE_SIZE - n, "ti_ldepth_i = %d\n", 230 n += snprintf(&buf[n], PAGE_SIZE - n, "ti_ldepth_i = %d\n",
231 p->LayerInfo[i].ti_ldepth_i); 231 p->layer_info[i].ti_ldepth_i);
232 n += snprintf(&buf[n], PAGE_SIZE - n, 232 n += snprintf(&buf[n], PAGE_SIZE - n,
233 "\tnumber_of_segments = %d\t", 233 "\tnumber_of_segments = %d\t",
234 p->LayerInfo[i].number_of_segments); 234 p->layer_info[i].number_of_segments);
235 n += snprintf(&buf[n], PAGE_SIZE - n, "tmcc_errors = %d\n", 235 n += snprintf(&buf[n], PAGE_SIZE - n, "tmcc_errors = %d\n",
236 p->LayerInfo[i].tmcc_errors); 236 p->layer_info[i].tmcc_errors);
237 } 237 }
238 238
239 debug_data->stats_count = n; 239 debug_data->stats_count = n;
@@ -296,36 +296,36 @@ void smsdvb_print_isdb_stats_ex(struct smsdvb_debugfs *debug_data,
296 p->tune_bw); 296 p->tune_bw);
297 297
298 for (i = 0; i < 3; i++) { 298 for (i = 0; i < 3; i++) {
299 if (p->LayerInfo[i].number_of_segments < 1 || 299 if (p->layer_info[i].number_of_segments < 1 ||
300 p->LayerInfo[i].number_of_segments > 13) 300 p->layer_info[i].number_of_segments > 13)
301 continue; 301 continue;
302 302
303 n += snprintf(&buf[n], PAGE_SIZE - n, "\nLayer %d\n", i); 303 n += snprintf(&buf[n], PAGE_SIZE - n, "\nLayer %d\n", i);
304 n += snprintf(&buf[n], PAGE_SIZE - n, "\tcode_rate = %d\t", 304 n += snprintf(&buf[n], PAGE_SIZE - n, "\tcode_rate = %d\t",
305 p->LayerInfo[i].code_rate); 305 p->layer_info[i].code_rate);
306 n += snprintf(&buf[n], PAGE_SIZE - n, "constellation = %d\n", 306 n += snprintf(&buf[n], PAGE_SIZE - n, "constellation = %d\n",
307 p->LayerInfo[i].constellation); 307 p->layer_info[i].constellation);
308 n += snprintf(&buf[n], PAGE_SIZE - n, "\tBER = %-5d\t", 308 n += snprintf(&buf[n], PAGE_SIZE - n, "\tber = %-5d\t",
309 p->LayerInfo[i].BER); 309 p->layer_info[i].ber);
310 n += snprintf(&buf[n], PAGE_SIZE - n, "\tber_error_count = %-5d\t", 310 n += snprintf(&buf[n], PAGE_SIZE - n, "\tber_error_count = %-5d\t",
311 p->LayerInfo[i].ber_error_count); 311 p->layer_info[i].ber_error_count);
312 n += snprintf(&buf[n], PAGE_SIZE - n, "ber_bit_count = %-5d\n", 312 n += snprintf(&buf[n], PAGE_SIZE - n, "ber_bit_count = %-5d\n",
313 p->LayerInfo[i].ber_bit_count); 313 p->layer_info[i].ber_bit_count);
314 n += snprintf(&buf[n], PAGE_SIZE - n, "\tpre_ber = %-5d\t", 314 n += snprintf(&buf[n], PAGE_SIZE - n, "\tpre_ber = %-5d\t",
315 p->LayerInfo[i].pre_ber); 315 p->layer_info[i].pre_ber);
316 n += snprintf(&buf[n], PAGE_SIZE - n, "\tTS_PER = %-5d\n", 316 n += snprintf(&buf[n], PAGE_SIZE - n, "\tts_per = %-5d\n",
317 p->LayerInfo[i].TS_PER); 317 p->layer_info[i].ts_per);
318 n += snprintf(&buf[n], PAGE_SIZE - n, "\terror_ts_packets = %-5d\t", 318 n += snprintf(&buf[n], PAGE_SIZE - n, "\terror_ts_packets = %-5d\t",
319 p->LayerInfo[i].error_ts_packets); 319 p->layer_info[i].error_ts_packets);
320 n += snprintf(&buf[n], PAGE_SIZE - n, "total_ts_packets = %-5d\t", 320 n += snprintf(&buf[n], PAGE_SIZE - n, "total_ts_packets = %-5d\t",
321 p->LayerInfo[i].total_ts_packets); 321 p->layer_info[i].total_ts_packets);
322 n += snprintf(&buf[n], PAGE_SIZE - n, "ti_ldepth_i = %d\n", 322 n += snprintf(&buf[n], PAGE_SIZE - n, "ti_ldepth_i = %d\n",
323 p->LayerInfo[i].ti_ldepth_i); 323 p->layer_info[i].ti_ldepth_i);
324 n += snprintf(&buf[n], PAGE_SIZE - n, 324 n += snprintf(&buf[n], PAGE_SIZE - n,
325 "\tnumber_of_segments = %d\t", 325 "\tnumber_of_segments = %d\t",
326 p->LayerInfo[i].number_of_segments); 326 p->layer_info[i].number_of_segments);
327 n += snprintf(&buf[n], PAGE_SIZE - n, "tmcc_errors = %d\n", 327 n += snprintf(&buf[n], PAGE_SIZE - n, "tmcc_errors = %d\n",
328 p->LayerInfo[i].tmcc_errors); 328 p->layer_info[i].tmcc_errors);
329 } 329 }
330 330
331 331
diff --git a/drivers/media/common/siano/smsdvb-main.c b/drivers/media/common/siano/smsdvb-main.c
index 29d1c41bbd66..d965a7ae5982 100644
--- a/drivers/media/common/siano/smsdvb-main.c
+++ b/drivers/media/common/siano/smsdvb-main.c
@@ -265,7 +265,7 @@ static void smsdvb_update_per_slices(struct smsdvb_client_t *client,
265 c->block_error.stat[0].uvalue += p->ets_packets; 265 c->block_error.stat[0].uvalue += p->ets_packets;
266 c->block_count.stat[0].uvalue += p->ets_packets + p->ts_packets; 266 c->block_count.stat[0].uvalue += p->ets_packets + p->ts_packets;
267 267
268 /* BER */ 268 /* ber */
269 c->post_bit_error.stat[0].scale = FE_SCALE_COUNTER; 269 c->post_bit_error.stat[0].scale = FE_SCALE_COUNTER;
270 c->post_bit_count.stat[0].scale = FE_SCALE_COUNTER; 270 c->post_bit_count.stat[0].scale = FE_SCALE_COUNTER;
271 c->post_bit_error.stat[0].uvalue += p->ber_error_count; 271 c->post_bit_error.stat[0].uvalue += p->ber_error_count;
@@ -318,14 +318,14 @@ static void smsdvb_update_dvb_stats(struct smsdvb_client_t *client,
318 c->block_error.stat[0].uvalue += p->error_ts_packets; 318 c->block_error.stat[0].uvalue += p->error_ts_packets;
319 c->block_count.stat[0].uvalue += p->total_ts_packets; 319 c->block_count.stat[0].uvalue += p->total_ts_packets;
320 320
321 /* BER */ 321 /* ber */
322 c->post_bit_error.stat[0].scale = FE_SCALE_COUNTER; 322 c->post_bit_error.stat[0].scale = FE_SCALE_COUNTER;
323 c->post_bit_count.stat[0].scale = FE_SCALE_COUNTER; 323 c->post_bit_count.stat[0].scale = FE_SCALE_COUNTER;
324 c->post_bit_error.stat[0].uvalue += p->ber_error_count; 324 c->post_bit_error.stat[0].uvalue += p->ber_error_count;
325 c->post_bit_count.stat[0].uvalue += p->ber_bit_count; 325 c->post_bit_count.stat[0].uvalue += p->ber_bit_count;
326 326
327 /* Legacy PER/BER */ 327 /* Legacy PER/BER */
328 client->legacy_ber = p->BER; 328 client->legacy_ber = p->ber;
329}; 329};
330 330
331static void smsdvb_update_isdbt_stats(struct smsdvb_client_t *client, 331static void smsdvb_update_isdbt_stats(struct smsdvb_client_t *client,
@@ -391,7 +391,7 @@ static void smsdvb_update_isdbt_stats(struct smsdvb_client_t *client,
391 c->post_bit_count.stat[0].scale = FE_SCALE_COUNTER; 391 c->post_bit_count.stat[0].scale = FE_SCALE_COUNTER;
392 392
393 for (i = 0; i < n_layers; i++) { 393 for (i = 0; i < n_layers; i++) {
394 lr = &p->LayerInfo[i]; 394 lr = &p->layer_info[i];
395 395
396 /* Update per-layer transmission parameters */ 396 /* Update per-layer transmission parameters */
397 if (lr->number_of_segments > 0 && lr->number_of_segments < 13) { 397 if (lr->number_of_segments > 0 && lr->number_of_segments < 13) {
@@ -479,7 +479,7 @@ static void smsdvb_update_isdbt_stats_ex(struct smsdvb_client_t *client,
479 c->block_error.len = n_layers + 1; 479 c->block_error.len = n_layers + 1;
480 c->block_count.len = n_layers + 1; 480 c->block_count.len = n_layers + 1;
481 for (i = 0; i < n_layers; i++) { 481 for (i = 0; i < n_layers; i++) {
482 lr = &p->LayerInfo[i]; 482 lr = &p->layer_info[i];
483 483
484 /* Update per-layer transmission parameters */ 484 /* Update per-layer transmission parameters */
485 if (lr->number_of_segments > 0 && lr->number_of_segments < 13) { 485 if (lr->number_of_segments > 0 && lr->number_of_segments < 13) {
@@ -500,13 +500,13 @@ static void smsdvb_update_isdbt_stats_ex(struct smsdvb_client_t *client,
500 c->block_error.stat[0].uvalue += lr->error_ts_packets; 500 c->block_error.stat[0].uvalue += lr->error_ts_packets;
501 c->block_count.stat[0].uvalue += lr->total_ts_packets; 501 c->block_count.stat[0].uvalue += lr->total_ts_packets;
502 502
503 /* BER */ 503 /* ber */
504 c->post_bit_error.stat[i + 1].scale = FE_SCALE_COUNTER; 504 c->post_bit_error.stat[i + 1].scale = FE_SCALE_COUNTER;
505 c->post_bit_count.stat[i + 1].scale = FE_SCALE_COUNTER; 505 c->post_bit_count.stat[i + 1].scale = FE_SCALE_COUNTER;
506 c->post_bit_error.stat[i + 1].uvalue += lr->ber_error_count; 506 c->post_bit_error.stat[i + 1].uvalue += lr->ber_error_count;
507 c->post_bit_count.stat[i + 1].uvalue += lr->ber_bit_count; 507 c->post_bit_count.stat[i + 1].uvalue += lr->ber_bit_count;
508 508
509 /* Update global BER counter */ 509 /* Update global ber counter */
510 c->post_bit_error.stat[0].uvalue += lr->ber_error_count; 510 c->post_bit_error.stat[0].uvalue += lr->ber_error_count;
511 c->post_bit_count.stat[0].uvalue += lr->ber_bit_count; 511 c->post_bit_count.stat[0].uvalue += lr->ber_bit_count;
512 } 512 }
@@ -636,44 +636,44 @@ static int smsdvb_start_feed(struct dvb_demux_feed *feed)
636{ 636{
637 struct smsdvb_client_t *client = 637 struct smsdvb_client_t *client =
638 container_of(feed->demux, struct smsdvb_client_t, demux); 638 container_of(feed->demux, struct smsdvb_client_t, demux);
639 struct sms_msg_data PidMsg; 639 struct sms_msg_data pid_msg;
640 640
641 sms_debug("add pid %d(%x)", 641 sms_debug("add pid %d(%x)",
642 feed->pid, feed->pid); 642 feed->pid, feed->pid);
643 643
644 client->feed_users++; 644 client->feed_users++;
645 645
646 PidMsg.x_msg_header.msg_src_id = DVBT_BDA_CONTROL_MSG_ID; 646 pid_msg.x_msg_header.msg_src_id = DVBT_BDA_CONTROL_MSG_ID;
647 PidMsg.x_msg_header.msg_dst_id = HIF_TASK; 647 pid_msg.x_msg_header.msg_dst_id = HIF_TASK;
648 PidMsg.x_msg_header.msg_flags = 0; 648 pid_msg.x_msg_header.msg_flags = 0;
649 PidMsg.x_msg_header.msg_type = MSG_SMS_ADD_PID_FILTER_REQ; 649 pid_msg.x_msg_header.msg_type = MSG_SMS_ADD_PID_FILTER_REQ;
650 PidMsg.x_msg_header.msg_length = sizeof(PidMsg); 650 pid_msg.x_msg_header.msg_length = sizeof(pid_msg);
651 PidMsg.msgData[0] = feed->pid; 651 pid_msg.msg_data[0] = feed->pid;
652 652
653 return smsclient_sendrequest(client->smsclient, 653 return smsclient_sendrequest(client->smsclient,
654 &PidMsg, sizeof(PidMsg)); 654 &pid_msg, sizeof(pid_msg));
655} 655}
656 656
657static int smsdvb_stop_feed(struct dvb_demux_feed *feed) 657static int smsdvb_stop_feed(struct dvb_demux_feed *feed)
658{ 658{
659 struct smsdvb_client_t *client = 659 struct smsdvb_client_t *client =
660 container_of(feed->demux, struct smsdvb_client_t, demux); 660 container_of(feed->demux, struct smsdvb_client_t, demux);
661 struct sms_msg_data PidMsg; 661 struct sms_msg_data pid_msg;
662 662
663 sms_debug("remove pid %d(%x)", 663 sms_debug("remove pid %d(%x)",
664 feed->pid, feed->pid); 664 feed->pid, feed->pid);
665 665
666 client->feed_users--; 666 client->feed_users--;
667 667
668 PidMsg.x_msg_header.msg_src_id = DVBT_BDA_CONTROL_MSG_ID; 668 pid_msg.x_msg_header.msg_src_id = DVBT_BDA_CONTROL_MSG_ID;
669 PidMsg.x_msg_header.msg_dst_id = HIF_TASK; 669 pid_msg.x_msg_header.msg_dst_id = HIF_TASK;
670 PidMsg.x_msg_header.msg_flags = 0; 670 pid_msg.x_msg_header.msg_flags = 0;
671 PidMsg.x_msg_header.msg_type = MSG_SMS_REMOVE_PID_FILTER_REQ; 671 pid_msg.x_msg_header.msg_type = MSG_SMS_REMOVE_PID_FILTER_REQ;
672 PidMsg.x_msg_header.msg_length = sizeof(PidMsg); 672 pid_msg.x_msg_header.msg_length = sizeof(pid_msg);
673 PidMsg.msgData[0] = feed->pid; 673 pid_msg.msg_data[0] = feed->pid;
674 674
675 return smsclient_sendrequest(client->smsclient, 675 return smsclient_sendrequest(client->smsclient,
676 &PidMsg, sizeof(PidMsg)); 676 &pid_msg, sizeof(pid_msg));
677} 677}
678 678
679static int smsdvb_sendrequest_and_wait(struct smsdvb_client_t *client, 679static int smsdvb_sendrequest_and_wait(struct smsdvb_client_t *client,
@@ -694,7 +694,7 @@ static int smsdvb_sendrequest_and_wait(struct smsdvb_client_t *client,
694static int smsdvb_send_statistics_request(struct smsdvb_client_t *client) 694static int smsdvb_send_statistics_request(struct smsdvb_client_t *client)
695{ 695{
696 int rc; 696 int rc;
697 struct sms_msg_hdr Msg; 697 struct sms_msg_hdr msg;
698 698
699 /* Don't request stats too fast */ 699 /* Don't request stats too fast */
700 if (client->get_stats_jiffies && 700 if (client->get_stats_jiffies &&
@@ -702,10 +702,10 @@ static int smsdvb_send_statistics_request(struct smsdvb_client_t *client)
702 return 0; 702 return 0;
703 client->get_stats_jiffies = jiffies + msecs_to_jiffies(100); 703 client->get_stats_jiffies = jiffies + msecs_to_jiffies(100);
704 704
705 Msg.msg_src_id = DVBT_BDA_CONTROL_MSG_ID; 705 msg.msg_src_id = DVBT_BDA_CONTROL_MSG_ID;
706 Msg.msg_dst_id = HIF_TASK; 706 msg.msg_dst_id = HIF_TASK;
707 Msg.msg_flags = 0; 707 msg.msg_flags = 0;
708 Msg.msg_length = sizeof(Msg); 708 msg.msg_length = sizeof(msg);
709 709
710 switch (smscore_get_device_mode(client->coredev)) { 710 switch (smscore_get_device_mode(client->coredev)) {
711 case DEVICE_MODE_ISDBT: 711 case DEVICE_MODE_ISDBT:
@@ -714,15 +714,15 @@ static int smsdvb_send_statistics_request(struct smsdvb_client_t *client)
714 * Check for firmware version, to avoid breaking for old cards 714 * Check for firmware version, to avoid breaking for old cards
715 */ 715 */
716 if (client->coredev->fw_version >= 0x800) 716 if (client->coredev->fw_version >= 0x800)
717 Msg.msg_type = MSG_SMS_GET_STATISTICS_EX_REQ; 717 msg.msg_type = MSG_SMS_GET_STATISTICS_EX_REQ;
718 else 718 else
719 Msg.msg_type = MSG_SMS_GET_STATISTICS_REQ; 719 msg.msg_type = MSG_SMS_GET_STATISTICS_REQ;
720 break; 720 break;
721 default: 721 default:
722 Msg.msg_type = MSG_SMS_GET_STATISTICS_REQ; 722 msg.msg_type = MSG_SMS_GET_STATISTICS_REQ;
723 } 723 }
724 724
725 rc = smsdvb_sendrequest_and_wait(client, &Msg, sizeof(Msg), 725 rc = smsdvb_sendrequest_and_wait(client, &msg, sizeof(msg),
726 &client->stats_done); 726 &client->stats_done);
727 727
728 return rc; 728 return rc;
@@ -845,9 +845,9 @@ static int smsdvb_dvbt_set_frontend(struct dvb_frontend *fe)
845 container_of(fe, struct smsdvb_client_t, frontend); 845 container_of(fe, struct smsdvb_client_t, frontend);
846 846
847 struct { 847 struct {
848 struct sms_msg_hdr Msg; 848 struct sms_msg_hdr msg;
849 u32 Data[3]; 849 u32 Data[3];
850 } Msg; 850 } msg;
851 851
852 int ret; 852 int ret;
853 853
@@ -856,26 +856,26 @@ static int smsdvb_dvbt_set_frontend(struct dvb_frontend *fe)
856 client->event_unc_state = -1; 856 client->event_unc_state = -1;
857 fe->dtv_property_cache.delivery_system = SYS_DVBT; 857 fe->dtv_property_cache.delivery_system = SYS_DVBT;
858 858
859 Msg.Msg.msg_src_id = DVBT_BDA_CONTROL_MSG_ID; 859 msg.msg.msg_src_id = DVBT_BDA_CONTROL_MSG_ID;
860 Msg.Msg.msg_dst_id = HIF_TASK; 860 msg.msg.msg_dst_id = HIF_TASK;
861 Msg.Msg.msg_flags = 0; 861 msg.msg.msg_flags = 0;
862 Msg.Msg.msg_type = MSG_SMS_RF_TUNE_REQ; 862 msg.msg.msg_type = MSG_SMS_RF_TUNE_REQ;
863 Msg.Msg.msg_length = sizeof(Msg); 863 msg.msg.msg_length = sizeof(msg);
864 Msg.Data[0] = c->frequency; 864 msg.Data[0] = c->frequency;
865 Msg.Data[2] = 12000000; 865 msg.Data[2] = 12000000;
866 866
867 sms_info("%s: freq %d band %d", __func__, c->frequency, 867 sms_info("%s: freq %d band %d", __func__, c->frequency,
868 c->bandwidth_hz); 868 c->bandwidth_hz);
869 869
870 switch (c->bandwidth_hz / 1000000) { 870 switch (c->bandwidth_hz / 1000000) {
871 case 8: 871 case 8:
872 Msg.Data[1] = BW_8_MHZ; 872 msg.Data[1] = BW_8_MHZ;
873 break; 873 break;
874 case 7: 874 case 7:
875 Msg.Data[1] = BW_7_MHZ; 875 msg.Data[1] = BW_7_MHZ;
876 break; 876 break;
877 case 6: 877 case 6:
878 Msg.Data[1] = BW_6_MHZ; 878 msg.Data[1] = BW_6_MHZ;
879 break; 879 break;
880 case 0: 880 case 0:
881 return -EOPNOTSUPP; 881 return -EOPNOTSUPP;
@@ -888,7 +888,7 @@ static int smsdvb_dvbt_set_frontend(struct dvb_frontend *fe)
888 fe_status_t status; 888 fe_status_t status;
889 889
890 /* tune with LNA off at first */ 890 /* tune with LNA off at first */
891 ret = smsdvb_sendrequest_and_wait(client, &Msg, sizeof(Msg), 891 ret = smsdvb_sendrequest_and_wait(client, &msg, sizeof(msg),
892 &client->tune_done); 892 &client->tune_done);
893 893
894 smsdvb_read_status(fe, &status); 894 smsdvb_read_status(fe, &status);
@@ -900,7 +900,7 @@ static int smsdvb_dvbt_set_frontend(struct dvb_frontend *fe)
900 sms_board_lna_control(client->coredev, 1); 900 sms_board_lna_control(client->coredev, 1);
901 } 901 }
902 902
903 return smsdvb_sendrequest_and_wait(client, &Msg, sizeof(Msg), 903 return smsdvb_sendrequest_and_wait(client, &msg, sizeof(msg),
904 &client->tune_done); 904 &client->tune_done);
905} 905}
906 906
@@ -915,17 +915,17 @@ static int smsdvb_isdbt_set_frontend(struct dvb_frontend *fe)
915 int ret; 915 int ret;
916 916
917 struct { 917 struct {
918 struct sms_msg_hdr Msg; 918 struct sms_msg_hdr msg;
919 u32 Data[4]; 919 u32 Data[4];
920 } Msg; 920 } msg;
921 921
922 fe->dtv_property_cache.delivery_system = SYS_ISDBT; 922 fe->dtv_property_cache.delivery_system = SYS_ISDBT;
923 923
924 Msg.Msg.msg_src_id = DVBT_BDA_CONTROL_MSG_ID; 924 msg.msg.msg_src_id = DVBT_BDA_CONTROL_MSG_ID;
925 Msg.Msg.msg_dst_id = HIF_TASK; 925 msg.msg.msg_dst_id = HIF_TASK;
926 Msg.Msg.msg_flags = 0; 926 msg.msg.msg_flags = 0;
927 Msg.Msg.msg_type = MSG_SMS_ISDBT_TUNE_REQ; 927 msg.msg.msg_type = MSG_SMS_ISDBT_TUNE_REQ;
928 Msg.Msg.msg_length = sizeof(Msg); 928 msg.msg.msg_length = sizeof(msg);
929 929
930 if (c->isdbt_sb_segment_idx == -1) 930 if (c->isdbt_sb_segment_idx == -1)
931 c->isdbt_sb_segment_idx = 0; 931 c->isdbt_sb_segment_idx = 0;
@@ -933,19 +933,19 @@ static int smsdvb_isdbt_set_frontend(struct dvb_frontend *fe)
933 if (!c->isdbt_layer_enabled) 933 if (!c->isdbt_layer_enabled)
934 c->isdbt_layer_enabled = 7; 934 c->isdbt_layer_enabled = 7;
935 935
936 Msg.Data[0] = c->frequency; 936 msg.Data[0] = c->frequency;
937 Msg.Data[1] = BW_ISDBT_1SEG; 937 msg.Data[1] = BW_ISDBT_1SEG;
938 Msg.Data[2] = 12000000; 938 msg.Data[2] = 12000000;
939 Msg.Data[3] = c->isdbt_sb_segment_idx; 939 msg.Data[3] = c->isdbt_sb_segment_idx;
940 940
941 if (c->isdbt_partial_reception) { 941 if (c->isdbt_partial_reception) {
942 if ((type == SMS_PELE || type == SMS_RIO) && 942 if ((type == SMS_PELE || type == SMS_RIO) &&
943 c->isdbt_sb_segment_count > 3) 943 c->isdbt_sb_segment_count > 3)
944 Msg.Data[1] = BW_ISDBT_13SEG; 944 msg.Data[1] = BW_ISDBT_13SEG;
945 else if (c->isdbt_sb_segment_count > 1) 945 else if (c->isdbt_sb_segment_count > 1)
946 Msg.Data[1] = BW_ISDBT_3SEG; 946 msg.Data[1] = BW_ISDBT_3SEG;
947 } else if (type == SMS_PELE || type == SMS_RIO) 947 } else if (type == SMS_PELE || type == SMS_RIO)
948 Msg.Data[1] = BW_ISDBT_13SEG; 948 msg.Data[1] = BW_ISDBT_13SEG;
949 949
950 c->bandwidth_hz = 6000000; 950 c->bandwidth_hz = 6000000;
951 951
@@ -959,7 +959,7 @@ static int smsdvb_isdbt_set_frontend(struct dvb_frontend *fe)
959 fe_status_t status; 959 fe_status_t status;
960 960
961 /* tune with LNA off at first */ 961 /* tune with LNA off at first */
962 ret = smsdvb_sendrequest_and_wait(client, &Msg, sizeof(Msg), 962 ret = smsdvb_sendrequest_and_wait(client, &msg, sizeof(msg),
963 &client->tune_done); 963 &client->tune_done);
964 964
965 smsdvb_read_status(fe, &status); 965 smsdvb_read_status(fe, &status);
@@ -970,7 +970,7 @@ static int smsdvb_isdbt_set_frontend(struct dvb_frontend *fe)
970 /* previous tune didn't lock - enable LNA and tune again */ 970 /* previous tune didn't lock - enable LNA and tune again */
971 sms_board_lna_control(client->coredev, 1); 971 sms_board_lna_control(client->coredev, 1);
972 } 972 }
973 return smsdvb_sendrequest_and_wait(client, &Msg, sizeof(Msg), 973 return smsdvb_sendrequest_and_wait(client, &msg, sizeof(msg),
974 &client->tune_done); 974 &client->tune_done);
975} 975}
976 976
diff --git a/drivers/media/common/siano/smsdvb.h b/drivers/media/common/siano/smsdvb.h
index 513f85366209..92c413ba0c79 100644
--- a/drivers/media/common/siano/smsdvb.h
+++ b/drivers/media/common/siano/smsdvb.h
@@ -87,7 +87,7 @@ struct RECEPTION_STATISTICS_PER_SLICES_S {
87 u32 request_id; 87 u32 request_id;
88 u32 modem_state; /* from SMSHOSTLIB_DVB_MODEM_STATE_ET */ 88 u32 modem_state; /* from SMSHOSTLIB_DVB_MODEM_STATE_ET */
89 89
90 u32 BER; /* Post Viterbi BER [1E-5] */ 90 u32 ber; /* Post Viterbi BER [1E-5] */
91 s32 RSSI; /* dBm */ 91 s32 RSSI; /* dBm */
92 s32 carrier_offset; /* Carrier Offset in bin/1024 */ 92 s32 carrier_offset; /* Carrier Offset in bin/1024 */
93 93
diff --git a/drivers/media/common/siano/smsendian.c b/drivers/media/common/siano/smsendian.c
index 32a7b28bd324..bfe831c10b1c 100644
--- a/drivers/media/common/siano/smsendian.c
+++ b/drivers/media/common/siano/smsendian.c
@@ -30,21 +30,21 @@ void smsendian_handle_tx_message(void *buffer)
30#ifdef __BIG_ENDIAN 30#ifdef __BIG_ENDIAN
31 struct sms_msg_data *msg = (struct sms_msg_data *)buffer; 31 struct sms_msg_data *msg = (struct sms_msg_data *)buffer;
32 int i; 32 int i;
33 int msgWords; 33 int msg_words;
34 34
35 switch (msg->x_msg_header.msg_type) { 35 switch (msg->x_msg_header.msg_type) {
36 case MSG_SMS_DATA_DOWNLOAD_REQ: 36 case MSG_SMS_DATA_DOWNLOAD_REQ:
37 { 37 {
38 msg->msgData[0] = le32_to_cpu(msg->msgData[0]); 38 msg->msg_data[0] = le32_to_cpu(msg->msg_data[0]);
39 break; 39 break;
40 } 40 }
41 41
42 default: 42 default:
43 msgWords = (msg->x_msg_header.msg_length - 43 msg_words = (msg->x_msg_header.msg_length -
44 sizeof(struct sms_msg_hdr))/4; 44 sizeof(struct sms_msg_hdr))/4;
45 45
46 for (i = 0; i < msgWords; i++) 46 for (i = 0; i < msg_words; i++)
47 msg->msgData[i] = le32_to_cpu(msg->msgData[i]); 47 msg->msg_data[i] = le32_to_cpu(msg->msg_data[i]);
48 48
49 break; 49 break;
50 } 50 }
@@ -57,7 +57,7 @@ void smsendian_handle_rx_message(void *buffer)
57#ifdef __BIG_ENDIAN 57#ifdef __BIG_ENDIAN
58 struct sms_msg_data *msg = (struct sms_msg_data *)buffer; 58 struct sms_msg_data *msg = (struct sms_msg_data *)buffer;
59 int i; 59 int i;
60 int msgWords; 60 int msg_words;
61 61
62 switch (msg->x_msg_header.msg_type) { 62 switch (msg->x_msg_header.msg_type) {
63 case MSG_SMS_GET_VERSION_EX_RES: 63 case MSG_SMS_GET_VERSION_EX_RES:
@@ -77,11 +77,11 @@ void smsendian_handle_rx_message(void *buffer)
77 77
78 default: 78 default:
79 { 79 {
80 msgWords = (msg->x_msg_header.msg_length - 80 msg_words = (msg->x_msg_header.msg_length -
81 sizeof(struct sms_msg_hdr))/4; 81 sizeof(struct sms_msg_hdr))/4;
82 82
83 for (i = 0; i < msgWords; i++) 83 for (i = 0; i < msg_words; i++)
84 msg->msgData[i] = le32_to_cpu(msg->msgData[i]); 84 msg->msg_data[i] = le32_to_cpu(msg->msg_data[i]);
85 85
86 break; 86 break;
87 } 87 }