@@ -54,7 +54,7 @@ MODULE_LICENSE("GPL");
5454/**************** DCB attribute policies *************************************/
5555
5656/* DCB netlink attributes policy */
57- static struct nla_policy dcbnl_rtnl_policy [DCB_ATTR_MAX + 1 ] = {
57+ static const struct nla_policy dcbnl_rtnl_policy [DCB_ATTR_MAX + 1 ] = {
5858 [DCB_ATTR_IFNAME ] = {.type = NLA_NUL_STRING , .len = IFNAMSIZ - 1 },
5959 [DCB_ATTR_STATE ] = {.type = NLA_U8 },
6060 [DCB_ATTR_PFC_CFG ] = {.type = NLA_NESTED },
@@ -68,7 +68,7 @@ static struct nla_policy dcbnl_rtnl_policy[DCB_ATTR_MAX + 1] = {
6868};
6969
7070/* DCB priority flow control to User Priority nested attributes */
71- static struct nla_policy dcbnl_pfc_up_nest [DCB_PFC_UP_ATTR_MAX + 1 ] = {
71+ static const struct nla_policy dcbnl_pfc_up_nest [DCB_PFC_UP_ATTR_MAX + 1 ] = {
7272 [DCB_PFC_UP_ATTR_0 ] = {.type = NLA_U8 },
7373 [DCB_PFC_UP_ATTR_1 ] = {.type = NLA_U8 },
7474 [DCB_PFC_UP_ATTR_2 ] = {.type = NLA_U8 },
@@ -81,7 +81,7 @@ static struct nla_policy dcbnl_pfc_up_nest[DCB_PFC_UP_ATTR_MAX + 1] = {
8181};
8282
8383/* DCB priority grouping nested attributes */
84- static struct nla_policy dcbnl_pg_nest [DCB_PG_ATTR_MAX + 1 ] = {
84+ static const struct nla_policy dcbnl_pg_nest [DCB_PG_ATTR_MAX + 1 ] = {
8585 [DCB_PG_ATTR_TC_0 ] = {.type = NLA_NESTED },
8686 [DCB_PG_ATTR_TC_1 ] = {.type = NLA_NESTED },
8787 [DCB_PG_ATTR_TC_2 ] = {.type = NLA_NESTED },
@@ -103,7 +103,7 @@ static struct nla_policy dcbnl_pg_nest[DCB_PG_ATTR_MAX + 1] = {
103103};
104104
105105/* DCB traffic class nested attributes. */
106- static struct nla_policy dcbnl_tc_param_nest [DCB_TC_ATTR_PARAM_MAX + 1 ] = {
106+ static const struct nla_policy dcbnl_tc_param_nest [DCB_TC_ATTR_PARAM_MAX + 1 ] = {
107107 [DCB_TC_ATTR_PARAM_PGID ] = {.type = NLA_U8 },
108108 [DCB_TC_ATTR_PARAM_UP_MAPPING ] = {.type = NLA_U8 },
109109 [DCB_TC_ATTR_PARAM_STRICT_PRIO ] = {.type = NLA_U8 },
@@ -112,7 +112,7 @@ static struct nla_policy dcbnl_tc_param_nest[DCB_TC_ATTR_PARAM_MAX + 1] = {
112112};
113113
114114/* DCB capabilities nested attributes. */
115- static struct nla_policy dcbnl_cap_nest [DCB_CAP_ATTR_MAX + 1 ] = {
115+ static const struct nla_policy dcbnl_cap_nest [DCB_CAP_ATTR_MAX + 1 ] = {
116116 [DCB_CAP_ATTR_ALL ] = {.type = NLA_FLAG },
117117 [DCB_CAP_ATTR_PG ] = {.type = NLA_U8 },
118118 [DCB_CAP_ATTR_PFC ] = {.type = NLA_U8 },
@@ -124,14 +124,14 @@ static struct nla_policy dcbnl_cap_nest[DCB_CAP_ATTR_MAX + 1] = {
124124};
125125
126126/* DCB capabilities nested attributes. */
127- static struct nla_policy dcbnl_numtcs_nest [DCB_NUMTCS_ATTR_MAX + 1 ] = {
127+ static const struct nla_policy dcbnl_numtcs_nest [DCB_NUMTCS_ATTR_MAX + 1 ] = {
128128 [DCB_NUMTCS_ATTR_ALL ] = {.type = NLA_FLAG },
129129 [DCB_NUMTCS_ATTR_PG ] = {.type = NLA_U8 },
130130 [DCB_NUMTCS_ATTR_PFC ] = {.type = NLA_U8 },
131131};
132132
133133/* DCB BCN nested attributes. */
134- static struct nla_policy dcbnl_bcn_nest [DCB_BCN_ATTR_MAX + 1 ] = {
134+ static const struct nla_policy dcbnl_bcn_nest [DCB_BCN_ATTR_MAX + 1 ] = {
135135 [DCB_BCN_ATTR_RP_0 ] = {.type = NLA_U8 },
136136 [DCB_BCN_ATTR_RP_1 ] = {.type = NLA_U8 },
137137 [DCB_BCN_ATTR_RP_2 ] = {.type = NLA_U8 },
@@ -160,7 +160,7 @@ static struct nla_policy dcbnl_bcn_nest[DCB_BCN_ATTR_MAX + 1] = {
160160};
161161
162162/* DCB APP nested attributes. */
163- static struct nla_policy dcbnl_app_nest [DCB_APP_ATTR_MAX + 1 ] = {
163+ static const struct nla_policy dcbnl_app_nest [DCB_APP_ATTR_MAX + 1 ] = {
164164 [DCB_APP_ATTR_IDTYPE ] = {.type = NLA_U8 },
165165 [DCB_APP_ATTR_ID ] = {.type = NLA_U16 },
166166 [DCB_APP_ATTR_PRIORITY ] = {.type = NLA_U8 },
0 commit comments