Rename hash_bias to hash_basis to make it consistent with similar
usages.
Signed-off-by: Andy Zhou <[email protected]>
---
include/linux/openvswitch.h | 4 ++--
lib/dpif-netdev.c | 2 +-
lib/odp-util.c | 2 +-
ofproto/ofproto-dpif-xlate.c | 4 ++--
ofproto/ofproto-dpif-xlate.h | 2 +-
5 files changed, 7 insertions(+), 7 deletions(-)
diff --git a/include/linux/openvswitch.h b/include/linux/openvswitch.h
index e17f802..1aa9158 100644
--- a/include/linux/openvswitch.h
+++ b/include/linux/openvswitch.h
@@ -553,11 +553,11 @@ enum ovs_hash_alg {
/*
* struct ovs_action_hash - %OVS_ACTION_ATTR_HASH action argument.
* @hash_alg: Algorithm used to compute hash prior to recirculation.
- * @hash_bias: bias used for computing hash.
+ * @hash_basis: basis used for computing hash.
*/
struct ovs_action_hash {
uint32_t hash_alg; /* One of ovs_hash_alg. */
- uint32_t hash_bias;
+ uint32_t hash_basis;
};
/**
diff --git a/lib/dpif-netdev.c b/lib/dpif-netdev.c
index d17bc64..291fb09 100644
--- a/lib/dpif-netdev.c
+++ b/lib/dpif-netdev.c
@@ -2146,7 +2146,7 @@ dp_execute_cb(void *aux_, struct ofpbuf *packet,
hash_act = nl_attr_get(a);
if (hash_act->hash_alg == OVS_HASH_ALG_L4) {
- hash = flow_hash_symmetric_l4(aux->key, hash_act->hash_bias);
+ hash = flow_hash_symmetric_l4(aux->key, hash_act->hash_basis);
if (!hash) {
hash = 1; /* 0 is not valid */
}
diff --git a/lib/odp-util.c b/lib/odp-util.c
index 70390bf..9d49198 100644
--- a/lib/odp-util.c
+++ b/lib/odp-util.c
@@ -399,7 +399,7 @@ format_odp_hash_action(struct ds *ds, const struct
ovs_action_hash *hash_act)
ds_put_format(ds, "hash(");
if (hash_act->hash_alg == OVS_HASH_ALG_L4) {
- ds_put_format(ds, "hash_l4(%"PRIu32")", hash_act->hash_bias);
+ ds_put_format(ds, "hash_l4(%"PRIu32")", hash_act->hash_basis);
} else {
ds_put_format(ds, "Unknown hash algorithm(%"PRIu32")",
hash_act->hash_alg);
diff --git a/ofproto/ofproto-dpif-xlate.c b/ofproto/ofproto-dpif-xlate.c
index 1ba5462..4c5a48f 100644
--- a/ofproto/ofproto-dpif-xlate.c
+++ b/ofproto/ofproto-dpif-xlate.c
@@ -1148,7 +1148,7 @@ output_normal(struct xlate_ctx *ctx, const struct xbundle
*out_xbundle,
if (ctx->xbridge->enable_recirc) {
ctx->xout->use_recirc = bond_may_recirc(
- out_xbundle->bond, &xr->recirc_id, &xr->hash_bias);
+ out_xbundle->bond, &xr->recirc_id, &xr->hash_basis);
if (ctx->xout->use_recirc) {
/* Only TCP mode uses recirculation. */
@@ -1851,7 +1851,7 @@ compose_output_action__(struct xlate_ctx *ctx, ofp_port_t
ofp_port,
OVS_ACTION_ATTR_HASH,
sizeof *act_hash);
act_hash->hash_alg = xr->hash_alg;
- act_hash->hash_bias = xr->hash_bias;
+ act_hash->hash_basis = xr->hash_basis;
/* Recirc action. */
nl_msg_put_u32(&ctx->xout->odp_actions, OVS_ACTION_ATTR_RECIRC,
diff --git a/ofproto/ofproto-dpif-xlate.h b/ofproto/ofproto-dpif-xlate.h
index 8b53e10..3dfa3b9 100644
--- a/ofproto/ofproto-dpif-xlate.h
+++ b/ofproto/ofproto-dpif-xlate.h
@@ -35,7 +35,7 @@ struct mac_learning;
struct xlate_recirc {
uint32_t recirc_id; /* !0 Use recirculation instead of output. */
uint8_t hash_alg; /* !0 Compute hash for recirc before. */
- uint32_t hash_bias; /* Compute hash for recirc before. */
+ uint32_t hash_basis; /* Compute hash for recirc before. */
};
struct xlate_out {
--
1.9.1
_______________________________________________
dev mailing list
[email protected]
http://openvswitch.org/mailman/listinfo/dev