From: Dan Carpenter Date: Tue, 27 Apr 2010 21:06:05 +0000 (-0700) Subject: sbshc: acpi_device_class "smbus_host_controller" too long X-Git-Tag: MMI-PSA29.97-13-9~24000^2^5~1 X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=97c227cb51ddcf52c66f7a7fba69237026418b56;p=GitHub%2FMotorolaMobilityLLC%2Fkernel-slsi.git sbshc: acpi_device_class "smbus_host_controller" too long acpi_device_class can only be 19 characters and a NULL terminator. With the current name we get a buffer overflow in acpi_smbus_hc_add() when we do: strcpy(acpi_device_class(device), ACPI_SMB_HC_CLASS); Signed-off-by: Dan Carpenter Cc: Alexey Starikovskiy Signed-off-by: Andrew Morton Signed-off-by: Len Brown --- diff --git a/drivers/acpi/sbshc.c b/drivers/acpi/sbshc.c index 36704b887ccf..f8be23b6c129 100644 --- a/drivers/acpi/sbshc.c +++ b/drivers/acpi/sbshc.c @@ -18,7 +18,7 @@ #define PREFIX "ACPI: " -#define ACPI_SMB_HC_CLASS "smbus_host_controller" +#define ACPI_SMB_HC_CLASS "smbus_host_ctl" #define ACPI_SMB_HC_DEVICE_NAME "ACPI SMBus HC" struct acpi_smb_hc {