From mboxrd@z Thu Jan 1 00:00:00 1970 From: Arend van Spriel Subject: Re: [PATCH] brcmfmac: drop Inter-Access Point Protocol packets by default Date: Wed, 14 Mar 2018 21:55:23 +0100 Message-ID: <5AA98C3B.2070406@broadcom.com> References: <20180314110119.13631-1-zajec5@gmail.com> <878tau7n23.fsf@codeaurora.org> <52b1812dd3e843adb63ff67fbe95975f@milecki.pl> <877eqe63kr.fsf@codeaurora.org> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 8bit Cc: =?UTF-8?B?UmFmYcWCIE1pxYJlY2tp?= , Franky Lin , Hante Meuleman , Chi-Hsien Lin , Wright Feng , Pieter-Paul Giesberts , James Hughes , linux-wireless-u79uwXL29TY76Z2rM5mHXA@public.gmane.org, brcm80211-dev-list.pdl-dY08KVG/lbpWk0Htik3J/w@public.gmane.org, brcm80211-dev-list-+wT8y+m8/X5BDgjK7y7TUQ@public.gmane.org, netdev-u79uwXL29TY76Z2rM5mHXA@public.gmane.org, =?UTF-8?Q?Linus_L=c3=bcssing?= , Felix Fietkau , bridge-cunTk1MwBs9QetFLy7KEm3xJsTq8ys+cHZ5vskTnxNA@public.gmane.org To: Kalle Valo , =?UTF-8?B?UmFmYcWCIE1pxYJlY2tp?= Return-path: In-Reply-To: <877eqe63kr.fsf-sgV2jX0FEOL9JmXXK+q4OQ@public.gmane.org> Sender: linux-wireless-owner-u79uwXL29TY76Z2rM5mHXA@public.gmane.org List-Id: netdev.vger.kernel.org On 3/14/2018 5:10 PM, Kalle Valo wrote: > Rafał Miłecki writes: > >>>> + unsigned char *eth_data = skb_mac_header(skb) + ETH_HLEN; >>>> +#if !defined(CONFIG_HAVE_EFFICIENT_UNALIGNED_ACCESS) >>> >>> #ifndef? >> >> I followed what is used in the include/linux/etherdevice.h. Is that a >> good exceuse? Could it be there any some good reason for #if defined()? > > Don't know, maybe just a matter of taste? But it would be nice to know > the background behind #ifdef vs #if defined(), never figured it out why > two different forms. Well. In this case you could use either one, but if you have more conditions #if defined() is bit more efficient: #ifdef A #ifdef B #endif #endif vs. #if defined(A) && defined(B) Regards, Arend