[PATCH 1/1] media: Fix a compiler warning in media_entity_pipeline_start()

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

 



Patch "[media] media: Print information on failed link validation" cause a
harmless compiler warning in printing a debug message. Fix this.

The type casting is done do ensure the type really is suitable for printing
as %u, as find_first_zero_bit() does return int on some architectures and
unsigned long on others.

Signed-off-by: Sakari Ailus <sakari.ailus@xxxxxx>
---
 drivers/media/media-entity.c |    3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/drivers/media/media-entity.c b/drivers/media/media-entity.c
index 4122d7f..4d8e01c 100644
--- a/drivers/media/media-entity.c
+++ b/drivers/media/media-entity.c
@@ -297,7 +297,8 @@ __must_check int media_entity_pipeline_start(struct media_entity *entity,
 			dev_dbg(entity->parent->dev,
 				"\"%s\":%u must be connected by an enabled link\n",
 				entity->name,
-				find_first_zero_bit(active, entity->num_pads));
+				(unsigned)find_first_zero_bit(
+					active, entity->num_pads));
 			goto error;
 		}
 	}
-- 
1.7.10.4

--
To unsubscribe from this list: send the line "unsubscribe linux-media" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[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