MFC: r233273

Exclude devices which are mutually exclusive with ATA_CAM. For better
or worse, the former are still built as modules as part of the LINT
builds.

Reviewed by:	mav


git-svn-id: svn://svn.freebsd.org/base/stable/9@233712 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f
MFC: r233274

Remove remnants of ATA_LOCKING uses in the ATA_CAM case and wrap it
along with functions, SYSCTLs and tunables that are not used with
ATA_CAM in #ifndef ATA_CAM, similar to the existing #ifdef'ed ATA_CAM
code for the other way around. This makes it easier to understand
which parts of ata(4) actually are used in the new world order and
to later on remove the !ATA_CAM bits. It also makes it obvious that
there is something fishy with the C-bus front-end as well as in the
ATP850 support, as these used ATA_LOCKING which is defunct in the
ATA_CAM case. When fixing the former, ATA_LOCKING probably needs to
be brought back in some form or other.

Reviewed by:	mav


git-svn-id: svn://svn.freebsd.org/base/stable/9@233715 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f
MFC: r233282

- First pass at const'ifying ata(4) as appropriate.
- Use DEVMETHOD_END.
- Use NULL instead of 0 for pointers.


git-svn-id: svn://svn.freebsd.org/base/stable/9@233717 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f
MFC: r233287

Use the common/shared CRC-32 implementation instead of duplicating it.


git-svn-id: svn://svn.freebsd.org/base/stable/9@233719 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f
MFC: r233403, r233404

- Use the PCI ID macros from mpi_cnfg.h rather than duplicating them here.
  Note that this driver additionally probes some device IDs for the most
  part not know to other MPT drivers, if at all. So rename the macros not
  present in mpi_cnfg.h to match the naming scheme in the latter and but
  suffix them with a _FB in order to not cause conflicts.
- Like mpt_set_config_regs(), comment out mpt_read_config_regs() as the
  content of the registers read isn't actually used and both functions
  aren't exactly up to date regarding the possible layouts of the BARs
  (these function might be helpful for debugging though, so don't remove
  them completely).
- Use DEVMETHOD_END.
- Use NULL rather than 0 for pointers.
- Remove an unusual check for the softc being NULL.
- Remove redundant zeroing of the softc.
- Remove an overly banal and actually partly incorrect as well as partly
  outdated comment regarding the allocation of the memory resource.


git-svn-id: svn://svn.freebsd.org/base/stable/9@233721 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f
MFC: r233421

Given that this is a host-PCI-Express bridge driver, create the parent
DMA tag with a 4 GB boundary as required by PCI-Express. With r232403
(MFC'ed to stable/9 in r233393) in place this actually is redundant.
However, the host-PCI-Express bridge driver is the more appropriate
place for implementing this restriction.


git-svn-id: svn://svn.freebsd.org/base/stable/9@233723 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f
MFC: r233423

Initialize the mutexes used for the NVM and the swflag as MTX_DUPOK in
order to avoid otherwise harmless witness warnings when these are acquired
at the same time and due to both using MTX_NETWORK_LOCK as their type.
The right fix actually would be to use different, descriptive types for
these. However, the latter would require undesirable changes to the shared
code base. Another approach would be to just supply NULL as the type, which
was deemed as less desirable though as it would cause the unique but cryptic
name also to be used for the type and to diverge from the type used by other
network device drivers.


git-svn-id: svn://svn.freebsd.org/base/stable/9@233725 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f
MFC r233100:
In vm_object_page_clean(), do not clean OBJ_MIGHTBEDIRTY object flag
if the filesystem performed short write and we are skipping the page
due to this.

Propogate write error from the pager back to the callers of
vm_pageout_flush().  Report the failure to write a page from the
requested range as the FALSE return value from vm_object_page_clean(),
and propagate it back to msync(2) to return EIO to usermode.

While there, convert the clearobjflags variable in the
vm_object_page_clean() and arguments of the helper functions to
boolean.

PR:	kern/165927


git-svn-id: svn://svn.freebsd.org/base/stable/9@233728 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f
MFC r233101:
Add sysctl vfs.nfs.nfs_keep_dirty_on_error to switch the nfs client
behaviour on error from write RPC back to behaviour of old nfs client.
When set to not zero, the pages for which write failed are kept dirty.

PR:	kern/165927


git-svn-id: svn://svn.freebsd.org/base/stable/9@233730 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f
MFC r233102:
Do not claim that msync(2) is obsoleted.
Document EIO from msync(2).


git-svn-id: svn://svn.freebsd.org/base/stable/9@233731 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f
MFC r233607:
Update comment.


git-svn-id: svn://svn.freebsd.org/base/stable/9@233732 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f
Merge remote-tracking branch 'upstream/svn_stable_9' into svn_stable_9