* [PATCH] acpi: check for pxm_to_node_map overflow
@ 2009-02-28 15:17 Cyrill Gorcunov
0 siblings, 0 replies; only message in thread
From: Cyrill Gorcunov @ 2009-02-28 15:17 UTC (permalink / raw)
To: Len Brown; +Cc: Andrew Morton, LKML
It is hardly (if ever) possible but in case of broken _PXM
entry we could reach out of pxm_to_node_map array
bounds in acpi_map_pxm_to_node() call.
Signed-off-by: Cyrill Gorcunov <gorcunov@openvz.org>
CC: Len Brown <lenb@kernel.org>
---
It's a patch resend. I didn't get any response on
previous submission from Len, oh :(
Len is the patch really not needed or such a situation
can't happen?
drivers/acpi/numa.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
Index: linux-2.6.git/drivers/acpi/numa.c
===================================================================
--- linux-2.6.git.orig/drivers/acpi/numa.c
+++ linux-2.6.git/drivers/acpi/numa.c
@@ -277,7 +277,7 @@ int acpi_get_node(acpi_handle *handle)
int pxm, node = -1;
pxm = acpi_get_pxm(handle);
- if (pxm >= 0)
+ if (pxm >= 0 && pxm < MAX_PXM_DOMAINS)
node = acpi_map_pxm_to_node(pxm);
return node;
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2009-02-28 15:18 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-02-28 15:17 [PATCH] acpi: check for pxm_to_node_map overflow Cyrill Gorcunov
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.