xmm6160: Rename modem_image to firmware to avoid confusion
authorPaul Kocialkowski <contact@paulk.fr>
Mon, 1 Jul 2013 13:42:09 +0000 (15:42 +0200)
committerPaul Kocialkowski <contact@paulk.fr>
Mon, 1 Jul 2013 13:42:09 +0000 (15:42 +0200)
Change-Id: I82bd09250192c47e3a5f43ead4bce2a899e484b4
Signed-off-by: Paul Kocialkowski <contact@paulk.fr>
samsung-ipc/device/aries/aries_ipc.c
samsung-ipc/device/crespo/crespo_ipc.c
samsung-ipc/device/xmm6160/xmm6160.c
samsung-ipc/device/xmm6160/xmm6160.h

index e62ec0a..87977e6 100644 (file)
@@ -158,12 +158,12 @@ int aries_ipc_bootstrap(struct ipc_client *client)
 
     pp = (unsigned char *) onedram_address;
 
-    rc = xmm6160_modem_image_send(client, -1, (void *) pp, (void *) p, ARIES_MODEM_IMAGE_SIZE - ARIES_PSI_SIZE);
+    rc = xmm6160_firmware_send(client, -1, (void *) pp, (void *) p, ARIES_MODEM_IMAGE_SIZE - ARIES_PSI_SIZE);
     if (rc < 0) {
-        ipc_client_log(client, "Sending XMM6160 modem image failed");
+        ipc_client_log(client, "Sending XMM6160 firmware failed");
         goto error;
     }
-    ipc_client_log(client, "Sent XMM6160 modem image");
+    ipc_client_log(client, "Sent XMM6160 firmware");
 
     pp = (unsigned char *) onedram_address + ARIES_ONEDRAM_NV_DATA_OFFSET;
 
index cd8777f..81a095d 100644 (file)
@@ -95,12 +95,12 @@ int crespo_ipc_bootstrap(struct ipc_client *client)
 
     lseek(modem_ctl_fd, 0, SEEK_SET);
 
-    rc = xmm6160_modem_image_send(client, modem_ctl_fd, NULL, (void *) p, CRESPO_MODEM_IMAGE_SIZE - CRESPO_PSI_SIZE);
+    rc = xmm6160_firmware_send(client, modem_ctl_fd, NULL, (void *) p, CRESPO_MODEM_IMAGE_SIZE - CRESPO_PSI_SIZE);
     if (rc < 0) {
-        ipc_client_log(client, "Sending XMM6160 modem image failed");
+        ipc_client_log(client, "Sending XMM6160 firmware failed");
         goto error;
     }
-    ipc_client_log(client, "Sent XMM6160 modem image");
+    ipc_client_log(client, "Sent XMM6160 firmware");
 
     lseek(modem_ctl_fd, CRESPO_MODEM_CTL_NV_DATA_OFFSET, SEEK_SET);
 
index 697c240..cf52f17 100644 (file)
@@ -185,8 +185,8 @@ complete:
     return rc;
 }
 
-int xmm6160_modem_image_send(struct ipc_client *client, int device_fd,
-    void *device_address, void *modem_image_data, int modem_image_size)
+int xmm6160_firmware_send(struct ipc_client *client, int device_fd,
+    void *device_address, void *firmware_data, int firmware_size)
 {
     int wc;
 
@@ -194,19 +194,19 @@ int xmm6160_modem_image_send(struct ipc_client *client, int device_fd,
     int rc;
     int i;
 
-    if (client == NULL || (device_fd < 0 && device_address == NULL) || modem_image_data == NULL || modem_image_size <= 0)
+    if (client == NULL || (device_fd < 0 && device_address == NULL) || firmware_data == NULL || firmware_size <= 0)
         return -1;
 
-    p = (unsigned char *) modem_image_data;
+    p = (unsigned char *) firmware_data;
 
     if (device_address != NULL) {
-        memcpy(device_address, (void *) p, modem_image_size);
+        memcpy(device_address, (void *) p, firmware_size);
     } else {
         wc = 0;
-        while (wc < modem_image_size) {
-            rc = write(device_fd, (void *) p, modem_image_size - wc);
+        while (wc < firmware_size) {
+            rc = write(device_fd, (void *) p, firmware_size - wc);
             if (rc < 0) {
-                ipc_client_log(client, "Writing modem image failed");
+                ipc_client_log(client, "Writing firmware failed");
                 goto error;
             }
 
@@ -214,7 +214,7 @@ int xmm6160_modem_image_send(struct ipc_client *client, int device_fd,
             wc += rc;
         }
     }
-    ipc_client_log(client, "Wrote modem image");
+    ipc_client_log(client, "Wrote firmware");
 
     rc = 0;
     goto complete;
index 9a2976c..9e201de 100644 (file)
@@ -31,8 +31,8 @@
 
 int xmm6160_psi_send(struct ipc_client *client, int serial_fd,
     void *psi_data, unsigned short psi_size);
-int xmm6160_modem_image_send(struct ipc_client *client, int device_fd,
-    void *device_address, void *modem_image_data, int modem_image_size);
+int xmm6160_firmware_send(struct ipc_client *client, int device_fd,
+    void *device_address, void *firmware_data, int firmware_size);
 int xmm6160_nv_data_send(struct ipc_client *client, int device_fd,
     void *device_address);