[PATCH] media: atomisp: pci: sh_css: Replace macro STATS_ENABLED() with function

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Replace the macro STATS_ENABLED() with a static function to conform to
Linux coding style standards.

Signed-off-by: Brent Pappas <bpappas@xxxxxxxxxxxxxxx>
---
 drivers/staging/media/atomisp/pci/sh_css.c | 10 +++++++---
 1 file changed, 7 insertions(+), 3 deletions(-)

diff --git a/drivers/staging/media/atomisp/pci/sh_css.c b/drivers/staging/media/atomisp/pci/sh_css.c
index 726cb7aa4ecd..753b3e0fcb07 100644
--- a/drivers/staging/media/atomisp/pci/sh_css.c
+++ b/drivers/staging/media/atomisp/pci/sh_css.c
@@ -97,8 +97,12 @@
  */
 #define JPEG_BYTES (16 * 1024 * 1024)
 
-#define STATS_ENABLED(stage) (stage && stage->binary && stage->binary->info && \
-	(stage->binary->info->sp.enable.s3a || stage->binary->info->sp.enable.dis))
+static bool stats_enabled(struct ia_css_pipeline_stage *stage)
+{
+	return stage && stage->binary && stage->binary->info &&
+	       (stage->binary->info->sp.enable.s3a ||
+		stage->binary->info->sp.enable.dis);
+}
 
 struct sh_css my_css;
 
@@ -3743,7 +3747,7 @@ ia_css_pipe_enqueue_buffer(struct ia_css_pipe *pipe,
 			 * The SP will read the params after it got
 			 * empty 3a and dis
 			 */
-			if (STATS_ENABLED(stage)) {
+			if (stats_enabled(stage)) {
 				/* there is a stage that needs it */
 				return_err = ia_css_bufq_enqueue_buffer(thread_id,
 									queue_id,
-- 
2.34.1




[Index of Archives]     [Linux Input]     [Video for Linux]     [Gstreamer Embedded]     [Mplayer Users]     [Linux USB Devel]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Yosemite Backpacking]

  Powered by Linux