Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753939AbbLDT1N (ORCPT ); Fri, 4 Dec 2015 14:27:13 -0500 Received: from shards.monkeyblade.net ([149.20.54.216]:40439 "EHLO shards.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752274AbbLDT1M (ORCPT ); Fri, 4 Dec 2015 14:27:12 -0500 Date: Fri, 04 Dec 2015 14:26:51 -0500 (EST) Message-Id: <20151204.142651.968075964630586979.davem@davemloft.net> To: alexei.starovoitov@gmail.com Cc: dvyukov@google.com, ast@kernel.org, netdev@vger.kernel.org, linux-kernel@vger.kernel.org, syzkaller@googlegroups.com, kcc@google.com, glider@google.com, sasha.levin@oracle.com, edumazet@google.com, ryabinin.a.a@gmail.com Subject: Re: bpf: undefined shift in __bpf_prog_run From: David Miller In-Reply-To: <20151204191013.GB45508@ast-mbp.thefacebook.com> References: <20151204184333.GA42737@ast-mbp.thefacebook.com> <20151204191013.GB45508@ast-mbp.thefacebook.com> X-Mailer: Mew version 6.7 on Emacs 24.5 / Mule 6.0 (HANACHIRUSATO) Mime-Version: 1.0 Content-Type: Text/Plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Greylist: Sender succeeded SMTP AUTH, not delayed by milter-greylist-4.5.12 (shards.monkeyblade.net [149.20.54.216]); Fri, 04 Dec 2015 11:27:11 -0800 (PST) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 577 Lines: 14 From: Alexei Starovoitov Date: Fri, 4 Dec 2015 11:10:15 -0800 > just don't generate random bpf programs with such shifts. Agreed, it is exactly the same as if the compiler emitted real cpu shift instructions with undefined behavior. The creator of the BPF code in question is what should be fixed. -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/