git.samba.org
/
sfrench
/
cifs-2.6.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
| inline |
side by side
Merge tag 'drm-fixes-for-v4.12-rc2' of git://people.freedesktop.org/~airlied/linux
[sfrench/cifs-2.6.git]
/
drivers
/
of
/
fdt.c
diff --git
a/drivers/of/fdt.c
b/drivers/of/fdt.c
index 3080d9dd031d14f27553b8596dc4d2dc0248bdfa..43bd69dceabfd36b43368366b8afdc9fa2b30106 100644
(file)
--- a/
drivers/of/fdt.c
+++ b/
drivers/of/fdt.c
@@
-507,6
+507,9
@@
void *__unflatten_device_tree(const void *blob,
/* Allocate memory for the expanded device tree */
mem = dt_alloc(size + 4, __alignof__(struct device_node));
+ if (!mem)
+ return NULL;
+
memset(mem, 0, size);
*(__be32 *)(mem + size) = cpu_to_be32(0xdeadbeef);