mail archive of the barebox mailing list
 help / color / mirror / Atom feed
From: Andrey Smirnov <andrew.smirnov@gmail.com>
To: "Uwe Kleine-König" <u.kleine-koenig@pengutronix.de>
Cc: Barebox List <barebox@lists.infradead.org>
Subject: Re: [PATCH 4/4] pci: don't hide hard to understand sanity check in size calculation
Date: Mon, 16 Apr 2018 06:42:31 -0700	[thread overview]
Message-ID: <CAHQ1cqGaupXUAaBCsgKeA2Gby+xE85qxrXs1AE0PvBVsTUOayA@mail.gmail.com> (raw)
In-Reply-To: <20180415182758.2gvkmxp7e5zzxtev@pengutronix.de>

On Sun, Apr 15, 2018 at 11:27 AM, Uwe Kleine-König
<u.kleine-koenig@pengutronix.de> wrote:
> Hello Andrey,
>
> On Sat, Apr 14, 2018 at 09:25:59AM -0700, Andrey Smirnov wrote:
>> On Fri, Apr 13, 2018 at 4:30 PM, Uwe Kleine-König
>> <u.kleine-koenig@pengutronix.de> wrote:
>> > +               /*
>> > +                * if maxbase isn't in the form 0b1...10...0 there is something
>> > +                * fishy
>> > +                */
>> > +               if ((maxbase | (maxbase - 1)) != (u32)-1 || maxbase == 0) {
>>
>> U32_MAX instead of (u32)-1 ?
>
> I don't feel strong here.

Me neither. I just read (u32)-1 as a shortcut for 0xffffffff and we
already have a shortcut for that. But if you want to keep using
(u32)-1, then by all means.

Thanks,
Andrey Smirnov

_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox

      reply	other threads:[~2018-04-16 13:42 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-04-13 23:30 [PATCH 1/4] pci: rename variable mask -> barval Uwe Kleine-König
2018-04-13 23:30 ` [PATCH 2/4] pci: refactor bar configuration Uwe Kleine-König
2018-04-13 23:30 ` [PATCH 3/4] pci: improve debug output Uwe Kleine-König
2018-04-13 23:58   ` Uwe Kleine-König
2018-04-13 23:30 ` [PATCH 4/4] pci: don't hide hard to understand sanity check in size calculation Uwe Kleine-König
2018-04-14 16:25   ` Andrey Smirnov
2018-04-15 18:27     ` Uwe Kleine-König
2018-04-16 13:42       ` Andrey Smirnov [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=CAHQ1cqGaupXUAaBCsgKeA2Gby+xE85qxrXs1AE0PvBVsTUOayA@mail.gmail.com \
    --to=andrew.smirnov@gmail.com \
    --cc=barebox@lists.infradead.org \
    --cc=u.kleine-koenig@pengutronix.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