Martine Lenders d8081453f2 gnrc_ipv6: clean-up and simplify send handling
This change is a gnrc_ipv6_nib/gnrc_netif(2)-based rework of #7210.

Packet duplication
==================

Its main optimization is that it restructures `gnrc_ipv6` handling of
sent packets so that duplication for write-protection happens at the
latest possible step:

* potential `gnrc_netif` headers added by upper layers are
  write-protected before their removal
* This unifies the duplication of the IPv6 header directly after
  that
* Extension headers in-between the IPv6 header and the payload header
  are duplicated just before the check sum is duplicated

Especially the last point allows for only handing a single packet snip
to all lower functions instead of an already searched IPv6 header
(which now is always the first until it is handed to the interface) +
payload header.

Further clean-ups
=================
* Next-hop link-layer address determination was moved to the
  `_send_unicast` function, greatly simplifying the unicast case in the
  `_send` function
* Code for loopback case was added to a new function `_send_to_self`
* Removed some code duplication
2018-07-16 15:08:56 +02:00
..
2018-06-11 19:12:02 +02:00
2018-04-05 14:39:59 +02:00
2018-02-22 19:13:39 +01:00
2018-05-28 15:43:41 -04:00
2017-09-06 08:49:05 +02:00
2018-06-11 19:12:02 +02:00
2018-06-11 19:12:02 +02:00
2016-09-05 02:22:37 +02:00
2018-06-15 00:34:33 +02:00
2018-06-14 11:57:11 +02:00
2018-06-11 19:12:02 +02:00
2018-04-05 14:39:59 +02:00
2016-12-16 09:48:08 +01:00
2016-11-09 11:59:45 +01:00
2018-06-11 15:46:46 +02:00
2018-06-11 19:12:02 +02:00
2017-05-24 17:54:01 +02:00
2016-04-08 23:53:46 +02:00
2018-06-27 08:58:00 +02:00
2017-07-03 10:55:35 +02:00
2018-06-11 19:12:02 +02:00
2017-06-27 18:05:14 +02:00
2018-05-29 18:40:58 +02:00