netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Jeff Garzik <jeff@garzik.org>
To: Netdev List <netdev@vger.kernel.org>
Subject: d80211: bitfield usage should go
Date: Wed, 09 Aug 2006 05:07:41 -0400	[thread overview]
Message-ID: <44D9A5DD.8080103@garzik.org> (raw)

I'm doing an in-depth review of d80211 right now.

One issue that leaps out:  use of bitfields.

1) single-bit signed bitfields are undefined

	int wep_include_iv:1;

2) bitfields in general generate HORRIBLE code.  Just don't use them. 
Compilers often fail to use even the most obvious simplifications.

Use flags and bitwise operators instead, like most other Linux code.


                 reply	other threads:[~2006-08-09  9:07 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

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=44D9A5DD.8080103@garzik.org \
    --to=jeff@garzik.org \
    --cc=netdev@vger.kernel.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).