From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail-qk1-f171.google.com (mail-qk1-f171.google.com [209.85.222.171]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id EA3E826F46F for ; Mon, 17 Nov 2025 21:34:47 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.222.171 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1763415289; cv=none; b=tHhybpLCHU1bRlDQY9q23cn9pxHhwRXvJPtp/vv7TSgf/39fN2NXia+CuU/5ESkBu4nvKvkbI8LjHYJN8m0lhzMQfySs5bOBDQIdnvGPmGQ5O76355cbi6Qxut1cBpkQ6dAK3OCQu+ju2/rfMDYJsKq2WSP4WCOQVWYerYifNHM= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1763415289; c=relaxed/simple; bh=8frZ29pQdygHLKVHQSqfYr9ibQZgqY0m/janBIhxcQk=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=Bo76fRbJHsddmzlJsUWoZjml/20Zc/wG2W2ZMbmeq0mWdyRbV2ohendjLwIllHR+atEK1c0rabg2oZwm2DyTkMGODXFJKZvMPm8Q2YLbNQoHqciRt1hrwVknzeeS6yKk26nXrZftx62hkiLUxEilh7wVjWWyBw/Ok4kCbcQuYFo= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com; spf=pass smtp.mailfrom=gmail.com; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b=fDTe/s4M; arc=none smtp.client-ip=209.85.222.171 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="fDTe/s4M" Received: by mail-qk1-f171.google.com with SMTP id af79cd13be357-8a479c772cfso308700185a.0 for ; Mon, 17 Nov 2025 13:34:47 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1763415287; x=1764020087; darn=vger.kernel.org; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:feedback-id:from:to:cc:subject:date :message-id:reply-to; bh=RoPNV2GPzGsaRXkMxX5Nbnqg1qr8foGzTNgWC0QK78k=; b=fDTe/s4MvPjfZ1LfrzOxDMeyblVmyhOe5HttOXajuyHL9IjKLLQGc1LstB8yu/MoJm NJYC4yrX0MOi+8qqCCI+WOG4jDKSgpGbw4Q+nnIAlN2UDIjvGLiBhnAyrXhCCVE8meIM RqwN7ddwieWvewlngeJNPtKatVA4HbMO5fHvBp7xQkPvxF7OlBLI5uADwvyle1hazOtu 63J4336ubnbF46JdDqPrplD5CM+wF4vvVk9k7R5MDmYsFyyKwaXqX06creEkQWGk4jna ujCJu7fKSoAohGtBQI9SC53XcnBsd4kFCQFSzE+tdl2XOERb1qz2EUk8j+j1fMIUT48R fp6Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1763415287; x=1764020087; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:feedback-id:x-gm-gg:x-gm-message-state:from :to:cc:subject:date:message-id:reply-to; bh=RoPNV2GPzGsaRXkMxX5Nbnqg1qr8foGzTNgWC0QK78k=; b=iV9V1ue8KVV/dHcpU5KLpruj1gge77RahQiI2sx0oEboYq7hw96Y0RXR66nCqBPWDS c6VO+0qWxEpwSNRlo8EB6KTwSbkb3jLyovphgF/TS6on2tBa4W1hTkDTDuyqKL3nMl4T KKRNu7QThPQX8R3qjNGpzW4ZzEwqf7dk4E7Ma3zVqOrlzsUNrB7QxzZNU0pYsLqtGahn LWvaQ4v/4d9LcWKYsLtdP0gbJlGDIKyMPR8iW62X6Q0DGro8vinPKpe2xuztE3VRil6K wCZaNAry35bFeSldyJak/lLaPuy3Zw1MwoQeIFfSKY/PonI515FAaneaqLaSHiu9BriH t0/A== X-Forwarded-Encrypted: i=1; AJvYcCXNHcXnJvHijZ13zvJGPAvasY3w5rCTaAyVDY1V2srIVMFqiEe8I5ioexlU7BLDDLsw0g8hxtBhelw8kpA=@vger.kernel.org X-Gm-Message-State: AOJu0YzxnMAeWg23W/6iHhPI+NSTDSQ7gp/q8EHkWVAW4Yj50jV3Vj6E C72X0xlALTLv8VOjzIzRdM+dEKHemHyEt8bfPfqel9hBSd8rQ0+vRgfR X-Gm-Gg: ASbGncsVerI/0PUUSkHS8/KCkS7btxxkmyovJHZTrw5e3Yd6k0uQSMXN+EaSasg4/TX I7EGgZ7rZfXcCZ5/kDfiYLGGTDeM7iR0gJD9iCkx6NsM/WfEO69QBbUQ0RKCulGQP+wPCPUqJKg G2slc9brNe09brE+5xl0U4ZY9IB0ZAI1JIFtgt4FHnfnLaubuS0DnTWpJgYO3ns0TzGxvsRemNa OfENLnGEIrDgzgfLApS+lw5gEISLtI0qX9u9xXGpFkYHxFeCB9kP5kxO77O+2oPxYiHq2nW75+s VFqG/uy9HjEAC/Z5JClAnf25bk0e1wTBb3vlaMiNmd9iiatgu9BGfHmPS8izshM/z3Q74lXXt2a j4ALDD2jUS4S50rmXZQzJTgvZH11kKsjjz9qwF6ubHOZHj4lV/RQyqi9PKMnAlJaekKR3xGohDq fXNMyWxDyUjppv8tSbKL/4y6cvRrf71YZp8dDuSAHV4LRhIarwreziRxZ/NSMZtuRkTEFRYaniq sygpqcZWebNRdUTnMUl2ZK9xg== X-Google-Smtp-Source: AGHT+IFECynbkvL4FMRmGCuZmRY0yMzTy3wQx+LA2SiuQQMsQOCq0mXHtzLJBXNtwXP9lEM/SkzAyA== X-Received: by 2002:a05:622a:14c6:b0:4c3:b7b0:3317 with SMTP id d75a77b69052e-4edf20f51cemr200167291cf.42.1763415286727; Mon, 17 Nov 2025 13:34:46 -0800 (PST) Received: from fauth-a2-smtp.messagingengine.com (fauth-a2-smtp.messagingengine.com. [103.168.172.201]) by smtp.gmail.com with ESMTPSA id d75a77b69052e-4ee02763778sm60690421cf.32.2025.11.17.13.34.45 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 17 Nov 2025 13:34:46 -0800 (PST) Received: from phl-compute-11.internal (phl-compute-11.internal [10.202.2.51]) by mailfauth.phl.internal (Postfix) with ESMTP id C8CE7F40080; Mon, 17 Nov 2025 16:34:45 -0500 (EST) Received: from phl-mailfrontend-01 ([10.202.2.162]) by phl-compute-11.internal (MEProxy); Mon, 17 Nov 2025 16:34:45 -0500 X-ME-Sender: X-ME-Received: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgeeffedrtdeggddvudelheehucetufdoteggodetrf dotffvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfurfetoffkrfgpnffqhgenuceu rghilhhouhhtmecufedttdenucesvcftvggtihhpihgvnhhtshculddquddttddmnecujf gurhepfffhvfevuffkfhggtggujgesthdtredttddtvdenucfhrhhomhepuehoqhhunhcu hfgvnhhguceosghoqhhunhdrfhgvnhhgsehgmhgrihhlrdgtohhmqeenucggtffrrghtth gvrhhnpeejtdekgfefteehffdtjeelffehkeehheeuveehuedugeetgfekleefjeefieei heenucffohhmrghinheptghouhhnthgvrhdrshhtohhrvgenucevlhhushhtvghrufhiii gvpedtnecurfgrrhgrmhepmhgrihhlfhhrohhmpegsohhquhhnodhmvghsmhhtphgruhht hhhpvghrshhonhgrlhhithihqdeiledvgeehtdeigedqudejjeekheehhedvqdgsohhquh hnrdhfvghngheppehgmhgrihhlrdgtohhmsehfihigmhgvrdhnrghmvgdpnhgspghrtghp thhtohepuddupdhmohguvgepshhmthhpohhuthdprhgtphhtthhopehsfhhrsegtrghnsg drrghuuhhgrdhorhhgrdgruhdprhgtphhtthhopehgrhgvgheskhhrohgrhhdrtghomhdp rhgtphhtthhopegurghkrheskhgvrhhnvghlrdhorhhgpdhrtghpthhtoheprhgrfhgrvg hlsehkvghrnhgvlhdrohhrghdprhgtphhtthhopehtghhlgieslhhinhhuthhrohhnihig rdguvgdprhgtphhtthhopehmihhnghhosehkvghrnhgvlhdrohhrghdprhgtphhtthhope hhphgrseiihihtohhrrdgtohhmpdhrtghpthhtohepphgvthgvrhiisehinhhfrhgruggv rggurdhorhhgpdhrtghpthhtoheplhhinhhugidqkhgvrhhnvghlsehvghgvrhdrkhgvrh hnvghlrdhorhhg X-ME-Proxy: Feedback-ID: iad51458e:Fastmail Received: by mail.messagingengine.com (Postfix) with ESMTPA; Mon, 17 Nov 2025 16:34:45 -0500 (EST) Date: Mon, 17 Nov 2025 13:34:44 -0800 From: Boqun Feng To: Stephen Rothwell Cc: Greg KH , Danilo Krummrich , "Rafael J. Wysocki" , Thomas Gleixner , Ingo Molnar , "H. Peter Anvin" , Peter Zijlstra , Linux Kernel Mailing List , Linux Next Mailing List Subject: Re: linux-next: manual merge of the driver-core tree with the tip tree Message-ID: References: <20251117163033.5fe01a29@canb.auug.org.au> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20251117163033.5fe01a29@canb.auug.org.au> On Mon, Nov 17, 2025 at 04:30:33PM +1100, Stephen Rothwell wrote: > Hi all, > > Today's linux-next merge of the driver-core tree got conflicts in: > > samples/rust/rust_debugfs.rs > samples/rust/rust_debugfs_scoped.rs > > between commit: > > f74cf399e02e ("rust: debugfs: Replace the usage of Rust native atomics") > > from the tip tree and commits: > > 0242623384c7 ("rust: driver: let probe() return impl PinInit") > 52af0c37964b ("samples: rust: debugfs: add example for blobs") > f656279afde1 ("samples: rust: debugfs_scoped: add example for blobs") > > from the driver-core tree. > > I fixed it up (I think - see below) and can carry the fix as necessary. Again, this fix looks good to me. Thanks! Regards, Boqun > This is now fixed as far as linux-next is concerned, but any non trivial > conflicts should be mentioned to your upstream maintainer when your tree > is submitted for merging. You may also want to consider cooperating > with the maintainer of the conflicting tree to minimise any particularly > complex conflicts. > > -- > Cheers, > Stephen Rothwell > > diff --cc samples/rust/rust_debugfs.rs > index 711faa07bece,c45b568d951b..000000000000 > --- a/samples/rust/rust_debugfs.rs > +++ b/samples/rust/rust_debugfs.rs > @@@ -36,8 -38,9 +36,9 @@@ use kernel::c_str > use kernel::debugfs::{Dir, File}; > use kernel::new_mutex; > use kernel::prelude::*; > + use kernel::sizes::*; > +use kernel::sync::atomic::{Atomic, Relaxed}; > use kernel::sync::Mutex; > - > use kernel::{acpi, device::Core, of, platform, str::CString, types::ARef}; > > kernel::module_platform_driver! { > @@@ -57,9 -60,13 +58,13 @@@ struct RustDebugFs > #[pin] > _compatible: File, > #[pin] > - counter: File, > + counter: File>, > #[pin] > inner: File>, > + #[pin] > + array_blob: File>, > + #[pin] > + vector_blob: File>>, > } > > #[derive(Debug)] > @@@ -104,16 -111,17 +109,17 @@@ impl platform::Driver for RustDebugFs > fn probe( > pdev: &platform::Device, > _info: Option<&Self::IdInfo>, > - ) -> Result>> { > - let result = KBox::try_pin_init(RustDebugFs::new(pdev), GFP_KERNEL)?; > - // We can still mutate fields through the files which are atomic or mutexed: > - result.counter.store(91, Relaxed); > - { > - let mut guard = result.inner.lock(); > - guard.x = guard.y; > - guard.y = 42; > - } > - Ok(result) > + ) -> impl PinInit { > + RustDebugFs::new(pdev).pin_chain(|this| { > - this.counter.store(91, Ordering::Relaxed); > ++ this.counter.store(91, Relaxed); > + { > + let mut guard = this.inner.lock(); > + guard.x = guard.y; > + guard.y = 42; > + } > + > + Ok(()) > + }) > } > } > > diff --cc samples/rust/rust_debugfs_scoped.rs > index 9f0ec5f24cda,c80312cf168d..000000000000 > --- a/samples/rust/rust_debugfs_scoped.rs > +++ b/samples/rust/rust_debugfs_scoped.rs > @@@ -6,9 -6,10 +6,10 @@@ > //! `Scope::dir` to create a variety of files without the need to separately > //! track them all. > > -use core::sync::atomic::AtomicUsize; > use kernel::debugfs::{Dir, Scope}; > use kernel::prelude::*; > + use kernel::sizes::*; > +use kernel::sync::atomic::Atomic; > use kernel::sync::Mutex; > use kernel::{c_str, new_mutex, str::CString}; > > @@@ -109,7 -114,8 +114,8 @@@ impl ModuleData > > struct DeviceData { > name: CString, > - nums: KVec, > + nums: KVec>, > + blob: Pin>>, > } > > fn init_control(base_dir: &Dir, dyn_dirs: Dir) -> impl PinInit> + '_ {