mirror of
https://github.com/SerenityOS/serenity.git
synced 2025-01-24 02:12:09 -05:00
649d2faeab
We had some inconsistencies before: - Sometimes "The", sometimes "the" - Sometimes trailing ".", sometimes no trailing "." I picked the most common one (lowecase "the", trailing ".") and applied it to all copyright headers. By using the exact same string everywhere we can ensure nothing gets missed during a global search (and replace), and that these inconsistencies are not spread any further (as copyright headers are commonly copied to new files).
38 lines
923 B
C++
38 lines
923 B
C++
/*
|
|
* Copyright (c) 2021, the SerenityOS developers.
|
|
*
|
|
* SPDX-License-Identifier: BSD-2-Clause
|
|
*/
|
|
|
|
#pragma once
|
|
|
|
#include <Kernel/Lock.h>
|
|
#include <Kernel/Storage/StorageDevice.h>
|
|
|
|
namespace Kernel {
|
|
|
|
class RamdiskController;
|
|
|
|
class RamdiskDevice final : public StorageDevice {
|
|
friend class RamdiskController;
|
|
AK_MAKE_ETERNAL
|
|
public:
|
|
static NonnullRefPtr<RamdiskDevice> create(const RamdiskController&, NonnullOwnPtr<Region>&& region, int major, int minor);
|
|
RamdiskDevice(const RamdiskController&, NonnullOwnPtr<Region>&&, int major, int minor);
|
|
virtual ~RamdiskDevice() override;
|
|
|
|
// ^BlockDevice
|
|
virtual void start_request(AsyncBlockDeviceRequest&) override;
|
|
|
|
// ^DiskDevice
|
|
virtual const char* class_name() const override;
|
|
virtual String device_name() const override;
|
|
|
|
bool is_slave() const;
|
|
|
|
Lock m_lock { "RamdiskDevice" };
|
|
|
|
NonnullOwnPtr<Region> m_region;
|
|
};
|
|
|
|
}
|