freebsd-src/sys
Bill Paul 9b307fe2be This commit makes a bunch of changes, some big, some not so big.
- Remove the old task threads from kern_ndis.c and reimplement them in
  subr_ntoskrnl.c, in order to more properly emulate the Windows DPC
  API. Each CPU gets its own DPC queue/thread, and each queue can
  have low, medium and high importance DPCs. New APIs implemented:
  KeSetTargetProcessorDpc(), KeSetImportanceDpc() and KeFlushQueuedDpcs().
  (This is the biggest change.)

- Fix a bug in NdisMInitializeTimer(): the k_dpc pointer in the
  nmt_timer embedded in the ndis_miniport_timer struct must be set
  to point to the DPC, also embedded in the struct. Failing to do
  this breaks dequeueing of DPCs submitted via timers, and in turn
  breaks cancelling timers.

- Fix a bug in KeCancelTimer(): if the timer is interted in the timer
  queue (i.e. the timeout callback is still pending), we have to both
  untimeout() the timer _and_ call KeRemoveQueueDpc() to nuke the DPC
  that might be pending. Failing to do this breaks cancellation of
  periodic timers, which always appear to be inserted in the timer queue.

- Make use of the nmt_nexttimer field in ndis_miniport_timer: keep a
  queue of pending timers and cancel them all in ndis_halt_nic(), prior
  to calling MiniportHalt(). Also call KeFlushQueuedDpcs() to make sure
  any DPCs queued by the timers have expired.

- Modify NdisMAllocateSharedMemory() and NdisMFreeSharedMemory() to keep
  track of both the virtual and physical addresses of the shared memory
  buffers that get handed out. The AirGo MIMO driver appears to have a bug
  in it: for one of the segments is allocates, it returns the wrong
  virtual address. This would confuse NdisMFreeSharedMemory() and cause
  a crash. Why it doesn't crash Windows too I have no idea (from reading
  the documentation for NdisMFreeSharedMemory(), it appears to be a violation
  of the API).

- Implement strstr(), strchr() and MmIsAddressValid().

- Implement IoAllocateWorkItem(), IoFreeWorkItem(), IoQueueWorkItem() and
  ExQueueWorkItem(). (This is the second biggest change.)

- Make NdisScheduleWorkItem() call ExQueueWorkItem(). (Note that the
  ExQueueWorkItem() API is deprecated by Microsoft, but NDIS still uses
  it, since NdisScheduleWorkItem() is incompatible with the IoXXXWorkItem()
  API.)

- Change if_ndis.c to use the NdisScheduleWorkItem() interface for scheduling
  tasks.

With all these changes and fixes, the AirGo MIMO driver for the Belkin
F5D8010 Pre-N card now works. Special thanks to Paul Robinson
(paul dawt robinson at pwermedia dawt net) for the loan of a card
for testing.
2005-05-05 03:56:09 +00:00
..
alpha Change cpu_set_kse_upcall to more generic style, so we can reuse it 2005-04-23 02:32:32 +00:00
amd64 Turn on PCB_FULLCTX in set_regs to fully restore context 2005-05-04 22:26:40 +00:00
arm Allocating the memory for the kernel stack one time is enough. 2005-04-27 13:29:54 +00:00
boot Allow BOOT_BOOT0_COMCONSOLE_SPEED to be derived from BOOT_COMCONSOLE_SPEED 2005-04-25 17:41:35 +00:00
bsm
cam Make sure we look at the correct sub op codes when 2005-04-14 04:51:18 +00:00
coda - Change all filesystems and vfs_cache to relock the dvp once the child is 2005-04-13 10:59:09 +00:00
compat This commit makes a bunch of changes, some big, some not so big. 2005-05-05 03:56:09 +00:00
conf Introduce MAC Framework and MAC Policy entry points to label and control 2005-05-04 10:39:15 +00:00
contrib if_mtu not ifp_mtu. 2005-05-04 19:51:06 +00:00
crypto
ddb Don't enter the debugger if KDB_UNATTENDED is set or if 2005-04-20 20:52:46 +00:00
dev This commit makes a bunch of changes, some big, some not so big. 2005-05-05 03:56:09 +00:00
doc
fs Make smbfs capable to use 16bit char set in filenames. 2005-05-04 15:05:46 +00:00
gdb check return value of gdb_rx_varhex 2005-03-28 18:31:18 +00:00
geom Fix signed vs unsigned warning. 2005-05-01 09:44:50 +00:00
gnu - Change all filesystems and vfs_cache to relock the dvp once the child is 2005-04-13 10:59:09 +00:00
i4b Don't use 'i386/include' directly. 2005-04-08 03:37:20 +00:00
i386 Add convenience APIs pmc_width() and pmc_capabilities() to -lpmc. 2005-05-01 14:11:49 +00:00
ia64 Change cpu_set_kse_upcall to more generic style, so we can reuse it 2005-04-23 02:32:32 +00:00
isa Add ISACFGATTR_HINTS flag to allow detection of a device that was created 2005-04-13 03:26:24 +00:00
isofs/cd9660 - Change all filesystems and vfs_cache to relock the dvp once the child is 2005-04-13 10:59:09 +00:00
kern Change m_uiotombuf so it will accept offset at which data should be copied 2005-05-04 18:55:03 +00:00
libkern Update comment to direct the reader to libkern.h instead of systm.h. 2005-04-28 05:50:18 +00:00
modules Introduce MAC Framework and MAC Policy entry points to label and control 2005-05-04 10:39:15 +00:00
net Change m_uiotombuf so it will accept offset at which data should be copied 2005-05-04 18:55:03 +00:00
net80211 Revise crypto api lightly to improve group key handling: 2005-04-12 17:55:13 +00:00
netatalk
netatm
netgraph Change m_uiotombuf so it will accept offset at which data should be copied 2005-05-04 18:55:03 +00:00
netinet If we don't get a suggested MTU during path MTU discovery 2005-05-04 13:48:44 +00:00
netinet6 Add IPv6 support to IPFW and Dummynet. 2005-04-18 18:35:05 +00:00
netipsec
netipx Update copyright: parts of the netipx implementation are covered by a 2005-04-10 18:05:46 +00:00
netkey
netnatm
netncp
netsmb Explicitly hold a reference to the cdev we have just cloned. This 2005-03-31 12:19:44 +00:00
nfs
nfs4client - We want if (mrep != NULL) not if (m_freem != NULL). m_freem will never 2005-04-25 05:11:19 +00:00
nfsclient Fix a bug in NFS/TCP where retransmissions would not reliably happen 2005-05-04 16:37:31 +00:00
nfsserver NFS write gathering defers execution of NFS server write requests to wait 2005-04-17 16:25:36 +00:00
opencrypto
pc98 MFi386: revision 1.1198 (add KDB_STOP_NMI option). 2005-05-01 04:00:12 +00:00
pccard
pci Deal with failed malloc calls[1]. 2005-04-25 10:18:24 +00:00
posix4 Introduce MAC Framework and MAC Policy entry points to label and control 2005-05-04 10:39:15 +00:00
powerpc - move to SCHED_4BSD per jeffr's comments on SCHED_ULE's state 2005-05-03 11:56:05 +00:00
rpc - Don't call rpcclnt_realign() if we don't have any mbufs to realign. 2005-03-19 01:16:25 +00:00
security Introduce MAC Framework and MAC Policy entry points to label and control 2005-05-04 10:39:15 +00:00
sparc64 Slightly reformat apb_alloc_resource() to create some horizontal space 2005-04-28 03:33:46 +00:00
sys Change m_uiotombuf so it will accept offset at which data should be copied 2005-05-04 18:55:03 +00:00
tools - Add the character "E" to the understood lock types. This means 2005-04-11 15:15:03 +00:00
ufs - Don't restrict the softdep stats to DEBUG kernels, they cost nothing to 2005-05-03 11:03:29 +00:00
vm - We need to inhert the OBJ_NEEDGIANT flag from the original object in 2005-05-04 20:54:16 +00:00
Makefile