Message ID | 1422460889-12144-3-git-send-email-ciprian.barbu@linaro.org |
---|---|
State | New |
Headers | show |
If you want to add returns you need to do it in all other examples also. Like example/packet Maxim. On 01/28/2015 07:01 PM, Ciprian Barbu wrote: > Fix for https://bugs.linaro.org/show_bug.cgi?id=1161 > > Signe-off-by: Ciprian Barbu <ciprian.barbu@linaro.org> > --- > example/l2fwd/odp_l2fwd.c | 2 ++ > 1 file changed, 2 insertions(+) > > diff --git a/example/l2fwd/odp_l2fwd.c b/example/l2fwd/odp_l2fwd.c > index 150de18..7c4e8bd 100644 > --- a/example/l2fwd/odp_l2fwd.c > +++ b/example/l2fwd/odp_l2fwd.c > @@ -146,6 +146,7 @@ static void *pktio_queue_thread(void *arg) > } > > /* unreachable */ > + return NULL; > } > > /** > @@ -233,6 +234,7 @@ static void *pktio_ifburst_thread(void *arg) > } > > /* unreachable */ > + return NULL; > } > > /**
On 28 January 2015 at 17:23, Maxim Uvarov <maxim.uvarov@linaro.org> wrote: > If you want to add returns you need to do it in all other examples also. Someone should do it. We are not stopping Ciprian's patch because it did not fix the whole universe? > Like example/packet > > Maxim. > > On 01/28/2015 07:01 PM, Ciprian Barbu wrote: >> >> Fix for https://bugs.linaro.org/show_bug.cgi?id=1161 >> >> Signe-off-by: Ciprian Barbu <ciprian.barbu@linaro.org> >> --- >> example/l2fwd/odp_l2fwd.c | 2 ++ >> 1 file changed, 2 insertions(+) >> >> diff --git a/example/l2fwd/odp_l2fwd.c b/example/l2fwd/odp_l2fwd.c >> index 150de18..7c4e8bd 100644 >> --- a/example/l2fwd/odp_l2fwd.c >> +++ b/example/l2fwd/odp_l2fwd.c >> @@ -146,6 +146,7 @@ static void *pktio_queue_thread(void *arg) >> } >> /* unreachable */ >> + return NULL; >> } >> /** >> @@ -233,6 +234,7 @@ static void *pktio_ifburst_thread(void *arg) >> } >> /* unreachable */ >> + return NULL; >> } >> /** > > > > _______________________________________________ > lng-odp mailing list > lng-odp@lists.linaro.org > http://lists.linaro.org/mailman/listinfo/lng-odp
Wouldn't a cleaner fix be to change the routine signature from void * to void? It doesn't return so why should if have a return type in its signature in the first place? On Wed, Jan 28, 2015 at 11:08 AM, Ola Liljedahl <ola.liljedahl@linaro.org> wrote: > On 28 January 2015 at 17:23, Maxim Uvarov <maxim.uvarov@linaro.org> wrote: > > If you want to add returns you need to do it in all other examples also. > Someone should do it. We are not stopping Ciprian's patch because it > did not fix the whole universe? > > > Like example/packet > > > > Maxim. > > > > On 01/28/2015 07:01 PM, Ciprian Barbu wrote: > >> > >> Fix for https://bugs.linaro.org/show_bug.cgi?id=1161 > >> > >> Signe-off-by: Ciprian Barbu <ciprian.barbu@linaro.org> > >> --- > >> example/l2fwd/odp_l2fwd.c | 2 ++ > >> 1 file changed, 2 insertions(+) > >> > >> diff --git a/example/l2fwd/odp_l2fwd.c b/example/l2fwd/odp_l2fwd.c > >> index 150de18..7c4e8bd 100644 > >> --- a/example/l2fwd/odp_l2fwd.c > >> +++ b/example/l2fwd/odp_l2fwd.c > >> @@ -146,6 +146,7 @@ static void *pktio_queue_thread(void *arg) > >> } > >> /* unreachable */ > >> + return NULL; > >> } > >> /** > >> @@ -233,6 +234,7 @@ static void *pktio_ifburst_thread(void *arg) > >> } > >> /* unreachable */ > >> + return NULL; > >> } > >> /** > > > > > > > > _______________________________________________ > > lng-odp mailing list > > lng-odp@lists.linaro.org > > http://lists.linaro.org/mailman/listinfo/lng-odp > > _______________________________________________ > lng-odp mailing list > lng-odp@lists.linaro.org > http://lists.linaro.org/mailman/listinfo/lng-odp >
On 01/28/2015 10:53 PM, Bill Fischofer wrote: > Wouldn't a cleaner fix be to change the routine signature from void * > to void? It doesn't return so why should if have a return type in its > signature in the first place? > Because it's thread created with pthread: int pthread_create(pthread_t *thread, const pthread_attr_t *attr, void *(*start_routine) (void *), void *arg); > On Wed, Jan 28, 2015 at 11:08 AM, Ola Liljedahl > <ola.liljedahl@linaro.org <mailto:ola.liljedahl@linaro.org>> wrote: > > On 28 January 2015 at 17:23, Maxim Uvarov <maxim.uvarov@linaro.org > <mailto:maxim.uvarov@linaro.org>> wrote: > > If you want to add returns you need to do it in all other > examples also. > Someone should do it. We are not stopping Ciprian's patch because it > did not fix the whole universe? > We should be consistent and have same code in all examples. Because this patch 2/2 actually does nothing I think we can skip it until there will be fix for all similar places. BR, Maxim. > > Like example/packet > > > > Maxim. > > > > On 01/28/2015 07:01 PM, Ciprian Barbu wrote: > >> > >> Fix for https://bugs.linaro.org/show_bug.cgi?id=1161 > >> > >> Signe-off-by: Ciprian Barbu <ciprian.barbu@linaro.org > <mailto:ciprian.barbu@linaro.org>> > >> --- > >> example/l2fwd/odp_l2fwd.c | 2 ++ > >> 1 file changed, 2 insertions(+) > >> > >> diff --git a/example/l2fwd/odp_l2fwd.c b/example/l2fwd/odp_l2fwd.c > >> index 150de18..7c4e8bd 100644 > >> --- a/example/l2fwd/odp_l2fwd.c > >> +++ b/example/l2fwd/odp_l2fwd.c > >> @@ -146,6 +146,7 @@ static void *pktio_queue_thread(void *arg) > >> } > >> /* unreachable */ > >> + return NULL; > >> } > >> /** > >> @@ -233,6 +234,7 @@ static void *pktio_ifburst_thread(void *arg) > >> } > >> /* unreachable */ > >> + return NULL; > >> } > >> /** > > > > > > > > _______________________________________________ > > lng-odp mailing list > > lng-odp@lists.linaro.org <mailto:lng-odp@lists.linaro.org> > > http://lists.linaro.org/mailman/listinfo/lng-odp > > _______________________________________________ > lng-odp mailing list > lng-odp@lists.linaro.org <mailto:lng-odp@lists.linaro.org> > http://lists.linaro.org/mailman/listinfo/lng-odp > >
diff --git a/example/l2fwd/odp_l2fwd.c b/example/l2fwd/odp_l2fwd.c index 150de18..7c4e8bd 100644 --- a/example/l2fwd/odp_l2fwd.c +++ b/example/l2fwd/odp_l2fwd.c @@ -146,6 +146,7 @@ static void *pktio_queue_thread(void *arg) } /* unreachable */ + return NULL; } /** @@ -233,6 +234,7 @@ static void *pktio_ifburst_thread(void *arg) } /* unreachable */ + return NULL; } /**