svn commit: r352142 - in projects/hps_callouts/sys: compat/linuxkpi/common/src kern netinet
Hans Petter Selasky
hselasky at FreeBSD.org
Tue Sep 10 16:35:28 UTC 2019
Author: hselasky
Date: Tue Sep 10 16:35:26 2019
New Revision: 352142
URL: https://svnweb.freebsd.org/changeset/base/352142
Log:
Compile fixes for LINT.
Sponsored by: Mellanox Technologies
Modified:
projects/hps_callouts/sys/compat/linuxkpi/common/src/linux_compat.c
projects/hps_callouts/sys/kern/kern_timeout.c
projects/hps_callouts/sys/netinet/tcp_hpts.c
projects/hps_callouts/sys/netinet/tcp_hpts.h
Modified: projects/hps_callouts/sys/compat/linuxkpi/common/src/linux_compat.c
==============================================================================
--- projects/hps_callouts/sys/compat/linuxkpi/common/src/linux_compat.c Tue Sep 10 16:30:06 2019 (r352141)
+++ projects/hps_callouts/sys/compat/linuxkpi/common/src/linux_compat.c Tue Sep 10 16:35:26 2019 (r352142)
@@ -1909,9 +1909,7 @@ int
del_timer(struct timer_list *timer)
{
- if (callout_stop(&(timer)->callout) == -1)
- return (0);
- return (1);
+ return (callout_stop(&(timer)->callout).was_cancelled);
}
static void
Modified: projects/hps_callouts/sys/kern/kern_timeout.c
==============================================================================
--- projects/hps_callouts/sys/kern/kern_timeout.c Tue Sep 10 16:30:06 2019 (r352141)
+++ projects/hps_callouts/sys/kern/kern_timeout.c Tue Sep 10 16:35:26 2019 (r352142)
@@ -1083,7 +1083,7 @@ callout_reset_sbt_on(struct callout *c, sbintime_t sbt
* callout. Don't reschedule.
*/
CTR4(KTR_CALLOUT, "%s %p func %p arg %p",
- cancelled ? "cancelled" : "failed to cancel",
+ retval.was_cancelled ? "cancelled" : "failed to cancel",
c, c->c_func, c->c_arg);
goto done;
}
@@ -1162,7 +1162,7 @@ callout_reset_sbt_on(struct callout *c, sbintime_t sbt
callout_cc_add(c, cc, to_sbt, precision, ftn, arg, cpu, flags);
CTR6(KTR_CALLOUT, "%sscheduled %p func %p arg %p in %d.%08x",
- cancelled ? "re" : "", c, c->c_func, c->c_arg, (int)(to_sbt >> 32),
+ retval.was_cancelled ? "re" : "", c, c->c_func, c->c_arg, (int)(to_sbt >> 32),
(u_int)(to_sbt & 0xffffffff));
done:
CC_UNLOCK(cc);
Modified: projects/hps_callouts/sys/netinet/tcp_hpts.c
==============================================================================
--- projects/hps_callouts/sys/netinet/tcp_hpts.c Tue Sep 10 16:30:06 2019 (r352141)
+++ projects/hps_callouts/sys/netinet/tcp_hpts.c Tue Sep 10 16:35:26 2019 (r352142)
@@ -1000,10 +1000,10 @@ tcp_hpts_insert_locked(struct tcp_hpts_entry *hpts, st
tcp_wakehpts(hpts);
if (diag) {
diag->need_new_to = 0;
- diag->co_ret = 0xffff0000;
+ diag->co_ret = (callout_ret_t){};
}
} else if (need_new_to) {
- int32_t co_ret;
+ callout_ret_t co_ret;
struct timeval tv;
sbintime_t sb;
Modified: projects/hps_callouts/sys/netinet/tcp_hpts.h
==============================================================================
--- projects/hps_callouts/sys/netinet/tcp_hpts.h Tue Sep 10 16:30:06 2019 (r352141)
+++ projects/hps_callouts/sys/netinet/tcp_hpts.h Tue Sep 10 16:35:26 2019 (r352142)
@@ -68,7 +68,7 @@ struct hpts_diag {
uint32_t wheel_tick; /* bbr->bw_inuse x */
uint32_t maxticks; /* bbr->delRate x */
uint32_t wheel_cts; /* bbr->rttProp x */
- int32_t co_ret; /* bbr->pkts_out x */
+ callout_ret_t co_ret; /* bbr->pkts_out x */
uint32_t p_curtick; /* upper bbr->cur_del_rate */
uint32_t p_lasttick; /* lower bbr->cur_del_rate */
uint8_t p_on_min_sleep; /* bbr->flex8 x */
More information about the svn-src-projects
mailing list