mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Andy Shevchenko <andriy.shevchenko@intel.com>
To: "Adil Hüsrev Tepe" <tadilhusrev@gmail.com>
Cc: "Jonathan Cameron" <jic23@kernel.org>,
	"Rob Herring" <robh@kernel.org>,
	"Krzysztof Kozlowski" <krzk+dt@kernel.org>,
	"Conor Dooley" <conor+dt@kernel.org>,
	"David Lechner" <dlechner@baylibre.com>,
	"Nuno Sá" <nuno.sa@analog.com>,
	"Andy Shevchenko" <andy@kernel.org>,
	linux-iio@vger.kernel.org, devicetree@vger.kernel.org,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH v1 2/2] iio: proximity: add Imagis ISG5320A SAR sensor driver
Date: Mon, 16 Nov 2026 12:53:12 +0200	[thread overview]
Message-ID: <avrgmAFpY7hvuwNh@ashevche-desk.local> (raw)
In-Reply-To: <20261116074013.355363-3-tadilhusrev@gmail.com>

On Mon, Nov 16, 2026 at 10:40:13AM +0300, Adil Hüsrev Tepe wrote:
> Add an IIO driver for the Imagis ISG5320A capacitive SAR/grip sensor
> (I2C), as fitted on the Samsung Galaxy XCover5. It exposes one
> IIO_PROXIMITY channel (the B-channel signal minus its baseline) and a
> rising/falling threshold proximity event.
> 
> The driver was derived from the Samsung vendor driver during XCover5
> mainline bring-up with the help of an AI coding assistant (Claude Code,
> Anthropic), which drafted the mainline IIO driver; I reviewed every line
> and tested it on hardware.

...

> +config ISG5320A
> +	tristate "Imagis ISG5320A SAR proximity sensor"

Make sure this, top level comment and MODULE_DESCRIPTION() have the same or
quite similar text.


> +	depends on I2C
> +	select REGMAP_I2C
> +	help
> +	  Say Y here to build a driver for the Imagis ISG5320A capacitive
> +	  SAR/grip proximity sensor.
> +
> +	  To compile this driver as a module, choose M here: the module will
> +	  be called isg5320a.

...

> +#include <linux/bits.h>
> +#include <linux/delay.h>
> +#include <linux/device.h>
> +#include <linux/gpio/consumer.h>
> +#include <linux/i2c.h>
> +#include <linux/interrupt.h>
> +#include <linux/irq.h>

> +#include <linux/kernel.h>

Definitely no.
Also, please follow IWYU principle.

> +#include <linux/mod_devicetable.h>
> +#include <linux/module.h>
> +#include <linux/mutex.h>
> +#include <linux/pm.h>
> +#include <linux/pm_runtime.h>
> +#include <linux/pm_wakeup.h>
> +#include <linux/property.h>
> +#include <linux/regmap.h>
> +#include <linux/regulator/consumer.h>

...

Also, take in use *ACQUIRE*() macros, in particular for runtime PM where it
makes sense.

...

I stopped here. You can now go via mailing list archive (linux-iio@) and check
what are the usual comments against new drier. You have many small things to
improve, I believe.

-- 
With Best Regards,
Andy Shevchenko



  reply	other threads:[~2026-11-16 10:53 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-11-16  7:40 [PATCH v1 0/2] iio: proximity: add Imagis ISG5320A (Samsung Galaxy XCover5) Adil Hüsrev Tepe
2026-11-16  7:40 ` [PATCH v1 1/2] dt-bindings: iio: proximity: add Imagis ISG5320A Adil Hüsrev Tepe
2026-11-16  7:40 ` [PATCH v1 2/2] iio: proximity: add Imagis ISG5320A SAR sensor driver Adil Hüsrev Tepe
2026-11-16 10:53   ` Andy Shevchenko [this message]
2026-11-16 10:48 ` [PATCH v1 0/2] iio: proximity: add Imagis ISG5320A (Samsung Galaxy XCover5) Andy Shevchenko

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=avrgmAFpY7hvuwNh@ashevche-desk.local \
    --to=andriy.shevchenko@intel.com \
    --cc=andy@kernel.org \
    --cc=conor+dt@kernel.org \
    --cc=devicetree@vger.kernel.org \
    --cc=dlechner@baylibre.com \
    --cc=jic23@kernel.org \
    --cc=krzk+dt@kernel.org \
    --cc=linux-iio@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=nuno.sa@analog.com \
    --cc=robh@kernel.org \
    --cc=tadilhusrev@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

all inboxes | Powered by JetHome®