|
@@ -40,7 +40,7 @@ static int bat_iv_ogm_iface_enable(struct hard_iface *hard_iface)
|
|
|
get_random_bytes(&random_seqno, sizeof(random_seqno));
|
|
|
atomic_set(&hard_iface->seqno, random_seqno);
|
|
|
|
|
|
- hard_iface->packet_len = BATMAN_OGM_LEN;
|
|
|
+ hard_iface->packet_len = BATMAN_OGM_HLEN;
|
|
|
hard_iface->packet_buff = kmalloc(hard_iface->packet_len, GFP_ATOMIC);
|
|
|
|
|
|
if (!hard_iface->packet_buff)
|
|
@@ -112,7 +112,7 @@ static uint8_t hop_penalty(uint8_t tq, const struct bat_priv *bat_priv)
|
|
|
static int bat_iv_ogm_aggr_packet(int buff_pos, int packet_len,
|
|
|
int tt_num_changes)
|
|
|
{
|
|
|
- int next_buff_pos = buff_pos + BATMAN_OGM_LEN + tt_len(tt_num_changes);
|
|
|
+ int next_buff_pos = buff_pos + BATMAN_OGM_HLEN + tt_len(tt_num_changes);
|
|
|
|
|
|
return (next_buff_pos <= packet_len) &&
|
|
|
(next_buff_pos <= MAX_AGGREGATION_BYTES);
|
|
@@ -162,7 +162,7 @@ static void bat_iv_ogm_send_to_if(struct forw_packet *forw_packet,
|
|
|
batman_ogm_packet->ttvn, hard_iface->net_dev->name,
|
|
|
hard_iface->net_dev->dev_addr);
|
|
|
|
|
|
- buff_pos += BATMAN_OGM_LEN +
|
|
|
+ buff_pos += BATMAN_OGM_HLEN +
|
|
|
tt_len(batman_ogm_packet->tt_num_changes);
|
|
|
packet_num++;
|
|
|
batman_ogm_packet = (struct batman_ogm_packet *)
|
|
@@ -540,7 +540,7 @@ static void bat_iv_ogm_forward(struct orig_node *orig_node,
|
|
|
batman_ogm_packet->flags &= ~DIRECTLINK;
|
|
|
|
|
|
bat_iv_ogm_queue_add(bat_priv, (unsigned char *)batman_ogm_packet,
|
|
|
- BATMAN_OGM_LEN + tt_len(tt_num_changes),
|
|
|
+ BATMAN_OGM_HLEN + tt_len(tt_num_changes),
|
|
|
if_incoming, 0, bat_iv_ogm_fwd_send_time());
|
|
|
}
|
|
|
|
|
@@ -1173,12 +1173,12 @@ static void bat_iv_ogm_receive(struct hard_iface *if_incoming,
|
|
|
batman_ogm_packet->seqno = ntohl(batman_ogm_packet->seqno);
|
|
|
batman_ogm_packet->tt_crc = ntohs(batman_ogm_packet->tt_crc);
|
|
|
|
|
|
- tt_buff = packet_buff + buff_pos + BATMAN_OGM_LEN;
|
|
|
+ tt_buff = packet_buff + buff_pos + BATMAN_OGM_HLEN;
|
|
|
|
|
|
bat_iv_ogm_process(ethhdr, batman_ogm_packet,
|
|
|
tt_buff, if_incoming);
|
|
|
|
|
|
- buff_pos += BATMAN_OGM_LEN +
|
|
|
+ buff_pos += BATMAN_OGM_HLEN +
|
|
|
tt_len(batman_ogm_packet->tt_num_changes);
|
|
|
|
|
|
batman_ogm_packet = (struct batman_ogm_packet *)
|