diff options
author | James Bottomley <James.Bottomley@HansenPartnership.com> | 2019-10-11 09:02:59 -0700 |
---|---|---|
committer | Jarkko Sakkinen <jarkko.sakkinen@linux.intel.com> | 2019-11-12 21:45:37 +0200 |
commit | 44abdb377b7c399dfec48de7252c564bdde8d26e (patch) | |
tree | 11b24209034b5dc69aeeab8227a4c63bb5f5f504 /tools/usb | |
parent | f1689114acc5e89a196fec6d732dae3e48edb6ad (diff) | |
download | linux-44abdb377b7c399dfec48de7252c564bdde8d26e.tar.bz2 |
tpm: use GFP_KERNEL instead of GFP_HIGHMEM for tpm_buf
The current code uses GFP_HIGHMEM, which is wrong because GFP_HIGHMEM
(on 32 bit systems) is memory ordinarily inaccessible to the kernel
and should only be used for allocations affecting userspace. In order
to make highmem visible to the kernel on 32 bit it has to be kmapped,
which consumes valuable entries in the kmap region. Since the tpm_buf
is only ever used in the kernel, switch to using a GFP_KERNEL
allocation so as not to waste kmap space on 32 bits.
Reviewed-by: Jerry Snitselaar <jsnitsel@redhat.com>
Reviewed-by: Jarkko Sakkinen <jarkko.sakkinen@linux.intel.com>
Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
Signed-off-by: Jarkko Sakkinen <jarkko.sakkinen@linux.intel.com>
Diffstat (limited to 'tools/usb')
0 files changed, 0 insertions, 0 deletions