Re: [PATCH 3/5] net: sched: taprio: Fix null pointer deref bug

2019-04-23 Thread Cong Wang
On Tue, Apr 23, 2019 at 12:21 PM Guedes, Andre wrote: > > > > On Apr 22, 2019, at 12:36 PM, Cong Wang wrote: > > Yeah, so we can just remove it. :) > > Fine by me. In that case, the function should_restart_cycle() will be just a > dummy wrapper on list_is_last() so we should probably get rid of

Re: [PATCH 3/5] net: sched: taprio: Fix null pointer deref bug

2019-04-23 Thread Guedes, Andre
> On Apr 22, 2019, at 12:36 PM, Cong Wang wrote: > > On Mon, Apr 22, 2019 at 12:24 PM Guedes, Andre wrote: >> >> >>> On Apr 22, 2019, at 11:07 AM, Cong Wang wrote: >>> >>> On Mon, Apr 22, 2019 at 11:04 AM Cong Wang wrote: On Fri, Apr 19, 2019 at 6:06 PM Andre Guedes wrot

Re: [PATCH 3/5] net: sched: taprio: Fix null pointer deref bug

2019-04-22 Thread Cong Wang
On Mon, Apr 22, 2019 at 12:24 PM Guedes, Andre wrote: > > > > On Apr 22, 2019, at 11:07 AM, Cong Wang wrote: > > > > On Mon, Apr 22, 2019 at 11:04 AM Cong Wang wrote: > >> > >> On Fri, Apr 19, 2019 at 6:06 PM Andre Guedes > >> wrote: > >>> > >>> If 'entry' is NULL we WARN_ON() but dereference

Re: [PATCH 3/5] net: sched: taprio: Fix null pointer deref bug

2019-04-22 Thread Guedes, Andre
> On Apr 22, 2019, at 11:07 AM, Cong Wang wrote: > > On Mon, Apr 22, 2019 at 11:04 AM Cong Wang wrote: >> >> On Fri, Apr 19, 2019 at 6:06 PM Andre Guedes wrote: >>> >>> If 'entry' is NULL we WARN_ON() but dereference the pointer anyway, >>> generating a null pointer dereference bug. This pa

Re: [PATCH 3/5] net: sched: taprio: Fix null pointer deref bug

2019-04-22 Thread Cong Wang
On Mon, Apr 22, 2019 at 11:04 AM Cong Wang wrote: > > On Fri, Apr 19, 2019 at 6:06 PM Andre Guedes wrote: > > > > If 'entry' is NULL we WARN_ON() but dereference the pointer anyway, > > generating a null pointer dereference bug. This patch fixes should_ > > restart_cycle() so we return if the poi

Re: [PATCH 3/5] net: sched: taprio: Fix null pointer deref bug

2019-04-22 Thread Cong Wang
On Fri, Apr 19, 2019 at 6:06 PM Andre Guedes wrote: > > If 'entry' is NULL we WARN_ON() but dereference the pointer anyway, > generating a null pointer dereference bug. This patch fixes should_ > restart_cycle() so we return if the pointer is NULL. Hmm, while you are on it, how is it possible to

[PATCH 3/5] net: sched: taprio: Fix null pointer deref bug

2019-04-19 Thread Andre Guedes
If 'entry' is NULL we WARN_ON() but dereference the pointer anyway, generating a null pointer dereference bug. This patch fixes should_ restart_cycle() so we return if the pointer is NULL. Fixes: 5a781ccbd19e (“tc: Add support for configuring the taprio scheduler”) Signed-off-by: Andre Guedes ---