Commit Graph

14062 Commits

Author SHA1 Message Date
Alexander Motin
815c973573 Some formatting for r232919.
Submitted by:	pluknet
2012-03-13 10:54:14 +00:00
Alexander Motin
fd053fae73 Add kern.eventtimer.activetick tunable/sysctl, specifying whether each
hardclock() tick should be run on every active CPU, or on only one.

On my tests, avoiding extra interrupts because of this on 8-CPU Core i7
system with HZ=10000 saves about 2% of performance. At this moment option
implemented only for global timers, as reprogramming per-CPU timers is
too expensive now to be compensated by this benefit, especially since we
still have to regularly run hardclock() on at least one active CPU to
update system uptime. For global timer it is quite trivial: timer runs
always, but we just skip IPIs to other CPUs when possible.

Option is enabled by default now, keeping previous behavior, as periodic
hardclock() calls are still used at least to implement setitimer(2) with
ITIMER_VIRTUAL and ITIMER_PROF arguments. But since default schedulers don't
depend on it since r232917, we are much more free to experiment with it.

MFC after:	1 month
2012-03-13 10:21:08 +00:00
Jung-uk Kim
de9dec16dd Make boot2 build with Clang again.
Submitted by:	dim (bsd.sys.mk)
Reviewed by:	dim, jhb
2012-03-09 23:30:30 +00:00
Ed Maste
caeb442fd2 Remove undesired sysctl(3) xref
Submitted by:	bde
2012-03-09 15:25:27 +00:00
Ed Maste
fb175d1c81 Correct markup, use proper reference for sysctl(3)
Submitted by:	brueffer@
2012-03-08 15:27:29 +00:00
Hans Petter Selasky
b733be57cc Add new USB device IDs.
PR:		usb/165815
MFC after:	1 week
2012-03-08 07:22:41 +00:00
Ed Maste
0ff32c4996 Inbound TCP-MD5 digest validation is now supported 2012-03-08 01:37:01 +00:00
Sergey Kandaurov
c46ad71972 Move struct if_data basic description to a more suitable place, and remove
a bit of .Bx 4.4 history.

MFC after:	1 week
2012-03-07 14:53:53 +00:00
Maxim Konovalov
92bf2c1bc3 o Sync LOCK_PROFILING manpage with the current code: remove
unexistent sysctls, add new ones.

Reviewed by:	gjb
Sponsored by:	Nginx, Inc.
2012-03-07 14:50:14 +00:00
Sergey Kandaurov
3f978c3537 Reflect that if_output changed to take a struct route as its fourth
argument (r191148).

MFC after:	1 week
2012-03-07 11:29:43 +00:00
Sergey Kandaurov
c469a8f18f Update ifa_rtrequest() description after post-4.4BSD change made in r85074.
3rd argument of ifa->ifa_rtrequest is now ``rt_addrinfo *'' instead of
``sockaddr *''. While here, un-document RTM_RESOLVE cmd argument for
ifa_rtrequest() that became a stub after separating L2 tables in r186119.

MFC after:	1 week
2012-03-07 09:42:19 +00:00
Bjoern A. Zeeb
0566170f70 Provide wbwd(4), a driver for the watchdog timer found on various
Winbond Super I/O chips.

With minor efforts it should be possible the extend the driver to support
further chips/revisions available from Winbond.  In the simplest case
only new IDs need to be added, while different chipsets might require
their own function to enter extended function mode, etc.

Sponsored by:	Sandvine Incorporated ULC (in 2011)
Reviewed by:	emaste, brueffer
MFC after:	2 weeks
2012-03-06 18:44:52 +00:00
Sergey Kandaurov
5aa77f88ec Remove if_watchdog remnants after if_timer/if_watchdog removal in r199975.
This part was missed in r199992.

MFC after:	1 week
2012-03-06 12:20:37 +00:00
Sergey Kandaurov
8b7b8e14a8 Fix a typo: use lower case in "A Shorthand".
Noted by:	maxim
2012-03-06 09:57:50 +00:00
Sergey Kandaurov
4f0ab9dc95 Kill EoL whitespaces. 2012-03-06 09:40:34 +00:00
Sergey Kandaurov
40b39918be The missing part of r232588 that documents ifaddr_byindex() itself.
MFC after:	1 week
2012-03-06 09:04:53 +00:00
Sergey Kandaurov
2abee21cd7 - ifnet_addrs has gone and replaced by ifaddr_byindex(), as per r83130
- access to the AF_LINK address through if_addrhead is deprecated (r128315)

