diff options
author | Juergen Gross <[email protected]> | 2020-07-01 14:16:37 +0200 |
---|---|---|
committer | Boris Ostrovsky <[email protected]> | 2020-07-02 16:19:34 -0500 |
commit | 3848e4e0a32afb96dc3b84e1358c3b9d103c6a2c (patch) | |
tree | 5f8d8c2b11ea908ddaee5045be1705c2ae9f3523 /scripts/gdb | |
parent | caef73cf207074a62701c95c317a97b2f8c1e04e (diff) |
xen/xenbus: avoid large structs and arrays on the stack
xenbus_map_ring_valloc() and its sub-functions are putting quite large
structs and arrays on the stack. This is problematic at runtime, but
might also result in build failures (e.g. with clang due to the option
-Werror,-Wframe-larger-than=... used).
Fix that by moving most of the data from the stack into a dynamically
allocated struct. Performance is no issue here, as
xenbus_map_ring_valloc() is used only when adding a new PV device to
a backend driver.
While at it move some duplicated code from pv/hvm specific mapping
functions to the single caller.
Reported-by: Arnd Bergmann <[email protected]>
Signed-off-by: Juergen Gross <[email protected]>
Reviewed-by: Boris Ostrovsky <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
Signed-off-by: Boris Ostrovsky <[email protected]>
Diffstat (limited to 'scripts/gdb')
0 files changed, 0 insertions, 0 deletions