You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
61 lines
2.0 KiB
61 lines
2.0 KiB
6 years ago
|
From 1ff6cbebfb5ce6a9509eb29d5f98d6b8710c021d Mon Sep 17 00:00:00 2001
|
||
|
From: Genki Sky <sky@genki.is>
|
||
|
Date: Tue, 5 Dec 2017 19:09:54 -0500
|
||
|
Subject: [PATCH 387/454] staging: vc04_services: Join multiline dereferences
|
||
|
|
||
|
commit 7260ea5fc327344974716e5109180f96f0483a85 upstream
|
||
|
|
||
|
This was found using checkpatch.pl's MULTILINE_DEREFERENCE warning.
|
||
|
Putting the dereference onto one line makes them easier to read,
|
||
|
especially when part of a larger expression (in this case, function
|
||
|
arguments and ternary operator), and when the dereferences are short
|
||
|
(as they are here).
|
||
|
|
||
|
Signed-off-by: Genki Sky <sky@genki.is>
|
||
|
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
|
||
|
---
|
||
|
.../bcm2835-camera/bcm2835-camera.c | 16 ++++++----------
|
||
|
1 file changed, 6 insertions(+), 10 deletions(-)
|
||
|
|
||
|
--- a/drivers/staging/vc04_services/bcm2835-camera/bcm2835-camera.c
|
||
|
+++ b/drivers/staging/vc04_services/bcm2835-camera/bcm2835-camera.c
|
||
|
@@ -356,11 +356,9 @@ static void buffer_cb(struct vchiq_mmal_
|
||
|
pr_debug("Grab another frame");
|
||
|
vchiq_mmal_port_parameter_set(
|
||
|
instance,
|
||
|
- dev->capture.
|
||
|
- camera_port,
|
||
|
+ dev->capture.camera_port,
|
||
|
MMAL_PARAMETER_CAPTURE,
|
||
|
- &dev->capture.
|
||
|
- frame_count,
|
||
|
+ &dev->capture.frame_count,
|
||
|
sizeof(dev->capture.frame_count));
|
||
|
}
|
||
|
} else {
|
||
|
@@ -419,11 +417,9 @@ static void buffer_cb(struct vchiq_mmal_
|
||
|
"Grab another frame as buffer has EOS");
|
||
|
vchiq_mmal_port_parameter_set(
|
||
|
instance,
|
||
|
- dev->capture.
|
||
|
- camera_port,
|
||
|
+ dev->capture.camera_port,
|
||
|
MMAL_PARAMETER_CAPTURE,
|
||
|
- &dev->capture.
|
||
|
- frame_count,
|
||
|
+ &dev->capture.frame_count,
|
||
|
sizeof(dev->capture.frame_count));
|
||
|
}
|
||
|
} else {
|
||
|
@@ -1268,8 +1264,8 @@ static int mmal_setup_components(struct
|
||
|
port->current_buffer.size =
|
||
|
(f->fmt.pix.sizeimage <
|
||
|
(100 << 10))
|
||
|
- ? (100 << 10) : f->fmt.pix.
|
||
|
- sizeimage;
|
||
|
+ ? (100 << 10)
|
||
|
+ : f->fmt.pix.sizeimage;
|
||
|
}
|
||
|
v4l2_dbg(1, bcm2835_v4l2_debug,
|
||
|
&dev->v4l2_dev,
|