public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
From: Peng Fan <van.freenix@gmail.com>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH 2/5] mmc: initialize mmc_cmd with 0
Date: Thu, 18 Aug 2016 14:21:22 +0800	[thread overview]
Message-ID: <20160818062120.GA25548@linux-7smt.suse> (raw)
In-Reply-To: <CAPnjgZ3wnP4s+uLpEYZAkXL+p9k+y-zp6KiO8=yqA7bHnrnP5A@mail.gmail.com>

Hi Simon,

On Wed, Aug 17, 2016 at 09:45:35PM -0600, Simon Glass wrote:
>Hi Peng,
>
>On 12 August 2016 at 19:41, Peng Fan <van.freenix@gmail.com> wrote:
>> Hi Simon,
>> On Fri, Aug 12, 2016 at 11:20:25AM -0600, Simon Glass wrote:
>>>Hi Peng,
>>>
>>>On 11 August 2016 at 05:00, Peng Fan <van.freenix@gmail.com> wrote:
>>>> Using {0} to initialize mmc_cmd, before filling the structure.
>>>>
>>>> Signed-off-by: Peng Fan <peng.fan@nxp.com>
>>>> Cc: Jaehoon Chung <jh80.chung@samsung.com>
>>>> Cc: Simon Glass <sjg@chromium.org>
>>>> Cc: Bin Meng <bmeng.cn@gmail.com>
>>>> Cc: Stefan Wahren <stefan.wahren@i2se.com>
>>>> Cc: Clemens Gruber <clemens.gruber@pqgruber.com>
>>>> Cc: Kever Yang <kever.yang@rock-chips.com>
>>>> Cc: Eric Nelson <eric@nelint.com>
>>>> Cc: Stephen Warren <swarren@nvidia.com>
>>>> ---
>>>>  drivers/mmc/mmc.c       | 28 ++++++++++++++--------------
>>>>  drivers/mmc/mmc_write.c |  4 ++--
>>>>  2 files changed, 16 insertions(+), 16 deletions(-)
>>>
>>>Why is this needed? Does it affect code size?
>>
>> I add a timeout entry in mmc_cmd, but I do not want to specify a value for timeout
>> for each mmc_cmd. So I use {0}.
>>
>> Then to those who want use timeout, a value can be assigned to timeout, just like
>> I added in the patchset for mmc erase.
>
>Instead of that, can you assign the value to 0, or whatever you want?
>You might want to have a helper like mmc_init_cmd() to zero things
>out.

Ok. Will follow your suggestion in V3.

Thanks,
Peng.

>
>Regards,
>Simon

  reply	other threads:[~2016-08-18  6:21 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <CGME20160811110023epcas1p4289773001396502dbc59a4638887cae5@epcas1p4.samsung.com>
2016-08-11 11:00 ` [U-Boot] [PATCH 1/5] mmc: sd: extracting erase timeout information from sd status Peng Fan
2016-08-11 11:00   ` [U-Boot] [PATCH 2/5] mmc: initialize mmc_cmd with 0 Peng Fan
2016-08-12 17:20     ` Simon Glass
2016-08-13  1:41       ` Peng Fan
2016-08-18  3:45         ` Simon Glass
2016-08-18  6:21           ` Peng Fan [this message]
2016-08-11 11:00   ` [U-Boot] [PATCH 3/5] mmc: sd: add erase timeout support Peng Fan
2016-08-11 11:00   ` [U-Boot] [PATCH 4/5] mmc: esdhc: change timeout value Peng Fan
2016-08-11 11:00   ` [U-Boot] [PATCH 5/5] mmc: sd: optimize erase Peng Fan
2016-08-12  0:53     ` Fabio Estevam
2016-08-12  3:02       ` Peng Fan
2016-08-12  3:12         ` Fabio Estevam
2016-08-12  2:08   ` [U-Boot] [PATCH 1/5] mmc: sd: extracting erase timeout information from sd status Jaehoon Chung
2016-08-12  2:55     ` Peng Fan
2016-08-12  3:51       ` Jaehoon Chung

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=20160818062120.GA25548@linux-7smt.suse \
    --to=van.freenix@gmail.com \
    --cc=u-boot@lists.denx.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