diff options
| author | Wolfram Sang <wsa@kernel.org> | 2023-04-24 12:50:20 +0200 |
|---|---|---|
| committer | Wolfram Sang <wsa@kernel.org> | 2023-04-24 12:50:20 +0200 |
| commit | 38c87827ffd3c7e1dd61eee9a7dea13d487dc2ed (patch) | |
| tree | e6bd1c3ae56823874a736c1512409c123c9a4219 /drivers/base/cacheinfo.c | |
| parent | i2c: omap: Improve error reporting for problems during .remove() (diff) | |
| parent | i2c: xiic: xiic_xfer(): Fix runtime PM leak on error path (diff) | |
| download | linux-38c87827ffd3c7e1dd61eee9a7dea13d487dc2ed.tar.gz linux-38c87827ffd3c7e1dd61eee9a7dea13d487dc2ed.zip | |
Merge branch 'i2c/for-current' into i2c/for-mergewindow
This should have been in 6.3, but sadly I missed it.
Diffstat (limited to 'drivers/base/cacheinfo.c')
| -rw-r--r-- | drivers/base/cacheinfo.c | 16 |
1 files changed, 11 insertions, 5 deletions
diff --git a/drivers/base/cacheinfo.c b/drivers/base/cacheinfo.c index f6573c335f4c..f3903d002819 100644 --- a/drivers/base/cacheinfo.c +++ b/drivers/base/cacheinfo.c @@ -474,12 +474,18 @@ int detect_cache_attributes(unsigned int cpu) populate_leaves: /* - * populate_cache_leaves() may completely setup the cache leaves and - * shared_cpu_map or it may leave it partially setup. + * If LLC is valid the cache leaves were already populated so just go to + * update the cpu map. */ - ret = populate_cache_leaves(cpu); - if (ret) - goto free_ci; + if (!last_level_cache_is_valid(cpu)) { + /* + * populate_cache_leaves() may completely setup the cache leaves and + * shared_cpu_map or it may leave it partially setup. + */ + ret = populate_cache_leaves(cpu); + if (ret) + goto free_ci; + } /* * For systems using DT for cache hierarchy, fw_token |
