]> CyberLeo.Net >> Repos - FreeBSD/stable/8.git/commit
Merge r196482 from head to stable/8:
authorrwatson <rwatson@ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f>
Fri, 28 Aug 2009 20:07:38 +0000 (20:07 +0000)
committerrwatson <rwatson@ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f>
Fri, 28 Aug 2009 20:07:38 +0000 (20:07 +0000)
commit4e3e0c4ca98ed72ff98b51d1958c7c1c626e2dc1
tree1e9947831b9de8f64be24a394ed8cb06445c8414
parentebbc685478c15856c2bf03bb99becaba6c8053cb
Merge r196482 from head to stable/8:

  Rather than using IFNET_RLOCK() when iterating over (and modifying) the
  ifnet list during if_ef load, directly acquire the ifnet_sxlock
  exclusively.  That way when if_alloc() recurses the lock, it's a write
  recursion rather than a read->write recursion.

  This code structure is arguably a bug, so add a comment indicating that
  this is the case.  Post-8.0, we should fix this, but this commit
  resolves panic-on-load for if_ef.

  Discussed with:       bz, julian
  Reported by:  phk

Approved by: re (kib)

git-svn-id: svn://svn.freebsd.org/base/stable/8@196627 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f
sys/net/if_ef.c