drivers/firmware: const-ify DMI API and internals
authorJeff Garzik <jeff@garzik.org>
Wed, 3 Oct 2007 19:15:40 +0000 (15:15 -0400)
committerJeff Garzik <jeff@garzik.org>
Wed, 10 Oct 2007 00:22:20 +0000 (20:22 -0400)
commit1855256c497ecfefc730df6032243f26855ce52c
treeb73947f1a5e1b798e1dec068ac1cda25ae910bf6
parentbbf25010f1a6b761914430f5fca081ec8c7accd1
drivers/firmware: const-ify DMI API and internals

Three main sets of changes:

1) dmi_get_system_info() return value should have been marked const,
   since callers should not be changing that data.

2) const-ify DMI internals, since DMI firmware tables should,
   whenever possible, be marked const to ensure we never ever write to
   that data area.

3) const-ify DMI API, to enable marking tables const where possible
   in low-level drivers.

And if we're really lucky, this might enable some additional
optimizations on the part of the compiler.

The bulk of the changes are #2 and #3, which are interrelated.  #1 could
have been a separate patch, but it was so small compared to the others,
it was easier to roll it into this changeset.

Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
35 files changed:
arch/i386/kernel/acpi/boot.c
arch/i386/kernel/acpi/sleep.c
arch/i386/kernel/apm.c
arch/i386/kernel/cpu/cpufreq/acpi-cpufreq.c
arch/i386/kernel/reboot.c
arch/i386/kernel/tsc.c
arch/i386/mach-generic/bigsmp.c
arch/i386/pci/common.c
arch/i386/pci/irq.c
drivers/acpi/osl.c
drivers/acpi/processor_idle.c
drivers/acpi/sleep/main.c
drivers/acpi/thermal.c
drivers/ata/ata_piix.c
drivers/ata/pata_ali.c
drivers/ata/pata_cs5530.c
drivers/ata/pata_via.c
drivers/char/i8k.c
drivers/char/ipmi/ipmi_si_intf.c
drivers/firmware/dmi_scan.c
drivers/hwmon/abituguru.c
drivers/hwmon/applesmc.c
drivers/hwmon/hdaps.c
drivers/ide/pci/alim15x3.c
drivers/ide/pci/via82cxxx.c
drivers/input/misc/wistron_btns.c
drivers/input/mouse/lifebook.c
drivers/input/mouse/synaptics.c
drivers/misc/msi-laptop.c
drivers/misc/sony-laptop.c
drivers/misc/thinkpad_acpi.c
drivers/pnp/pnpbios/core.c
drivers/usb/host/uhci-hcd.c
drivers/video/imacfb.c
include/linux/dmi.h