| 1241 | } |
| 1242 | |
| 1243 | void |
| 1244 | Clear_Span(const std::string &devicePath) |
| 1245 | { |
| 1246 | Cache cache; |
| 1247 | if ((err = cache.loadSpan(SpanFile))) { |
| 1248 | cache.dumpSpans(Cache::SpanDumpDepth::SPAN); |
| 1249 | for (auto sp : cache._spans) { |
| 1250 | if (devicePath.size() > 0 && sp->_path.view() == devicePath) { |
| 1251 | printf("clearing %s\n", devicePath.data()); |
| 1252 | sp->clearPermanently(); |
| 1253 | } |
| 1254 | } |
| 1255 | } |
| 1256 | return; |
| 1257 | } |
| 1258 | |
| 1259 | void |
| 1260 | Check_Freelist(const std::string &devicePath) |