]> git.baikalelectronics.ru Git - kernel.git/commit
tpm: tpm_crb: constify acpi_device_id.
authorArvind Yadav <arvind.yadav.cs@gmail.com>
Thu, 6 Jul 2017 17:48:39 +0000 (23:18 +0530)
committerJames Morris <james.l.morris@oracle.com>
Sun, 24 Sep 2017 04:49:52 +0000 (21:49 -0700)
commit0809dd49448a7af64e9290177ff4857a9be9c71a
treeceb2528962c32f8a71ae218f04e6ac0595e07103
parent1c8c9f63478f8fa1aa0f7629df74ee0200415ef9
tpm: tpm_crb: constify acpi_device_id.

acpi_device_id are not supposed to change at runtime. All functions
working with acpi_device_id provided by <acpi/acpi_bus.h> work with
const acpi_device_id. So mark the non-const structs as const.

File size before:
   text    data     bss     dec     hex filename
   4198     608       0    4806    12c6 drivers/char/tpm/tpm_crb.o

File size After adding 'const':
   text    data     bss     dec     hex filename
   4262     520       0    4782    12ae drivers/char/tpm/tpm_crb.o

Signed-off-by: Arvind Yadav <arvind.yadav.cs@gmail.com>
Reviewed-by: Jarkko Sakkinen <jarkko.sakkinen@linux.intel.com>
Tested-by: Jarkko Sakkinen <jarkko.sakkinen@linux.intel.com>
Signed-off-by: Jarkko Sakkinen <jarkko.sakkinen@linux.intel.com>
Signed-off-by: James Morris <james.l.morris@oracle.com>
drivers/char/tpm/tpm_crb.c