linux/include
Behan Webster a0a77af141 crypto: LLVMLinux: Add macro to remove use of VLAIS in crypto code
Add a macro which replaces the use of a Variable Length Array In Struct (VLAIS)
with a C99 compliant equivalent. This macro instead allocates the appropriate
amount of memory using an char array.

The new code can be compiled with both gcc and clang.

struct shash_desc contains a flexible array member member ctx declared with
CRYPTO_MINALIGN_ATTR, so sizeof(struct shash_desc) aligns the beginning
of the array declared after struct shash_desc with long long.

No trailing padding is required because it is not a struct type that can
be used in an array.

The CRYPTO_MINALIGN_ATTR is required so that desc is aligned with long long
as would be the case for a struct containing a member with
CRYPTO_MINALIGN_ATTR.

If you want to get to the ctx at the end of the shash_desc as before you can do
so using shash_desc_ctx(shash)

Signed-off-by: Behan Webster <behanw@converseincode.com>
Reviewed-by: Mark Charlebois <charlebm@gmail.com>
Acked-by: Herbert Xu <herbert@gondor.apana.org.au>
Cc: Michał Mirosław <mirqus@gmail.com>
2014-10-14 10:51:22 +02:00
..
acpi ACPICA: Introduce acpi_enable_all_wakeup_gpes() 2014-09-30 21:04:47 +02:00
asm-generic mm: softdirty: enable write notifications on VMAs after VM_SOFTDIRTY cleared 2014-10-14 02:18:28 +02:00
clocksource
crypto crypto: LLVMLinux: Add macro to remove use of VLAIS in crypto code 2014-10-14 10:51:22 +02:00
drm drm/mst: rework payload table allocation to conform better. 2014-10-13 14:40:53 +10:00
dt-bindings sound updates for 3.18-rc1 2014-10-10 22:13:25 -04:00
keys KEYS: Restore partial ID matching functionality for asymmetric keys 2014-10-06 15:21:05 +01:00
kvm arm/arm64: KVM: vgic: delay vgic allocation until init time 2014-09-18 18:48:58 -07:00
linux Merge branch 'drm-next' of git://people.freedesktop.org/~airlied/linux 2014-10-14 09:39:08 +02:00
math-emu
media Merge branch 'patchwork' into v4l_for_linus 2014-10-09 14:00:54 -03:00
memory
misc cxl: Add new header for call backs and structs 2014-10-08 20:15:43 +11:00
net lib80211: remove unused print_ssid() 2014-10-14 02:18:27 +02:00
pcmcia
ras PCI/AER: Rename PCI_ERR_UNC_TRAIN to PCI_ERR_UNC_UND 2014-09-25 09:42:40 -06:00
rdma IB: ib_umem_release() should decrement mm->pinned_vm from ib_umem_get 2014-09-19 09:55:42 -07:00
rxrpc include/rxrpc/types.h: Remove unused header 2014-08-29 20:33:39 -07:00
scsi Merge remote-tracking branch 'scsi-queue/drivers-for-3.18' into for-linus 2014-10-07 13:48:12 -07:00
soc/tegra
sound ASoC: Updates for v3.18 2014-10-06 14:01:11 +02:00
target
trace Merge branch 'core-rcu-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip 2014-10-13 15:44:12 +02:00
uapi Merge branch 'drm-next' of git://people.freedesktop.org/~airlied/linux 2014-10-14 09:39:08 +02:00
video gpu: ipu-v3: Add ipu_dump() 2014-09-02 14:55:56 +02:00
xen xen: remove DEFINE_XENBUS_DRIVER() macro 2014-10-06 10:27:57 +01:00
Kbuild