Signed-off-by: Yaogong Wang <ywang15@xxxxxxxx> --- net/sctp/protocol.c | 4 +++- 1 files changed, 3 insertions(+), 1 deletions(-) diff --git a/net/sctp/protocol.c b/net/sctp/protocol.c index d40c5cc..0121def 100644 --- a/net/sctp/protocol.c +++ b/net/sctp/protocol.c @@ -1310,11 +1310,13 @@ SCTP_STATIC __init int sctp_init(void) /* Add FCFS to sctp_sched_list */ status = sctp_register_sched(&sctp_fcfs); if (status) - goto err_v6_add_protocol; + goto err_register_sched; status = 0; out: return status; +err_register_sched: + sctp_v6_del_protocol(); err_v6_add_protocol: sctp_v4_del_protocol(); err_add_protocol: -- 1.7.0.4 On Mon, Sep 13, 2010 at 9:45 AM, Vlad Yasevich <vladislav.yasevich@xxxxxx> wrote: > One small nit. > > On 09/11/2010 09:12 PM, Yaogong Wang wrote: >> Implement the pluggable multistream scheduling framework. >> Provide the default first-come-first-serve (FCFS) algorithm. >> >> Signed-off-by: Yaogong Wang <ywang15@xxxxxxxx> >> --- >> diff --git a/net/sctp/protocol.c b/net/sctp/protocol.c >> index 5027b83..d40c5cc 100644 >> --- a/net/sctp/protocol.c >> +++ b/net/sctp/protocol.c >> @@ -1157,6 +1157,9 @@ SCTP_STATIC __init int sctp_init(void) >> sctp_max_instreams = SCTP_DEFAULT_INSTREAMS; >> sctp_max_outstreams = SCTP_DEFAULT_OUTSTREAMS; >> >> + /* Initialize default multistream scheduling algorithm to FCFS */ >> + sctp_default_sched_ops = &sctp_fcfs; >> + >> /* Initialize handle used for association ids. */ >> idr_init(&sctp_assocs_id); >> >> @@ -1304,6 +1307,11 @@ SCTP_STATIC __init int sctp_init(void) >> if (status) >> goto err_v6_add_protocol; >> >> + /* Add FCFS to sctp_sched_list */ >> + status = sctp_register_sched(&sctp_fcfs); >> + if (status) >> + goto err_v6_add_protocol; >> + > > This needs its own tag that will call sctp_v6_del_protocol(). > > -vlad > >> status = 0; >> out: >> return status; -- To unsubscribe from this list: send the line "unsubscribe linux-sctp" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html