search for: d6da8a5

Displaying 1 result from an estimated 1 matches for "d6da8a5".

Did you mean: 766da8a5
2013 Dec 26
0
[PATCH] core: Avoid initializing the cache more than once
...device_init(void *args) dev.disk = firmware->disk_init(args); dev.cache_size = 128*1024; dev.cache_data = malloc(dev.cache_size); + dev.cache_init = 0; /* Explicitly set cache as uninitialized */ return &dev; } diff --git a/core/fs/fs.c b/core/fs/fs.c index 8c1feea..d6da8a5 100644 --- a/core/fs/fs.c +++ b/core/fs/fs.c @@ -422,8 +422,9 @@ void fs_init(const struct fs_ops **ops, void *priv) } this_fs = &fs; - /* initialize the cache */ - if (fs.fs_dev && fs.fs_dev->cache_data) + /* initialize the cache only if it wasn't already in...