cvs commit: src/sys/net bpf.c bpfdesc.h

Christian S.J. Peron csjp at
Mon Sep 5 16:08:05 PDT 2005

csjp        2005-09-05 23:08:04 UTC

  FreeBSD src repository

  Modified files:
    sys/net              bpf.c bpfdesc.h 
  Instead of caching the PID which opened the bpf descriptor, continuously
  refresh the PID which has the descriptor open. The PID is refreshed in various
  operations like ioctl(2), kevent(2) or poll(2). This produces more accurate
  information about current bpf consumers. While we are here remove the bd_pcomm
  member of the bpf stats structure because now that we have an accurate PID we
  can lookup the via the sysctl variable. This is the trick that
  NetBSD decided to use to deal with this issue.
  Special care needs to be taken when MFC'ing this change, as we have made a
  change to the bpf stats structure. What will end up happening is we will leave
  the pcomm structure but just mark it as being un-used. This way we keep the ABI
  in tact.
  MFC after:      1 month
  Discussed with: Rui Paulo < rpaulo at NetBSD dot org >
  Revision  Changes    Path
  1.159     +12 -2     src/sys/net/bpf.c
  1.32      +0 -2      src/sys/net/bpfdesc.h

More information about the cvs-src mailing list