mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Mario Limonciello <mario.limonciello@amd.com>
To: Natikar Basavaraj <Basavaraj.Natikar@amd.com>,
	<linux-gpio@vger.kernel.org>
Cc: Mario Limonciello <mario.limonciello@amd.com>,
	<linux-kernel@vger.kernel.org>
Subject: [PATCH 0/2] pinctrl-amd debugfs improvements
Date: Tue, 28 Mar 2023 12:42:29 -0500	[thread overview]
Message-ID: <20230328174231.8924-1-mario.limonciello@amd.com> (raw)

Debugging an issue recently of poor residency in a low power state
concluded it was caused by GPIO controller misprogrammed in BIOS.

What happened was _CRS was missing a configuration but device was
trying to assert an interrupt.  This is found by interrupt status
bit which isn't currently covered in debug output.

Add this and also the similar wake status bit to debug output.
As the display is very busy and growing long again with so much info,
adjust the display to only render characters for relevant bits
and to now use headers for each GPIO bank.

New sample output, including demonstrating detection of
BIOS issue (by 🔥):

gpio	  int|active|trigger|S0i3| S3|S4/S5| Z|wake|pull|  orient|       debounce|reg
#0	   😛|     ↑|   edge|  ⏰| ⏰|     |⏰|    |4k ↑|input  ↑|b (🕑 046875us)|0x81578e3
#1	    ∅|      |       |    |   |     |  |    |4k ↑|input  ↑|               |0x150000
#2	   😛|     ↓|   edge|  ⏰| ⏰|     |  |    |4k ↑|input  ↑|               |0x157a00
#3	   😛|     ↓|   edge|  ⏰| ⏰|     |  |    |4k ↑|input  ↑|               |0x157a00
#4	    ∅|      |       |    |   |     |  |    |4k ↑|input  ↑|               |0x150000
#5	    ∅|      |       |    |   |     |  |    |4k ↑|input  ↑|               |0x150000
#6	   😷|     ↓|  level|    |   |     |⏰|    |4k ↑|input  ↑|               |0x8150b00
#7	    ∅|      |       |    |   |     |  |    |4k ↑|input  ↑|               |0x150200
#8	🔥 😷|     ↓|  level|    |   |     |⏰|    |4k ↑|input  ↓|               |0x18140b00

Mario Limonciello (2):
  pinctrl: amd: Adjust debugfs output
  pinctrl: amd: Add fields for interrupt status and wake status

 drivers/pinctrl/pinctrl-amd.c | 90 +++++++++++++++++------------------
 1 file changed, 44 insertions(+), 46 deletions(-)

-- 
2.34.1


             reply	other threads:[~2023-03-28 17:43 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-03-28 17:42 Mario Limonciello [this message]
2023-03-28 17:42 ` [PATCH 1/2] pinctrl: amd: Adjust debugfs output Mario Limonciello
2023-03-31 12:24   ` Linus Walleij
2023-03-28 17:42 ` [PATCH 2/2] pinctrl: amd: Add fields for interrupt status and wake status Mario Limonciello

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=20230328174231.8924-1-mario.limonciello@amd.com \
    --to=mario.limonciello@amd.com \
    --cc=Basavaraj.Natikar@amd.com \
    --cc=linux-gpio@vger.kernel.org \
    --cc=linux-kernel@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®