svn commit: r203941 - projects/tcp_cc_head/sys/netinet
Lawrence Stewart
lstewart at FreeBSD.org
Tue Feb 16 00:21:33 UTC 2010
Author: lstewart
Date: Tue Feb 16 00:21:33 2010
New Revision: 203941
URL: http://svn.freebsd.org/changeset/base/203941
Log:
- Fix a memory leak caused by creating the helper's uma zone with the
UMA_ZONE_NOFREE flag.
Modified:
projects/tcp_cc_head/sys/netinet/h_ertt.c
Modified: projects/tcp_cc_head/sys/netinet/h_ertt.c
==============================================================================
--- projects/tcp_cc_head/sys/netinet/h_ertt.c Tue Feb 16 00:08:42 2010 (r203940)
+++ projects/tcp_cc_head/sys/netinet/h_ertt.c Tue Feb 16 00:21:33 2010 (r203941)
@@ -1,7 +1,8 @@
/*-
* Copyright (c) 2009-2010
* Swinburne University of Technology, Melbourne, Australia
-* All rights reserved.
+ * Copyright (c) 2010 Lawrence Stewart <lstewart at freebsd.org>
+ * All rights reserved.
*
* This software was developed at the Centre for Advanced Internet
* Architectures, Swinburne University, by David Hayes and Lawrence Stewart,
@@ -85,10 +86,6 @@ struct txseginfo {
/* flags for operation */
u_int flags;
};
-/* txseginfo flags */
-#define TXSI_TSO 0x01 /* TSO was used for this entry */
-#define TXSI_RTT_MEASURE_START 0x02 /* a rate measure starts here based on this txsi's rtt */
-#define TXSI_RX_MEASURE_END 0x04 /* measure the received rate until this txsi */
/* txseginfo flags */
#define TXSI_TSO 0x01 /* TSO was used for this entry */
@@ -322,7 +319,7 @@ ertt_mod_init(void)
int ret;
V_txseginfo_zone = uma_zcreate("txseginfo", sizeof(struct txseginfo),
- NULL, NULL, NULL, NULL, UMA_ALIGN_PTR, UMA_ZONE_NOFREE);
+ NULL, NULL, NULL, NULL, 0, 0);
ret = register_hhook(HHOOK_TYPE_TCP, HHOOK_TCP_ESTABLISHED_IN,
&ertt_helper, &ertt_packet_measurement_hook, NULL, HHOOK_WAITOK);
@@ -377,7 +374,6 @@ ertt_uma_dtor(void *mem, int size, void
uma_zfree(V_txseginfo_zone, txsi);
txsi = n_txsi;
}
-
}
DECLARE_HELPER_UMA(ertt, &ertt_helper, 1, sizeof(struct ertt), ertt_uma_ctor, ertt_uma_dtor);
More information about the svn-src-projects
mailing list