From: Joe Perches <joe-6d6DIl74uiNBDgjK7y7TUQ@public.gmane.org>
To: Jean Sacren <sakiwit-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
Cc: Eric Dumazet
<eric.dumazet-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>,
netdev-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
linux-zigbee-devel-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org
Subject: Re: [PATCH net-next] ieee802154: fix variable declaration and initializer
Date: Tue, 18 Mar 2014 22:11:28 -0700 [thread overview]
Message-ID: <1395205888.8649.36.camel@joe-AO722> (raw)
In-Reply-To: <20140319045634.GB1448-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
On Tue, 2014-03-18 at 22:56 -0600, Jean Sacren wrote:
> Stating it is a "fix" is not a false statement at all. !! falsely
> changes the value to be int TWICE for nothing! Are you still not
> convinced?
Not so fast Jean. There's no logic change.
Changing the type to bool does exactly the same thing
and doesn't change the generated object code at all.
$ diff net/ieee802154/nl-phy.lst.new net/ieee802154/nl-phy.lst.old
2289d2288
< static int phy_set_lbt(struct wpan_phy *phy, struct genl_info *info)
2291c2290
< u8 on = !!nla_get_u8(info->attrs[IEEE802154_ATTR_LBT_ENABLED]);
---
> bool on;
2293a2293
> on = nla_get_u8(info->attrs[IEEE802154_ATTR_LBT_ENABLED]);
2296,2298d2295
< return 0;
< }
<
2301,2303c2298
< u8 on = !!nla_get_u8(info->attrs[IEEE802154_ATTR_LBT_ENABLED]);
< 1096: 80 78 04 00 cmpb $0x0,0x4(%rax)
< 109a: 41 0f 95 c5 setne %r13b
---
> bool on;
2305a2301,2303
> on = nla_get_u8(info->attrs[IEEE802154_ATTR_LBT_ENABLED]);
> 1096: 80 78 04 00 cmpb $0x0,0x4(%rax)
> 109a: 41 0f 95 c5 setne %r13b
2322c2320
<
---
------------------------------------------------------------------------------
Learn Graph Databases - Download FREE O'Reilly Book
"Graph Databases" is the definitive new guide to graph databases and their
applications. Written by three acclaimed leaders in the field,
this first edition is now available. Download your free book today!
http://p.sf.net/sfu/13534_NeoTech
next prev parent reply other threads:[~2014-03-19 5:11 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-03-19 3:19 [PATCH net-next] ieee802154: fix variable declaration and initializer Jean Sacren
[not found] ` <1395199198-14310-1-git-send-email-sakiwit-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
2014-03-19 3:32 ` Eric Dumazet
2014-03-19 3:42 ` Joe Perches
2014-03-19 4:35 ` Eric Dumazet
2014-03-19 4:56 ` Jean Sacren
[not found] ` <20140319045634.GB1448-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2014-03-19 5:11 ` Joe Perches [this message]
2014-03-19 5:13 ` Eric Dumazet
2014-03-19 5:11 ` Joe Perches
2014-03-19 4:31 ` Jean Sacren
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=1395205888.8649.36.camel@joe-AO722 \
--to=joe-6d6dil74uinbdgjk7y7tuq@public.gmane.org \
--cc=eric.dumazet-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org \
--cc=linux-zigbee-devel-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org \
--cc=netdev-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
--cc=sakiwit-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.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