summaryrefslogtreecommitdiff
path: root/Documentation/devicetree/bindings/iommu
diff options
context:
space:
mode:
authorTycho Andersen <tycho@tycho.ws>2018-04-24 23:26:39 +0300
committerJames Morris <james.morris@microsoft.com>2018-05-11 23:07:49 +0300
commit890e2abe1028c39e5399101a2c277219cd637aaa (patch)
tree6e3997847bd92871d1ee00916fcd04d59f19126a /Documentation/devicetree/bindings/iommu
parent383203eff718d7397ffc68ac6c3ed644d3017fc7 (diff)
downloadlinux-890e2abe1028c39e5399101a2c277219cd637aaa.tar.xz
dh key: get rid of stack allocated array for zeroes
We're interested in getting rid of all of the stack allocated arrays in the kernel: https://lkml.org/lkml/2018/3/7/621 This case is interesting, since we really just need an array of bytes that are zero. The loop already ensures that if the array isn't exactly the right size that enough zero bytes will be copied in. So, instead of choosing this value to be the size of the hash, let's just choose it to be 32, since that is a common size, is not too big, and will not result in too many extra iterations of the loop. v2: split out from other patch, just hardcode array size instead of dynamically allocating something the right size v3: fix typo of 256 -> 32 Signed-off-by: Tycho Andersen <tycho@tycho.ws> Reviewed-by: Kees Cook <keescook@chromium.org> CC: David Howells <dhowells@redhat.com> CC: James Morris <jmorris@namei.org> CC: "Serge E. Hallyn" <serge@hallyn.com> CC: Eric Biggers <ebiggers3@gmail.com> Signed-off-by: James Morris <james.morris@microsoft.com>
Diffstat (limited to 'Documentation/devicetree/bindings/iommu')
0 files changed, 0 insertions, 0 deletions