lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <871pqpn3su.fsf@kernel.org>
Date: Wed, 09 Jul 2025 10:53:21 +0200
From: Andreas Hindborg <a.hindborg@...nel.org>
To: "Benno Lossin" <lossin@...nel.org>
Cc: "Miguel Ojeda" <miguel.ojeda.sandonis@...il.com>,  "Oliver Mangold"
 <oliver.mangold@...me>,  "Miguel Ojeda" <ojeda@...nel.org>,  "Alex Gaynor"
 <alex.gaynor@...il.com>,  "Boqun Feng" <boqun.feng@...il.com>,  "Gary Guo"
 <gary@...yguo.net>,  Björn Roy Baron
 <bjorn3_gh@...tonmail.com>,  "Alice
 Ryhl" <aliceryhl@...gle.com>,  "Trevor Gross" <tmgross@...ch.edu>,  "Asahi
 Lina" <lina+kernel@...hilina.net>,  <rust-for-linux@...r.kernel.org>,
  <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH v11 1/4] rust: types: Add Ownable/Owned types

"Benno Lossin" <lossin@...nel.org> writes:

> On Tue Jul 8, 2025 at 8:30 PM CEST, Andreas Hindborg wrote:
>> "Benno Lossin" <lossin@...nel.org> writes:
>>
>>> On Tue Jul 8, 2025 at 12:16 PM CEST, Miguel Ojeda wrote:
>>>> On Tue, Jul 8, 2025 at 11:57 AM Oliver Mangold <oliver.mangold@...me> wrote:
>>>>>
>>>>> Note, though, that I already moved it from types.rs to types/ownable.rs on
>>>>> request. It seems to me different people here have different ideas where it
>>>>> should be placed. I feel now, that it would make sense to come to an
>>>>> agreement between the interested parties about where it should finally be
>>>>> placed, before I move it again. Could I ask that we settle that question
>>>>> once and for all before my next revision?
>>>>
>>>> Yeah, if there is a disagreement with something said previously, then
>>>> it should be resolved before starting to ping-pong between approaches
>>>> with more and more patch versions. Reviewers can forget or they may
>>>> not have read an earlier comment, but you did the right thing
>>>> mentioning there is such a conflict in opinions.
>>>
>>> Yeah, I checked and that was Andreas on v9. @Andreas what do you think?
>>>
>>> I think we should just get rid of `types.rs` and split it into:
>>>
>>> * `opaque.rs`
>>> * `foreign.rs`
>>> * `scope_guard.rs` (this might need a better name)
>>>
>>> `Either` can just be removed entirely, `AlwaysRefcounted` & `ARef`
>>> should be in the `sync` module (I already created an issue for this) as
>>> well as `NotThreadSafe` (or we could create a `marker` module for that).
>>> Thoughts?
>>
>> Sounds good. I just wanted to prevent us from cramming everything into
>> types.rs.
>
> Yeah me too :)
>
>> But we should probably move `Owned` into `sync` with `ARef` et. al.,
>> right?
>
> I don't think it fits into `sync`... It's more like a `Box` and could
> very well store something that is `!Send` & `!Sync`.

Good point. My primary use case is `OwnableRefCounted`. Where do you
want tput that? It is strongly tied to `Ownable` and `Owned`, but
revolving around refcounts.


Best regards,
Andreas Hindborg




Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