Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1706371 > unrolled thread
| Started by | Julia Lawall <Julia.Lawall@lip6.fr> |
|---|---|
| First post | 2017-08-08 13:30 +0200 |
| Last post | 2017-08-08 14:40 +0200 |
| Articles | 2 — 2 participants |
Back to article view | Back to linux.kernel
This discussion starts older than the indexed window; earlier articles aren't shown. The article labeled Started by
below is the oldest one visible, not the original post.
[PATCH 5/6] [media] exynos4-is: constify video_subdev structures Julia Lawall <Julia.Lawall@lip6.fr> - 2017-08-08 13:30 +0200
Re: [PATCH 5/6] [media] exynos4-is: constify video_subdev structures Sylwester Nawrocki <s.nawrocki@samsung.com> - 2017-08-08 14:40 +0200
| From | Julia Lawall <Julia.Lawall@lip6.fr> |
|---|---|
| Date | 2017-08-08 13:30 +0200 |
| Subject | [PATCH 5/6] [media] exynos4-is: constify video_subdev structures |
| Message-ID | <ucaRX-7FO-7@gated-at.bofh.it> |
The v4l2_subdev_ops structures are only passed as the second
argument of v4l2_subdev_init, which is const, so the
v4l2_subdev_ops structures can be const as well.
Done with the help of Coccinelle.
Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr>
---
drivers/media/platform/exynos4-is/fimc-isp.c | 2 +-
drivers/media/platform/exynos4-is/fimc-lite.c | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/media/platform/exynos4-is/fimc-isp.c b/drivers/media/platform/exynos4-is/fimc-isp.c
index 8efe916..fd793d3 100644
--- a/drivers/media/platform/exynos4-is/fimc-isp.c
+++ b/drivers/media/platform/exynos4-is/fimc-isp.c
@@ -433,7 +433,7 @@ static void fimc_isp_subdev_unregistered(struct v4l2_subdev *sd)
.s_power = fimc_isp_subdev_s_power,
};
-static struct v4l2_subdev_ops fimc_is_subdev_ops = {
+static const struct v4l2_subdev_ops fimc_is_subdev_ops = {
.core = &fimc_is_core_ops,
.video = &fimc_is_subdev_video_ops,
.pad = &fimc_is_subdev_pad_ops,
diff --git a/drivers/media/platform/exynos4-is/fimc-lite.c b/drivers/media/platform/exynos4-is/fimc-lite.c
index 7d3ec5c..30282c5 100644
--- a/drivers/media/platform/exynos4-is/fimc-lite.c
+++ b/drivers/media/platform/exynos4-is/fimc-lite.c
@@ -1361,7 +1361,7 @@ static void fimc_lite_subdev_unregistered(struct v4l2_subdev *sd)
.log_status = fimc_lite_log_status,
};
-static struct v4l2_subdev_ops fimc_lite_subdev_ops = {
+static const struct v4l2_subdev_ops fimc_lite_subdev_ops = {
.core = &fimc_lite_core_ops,
.video = &fimc_lite_subdev_video_ops,
.pad = &fimc_lite_subdev_pad_ops,
[toc] | [next] | [standalone]
| From | Sylwester Nawrocki <s.nawrocki@samsung.com> |
|---|---|
| Date | 2017-08-08 14:40 +0200 |
| Subject | Re: [PATCH 5/6] [media] exynos4-is: constify video_subdev structures |
| Message-ID | <ucbXJ-8or-31@gated-at.bofh.it> |
| In reply to | #1706371 |
On 08/08/2017 12:58 PM, Julia Lawall wrote: > The v4l2_subdev_ops structures are only passed as the second > argument of v4l2_subdev_init, which is const, so the > v4l2_subdev_ops structures can be const as well. > > Done with the help of Coccinelle. > > Signed-off-by: Julia Lawall<Julia.Lawall@lip6.fr> Reviewed-by: Sylwester Nawrocki <s.nawrocki@samsung.com>
[toc] | [prev] | [standalone]
Back to top | Article view | linux.kernel
csiph-web