2009-12-21 3 views

답변

6

이 대답은 분명한 답변이지만 NAPI API가 사용 중인지 확인하려면 소스를 확인하십시오. 예를를 들어
:

  • 드라이버의 인터럽트 핸들러에서, 그것은 아래 전화 중 하나를 사용합니까?
  • 드라이버가 NAPI의 poll() 메소드를 구현합니까? 그렇다면 netif_rx() 대신 netif_receive_skb()을 사용하는지 확인하십시오.

두 질문 모두 '예'일 경우 드라이버가 NAPI를 사용하고 있습니다.

참고 : 다음은 here

NAPI API 

netif_rx_schedule(dev) 
    Called by an IRQ handler to schedule a poll for device 
netif_rx_schedule_prep(dev) 
    puts the device in a state ready to be added to the CPU polling list if it is up and running. You can look at this as the first half of netif_rx_schedule(dev). 
__netif_rx_schedule(dev) 
    Add device to the poll list for this CPU; assuming that netif_schedule_prep(dev) has already been called and returned 1 
__netif_rx_schedule_prep(dev) 
    similar to netif_rx_schedule_prep(dev) but no check if device is up, usually not used 
netif_rx_reschedule(dev, undo) 
    Called to reschedule polling for device specifically for some deficient hardware. 
netif_rx_complete(dev) 
    Remove interface from the CPU poll list: it must be in the poll list on current cpu. This primitive is called by dev->poll(), when it completes its work. The device cannot be out of poll list at this call, if it is then clearly it is a BUG(). 
__netif_rx_complete(dev) 
    same as netif_rx_complete but called when local interrupts are already disabled. 

체크 아웃이 wikipedia article 더 자세한 내용은 그것의 외부 링크에서 복사되었습니다.

도움이 되었기를 바랍니다.

관련 문제