Changeset ca652eb in mainline
- Timestamp:
- 2014-07-05T19:27:22Z (10 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- b8e75319
- Parents:
- 727e639
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/drv/nic/rtl8169/driver.c
r727e639 rca652eb 247 247 return rc; 248 248 249 ddf_msg(LVL_DEBUG, "TX ring address: phys=0x% 08lx, virt=%p",249 ddf_msg(LVL_DEBUG, "TX ring address: phys=0x%#" PRIxn ", virt=%p", 250 250 rtl8169->tx_ring_phys, rtl8169->tx_ring); 251 251 … … 261 261 return rc; 262 262 263 ddf_msg(LVL_DEBUG, "RX ring address: phys=0x% 08lx, virt=%p",263 ddf_msg(LVL_DEBUG, "RX ring address: phys=0x%#" PRIxn ", virt=%p", 264 264 rtl8169->rx_ring_phys, rtl8169->rx_ring); 265 265 … … 275 275 return rc; 276 276 277 ddf_msg(LVL_DEBUG, "TX buffers base address: phys=0x% 08lx,virt=%p",277 ddf_msg(LVL_DEBUG, "TX buffers base address: phys=0x%#" PRIxn " virt=%p", 278 278 rtl8169->tx_buff_phys, rtl8169->tx_buff); 279 279 … … 287 287 return rc; 288 288 289 ddf_msg(LVL_DEBUG, "RX buffers base address: phys=0x% 08lx, virt=%p",289 ddf_msg(LVL_DEBUG, "RX buffers base address: phys=0x%#" PRIxn ", virt=%p", 290 290 rtl8169->rx_buff_phys, rtl8169->rx_buff); 291 291 … … 615 615 { 616 616 rtl8169_descr_t *descr; 617 uint ptr_t buff_phys;617 uint64_t buff_phys; 618 618 unsigned int i = first; 619 619 … … 638 638 { 639 639 int rc; 640 uint64_t tmp; 640 641 641 642 ddf_msg(LVL_NOTE, "Activating device"); … … 658 659 659 660 /* Write address of descriptor as start of TX ring */ 660 pio_write_32(rtl8169->regs + TNPDS, rtl8169->tx_ring_phys & 0xffffffff); 661 pio_write_32(rtl8169->regs + TNPDS + 4, (rtl8169->tx_ring_phys >> 32) & 0xffffffff); 661 tmp = rtl8169->tx_ring_phys; 662 pio_write_32(rtl8169->regs + TNPDS, tmp & 0xffffffff); 663 pio_write_32(rtl8169->regs + TNPDS + 4, (tmp >> 32) & 0xffffffff); 662 664 rtl8169->tx_head = 0; 663 665 rtl8169->tx_tail = 0; … … 665 667 666 668 /* Write RX ring address */ 667 pio_write_32(rtl8169->regs + RDSAR, rtl8169->rx_ring_phys & 0xffffffff); 668 pio_write_32(rtl8169->regs + RDSAR + 4, (rtl8169->rx_ring_phys >> 32) & 0xffffffff); 669 tmp = rtl8169->rx_ring_phys; 670 pio_write_32(rtl8169->regs + RDSAR, tmp & 0xffffffff); 671 pio_write_32(rtl8169->regs + RDSAR + 4, (tmp >> 32) & 0xffffffff); 669 672 rtl8169->rx_head = 0; 670 673 rtl8169->rx_tail = 0; … … 895 898 unsigned int head, tail; 896 899 void *buff; 897 uint ptr_t buff_phys;900 uint64_t buff_phys; 898 901 rtl8169_t *rtl8169 = nic_get_specific(nic_data); 899 902 … … 906 909 fibril_mutex_lock(&rtl8169->tx_lock); 907 910 908 ddf_msg(LVL_NOTE, "send_frame: size: % ld, tx_head=%d tx_tail=%d",911 ddf_msg(LVL_NOTE, "send_frame: size: %zu, tx_head=%d tx_tail=%d", 909 912 size, rtl8169->tx_head, rtl8169->tx_tail); 910 913
Note:
See TracChangeset
for help on using the changeset viewer.