Linux-IIO Archive on lore.kernel.org
 help / color / Atom feed
* Re: [PATCH v2] iio: magnetometer: ak8974: Fix runtime PM imbalance on error in ak8974_probe()
@ 2020-05-31 14:06 Markus Elfring
  2020-06-25 12:34 ` Markus Elfring
  0 siblings, 1 reply; 4+ messages in thread
From: Markus Elfring @ 2020-05-31 14:06 UTC (permalink / raw)
  To: Dinghao Liu, Linus Walleij, linux-iio
  Cc: kernel-janitors, linux-kernel, Hartmut Knaack, Jonathan Cameron,
	Kangjie Lu, Lars-Peter Clausen, Peter Meerwald-Stadler

> When devm_regmap_init_i2c() returns an error code, a pairing
> runtime PM usage counter decrement is needed to keep the
> counter balanced.

How do you think about to replace the word “pairing” by “corresponding”?


> For error paths after ak8974_set_power(),
> ak8974_detect() and ak8974_reset(), things are the same.

Will an other wording become more helpful than this information?


> However, When iio_triggered_buffer_setup() returns an error
> code, there will be two PM usgae counter decrements.

Please avoid two typos in this sentence.


Would you like to add the tag “Fixes” to the commit message?


…
+++ b/drivers/iio/magnetometer/ak8974.c
…
@@ -854,7 +856,6 @@  static int ak8974_probe(struct i2c_client *i2c,
…

Can a source code variant like the following make sense
for a more complete exception handling?

power_off:
	ak8974_set_power(ak8974, AK8974_PWR_OFF);
put_pm:
	pm_runtime_put_noidle(&i2c->dev);
	pm_runtime_disable(&i2c->dev);
disable_regulator:
	regulator_bulk_disable(ARRAY_SIZE(ak8974->regs), ak8974->regs);
	return ret;


Regards,
Markus

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH v2] iio: magnetometer: ak8974: Fix runtime PM imbalance on error in ak8974_probe()
  2020-05-31 14:06 [PATCH v2] iio: magnetometer: ak8974: Fix runtime PM imbalance on error in ak8974_probe() Markus Elfring
@ 2020-06-25 12:34 ` Markus Elfring
  2020-06-27 14:53   ` Jonathan Cameron
  0 siblings, 1 reply; 4+ messages in thread
From: Markus Elfring @ 2020-06-25 12:34 UTC (permalink / raw)
  To: Jonathan Cameron, Linus Walleij, Dinghao Liu, linux-iio
  Cc: kernel-janitors, linux-kernel, Hartmut Knaack, Jonathan Cameron,
	Kangjie Lu, Lars-Peter Clausen, Peter Meerwald-Stadler

https://lkml.org/lkml/2020/6/14/117
https://lore.kernel.org/patchwork/comment/1452516/
https://lore.kernel.org/linux-iio/20200614131116.143bcf92@archlinux/

> There was a lot of fuzz in this one due to other changes to the driver.
> I 'think' it went it cleanly though.

Is it interesting anyhow that you committed a change description
which contained typos (on 2020-06-14 13:08:47 +0100)?
https://git.kernel.org/pub/scm/linux/kernel/git/jic23/iio.git/commit/drivers/iio/magnetometer/ak8974.c?h=fixes-togreg&id=0187294d227dfc42889e1da8f8ce1e44fc25f147

How were the chances that my patch review comments would be taken
better into account?
https://lore.kernel.org/linux-iio/dd84c12f-277d-27e7-3727-4592e530e4ed@web.de/
https://lkml.org/lkml/2020/5/31/152

Regards,
Markus

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH v2] iio: magnetometer: ak8974: Fix runtime PM imbalance on error in ak8974_probe()
  2020-06-25 12:34 ` Markus Elfring
@ 2020-06-27 14:53   ` Jonathan Cameron
  2020-06-27 15:52     ` [v2] " Markus Elfring
  0 siblings, 1 reply; 4+ messages in thread
