mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-10-02 06:09:51 +00:00
Kernel: Use IOAddress instead of direct IO calls in SerialDevice
This commit is contained in:
parent
a5699a141d
commit
62f69cc50f
Notes:
sideshowbarker
2024-07-18 17:57:05 +09:00
Author: https://github.com/IdanHo
Commit: 62f69cc50f
Pull-request: https://github.com/SerenityOS/serenity/pull/7116
Reviewed-by: https://github.com/awesomekling
Reviewed-by: https://github.com/supercomputer7
3 changed files with 21 additions and 20 deletions
|
@ -7,6 +7,7 @@
|
|||
#pragma once
|
||||
|
||||
#include <Kernel/Devices/CharacterDevice.h>
|
||||
#include <Kernel/IO.h>
|
||||
|
||||
namespace Kernel {
|
||||
|
||||
|
@ -18,7 +19,7 @@ namespace Kernel {
|
|||
class SerialDevice final : public CharacterDevice {
|
||||
AK_MAKE_ETERNAL
|
||||
public:
|
||||
SerialDevice(u32 base_addr, unsigned minor);
|
||||
SerialDevice(IOAddress base_addr, unsigned minor);
|
||||
virtual ~SerialDevice() override;
|
||||
|
||||
// ^CharacterDevice
|
||||
|
@ -122,7 +123,7 @@ private:
|
|||
void set_modem_control(u8 modem_control);
|
||||
u8 get_line_status() const;
|
||||
|
||||
u32 m_base_addr { 0 };
|
||||
IOAddress m_base_addr;
|
||||
bool m_interrupt_enable { false };
|
||||
u8 m_fifo_control { 0 };
|
||||
Baud m_baud { Baud38400 };
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue