File tree Expand file tree Collapse file tree 14 files changed +29
-29
lines changed Expand file tree Collapse file tree 14 files changed +29
-29
lines changed Original file line number Diff line number Diff line change @@ -34,7 +34,7 @@ UNMAP_AFTER_INIT ErrorOr<bool> VoodooGraphicsAdapter::probe(PCI::DeviceIdentifie
34
34
return id.vendor_id == PCI::VendorID::Tdfx && is_supported_model (id.device_id );
35
35
}
36
36
37
- UNMAP_AFTER_INIT ErrorOr<NonnullLockRefPtr<GenericGraphicsAdapter >> VoodooGraphicsAdapter::create (PCI::DeviceIdentifier const & pci_device_identifier)
37
+ UNMAP_AFTER_INIT ErrorOr<NonnullLockRefPtr<GPUDevice >> VoodooGraphicsAdapter::create (PCI::DeviceIdentifier const & pci_device_identifier)
38
38
{
39
39
auto adapter = TRY (adopt_nonnull_lock_ref_or_enomem (new (nothrow) VoodooGraphicsAdapter (pci_device_identifier)));
40
40
MUST (adapter->initialize_adapter (pci_device_identifier));
Original file line number Diff line number Diff line change 9
9
#include < AK/Types.h>
10
10
#include < Kernel/Bus/PCI/Device.h>
11
11
#include < Kernel/Devices/GPU/Console/GenericFramebufferConsole.h>
12
- #include < Kernel/Devices/GPU/GenericGraphicsAdapter .h>
12
+ #include < Kernel/Devices/GPU/GPUDevice .h>
13
13
14
14
namespace Kernel {
15
15
16
- class VoodooGraphicsAdapter final : public GenericGraphicsAdapter
16
+ class VoodooGraphicsAdapter final : public GPUDevice
17
17
, public PCI::Device {
18
18
19
19
public:
20
20
static ErrorOr<bool > probe (PCI::DeviceIdentifier const &);
21
- static ErrorOr<NonnullLockRefPtr<GenericGraphicsAdapter >> create (PCI::DeviceIdentifier const &);
21
+ static ErrorOr<NonnullLockRefPtr<GPUDevice >> create (PCI::DeviceIdentifier const &);
22
22
virtual ~VoodooGraphicsAdapter () = default ;
23
23
virtual StringView device_name () const override { return " VoodooGraphicsAdapter" sv; }
24
24
Original file line number Diff line number Diff line change @@ -33,7 +33,7 @@ UNMAP_AFTER_INIT ErrorOr<bool> BochsGraphicsAdapter::probe(PCI::DeviceIdentifier
33
33
return false ;
34
34
}
35
35
36
- UNMAP_AFTER_INIT ErrorOr<NonnullLockRefPtr<GenericGraphicsAdapter >> BochsGraphicsAdapter::create (PCI::DeviceIdentifier const & pci_device_identifier)
36
+ UNMAP_AFTER_INIT ErrorOr<NonnullLockRefPtr<GPUDevice >> BochsGraphicsAdapter::create (PCI::DeviceIdentifier const & pci_device_identifier)
37
37
{
38
38
auto adapter = TRY (adopt_nonnull_lock_ref_or_enomem (new (nothrow) BochsGraphicsAdapter (pci_device_identifier)));
39
39
MUST (adapter->initialize_adapter (pci_device_identifier));
Original file line number Diff line number Diff line change 10
10
#include < Kernel/Bus/PCI/Device.h>
11
11
#include < Kernel/Devices/GPU/Bochs/Definitions.h>
12
12
#include < Kernel/Devices/GPU/Console/GenericFramebufferConsole.h>
13
- #include < Kernel/Devices/GPU/GenericGraphicsAdapter .h>
13
+ #include < Kernel/Devices/GPU/GPUDevice .h>
14
14
#include < Kernel/Memory/PhysicalAddress.h>
15
15
#include < Kernel/Memory/TypedMapping.h>
16
16
@@ -19,13 +19,13 @@ namespace Kernel {
19
19
class GraphicsManagement ;
20
20
struct BochsDisplayMMIORegisters ;
21
21
22
- class BochsGraphicsAdapter final : public GenericGraphicsAdapter
22
+ class BochsGraphicsAdapter final : public GPUDevice
23
23
, public PCI::Device {
24
24
friend class GraphicsManagement ;
25
25
26
26
public:
27
27
static ErrorOr<bool > probe (PCI::DeviceIdentifier const &);
28
- static ErrorOr<NonnullLockRefPtr<GenericGraphicsAdapter >> create (PCI::DeviceIdentifier const &);
28
+ static ErrorOr<NonnullLockRefPtr<GPUDevice >> create (PCI::DeviceIdentifier const &);
29
29
virtual ~BochsGraphicsAdapter () = default ;
30
30
virtual StringView device_name () const override { return " BochsGraphicsAdapter" sv; }
31
31
Original file line number Diff line number Diff line change 8
8
9
9
#include < AK/AtomicRefCounted.h>
10
10
#include < AK/Types.h>
11
- #include < Kernel/Devices/GPU/GenericGraphicsAdapter .h>
11
+ #include < Kernel/Devices/GPU/GPUDevice .h>
12
12
13
13
namespace Kernel ::Graphics {
14
14
Original file line number Diff line number Diff line change 13
13
#include < Kernel/Memory/PhysicalAddress.h>
14
14
15
15
namespace Kernel {
16
- class GenericGraphicsAdapter
17
- : public AtomicRefCounted<GenericGraphicsAdapter >
18
- , public LockWeakable<GenericGraphicsAdapter > {
16
+ class GPUDevice
17
+ : public AtomicRefCounted<GPUDevice >
18
+ , public LockWeakable<GPUDevice > {
19
19
public:
20
- virtual ~GenericGraphicsAdapter () = default ;
20
+ virtual ~GPUDevice () = default ;
21
21
22
22
protected:
23
- GenericGraphicsAdapter () = default ;
23
+ GPUDevice () = default ;
24
24
};
25
25
26
26
}
Original file line number Diff line number Diff line change @@ -32,7 +32,7 @@ ErrorOr<bool> IntelNativeGraphicsAdapter::probe(PCI::DeviceIdentifier const& pci
32
32
return is_supported_model (pci_device_identifier.hardware_id ().device_id );
33
33
}
34
34
35
- ErrorOr<NonnullLockRefPtr<GenericGraphicsAdapter >> IntelNativeGraphicsAdapter::create (PCI::DeviceIdentifier const & pci_device_identifier)
35
+ ErrorOr<NonnullLockRefPtr<GPUDevice >> IntelNativeGraphicsAdapter::create (PCI::DeviceIdentifier const & pci_device_identifier)
36
36
{
37
37
auto adapter = TRY (adopt_nonnull_lock_ref_or_enomem (new (nothrow) IntelNativeGraphicsAdapter (pci_device_identifier)));
38
38
TRY (adapter->initialize_adapter ());
@@ -67,7 +67,7 @@ ErrorOr<void> IntelNativeGraphicsAdapter::initialize_adapter()
67
67
}
68
68
69
69
IntelNativeGraphicsAdapter::IntelNativeGraphicsAdapter (PCI::DeviceIdentifier const & pci_device_identifier)
70
- : GenericGraphicsAdapter ()
70
+ : GPUDevice ()
71
71
, PCI::Device(const_cast <PCI::DeviceIdentifier&>(pci_device_identifier))
72
72
{
73
73
}
Original file line number Diff line number Diff line change 17
17
namespace Kernel {
18
18
19
19
class IntelNativeGraphicsAdapter final
20
- : public GenericGraphicsAdapter
20
+ : public GPUDevice
21
21
, public PCI::Device {
22
22
23
23
public:
24
24
static ErrorOr<bool > probe (PCI::DeviceIdentifier const &);
25
- static ErrorOr<NonnullLockRefPtr<GenericGraphicsAdapter >> create (PCI::DeviceIdentifier const &);
25
+ static ErrorOr<NonnullLockRefPtr<GPUDevice >> create (PCI::DeviceIdentifier const &);
26
26
27
27
virtual ~IntelNativeGraphicsAdapter () = default ;
28
28
Original file line number Diff line number Diff line change @@ -123,7 +123,7 @@ static inline bool is_display_controller_pci_device(PCI::DeviceIdentifier const&
123
123
124
124
struct PCIGraphicsDriverInitializer {
125
125
ErrorOr<bool > (*probe)(PCI::DeviceIdentifier const &) = nullptr ;
126
- ErrorOr<NonnullLockRefPtr<GenericGraphicsAdapter >> (*create)(PCI::DeviceIdentifier const &) = nullptr ;
126
+ ErrorOr<NonnullLockRefPtr<GPUDevice >> (*create)(PCI::DeviceIdentifier const &) = nullptr ;
127
127
};
128
128
129
129
static constexpr PCIGraphicsDriverInitializer s_initializers[] = {
Original file line number Diff line number Diff line change 15
15
#include < Kernel/Bus/PCI/Definitions.h>
16
16
#include < Kernel/Devices/GPU/Console/Console.h>
17
17
#include < Kernel/Devices/GPU/DisplayConnector.h>
18
+ #include < Kernel/Devices/GPU/GPUDevice.h>
18
19
#include < Kernel/Devices/GPU/Generic/DisplayConnector.h>
19
- #include < Kernel/Devices/GPU/GenericGraphicsAdapter.h>
20
20
#include < Kernel/Devices/GPU/VirtIO/GraphicsAdapter.h>
21
21
#include < Kernel/Library/NonnullLockRefPtr.h>
22
22
#include < Kernel/Memory/Region.h>
@@ -53,7 +53,7 @@ class GraphicsManagement {
53
53
54
54
void initialize_preset_resolution_generic_display_connector ();
55
55
56
- Vector<NonnullLockRefPtr<GenericGraphicsAdapter >> m_graphics_devices;
56
+ Vector<NonnullLockRefPtr<GPUDevice >> m_graphics_devices;
57
57
LockRefPtr<Graphics::Console> m_console;
58
58
59
59
// Note: This is only used when booting with kernel commandline that includes "graphics_subsystem_mode=limited"
You can’t perform that action at this time.
0 commit comments