linux-i2c.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Sui Chen <suichen@google.com>
To: linux-kernel@vger.kernel.org
Cc: linux-i2c@vger.kernel.org, openbmc@lists.ozlabs.org,
	joel@jms.id.au, andrew@aj.id.au, tali.perry1@gmail.com,
	benjaminfair@google.com, krellan@google.com,
	Sui Chen <suichen@google.com>
Subject: [RFC Patch v3 0/3] I2C statistics as sysfs attributes
Date: Tue, 21 Dec 2021 09:43:41 -0800	[thread overview]
Message-ID: <20211221174344.1249202-1-suichen@google.com> (raw)

Add I2C statistics (transaction, bus error and NACK counts) as sysfs
attributes for a stable and unified API.

The motivation is monitoring large numbers of BMCs at scale.
Monitoring will be done using OpenBMC, which includes a Redfish
implementation (bmcweb) and runs on different SoCs.

OpenBMC has distribution-wide DBus C++ bindings, for which I2C
statistics will be added. For the Redfish schemas, the upcoming
Release 2021.4 will include I2C statistics too.

Since both OpenBMC and Redfish have/will have committed to stable
APIs for monitoring I2C statistics, we would like to learn the
kernel community's opinion on stable kernel APIs for I2C counters.

A more detailed explanation could be found in [1].

This version (v3) fixes format errors, potential unchecked memory
allocation, and fixes a build problem found by the Kernel Test Robot.

Thanks!

[1] https://lore.kernel.org/lkml/CAJOps0u=seskB-YGvLBsHantJohkEX7do-mt7YSZ6zChQMQxbg@mail.gmail.com/


Sui Chen (2):
  i2c debug counters as sysfs attributes
  add npcm7xx debug counters as sysfs attributes

Tali Perry (1):
  i2c: npcm7xx: add tx_complete counter

 drivers/i2c/busses/i2c-npcm7xx.c |  13 ++++
 drivers/i2c/i2c-core-base.c      |  23 ++++++
 drivers/i2c/i2c-dev.c            | 124 +++++++++++++++++++++++++++++++
 include/linux/i2c.h              |  28 +++++++
 4 files changed, 188 insertions(+)

-- 
2.34.1.307.g9b7440fafd-goog


             reply	other threads:[~2021-12-21 17:44 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-12-21 17:43 Sui Chen [this message]
2021-12-21 17:43 ` [RFC Patch v3 1/3] i2c debug counters as sysfs attributes Sui Chen
2022-02-07 13:01   ` Wolfram Sang
2021-12-21 17:43 ` [RFC Patch v3 2/3] i2c: npcm7xx: add tx_complete counter Sui Chen
2021-12-21 17:43 ` [RFC Patch v3 3/3] add npcm7xx debug counters as sysfs attributes Sui Chen

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=20211221174344.1249202-1-suichen@google.com \
    --to=suichen@google.com \
    --cc=andrew@aj.id.au \
    --cc=benjaminfair@google.com \
    --cc=joel@jms.id.au \
    --cc=krellan@google.com \
    --cc=linux-i2c@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=openbmc@lists.ozlabs.org \
    --cc=tali.perry1@gmail.com \
    /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;
as well as URLs for NNTP newsgroup(s).