Received: by 2002:a05:6902:102b:0:0:0:0 with SMTP id x11csp940414ybt; Wed, 8 Jul 2020 16:00:30 -0700 (PDT) X-Google-Smtp-Source: ABdhPJz4QRLDzAGCpjXWCwW/W+ECvNKHeJImZ4sKlxe9qy1Zdxapw4ER+/mrRwec7Lcw3NYgTqjS X-Received: by 2002:a05:6402:2064:: with SMTP id bd4mr67499789edb.180.1594249230520; Wed, 08 Jul 2020 16:00:30 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1594249230; cv=none; d=google.com; s=arc-20160816; b=XsC1Vp800RZV9MRsKG+TWLDaHo98hNgtHpB0lmpsqD28yh3cY80CpdUm4WVi2vrxJA +X1M3tkruSJXGGZ1YKy6WuIG+tb8LZXQCZp0bu1T5m7n2OfTwm5vvvYKIwptHf21ueDx f5w2LQM1luywvxtOa2duNezKvj7IDDk7QwaKMaDBsibf+zQ0lDgDQAcsgfIv5mvUUSu2 5dgvbm3XkrKR5KMD2YJw7Hiy+6ctlnOE7mrWhu2OCx/3f+v3LV75sqbwhOEu2+ZqXbXy 38vfCD5rl3wYF9Czq3BrCuMdjll53CMvkUEJvCgtZueHxtGckwde/4axA0KQ7IjMIw41 xsTA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding :content-language:in-reply-to:mime-version:user-agent:date :message-id:from:references:cc:to:subject; bh=K380CCisNMphsBppcoxwQtyD/WDrJXtHOvgjVoZ1W6w=; b=dqQRUIuvas6jv4I+LAgAZZR6qiIR4AqQkcxn5tyxOhJw96JHdUvePa3sviOsEBnIcY OyoFWLsoh25iiQsfvf2wf8GUCAtxay0lnPR0B+gB1dESk4isKBFuP2oCvMkJqBKLehn+ u8n5RcIiiCr6kYvAtiN0856prnQ4Rht+EV2Bz2b7oB7QsfutXAsVkM2Gahy6n3cQ4so2 m/38qWXUdIOs6EjclkHrAGp1kGxQjuYKPPF42suHo1uMf6s32UDGagk0A4y4YWqXw90q zyekNGEBlADdp2MqOSSexYqLcCaSs+RF9DARuyLRnFCXo1HoNOEToU+g9KH1oWaGErsn hGtw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id dt4si888864ejc.34.2020.07.08.16.00.07; Wed, 08 Jul 2020 16:00:30 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726275AbgGHW5o (ORCPT + 99 others); Wed, 8 Jul 2020 18:57:44 -0400 Received: from www62.your-server.de ([213.133.104.62]:33960 "EHLO www62.your-server.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726044AbgGHW5o (ORCPT ); Wed, 8 Jul 2020 18:57:44 -0400 Received: from sslproxy01.your-server.de ([78.46.139.224]) by www62.your-server.de with esmtpsa (TLSv1.2:DHE-RSA-AES256-GCM-SHA384:256) (Exim 4.89_1) (envelope-from ) id 1jtJ0Y-0000NY-HT; Thu, 09 Jul 2020 00:57:42 +0200 Received: from [178.196.57.75] (helo=pc-9.home) by sslproxy01.your-server.de with esmtpsa (TLSv1.3:TLS_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1jtJ0Y-000KiM-8i; Thu, 09 Jul 2020 00:57:42 +0200 Subject: Re: [PATCH bpf-next V3 0/2] BPF selftests test runner 'test_progs' use proper shell exit codes To: Jesper Dangaard Brouer , bpf@vger.kernel.org, Andrii Nakryiko Cc: Hangbin Liu , Daniel Borkmann , Alexei Starovoitov , vkabatov@redhat.com, jbenc@redhat.com, yhs@fb.com, kafai@fb.com, netdev@vger.kernel.org, linux-kernel@vger.kernel.org References: <159410590190.1093222.8436994742373578091.stgit@firesoul> From: Daniel Borkmann Message-ID: Date: Thu, 9 Jul 2020 00:57:41 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.7.2 MIME-Version: 1.0 In-Reply-To: <159410590190.1093222.8436994742373578091.stgit@firesoul> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 7bit X-Authenticated-Sender: daniel@iogearbox.net X-Virus-Scanned: Clear (ClamAV 0.102.3/25867/Wed Jul 8 15:50:39 2020) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 7/7/20 9:12 AM, Jesper Dangaard Brouer wrote: > This patchset makes it easier to use test_progs from shell scripts, by using > proper shell exit codes. The process's exit status should be a number > between 0 and 255 as defined in man exit(3) else it will be masked to comply. > > Shell exit codes used by programs should be below 127. As 127 and above are > used for indicating signals. E.g. 139 means 11=SIGSEGV $((139 & 127))=11. > POSIX defines in man wait(3p) signal check if WIFSIGNALED(STATUS) and > WTERMSIG(139)=11. (Hint: cmd 'kill -l' list signals and their numbers). > > Using Segmentation fault as an example, as these have happened before with > different tests (that are part of test_progs). CI people writing these > shell-scripts could pickup these hints and report them, if that makes sense. > > --- > > Jesper Dangaard Brouer (2): > selftests/bpf: test_progs use another shell exit on non-actions > selftests/bpf: test_progs avoid minus shell exit codes Applied, thanks!