MFC after:	1 week
2012-03-06 08:59:42 +00:00
Sergey Kandaurov
dfef665819 Actually bump date, sigh. 2012-03-05 20:04:28 +00:00
John Baldwin
281a359e83 Fix three instances of a missing word.
Submitted by:	bjk
2012-03-05 19:38:59 +00:00
Sergey Kandaurov
642c499386 Fix typo. Bump .Dd for the previous change. 2012-03-05 17:38:44 +00:00
Gleb Smirnoff
2875b4b999 Fix ng_ipfw(4) cookie number in example.
Pointed out by:		"Jacco van Buuren" <jaccovanbuuren gmail.com>
2012-03-05 06:12:15 +00:00
John Baldwin
68bf97175d Document pci_find_extcap() and pci_find_htcap(). 2012-03-04 18:55:33 +00:00
Eitan Adler
4a63252f49 Bump date as modified the man page
Submitted by:	gjb
2012-03-04 16:59:45 +00:00
Eitan Adler
4e8eb2e06c ehci tunables are only available when kernel is compiled with USB_DEBUG
PR:		docs/163646
Reported by:	Momchil Ivanov <momchil@xaxo.eu>
Submitted by:	Benjamin Kaduk <kaduk@mit.edu>
Approved by:	cperciva
MFC after:	1 week
2012-03-04 16:26:49 +00:00
Eitan Adler
b269e8dccb PR: docs/158813
Submitted by:	Ben Kaduk <kaduk@mit.edu>
Approved by:	bcr
MFC after:	1 week
2012-03-04 15:22:03 +00:00
Dimitry Andric
2651e350d3 Revert r232473. I have been convinced by Doug Barton and Bjoern Zeeb
that it is better to error out when people attempt to build using the
wrong bsd.*.mk files, than to silently ignore the problem.

This means, that after this commit, if you want to build kernel modules
by hand (or via a port) from a head source tree, you *must* make sure
the files in /usr/share/mk are in sync with that tree.  If that isn't
possible, for example when you are running on an older FreeBSD branch,
you can:

- Run "make buildenv" from your head source tree, to have the correct
  environment setup.  (It's advisable to have run "make buildworld", or
  at a minimum "make toolchain" first.)
- Alternatively, set MAKESYSPATH to the share/mk directory under your
  head source tree.  If your build tools are too old, other problems may
  still occur.
- Alternatively, use "make -m" and specify the share/mk directory under
  your head source tree.  Again, build tools that are too old may still
  result in trouble.

MFC after:	2 weeks
2012-03-03 23:49:53 +00:00
Dimitry Andric
2677e7fea5 After r232322, it turned out many people (and some ports) are building
kernel modules using their old installed /usr/share/mk/bsd.*.mk files,
instead of the updated ones in their source tree.  This leads to errors
like:

  "sys/conf/kmod.mk", line 111: Malformed conditional (${MK_CLANG_IS_CC} == "no" && ${CC:T:Mclang} != "clang")

Obviously, these errors will go away after a "make installworld", or
alternatively, by using "make buildenv" before attempting to manually
build modules.

However, since it is apparently an expected use case to build using old
.mk files, change the way we test for clang, so it also works when the
MK_CLANG_IS_CC macro doesn't exist.

Note the conditional expressions are becoming rather unreadable now, but
I will attempt to fix that on a followup commit.

MFC after:	2 weeks
2012-03-03 18:58:15 +00:00
John Baldwin
855ed4c598 Expand and reorganize the pci(9) manpage a bit:
- Document the following routines: pci_alloc_msi(), pci_alloc_msix(),
  pci_find_cap(), pci_get_max_read_req(), pci_get_vpd_ident(),
  pci_get_vpd_readonly(), pci_msi_count(), pci_msix_count(),
  pci_pending_msix(), pci_release_msi(),  pci_remap_msix(), and
  pci_set_max_read_req().
- Group the functions into five sub-sections: raw configuration access,
  locating devices, device information, device configuration, and
  message signaled interrupts.
- Discourage use of pci_disable_io() and pci_enable_io() in device drivers.
  The PCI bus driver handles this automatically as resources are activated.

MFC after:	2 weeks
2012-03-03 14:23:54 +00:00
Sergey Kandaurov
c136083e86 Reflect the renaming of ifmaof_ifpforaddr() to if_findmulti() in r148652.
MFC after:	1 week
2012-03-02 09:52:42 +00:00
Sergey Kandaurov
1e0f75d313 ifp->if_ioctl() has moved to u_long cmd in r36735.
Somehow that change had not reached here together with ifioctl().

MFC after:	1 week
2012-03-02 09:30:54 +00:00
Alexander Motin
9364490242 Fix names of some Marvell SATA chips. It looks like chips with proprietary
interface supported by mvs(4) are 88SX, while AHCI-like chips are 88SE.

