@@ -403,17 +403,17 @@ static bool dcb_app_is_port(const struct dcb_app *app)
return app->selector == IEEE_8021QAZ_APP_SEL_ANY;
}
-static int dcb_app_print_key_dec(__u16 protocol)
+static int dcb_app_print_pid_dec(__u16 protocol)
{
return print_uint(PRINT_ANY, NULL, "%u", protocol);
}
-static int dcb_app_print_key_hex(__u16 protocol)
+static int dcb_app_print_pid_hex(__u16 protocol)
{
return print_uint(PRINT_ANY, NULL, "%x", protocol);
}
-static int dcb_app_print_key_dscp(__u16 protocol)
+static int dcb_app_print_pid_dscp(__u16 protocol)
{
const char *name = rtnl_dsfield_get_name(protocol << 2);
@@ -423,7 +423,7 @@ static int dcb_app_print_key_dscp(__u16 protocol)
return print_uint(PRINT_ANY, NULL, "%u", protocol);
}
-static int dcb_app_print_key_pcp(__u16 protocol)
+static int dcb_app_print_pid_pcp(__u16 protocol)
{
/* Print in numerical form, if protocol value is out-of-range */
if (protocol > DCB_APP_PCP_MAX)
@@ -466,7 +466,7 @@ static void dcb_app_print_filtered(const struct dcb_app_table *tab,
static void dcb_app_print_ethtype_prio(const struct dcb_app_table *tab)
{
- dcb_app_print_filtered(tab, dcb_app_is_ethtype, dcb_app_print_key_hex,
+ dcb_app_print_filtered(tab, dcb_app_is_ethtype, dcb_app_print_pid_hex,
"ethtype_prio", "ethtype-prio");
}
@@ -474,8 +474,8 @@ static void dcb_app_print_pcp_prio(const struct dcb *dcb,
const struct dcb_app_table *tab)
{
dcb_app_print_filtered(tab, dcb_app_is_pcp,
- dcb->numeric ? dcb_app_print_key_dec
- : dcb_app_print_key_pcp,
+ dcb->numeric ? dcb_app_print_pid_dec
+ : dcb_app_print_pid_pcp,
"pcp_prio", "pcp-prio");
}
@@ -483,26 +483,26 @@ static void dcb_app_print_dscp_prio(const struct dcb *dcb,
const struct dcb_app_table *tab)
{
dcb_app_print_filtered(tab, dcb_app_is_dscp,
- dcb->numeric ? dcb_app_print_key_dec
- : dcb_app_print_key_dscp,
+ dcb->numeric ? dcb_app_print_pid_dec
+ : dcb_app_print_pid_dscp,
"dscp_prio", "dscp-prio");
}
static void dcb_app_print_stream_port_prio(const struct dcb_app_table *tab)
{
- dcb_app_print_filtered(tab, dcb_app_is_stream_port, dcb_app_print_key_dec,
+ dcb_app_print_filtered(tab, dcb_app_is_stream_port, dcb_app_print_pid_dec,
"stream_port_prio", "stream-port-prio");
}
static void dcb_app_print_dgram_port_prio(const struct dcb_app_table *tab)
{
- dcb_app_print_filtered(tab, dcb_app_is_dgram_port, dcb_app_print_key_dec,
+ dcb_app_print_filtered(tab, dcb_app_is_dgram_port, dcb_app_print_pid_dec,
"dgram_port_prio", "dgram-port-prio");
}
static void dcb_app_print_port_prio(const struct dcb_app_table *tab)
{
- dcb_app_print_filtered(tab, dcb_app_is_port, dcb_app_print_key_dec,
+ dcb_app_print_filtered(tab, dcb_app_is_port, dcb_app_print_pid_dec,
"port_prio", "port-prio");
}
In preparation for changing the prototype of dcb_app_print_filtered(), rename the _print_key_*() functions to _print_pid_*(), as the protocol can both be key and value with the introduction of dcb-rewr. Signed-off-by: Daniel Machon <daniel.machon@microchip.com> --- dcb/dcb_app.c | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-)