Module Name: src Committed By: ozaki-r Date: Fri Jul 21 04:50:11 UTC 2017
Modified Files: src/sys/netipsec: ipsec.c ipsec.h key.c key_debug.c Log Message: Remove ipsecrequest#sav To generate a diff of this commit: cvs rdiff -u -r1.109 -r1.110 src/sys/netipsec/ipsec.c cvs rdiff -u -r1.54 -r1.55 src/sys/netipsec/ipsec.h cvs rdiff -u -r1.190 -r1.191 src/sys/netipsec/key.c cvs rdiff -u -r1.17 -r1.18 src/sys/netipsec/key_debug.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
Modified files: Index: src/sys/netipsec/ipsec.c diff -u src/sys/netipsec/ipsec.c:1.109 src/sys/netipsec/ipsec.c:1.110 --- src/sys/netipsec/ipsec.c:1.109 Fri Jul 21 04:39:08 2017 +++ src/sys/netipsec/ipsec.c Fri Jul 21 04:50:11 2017 @@ -1,4 +1,4 @@ -/* $NetBSD: ipsec.c,v 1.109 2017/07/21 04:39:08 ozaki-r Exp $ */ +/* $NetBSD: ipsec.c,v 1.110 2017/07/21 04:50:11 ozaki-r Exp $ */ /* $FreeBSD: /usr/local/www/cvsroot/FreeBSD/src/sys/netipsec/ipsec.c,v 1.2.2.2 2003/07/01 01:38:13 sam Exp $ */ /* $KAME: ipsec.c,v 1.103 2001/05/24 07:14:18 sakane Exp $ */ @@ -32,7 +32,7 @@ */ #include <sys/cdefs.h> -__KERNEL_RCSID(0, "$NetBSD: ipsec.c,v 1.109 2017/07/21 04:39:08 ozaki-r Exp $"); +__KERNEL_RCSID(0, "$NetBSD: ipsec.c,v 1.110 2017/07/21 04:50:11 ozaki-r Exp $"); /* * IPsec controller part. @@ -1313,7 +1313,6 @@ ipsec_deepcopy_policy(const struct secpo memcpy(&(*q)->saidx.src, &p->saidx.src, sizeof((*q)->saidx.src)); memcpy(&(*q)->saidx.dst, &p->saidx.dst, sizeof((*q)->saidx.dst)); - (*q)->sav = NULL; (*q)->sp = dst; q = &((*q)->next); Index: src/sys/netipsec/ipsec.h diff -u src/sys/netipsec/ipsec.h:1.54 src/sys/netipsec/ipsec.h:1.55 --- src/sys/netipsec/ipsec.h:1.54 Fri Jul 21 04:39:08 2017 +++ src/sys/netipsec/ipsec.h Fri Jul 21 04:50:11 2017 @@ -1,4 +1,4 @@ -/* $NetBSD: ipsec.h,v 1.54 2017/07/21 04:39:08 ozaki-r Exp $ */ +/* $NetBSD: ipsec.h,v 1.55 2017/07/21 04:50:11 ozaki-r Exp $ */ /* $FreeBSD: /usr/local/www/cvsroot/FreeBSD/src/sys/netipsec/ipsec.h,v 1.2.4.2 2004/02/14 22:23:23 bms Exp $ */ /* $KAME: ipsec.h,v 1.53 2001/11/20 08:32:38 itojun Exp $ */ @@ -110,7 +110,6 @@ struct ipsecrequest { /* if __ss_len == 0 then no address specified.*/ u_int level; /* IPsec level defined below. */ - struct secasvar *sav; /* place holder of SA for use */ struct secpolicy *sp; /* back pointer to SP */ }; Index: src/sys/netipsec/key.c diff -u src/sys/netipsec/key.c:1.190 src/sys/netipsec/key.c:1.191 --- src/sys/netipsec/key.c:1.190 Fri Jul 21 04:43:42 2017 +++ src/sys/netipsec/key.c Fri Jul 21 04:50:11 2017 @@ -1,4 +1,4 @@ -/* $NetBSD: key.c,v 1.190 2017/07/21 04:43:42 ozaki-r Exp $ */ +/* $NetBSD: key.c,v 1.191 2017/07/21 04:50:11 ozaki-r Exp $ */ /* $FreeBSD: src/sys/netipsec/key.c,v 1.3.2.3 2004/02/14 22:23:23 bms Exp $ */ /* $KAME: key.c,v 1.191 2001/06/27 10:46:49 sakane Exp $ */ @@ -32,7 +32,7 @@ */ #include <sys/cdefs.h> -__KERNEL_RCSID(0, "$NetBSD: key.c,v 1.190 2017/07/21 04:43:42 ozaki-r Exp $"); +__KERNEL_RCSID(0, "$NetBSD: key.c,v 1.191 2017/07/21 04:50:11 ozaki-r Exp $"); /* * This code is referd to RFC 2367 @@ -1277,11 +1277,6 @@ key_delsp(struct secpolicy *sp) struct ipsecrequest *isr = sp->req, *nextisr; while (isr != NULL) { - if (isr->sav != NULL) { - KEY_FREESAV(&isr->sav); - isr->sav = NULL; - } - nextisr = isr->next; kmem_intr_free(isr, sizeof(*isr)); isr = nextisr; @@ -1538,7 +1533,6 @@ key_msg2sp(const struct sadb_x_policy *x memcpy(&(*p_isr)->saidx.dst, paddr, paddr->sa_len); } - (*p_isr)->sav = NULL; (*p_isr)->sp = newsp; /* initialization for the next. */ Index: src/sys/netipsec/key_debug.c diff -u src/sys/netipsec/key_debug.c:1.17 src/sys/netipsec/key_debug.c:1.18 --- src/sys/netipsec/key_debug.c:1.17 Wed Apr 26 03:16:06 2017 +++ src/sys/netipsec/key_debug.c Fri Jul 21 04:50:11 2017 @@ -1,4 +1,4 @@ -/* $NetBSD: key_debug.c,v 1.17 2017/04/26 03:16:06 ozaki-r Exp $ */ +/* $NetBSD: key_debug.c,v 1.18 2017/07/21 04:50:11 ozaki-r Exp $ */ /* $FreeBSD: src/sys/netipsec/key_debug.c,v 1.1.4.1 2003/01/24 05:11:36 sam Exp $ */ /* $KAME: key_debug.c,v 1.26 2001/06/27 10:46:50 sakane Exp $ */ @@ -33,7 +33,7 @@ #ifdef _KERNEL #include <sys/cdefs.h> -__KERNEL_RCSID(0, "$NetBSD: key_debug.c,v 1.17 2017/04/26 03:16:06 ozaki-r Exp $"); +__KERNEL_RCSID(0, "$NetBSD: key_debug.c,v 1.18 2017/07/21 04:50:11 ozaki-r Exp $"); #endif #if defined(_KERNEL_OPT) @@ -479,9 +479,6 @@ kdebug_secpolicy(const struct secpolicy printf(" level=%u\n", isr->level); kdebug_secasindex(&isr->saidx); - - if (isr->sav != NULL) - kdebug_secasv(isr->sav); } printf(" }\n"); }