From: "Daisuke Kobayashi (Fujitsu)" <kobayashi.da-06@fujitsu.com>
To: "Daisuke Kobayashi (Fujitsu)" <kobayashi.da-06@fujitsu.com>,
Jonathan Cameron <Jonathan.Cameron@Huawei.com>
Cc: "linux-pci@vger.kernel.org" <linux-pci@vger.kernel.org>,
"kw@linux.com" <kw@linux.com>
Subject: RE: [PATCH v4] Export PBEC Data register into sysfs
Date: Thu, 14 Nov 2024 09:37:16 +0000 [thread overview]
Message-ID: <OSAPR01MB71829048884C23C3673C7484BA5B2@OSAPR01MB7182.jpnprd01.prod.outlook.com> (raw)
In-Reply-To: <OSAPR01MB7182F740B00B1A38AB84AB6DBA5B2@OSAPR01MB7182.jpnprd01.prod.outlook.com>
> Jonathan Cameron wrote:
> > "Kobayashi,Daisuke" <kobayashi.da-06@fujitsu.com> wrote:
> >
> [...]
> > It's not user friendly to just output the register content, and this
> > is breaking the one thing per sysfs file ABI rules.
> >
> > Various possible sysfs structures may make more sense.
> >
> > 1) Directory with files for each entry found. Each file
> > is one thing so
> > power_budget/X_power - maths done to take base power and apply the
> > data scale.
> > X_pm_state
> > X_pm_substate
> > X_type - potentially with nice strings for each type.
> > X_rail - 12V, 3,3V , 1.5V/1.8V, 48V, 5V, thermal
> > X_connector -
> > X_connector_type
> >
> > With the stuff in the extended bit only visible if flag in bit 31 is set.
>
> Following the ABI rules, I propose the following directory structure, based on
> the suggestion provided.
> Please review it and let me know if you have any concerns.
> If there are no objections, I will implement this and release it as the next v5
> patch.
>
> power_budget
> ├── 0 - The index number to be set in the Data Select Register
> │ ├── power - Value considering base power and data scale
> │ ├── pm_state - D0, D1, D2, D3
> │ ├── pm_substate
> │ ├── type
> │ ├── rail - 12V, 3.3V, 1.5V/1.8V, 48V, 5V, Thermal
> │ ├── connector
> │ └── connector_type
> ├── 1
> │ ├── power
> │ ├── pm_state
> │ ├──
After reviewing the existing pci-sysfs implementation, I've found that
implementing the directory structure that I proposed cleanly is proving difficult.
Therefore, I'm proposing a second option with the following structure.
power_budget
├── data_select - Read-Write value selecting the power budget to be displayed.
├── power - Value considering base power and data scale
├── pm_state - D0, D1, D2, D3
├── pm_substate
├── type
├── rail - 12V, 3.3V, 1.5V/1.8V, 48V, 5V, Thermal
├── connector
└── connector_type
prev parent reply other threads:[~2024-11-14 9:37 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-09-11 1:20 [PATCH v4] Export PBEC Data register into sysfs Kobayashi,Daisuke
2024-09-24 7:39 ` Daisuke Kobayashi (Fujitsu)
2024-10-15 1:04 ` Daisuke Kobayashi (Fujitsu)
2024-10-31 7:37 ` Daisuke Kobayashi (Fujitsu)
2024-11-01 11:04 ` Jonathan Cameron
2024-11-06 8:58 ` Daisuke Kobayashi (Fujitsu)
2024-11-07 15:55 ` Krzysztof Wilczyński
2024-11-14 2:27 ` Daisuke Kobayashi (Fujitsu)
2024-11-14 9:37 ` Daisuke Kobayashi (Fujitsu) [this message]
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=OSAPR01MB71829048884C23C3673C7484BA5B2@OSAPR01MB7182.jpnprd01.prod.outlook.com \
--to=kobayashi.da-06@fujitsu.com \
--cc=Jonathan.Cameron@Huawei.com \
--cc=kw@linux.com \
--cc=linux-pci@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