* [PATCH] ACPI, APEI, fix ERST table size checking
@ 2011-09-05 21:07 Colin King
2011-09-11 21:46 ` Thomas Renninger
0 siblings, 1 reply; 3+ messages in thread
From: Colin King @ 2011-09-05 21:07 UTC (permalink / raw)
To: Len Brown, linux-acpi
From: Colin Ian King <colin.king@canonical.com>
Check ERST size against acpi_table_erst rather than
acpi_table_einj. The original code just so happened to work
because the ERST and EINJ headers are the same size.
Signed-off-by: Colin Ian King <colin.king@canonical.com>
---
drivers/acpi/apei/erst.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/drivers/acpi/apei/erst.c b/drivers/acpi/apei/erst.c
index 2ca59dc..5f6153e 100644
--- a/drivers/acpi/apei/erst.c
+++ b/drivers/acpi/apei/erst.c
@@ -917,7 +917,7 @@ static int erst_check_table(struct acpi_table_erst *erst_tab)
{
if ((erst_tab->header_length !=
(sizeof(struct acpi_table_erst) - sizeof(erst_tab->header)))
- && (erst_tab->header_length != sizeof(struct acpi_table_einj)))
+ && (erst_tab->header_length != sizeof(struct acpi_table_erst)))
return -EINVAL;
if (erst_tab->header.length < sizeof(struct acpi_table_erst))
return -EINVAL;
--
1.7.0.4
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH] ACPI, APEI, fix ERST table size checking
2011-09-05 21:07 [PATCH] ACPI, APEI, fix ERST table size checking Colin King
@ 2011-09-11 21:46 ` Thomas Renninger
0 siblings, 0 replies; 3+ messages in thread
From: Thomas Renninger @ 2011-09-11 21:46 UTC (permalink / raw)
To: Colin King; +Cc: Len Brown, linux-acpi
On Monday 05 September 2011 23:07:36 Colin King wrote:
> From: Colin Ian King <colin.king@canonical.com>
>
> Check ERST size against acpi_table_erst rather than
> acpi_table_einj. The original code just so happened to work
> because the ERST and EINJ headers are the same size.
>
> Signed-off-by: Colin Ian King <colin.king@canonical.com>
This looks like a candidate for stable and should either get:
CC: stable@kernel.org
or get submitted there manually.
Thanks,
Thomas
^ permalink raw reply [flat|nested] 3+ messages in thread
* [PATCH] ACPI, APEI, fix ERST table size checking
@ 2012-03-23 8:48 Colin King
0 siblings, 0 replies; 3+ messages in thread
From: Colin King @ 2012-03-23 8:48 UTC (permalink / raw)
To: Len Brown, Matthew Garrett, linux-acpi; +Cc: linux-kernel
From: Colin Ian King <colin.king@canonical.com>
Check ERST size against acpi_table_erst rather than
acpi_table_einj. The original code just so happened to work
because the ERST and EINJ headers are the same size.
I'm re-sending this patch as it didn't seem to get picked up when I first
sent it to the list back in September 2011.
Signed-off-by: Colin Ian King <colin.king@canonical.com>
Cc: stable@kernel.org
---
drivers/acpi/apei/erst.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/drivers/acpi/apei/erst.c b/drivers/acpi/apei/erst.c
index eb9fab5..e4d9d24 100644
--- a/drivers/acpi/apei/erst.c
+++ b/drivers/acpi/apei/erst.c
@@ -917,7 +917,7 @@ static int erst_check_table(struct acpi_table_erst *erst_tab)
{
if ((erst_tab->header_length !=
(sizeof(struct acpi_table_erst) - sizeof(erst_tab->header)))
- && (erst_tab->header_length != sizeof(struct acpi_table_einj)))
+ && (erst_tab->header_length != sizeof(struct acpi_table_erst)))
return -EINVAL;
if (erst_tab->header.length < sizeof(struct acpi_table_erst))
return -EINVAL;
--
1.7.0.4
^ permalink raw reply related [flat|nested] 3+ messages in thread
end of thread, other threads:[~2012-03-23 8:49 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-09-05 21:07 [PATCH] ACPI, APEI, fix ERST table size checking Colin King
2011-09-11 21:46 ` Thomas Renninger
-- strict thread matches above, loose matches on Subject: below --
2012-03-23 8:48 Colin King
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox