Make a GPU class in VideoCore to contain the GPU state.

Also moved the GPU MemoryManager class to video_core since it makes more sense for it to be there.
This commit is contained in:
Subv
2018-02-11 23:44:12 -05:00
parent e01a8f2187
commit 6cddf9d88e
20 changed files with 125 additions and 76 deletions

View File

@ -11,7 +11,6 @@
#include "core/hle/service/nvdrv/devices/nvhost_gpu.h"
#include "core/hle/service/nvdrv/devices/nvmap.h"
#include "core/hle/service/nvdrv/interface.h"
#include "core/hle/service/nvdrv/memory_manager.h"
#include "core/hle/service/nvdrv/nvdrv.h"
#include "core/hle/service/nvdrv/nvmemp.h"
@ -32,10 +31,8 @@ void InstallInterfaces(SM::ServiceManager& service_manager) {
Module::Module() {
auto nvmap_dev = std::make_shared<Devices::nvmap>();
auto memory_manager = std::make_shared<MemoryManager>();
devices["/dev/nvhost-as-gpu"] =
std::make_shared<Devices::nvhost_as_gpu>(nvmap_dev, memory_manager);
devices["/dev/nvhost-gpu"] = std::make_shared<Devices::nvhost_gpu>(nvmap_dev, memory_manager);
devices["/dev/nvhost-as-gpu"] = std::make_shared<Devices::nvhost_as_gpu>(nvmap_dev);
devices["/dev/nvhost-gpu"] = std::make_shared<Devices::nvhost_gpu>(nvmap_dev);
devices["/dev/nvhost-ctrl-gpu"] = std::make_shared<Devices::nvhost_ctrl_gpu>();
devices["/dev/nvmap"] = nvmap_dev;
devices["/dev/nvdisp_disp0"] = std::make_shared<Devices::nvdisp_disp0>(nvmap_dev);