diff options
author | Chihau Chau <chihau@gmail.com> | 2010-02-25 16:13:00 -0500 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@suse.de> | 2010-03-04 10:59:01 -0500 |
commit | d4023a5ee2f683f57636346c0baf94cda710055a (patch) | |
tree | eb48adfa319992a5a8cc2a1698ddc68a03eb76f7 | |
parent | 71508ee489e09dc206ea3f62542dd3bd11c0e201 (diff) |
Staging: dream: camera: msm_camera: fix some code style issues
This fixes some code style issues like else staments after the close
braces '}' and to use __func__ instead of __FUNCTION__.
Signed-off-by: Chihau Chau <chihau@gmail.com>
Acked-by: Pavel Machek <pavel@ucw.cz>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
-rw-r--r-- | drivers/staging/dream/camera/msm_camera.c | 37 |
1 files changed, 18 insertions, 19 deletions
diff --git a/drivers/staging/dream/camera/msm_camera.c b/drivers/staging/dream/camera/msm_camera.c index 4f808dc2ca48..925e16c324d2 100644 --- a/drivers/staging/dream/camera/msm_camera.c +++ b/drivers/staging/dream/camera/msm_camera.c | |||
@@ -670,7 +670,7 @@ static int msm_get_stats(struct msm_sync *sync, void __user *arg) | |||
670 | &(stats.fd)); | 670 | &(stats.fd)); |
671 | if (!stats.buffer) { | 671 | if (!stats.buffer) { |
672 | pr_err("%s: msm_pmem_stats_ptov_lookup error\n", | 672 | pr_err("%s: msm_pmem_stats_ptov_lookup error\n", |
673 | __FUNCTION__); | 673 | __func__); |
674 | rc = -EINVAL; | 674 | rc = -EINVAL; |
675 | goto failure; | 675 | goto failure; |
676 | } | 676 | } |
@@ -718,8 +718,7 @@ static int msm_get_stats(struct msm_sync *sync, void __user *arg) | |||
718 | buf.fmain.buffer = | 718 | buf.fmain.buffer = |
719 | (unsigned long)region.vaddr; | 719 | (unsigned long)region.vaddr; |
720 | buf.fmain.fd = region.fd; | 720 | buf.fmain.fd = region.fd; |
721 | } | 721 | } else { |
722 | else { | ||
723 | pr_err("%s: pmem lookup failed\n", | 722 | pr_err("%s: pmem lookup failed\n", |
724 | __func__); | 723 | __func__); |
725 | rc = -EINVAL; | 724 | rc = -EINVAL; |
@@ -838,8 +837,8 @@ static int msm_ctrl_cmd_done(struct msm_control_device *ctrl_pmsm, | |||
838 | kfree(qcmd); | 837 | kfree(qcmd); |
839 | goto end; | 838 | goto end; |
840 | } | 839 | } |
841 | } | 840 | } else |
842 | else ctrlcmd->value = NULL; | 841 | ctrlcmd->value = NULL; |
843 | 842 | ||
844 | end: | 843 | end: |
845 | CDBG("msm_ctrl_cmd_done: end rc = %d\n", rc); | 844 | CDBG("msm_ctrl_cmd_done: end rc = %d\n", rc); |
@@ -876,7 +875,7 @@ static int msm_config_vfe(struct msm_sync *sync, void __user *arg) | |||
876 | MSM_PMEM_AEC_AWB, ®ion[0], | 875 | MSM_PMEM_AEC_AWB, ®ion[0], |
877 | NUM_WB_EXP_STAT_OUTPUT_BUFFERS); | 876 | NUM_WB_EXP_STAT_OUTPUT_BUFFERS); |
878 | if (!axi_data.bufnum1) { | 877 | if (!axi_data.bufnum1) { |
879 | pr_err("%s: pmem region lookup error\n", __FUNCTION__); | 878 | pr_err("%s: pmem region lookup error\n", __func__); |
880 | return -EINVAL; | 879 | return -EINVAL; |
881 | } | 880 | } |
882 | axi_data.region = ®ion[0]; | 881 | axi_data.region = ®ion[0]; |
@@ -888,7 +887,7 @@ static int msm_config_vfe(struct msm_sync *sync, void __user *arg) | |||
888 | MSM_PMEM_AF, ®ion[0], | 887 | MSM_PMEM_AF, ®ion[0], |
889 | NUM_AF_STAT_OUTPUT_BUFFERS); | 888 | NUM_AF_STAT_OUTPUT_BUFFERS); |
890 | if (!axi_data.bufnum1) { | 889 | if (!axi_data.bufnum1) { |
891 | pr_err("%s: pmem region lookup error\n", __FUNCTION__); | 890 | pr_err("%s: pmem region lookup error\n", __func__); |
892 | return -EINVAL; | 891 | return -EINVAL; |
893 | } | 892 | } |
894 | axi_data.region = ®ion[0]; | 893 | axi_data.region = ®ion[0]; |
@@ -899,7 +898,7 @@ static int msm_config_vfe(struct msm_sync *sync, void __user *arg) | |||
899 | break; | 898 | break; |
900 | default: | 899 | default: |
901 | pr_err("%s: unknown command type %d\n", | 900 | pr_err("%s: unknown command type %d\n", |
902 | __FUNCTION__, cfgcmd.cmd_type); | 901 | __func__, cfgcmd.cmd_type); |
903 | return -EINVAL; | 902 | return -EINVAL; |
904 | } | 903 | } |
905 | 904 | ||
@@ -928,7 +927,7 @@ static int msm_frame_axi_cfg(struct msm_sync *sync, | |||
928 | msm_pmem_region_lookup(&sync->frame, pmem_type, | 927 | msm_pmem_region_lookup(&sync->frame, pmem_type, |
929 | ®ion[0], 8); | 928 | ®ion[0], 8); |
930 | if (!axi_data.bufnum1) { | 929 | if (!axi_data.bufnum1) { |
931 | pr_err("%s: pmem region lookup error\n", __FUNCTION__); | 930 | pr_err("%s: pmem region lookup error\n", __func__); |
932 | return -EINVAL; | 931 | return -EINVAL; |
933 | } | 932 | } |
934 | break; | 933 | break; |
@@ -939,7 +938,7 @@ static int msm_frame_axi_cfg(struct msm_sync *sync, | |||
939 | msm_pmem_region_lookup(&sync->frame, pmem_type, | 938 | msm_pmem_region_lookup(&sync->frame, pmem_type, |
940 | ®ion[0], 8); | 939 | ®ion[0], 8); |
941 | if (!axi_data.bufnum2) { | 940 | if (!axi_data.bufnum2) { |
942 | pr_err("%s: pmem region lookup error\n", __FUNCTION__); | 941 | pr_err("%s: pmem region lookup error\n", __func__); |
943 | return -EINVAL; | 942 | return -EINVAL; |
944 | } | 943 | } |
945 | break; | 944 | break; |
@@ -950,7 +949,7 @@ static int msm_frame_axi_cfg(struct msm_sync *sync, | |||
950 | msm_pmem_region_lookup(&sync->frame, pmem_type, | 949 | msm_pmem_region_lookup(&sync->frame, pmem_type, |
951 | ®ion[0], 8); | 950 | ®ion[0], 8); |
952 | if (!axi_data.bufnum1) { | 951 | if (!axi_data.bufnum1) { |
953 | pr_err("%s: pmem region lookup error\n", __FUNCTION__); | 952 | pr_err("%s: pmem region lookup error\n", __func__); |
954 | return -EINVAL; | 953 | return -EINVAL; |
955 | } | 954 | } |
956 | 955 | ||
@@ -959,7 +958,7 @@ static int msm_frame_axi_cfg(struct msm_sync *sync, | |||
959 | msm_pmem_region_lookup(&sync->frame, pmem_type, | 958 | msm_pmem_region_lookup(&sync->frame, pmem_type, |
960 | ®ion[axi_data.bufnum1], 8); | 959 | ®ion[axi_data.bufnum1], 8); |
961 | if (!axi_data.bufnum2) { | 960 | if (!axi_data.bufnum2) { |
962 | pr_err("%s: pmem region lookup error\n", __FUNCTION__); | 961 | pr_err("%s: pmem region lookup error\n", __func__); |
963 | return -EINVAL; | 962 | return -EINVAL; |
964 | } | 963 | } |
965 | break; | 964 | break; |
@@ -970,7 +969,7 @@ static int msm_frame_axi_cfg(struct msm_sync *sync, | |||
970 | msm_pmem_region_lookup(&sync->frame, pmem_type, | 969 | msm_pmem_region_lookup(&sync->frame, pmem_type, |
971 | ®ion[0], 8); | 970 | ®ion[0], 8); |
972 | if (!axi_data.bufnum2) { | 971 | if (!axi_data.bufnum2) { |
973 | pr_err("%s: pmem region lookup error\n", __FUNCTION__); | 972 | pr_err("%s: pmem region lookup error\n", __func__); |
974 | return -EINVAL; | 973 | return -EINVAL; |
975 | } | 974 | } |
976 | break; | 975 | break; |
@@ -981,7 +980,7 @@ static int msm_frame_axi_cfg(struct msm_sync *sync, | |||
981 | 980 | ||
982 | default: | 981 | default: |
983 | pr_err("%s: unknown command type %d\n", | 982 | pr_err("%s: unknown command type %d\n", |
984 | __FUNCTION__, cfgcmd->cmd_type); | 983 | __func__, cfgcmd->cmd_type); |
985 | return -EINVAL; | 984 | return -EINVAL; |
986 | } | 985 | } |
987 | 986 | ||
@@ -1047,7 +1046,7 @@ static int __msm_put_frame_buf(struct msm_sync *sync, | |||
1047 | rc = sync->vfefn.vfe_config(&cfgcmd, &pphy); | 1046 | rc = sync->vfefn.vfe_config(&cfgcmd, &pphy); |
1048 | } else { | 1047 | } else { |
1049 | pr_err("%s: msm_pmem_frame_vtop_lookup failed\n", | 1048 | pr_err("%s: msm_pmem_frame_vtop_lookup failed\n", |
1050 | __FUNCTION__); | 1049 | __func__); |
1051 | rc = -EINVAL; | 1050 | rc = -EINVAL; |
1052 | } | 1051 | } |
1053 | 1052 | ||
@@ -1131,7 +1130,7 @@ static int msm_stats_axi_cfg(struct msm_sync *sync, | |||
1131 | break; | 1130 | break; |
1132 | default: | 1131 | default: |
1133 | pr_err("%s: unknown command type %d\n", | 1132 | pr_err("%s: unknown command type %d\n", |
1134 | __FUNCTION__, cfgcmd->cmd_type); | 1133 | __func__, cfgcmd->cmd_type); |
1135 | return -EINVAL; | 1134 | return -EINVAL; |
1136 | } | 1135 | } |
1137 | 1136 | ||
@@ -1140,7 +1139,7 @@ static int msm_stats_axi_cfg(struct msm_sync *sync, | |||
1140 | msm_pmem_region_lookup(&sync->stats, pmem_type, | 1139 | msm_pmem_region_lookup(&sync->stats, pmem_type, |
1141 | ®ion[0], NUM_WB_EXP_STAT_OUTPUT_BUFFERS); | 1140 | ®ion[0], NUM_WB_EXP_STAT_OUTPUT_BUFFERS); |
1142 | if (!axi_data.bufnum1) { | 1141 | if (!axi_data.bufnum1) { |
1143 | pr_err("%s: pmem region lookup error\n", __FUNCTION__); | 1142 | pr_err("%s: pmem region lookup error\n", __func__); |
1144 | return -EINVAL; | 1143 | return -EINVAL; |
1145 | } | 1144 | } |
1146 | axi_data.region = ®ion[0]; | 1145 | axi_data.region = ®ion[0]; |
@@ -1177,7 +1176,7 @@ static int msm_put_stats_buffer(struct msm_sync *sync, void __user *arg) | |||
1177 | cfgcmd.cmd_type = CMD_STATS_AF_BUF_RELEASE; | 1176 | cfgcmd.cmd_type = CMD_STATS_AF_BUF_RELEASE; |
1178 | else { | 1177 | else { |
1179 | pr_err("%s: invalid buf type %d\n", | 1178 | pr_err("%s: invalid buf type %d\n", |
1180 | __FUNCTION__, | 1179 | __func__, |
1181 | buf.type); | 1180 | buf.type); |
1182 | rc = -EINVAL; | 1181 | rc = -EINVAL; |
1183 | goto put_done; | 1182 | goto put_done; |
@@ -1223,7 +1222,7 @@ static int msm_axi_config(struct msm_sync *sync, void __user *arg) | |||
1223 | 1222 | ||
1224 | default: | 1223 | default: |
1225 | pr_err("%s: unknown command type %d\n", | 1224 | pr_err("%s: unknown command type %d\n", |
1226 | __FUNCTION__, | 1225 | __func__, |
1227 | cfgcmd.cmd_type); | 1226 | cfgcmd.cmd_type); |
1228 | return -EINVAL; | 1227 | return -EINVAL; |
1229 | } | 1228 | } |