[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <1394177091.4653.1.camel@jlt4.sipsolutions.net>
Date: Fri, 07 Mar 2014 08:24:51 +0100
From: Johannes Berg <johannes@...solutions.net>
To: behanw@...verseincode.com
Cc: linville@...driver.com, davem@...emloft.net,
linux-wireless@...r.kernel.org, netdev@...r.kernel.org,
linux-kernel@...r.kernel.org, torvalds@...ux-foundation.org,
dwmw2@...radead.org, pageexec@...email.hu,
Jan-Simon Möller <dl9pf@....de>,
Vinícius Tinti <viniciustinti@...il.com>,
Mark Charlebois <charlebm@...il.com>
Subject: Re: [PATCH] mac80211: LLVMLinux: Remove VLAIS usage from mac80211
On Thu, 2014-03-06 at 11:52 -0800, behanw@...verseincode.com wrote:
> From: Jan-Simon Möller <dl9pf@....de>
>
> Replaced the use of a Variable Length Array In Struct (VLAIS) with a C99
> compliant equivalent.
Fine, but
> + char aead_req_data[sizeof(struct aead_request)
> + + crypto_aead_reqsize(tfm)
> + + CRYPTO_MINALIGN] CRYPTO_MINALIGN_ATTR;
You really should be using kernel coding style, which changes
indentation and has the + on the previous line.
> + struct aead_request *aead_req
> + = (struct aead_request *) aead_req_data;
(void *) is perfectly find and it'll probably fit on one line then.
> + memset(&aead_req_data, 0, (sizeof(struct aead_request)+
> + crypto_aead_reqsize(tfm) + CRYPTO_MINALIGN));
You don't need the size calculation again, you can use
sizeof(aead_req_data)
johannes
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Powered by blists - more mailing lists