From: "viktor.prutyanov" <viktor.prutyanov@virtuozzo.com>
To: linux-pci@vger.kernel.org, mj@ucw.cz
Subject: Re: [PATCH v3 0/3] lspci: Add support of JSON output format
Date: Sun, 11 Mar 2018 18:03:34 +0300 [thread overview]
Message-ID: <20180311180334.4ba6baec@virtuozzo.com> (raw)
In-Reply-To: <20180218231251.23988-1-viktor.prutyanov@virtuozzo.com>
=D0=92 Mon, 19 Feb 2018 02:12:48 +0300
Viktor Prutyanov <viktor.prutyanov@virtuozzo.com> =D0=BF=D0=B8=D1=88=D0=B5=
=D1=82:
ping
> This collection of patches adds support of printing PCI info in JSON
> format.
>=20
> 1st patch adds skeleton for creating structured object which can be
> printed in JSON or another structured format.
> 2nd patch adds output of general PCI info which prints with -m, -k,
> -[v]+ options, but without capabilities.
> 3rd patch adds PCI-E capability.
>=20
> For example, we can easily, using jq utility, check speed of a device:
> lspci -Jvv | jq -r '.[][] | select(.Device =3D=3D "GK107M [GeForce GT
> 750M]") | .capabilities.express | {s1:.LnkCap.Speed,
> s2:.LnkSta.Speed, w1 :.LnkCap.Width, w2:.LnkSta.Width }'
>=20
> {
> "s1": "8GT/s",
> "s2": "5GT/s",
> "w1": "x16",
> "w2": "x4"
> }
>=20
> Viktor Prutyanov (3):
> lspci: Add printing info in JSON format
> lspci: Add PCI info output in JSON format
> lspci: Add JSON PCI Express capabilities
>=20
> Makefile | 3 +-
> common.c | 2 +-
> ls-caps.c | 417 +++++++++++++++++++++++++++++++++++
> ls-info.c | 328 ++++++++++++++++++++++++++++
> ls-kernel.c | 24 +++
> lspci.c | 706
> +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++-
> lspci.h | 56 +++++ lspci.man | 3 +
> pciutils.h | 2 +-
> 9 files changed, 1537 insertions(+), 4 deletions(-)
> create mode 100644 ls-info.c
>=20
prev parent reply other threads:[~2018-03-11 15:03 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-02-18 23:12 [PATCH v3 0/3] lspci: Add support of JSON output format Viktor Prutyanov
2018-02-18 23:12 ` [PATCH v3 1/3] lspci: Add printing info in JSON format Viktor Prutyanov
2018-02-18 23:12 ` [PATCH v3 2/3] lspci: Add PCI info output " Viktor Prutyanov
2018-02-18 23:12 ` [PATCH v3 3/3] lspci: Add JSON PCI Express capabilities Viktor Prutyanov
2018-03-11 15:03 ` viktor.prutyanov [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=20180311180334.4ba6baec@virtuozzo.com \
--to=viktor.prutyanov@virtuozzo.com \
--cc=linux-pci@vger.kernel.org \
--cc=mj@ucw.cz \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.