PR:		kern/165271
Submitted by:	Jia-Shiun Li <jiashiun@gmail.com>
MFC after:	1 week
2012-03-02 08:49:07 +00:00
John Baldwin
adb6390718 Update the documentation on pci_get/set_powerstate(). These methods are
not ACPI-specific at all, but deal with PCI power states.  Also,
pci_set_powerstate() fails with EOPNOTSUPP if a request is made that the
underlying device does not support rather than falling back to somehow
setting D0.
2012-03-01 20:36:50 +00:00
John Baldwin
0a9c80e520 Sort function prototypes. 2012-03-01 20:32:02 +00:00
John Baldwin
9415d1e0ac Add pci_save_state() and pci_restore_state() wrappers around
pci_cfg_save() and pci_cfg_restore() for device drivers to use when
saving and restoring state (e.g. to handle device-specific resets).

Reviewed by:	imp
MFC after:	2 weeks
2012-03-01 20:20:55 +00:00
John Baldwin
5c8d3de02b Update for adjusted types for boundary arguments in 232356. 2012-03-01 20:19:21 +00:00
Alex Kozlov
3d876232e5 Add myself
Approved by:	itetcu (mentor)
2012-03-01 20:03:44 +00:00
Jaakko Heinonen
8bffca5eb2 Since r199137 namei() returns EINVAL for DELETE and RENAME operations if
the last component of the pathname is ".".

Reviewed by:	kib
MFC after:	1 week
2012-03-01 18:17:45 +00:00
Alexander Motin
e4afd792df Add driver for the RME HDSPe AIO/RayDAT sound cards -- snd_hdspe(4).
Cards are expensive and so rare, so leave the driver as module.

Submitted by:	Ruslan Bukin <br@bsdpad.com>
MFC after:	2 weeks
2012-03-01 13:10:18 +00:00
Sergey Kandaurov
40d5e8a628 Changes in ifaddr refcounting: ifa_refcnt IFAREF/IFAFREE macros
moved to ifa_ref()/ifa_free() refcounting functions.

MFC after:	1 week
2012-03-01 12:52:14 +00:00
Sergey Kandaurov
8963e1b501 Refine r232333 [1] and put note about ifnet refcount caller responsibility.
Spotted by:	gavin [1]
MFC after:	1 week
2012-03-01 12:30:57 +00:00
Sergey Kandaurov
1c6fed25bb Reflect that ifa_ifwithnet() gained ignore_ptp argument.
MFC after:	1 week
2012-03-01 12:16:00 +00:00
Sergey Kandaurov
86d2665cdb Document ifunit_ref function.
MFC after:	1 week
2012-03-01 12:03:52 +00:00
Sergey Kandaurov
89eb4374e3 Document ifnet refcount.
MFC after:	1 week
2012-03-01 11:03:39 +00:00
Dimitry Andric
4d051adb0f Regenerate src.conf(5) after r232322.
MFC after:	2 weeks
2012-02-29 23:06:48 +00:00
Dimitry Andric
dfbaea8347 Add a WITH_CLANG_IS_CC option for src.conf(5), disabled by default, that
installs clang as /usr/bin/cc, /usr/bin/c++ and /usr/bin/cpp.

Note this does *not* disable building and installing gcc, which will
still be available as /usr/bin/gcc, /usr/bin/g++ and /usr/bin/gcpp.  If
you want to disable gcc completely, you must use WITHOUT_GCC.

MFC after:	2 weeks
2012-02-29 22:58:51 +00:00
Andrew Thompson
6b9597aac4 Correct the description for CTLFLAG_TUN and CTLFLAG_RDTUN, the declaring of a
system tunable has never been implemented. This flag is only used by sysctl(8)
to provide a helpful error message.

Discussed with:	dwhite, kan
2012-02-29 22:41:40 +00:00
Sergey Kandaurov
4278ee3b07 Add myself, and show marck@ as my mentor.
Approved by:	marck (mentor)
2012-02-29 20:13:53 +00:00
Dimitry Andric
a37b5fe456 Regenerate src.conf(5) after r231530 (and to correct a little screwup
with the WITH_CLANG_EXTRAS fragment I added).
2012-02-29 19:18:32 +00:00
Dimitry Andric
07b202a847 Define several extra macros in bsd.sys.mk and sys/conf/kern.pre.mk, to
get rid of testing explicitly for clang (using ${CC:T:Mclang}) in
individual Makefiles.

Instead, use the following extra macros, for use with clang:
- NO_WERROR.clang       (disables -Werror)
- NO_WCAST_ALIGN.clang  (disables -Wcast-align)
- NO_WFORMAT.clang	(disables -Wformat and friends)
- CLANG_NO_IAS		(disables integrated assembler)
- CLANG_OPT_SMALL	(adds flags for extra small size optimizations)

As a side effect, this enables setting CC/CXX/CPP in src.conf instead of
make.conf!  For clang, use the following:

CC=clang
CXX=clang++
CPP=clang-cpp

MFC after:	2 weeks
2012-02-28 18:30:18 +00:00
Kevin Lo
aa58a5719b Mention mos(4) 2012-02-28 15:47:39 +00:00