mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Wolfram Sang <wsa+renesas@sang-engineering.com>
To: Geert Uytterhoeven <geert@linux-m68k.org>
Cc: linux-renesas-soc@vger.kernel.org, linux-kernel@vger.kernel.org,
	Bjorn Andersson <andersson@kernel.org>,
	Baolin Wang <baolin.wang@linux.alibaba.com>,
	linux-remoteproc@vger.kernel.org
Subject: Re: [PATCH v7 2/3] hwspinlock: add list of locks to debugfs
Date: Wed, 16 Sep 2026 23:40:30 +0200	[thread overview]
Message-ID: <aqsMzXQ__BsWXUqH@shikoro> (raw)
In-Reply-To: <CAMuHMdVbYaUXiW11j+LKSuSaLLF2PRR2kAFsaj-ZGsx7nNjK-w@mail.gmail.com>

[-- Attachment #1: Type: text/plain, Size: 883 bytes --]

> > +static void *hwspin_lock_seq_next(struct seq_file *s, void *v, loff_t *ppos)
> > +{
> > +       /* Increase ppos here to avoid endless loops. Don't use xa_find_after() */
> 
> Do you mean xa_find_after() may loop forever?

Ehrm, it's been a while, I need to look this up. Which means the comment
is not explanationary enough :/

> > +static int hwspin_lock_seq_show(struct seq_file *s, void *v)
> > +{
> > +       struct hwspinlock *hwlock = v;
> > +       bool unused = xa_get_mark(&hwspinlocks, s->index, HWSPINLOCK_UNUSED);
> > +
> > +       seq_printf(s, "%4llu:\t%s\t%s\n", s->index, unused ? "free" : "in use",
> 
> For easier parsing the output, you may want to use a string without
> spaces, e.g. "busy", "active", ...

I get the idea, but haven't found a nice word yet. "Busy" could be
interpreted as "lock taken". I'll think some more about it.


[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

  parent reply	other threads:[~2026-09-16 21:40 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-09-12 19:14 [PATCH v7 0/3] hwspinlock: convert to XArray and add debug capabilities Wolfram Sang
2026-09-12 19:14 ` [PATCH v7 1/3] hwspinlock: Convert to XArray Wolfram Sang
2026-09-12 19:14 ` [PATCH v7 2/3] hwspinlock: add list of locks to debugfs Wolfram Sang
2026-09-16 14:01   ` Geert Uytterhoeven
2026-09-16 14:16     ` Geert Uytterhoeven
2026-09-16 21:38       ` Wolfram Sang
2026-09-17  7:40         ` Geert Uytterhoeven
2026-09-17  9:08           ` Wolfram Sang
2026-09-16 21:40     ` Wolfram Sang [this message]
2026-09-17  7:44       ` Geert Uytterhoeven
2026-09-17  9:21         ` Wolfram Sang
2026-09-12 19:14 ` [PATCH v7 3/3] hwspinlock: add low level debug capabilities Wolfram Sang
2026-09-16 14:11   ` Geert Uytterhoeven
2026-09-16 21:44     ` Wolfram Sang
2026-09-17  8:10       ` Geert Uytterhoeven
2026-09-17  9:10         ` Wolfram Sang

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=aqsMzXQ__BsWXUqH@shikoro \
    --to=wsa+renesas@sang-engineering.com \
    --cc=andersson@kernel.org \
    --cc=baolin.wang@linux.alibaba.com \
    --cc=geert@linux-m68k.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-remoteproc@vger.kernel.org \
    --cc=linux-renesas-soc@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®