59742f424eec5b269d5b9c5aadbf4c6455dde301
[openwrt/staging/nbd.git] /
1 From 690744fd6e5714f8e7a7f97578c6d3adad9ec483 Mon Sep 17 00:00:00 2001
2 From: Dave Stevenson <dave.stevenson@raspberrypi.org>
3 Date: Fri, 8 Mar 2019 11:26:00 +0000
4 Subject: [PATCH 376/782] staging: bcm2835_codec: Clean up logging on unloading
5 the driver
6
7 The log line was missing a closing \n, so wasn't added to the
8 log immediately.
9 Adds the function of the V4L2 device that is being unregistered
10 too.
11
12 Signed-off-by: Dave Stevenson <dave.stevenson@raspberrypi.org>
13 ---
14 .../vc04_services/bcm2835-codec/bcm2835-v4l2-codec.c | 10 ++++++++--
15 1 file changed, 8 insertions(+), 2 deletions(-)
16
17 --- a/drivers/staging/vc04_services/bcm2835-codec/bcm2835-v4l2-codec.c
18 +++ b/drivers/staging/vc04_services/bcm2835-codec/bcm2835-v4l2-codec.c
19 @@ -77,6 +77,12 @@ enum bcm2835_codec_role {
20 ISP,
21 };
22
23 +const static char *roles[] = {
24 + "decode",
25 + "encode",
26 + "isp"
27 +};
28 +
29 static const char * const components[] = {
30 "ril.video_decode",
31 "ril.video_encode",
32 @@ -2522,7 +2528,6 @@ static int bcm2835_codec_create(struct p
33 struct video_device *vfd;
34 int video_nr;
35 int ret;
36 - const static char *roles[] = {"decode", "encode", "isp"};
37
38 dev = devm_kzalloc(&pdev->dev, sizeof(*dev), GFP_KERNEL);
39 if (!dev)
40 @@ -2615,7 +2620,8 @@ static int bcm2835_codec_destroy(struct
41 if (!dev)
42 return -ENODEV;
43
44 - v4l2_info(&dev->v4l2_dev, "Removing " MEM2MEM_NAME);
45 + v4l2_info(&dev->v4l2_dev, "Removing " MEM2MEM_NAME ", %s\n",
46 + roles[dev->role]);
47 v4l2_m2m_release(dev->m2m_dev);
48 video_unregister_device(&dev->vfd);
49 v4l2_device_unregister(&dev->v4l2_dev);