Received: by 2002:a05:7412:5112:b0:fa:6e18:a558 with SMTP id fm18csp575594rdb; Tue, 23 Jan 2024 08:11:48 -0800 (PST) X-Google-Smtp-Source: AGHT+IF1M2KtXC+nBb/q1qcxlwlF1CUsiYxXA/hnFxfnPtN6gSBvGA/BiwQ2D2qyd1d8qYRcrNHU X-Received: by 2002:a05:6214:c2e:b0:680:ffed:c1bf with SMTP id a14-20020a0562140c2e00b00680ffedc1bfmr1257263qvd.54.1706026308095; Tue, 23 Jan 2024 08:11:48 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1706026308; cv=pass; d=google.com; s=arc-20160816; b=sIXg9mQynxByW5Hg9oC2YBjoxKrEUHQ+/y+i0iN1fiqrQGZgDmwTwicvBGhxp5Zh6a Zowo2BbRZw2N1vJTjpJcddlmo18lGOB2Ie0CpF9+Foa5VXCd62DnfrsJK6SrJJj0BmEv QlUoyspFDraJ1s8p5o3LPNvPe6YbTKkW2yVJFxIZOsU8F4236YVv6flTafL7lV/CB/VO lZHm6d4nHV3TgB3XJtXbk9UMrezoBSzvQhdNg/vKmb3+56Xo7UHjWoYWkdS4ZYLDg8ZI OR/kH3dk0LV7kf6XwFVIFGrSQBJicrBRag92eeHL+ZsuzRK6BMysTBZH3FL1NgBn2Ffj zPaw== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=ui-outboundreport:content-transfer-encoding:mime-version :list-unsubscribe:list-subscribe:list-id:precedence:references :in-reply-to:message-id:date:subject:cc:to:from; bh=lcAeFLRu5pXHLe2pLZr+LMahuPV/eSA+ONl17jIjPck=; fh=BZI9iWTaEf0O3fXVlcMygnOLgsZaFpsfuA9TcLqdYG4=; b=nrHYPLCFfx+2erdnIykc4FX2nnH86K80PTPB5M9vBX+NWeQ8d4z9+f1hkVu6yNPrCB d42tKK8vJVjyJ0jZMYynmwz6k3Wl+sHQ5qPWd1t/4HGP/9A1htGna53zaB9fV22xfEsx klESSqzrwIWXk9Ttz4HlwtP7B1aEoqmOHkkTT8ngN6qLPXlP3V5CxdwOfSo2fThzAat5 fDCtlgbofhBqP2KCGx1GNHShrZaWC62g2Ink2hg0OTIiolUM7g9rx96bTKn9F8sql9kv vj4/X1Q7vqF5kV5Un8X/Wnnj8+BflLstPPUK0NAyBE59FdVZg7E0oo+TBNrBi7iXFWgS Daqg== ARC-Authentication-Results: i=2; mx.google.com; arc=pass (i=1 spf=pass spfdomain=valentinobst.de); spf=pass (google.com: domain of linux-kernel+bounces-35629-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) smtp.mailfrom="linux-kernel+bounces-35629-linux.lists.archive=gmail.com@vger.kernel.org" Return-Path: Received: from ny.mirrors.kernel.org (ny.mirrors.kernel.org. [147.75.199.223]) by mx.google.com with ESMTPS id w7-20020a0ce107000000b0067f80b3353bsi8187187qvk.247.2024.01.23.08.11.47 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 23 Jan 2024 08:11:48 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-35629-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) client-ip=147.75.199.223; Authentication-Results: mx.google.com; arc=pass (i=1 spf=pass spfdomain=valentinobst.de); spf=pass (google.com: domain of linux-kernel+bounces-35629-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) smtp.mailfrom="linux-kernel+bounces-35629-linux.lists.archive=gmail.com@vger.kernel.org" Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ny.mirrors.kernel.org (Postfix) with ESMTPS id B2A951C272B8 for ; Tue, 23 Jan 2024 16:11:15 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id DAC886BB25; Tue, 23 Jan 2024 16:10:05 +0000 (UTC) Received: from mout.kundenserver.de (mout.kundenserver.de [212.227.126.130]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 7B04763511; Tue, 23 Jan 2024 16:10:03 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=212.227.126.130 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1706026205; cv=none; b=T0lC3V8FWvE7kuSlwJG7/ki+EuFt/L1YL9j9NmYQV0iJExpvZJOVa6aLlsxBc0ds6OAQNAfBGS4++pE2NLHtQr03dx5uzTQ6pkmrIcmRe4VF8lK0TDoGblYfTAV6yOqfs25gKzqbVBQiQIgWG1qQpmhX8QZ6eXVt7G8m4qiE8/o= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1706026205; c=relaxed/simple; bh=vqGse0J/VzdCW0jsSamCryiiEi2OKG6PX8sSBlLVGaU=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=SoPp86GDmYKjaCbYDHVR1yO7rUCX4T1LVw2pgFi/NlfYYVl+oS1aR/ey7zXjGjvv4mYBizGaAXh9C35MewR3uRV/Gzsr78o6DKOSKmJ0XDwQvl4jK0YOUoIdk3xpNp/RWuTcCCxU+NuKhcBYj9H5zT3yd6yJLpcWcdpDoPS9Lho= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=valentinobst.de; spf=pass smtp.mailfrom=valentinobst.de; arc=none smtp.client-ip=212.227.126.130 Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=valentinobst.de Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=valentinobst.de Received: from localhost.localdomain ([95.223.130.98]) by mrelayeu.kundenserver.de (mreue010 [213.165.67.97]) with ESMTPSA (Nemesis) id 1Md6hP-1qs9aB0OwN-00aD4z; Tue, 23 Jan 2024 17:09:56 +0100 From: Valentin Obst To: Miguel Ojeda , Alex Gaynor , Wedson Almeida Filho Cc: rust-for-linux@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH v2 09/12] rust: kernel: add blank lines in front of code blocks Date: Tue, 23 Jan 2024 17:09:55 +0100 Message-ID: <20240123160955.125365-1-kernel@valentinobst.de> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20240123150112.124084-1-kernel@valentinobst.de> References: <20240123150112.124084-1-kernel@valentinobst.de> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Provags-ID: V03:K1:NnxvmERd/P/mfjrEmRtmikwaiBnqYIQP8fv4hY0wnbrU2U6aaJ2 XeVs6Jra1qtnsUF9guX0jtVD4tCz0lZtJkauGQKHisA/Kv5YUMxatR3hpPcXGIaE2WjIBLH SEuP9gTIvXhPJBG2Zdbb4hDJJndQjFgoc1cY/XlIbBP8q7EH1jZC1XCjjyLCJ5hQ66FzRy7 VCyqMIm4heY1WaLDx7Viw== X-Spam-Flag: NO UI-OutboundReport: notjunk:1;M01:P0:uPLII7ESCc0=;r6j2HXtUl2O7ze2zRdnyNNvBgeh bD/f+S5Ve3pvxPJqztr0eq9eiZOBdnUl70OM5aGuH8eN0Pk1GPSPssBthqfzxVboqQWDGpM1K kxeErRQRHAtJKT4PDnLqfRPkVeztkon7pi3bes1wsMyPb9i+8XxHu4PZ45+p8p+jIXAxT+kBt 2U/+GsisnVNK0uYruAiIRn3SveTj/DEQP0qJ5OSBKbHmXmYqPA2rJOqxf0VbsPZ21LCG1facU XtnfmPkOgOSr1HYNADJviH4d/3FA/0tq6LMaFEWdxD30ODTr/PnPY0ulCl9Oyl9+znTIE16+H y53QgZAeoYsmaiQzcFeKCVlrPfEHio6LrL9gw6zsWYtL4DQjfFGV9rAbrMF8r9j8DLiK7DZ+1 OvZk8nPv7/Nmn02SZq5WEVp1o4hsjF7nW5g6OKMjSobySqrkeiqyRVNYsrYxilzURONxeG9nd i6D4jCX3R/Qw1XrMPTudc6zLSDVxA84FpmxmZSivuVCDEUY3hMub9Ln5eZuRrrefXcYANMdRs HNgKxgtl+hcG5Irgn0k5xQIKfaAXMpbXmQ7/jZiCc7PRc7DYaTAAGwcycJk3EOCKUIPKRDGdO 3osoFu/qC87qNpZMXKNf8MNnVTTCpbmyY1kIb9G4Vx+qIt5B1Xntw3o95BtNeHOQTFaUx0H65 cAU4XzZjNAjKOL8DyA8DpGB0wHeUvMeIAlaDiqeoIvNvNpLI90RRfGSz8FQ62Q+sZwK7wd/nh 2klyLU4mrlsabdvC+h8YnCANKZZ8/3N1BuEk8nSOoKfxtjRY0DiEyDLAY8BG17VSBPCaIviyM KfThMfH52bON5lrs5WHkJnEWlnaAWxZXmLebAC855Fd+5mOhKQ/KOxkiSzcqesHRRSOaa2Z/F ifn72iHbHP1BSUA== Throughout the code base, blank lines are used before starting a code block. Adapt outliers to improve consistency within the kernel crate. Signed-off-by: Valentin Obst Reviewed-by: Trevor Gross Reviewed-by: Martin Rodriguez Reboredo --- rust/kernel/types.rs | 3 +++ 1 file changed, 3 insertions(+) diff --git a/rust/kernel/types.rs b/rust/kernel/types.rs index fdb778e65d79..8aabe348b194 100644 --- a/rust/kernel/types.rs +++ b/rust/kernel/types.rs @@ -90,6 +90,7 @@ unsafe fn from_foreign(_: *const core::ffi::c_void) -> Self {} /// /// In the example below, we have multiple exit paths and we want to log regardless of which one is /// taken: +/// /// ``` /// # use kernel::types::ScopeGuard; /// fn example1(arg: bool) { @@ -108,6 +109,7 @@ unsafe fn from_foreign(_: *const core::ffi::c_void) -> Self {} /// /// In the example below, we want to log the same message on all early exits but a different one on /// the main exit path: +/// /// ``` /// # use kernel::types::ScopeGuard; /// fn example2(arg: bool) { @@ -129,6 +131,7 @@ unsafe fn from_foreign(_: *const core::ffi::c_void) -> Self {} /// /// In the example below, we need a mutable object (the vector) to be accessible within the log /// function, so we wrap it in the [`ScopeGuard`]: +/// /// ``` /// # use kernel::types::ScopeGuard; /// fn example3(arg: bool) -> Result { -- 2.43.0