Received: by 2002:a05:6358:9144:b0:117:f937:c515 with SMTP id r4csp3633200rwr; Sun, 7 May 2023 16:41:14 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ4uRmlcNgcEF+5qdKxWhM9TECUiqqF9oNU8wmRz3gzVSI7Toyr0oeId8TEP3sSYRWHVxnRc X-Received: by 2002:a05:6a20:9183:b0:fc:8dfb:318b with SMTP id v3-20020a056a20918300b000fc8dfb318bmr11649932pzd.0.1683502874118; Sun, 07 May 2023 16:41:14 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1683502874; cv=none; d=google.com; s=arc-20160816; b=vIBgRD05O0pRp5c9NARKImxQyNupjgiOlFurkK9tACzcVIGddhZM71uOs0jxuo4Oz3 io6tzmWsxMwskFvhSgJE+Zs8pEbOXoLFj0MnQdwQC1W2P0q7+YY9wiz7e/bU5xjFpp9M Ostgjtl5zN8sQx6BvSk1CWu3aw68IY3FaOknj1f5LpqhmkDWmSmrss0/1GltlP6WRC/a 3CRQ/tCiCr0lzFqCa8oKL+VjzN7nWJalzGMIHO5ajV0aK3gArEH7c7C2UQXYgsihwiGg NGBB90qceNmqK1IGIaygB9Mr/3+9riVTE/mScwylQv8zdsRdYs0qwR50FGnEkH9XhLrd EsAg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:in-reply-to:content-disposition :mime-version:references:message-id:subject:cc:to:from:date :dkim-signature; bh=BUVBPdJNfX+NvARu2ntIXNIYA3Z9htVV8ADqSWHvC50=; b=Sy02eOkW5uzHb/KRKhL/Q+kUunQ3orRTbj3vOYT7KJGti/4CERhY9hfjbLoLifG/ZD zJseFfAZC0uk4vbcbBdiUMD7ha+93UwxTgYmxp3tehvWP2u81V9fvuSqDxOHuSzU/xNI M6msMY7dLn26n4kENHjFuXBe8cVanY8DqPsfsy6CzCzngnaaX12OHHH75Cg3lCVf+RtV Vf/tSbxSlv3q26c0D4dqRW3hS9l7Eg6Pk8E0ga4ktkcjRTtIBirEvir/Iu6wPbR74U3x bstfCb5q0mwOWtQAvlcF345bGeMeu7+PKQKvCq5vcQgZU48ScaVbwLDQv4R48EUtprDS DyMQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@infradead.org header.s=bombadil.20210309 header.b=n68XH7Z0; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id 4-20020a630704000000b005192d51325dsi7306877pgh.42.2023.05.07.16.40.59; Sun, 07 May 2023 16:41:14 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@infradead.org header.s=bombadil.20210309 header.b=n68XH7Z0; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229960AbjEGXbd (ORCPT + 99 others); Sun, 7 May 2023 19:31:33 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:48202 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229507AbjEGXbb (ORCPT ); Sun, 7 May 2023 19:31:31 -0400 Received: from bombadil.infradead.org (bombadil.infradead.org [IPv6:2607:7c80:54:3::133]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id E924886BE; Sun, 7 May 2023 16:31:30 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=bombadil.20210309; h=Sender:In-Reply-To:Content-Type: MIME-Version:References:Message-ID:Subject:Cc:To:From:Date:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description; bh=BUVBPdJNfX+NvARu2ntIXNIYA3Z9htVV8ADqSWHvC50=; b=n68XH7Z0kRUMjXqTxz0GjNZgA2 o9gGHcpt9lf7+QviupkjuyWpJehlLY+V49Jl6wNx6GGXr4ysabnRbJ5Bs2hLB4dEwORnPQ29JbnZW kjCmris7SBDSp9K+n1oKXKgofxfK1LQ63ShxKPV35r87w7/2pzOp/luzgACPW8xXEcvofRaDo8lis rUP3woe7e8xfiz40u6LQnVp1+Eowe9aXxS2r57nJnoPyKuDTF9l3leAPhkdx4o94KyZRWHa/iKLxz 3eQr1AA3RPBf+nfLCsh1p8kvU5P49r/aI8wNS1KhCiOyt+fXLSIj2K2l0I3jEHpBfH+MOVy8iK2BP 2KLDrAjw==; Received: from mcgrof by bombadil.infradead.org with local (Exim 4.96 #2 (Red Hat Linux)) id 1pvnqX-00Gpd9-03; Sun, 07 May 2023 23:31:17 +0000 Date: Sun, 7 May 2023 16:31:16 -0700 From: Luis Chamberlain To: Andreas Hindborg Cc: Jens Axboe , Christoph Hellwig , Keith Busch , Damien Le Moal , Hannes Reinecke , lsf-pc@lists.linux-foundation.org, rust-for-linux@vger.kernel.org, linux-block@vger.kernel.org, Andreas Hindborg , Matthew Wilcox , Miguel Ojeda , Alex Gaynor , Wedson Almeida Filho , Boqun Feng , Gary Guo , =?iso-8859-1?Q?Bj=F6rn?= Roy Baron , Benno Lossin , open list , gost.dev@samsung.com Subject: Re: [RFC PATCH 00/11] Rust null block driver Message-ID: References: <20230503090708.2524310-1-nmi@metaspace.dk> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20230503090708.2524310-1-nmi@metaspace.dk> Sender: Luis Chamberlain X-Spam-Status: No, score=-4.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_EF,HEADER_FROM_DIFFERENT_DOMAINS, RCVD_IN_DNSWL_MED,SPF_HELO_NONE,SPF_NONE,T_SCC_BODY_TEXT_LINE, URIBL_BLOCKED autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, May 03, 2023 at 11:06:57AM +0200, Andreas Hindborg wrote: > The statistics presented in my previous message [1] show that the C null block > driver has had a significant amount of memory safety related problems in the > past. 41% of fixes merged for the C null block driver are fixes for memory > safety issues. This makes the null block driver a good candidate for rewriting > in Rust. Curious, how long does it take to do an analysis like this? Are there efforts to automate this a bit more? We have efforts to use machine learning to evaluate stable candidate patches, we probably should be able to qualify commits as fixing "memory safety", I figure. Because what I'd love to see is if we can could easily obtain similar statistics for arbitrary parts of the kernel. The easiest way to break this down might be by kconfig symbol for instance, and then based on that gather more information about subsystems. Then the rationale for considerating adopting rust bindings for certain areas of the kernel becomes a bit clearer. I figured some of this work has already been done, but I just haven't seen it yet. Luis