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: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <ZvPDbFatkelji1FM@archie.me>
Date: Wed, 25 Sep 2024 15:01:48 +0700
From: Bagas Sanjaya <bagasdotme@...il.com>
To: Sebastian Fricke <sebastian.fricke@...labora.com>,
	Jonathan Corbet <corbet@....net>
Cc: linux-doc@...r.kernel.org, linux-kernel@...r.kernel.org,
	linux-media@...r.kernel.org, laurent.pinchart@...asonboard.com,
	hverkuil-cisco@...all.nl, mauro.chehab@...ux.intel.com,
	kernel@...labora.com, bob.beckett@...labora.com,
	nicolas.dufresne@...labora.com
Subject: Re: [PATCH RFC v2 2/3] docs: Add guides section for debugging

On Tue, Sep 24, 2024 at 10:45:58AM +0200, Sebastian Fricke wrote:
> +This document serves as a general starting point and lookup for debugging device
> +drivers.
> +While this guide focuses on debugging that requires re-compiling the
> +module/kernel, the `userspace-debugging-guide <userspace_debugging_guide.html>`__
> +will guide you through tools like dynamic debug, ftrace and other tools useful
> +for debugging issues and behavior.
> +For general debugging advice, see `general-debugging-guide <index.html>`__.

You can use :doc: syntax for linking to other docs with custom anchor text,
like:

```
:doc:`userspace debugging guide <userspace_debugging_guide>`
```

(note the file suffix omission).

Better yet, specify the full doc path (e.g.
`Documentation/debugging/userspace_debugging_guide.rst`) and Sphinx will
generate the anchor text with target doc's title.

> +====================================================
> +General debugging advice for Linux Kernel developers
> +====================================================
> +
> +.. toctree::
> +   :maxdepth: 1
> +
> +   driver_development_debugging_guide
> +   userspace_debugging_guide
> +
> +.. only::  subproject and html
> +
> +   Indices
> +   =======
> +
> +   * :ref:`genindex`
> +
> +General debugging advice
> +========================

Please split general debugging advice into its own doc (e.g. at
general-advice.rst). Most other docs have index.rst only for toctree
listing.

> +**When should you use this over** `Ftrace`_ **?**
> +
> +- When the code contains one of the :ref:`valid print statements <valid_dyndbg_prints_>`_ or when you have added multiple pr_debug() statements during development

Sphinx complains about stray underscores:

Documentation/debugging/userspace_debugging_guide.rst:54: WARNING: Mismatch: both interpreted text role prefix and reference suffix.

I have to trim them:

---- >8 ----
diff --git a/Documentation/debugging/userspace_debugging_guide.rst b/Documentation/debugging/userspace_debugging_guide.rst
index 4d269a9ef9..eac459e30f 100644
--- a/Documentation/debugging/userspace_debugging_guide.rst
+++ b/Documentation/debugging/userspace_debugging_guide.rst
@@ -51,7 +51,7 @@ Here is one example, that enables all available `pr_debug()`'s within the file:
 
 **When should you use this over** `Ftrace`_ **?**
 
-- When the code contains one of the :ref:`valid print statements <valid_dyndbg_prints_>`_ or when you have added multiple pr_debug() statements during development
+- When the code contains one of the :ref:`valid print statements <valid_dyndbg_prints>` or when you have added multiple pr_debug() statements during development
 - When timing is not an issue, meaning if multiple `pr_debug()` statements in the code won't cause delays
 - When you care more about receiving specific log messages than tracing the pattern of how a function is called
 
Thanks.

-- 
An old man doll... just what I always wanted! - Clara

Download attachment "signature.asc" of type "application/pgp-signature" (229 bytes)

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