kernel/vm: Fix and reactivate VMAnonymousNoSwapCache::Merge.
It seems this method was never renamed when MergeStore was renamed to Merge all the way back in hrev27179. However, that wound up working out, because this method also didn't call the base class implementation that actually merges the page trees properly, so it wouldn't have worked anyway.
This commit is contained in:
@@ -165,17 +165,17 @@ VMAnonymousNoSwapCache::Fault(struct VMAddressSpace* aspace, off_t offset)
|
||||
|
||||
|
||||
void
|
||||
VMAnonymousNoSwapCache::MergeStore(VMCache* _source)
|
||||
VMAnonymousNoSwapCache::Merge(VMCache* _source)
|
||||
{
|
||||
VMAnonymousNoSwapCache* source
|
||||
= dynamic_cast<VMAnonymousNoSwapCache*>(_source);
|
||||
if (source == NULL) {
|
||||
panic("VMAnonymousNoSwapCache::MergeStore(): merge with incompatible "
|
||||
panic("VMAnonymousNoSwapCache::Merge(): merge with incompatible "
|
||||
"cache %p requested", _source);
|
||||
return;
|
||||
}
|
||||
|
||||
// take over the source' committed size
|
||||
// take over the source's committed size
|
||||
committed_size += source->committed_size;
|
||||
source->committed_size = 0;
|
||||
|
||||
@@ -184,6 +184,8 @@ VMAnonymousNoSwapCache::MergeStore(VMCache* _source)
|
||||
vm_unreserve_memory(committed_size - actualSize);
|
||||
committed_size = actualSize;
|
||||
}
|
||||
|
||||
VMCache::Merge(source);
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -39,7 +39,7 @@ public:
|
||||
virtual status_t Fault(struct VMAddressSpace* aspace,
|
||||
off_t offset);
|
||||
|
||||
virtual void MergeStore(VMCache* source);
|
||||
virtual void Merge(VMCache* source);
|
||||
|
||||
protected:
|
||||
virtual void DeleteObject();
|
||||
|
||||
Reference in New Issue
Block a user