public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
From: Richard Retanubun <richardretanubun@ruggedcom.com>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH] spi: Use DIV_ROUND_UP at appropriate places
Date: Fri, 14 Jun 2013 09:24:37 -0400	[thread overview]
Message-ID: <51BB1995.4000503@ruggedcom.com> (raw)
In-Reply-To: <CAFRkauDEBN2NBAYzk5NSMARTT7jzbLu3rDp1QLccwnSsGbZG3g@mail.gmail.com>

On 14/06/13 09:09 AM, Axel Lin wrote:
> 2013/6/14 Jagan Teki<jagannadh.teki@gmail.com>:
>> Hi,
>>
>> IMHO:
>> Can you please use the proper commit header prefix.
>>
>> I am just sharing my thoughts, ignore this if you know it already.
>> I followed below syntax.
>> "<main_module>:<sub_module>:<sub_sub_module>:<COMMIT_HEADER>"
>>
>> Ex: for this commit (seems like this commit changes two drivers)
>> spi: cf_qspi | mxc_spi: Use DIV_ROUND_UP at appropriate places
>
> This does not scale.
> What if a (trivial) patch touches 10 drivers?
Depends how trivial it is I guess. I can see benefits to both approaches.

This one is simple enough that I am okay if it is grouped.

Just for my own education, how do I correctly ACK just the part I know
(mcf_qspi in this case) in a grouped patch?
Is there a way to automate my "Signed-off-by:" via e-mail?

-- Richard Retanubun
>
>>
>> if you send same changes individually.
>> spi: cf_qspi: Use DIV_ROUND_UP at appropriate places
>> spi: mxc_spi: Use DIV_ROUND_UP at appropriate places
>
> I was thinking doing so may add maintainer's burden. (well for this
> case with 2 patches, it's not a problem)
> But since you prefer sending a fix per driver, I'll resend the patches.
>
>>
>> On Fri, Jun 14, 2013 at 1:29 PM, Axel Lin<axel.lin@ingics.com>  wrote:
>>> This change slightly improves readability.
>>>
>>> Signed-off-by: Axel Lin<axel.lin@ingics.com>
>>> ---
>>>   drivers/spi/cf_qspi.c | 2 +-
>>>   drivers/spi/mxc_spi.c | 6 +++---
>>>   2 files changed, 4 insertions(+), 4 deletions(-)
>>>
>>> diff --git a/drivers/spi/cf_qspi.c b/drivers/spi/cf_qspi.c
>>> index a37ac4e..06bcf91 100644
>>> --- a/drivers/spi/cf_qspi.c
>>> +++ b/drivers/spi/cf_qspi.c
>>> @@ -171,7 +171,7 @@ int spi_xfer(struct spi_slave *slave, unsigned int bitlen, const void *dout,
>>>          volatile qspi_t *qspi = dev->regs;
>>>          u8 *txbuf = (u8 *)dout;
>>>          u8 *rxbuf = (u8 *)din;
>>> -       u32 count = ((bitlen / 8) + (bitlen % 8 ? 1 : 0));
>>
>> Was this equivalent to  (bitlen + 7) / 8 ?
>
> Yes. And that is the point of this patch ( to handle divide-round-up
> in a uniform way).
>>
>> --
>> Thanks,
>> Jagan.

  parent reply	other threads:[~2013-06-14 13:24 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-06-14  7:59 [U-Boot] [PATCH] spi: Use DIV_ROUND_UP at appropriate places Axel Lin
2013-06-14 12:20 ` Jagan Teki
2013-06-14 13:09   ` Axel Lin
2013-06-14 13:18     ` Jagan Teki
2013-06-17 10:40       ` Stefano Babic
2013-06-14 13:24     ` Richard Retanubun [this message]
2013-06-14 13:28       ` Jagan Teki

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=51BB1995.4000503@ruggedcom.com \
    --to=richardretanubun@ruggedcom.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