l2tp: add peer_offset parameter
Introduce peer_offset parameter in order to add the capability to specify two different values for payload offset on tx/rx side. If just offset is provided by userspace use it for rx side as well in order to maintain compatibility with older l2tp versions Signed-off-by: Lorenzo Bianconi <lorenzo.bianconi@redhat.com> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:

committed by
David S. Miller

parent
820da53575
commit
f15bc54eee
@@ -180,8 +180,9 @@ static void l2tp_dfs_seq_session_show(struct seq_file *m, void *v)
|
||||
session->lns_mode ? "LNS" : "LAC",
|
||||
session->debug,
|
||||
jiffies_to_msecs(session->reorder_timeout));
|
||||
seq_printf(m, " offset %hu l2specific %hu/%hu\n",
|
||||
session->offset, session->l2specific_type, session->l2specific_len);
|
||||
seq_printf(m, " offset %hu peer_offset %hu l2specific %hu/%hu\n",
|
||||
session->offset, session->peer_offset,
|
||||
session->l2specific_type, session->l2specific_len);
|
||||
if (session->cookie_len) {
|
||||
seq_printf(m, " cookie %02x%02x%02x%02x",
|
||||
session->cookie[0], session->cookie[1],
|
||||
@@ -228,7 +229,8 @@ static int l2tp_dfs_seq_show(struct seq_file *m, void *v)
|
||||
seq_puts(m, " debug tx-pkts/bytes/errs rx-pkts/bytes/errs\n");
|
||||
seq_puts(m, " SESSION ID, peer ID, PWTYPE\n");
|
||||
seq_puts(m, " refcnt cnt\n");
|
||||
seq_puts(m, " offset OFFSET l2specific TYPE/LEN\n");
|
||||
seq_puts(m, " offset OFFSET peer_offset OFFSET");
|
||||
seq_puts(m, " l2specific TYPE/LEN\n");
|
||||
seq_puts(m, " [ cookie ]\n");
|
||||
seq_puts(m, " [ peer cookie ]\n");
|
||||
seq_puts(m, " config mtu/mru/rcvseq/sendseq/dataseq/lns debug reorderto\n");
|
||||
|
Reference in New Issue
Block a user