DPDK patches and discussions
 help / color / mirror / Atom feed
From: Owen Hilyard <ohilyard@iol.unh.edu>
To: Aaron Conole <aconole@redhat.com>
Cc: Stephen Hemminger <stephen@networkplumber.org>,
	David Marchand <david.marchand@redhat.com>,  dev <dev@dpdk.org>,
	Rasesh Mody <rmody@marvell.com>,
	Shahed Shaikh <shshaikh@marvell.com>
Subject: Re: [dpdk-dev] Define statement with UB prevents compilation using UBSAN
Date: Fri, 11 Jun 2021 14:15:47 -0400	[thread overview]
Message-ID: <CAHx6DYC8gx+3u7Sbt9LgkgM5U0-_+uaeKvpUUw8ZAn5juOrCug@mail.gmail.com> (raw)
In-Reply-To: <f7teed8zczx.fsf@redhat.com>

Seeing the discussion so far, do we want to change the single definition to
be (0b1u << 31) so it works, or should we make this change in a wider scope
(file, directory, project-wide). If we do make the change in a wider scope,
should we only change instances where there is UB (1 << 31) or should we
change all of the bitflags and similar constructs to uint32_t? If we change
a lot, it may require special testing since I don't think every driver is
tested on a regular basis, and making a change like this in a wide-reaching
fashion has the potential to break a lot of things.

On Fri, Jun 11, 2021 at 10:34 AM Aaron Conole <aconole@redhat.com> wrote:

> Stephen Hemminger <stephen@networkplumber.org> writes:
>
> > On Thu, 10 Jun 2021 16:51:37 -0400
> > Owen Hilyard <ohilyard@iol.unh.edu> wrote:
> >
> >> Working backward to the define
> >> statement, AEU_INPUTS_ATTN_BITS_MCP_LATCHED_SCPAD_PARITY is defined as
> >>
> >> #define AEU_INPUTS_ATTN_BITS_MCP_LATCHED_SCPAD_PARITY (0x1 << 31)
> >
> > Why not (1u << 31)?
>
> +1
>
> CC'd the QLogic maintainers as well.
>
>

      reply	other threads:[~2021-06-11 18:16 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-06-10 20:51 Owen Hilyard
2021-06-10 21:36 ` Stephen Hemminger
2021-06-11  9:19   ` Morten Brørup
2021-06-11 14:34   ` Aaron Conole
2021-06-11 18:15     ` Owen Hilyard [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=CAHx6DYC8gx+3u7Sbt9LgkgM5U0-_+uaeKvpUUw8ZAn5juOrCug@mail.gmail.com \
    --to=ohilyard@iol.unh.edu \
    --cc=aconole@redhat.com \
    --cc=david.marchand@redhat.com \
    --cc=dev@dpdk.org \
    --cc=rmody@marvell.com \
    --cc=shshaikh@marvell.com \
    --cc=stephen@networkplumber.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).