| 317 | vnet_ipsec_uninit, NULL); |
| 318 | |
| 319 | static struct secpolicy * |
| 320 | ipsec_getpolicy(struct ipsec_softc *sc, int dir, sa_family_t af) |
| 321 | { |
| 322 | |
| 323 | switch (af) { |
| 324 | #ifdef INET |
| 325 | case AF_INET: |
| 326 | return (sc->sp[(dir == IPSEC_DIR_INBOUND ? 0: 1)]); |
| 327 | #endif |
| 328 | #ifdef INET6 |
| 329 | case AF_INET6: |
| 330 | return (sc->sp[(dir == IPSEC_DIR_INBOUND ? 0: 1) |
| 331 | #ifdef INET |
| 332 | + 2 |
| 333 | #endif |
| 334 | ]); |
| 335 | #endif |
| 336 | } |
| 337 | return (NULL); |
| 338 | } |
| 339 | |
| 340 | static struct secasindex * |
| 341 | ipsec_getsaidx(struct ipsec_softc *sc, int dir, sa_family_t af) |
no outgoing calls
no test coverage detected