summaryrefslogtreecommitdiff
path: root/Kernel/Graphics
diff options
context:
space:
mode:
authorAndreas Kling <kling@serenityos.org>2021-07-22 09:03:13 +0200
committerAndreas Kling <kling@serenityos.org>2021-07-22 09:17:02 +0200
commit5217875f6ae204e6b23862ab28549364599a9729 (patch)
treeb17ba0a078a43f2514e187c95de16e5a3a83ac0f /Kernel/Graphics
parent9e15708aa08454d6418c256a82ac21597eee20fe (diff)
downloadserenity-5217875f6ae204e6b23862ab28549364599a9729.zip
Kernel: Consolidate API for creating AnonymousVMObject with given pages
We don't need to have a dedicated API for creating a VMObject with a single page, the multi-page API option works in all cases. Also make the API take a Span<NonnullRefPtr<PhysicalPage>> instead of a NonnullRefPtrVector<PhysicalPage>.
Diffstat (limited to 'Kernel/Graphics')
-rw-r--r--Kernel/Graphics/VirtIOGPU/FrameBufferDevice.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/Kernel/Graphics/VirtIOGPU/FrameBufferDevice.cpp b/Kernel/Graphics/VirtIOGPU/FrameBufferDevice.cpp
index 4ea92dcb99..49b9bee8f7 100644
--- a/Kernel/Graphics/VirtIOGPU/FrameBufferDevice.cpp
+++ b/Kernel/Graphics/VirtIOGPU/FrameBufferDevice.cpp
@@ -40,7 +40,7 @@ void FrameBufferDevice::create_framebuffer()
for (auto i = 0u; i < num_needed_pages; ++i) {
pages.append(write_sink_page);
}
- m_framebuffer_sink_vmobject = AnonymousVMObject::try_create_with_physical_pages(move(pages));
+ m_framebuffer_sink_vmobject = AnonymousVMObject::try_create_with_physical_pages(pages.span());
MutexLocker locker(m_gpu.operation_lock());
m_current_buffer = &buffer_from_index(m_last_set_buffer_index.load());