Commit Graph

15 Commits

Author SHA1 Message Date
jmcneill
545ad3210a don't transmit while in a key change is in progress 2013-01-27 12:48:56 +00:00
dyoung
216b022d43 Use NetBSD's own KASSERT() and KASSERTMSG() instead of #undef and re-#defining
KASSERT(), which is awkward at best.
2012-11-08 20:43:55 +00:00
dsl
e21a34c25e Add some pre-processor magic to verify that the type of the data item
passed to sysctl_createv() actually matches the declared type for
  the item itself.
In the places where the caller specifies a function and a structure
  address (typically the 'softc') an explicit (void *) cast is now needed.
Fixes bugs in sys/dev/acpi/asus_acpi.c sys/dev/bluetooth/bcsp.c
  sys/kern/vfs_bio.c sys/miscfs/syncfs/sync_subr.c and setting
  AcpiGbl_EnableAmlDebugObject.
(mostly passing the address of a uint64_t when typed as CTLTYPE_INT).
I've test built quite a few kernels, but there may be some unfixed MD
  fallout. Most likely passing &char[] to char *.
Also add CTLFLAG_UNSIGNED for unsiged decimals - not set yet.
2012-06-02 21:36:41 +00:00
dyoung
9d36091c67 Get rid of the "I don't know what I was thinking / somebody should have
stopped me / does anybody read source-changes?" ATH_LOCK()/ATH_UNLOCK()
and bracket with splnet()/splx() instead.  This is still not *good*,
since ifnet ioctls are not (yet) synchronized, but could be no worse
than what we have, now.  Survives light testing with my (forthcoming)
ifnet ioctl synchronization patch.
2011-10-07 16:58:11 +00:00
dyoung
56f6a5a11c Move device_printf() from ath_netbsd.c to subr_prf.c for reuse in a new
driver.
2011-01-21 17:46:19 +00:00
dyoung
1d4183c115 Don't pick up the <sys/sysctl.h> definitions by chance,
but #include here.
2010-03-19 01:31:11 +00:00
rmind
993cb03302 Drop 3rd and 4th clauses from David Young's license.
Reviewed and approved by dyoung@ (copyright holder).
2009-10-19 23:19:37 +00:00
dyoung
37bdac8857 Eliminate redundant check for read-only mbuf data, since
M_TRAILINGSPACE() does a more complete check on NetBSD.
2007-11-26 23:52:40 +00:00
dyoung
ecfc7c1996 Use device_xname(). Make device_printf() take a device_t argument.
Add __attribute__((__format__(__printf__,2,3))) to device_printf()
so that the compiler will help us detect bad arguments.

Retire unused subroutine m_defrag(), and unused declaration m_getcl().
2007-11-26 23:48:37 +00:00
ad
88ab7da936 Merge some of the less invasive changes from the vmlocking branch:
- kthread, callout, devsw API changes
- select()/poll() improvements
- miscellaneous MT safety improvements
2007-07-09 20:51:58 +00:00
xtraeme
fd8cfc5edb Add missing $NetBSD$ tags and __KERNEL_RCSID(). 2006-02-05 06:03:26 +00:00
dyoung
89c0a98ceb Export ath_sysctl_instance for the SampleRate rate-control module
to use.

Also, add sysctl helper macro SYSCTL_PFX_INT (for SampleRate) that
prepends an arbitrary prefix to the sysctl name, instead of sc->sc_
like SYSCTL_INT.  Factor with SYSCTL_INT.
2005-07-28 02:05:20 +00:00
dyoung
ac7254c1e3 Cosmetic: the '_type' argument to ATH_LOCK_IMPL and family is more
properly called '_obj'.
2005-07-10 19:07:39 +00:00
dyoung
c1446c092d Locking changes.
+ Synchronize ath_calibrate() with ATH_LOCK()/ATH_UNLOCK().  Thanks
  to Steve Woodford for suggesting this fix.  This patch stops
  ath(4) from generating messages "hardware error; resetting" while
  Steve's D-Link DWL-AG650 card is operating (kern/28385).  The
  MiniPCI wireless adapter on one of my Soekris boards also operates
  more reliably following this patch.

+ Use ATH_LOCK_IMPL() and family to synchronize access to the
  transmit queue, also.
2005-07-03 19:58:16 +00:00
dyoung
9063402978 Resolve conflicts in importation of 18-May-2005 ath(4) / net80211(9)
from FreeBSD.  Introduce compatibility shims (sys/dev/ic/ath_netbsd.[ch],
sys/net80211/ieee80211_netbsd.[ch]).  Update drivers (an, atu, atw,
awi, ipw, iwi, rtw, wi) for the new net80211(9) API.
2005-06-22 06:14:51 +00:00