From: Kim Seer Paller <kimseer.paller@analog.com>
To: unlisted-recipients:; (no To-header on input)
Cc: <jic23@kernel.org>, <lars@metafoo.de>, <lgirdwood@gmail.com>,
<broonie@kernel.org>, <Michael.Hennerich@analog.com>,
<robh+dt@kernel.org>, <krzysztof.kozlowski+dt@linaro.org>,
<conor+dt@kernel.org>, <kimseer.paller@analog.com>,
<linux-iio@vger.kernel.org>, <linux-kernel@vger.kernel.org>,
<devicetree@vger.kernel.org>
Subject: [PATCH v3 0/2] Add max14001 support
Date: Fri, 9 Jun 2023 01:55:15 +0800 [thread overview]
Message-ID: <20230608175517.40217-1-kimseer.paller@analog.com> (raw)
Hi all,
Attached link is the app note I used as reference for programming the max14001,
which I found to provide a much easier approach. You can find it here:
https://www.analog.com/media/en/technical-documentation/user-guides/guide-to-programming-the-max14001max14002-isolated-adcs--maxim-integrated.pdf
The code has been tested and is working fine with the max14001pmb and
max14001evsys boards on the Raspberry Pi 4.
Changes in v3:
max14001:
* Replaced __cacheline_aligned with __aligned(IIO_DMA_MINALIGN).
* Removed redundant assignment of the tx variable in the max14001_write()
and max14001_read() functions.
* Assigned struct device *dev with &spi->dev to improve code readability.
* Utilized a non-regmap approach and ensure a consistent use of interface
throughout the driver code. I attempted to use the regmap API but faced
difficulties in implementing it due to the timing diagram requirements.
Specifically, the need to change the chip select between transfers, which, as
far as I know, is not applicable with regmap. While I am open to thorough
guidance and suggestions on utilizing the regmap API, for now, I have chosen
to stick with the non-regmap approach.
bindings:
* Utilized the default register values, which led to the omission of some
properties in v2. I plan to include and switch to generic values the excluded
properties in v1 in future support.
* Dropped the status property.
* Moved the allOf property after the required property for better alignment.
Best Regards,
Kim Seer Paller
Kim Seer Paller (2):
dt-bindings:iio:adc: add max14001
iio: adc: max14001: New driver
.../bindings/iio/adc/adi,max14001.yaml | 54 +++
MAINTAINERS | 8 +
drivers/iio/adc/Kconfig | 10 +
drivers/iio/adc/Makefile | 1 +
drivers/iio/adc/max14001.c | 337 ++++++++++++++++++
5 files changed, 410 insertions(+)
create mode 100644 Documentation/devicetree/bindings/iio/adc/adi,max14001.yaml
create mode 100644 drivers/iio/adc/max14001.c
base-commit: 9561de3a55bed6bdd44a12820ba81ec416e705a7
--
2.34.1
next reply other threads:[~2023-06-08 17:56 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-06-08 17:55 Kim Seer Paller [this message]
2023-06-08 17:55 ` [PATCH v3 1/2] dt-bindings:iio:adc: add max14001 Kim Seer Paller
2023-06-09 15:33 ` Krzysztof Kozlowski
2023-06-08 17:55 ` [PATCH v3 2/2] iio: adc: max14001: New driver Kim Seer Paller
2023-06-10 18:17 ` Jonathan Cameron
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=20230608175517.40217-1-kimseer.paller@analog.com \
--to=kimseer.paller@analog.com \
--cc=Michael.Hennerich@analog.com \
--cc=broonie@kernel.org \
--cc=conor+dt@kernel.org \
--cc=devicetree@vger.kernel.org \
--cc=jic23@kernel.org \
--cc=krzysztof.kozlowski+dt@linaro.org \
--cc=lars@metafoo.de \
--cc=lgirdwood@gmail.com \
--cc=linux-iio@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=robh+dt@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®