diff options
author | Aidan MacDonald <amachronic@protonmail.com> | 2022-01-18 18:57:06 +0000 |
---|---|---|
committer | Aidan MacDonald <amachronic@protonmail.com> | 2022-02-12 10:24:32 -0500 |
commit | e8faf2f2adeb9066de3c968a57803bb262f61ee1 (patch) | |
tree | 130c2e3d904da7876ac88ea089f85f48cab5e313 /lib/x1000-installer/src/xf_nandio.c | |
parent | 95dfc489b5a602f68202b206c434f8485e9d3915 (diff) | |
download | rockbox-e8faf2f2adeb9066de3c968a57803bb262f61ee1.tar.gz rockbox-e8faf2f2adeb9066de3c968a57803bb262f61ee1.zip |
buflib: add a common dummy callbacks struct & use it
There are various allocations that can't be moved or shrunk.
Provide a global callback struct for this use case instead of
making each caller declare its own dummy struct.
Also fixed ROLO and x1000 installer code which incorrectly
used movable allocations.
Change-Id: I00088396b9826e02e69a4a33477fe1a7816374f1
Diffstat (limited to 'lib/x1000-installer/src/xf_nandio.c')
-rw-r--r-- | lib/x1000-installer/src/xf_nandio.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/x1000-installer/src/xf_nandio.c b/lib/x1000-installer/src/xf_nandio.c index ba79cbbcbf..29ff9d9120 100644 --- a/lib/x1000-installer/src/xf_nandio.c +++ b/lib/x1000-installer/src/xf_nandio.c | |||
@@ -51,7 +51,7 @@ int xf_nandio_init(struct xf_nandio* nio) | |||
51 | alloc_size += CACHEALIGN_SIZE - 1; | 51 | alloc_size += CACHEALIGN_SIZE - 1; |
52 | alloc_size += nio->block_size * 2; | 52 | alloc_size += nio->block_size * 2; |
53 | 53 | ||
54 | nio->alloc_handle = core_alloc("xf_nandio", alloc_size); | 54 | nio->alloc_handle = core_alloc_ex("xf_nandio", alloc_size, &buflib_ops_locked); |
55 | if(nio->alloc_handle < 0) { | 55 | if(nio->alloc_handle < 0) { |
56 | rc = XF_E_OUT_OF_MEMORY; | 56 | rc = XF_E_OUT_OF_MEMORY; |
57 | goto out_nclose; | 57 | goto out_nclose; |