Commit f551e2fd authored by Tanner Love's avatar Tanner Love Committed by David S. Miller

selftests/net: update initializer syntax to use c99 designators

Before, clang version 9 threw errors such as: error:
use of GNU old-style field designator extension [-Werror,-Wgnu-designator]
                { tstamp: true, swtstamp: true }
                  ^~~~~~~
                  .tstamp =
Fix these warnings in tools/testing/selftests/net in the same manner as
commit 121e357a ("selftests/harness: Update named initializer syntax").
N.B. rxtimestamp.c is the only affected file in the directory.
Signed-off-by: default avatarTanner Love <tannerlove@google.com>
Acked-by: default avatarWillem de Bruijn <willemb@google.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 565f499c
......@@ -68,44 +68,44 @@ static struct socket_type socket_types[] = {
static struct test_case test_cases[] = {
{ {}, {} },
{
{ so_timestamp: 1 },
{ tstamp: true }
{ .so_timestamp = 1 },
{ .tstamp = true }
},
{
{ so_timestampns: 1 },
{ tstampns: true }
{ .so_timestampns = 1 },
{ .tstampns = true }
},
{
{ so_timestamp: 1, so_timestampns: 1 },
{ tstampns: true }
{ .so_timestamp = 1, .so_timestampns = 1 },
{ .tstampns = true }
},
{
{ so_timestamping: SOF_TIMESTAMPING_RX_SOFTWARE },
{ .so_timestamping = SOF_TIMESTAMPING_RX_SOFTWARE },
{}
},
{
/* Loopback device does not support hw timestamps. */
{ so_timestamping: SOF_TIMESTAMPING_RX_HARDWARE },
{ .so_timestamping = SOF_TIMESTAMPING_RX_HARDWARE },
{}
},
{
{ so_timestamping: SOF_TIMESTAMPING_SOFTWARE },
warn_on_fail : true
{ .so_timestamping = SOF_TIMESTAMPING_SOFTWARE },
.warn_on_fail = true
},
{
{ so_timestamping: SOF_TIMESTAMPING_RX_SOFTWARE
{ .so_timestamping = SOF_TIMESTAMPING_RX_SOFTWARE
| SOF_TIMESTAMPING_RX_HARDWARE },
{}
},
{
{ so_timestamping: SOF_TIMESTAMPING_SOFTWARE
{ .so_timestamping = SOF_TIMESTAMPING_SOFTWARE
| SOF_TIMESTAMPING_RX_SOFTWARE },
{ swtstamp: true }
{ .swtstamp = true }
},
{
{ so_timestamp: 1, so_timestamping: SOF_TIMESTAMPING_SOFTWARE
{ .so_timestamp = 1, .so_timestamping = SOF_TIMESTAMPING_SOFTWARE
| SOF_TIMESTAMPING_RX_SOFTWARE },
{ tstamp: true, swtstamp: true }
{ .tstamp = true, .swtstamp = true }
},
};
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment