projects
/
openwrt
/
staging
/
blogic.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
85a9c0b
)
drm/i915/selftests: Allow random array allocation to fail
author
Chris Wilson
<
[email protected]
>
Sat, 23 Dec 2017 11:04:07 +0000
(11:04 +0000)
committer
Chris Wilson
<
[email protected]
>
Tue, 2 Jan 2018 15:30:40 +0000
(15:30 +0000)
In the selftests, we don't want to force an oom and would rather
ENOMEM be reported. In this case, we would rather the allocation for the
random array to fail.
Signed-off-by: Chris Wilson <
[email protected]
>
Reviewed-by: Matthew Auld <
[email protected]
>
Link:
https://patchwork.freedesktop.org/patch/msgid/
[email protected]
drivers/gpu/drm/i915/selftests/i915_random.c
patch
|
blob
|
history
diff --git
a/drivers/gpu/drm/i915/selftests/i915_random.c
b/drivers/gpu/drm/i915/selftests/i915_random.c
index 2088ae57aa899184e611b219bda5202d68b51d51..1f415ce4701831758935465a330e11eb2cf9dfc9 100644
(file)
--- a/
drivers/gpu/drm/i915/selftests/i915_random.c
+++ b/
drivers/gpu/drm/i915/selftests/i915_random.c
@@
-57,7
+57,8
@@
unsigned int *i915_random_order(unsigned int count, struct rnd_state *state)
{
unsigned int *order, i;
- order = kmalloc_array(count, sizeof(*order), GFP_KERNEL | __GFP_NOWARN);
+ order = kmalloc_array(count, sizeof(*order),
+ GFP_KERNEL | __GFP_RETRY_MAYFAIL | __GFP_NOWARN);
if (!order)
return order;