[media] pvrusb2: Stop statically initializing reserved struct fields to zero
authorMike Isely <isely@pobox.com>
Mon, 20 Feb 2012 05:03:39 +0000 (02:03 -0300)
committerMauro Carvalho Chehab <mchehab@redhat.com>
Mon, 7 May 2012 19:48:19 +0000 (16:48 -0300)
In any statically initialized data structure, the compiler is going to
zero any part which is not already explicitly initialized.  While we
can take that knowledge overboard and simply avoid initializing
anything that needs to be zero, it's at least a good idea not to
bother zeroing parts that we don't otherwise care about - like
"reserved" fields which may change in the future.  Avoiding
initialization of those fields now also avoids possible conflict down
the road.

Signed-off-by: Mike Isely <isely@pobox.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
drivers/media/video/pvrusb2/pvrusb2-v4l2.c

index e1111d968a3d41e942f3cd0eae556282c144b586..5e462faa2726a875e1b3367007ab0631f4c96ee8 100644 (file)
@@ -107,7 +107,6 @@ static struct v4l2_fmtdesc pvr_fmtdesc [] = {
                // This should really be V4L2_PIX_FMT_MPEG, but xawtv
                // breaks when I do that.
                .pixelformat    = 0, // V4L2_PIX_FMT_MPEG,
-               .reserved       = { 0, 0, 0, 0 }
        }
 };
 
@@ -145,7 +144,6 @@ static struct v4l2_format pvr_format [] = {
                                .start = { 0, 0 },
                                .count = { 0, 0 },
                                .flags = 0,
-                               .reserved = { 0, 0 }
                        }
                }
        }