summaryrefslogtreecommitdiff
path: root/kernel/drivers/rtl8139.c
diff options
context:
space:
mode:
authorAnton Kling <anton@kling.gg>2024-02-07 11:36:21 +0100
committerAnton Kling <anton@kling.gg>2024-02-07 22:25:47 +0100
commit35958c8c6b600482f68fef08ac26547b5655e987 (patch)
treea3329136adc1b92885c60462e7dd74c98eaa0953 /kernel/drivers/rtl8139.c
parentb7fa1457727338416499d1b0144f1042a6878a97 (diff)
A lot of small changes
Diffstat (limited to 'kernel/drivers/rtl8139.c')
-rw-r--r--kernel/drivers/rtl8139.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/kernel/drivers/rtl8139.c b/kernel/drivers/rtl8139.c
index dd81533..b07ccef 100644
--- a/kernel/drivers/rtl8139.c
+++ b/kernel/drivers/rtl8139.c
@@ -3,6 +3,7 @@
#include <cpu/io.h>
#include <drivers/pci.h>
#include <drivers/rtl8139.h>
+#include <ipc.h>
#include <mmu.h>
#include <network/arp.h>
#include <network/ethernet.h>
@@ -104,6 +105,9 @@ __attribute__((interrupt)) void rtl8139_handler(void *regs) {
}
void rtl8139_send_data(u8 *data, u16 data_size) {
+ kprintf("ipc_write\n");
+ ipc_write(0, data, data_size);
+ /*
const struct PCI_DEVICE *device = &rtl8139;
// FIXME: It should block or fail if there is too little space for the
// buffer
@@ -120,7 +124,7 @@ void rtl8139_send_data(u8 *data, u16 data_size) {
outl(device->gen.base_mem_io + 0x20 + send_buffers_loop * 4,
(u32)virtual_to_physical(send_buffers[send_buffers_loop], NULL));
outl(device->gen.base_mem_io + 0x10 + send_buffers_loop * 4, data_size);
- send_buffers_loop += 1;
+ send_buffers_loop += 1;*/
}
void get_mac_address(u8 mac[6]) {