Print this page
7127  remove -Wno-missing-braces from Makefile.uts

Split Close
Expand all
Collapse all
          --- old/usr/src/uts/common/inet/ip/icmp.c
          +++ new/usr/src/uts/common/inet/ip/icmp.c
↓ open down ↓ 232 lines elided ↑ open up ↑
 233  233  /*
 234  234   * All of these are alterable, within the min/max values given, at run time.
 235  235   *
 236  236   * Note: All those tunables which do not start with "icmp_" are Committed and
 237  237   * therefore are public. See PSARC 2010/080.
 238  238   */
 239  239  static mod_prop_info_t icmp_propinfo_tbl[] = {
 240  240          /* tunable - 0 */
 241  241          { "_wroff_extra", MOD_PROTO_RAWIP,
 242  242              mod_set_uint32, mod_get_uint32,
 243      -            {0, 128, 32}, {32} },
      243 +            {{0, 128, 32}}, {32} },
 244  244  
 245  245          { "_ipv4_ttl", MOD_PROTO_RAWIP,
 246  246              mod_set_uint32, mod_get_uint32,
 247      -            {1, 255, 255}, {255} },
      247 +            {{1, 255, 255}}, {255} },
 248  248  
 249  249          { "_ipv6_hoplimit", MOD_PROTO_RAWIP,
 250  250              mod_set_uint32, mod_get_uint32,
 251      -            {0, IPV6_MAX_HOPS, IPV6_DEFAULT_HOPS},
      251 +            {{0, IPV6_MAX_HOPS, IPV6_DEFAULT_HOPS}},
 252  252              {IPV6_DEFAULT_HOPS} },
 253  253  
 254  254          { "_bsd_compat", MOD_PROTO_RAWIP,
 255  255              mod_set_boolean, mod_get_boolean,
 256      -            {B_TRUE}, {B_TRUE} },
      256 +            {.mpi_bval = B_TRUE}, {B_TRUE} },
 257  257  
 258  258          { "send_buf", MOD_PROTO_RAWIP,
 259  259              icmp_set_buf_prop, icmp_get_buf_prop,
 260      -            {4096, 65536, 8192}, {8192} },
      260 +            {{4096, 65536, 8192}}, {8192} },
 261  261  
 262  262          { "_xmit_lowat", MOD_PROTO_RAWIP,
 263  263              mod_set_uint32, mod_get_uint32,
 264      -            {0, 65536, 1024}, {1024} },
      264 +            {{0, 65536, 1024}}, {1024} },
 265  265  
 266  266          { "recv_buf", MOD_PROTO_RAWIP,
 267  267              icmp_set_buf_prop, icmp_get_buf_prop,
 268      -            {4096, 65536, 8192}, {8192} },
      268 +            {{4096, 65536, 8192}}, {8192} },
 269  269  
 270  270          { "max_buf", MOD_PROTO_RAWIP,
 271  271              mod_set_uint32, mod_get_uint32,
 272      -            {65536, ULP_MAX_BUF, 256*1024}, {256*1024} },
      272 +            {{65536, ULP_MAX_BUF, 256*1024}}, {256*1024} },
 273  273  
 274  274          { "_pmtu_discovery", MOD_PROTO_RAWIP,
 275  275              mod_set_boolean, mod_get_boolean,
 276      -            {B_FALSE}, {B_FALSE} },
      276 +            {.mpi_bval = B_FALSE}, {B_FALSE} },
 277  277  
 278  278          { "_sendto_ignerr", MOD_PROTO_RAWIP,
 279  279              mod_set_boolean, mod_get_boolean,
 280      -            {B_FALSE}, {B_FALSE} },
      280 +            {.mpi_bval = B_FALSE}, {B_FALSE} },
 281  281  
 282      -        { "?", MOD_PROTO_RAWIP, NULL, mod_get_allprop, {0}, {0} },
      282 +        { "?", MOD_PROTO_RAWIP, NULL, mod_get_allprop, {{0}}, {0} },
 283  283  
 284      -        { NULL, 0, NULL, NULL, {0}, {0} }
      284 +        { NULL, 0, NULL, NULL, {{0}}, {0} }
 285  285  };
 286  286  
 287  287  #define is_wroff_extra                  is_propinfo_tbl[0].prop_cur_uval
 288  288  #define is_ipv4_ttl                     is_propinfo_tbl[1].prop_cur_uval
 289  289  #define is_ipv6_hoplimit                is_propinfo_tbl[2].prop_cur_uval
 290  290  #define is_bsd_compat                   is_propinfo_tbl[3].prop_cur_bval
 291  291  #define is_xmit_hiwat                   is_propinfo_tbl[4].prop_cur_uval
 292  292  #define is_xmit_lowat                   is_propinfo_tbl[5].prop_cur_uval
 293  293  #define is_recv_hiwat                   is_propinfo_tbl[6].prop_cur_uval
 294  294  #define is_max_buf                      is_propinfo_tbl[7].prop_cur_uval
↓ open down ↓ 4729 lines elided ↑ open up ↑
5024 5024          is->is_ksp = NULL;
5025 5025          ldi_ident_release(is->is_ldi_ident);
5026 5026          kmem_free(is, sizeof (*is));
5027 5027  }
5028 5028  
5029 5029  static void *
5030 5030  rawip_kstat_init(netstackid_t stackid) {
5031 5031          kstat_t *ksp;
5032 5032  
5033 5033          rawip_named_kstat_t template = {
5034      -                { "inDatagrams",        KSTAT_DATA_UINT32, 0 },
5035      -                { "inCksumErrs",        KSTAT_DATA_UINT32, 0 },
5036      -                { "inErrors",           KSTAT_DATA_UINT32, 0 },
5037      -                { "outDatagrams",       KSTAT_DATA_UINT32, 0 },
5038      -                { "outErrors",          KSTAT_DATA_UINT32, 0 },
     5034 +                { "inDatagrams",        KSTAT_DATA_UINT32, {{0}} },
     5035 +                { "inCksumErrs",        KSTAT_DATA_UINT32, {{0}} },
     5036 +                { "inErrors",           KSTAT_DATA_UINT32, {{0}} },
     5037 +                { "outDatagrams",       KSTAT_DATA_UINT32, {{0}} },
     5038 +                { "outErrors",          KSTAT_DATA_UINT32, {{0}} },
5039 5039          };
5040 5040  
5041 5041          ksp = kstat_create_netstack("icmp", 0, "rawip", "mib2",
5042 5042                                          KSTAT_TYPE_NAMED,
5043 5043                                          NUM_OF_FIELDS(rawip_named_kstat_t),
5044 5044                                          0, stackid);
5045 5045          if (ksp == NULL || ksp->ks_data == NULL)
5046 5046                  return (NULL);
5047 5047  
5048 5048          bcopy(&template, ksp->ks_data, sizeof (template));
↓ open down ↓ 812 lines elided ↑ open up ↑
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX