dsched_fq - Refactor fqp allocation/destruction
authorAlex Hornung <ahornung@gmail.com>
Tue, 13 Apr 2010 07:15:10 +0000 (07:15 +0000)
committerAlex Hornung <ahornung@gmail.com>
Thu, 15 Apr 2010 20:24:51 +0000 (20:24 +0000)
commitedd247d31a4c3de0b873a975b4cb8230f858031f
treeb174da0824d0f15e3533346088d178b36a18226e
parent0746e1609bd535bbea4d3f6037080d32813e0265
dsched_fq - Refactor fqp allocation/destruction

* Accept another argument for fqp allocation which is the corresponding
  fqmp. This is internally stored for proper self-removal out of the
  fqmp list on destruction.

* This parameter is also used to link the fqp into the fqmp list
  automatically on creation, avoiding code duplication and deadlocking.

* Changed the destruction refcount to -0x400 instead of -3 to make
  tracking of these cases simpler and not confuse them with bad
  refcounting.

* NOTE: this also fixes the longstanding issue of an eventual panic
  after a number of policy switches to/from fq.

Reported-by: Antonio Huete (tuxillo@)
sys/dsched/fq/dsched_fq.h
sys/dsched/fq/dsched_fq_core.c
sys/dsched/fq/dsched_fq_diskops.c