mirror of
https://github.com/RGBCube/serenity
synced 2025-05-14 08:54:58 +00:00

This class had slightly confusing semantics and the added weirdness doesn't seem worth it just so we can say "." instead of "->" when iterating over a vector of NNRPs. This patch replaces NonnullRefPtrVector<T> with Vector<NNRP<T>>.
24 lines
885 B
C++
24 lines
885 B
C++
/*
|
|
* Copyright (c) 2022, Pankaj R <pankydev8@gmail.com>
|
|
*
|
|
* SPDX-License-Identifier: BSD-2-Clause
|
|
*/
|
|
|
|
#pragma once
|
|
|
|
#include <Kernel/Storage/NVMe/NVMeQueue.h>
|
|
|
|
namespace Kernel {
|
|
|
|
class NVMeInterruptQueue : public NVMeQueue
|
|
, public IRQHandler {
|
|
public:
|
|
NVMeInterruptQueue(NonnullOwnPtr<Memory::Region> rw_dma_region, Memory::PhysicalPage const& rw_dma_page, u16 qid, u8 irq, u32 q_depth, OwnPtr<Memory::Region> cq_dma_region, Vector<NonnullRefPtr<Memory::PhysicalPage>> cq_dma_page, OwnPtr<Memory::Region> sq_dma_region, Vector<NonnullRefPtr<Memory::PhysicalPage>> sq_dma_page, Memory::TypedMapping<DoorbellRegister volatile> db_regs);
|
|
void submit_sqe(NVMeSubmission& submission) override;
|
|
virtual ~NVMeInterruptQueue() override {};
|
|
|
|
private:
|
|
virtual void complete_current_request(u16 status) override;
|
|
bool handle_irq(RegisterState const&) override;
|
|
};
|
|
}
|