On Thu, Dec 29, 2011 at 10:56:43PM +0100, Matthias Schiffer wrote:
Hi, I already posted a first patch to add support for link-local addresses for BGP peerings one year ago, and now I've finally found time to update the patch for the current bird version and fix the problems mentioned in reply to the first patch.
This patch series allows using NEF_STICKY neighbors for link-local addresses by saving the interface name in the neighbor structure, thus working even when the interface is removed and re-added causing the interface index to change.
Hello Thanks for the patch. I noticed that struct iface could exist even if the iface is missing (this is done when iface is removed), so sticky link-local neighbors could be implemented and used in more uniform way (using neigh_find2() with NEF_STICKY, like it is done for neighbors with global addresses). I implemented it in that way and adapted the static protocol for that (primarily for testing). See attached patch. Instead of separate option, this also uses standard syntax (like fe80::1%eth0) for link-local addresses. I will adapt the rest of your BGP patch to that and merge it.
An additional patch that is needed to make this work under FreeBSD is also included; the current behaviour doesn't handle numbered v6 addresses on peer-to-peer interfaces correctly, which link-local addresses are generally. I didn't get the chance to test this under other BSDs though.
Thanks. The patch is: +#ifdef IPV6 + if ((iface->flags & IF_MULTIACCESS) || (masklen != BITS_PER_IP_ADDRESS)) +#else if (iface->flags & IF_MULTIACCESS) +#endif Does anybody know, whether there should ever be check for (iface->flags & IF_MULTIACCESS), and not just the (masklen != BITS_PER_IP_ADDRESS), like it is in the Linux code? -- Elen sila lumenn' omentielvo Ondrej 'SanTiago' Zajicek (email: santiago@crfreenet.org) OpenPGP encrypted e-mails preferred (KeyID 0x11DEADC3, wwwkeys.pgp.net) "To err is human -- to blame it on a computer is even more so."