mirror of
https://github.com/RGBCube/serenity
synced 2025-07-27 02:27:43 +00:00
Kernel: Try to detect Sound Blaster 16 before creating an instance
We shouldn't create a SB16 instance without checking if the Sound Blaster 16 card is actually installed in the system.
This commit is contained in:
parent
5bb35da784
commit
f2faf11d61
3 changed files with 16 additions and 2 deletions
|
@ -42,6 +42,7 @@ public:
|
|||
SB16();
|
||||
virtual ~SB16() override;
|
||||
|
||||
static void detect();
|
||||
static void create();
|
||||
static SB16& the();
|
||||
|
||||
|
@ -69,7 +70,7 @@ private:
|
|||
void dma_start(uint32_t length);
|
||||
void set_sample_rate(uint16_t hz);
|
||||
void dsp_write(u8 value);
|
||||
u8 dsp_read();
|
||||
static u8 dsp_read();
|
||||
u8 get_irq_line();
|
||||
void set_irq_register(u8 irq_number);
|
||||
void set_irq_line(u8 irq_number);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue