Commit Graph

6982 Commits

Author SHA1 Message Date
Warren Block
77b722fce4 Use possessive "its", no apostrophe.
MFC after:	1 day
2012-06-27 01:44:48 +00:00
Kenneth D. Merry
7027b9cda4 Change 'camcontrol defects' to first probe a drive to find out how much
defect information it has before grabbing the full defect list.

This works around a bug with some Hitachi drives that generate data overrun
errors when they are asked for more defect data than they have.

The change is done in a spec-compliant way, so it should have no negative
impact on drives that don't have this issue.

This is based on work originally done at Sandvine.

scsi_da.h:	Add a define for the maximum amount of data that can be
		contained in a defect list.

camcontrol.c:	Update the readdefects() function to issue an initial
		command to determine the length of the defect list, and
		then use that length in the request for the full defect
		list.

camcontrol.8:	Add a note that some drives will report 0 defects available
		if you don't request either the PLIST or GLIST.

Submitted by:	Mark Johnston <markjdb@gmail.com> (original version)
MFC after:	3 days
2012-06-22 18:57:06 +00:00
Scott Long
cfc0a49549 Add progress.c and progress.h, missed in the previous commit to camcontrol.
Submitted by:   Garrett Cooper
Obtained from:  Netflix, Inc.
2012-06-20 04:11:34 +00:00
Scott Long
3ff78f8218 Update the 'fwdownload' command to also flash disks connected over an
ATA/SATA transport.  The detection logic is automatic, so it should Just
Work.  While here, also improve the progress meter that is displayed
during firmware download.

Submitted by:	Alistair Crooks
Obtained from:	Netflix, Inc.
MFC after:	3 days
2012-06-20 00:17:29 +00:00
Navdeep Parhar
09fe63205c - Updated TOE support in the kernel.
- Stateful TCP offload drivers for Terminator 3 and 4 (T3 and T4) ASICs.
  These are available as t3_tom and t4_tom modules that augment cxgb(4)
  and cxgbe(4) respectively.  The cxgb/cxgbe drivers continue to work as
  usual with or without these extra features.

- iWARP driver for Terminator 3 ASIC (kernel verbs).  T4 iWARP in the
  works and will follow soon.

Build-tested with make universe.

30s overview
============
What interfaces support TCP offload?  Look for TOE4 and/or TOE6 in the
capabilities of an interface:
# ifconfig -m | grep TOE

Enable/disable TCP offload on an interface (just like any other ifnet
capability):
# ifconfig cxgbe0 toe
# ifconfig cxgbe0 -toe

Which connections are offloaded?  Look for toe4 and/or toe6 in the
output of netstat and sockstat:
# netstat -np tcp | grep toe
# sockstat -46c | grep toe

Reviewed by:	bz, gnn
Sponsored by:	Chelsio communications.
MFC after:	~3 months (after 9.1, and after ensuring MFC is feasible)
2012-06-19 07:34:13 +00:00
Konstantin Belousov
364e72457f For incompleted block allocations or frees, the inode block count usage
must be recalculated. The blk_check pass of suj checker explicitely marks
inodes which owned such blocks as needing block count adjustment. But
ino_adjblks() is only called by cg_trunc pass, which is performed before
blk_check. As result, the block use count for such inodes is left wrong.
This causes full fsck run after journaled run to still find inconsistencies
like 'INCORRECT BLOCK COUNT I=14557 (328 should be 0)' in phase 1.

Fix this issue by running additional adj_blk pass after blk_check, which
updates the field.

Reviewed by:	jeff, mckusick
MFC after:	1 week
2012-06-12 21:37:27 +00:00
Hans Petter Selasky
4f2380c0cf Revert: r236909
Pointyhat: me
2012-06-11 20:27:52 +00:00
Hans Petter Selasky
9ae652f11f Use the correct clock source when computing timeouts.
MFC after:	1 week
2012-06-11 19:20:59 +00:00
Alexander V. Chernikov
2bd61de08c Update maximum number of tables available in ipfw to reflect
changes done in r233478.

Approved by:      kib(mentor)
MFC after:        3 days
2012-06-09 20:47:58 +00:00
Joel Dahl
9760b0e0c5 mdoc: fix a few badly nested blocks. 2012-06-09 10:43:33 +00:00
Joel Dahl
21c2aa5e52 mdoc: minor improvements to a few lists with tags. 2012-06-09 07:18:53 +00:00
Joel Dahl
a4dec862ed Remove repeated words. 2012-06-05 18:19:52 +00:00
Joel Dahl
19769ec2c7 Minor spelling fixes. 2012-06-05 18:07:20 +00:00
Alexander Motin
fbfb753fad Add -p argument for camcontrol debug to allow enabling CAM_DEBUG_PROBE
added at r208911.
2012-06-04 10:42:09 +00:00
Pawel Jakub Dawidek
4c71d26341 Simplify the code by using snprlcat().
MFC after:	3 days
2012-06-03 10:50:46 +00:00
Joel Dahl
29e758c263 Minor mdoc improvements. 2012-06-03 07:45:42 +00:00
Alexander Motin
b9c473b2ed Rewrite enabling NCQ for SATA devices in a way more alike to SCSI TCQ.
This allows to control it with `camcontrol negotiate adaX -T (en|dis)able`
on the fly, same as for SCSI devices.

Sponsored by:	iXsystems, Inc.
2012-06-02 08:29:07 +00:00
Dimitry Andric
5d586d29dd Make devd build with libc++.
MFC after:	3 days
2012-06-01 06:56:35 +00:00
Eitan Adler
903892c793 Fix a variety of compile errors with gcc48 and clang
PR:		bin/165699
Submitted by:	Arne Meyer <meyer.arne83@gmail.com>
Approved by:	cperciva
MFC after:	1 week
2012-05-31 08:22:02 +00:00
Eitan Adler
5e4cc10b6d Add missing flag enable when certain arguments are parsed
PR:		bin/163053
Submitted by:	Peter <pmc@citylink.dinoex.sub.org>
Approved by:	cperciva
MFC after:	1 week
2012-05-30 03:54:10 +00:00
Kevin Lo
544c5e5b53 Make sure that each va_start has one and only one matching va_end,
especially in error cases.
2012-05-29 01:48:06 +00:00
Eygene Ryabinkin
f74d5a7a20 if_lagg: allow to invoke SIOCSLAGGPORT multiple times in a row
Currently, 'ifconfig laggX down' does not remove members from this
lagg(4) interface.  So, 'service netif stop laggX' followed by
'service netif start laggX' will choke, because "stop" will leave
interfaces attached to the laggX and ifconfig from the "start" will
refuse to add already-existing interfaces.

The real-world case is when I am bundling together my Ethernet and
WiFi interfaces and using multiple profiles for accessing network in
different places: system being booted up with one profile, but later
this profile being exchanged to another one, followed by 'service
netif restart' will not add WiFi interface back to the lagg: the
"stop" action from 'service netif restart' will shut down my main WiFi
interface, so wlan0 that exists in the lagg0 will be destroyed and
purged from lagg0; the "start" action will try to re-add both
interfaces, but since Ethernet one is already in lagg0, ifconfig will
refuse to add the wlan0 from WiFi interface.

Since adding the interface to the lagg(4) when it is already here
should be an idempotent action: we're really not changing anything,
so this fix doesn't change the semantics of interface addition.

Approved by: thompsa
Reviewed by: emaste
MFC after: 1 week
2012-05-28 12:13:04 +00:00
Bjoern A. Zeeb
cf7aca24f7 Removed the IFCAP_ prefix when printing the IPv6 checksum capabilities.
Submitted by:	dim
MFC after:	3 days
2012-05-28 10:45:51 +00:00
Bjoern A. Zeeb
356ab07e2d It turns out that too many drivers are not only parsing the L2/3/4
headers for TSO but also for generic checksum offloading.  Ideally we
would only have one common function shared amongst all drivers, and
perhaps when updating them for IPv6 we should introduce that.
Eventually we should provide the meta information along with mbufs to
avoid (re-)parsing entirely.

To not break IPv6 (checksums and offload) and to be able to MFC the
changes without risking to hurt 3rd party drivers, duplicate the v4
framework, as other OSes have done as well.

Introduce interface capability flags for TX/RX checksum offload with
IPv6, to allow independent toggling (where possible).  Add CSUM_*_IPV6
flags for UDP/TCP over IPv6, and reserve further for SCTP, and IPv6
fragmentation.  Define CSUM_DELAY_DATA_IPV6 as we do for legacy IP and
add an alias for CSUM_DATA_VALID_IPV6.

This pretty much brings IPv6 handling in line with IPv4.
TSO is still handled in a different way and not via if_hwassist.

Update ifconfig to allow (un)setting of the new capability flags.
Update loopback to announce the new capabilities and if_hwassist flags.

Individual driver updates will have to follow, as will SCTP.

Reported by:	gallatin, dim, ..
Reviewed by:	gallatin (glanced at?)
MFC after:	3 days
X-MFC with:	r235961,235959,235958
2012-05-28 09:30:13 +00:00
Jilles Tjoelker
3c52150e70 init: Remove unnecessary 2-second delay before calling reboot(2). 2012-05-25 19:45:01 +00:00
Alexander Motin
3089bb2e84 MFprojects/zfsd:
- Add low-level support for SATA Enclosure Management Bridge (SEMB)
devices -- SATA equivalents of the SCSI SES/SAF-TE devices.
 - Add some utility functions for SCSI SAF-TE devices access.

Sponsored by:	iXsystems, Inc.
2012-05-24 11:07:39 +00:00
Warren Block
344c81a166 Fixes to man8 groff mandoc style, usage mistakes, or typos.
PR:		168016
Submitted by:	Nobuyuki Koganemaru
Approved by:	gjb
MFC after:	3 days
2012-05-24 02:24:03 +00:00
Jilles Tjoelker
23124c879c shutdown: Remove unnecessary 2-second delay. 2012-05-23 19:25:46 +00:00
Joel Dahl
a692c58a90 mdoc: move two sentences from synopsis to description (where they really
belong). With this change, mandoc now formats these manpages properly.
2012-05-23 15:06:13 +00:00
Baptiste Daroussin
5e2a209a27 Fix world after byacc import:
- old yacc(1) use to magicially append stdlib.h, while new one don't
- new yacc(1) do declare yyparse by itself, fix redundant declaration of
  'yyparse'

Approved by:	des (mentor)
2012-05-22 16:33:10 +00:00
Bjoern A. Zeeb
1623284fab MFp4 bz_ipv6_fast:
Allow tso4 and tso6 be set individually given we have the bits.
  This will help with drivers not working as expected during the
  transition time and later.

  Sponsored by:	The FreeBSD Foundation
  Sponsored by:	iXsystems

Reviewed by:	gnn
MFC After:	1 week
2012-05-19 23:25:57 +00:00
Joel Dahl
46f5f178a0 mdoc: remove whitespace. 2012-05-17 11:50:12 +00:00
Joel Dahl
a8a5898dca mdoc: remove superfluous paragraph macro. 2012-05-17 11:29:22 +00:00
Grzegorz Bernacki
7f725bcd5c Import work done under project/nand (@235533) into head.
The NAND Flash environment consists of several distinct components:
  - NAND framework (drivers harness for NAND controllers and NAND chips)
  - NAND simulator (NANDsim)
  - NAND file system (NAND FS)
  - Companion tools and utilities
  - Documentation (manual pages)

This work is still experimental. Please use with caution.

Obtained from: Semihalf
Supported by:  FreeBSD Foundation, Juniper Networks
2012-05-17 10:11:18 +00:00
Joel Dahl
35471bf8ef Minor mdoc nits. 2012-05-13 14:16:04 +00:00
Joel Dahl
4228c8a2b1 Remove end of line whitespace. 2012-05-12 19:59:37 +00:00
Joel Dahl
5da4420931 mdoc: use Po and Pc macros instead of parens. Also avoid starting a line
with Ns.
2012-05-12 17:14:55 +00:00
Glen Barber
7b1d17a1bc General mdoc(7) and typo fixes.
PR:		167804
Submitted by:	Nobuyuki Koganemaru (kogane!jp.freebsd.org)
MFC after:	3 days
2012-05-12 15:08:22 +00:00
Joel Dahl
cd92c96215 mdoc: remove redundant paragraph macro. 2012-05-12 14:46:49 +00:00
Adrian Chadd
270069b756 Add etherswitchcfg.
Submitted by:	Stefan Bethke <stb@lassitu.de>
2012-05-11 20:56:04 +00:00
Hiroki Sato
8a3beec66e Skip nd6 line with no warning message when the system does not support
INET6.

Spotted by:	flo
2012-05-11 20:01:45 +00:00
Glen Barber
2fccbf04cc General mdoc(7) and typo fixes.
PR:		167696
Submitted by:	Nobuyuki Koganemaru (kogane!jp.freebsd.org)
MFC after:	3 days
2012-05-10 02:07:00 +00:00
Eitan Adler
cf0badf098 Document the -c option in --help output
PR:		bin/167463
Submitted by:	"Bryan Drewery" <bryan@shatow.net>
Approved by:	cperciva
MFC after:	3 days
2012-05-09 17:32:10 +00:00
Eitan Adler
af23b88b5c Clarify error that geli generates
when it finds corrupt data.

PR:		kern/165695
Submitted by:	Robert Simmons <rsimmons0@gmail.com>
Reviewed by:	pjd
Approved by:	cperciva
MFC after:	1 week
2012-05-09 17:26:52 +00:00
Edward Tomasz Napierala
deb35287b3 Fix offset calculation to actually rewrite the _last_ block. 2012-05-06 11:48:37 +00:00
Alexander Motin
8f12ca2ee1 Add support for RAID5R. Slightly improve support for RAIDMDF. 2012-05-06 11:32:36 +00:00
Alexander Motin
e231bbbaa3 Add description for GEOM RAID tunables/sysctls.
MFC after:	1 week
2012-05-06 06:25:17 +00:00
Andrey V. Elsukov
ceeac1ac05 Don't ignore start offset value when user specifies it together
with alignment.

PR:		bin/167567
Tested by:	Warren Block
MFC after:	1 week
2012-05-04 19:49:24 +00:00
Alexander Motin
4b97ff6137 Implement read-only support for volumes in optimal state (without using
redundancy) for the following RAID levels: RAID4/5E/5EE/6/MDF.
2012-05-04 07:32:57 +00:00
Alexander Motin
8df8e26adc Add optional -o argument to the graid label to specify some metadata
format options. Use it for specifying byte order for the DDF metadata:
big-endian defined by specification and little-endian used by Adaptec.
2012-05-03 05:32:56 +00:00