Commit 4aa02644 authored by Chris Metcalf's avatar Chris Metcalf Committed by David S. Miller

tile: make "tile_net.custom" a proper bool module parameter

Signed-off-by: default avatarChris Metcalf <cmetcalf@tilera.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 2c7d04a9
...@@ -256,11 +256,11 @@ static char *network_cpus_string; ...@@ -256,11 +256,11 @@ static char *network_cpus_string;
/* The actual cpus in "network_cpus". */ /* The actual cpus in "network_cpus". */
static struct cpumask network_cpus_map; static struct cpumask network_cpus_map;
/* If "loopify=LINK" was specified, this is "LINK". */ /* If "tile_net.loopify=LINK" was specified, this is "LINK". */
static char *loopify_link_name; static char *loopify_link_name;
/* If "tile_net.custom" was specified, this is non-NULL. */ /* If "tile_net.custom" was specified, this is true. */
static char *custom_str; static bool custom_flag;
/* If "tile_net.jumbo=NUM" was specified, this is "NUM". */ /* If "tile_net.jumbo=NUM" was specified, this is "NUM". */
static uint jumbo_num; static uint jumbo_num;
...@@ -323,7 +323,7 @@ MODULE_PARM_DESC(loopify, "name the device to use loop0/1 for ingress/egress"); ...@@ -323,7 +323,7 @@ MODULE_PARM_DESC(loopify, "name the device to use loop0/1 for ingress/egress");
/* The "tile_net.custom" argument causes us to ignore the "conventional" /* The "tile_net.custom" argument causes us to ignore the "conventional"
* classifier metadata, in particular, the "l2_offset". * classifier metadata, in particular, the "l2_offset".
*/ */
module_param_named(custom, custom_str, charp, 0444); module_param_named(custom, custom_flag, bool, 0444);
MODULE_PARM_DESC(custom, "indicates a (heavily) customized classifier"); MODULE_PARM_DESC(custom, "indicates a (heavily) customized classifier");
/* The "tile_net.jumbo" argument causes us to support "jumbo" packets, /* The "tile_net.jumbo" argument causes us to support "jumbo" packets,
...@@ -501,7 +501,7 @@ static bool tile_net_handle_packet(int instance, gxio_mpipe_idesc_t *idesc) ...@@ -501,7 +501,7 @@ static bool tile_net_handle_packet(int instance, gxio_mpipe_idesc_t *idesc)
} }
/* Get the "l2_offset", if allowed. */ /* Get the "l2_offset", if allowed. */
l2_offset = custom_str ? 0 : gxio_mpipe_idesc_get_l2_offset(idesc); l2_offset = custom_flag ? 0 : gxio_mpipe_idesc_get_l2_offset(idesc);
/* Get the VA (including NET_IP_ALIGN bytes of "headroom"). */ /* Get the VA (including NET_IP_ALIGN bytes of "headroom"). */
va = tile_io_addr_to_va((unsigned long)idesc->va); va = tile_io_addr_to_va((unsigned long)idesc->va);
......
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