From nobody Sun Feb 8 05:07:29 2026 Received: from mail-ej1-f73.google.com (mail-ej1-f73.google.com [209.85.218.73]) (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 B9CDA33B6D1 for ; Mon, 5 Jan 2026 12:43:10 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.218.73 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1767616993; cv=none; b=WGuv7qayGBvlU0Tu79BBo82ndeDLqEpFvwqeiDh+QljEuWFd/BpJ3tfcrWPRPx08oAhcKbtW3UKpCPrF8gtoZJR6vdxlsoKrsm6jW4pGaErerqEMpzwKO/Cz0y/H+VD8T1lqEyJRrC6U0rkrvyGTODS6f+Kx6xn9dLUonIEioho= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1767616993; c=relaxed/simple; bh=eIFTMJvvIG8WnTx/bh2M+JnarWwYg5CBU8VbbqLKFuw=; h=Date:In-Reply-To:Mime-Version:References:Message-ID:Subject:From: To:Cc:Content-Type; b=gJhz6jVWnERJ1jq3NYEIn+u94RvMYvbksnGSff2qJNUS8GoCJWOvArTf1KjjEEGqzccvnDMXZBgXvhmCwo97HIFV/i6s/w7inkU2sMcX3sNs5ho3elKteb/uauHIYnknluiQ+KTbf2NKAl4xuDfsgH/cZFVo2Ft6K7lwBxw/1hc= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=google.com; spf=pass smtp.mailfrom=flex--aliceryhl.bounces.google.com; dkim=pass (2048-bit key) header.d=google.com header.i=@google.com header.b=VfNY4SqI; arc=none smtp.client-ip=209.85.218.73 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=google.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=flex--aliceryhl.bounces.google.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=google.com header.i=@google.com header.b="VfNY4SqI" Received: by mail-ej1-f73.google.com with SMTP id a640c23a62f3a-b7d28772a67so1390134866b.1 for ; Mon, 05 Jan 2026 04:43:10 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20230601; t=1767616989; x=1768221789; darn=vger.kernel.org; h=cc:to:from:subject:message-id:references:mime-version:in-reply-to :date:from:to:cc:subject:date:message-id:reply-to; bh=vZ1w17uWB1ETJtgqP9MglCAj+wjV3dPqqThIMVoGXnk=; b=VfNY4SqIudjD8r5SHcdfQOJlEWrz65z/QqXgOhguAbqv9ki/0Wcd4Qc3doXc+zGS47 zpnSVjtrc8MSHDzmhkk6CbtFnqroGYcebxKpQM6oN0VpM5124rnpiaRtygQf6/jsRZri RHcuv/IuvFuHsmb2PDhFiI6GZPNvhcSJD2mjJpm9fkRkFaxxksVw+l9pgP++2YMRgbzM 2Zwh7tsogtK6BWjM4tnWR0cEastWVBGHYN7MSRUod44f2gU7mt4UoFojznZHrYW7fiiy n7lNYMmWyngg3PmjYUztKOxe5uEWMr4PV9perBo4VUb0o4MnaKV9LEHehecVi5J3SiMf w3Wg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1767616989; x=1768221789; h=cc:to:from:subject:message-id:references:mime-version:in-reply-to :date:x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=vZ1w17uWB1ETJtgqP9MglCAj+wjV3dPqqThIMVoGXnk=; b=EaIijD4Jhl00O5skPrr+DuKEj2fid64adrDzHEd1o9m50xfonPsQmuRs3HZLbUp/W7 juz8U29Df89OODtYhf/cT3FA3bLQiIOu43LaHOXgT3/f4bJ4+xwEfaVjI0AajwykT0+3 t714xj++7R023jD23DH68TowtusWt9Rkmt8a6OdYgy9cBn51wxgwfMcbRMZNckarT98P 67v/DlkTf7XqxlomhPfi5pF0anc38R6visVkGk3rosz0okj9rQuJrbs+81PCK+EGOtUs p/rbNOhywtq27lfB7kDJ0wYSSo9HS7jhIVtVhJXFAsJRQH50AXauBSrFBONKaTbg3/2l qA3w== X-Gm-Message-State: AOJu0YxG3kRS4zBvaVP7HMSqdEY6MQxKrjTqG+DncYn2AYW16c0UkgPd 4Obx8qdzMd2eusZLjxJkV47F0fT6aLJ9IHj8pTS9hf8WngHUWKJfIsrninGuj1NNzeWFfgEgC8d uNj4xcpNHASZGFf8r9Q== X-Google-Smtp-Source: AGHT+IEfs7Tj1awy8z2piQbyZvKQSdOb3vhusJoHwVFvSNLuo27yZEsGUMNqh4ty+o1Y1P3euU/d7I+UrdqSx6w= X-Received: from ejcrg14.prod.google.com ([2002:a17:907:6b8e:b0:b79:f6f7:595d]) (user=aliceryhl job=prod-delivery.src-stubby-dispatcher) by 2002:a17:907:6eac:b0:b73:6b24:14a0 with SMTP id a640c23a62f3a-b8036f10e30mr5119035066b.18.1767616989208; Mon, 05 Jan 2026 04:43:09 -0800 (PST) Date: Mon, 05 Jan 2026 12:42:35 +0000 In-Reply-To: <20260105-define-rust-helper-v2-0-51da5f454a67@google.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: Mime-Version: 1.0 References: <20260105-define-rust-helper-v2-0-51da5f454a67@google.com> X-Developer-Key: i=aliceryhl@google.com; a=openpgp; fpr=49F6C1FAA74960F43A5B86A1EE7A392FDE96209F X-Developer-Signature: v=1; a=openpgp-sha256; l=2084; i=aliceryhl@google.com; h=from:subject:message-id; bh=eIFTMJvvIG8WnTx/bh2M+JnarWwYg5CBU8VbbqLKFuw=; b=owEBbQKS/ZANAwAKAQRYvu5YxjlGAcsmYgBpW7G9V1HIWnFSpQ0uxJw7pLlxRqHWjqHEfsI2P GM2lc+y/tqJAjMEAAEKAB0WIQSDkqKUTWQHCvFIvbIEWL7uWMY5RgUCaVuxvQAKCRAEWL7uWMY5 Rv/wD/9dlO73AM8tUctSY75Ii5NfrQqeu2TgC61ONBspIlSFpXHlQ8Q+fesBtpDtlHTf9wa8lnC k81INDC1kRFs+SEutxbUq/l5EG9+q/Q2IVL7gTk4lNdIl7FLw3O9NdeAoB/sJbZicS0KkkFkpVk CnTJuJ/+xVuXQSqSk3IJeoCOP9sdyzPr5RjWJKYdsBXkB1h8/fTeQBhH2bc07fHyUr6gj7F3Usr ANy5bC8k7vmQ4tpj6YHQy0RljOydMVwT1l2riWXXOdoD2/AOC7ZJiARjneTxAJs2+jK9lyEs2/G CbVVUbQBYc7yeLxRmMWQ5Sb3WjCDgmr5wTeGUpwPJUfLVBaZTXo6yOMmp5gtaiYAWRQabMx5SnR Fm9zca8yl3biGM3bpQsc8+Nv6J0jtVIq0TObCwHjqcgsJEvvLU7CzhBBvIqX9hopzg/D67r7cM4 +b3Dn4vAdMhEDehMjqZ4YR9Q3R6uOMeMt5ixDBW10ozYAAb6D9c3r355ogLeWChflTXlDemVssY jNBlb5eXlyEB99uJ06KMBybjTRralEW5+9056vJ1lxep4kLA54JzkKjEUJ4+4x50PmLSt9VukJD MOgEGNmWQxL6e6obJfeWx+JThgdDjJ/DDEZ8xU94XE4ooXMougH1iXDFHvMpQhrE8bNLAIyENwo fX8xpOl8o9BAjNQ== X-Mailer: b4 0.14.2 Message-ID: <20260105-define-rust-helper-v2-22-51da5f454a67@google.com> Subject: [PATCH v2 22/27] rust: time: add __rust_helper to helpers From: Alice Ryhl To: rust-for-linux@vger.kernel.org Cc: linux-kernel@vger.kernel.org, Alice Ryhl , Boqun Feng , Gary Guo , Andreas Hindborg , FUJITA Tomonori , Frederic Weisbecker , Lyude Paul , Thomas Gleixner , Anna-Maria Behnsen , John Stultz , Stephen Boyd , Fiona Behrens Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable This is needed to inline these helpers into Rust code. Reviewed-by: Boqun Feng Reviewed-by: Gary Guo Signed-off-by: Alice Ryhl --- Cc: Andreas Hindborg Cc: Boqun Feng Cc: FUJITA Tomonori Cc: Frederic Weisbecker Cc: Lyude Paul Cc: Thomas Gleixner Cc: Anna-Maria Behnsen Cc: John Stultz Cc: Stephen Boyd Cc: Fiona Behrens Cc: Gary Guo --- rust/helpers/time.c | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/rust/helpers/time.c b/rust/helpers/time.c index 67a36ccc3ec48379bc5983e58b1567947c5dcace..32f4959704939c0691bca03bad4= 8b95becf21d10 100644 --- a/rust/helpers/time.c +++ b/rust/helpers/time.c @@ -4,37 +4,37 @@ #include #include =20 -void rust_helper_fsleep(unsigned long usecs) +__rust_helper void rust_helper_fsleep(unsigned long usecs) { fsleep(usecs); } =20 -ktime_t rust_helper_ktime_get_real(void) +__rust_helper ktime_t rust_helper_ktime_get_real(void) { return ktime_get_real(); } =20 -ktime_t rust_helper_ktime_get_boottime(void) +__rust_helper ktime_t rust_helper_ktime_get_boottime(void) { return ktime_get_boottime(); } =20 -ktime_t rust_helper_ktime_get_clocktai(void) +__rust_helper ktime_t rust_helper_ktime_get_clocktai(void) { return ktime_get_clocktai(); } =20 -s64 rust_helper_ktime_to_us(const ktime_t kt) +__rust_helper s64 rust_helper_ktime_to_us(const ktime_t kt) { return ktime_to_us(kt); } =20 -s64 rust_helper_ktime_to_ms(const ktime_t kt) +__rust_helper s64 rust_helper_ktime_to_ms(const ktime_t kt) { return ktime_to_ms(kt); } =20 -void rust_helper_udelay(unsigned long usec) +__rust_helper void rust_helper_udelay(unsigned long usec) { udelay(usec); } --=20 2.52.0.351.gbe84eed79e-goog