devicetree.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Ludovic BARRE <ludovic.barre@st.com>
To: Russell King - ARM Linux admin <linux@armlinux.org.uk>
Cc: Ulf Hansson <ulf.hansson@linaro.org>,
	Rob Herring <robh+dt@kernel.org>,
	devicetree@vger.kernel.org,
	Alexandre Torgue <alexandre.torgue@st.com>,
	linux-mmc@vger.kernel.org, linux-kernel@vger.kernel.org,
	srinivas.kandagatla@linaro.org,
	Maxime Coquelin <mcoquelin.stm32@gmail.com>,
	linux-stm32@st-md-mailman.stormreply.com,
	linux-arm-kernel@lists.infradead.org
Subject: Re: [PATCH V2 6/6] mmc: mmci: replace blksz_datactrlXX by get_datactrl_cfg callback
Date: Fri, 8 Mar 2019 09:44:40 +0100	[thread overview]
Message-ID: <eb213e3e-a574-b11e-ad4f-dd270d964707@st.com> (raw)
In-Reply-To: <20190307164649.ywhgdikxf4nhb2sd@shell.armlinux.org.uk>

hi Russell, Ulf

On 3/7/19 5:46 PM, Russell King - ARM Linux admin wrote:
> On Thu, Mar 07, 2019 at 05:39:02PM +0100, Ludovic Barre wrote:
>> -	if (data->flags & MMC_DATA_READ)
>> -		datactrl |= MCI_DPSM_DIRECTION;
> 
> Given that this is currently an invariant between all, it doesn't make
> sense to have a separate public function and combine it into the
> get_datactrl_cfg() implementations.  You may as well leave it in place
> here, after you call get_datactrl_cfg().
> 
>> +	datactrl = host->ops->get_datactrl_cfg(host);
> 
> Otherwise, I don't see a problem with this, although it would be nice to
> avoid the overhead of so many public functions, which could be done by
> adding them as inline functions in mmci.h
> 

To combine your comments (above and https://lkml.org/lkml/2019/3/6/318).
I could regroup mmci_dctrl_dir & mmci_dctrl_ddr & mmci_dctrl_sdio in a
common function mmci_dctrl_common and call by:
-Each get_datactrl_cfg variant
-Or in mmci_start_data

What do you prefer ?

Regards,
Ludo

      reply	other threads:[~2019-03-08  8:44 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-03-07 16:38 [PATCH V2 0/6] mmc: mmci: add get_datactrl_cfg callback Ludovic Barre
2019-03-07 16:38 ` [PATCH V2 1/6] " Ludovic Barre
2019-03-21 16:57   ` Ulf Hansson
2019-03-07 16:38 ` [PATCH V2 2/6] mmc: mmci: add helper functions to define datactrl value for variants Ludovic Barre
2019-03-21 16:43   ` Ulf Hansson
2019-03-07 16:38 ` [PATCH V2 3/6] mmc: mmci: define get_dctrl_cfg for legacy variant Ludovic Barre
2019-03-21 16:55   ` Ulf Hansson
2019-03-07 16:39 ` [PATCH V2 4/6] mmc: mmci: qcom: define get_dctrl_cfg Ludovic Barre
2019-03-07 16:39 ` [PATCH V2 5/6] mmc: mmci: stm32: " Ludovic Barre
2019-03-07 16:39 ` [PATCH V2 6/6] mmc: mmci: replace blksz_datactrlXX by get_datactrl_cfg callback Ludovic Barre
2019-03-07 16:46   ` Russell King - ARM Linux admin
2019-03-08  8:44     ` Ludovic BARRE [this message]

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=eb213e3e-a574-b11e-ad4f-dd270d964707@st.com \
    --to=ludovic.barre@st.com \
    --cc=alexandre.torgue@st.com \
    --cc=devicetree@vger.kernel.org \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mmc@vger.kernel.org \
    --cc=linux-stm32@st-md-mailman.stormreply.com \
    --cc=linux@armlinux.org.uk \
    --cc=mcoquelin.stm32@gmail.com \
    --cc=robh+dt@kernel.org \
    --cc=srinivas.kandagatla@linaro.org \
    --cc=ulf.hansson@linaro.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;
as well as URLs for NNTP newsgroup(s).