public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Dejin Zheng <zhengdejin5@gmail.com>
To: Wolfram Sang <wsa@the-dreams.de>
Cc: michal.simek@xilinx.com, wsa+renesas@sang-engineering.com,
	pierre-yves.mordret@st.com, mcoquelin.stm32@gmail.com,
	alexandre.torgue@st.com, alain.volmat@st.com,
	linux-i2c@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH v1] i2c: busses: convert to devm_platform_get_and_ioremap_resource
Date: Thu, 16 Apr 2020 00:07:57 +0800	[thread overview]
Message-ID: <20200415160757.GC17519@nuc8i5> (raw)
In-Reply-To: <20200415102158.GH1141@ninjato>

On Wed, Apr 15, 2020 at 12:21:58PM +0200, Wolfram Sang wrote:
> On Tue, Apr 14, 2020 at 09:48:27PM +0800, Dejin Zheng wrote:
> > use devm_platform_get_and_ioremap_resource() to simplify code, which
> > contains platform_get_resource() and devm_ioremap_resource(), it also
> > get the resource for use by the following code.
> > 
> > Signed-off-by: Dejin Zheng <zhengdejin5@gmail.com>
> 
> Applied to for-next, because it seems 'the new way' but...
> 
> > -	r_mem = platform_get_resource(pdev, IORESOURCE_MEM, 0);
> > -	id->membase = devm_ioremap_resource(&pdev->dev, r_mem);
> > +	id->membase = devm_platform_get_and_ioremap_resource(pdev, 0, &r_mem);
> 
> ... guys, do you really think this one line reduction improves
> readability? Oh well...
>
Wolfram, Thank you for accepting it. From my personal point of view,
as long as the direction is correct, even small improvements are
worth doing. Thanks again for your tolerance.

BR,
Dejin



  reply	other threads:[~2020-04-15 16:08 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-04-14 13:48 [PATCH v1] i2c: busses: convert to devm_platform_get_and_ioremap_resource Dejin Zheng
2020-04-15 10:21 ` Wolfram Sang
2020-04-15 16:07   ` Dejin Zheng [this message]
2020-04-17 20:46     ` Andy Shevchenko
2020-04-18  4:06       ` Dejin Zheng
  -- strict thread matches above, loose matches on Subject: below --
2020-04-17 20:36 Markus Elfring

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=20200415160757.GC17519@nuc8i5 \
    --to=zhengdejin5@gmail.com \
    --cc=alain.volmat@st.com \
    --cc=alexandre.torgue@st.com \
    --cc=linux-i2c@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mcoquelin.stm32@gmail.com \
    --cc=michal.simek@xilinx.com \
    --cc=pierre-yves.mordret@st.com \
    --cc=wsa+renesas@sang-engineering.com \
    --cc=wsa@the-dreams.de \
    /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