From mboxrd@z Thu Jan 1 00:00:00 1970 From: Alexei Starovoitov Subject: Re: [PATCH v2] bpf: fix divides by zero Date: Sun, 14 Jan 2018 09:08:24 -0800 Message-ID: <20180114170822.sdqs2jreb3eaflsr@ast-mbp> References: <1515807206.3606.4.camel@gmail.com> <1515807803.3606.7.camel@gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Cc: Alexei Starovoitov , Daniel Borkmann , netdev , edumazet@google.com To: Eric Dumazet Return-path: Received: from mail-pl0-f43.google.com ([209.85.160.43]:32842 "EHLO mail-pl0-f43.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751653AbeANRI0 (ORCPT ); Sun, 14 Jan 2018 12:08:26 -0500 Received: by mail-pl0-f43.google.com with SMTP id 1so2079254plv.0 for ; Sun, 14 Jan 2018 09:08:26 -0800 (PST) Content-Disposition: inline In-Reply-To: <1515807803.3606.7.camel@gmail.com> Sender: netdev-owner@vger.kernel.org List-ID: On Fri, Jan 12, 2018 at 05:43:23PM -0800, Eric Dumazet wrote: > From: Eric Dumazet > > Divides by zero are not nice, lets avoid them if possible. > > Also do_div() seems not needed when dealing with 32bit operands, > but this seems a minor detail. > > Fixes: bd4cf0ed331a ("net: filter: rework/optimize internal BPF interpreter's instruction set") > Signed-off-by: Eric Dumazet > Reported-by: syzbot > --- Applied, Thank you Eric.