Received: by 2002:a05:6358:700f:b0:131:369:b2a3 with SMTP id 15csp1993825rwo; Thu, 3 Aug 2023 03:10:47 -0700 (PDT) X-Google-Smtp-Source: AGHT+IELjY0c3Pdh5tx5w+fMVhwF0Vh8cLxx7kUPHmBalFD3LyYU44biG5B0bWqCw1QqRsQ0xEvV X-Received: by 2002:a17:903:2344:b0:1bc:3504:de35 with SMTP id c4-20020a170903234400b001bc3504de35mr4064334plh.62.1691057446706; Thu, 03 Aug 2023 03:10:46 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1691057446; cv=none; d=google.com; s=arc-20160816; b=l+tg2qSAi8ytRfVePxRpc11kTDx+SiwvJeS94cHqq5geKLi+vlvqsGgOnscpQPAr+4 acGDFMVIi9I78wVe/C7G8BMYwi+oV2NPVZD3yzUTq4BjJWx6z+EiNNpy53FwZ1c1zOGP zi696tZcmRYThNkxZ3A644S/Fs8o6b06W69+m1rDt0mk2zU79SVuWllCQ8DNgaJc9yPP xnEq9jgvkwteDabORZ5ZwWHQ2FUc+81gRHnVvctyo71BjyZ5M9UfPQw/m/ft+DYPJ13h QZsvctdbkaGWgCqeRWJOai2j0yLIbmBDEaGiChIOVQYtIh2YUMwPy1JH+OQ8PtwYt0UV GXrg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=eCGHB3OVxX8oKBCn/5KheI7o8Eqib5nZqv5FXr+nZ7A=; fh=NWEzFAZVRz25+ue9dsydvAiW929cQ8aKCXsE+drPkco=; b=S9sbnlJwpmAwJaXraP8Jmw7zpqJbG6JxfiJFY8Ws2L0Nsh99PVA8ZHGejkxua65o6y NufhzmqrxFkJ+oWpWrnkaNfblFg7erxBh78mBACUVKRvie7IkpunmG+vd/B4aGSuSWTy oVWnE+2hHz2dvitJfo/eYN6/pBLgCAbcOQDeDbreJv0QWKBrpxfcknae9otbl6iggUz3 44HyKehNuzflV8ozj36ZF0bSnvQVTmRlqRBHgSyjgsYDvTR7uuSm7J5MPLWFuNagA5/4 SC0n7lp9Rx8sLuhfq7hs+EZ8dyAOMPDHXHAsQtyu+PG5ZKa0oEOW4kc1NL2xRwyUXj0s hHKA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@umich.edu header.s=relay-2018-08-29 header.b=TTzt+6Ue; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=umich.edu Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id l6-20020a170902f68600b001bc1b018950si3706309plg.442.2023.08.03.03.10.09; Thu, 03 Aug 2023 03:10:46 -0700 (PDT) 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=@umich.edu header.s=relay-2018-08-29 header.b=TTzt+6Ue; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=umich.edu Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S235183AbjHCJgb (ORCPT + 99 others); Thu, 3 Aug 2023 05:36:31 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:34040 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235156AbjHCJfz (ORCPT ); Thu, 3 Aug 2023 05:35:55 -0400 Received: from keen-gwydion.relay-egress.a.mail.umich.edu (relay-egress-host.us-east-2.a.mail.umich.edu [18.217.159.240]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id AFD1F3A86; Thu, 3 Aug 2023 02:35:44 -0700 (PDT) Received: from malleable-ellyllon.authn-relay.a.mail.umich.edu (ip-10-0-72-197.us-east-2.compute.internal [10.0.72.197]) by keen-gwydion.relay-egress.a.mail.umich.edu with ESMTPS id 64CB74E7.31CF9656.4E62D228.70552; Thu, 03 Aug 2023 05:35:35 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=umich.edu; s=relay-2018-08-29; t=1691055333; bh=eCGHB3OVxX8oKBCn/5KheI7o8Eqib5nZqv5FXr+nZ7A=; h=From:To:Cc:Subject:Date:In-Reply-To:References; b=TTzt+6UeD2pXwcRAiDxIsUtrd6xhzYCWA7E0fhG95/0mbEhcPKAehiF86g9uhqaLs BQzTLvk8hzLtxeyMiP3l+N/bEk5+PESAsvk59Q6u8UzC+petFkAry0XbGogBj3me3Q +2533Qqqk36GziD7mOJSICbMyHkZSpkZrSaKfZm9cCXLGQPtbCjzZpOZZEt0SEka1W wcPA8kpPmuqWImw2BlGjh0I/+rKHgds/XfQmb7vsoBznvY46XRVSmpTG9RnKt0PUbv vZi9gw2JLO/oEgBprDm8x3o+e2aU0hNjXc/4sBJ8kb/gV5em+uSO3izE7Z7a25fkVg iCr8BrmV/qb+w== Authentication-Results: malleable-ellyllon.authn-relay.a.mail.umich.edu; iprev=permerror policy.iprev=68.32.216.219 (unknown); auth=pass smtp.auth=tmgross Received: from localhost.localdomain (unknown [68.32.216.219]) by malleable-ellyllon.authn-relay.a.mail.umich.edu with ESMTPSA id 64CB74E4.2CE0CA91.645E8B9.1340056; Thu, 03 Aug 2023 05:35:33 -0400 From: Trevor Gross To: Miguel Ojeda , Alex Gaynor , Wedson Almeida Filho Cc: Boqun Feng , Gary Guo , =?UTF-8?q?Bj=C3=B6rn=20Roy=20Baron?= , Benno Lossin , rust-for-linux@vger.kernel.org, linux-doc@vger.kernel.org, linux-kernel@vger.kernel.org, Trevor Gross Subject: [RFC PATCH 1/2] rust: bindings: generate API documentation for the 'bindings' crate Date: Thu, 3 Aug 2023 05:34:17 -0400 Message-Id: <20230803093418.51872-2-tmgross@umich.edu> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20230803093418.51872-1-tmgross@umich.edu> References: <20230803093418.51872-1-tmgross@umich.edu> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_BLOCKED, SPF_HELO_NONE,SPF_NONE,T_SCC_BODY_TEXT_LINE 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 The 'bindings' crate is currently not included in rustdoc output. Add this crate to documentation output to provide an easy reference when developing abstractions or inspecting Rust-C bindings. Signed-off-by: Trevor Gross --- rust/Makefile | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) diff --git a/rust/Makefile b/rust/Makefile index f7c9a6e54c85..b5ce57a50eb5 100644 --- a/rust/Makefile +++ b/rust/Makefile @@ -81,7 +81,7 @@ quiet_cmd_rustdoc = RUSTDOC $(if $(rustdoc_host),H, ) $< # command-like flags to solve the issue. Meanwhile, we use the non-custom case # and then retouch the generated files. rustdoc: rustdoc-core rustdoc-macros rustdoc-compiler_builtins \ - rustdoc-alloc rustdoc-kernel + rustdoc-alloc rustdoc-bindings rustdoc-kernel $(Q)cp $(srctree)/Documentation/images/logo.svg $(objtree)/$(obj)/doc $(Q)cp $(srctree)/Documentation/images/COPYING-logo $(objtree)/$(obj)/doc $(Q)find $(objtree)/$(obj)/doc -name '*.html' -type f -print0 | xargs -0 sed -Ei \ @@ -114,12 +114,20 @@ rustdoc-alloc: private rustc_target_flags = $(alloc-cfgs) \ rustdoc-alloc: $(src)/alloc/lib.rs rustdoc-core rustdoc-compiler_builtins FORCE $(call if_changed,rustdoc) +rustdoc-bindings: private rustc_target_flags = --extern alloc \ + --extern build_error --extern macros=$(objtree)/$(obj)/libmacros.so \ + --extern uapi +rustdoc-bindings: $(src)/bindings/lib.rs rustdoc-core rustdoc-macros \ + rustdoc-compiler_builtins rustdoc-alloc $(obj)/libmacros.so \ + $(obj)/bindings.o FORCE + $(call if_changed,rustdoc) + rustdoc-kernel: private rustc_target_flags = --extern alloc \ --extern build_error --extern macros=$(objtree)/$(obj)/libmacros.so \ --extern bindings --extern uapi rustdoc-kernel: $(src)/kernel/lib.rs rustdoc-core rustdoc-macros \ - rustdoc-compiler_builtins rustdoc-alloc $(obj)/libmacros.so \ - $(obj)/bindings.o FORCE + rustdoc-compiler_builtins rustdoc-alloc rustdoc-bindings \ + $(obj)/libmacros.so FORCE $(call if_changed,rustdoc) quiet_cmd_rustc_test_library = RUSTC TL $< -- 2.34.1