From: Jonathan Cameron @ 2020-06-27 14:53 UTC (permalink / raw)
  To: Markus Elfring
  Cc: Jonathan Cameron, Linus Walleij, Dinghao Liu, linux-iio,
	kernel-janitors, linux-kernel, Hartmut Knaack, Kangjie Lu,
	Lars-Peter Clausen, Peter Meerwald-Stadler

On Thu, 25 Jun 2020 14:34:44 +0200
Markus Elfring <Markus.Elfring@web.de> wrote:

> https://lkml.org/lkml/2020/6/14/117
> https://lore.kernel.org/patchwork/comment/1452516/
> https://lore.kernel.org/linux-iio/20200614131116.143bcf92@archlinux/
> 
> > There was a lot of fuzz in this one due to other changes to the driver.
> > I 'think' it went it cleanly though.  
> 
> Is it interesting anyhow that you committed a change description
> which contained typos (on 2020-06-14 13:08:47 +0100)?
> https://git.kernel.org/pub/scm/linux/kernel/git/jic23/iio.git/commit/drivers/iio/magnetometer/ak8974.c?h=fixes-togreg&id=0187294d227dfc42889e1da8f8ce1e44fc25f147
> 
> How were the chances that my patch review comments would be taken
> better into account?
> https://lore.kernel.org/linux-iio/dd84c12f-277d-27e7-3727-4592e530e4ed@web.de/
> https://lkml.org/lkml/2020/5/31/152

I'm not sure why, but your reply did not have a reply-to field in the header
as such my email client did not present it alongside the patch. Hence I
missed it when applying.

Agreed it would have been nicer to have fixed those typos.
However, they don't affect comprehensibility of the message so I'm not that
worried about having them in the log.

Jonathan



> 
> Regards,
> Markus


^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [v2] iio: magnetometer: ak8974: Fix runtime PM imbalance on error in ak8974_probe()
  2020-06-27 14:53   ` Jonathan Cameron
@ 2020-06-27 15:52     ` Markus Elfring
  0 siblings, 0 replies; 4+ messages in thread
From: Markus Elfring @ 2020-06-27 15:52 UTC (permalink / raw)
  To: Jonathan Cameron, linux-iio
  Cc: Jonathan Cameron, Linus Walleij, Dinghao Liu, kernel-janitors,
	linux-kernel, Hartmut Knaack, Kangjie Lu, Lars-Peter Clausen,
	Peter Meerwald-Stadler

>> How were the chances that my patch review comments would be taken
>> better into account?
>> https://lore.kernel.org/linux-iio/dd84c12f-277d-27e7-3727-4592e530e4ed@web.de/
>> https://lkml.org/lkml/2020/5/31/152
>
> I'm not sure why, but your reply did not have a reply-to field in the header
> as such my email client did not present it alongside the patch.

There are some factors involved for this undesirable effect.

Example:
My software selection contains open issues in the handling of mailto links
according to the communication interface “public inbox”.


> Hence I missed it when applying.

Can my approach for a patch review reminder get more attention?


> Agreed it would have been nicer to have fixed those typos.

Thanks for this positive feedback.


> However, they don't affect comprehensibility of the message
> so I'm not that worried about having them in the log.

Can you get other concerns around the quality of commit messages?


Will it become more interesting to take another look at jump targets
for the exception handling?

Regards,
Markus

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, back to index

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-05-31 14:06 [PATCH v2] iio: magnetometer: ak8974: Fix runtime PM imbalance on error in ak8974_probe() Markus Elfring
2020-06-25 12:34 ` Markus Elfring
2020-06-27 14:53   ` Jonathan Cameron
2020-06-27 15:52     ` [v2] " Markus Elfring

Linux-IIO Archive on lore.kernel.org

Archives are clonable:
	git clone --mirror https://lore.kernel.org/linux-iio/0 linux-iio/git/0.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 linux-iio linux-iio/ https://lore.kernel.org/linux-iio \
		linux-iio@vger.kernel.org
	public-inbox-index linux-iio

Example config snippet for mirrors

Newsgroup available over NNTP:
	nntp://nntp.lore.kernel.org/org.kernel.vger.linux-iio


AGPL code for this site: git clone https://public-inbox.org/public-inbox.git