Changes in uspace/drv/nic/rtl8139/driver.c [d87561c:e777847] in mainline
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
TabularUnified uspace/drv/nic/rtl8139/driver.c ¶
rd87561c re777847 27 27 */ 28 28 29 /* XXX Fix this */30 #define _DDF_DATA_IMPLANT31 32 29 #include <assert.h> 33 30 #include <errno.h> 34 31 #include <align.h> 35 32 #include <byteorder.h> 33 #include <libarch/ddi.h> 36 34 #include <libarch/barrier.h> 37 35 … … 41 39 #include <io/log.h> 42 40 #include <nic.h> 41 #include <packet_client.h> 43 42 #include <device/pci.h> 44 43 … … 47 46 #include <ipc/ns.h> 48 47 48 #include <net_checksum.h> 49 49 50 #include <str.h> 50 51 … … 55 56 /** Global mutex for work with shared irq structure */ 56 57 FIBRIL_MUTEX_INITIALIZE(irq_reg_lock); 57 58 58 /** Lock interrupt structure mutex */ 59 #define RTL8139_IRQ_STRUCT_LOCK() \ 60 fibril_mutex_lock(&irq_reg_lock) 61 59 #define RTL8139_IRQ_STRUCT_LOCK() fibril_mutex_lock(&irq_reg_lock) 62 60 /** Unlock interrupt structure mutex */ 63 #define RTL8139_IRQ_STRUCT_UNLOCK() \ 64 fibril_mutex_unlock(&irq_reg_lock) 61 #define RTL8139_IRQ_STRUCT_UNLOCK() fibril_mutex_unlock(&irq_reg_lock) 65 62 66 63 /** PCI clock frequency in kHz */ 67 #define RTL8139_PCI_FREQ_KHZ 68 69 #define RTL8139_AUTONEG_CAPS (ETH_AUTONEG_10BASE_T_HALF |\70 ETH_AUTONEG_10BASE_T_FULL | ETH_AUTONEG_100BASE_TX_HALF |\71 64 #define RTL8139_PCI_FREQ_KHZ 33000 65 66 #define RTL8139_AUTONEG_CAPS (ETH_AUTONEG_10BASE_T_HALF \ 67 | ETH_AUTONEG_10BASE_T_FULL | ETH_AUTONEG_100BASE_TX_HALF \ 68 | ETH_AUTONEG_100BASE_TX_FULL | ETH_AUTONEG_PAUSE_SYMETRIC) 72 69 73 70 /** Lock transmitter and receiver data 74 * 75 * This function shall be called whenever 76 * both transmitter and receiver locking 77 * to force safe lock ordering (deadlock prevention) 78 * 79 * @param rtl8139 RTL8139 private data 80 * 71 * This function shall be called whenever both transmitter and receiver locking 72 * to force safe lock ordering (deadlock prevention) 73 * 74 * @param rtl8139 RTL8139 private data 81 75 */ 82 76 inline static void rtl8139_lock_all(rtl8139_t *rtl8139) … … 89 83 /** Unlock transmitter and receiver data 90 84 * 91 * @param rtl8139 RTL8139 private data 92 * 85 * @param rtl8139 RTL8139 private data 93 86 */ 94 87 inline static void rtl8139_unlock_all(rtl8139_t *rtl8139) … … 159 152 } 160 153 161 /** Update the mask of accepted frames in the RCR register according to154 /** Update the mask of accepted packets in the RCR register according to 162 155 * rcr_accept_mode value in rtl8139_t 163 156 * … … 177 170 } 178 171 179 /** Fill the mask of accepted multicast frames in the card registers172 /** Fill the mask of accepted multicast packets in the card registers 180 173 * 181 174 * @param rtl8139 The rtl8139 private data … … 214 207 rtl8139_regs_lock(rtl8139->io_port); 215 208 216 async_sess_t *pci_sess =217 ddf_dev_parent_sess_get(nic_get_ddf_dev(rtl8139->nic_data));218 219 209 if (bit_val) { 210 async_sess_t *pci_sess = 211 nic_get_ddf_dev(rtl8139->nic_data)->parent_sess; 220 212 uint8_t pmen; 221 213 pci_config_space_read_8(pci_sess, 0x55, &pmen); 222 214 pci_config_space_write_8(pci_sess, 0x55, pmen | 1 | (1 << 7)); 223 215 } else { 216 async_sess_t *pci_sess = 217 nic_get_ddf_dev(rtl8139->nic_data)->parent_sess; 224 218 uint8_t pmen; 225 219 pci_config_space_read_8(pci_sess, 0x55, &pmen); … … 400 394 #define rtl8139_tbuf_busy(tsd) ((pio_read_32(tsd) & TSD_OWN) == 0) 401 395 402 /** Send framewith the hardware396 /** Send packet with the hardware 403 397 * 404 398 * note: the main_lock is locked when framework calls this function … … 418 412 ddf_msg(LVL_DEBUG, "Sending frame"); 419 413 420 if (size > RTL8139_ FRAME_MAX_LENGTH) {414 if (size > RTL8139_PACKET_MAX_LENGTH) { 421 415 ddf_msg(LVL_ERROR, "Send frame: frame too long, %zu bytes", 422 416 size); … … 443 437 fibril_mutex_unlock(&rtl8139->tx_lock); 444 438 445 /* Get address of the buffer descriptor and framedata */439 /* Get address of the buffer descriptor and packet data */ 446 440 void *tsd = rtl8139->io_port + TSD0 + tx_curr * 4; 447 441 void *buf_addr = rtl8139->tx_buff[tx_curr]; … … 464 458 pio_write_32(tsd, tsd_value); 465 459 return; 466 460 467 461 err_busy_no_inc: 468 462 err_size: … … 511 505 } 512 506 513 /** Create framestructure from the buffer data507 /** Create packet structure from the buffer data 514 508 * 515 509 * @param nic_data NIC driver data 516 510 * @param rx_buffer The receiver buffer 517 511 * @param rx_size The buffer size 518 * @param frame_start The offset where packet data start 519 * @param frame_size The size of the frame data 520 * 521 * @return The frame list node (not connected) 522 * 523 */ 524 static nic_frame_t *rtl8139_read_frame(nic_t *nic_data, 525 void *rx_buffer, size_t rx_size, size_t frame_start, size_t frame_size) 526 { 527 nic_frame_t *frame = nic_alloc_frame(nic_data, frame_size); 512 * @param packet_start The offset where packet data start 513 * @param packet_size The size of the packet data 514 * 515 * @return The packet list node (not connected) 516 */ 517 static nic_frame_t *rtl8139_read_packet(nic_t *nic_data, 518 void *rx_buffer, size_t rx_size, size_t packet_start, size_t packet_size) 519 { 520 nic_frame_t *frame = nic_alloc_frame(nic_data, packet_size); 528 521 if (! frame) { 529 ddf_msg(LVL_ERROR, "Can not allocate frame for received frame.");522 ddf_msg(LVL_ERROR, "Can not allocate frame for received packet."); 530 523 return NULL; 531 524 } 532 525 533 void *ret = rtl8139_memcpy_wrapped(frame->data, rx_buffer, frame_start, 534 RxBUF_SIZE, frame_size); 526 void *packet_data = packet_suffix(frame->packet, packet_size); 527 if (!packet_data) { 528 ddf_msg(LVL_ERROR, "Can not get the packet suffix."); 529 nic_release_frame(nic_data, frame); 530 return NULL; 531 } 532 533 void *ret = rtl8139_memcpy_wrapped(packet_data, rx_buffer, packet_start, 534 RxBUF_SIZE, packet_size); 535 535 if (ret == NULL) { 536 536 nic_release_frame(nic_data, frame); … … 568 568 } 569 569 570 /** Receive all frames in queue570 /** Receive all packets in queue 571 571 * 572 572 * @param nic_data The controller data 573 * @return The linked list of nic_frame_list_t nodes, each containing one frame574 */ 575 static nic_frame_list_t *rtl8139_ frame_receive(nic_t *nic_data)573 * @return The linked list of packet_list_t nodes, each containing one packet 574 */ 575 static nic_frame_list_t *rtl8139_packet_receive(nic_t *nic_data) 576 576 { 577 577 rtl8139_t *rtl8139 = nic_get_specific(nic_data); … … 581 581 nic_frame_list_t *frames = nic_alloc_frame_list(); 582 582 if (!frames) 583 ddf_msg(LVL_ERROR, "Can not allocate frame list for received frames.");583 ddf_msg(LVL_ERROR, "Can not allocate frame list for received packets."); 584 584 585 585 void *rx_buffer = rtl8139->rx_buff_virt; … … 605 605 while (!rtl8139_hw_buffer_empty(rtl8139)) { 606 606 void *rx_ptr = rx_buffer + rx_offset % RxBUF_SIZE; 607 uint32_t frame_header = uint32_t_le2host( *((uint32_t*)rx_ptr) );608 uint16_t size = frame_header >> 16;609 uint16_t frame_size = size - RTL8139_CRC_SIZE;610 /* received frame flags in frameheader */611 uint16_t rcs = (uint16_t) frame_header;607 uint32_t packet_header = uint32_t_le2host( *((uint32_t*)rx_ptr) ); 608 uint16_t size = packet_header >> 16; 609 uint16_t packet_size = size - RTL8139_CRC_SIZE; 610 /* received packet flags in packet header */ 611 uint16_t rcs = (uint16_t) packet_header; 612 612 613 613 if (size == RTL8139_EARLY_SIZE) { 614 /* The framecopying is still in progress, break receiving */614 /* The packet copying is still in progress, break receiving */ 615 615 ddf_msg(LVL_DEBUG, "Early threshold reached, not completely coppied"); 616 616 break; … … 618 618 619 619 /* Check if the header is valid, otherwise we are lost in the buffer */ 620 if (size == 0 || size > RTL8139_ FRAME_MAX_LENGTH) {621 ddf_msg(LVL_ERROR, "Receiver error -> receiver reset (size: %4" PRIu16", "622 "header 0x%4" PRIx32 ". Offset: %" PRIu16 ")", size, frame_header,620 if (size == 0 || size > RTL8139_PACKET_MAX_LENGTH) { 621 ddf_msg(LVL_ERROR, "Receiver error -> receiver reset (size: %4"PRIu16", " 622 "header 0x%4"PRIx16". Offset: %zu)", size, packet_header, 623 623 rx_offset); 624 624 goto rx_err; … … 629 629 } 630 630 631 cur_read += size + RTL_ FRAME_HEADER_SIZE;631 cur_read += size + RTL_PACKET_HEADER_SIZE; 632 632 if (cur_read > max_read) 633 633 break; 634 634 635 635 if (frames) { 636 nic_frame_t *frame = rtl8139_read_ frame(nic_data, rx_buffer,637 RxBUF_SIZE, rx_offset + RTL_ FRAME_HEADER_SIZE, frame_size);636 nic_frame_t *frame = rtl8139_read_packet(nic_data, rx_buffer, 637 RxBUF_SIZE, rx_offset + RTL_PACKET_HEADER_SIZE, packet_size); 638 638 639 639 if (frame) … … 642 642 643 643 /* Update offset */ 644 rx_offset = ALIGN_UP(rx_offset + size + RTL_ FRAME_HEADER_SIZE, 4);645 646 /* Write lesser value to prevent overflow into unread frame644 rx_offset = ALIGN_UP(rx_offset + size + RTL_PACKET_HEADER_SIZE, 4); 645 646 /* Write lesser value to prevent overflow into unread packet 647 647 * (the recomendation from the RealTech rtl8139 programming guide) 648 648 */ … … 735 735 tx_used++; 736 736 737 /* If the framewas sent */737 /* If the packet was sent */ 738 738 if (tsd_value & TSD_TOK) { 739 739 size_t size = REG_GET_VAL(tsd_value, TSD_SIZE); … … 765 765 } 766 766 767 /** Receive all frames from the buffer767 /** Receive all packets from the buffer 768 768 * 769 769 * @param rtl8139 driver private data 770 770 */ 771 static void rtl8139_receive_ frames(nic_t *nic_data)771 static void rtl8139_receive_packets(nic_t *nic_data) 772 772 { 773 773 assert(nic_data); … … 777 777 778 778 fibril_mutex_lock(&rtl8139->rx_lock); 779 nic_frame_list_t *frames = rtl8139_ frame_receive(nic_data);779 nic_frame_list_t *frames = rtl8139_packet_receive(nic_data); 780 780 fibril_mutex_unlock(&rtl8139->rx_lock); 781 781 … … 833 833 } 834 834 835 /* Check transmittion interrupts first to allow transmit next frames835 /* Check transmittion interrupts first to allow transmit next packets 836 836 * sooner 837 837 */ … … 840 840 } 841 841 if (isr & INT_ROK) { 842 rtl8139_receive_ frames(nic_data);842 rtl8139_receive_packets(nic_data); 843 843 } 844 844 if (isr & (INT_RER | INT_RXOVW | INT_FIFOOVW)) { … … 942 942 } 943 943 944 /** Activate the device to receive and transmit frames944 /** Activate the device to receive and transmit packets 945 945 * 946 946 * @param nic_data The nic driver data … … 1020 1020 } 1021 1021 1022 memset(rtl8139, 0, sizeof(rtl8139_t));1022 bzero(rtl8139, sizeof(rtl8139_t)); 1023 1023 1024 1024 rtl8139->nic_data = nic_data; … … 1053 1053 assert(dev); 1054 1054 1055 if (d df_dev_data_get(dev))1055 if (dev->driver_data) 1056 1056 nic_unbind_and_destroy(dev); 1057 1058 if (dev->parent_sess != NULL) { 1059 async_hangup(dev->parent_sess); 1060 dev->parent_sess = NULL; 1061 } 1057 1062 } 1058 1063 … … 1076 1081 1077 1082 if (hw_resources->irqs.count != 1) { 1078 ddf_msg(LVL_ERROR, "%s device: unexpected irq count", d df_dev_get_name(dev));1083 ddf_msg(LVL_ERROR, "%s device: unexpected irq count", dev->name); 1079 1084 return EINVAL; 1080 1085 }; 1081 1086 if (hw_resources->io_ranges.count != 1) { 1082 ddf_msg(LVL_ERROR, "%s device: unexpected io ranges count", d df_dev_get_name(dev));1087 ddf_msg(LVL_ERROR, "%s device: unexpected io ranges count", dev->name); 1083 1088 return EINVAL; 1084 1089 } 1085 1090 1086 1091 rtl8139->irq = hw_resources->irqs.irqs[0]; 1087 ddf_msg(LVL_DEBUG, "%s device: irq 0x%x assigned", d df_dev_get_name(dev), rtl8139->irq);1092 ddf_msg(LVL_DEBUG, "%s device: irq 0x%x assigned", dev->name, rtl8139->irq); 1088 1093 1089 1094 rtl8139->io_addr = IOADDR_TO_PTR(hw_resources->io_ranges.ranges[0].address); 1090 1095 if (hw_resources->io_ranges.ranges[0].size < RTL8139_IO_SIZE) { 1091 1096 ddf_msg(LVL_ERROR, "i/o range assigned to the device " 1092 "%s is too small.", d df_dev_get_name(dev));1097 "%s is too small.", dev->name); 1093 1098 return EINVAL; 1094 1099 } 1095 ddf_msg(LVL_DEBUG, "%s device: i/o addr %p assigned.", d df_dev_get_name(dev), rtl8139->io_addr);1100 ddf_msg(LVL_DEBUG, "%s device: i/o addr %p assigned.", dev->name, rtl8139->io_addr); 1096 1101 1097 1102 return EOK; … … 1161 1166 1162 1167 /* Allocate buffer for receiver */ 1163 ddf_msg(LVL_DEBUG, "Allocating receiver buffer of the size % dbytes",1168 ddf_msg(LVL_DEBUG, "Allocating receiver buffer of the size %zu bytes", 1164 1169 RxBUF_TOT_LENGTH); 1165 1170 … … 1188 1193 static int rtl8139_device_initialize(ddf_dev_t *dev) 1189 1194 { 1190 ddf_msg(LVL_DEBUG, "rtl8139_dev_initialize %s", d df_dev_get_name(dev));1195 ddf_msg(LVL_DEBUG, "rtl8139_dev_initialize %s", dev->name); 1191 1196 1192 1197 int ret = EOK; … … 1197 1202 rtl8139_t *rtl8139 = rtl8139_create_dev_data(dev); 1198 1203 if (rtl8139 == NULL) { 1199 ddf_msg(LVL_ERROR, "Not enough memory for initializing %s.", d df_dev_get_name(dev));1204 ddf_msg(LVL_ERROR, "Not enough memory for initializing %s.", dev->name); 1200 1205 return ENOMEM; 1201 1206 } … … 1217 1222 goto failed; 1218 1223 1219 /* Set default frameacceptance */1224 /* Set default packet acceptance */ 1220 1225 rtl8139->rcr_data.ucast_mask = RTL8139_RCR_UCAST_DEFAULT; 1221 1226 rtl8139->rcr_data.mcast_mask = RTL8139_RCR_MCAST_DEFAULT; 1222 1227 rtl8139->rcr_data.bcast_mask = RTL8139_RCR_BCAST_DEFAULT; 1223 1228 rtl8139->rcr_data.defect_mask = RTL8139_RCR_DEFECT_DEFAULT; 1224 /* Set receiver early treshold to 8/16 of framelength */1229 /* Set receiver early treshold to 8/16 of packet length */ 1225 1230 rtl8139->rcr_data.rcr_base = (0x8 << RCR_ERTH_SHIFT); 1226 1231 1227 1232 ddf_msg(LVL_DEBUG, "The device is initialized"); 1228 1233 return ret; 1229 1234 1230 1235 failed: 1231 1236 ddf_msg(LVL_ERROR, "The device initialization failed"); … … 1242 1247 static int rtl8139_pio_enable(ddf_dev_t *dev) 1243 1248 { 1244 ddf_msg(LVL_DEBUG, NAME ": rtl8139_pio_enable %s", d df_dev_get_name(dev));1249 ddf_msg(LVL_DEBUG, NAME ": rtl8139_pio_enable %s", dev->name); 1245 1250 1246 1251 rtl8139_t *rtl8139 = nic_get_specific(nic_get_from_ddf_dev(dev)); … … 1248 1253 /* Gain control over port's registers. */ 1249 1254 if (pio_enable(rtl8139->io_addr, RTL8139_IO_SIZE, &rtl8139->io_port)) { 1250 ddf_msg(LVL_ERROR, "Cannot gain the port % pfor device %s.", rtl8139->io_addr,1251 d df_dev_get_name(dev));1255 ddf_msg(LVL_ERROR, "Cannot gain the port %lx for device %s.", rtl8139->io_addr, 1256 dev->name); 1252 1257 return EADDRNOTAVAIL; 1253 1258 } … … 1292 1297 int rtl8139_dev_add(ddf_dev_t *dev) 1293 1298 { 1294 ddf_fun_t *fun;1295 1296 1299 assert(dev); 1297 ddf_msg(LVL_NOTE, "RTL8139_dev_add %s (handle = %zu)", 1298 ddf_dev_get_name(dev), ddf_dev_get_handle(dev)); 1300 ddf_msg(LVL_NOTE, "RTL8139_dev_add %s (handle = %d)", dev->name, dev->handle); 1299 1301 1300 1302 /* Init device structure for rtl8139 */ … … 1327 1329 rc = nic_connect_to_services(nic_data); 1328 1330 if (rc != EOK) { 1329 ddf_msg(LVL_ERROR, "Failed to connect to services (%d)", rc);1331 ddf_msg(LVL_ERROR, "Failed to connect to services", rc); 1330 1332 goto err_irq; 1331 1333 } 1332 1334 1333 fun = ddf_fun_create(nic_get_ddf_dev(nic_data), fun_exposed, "port0"); 1334 if (fun == NULL) { 1335 ddf_msg(LVL_ERROR, "Failed creating device function"); 1336 goto err_srv; 1337 } 1338 nic_set_ddf_fun(nic_data, fun); 1339 ddf_fun_set_ops(fun, &rtl8139_dev_ops); 1340 ddf_fun_data_implant(fun, nic_data); 1341 1342 rc = ddf_fun_bind(fun); 1335 rc = nic_register_as_ddf_fun(nic_data, &rtl8139_dev_ops); 1343 1336 if (rc != EOK) { 1344 ddf_msg(LVL_ERROR, "Failed binding device function"); 1345 goto err_fun_create; 1346 } 1347 rc = ddf_fun_add_to_category(fun, DEVICE_CATEGORY_NIC); 1348 if (rc != EOK) { 1349 ddf_msg(LVL_ERROR, "Failed adding function to category"); 1350 goto err_fun_bind; 1337 ddf_msg(LVL_ERROR, "Failed to register as DDF function - error %d", rc); 1338 goto err_irq; 1351 1339 } 1352 1340 1353 1341 ddf_msg(LVL_NOTE, "The %s device has been successfully initialized.", 1354 ddf_dev_get_name(dev)); 1355 1356 return EOK; 1357 1358 err_fun_bind: 1359 ddf_fun_unbind(fun); 1360 err_fun_create: 1361 ddf_fun_destroy(fun); 1362 err_srv: 1363 /* XXX Disconnect from services */ 1342 dev->name); 1343 1344 return EOK; 1345 1364 1346 err_irq: 1365 1347 unregister_interrupt_handler(dev, rtl8139->irq); … … 1504 1486 }; 1505 1487 1506 /** Check if pause frameoperations are valid in current situation1488 /** Check if pause packet operations are valid in current situation 1507 1489 * 1508 1490 * @param rtl8139 RTL8139 private structure … … 1529 1511 } 1530 1512 1531 /** Get current pause frameconfiguration1513 /** Get current pause packet configuration 1532 1514 * 1533 1515 * Values are filled with NIC_RESULT_NOT_AVAILABLE if the value has no sense in … … 1535 1517 * 1536 1518 * @param[in] fun The DDF structure of the RTL8139 1537 * @param[out] we_send Sign if local constroller sends pause frame1538 * @param[out] we_receive Sign if local constroller receives pause frame1539 * @param[out] time Time filled in pause frames. 0xFFFF in rtl81391519 * @param[out] we_send Sign if local constroller sends pause packets 1520 * @param[out] we_receive Sign if local constroller receives pause packets 1521 * @param[out] time Time filled in pause packets. 0xFFFF in rtl8139 1540 1522 * 1541 1523 * @return EOK if succeed … … 1567 1549 }; 1568 1550 1569 /** Set current pause frameconfiguration1551 /** Set current pause packet configuration 1570 1552 * 1571 1553 * @param fun The DDF structure of the RTL8139 1572 * @param allow_send Sign if local constroller sends pause frame1573 * @param allow_receive Sign if local constroller receives pause frames1554 * @param allow_send Sign if local constroller sends pause packets 1555 * @param allow_receive Sign if local constroller receives pause packets 1574 1556 * @param time Time to use, ignored (not supported by device) 1575 1557 * 1576 * @return EOK if succeed, INVAL if the pause framehas no sence1558 * @return EOK if succeed, INVAL if the pause packet has no sence 1577 1559 */ 1578 1560 static int rtl8139_pause_set(ddf_fun_t *fun, int allow_send, int allow_receive, … … 1823 1805 } 1824 1806 1825 /** Set unicast frames acceptance mode1807 /** Set unicast packets acceptance mode 1826 1808 * 1827 1809 * @param nic_data The nic device to update … … 1881 1863 } 1882 1864 1883 /** Set multicast frames acceptance mode1865 /** Set multicast packets acceptance mode 1884 1866 * 1885 1867 * @param nic_data The nic device to update … … 1926 1908 } 1927 1909 1928 /** Set broadcast frames acceptance mode1910 /** Set broadcast packets acceptance mode 1929 1911 * 1930 1912 * @param nic_data The nic device to update … … 1956 1938 } 1957 1939 1958 /** Get state of acceptance of weird frames1940 /** Get state of acceptance of weird packets 1959 1941 * 1960 1942 * @param[in] device The device to check … … 1978 1960 }; 1979 1961 1980 /** Set acceptance of weird frames1962 /** Set acceptance of weird packets 1981 1963 * 1982 1964 * @param device The device to update … … 2138 2120 pio_write_32(rtl8139->io_port + TCTR, 0); 2139 2121 2140 ddf_msg(LVL_DEBUG, "Periodic mode. Interrupt mask %" PRIx16 ", " 2141 "poll.full_skips %zu, last timer %" PRIu32, 2142 rtl8139->int_mask, rtl8139->poll_timer.full_skips, 2143 rtl8139->poll_timer.last_val); 2122 ddf_msg(LVL_DEBUG, "Periodic mode. Interrupt mask %"PRIx16", poll.full_skips %" 2123 PRIu32", last timer %"PRIu32".", rtl8139->int_mask, 2124 rtl8139->poll_timer.full_skips, rtl8139->poll_timer.last_val); 2144 2125 break; 2145 2126 default: … … 2155 2136 } 2156 2137 2157 /** Force receiving all frames in the receive buffer2138 /** Force receiving all packets in the receive buffer 2158 2139 * 2159 2140 * @param device The device to receive … … 2186 2167 &rtl8139_driver_ops, &rtl8139_dev_ops, &rtl8139_nic_iface); 2187 2168 2188 ddf_log_init(NAME );2169 ddf_log_init(NAME, LVL_ERROR); 2189 2170 ddf_msg(LVL_NOTE, "HelenOS RTL8139 driver started"); 2190 2171 return ddf_driver_main(&rtl8139_driver);
Note:
See TracChangeset
for help on using the changeset viewer.