Messages in this thread | | | Date | Fri, 14 Mar 2014 11:50:39 +0100 | Subject | Re: [PATCH v2 5/5] gpio / ACPI: Add support for ACPI GPIO operation regions | From | Linus Walleij <> |
| |
On Thu, Mar 13, 2014 at 4:05 PM, Cox, Alan <alan.cox@intel.com> wrote: >> > + gpiod_set_raw_value(desc, !!((1 << i) & *value)); >> >> What is this? How can the expression !!((1 << i) possibly evaluate to >> anything else than "true"? I don't get it. Just (desc, *value) seem more >> apropriate. > > > The expression is !!((1 << i) & *value) > > so its the standard C sematic for 'logical and' ? 1 : 0
Hm I missed the first paranthesis when parsing in my head, all wrong, too bad. Thanks Alan.
Yours, Linus Walleij
| |