lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:   Fri, 26 Apr 2019 12:36:07 +0100
From:   Ben Hutchings <ben@...adent.org.uk>
To:     Linus Torvalds <torvalds@...ux-foundation.org>,
        syzbot <syzbot+45474c076a4927533d2e@...kaller.appspotmail.com>
Cc:     David Miller <davem@...emloft.net>,
        Dmitry Vyukov <dvyukov@...gle.com>,
        Alan Cox <gnomes@...rguk.ukuu.org.uk>,
        Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
        Jiri Slaby <jslaby@...e.com>,
        Linux List Kernel Mailing <linux-kernel@...r.kernel.org>,
        Michal Hocko <mhocko@...e.com>,
        Netdev <netdev@...r.kernel.org>,
        Tetsuo Handa <penguin-kernel@...ove.sakura.ne.jp>,
        peter@...leysoftware.com,
        syzkaller-bugs <syzkaller-bugs@...glegroups.com>,
        vegard.nossum@...il.com
Subject: Re: BUG: unable to handle page fault for address = ADDR

On Thu, 2019-04-25 at 16:13 -0700, Linus Torvalds wrote:
[...]
> so we do "slhc_free()" on an error pointer, which results in
> 
>     BUG: unable to handle page fault for address = fffffffffffffff4
> 
> and the fix might be something like the appended whitespace-damaged
> trivial one-liner: just make slhc_free() silently ignore an error
> pointer, to match the slhc_init() return behavior.
> 
> Ben? David?

This looks sensible to me.

Ben.

>                        Linus
> 
> diff --git a/drivers/net/slip/slhc.c b/drivers/net/slip/slhc.c
> index f4e93f5fc204..ea90db3c7705 100644
> --- a/drivers/net/slip/slhc.c
> +++ b/drivers/net/slip/slhc.c
> @@ -153,7 +153,7 @@ slhc_init(int rslots, int tslots)
>  void
>  slhc_free(struct slcompress *comp)
>  {
> -       if ( comp == NULLSLCOMPR )
> +       if ( IS_ERR_OR_NULL(comp) )
>                 return;
> 
>         if ( comp->tstate != NULLSLSTATE )
-- 
Ben Hutchings
It is impossible to make anything foolproof
because fools are so ingenious.


Download attachment "signature.asc" of type "application/pgp-signature" (834 bytes)

Powered by blists - more mailing lists