Changeset f300523 in mainline for uspace/drv/nic/rtl8169/driver.c


Ignore:
Timestamp:
2017-11-29T18:43:10Z (6 years ago)
Author:
Jiri Svoboda <jiri@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
39026d7c
Parents:
48b77ed
Message:

Eliminate uses of thread_usleep() in favor of async_usleep(). Obvious cases are in components that don't explicitly create threads.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/drv/nic/rtl8169/driver.c

    r48b77ed rf300523  
    2828
    2929#include <assert.h>
     30#include <async.h>
    3031#include <errno.h>
    3132#include <align.h>
     
    3435
    3536#include <as.h>
    36 #include <thread.h>
    3737#include <ddf/log.h>
    3838#include <ddf/interrupt.h>
     
    763763        memory_barrier();
    764764        while (pio_read_8(rtl8169->regs + CR) & CR_RST) {
    765                 thread_usleep(1);
     765                async_usleep(1);
    766766                read_barrier();
    767767        }
     
    11761176        do {
    11771177                phyar = pio_read_32(rtl8169->regs + PHYAR);
    1178                 thread_usleep(20);
     1178                async_usleep(20);
    11791179        } while ((phyar & PHYAR_RW_WRITE) == 0);
    11801180
     
    11941194        do {
    11951195                phyar = pio_read_32(rtl8169->regs + PHYAR);
    1196                 thread_usleep(20);
     1196                async_usleep(20);
    11971197        } while ((phyar & PHYAR_RW_WRITE) != 0);
    11981198
    1199         thread_usleep(20);
     1199        async_usleep(20);
    12001200}
    12011201
Note: See TracChangeset for help on using the changeset viewer.