mirror of
https://github.com/RGBCube/serenity
synced 2025-07-27 20:47:45 +00:00
Kernel/VirtIO: Ensure proper error propagation in core methods
Simplify core methods in the VirtIO bus handling code by ensuring proper error propagation. This makes initialization of queues, handling changes in device configuration, and other core patterns more readable as well. It also allows us to remove the obnoxious pattern of checking for boolean "success" and if we get false answer then returning an actual errno code.
This commit is contained in:
parent
6ee6a2534d
commit
7718842829
12 changed files with 56 additions and 81 deletions
|
@ -27,7 +27,7 @@ public:
|
|||
private:
|
||||
virtual StringView class_name() const override { return "VirtIORNG"sv; }
|
||||
explicit RNG(NonnullOwnPtr<TransportEntity>);
|
||||
virtual bool handle_device_config_change() override;
|
||||
virtual ErrorOr<void> handle_device_config_change() override;
|
||||
virtual void handle_queue_update(u16 queue_index) override;
|
||||
void request_entropy_from_host();
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue