aboutsummaryrefslogtreecommitdiffstats
path: root/security
diff options
context:
space:
mode:
authorBryan Buckley <bryan.buckley@ti.com>2011-11-29 15:29:53 -0600
committerLeed Aguilar <leed.aguilar@ti.com>2011-12-09 16:06:20 -0500
commit293ac47ddfca3445ba57d07b371b750524214a7a (patch)
treeecad1b51e8617e66773b2092606e82e15b09768d /security
parent335de32e6b4666d383d904b00612231c9f8ff2a7 (diff)
downloadkernel_samsung_espresso10-293ac47ddfca3445ba57d07b371b750524214a7a.zip
kernel_samsung_espresso10-293ac47ddfca3445ba57d07b371b750524214a7a.tar.gz
kernel_samsung_espresso10-293ac47ddfca3445ba57d07b371b750524214a7a.tar.bz2
OMAP: SMC: Fix-up some whitespace
Change-Id: Iead40d07843a876892f17f109619a593e3b53a58 Signed-off-by: Bryan Buckley <bryan.buckley@ti.com>
Diffstat (limited to 'security')
-rw-r--r--security/smc/bridge_pub2sec.S1
-rw-r--r--security/smc/tf_comm_mshield.c5
-rw-r--r--security/smc/tf_conn.c2
-rw-r--r--security/smc/tf_conn.h1
-rw-r--r--security/smc/tf_crypto_aes.c1
-rw-r--r--security/smc/tf_defs.h2
-rw-r--r--security/smc/tf_device.c1
-rw-r--r--security/smc/tf_device_mshield.c4
-rw-r--r--security/smc/tf_teec.c6
9 files changed, 10 insertions, 13 deletions
diff --git a/security/smc/bridge_pub2sec.S b/security/smc/bridge_pub2sec.S
index 05b4c99..1c9df24 100644
--- a/security/smc/bridge_pub2sec.S
+++ b/security/smc/bridge_pub2sec.S
@@ -121,4 +121,3 @@ rpc_handler:
/* Restore registers */
pop {r4-r12, pc}
-
diff --git a/security/smc/tf_comm_mshield.c b/security/smc/tf_comm_mshield.c
index aec5b80..4569343 100644
--- a/security/smc/tf_comm_mshield.c
+++ b/security/smc/tf_comm_mshield.c
@@ -108,7 +108,6 @@ struct tf_ns_pa_info {
void *results;
};
-
#ifdef CONFIG_HAS_WAKELOCK
static struct wake_lock g_tf_wake_lock;
#endif
@@ -690,7 +689,6 @@ int tf_start(struct tf_comm *comm,
workspace_size -= 0x20000;
sdp_bkext_store_addr = workspace_addr + workspace_size;
-
if (test_bit(TF_COMM_FLAG_PA_AVAILABLE, &comm->flags)) {
dpr_err("%s(%p): The SMC PA is already started\n",
__func__, comm);
@@ -713,7 +711,6 @@ int tf_start(struct tf_comm *comm,
goto error1;
}
-
l1_shared_buffer =
(struct tf_l1_shared_buffer *)
internal_get_zeroed_page(GFP_KERNEL);
@@ -749,7 +746,6 @@ int tf_start(struct tf_comm *comm,
dpr_info("%s(%p): Starting PA (%d bytes)...\n",
__func__, comm, pa_size);
-
/*
* Make sure all data is visible to the secure world
*/
@@ -777,6 +773,7 @@ int tf_start(struct tf_comm *comm,
}
iounmap(tmp);
}
+
dmac_flush_range((void *)&pa_info,
(void *)(((u32)&pa_info) + sizeof(struct tf_ns_pa_info)));
outer_clean_range(__pa(&pa_info),
diff --git a/security/smc/tf_conn.c b/security/smc/tf_conn.c
index 943b95c..27ac1a0 100644
--- a/security/smc/tf_conn.c
+++ b/security/smc/tf_conn.c
@@ -1161,6 +1161,7 @@ int tf_invoke_client_command(
for (i = 0; i < 4; i++) {
int param_type = TF_GET_PARAM_TYPE(
command->invoke_client_command.param_types, i);
+
if ((param_type & (TF_PARAM_TYPE_MEMREF_FLAG |
TF_PARAM_TYPE_REGISTERED_MEMREF_FLAG))
== TF_PARAM_TYPE_MEMREF_FLAG) {
@@ -1262,7 +1263,6 @@ error:
if (new_handle != NULL)
ion_free(connection->ion_client, new_handle);
#endif /* CONFIG_TF_ION */
-
/* Unmap de temp mem refs */
for (i = 0; i < 4; i++) {
if (shmem_desc[i] != NULL) {
diff --git a/security/smc/tf_conn.h b/security/smc/tf_conn.h
index 35d2a2b..8bed16f 100644
--- a/security/smc/tf_conn.h
+++ b/security/smc/tf_conn.h
@@ -50,6 +50,7 @@ void tf_unmap_shmem(
struct tf_connection *connection,
struct tf_shmem_desc *shmem_desc,
u32 full_cleanup);
+
/*----------------------------------------------------------------------------
* Connection operations to the Secure World
*----------------------------------------------------------------------------*/
diff --git a/security/smc/tf_crypto_aes.c b/security/smc/tf_crypto_aes.c
index 07c9cdbb..3457e7a 100644
--- a/security/smc/tf_crypto_aes.c
+++ b/security/smc/tf_crypto_aes.c
@@ -881,7 +881,6 @@ static int aes_dma_stop(struct aes_hwa_ctx *ctx)
OUTREG32(&paes_reg->AES_SYSCONFIG, 0);
-
omap_stop_dma(ctx->dma_lch_in);
omap_stop_dma(ctx->dma_lch_out);
diff --git a/security/smc/tf_defs.h b/security/smc/tf_defs.h
index ba9940d..9c28ed0 100644
--- a/security/smc/tf_defs.h
+++ b/security/smc/tf_defs.h
@@ -246,7 +246,6 @@ struct tf_comm {
*/
int se_initialized;
-
/*
* Lock to be held by a client when executing an RPC
*/
@@ -269,7 +268,6 @@ struct tf_comm {
/*----------------------------------------------------------------------------*/
struct tf_device_stats {
-
atomic_t stat_pages_allocated;
atomic_t stat_memories_allocated;
atomic_t stat_pages_locked;
diff --git a/security/smc/tf_device.c b/security/smc/tf_device.c
index fcd09e3..9ee72ec 100644
--- a/security/smc/tf_device.c
+++ b/security/smc/tf_device.c
@@ -198,7 +198,6 @@ static ssize_t info_show(struct tf_device *dev, char *buf)
{
struct tf_device_stats *dev_stats = &dev->stats;
-
return snprintf(buf, PAGE_SIZE,
"stat.memories.allocated: %d\n"
"stat.pages.allocated: %d\n"
diff --git a/security/smc/tf_device_mshield.c b/security/smc/tf_device_mshield.c
index 309e15e..0fa30a9 100644
--- a/security/smc/tf_device_mshield.c
+++ b/security/smc/tf_device_mshield.c
@@ -76,6 +76,7 @@ static int tf_ctrl_check_omap_type(void)
return -EFAULT;
}
}
+
/*----------------------------------------------------------------------------*/
static int tf_ctrl_device_release(struct inode *inode, struct file *file)
@@ -177,7 +178,6 @@ static long tf_ctrl_device_ioctl(struct file *file, unsigned int ioctl_num,
if (descriptor_count > 1) {
dpr_err("%s(%p): configuration file is too long (%d)\n",
__func__, file, descriptor_count);
-
result = -ENOMEM;
goto start_exit;
}
@@ -252,10 +252,10 @@ static int tf_ctrl_device_open(struct inode *inode, struct file *file)
}
file->private_data = connection;
+
/*
* Successful completion.
*/
-
dpr_info("%s(%p): Success\n", __func__, file);
return 0;
diff --git a/security/smc/tf_teec.c b/security/smc/tf_teec.c
index 989ac8a..e06e4fa 100644
--- a/security/smc/tf_teec.c
+++ b/security/smc/tf_teec.c
@@ -81,6 +81,7 @@ TEEC_Result TEEC_encode_error(int err)
{
if (err >= 0)
return S_SUCCESS;
+
switch (err) {
case 0: return TEEC_SUCCESS;
case -EIO: return TEEC_ERROR_GENERIC;
@@ -197,8 +198,10 @@ void TEEC_decode_parameters(union tf_answer_param *params,
TEEC_Operation *operation)
{
unsigned i;
+
if (operation == NULL)
return;
+
for (i = 0; i < 4; i++) {
unsigned ty = TF_GET_PARAM_TYPE(operation->paramTypes, i);
TEEC_Parameter *op = operation->params + i;
@@ -311,6 +314,7 @@ TEEC_Result TEEC_RegisterSharedMemory(TEEC_Context *context,
&answer_message));
if (ret == TEEC_SUCCESS)
ret = ans->error_code;
+
if (ret == S_SUCCESS) {
sharedMem->imp._context = context;
sharedMem->imp._block = ans->block;
@@ -442,6 +446,7 @@ TEEC_Result TEEC_OpenSessionEx(TEEC_Context *context,
if (ret == TEEC_SUCCESS)
ret = ans->error_code;
+
if (ret == S_SUCCESS) {
session->imp._client_session = ans->client_session;
session->imp._context = context;
@@ -608,7 +613,6 @@ void TEEC_RequestCancellation(TEEC_Operation *operation)
schedule();
}
}
-
EXPORT_SYMBOL(TEEC_RequestCancellation);
#endif /* defined(CONFIG_TF_TEEC) */