Received: by 2002:a05:6358:16cc:b0:ea:6187:17c9 with SMTP id r12csp8429964rwl; Tue, 10 Jan 2023 13:31:03 -0800 (PST) X-Google-Smtp-Source: AMrXdXu/xlW39Nw+wvl4oco84OKFvp3LYbs4YZh/rCydxOsuJLqaROr2x8i9FlDYfpx0fDPvDG5/ X-Received: by 2002:a17:906:4f14:b0:7c1:98e:ed20 with SMTP id t20-20020a1709064f1400b007c1098eed20mr56453336eju.35.1673386262975; Tue, 10 Jan 2023 13:31:02 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1673386262; cv=none; d=google.com; s=arc-20160816; b=AOpyXVA583b04fO/i4cXM4ndBKmTAhUZvAUi5LwITkwLIhji93u5WmXaztWqRNQyeS /1UDmTIZ4R+QykJiEVzxo5eCmo3bMvG36ZJiDolT4rTvxaph8iya28IVfsom4nzHW32d uxOMkNCx0pCC5FTinKddTpalX57L7X7nARS/3b7ux/VgH1LlbWEhCaEH7JQHDMEVJDVz tFNz+tGi559uVuuxQz2ZPDLe65gc79Mgs31HeFl34LvpT5WdeTgJRvhPSwMUU8FsVEjU ts2B81dL7n1IFqpTsLPS8dIjM6YptCWjXy0ov/+1OZwO3/qiTbnDmHkaUYJNyi4eHO5k eS/Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=LBYx7tyllNxxanNj4C/c3Rthmyngs458XvfvtfnV0JE=; b=DVxjmboru75VWFORBFisW/k4/S1oiBYSai7UFBAplZhO2LyVXiMnfGZvbM7JSxf+H+ Q/hr5XPVZLs1Cvbqhex5CUb0AoluXA24198YreFMpm0rYyXuWR6opVHpZtLPl3Vdr9xY QgD5YV9zKQ1sYlYb7qbzXJxvk7YvIHGRO18ApvqFjtQjPlPHJENg4JICUqkClfRt/gn9 Wvqm+cSlgKDjRM8hzzp5WvqIAEvPV2OMe1AH3dgOAQcvSOXvhrzPuqAk/VWjypgK5uLu +P+ZVljTpse9iES4WWoqcNttNIPgFXF+glg85GAvVH+z6E+W/esE4WGSdp1omT5tUJvl iS6A== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@infradead.org header.s=casper.20170209 header.b=ZwT07gRd; 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 Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id qw4-20020a1709066a0400b007c17efb64fcsi13834462ejc.639.2023.01.10.13.30.49; Tue, 10 Jan 2023 13:31:02 -0800 (PST) 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=casper.20170209 header.b=ZwT07gRd; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231596AbjAJVVN (ORCPT + 55 others); Tue, 10 Jan 2023 16:21:13 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:37402 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232465AbjAJVVH (ORCPT ); Tue, 10 Jan 2023 16:21:07 -0500 Received: from casper.infradead.org (casper.infradead.org [IPv6:2001:8b0:10b:1236::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id CD09C1AA09; Tue, 10 Jan 2023 13:21:01 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=casper.20170209; h=In-Reply-To:Content-Type:MIME-Version: References:Message-ID:Subject:Cc:To:From:Date:Sender:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description; bh=LBYx7tyllNxxanNj4C/c3Rthmyngs458XvfvtfnV0JE=; b=ZwT07gRdDTytos5AC5hgG5ugv8 6YuKG7mj6bEipP8Pkjdv/wbJsmWe9hmTgWTBaeHLlF+B7eUiL3DiYG6lZMSttgFVe+F/Pzk5eLGb3 bmOdYs5f7Nh104PnhauwddMe8X2ypx+b2puirEjXRrHLZjIlF8GyQkTHnPckiMOJvD6Lj3BmVNq1w +v5TDMOAfWS64Xofp/x9S78w7SRzo4Z0LfdWHYVueTtHOu5pwQjAd6gyitkVlflOIrTaV8bXUWylq meMHae66blHXjYBpk67QgZ/ARhIKEJshzvmDGE/hK/aKE5KMdgypmiT++yaJUXbKnitVRYGas2CCV HevjIrgw==; Received: from j130084.upc-j.chello.nl ([24.132.130.84] helo=noisy.programming.kicks-ass.net) by casper.infradead.org with esmtpsa (Exim 4.94.2 #2 (Red Hat Linux)) id 1pFM3L-003Xj6-IH; Tue, 10 Jan 2023 21:21:03 +0000 Received: from hirez.programming.kicks-ass.net (hirez.programming.kicks-ass.net [192.168.1.225]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits)) (Client did not present a certificate) by noisy.programming.kicks-ass.net (Postfix) with ESMTPS id 5FBC03001E5; Tue, 10 Jan 2023 22:20:50 +0100 (CET) Received: by hirez.programming.kicks-ass.net (Postfix, from userid 1000) id 418EE2C4CABC3; Tue, 10 Jan 2023 22:20:50 +0100 (CET) Date: Tue, 10 Jan 2023 22:20:50 +0100 From: Peter Zijlstra To: Boqun Feng Cc: Wedson Almeida Filho , rust-for-linux@vger.kernel.org, Miguel Ojeda , Alex Gaynor , Gary Guo , =?iso-8859-1?Q?Bj=F6rn?= Roy Baron , linux-kernel@vger.kernel.org, Will Deacon , Mark Rutland Subject: Re: [PATCH 1/7] rust: sync: add `Arc` for ref-counted allocations Message-ID: References: <20221228060346.352362-1-wedsonaf@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: X-Spam-Status: No, score=-4.4 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_MED,SPF_HELO_NONE, SPF_NONE 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 Tue, Jan 10, 2023 at 12:22:47PM -0800, Boqun Feng wrote: > First, I'd really appreciate it that Will, Peter or Mark can take a look > at the series and see if they are happy or not ;-) I only have 1 patch, and since I don't speak rust I have very limited feedback. Having to use out-of-line functions seems sub-optimal, but I suppose that's a limitation of the Rust-C bindings. Afaict this is like C++ shared_ptr<> and using refcount_t seems okay for that, not sure what else you're asking.