Tomohiro Kusumi [Tue, 7 Jun 2016 20:13:32 +0000 (05:13 +0900)]
autofs: Add "Donated to DragonFlyBSD by ..." to manpages
Imre Vadász [Tue, 7 Jun 2016 19:50:29 +0000 (21:50 +0200)]
if_iwm - Avoid bus_dmamap_create()/_destroy() calls in iwm_rx_addbuf().
* Instead of doing bus_dmamap_create() and bus_dmamap_destroy() all the
time, create an extra bus_dmamap_t which we can use to safely
try bus_dmamap_load()-ing the new mbuf. On success we just swap the
spare bus_dmamap_t with the data->map of that ring entry.
Sascha Wildner [Tue, 7 Jun 2016 19:20:23 +0000 (21:20 +0200)]
auto_master.5: Fix .Sx markup.
Sepherosa Ziehau [Tue, 7 Jun 2016 10:11:10 +0000 (18:11 +0800)]
de: Install if_init.
This makes 'ifconfig deX inet x.x.x.x' work.
Sascha Wildner [Tue, 7 Jun 2016 07:04:56 +0000 (09:04 +0200)]
kernel/iwm: Fix building without IWM_DEBUG.
Justin C. Sherrill [Tue, 7 Jun 2016 02:46:32 +0000 (22:46 -0400)]
Merge branch 'master' of ssh://crater.dragonflybsd.org/repository/git/dragonfly
Justin C. Sherrill [Tue, 7 Jun 2016 02:45:25 +0000 (22:45 -0400)]
Remove random download note as it no longer happens that way, and clean up.
Imre Vadász [Mon, 6 Jun 2016 20:22:27 +0000 (22:22 +0200)]
if_iwm - Use vap->iv_myaddr instead of ic->ic_macaddr when vap != NULL.
* ic_macaddr is only used for the initial mac address provided by NVM.
We should rather use vap->iv_myaddr when vap != NULL, to allow the
MAC address to be changed via e.g. ifconfig.
Imre Vadász [Sat, 4 Jun 2016 11:21:06 +0000 (13:21 +0200)]
if_iwm - Add support for Intel AC 8260 chipset.
Taken-From: OpenBSD, Linux (iwlwifi driver)
Imre Vadász [Fri, 3 Jun 2016 21:56:47 +0000 (23:56 +0200)]
iwmfw - Add 8000C firmware for Intel AC 8260 support.
Matthew Dillon [Mon, 6 Jun 2016 17:01:45 +0000 (10:01 -0700)]
nvme - Cleanups, limit nirqs
* Cleanups in the manual page.
* Limit nirqs to ncpus + 1. We don't need more than this number for now.
zrj [Mon, 6 Jun 2016 08:28:15 +0000 (11:28 +0300)]
usr.sbin/autofs: Unbreak make depend.
Add back -I{.CURDIR} path for common.l
zrj [Mon, 6 Jun 2016 07:17:05 +0000 (10:17 +0300)]
sys/cpu: Unbreak world.
For now just hide new functions under _KERNEL.
While there, perform some cleanup.
zrj [Mon, 6 Jun 2016 05:58:23 +0000 (08:58 +0300)]
drm/i915: Remove empty header.
Matthew Dillon [Mon, 6 Jun 2016 06:00:37 +0000 (23:00 -0700)]
nvme - Fix minor cpu mapping issues
* Fix some issues with the cpu mapping. cpu 0 was not getting properly
accounted for due to an array overflow bug. And do a few other things.
* With these changes, extints are nicely distributed across all cpus on
large concurrent workloads, and IPIs are minimal-to-none.
Matthew Dillon [Mon, 6 Jun 2016 03:41:00 +0000 (20:41 -0700)]
nvme - Implement MSIX and reverse comq mapping
* Implement MSIX. Map completion queues to cpus via a rotation.
* Adjust the comq mapping code. For now prioritize assigning a 1:1 cpu
mapping for submission and completion queues over creating separate
queues for reads and writes.
* Tested, systat -pv 1 shows this is capable of pushing 50,000+ interrupts
per second on EACH cpu (all 8 in the xeon box I tested), and run
250,000 IOPS x 2 cards (500,000 IOPS) using interrupt based comq handling.
Matthew Dillon [Sun, 5 Jun 2016 22:35:37 +0000 (15:35 -0700)]
ahci/misc - Add manual links
* Add manual links to nvme.4 to some of the other manual pages.
Matthew Dillon [Sun, 5 Jun 2016 22:33:59 +0000 (15:33 -0700)]
ahci - update manual page
* Fixup the copyright and enhance some of the text. The AHCI driver is
really almost a complete rewrite... even a almost-from-scratch rewrite,
so it is appropriate to add the DragonFly copyright to the comments
section.
Matthew Dillon [Sun, 5 Jun 2016 22:33:24 +0000 (15:33 -0700)]
nvme - Add manual page
* Add the nvme(4) manual page and include some general performance metrics.
Matthew Dillon [Sun, 5 Jun 2016 21:24:02 +0000 (14:24 -0700)]
nvme - Iterate disk units for multiple devices
* Just iterate disk units starting at 0 for now, instead of trying to
use the namespace id, preventing collisions when multiple nvme
controllers are present.
Matthew Dillon [Sun, 5 Jun 2016 18:59:47 +0000 (11:59 -0700)]
nvme - Fix b_resid prior to biodone()
* Oops, forgot to set b_resid to 0 on a successful I/O prior to biodone().
Could cause 'dd' tests to EOF early.
Matthew Dillon [Sun, 5 Jun 2016 18:37:43 +0000 (11:37 -0700)]
debug - fix randread
* Fix randread when used with large > 2GB areas. random() was limiting
the range.
Matthew Dillon [Sun, 5 Jun 2016 18:37:06 +0000 (11:37 -0700)]
kernel - Add nvme driver to the kernel build as a module.
* Add the nvme driver to the kernel build as a module.
Matthew Dillon [Sun, 5 Jun 2016 18:29:22 +0000 (11:29 -0700)]
kernel - Add bus_space_read_8() and bus_space_write_8()
* Add bus_space_read_8() and bus_space_write_8() for memory-mapped
handles only (used by nvme).
Matthew Dillon [Sun, 5 Jun 2016 18:28:41 +0000 (11:28 -0700)]
kernel - Add PCIS_STORAGE_NVM
* Add #defines for PCIS_STORAGE_NVM and friends
Matthew Dillon [Sun, 5 Jun 2016 18:04:48 +0000 (11:04 -0700)]
nvme - Flesh out the driver more
* Handle the case where there are an insufficient number of queue entries
available to handle BIOs (tested by forcing maxqe to 4).
* Issue delete queue commands and issue and wait for controller shutdown
on a normal halt/reboot as per spec.
* Disallow new device open()s during unload.
Sascha Wildner [Sun, 5 Jun 2016 17:47:08 +0000 (19:47 +0200)]
automountd(8) et al.: Clean up the Makefile a little bit.
* The current dir is searched automatically for includes.
* WARNS=6 is not necessary since it is the default for usr.bin.
* Add DPADD for make depend.
Sascha Wildner [Sun, 5 Jun 2016 16:21:55 +0000 (18:21 +0200)]
Adjust share/examples/etc/README.examples for autofs.
Sascha Wildner [Sun, 5 Jun 2016 16:15:37 +0000 (18:15 +0200)]
Add some assignments to etc/defaults/rc.conf for autofs.
Sascha Wildner [Sun, 5 Jun 2016 16:14:56 +0000 (18:14 +0200)]
Add autofs to LINT64.
Tomohiro Kusumi [Sun, 5 Jun 2016 17:18:57 +0000 (02:18 +0900)]
sys/vfs/autofs: Remove .vfs_sync = vfs_stdsync,
This should have been removed by
ef560bee along with other fs.
Imre Vadász [Sun, 5 Jun 2016 14:58:53 +0000 (16:58 +0200)]
if_iwm - Fix m_defrag() usage. Copy-pasto when copying code from OpenBSD.
Imre Vadász [Sun, 5 Jun 2016 12:31:01 +0000 (14:31 +0200)]
if_iwm - Add and use iwm_is_valid_ether_addr() function.
* While there use IEEE80211_ADDR_EQ and IEEE80211_ADDR_COPY macros where
appropriate.
Imre Vadász [Sun, 5 Jun 2016 11:40:31 +0000 (13:40 +0200)]
if_iwm - Avoid leaking memory, and fix error handling in iwm_rx_addbuf().
Imre Vadász [Sat, 4 Jun 2016 12:49:12 +0000 (14:49 +0200)]
if_iwm - When transitioning to INIT, vap->iv_newstate will just ignore arg.
* Just fix the comment to be more helpful here.
Tomohiro Kusumi [Sun, 5 Jun 2016 11:25:02 +0000 (20:25 +0900)]
sbin/hammer: Cleanup on
aac2051d
The if conditional wasn't necessary after
aac2051d.
Sascha Wildner [Sun, 5 Jun 2016 10:35:54 +0000 (12:35 +0200)]
kstrdup.9: Mention kstrndup().
Matthew Dillon [Sun, 5 Jun 2016 06:45:59 +0000 (23:45 -0700)]
kernel - Flesh out nvme interrupts (non-msi for now)
* MSI/MSIX not working currently so just turn it off for the moment.
* Normal interrupt now operational. Implement a real nvme_intr() and
Cleanup some of our polling hacks now that interrupts work.
* Rearrange shutdown so admin polling continues to work while the devfs
disk infrastructure is being torn down.
* Tests with this little samsung mini-pcie nvme card:
120,000 IOPS (concurrent 512 byte dd)
1.5 GBytes/sec (sequential read uncompressable file through filesystem)
1.5 GBytes/sec reading via tar.
test40# ls -la /mnt2/test.dat
-rw-r--r-- 1 root wheel
7516192768 Jun 4 23:50 /mnt2/test.dat
test40# time tar cf /dev/null /mnt2/test.dat
0.062u 3.937s 0:04.84 82.4% 28+69k 28642+0io 0pf+0w (from media)
0.164u 1.367s 0:01.81 83.9% 29+71k 978+0io 0pf+0w (from buffer cache)
Matthew Dillon [Sun, 5 Jun 2016 02:35:29 +0000 (19:35 -0700)]
kernel - Initial native DragonFly NVME driver commit
* Initial from-scratch NVME implementation using the NVM Express 1.2a
chipset specification pdf. Nothing ported from anywhere else.
Basic implementation.
* Not yet connected to the build, interrupts are not yet functional
(it currently just polls at 100hz for testing), some additional error
handling is needed, and we will need ioctl support and a userland utility
to do various administrative tasks like formatting.
* Near full header spec keyed in including the bits we don't use (yet).
* Full SMP BIO interface and four different queue topologies implemented
depending on how many queues the chipset lets us create. The best is
ncpus * 4 queues, i.e. (low, high priority) x (read, write) per cpu.
The second best is just (low, high priority) x (read, write) shared between
all cpus.
Extremely low BIO overhead. Full strategy support and beginnings of
optimizations for low-latency I/Os (currently a hack).
* Initial testing with multiple concurrent sequential dd's on a little
samsung nvme mini-pcie card:
1.2 GBytes/sec 16KB
2.0 GBytes/sec 32KB
2.5 GBytes/sec 64KB
Imre Vadász [Sat, 4 Jun 2016 21:12:11 +0000 (23:12 +0200)]
if_iwm - Fix iwm_mvm_lmac_scan_fill_channels(), only add 11b and 11a chans.
Fixes breakage introduced in
edfc8a0769eef4f5d883c22ee95a6ec79a1d85c6,
after which only channels 36,40,44,48,52,56 from the 5GHz band were
scanned, since all the 11b channels were added twice.
Imre Vadász [Sat, 4 Jun 2016 10:52:08 +0000 (12:52 +0200)]
if_iwm - Make some functions static in if_iwm_led.c, no functional change.
* While there clean up two more cases of
if (ret)
return ret;
return 0;
Tomohiro Kusumi [Sat, 4 Jun 2016 16:23:27 +0000 (01:23 +0900)]
sbin/hammer: Fix used bytes for zone15
zone15 (physically not available zone) is always 100% used,
so bytes_used for zone15 big-block should be 8MB istead of 0.
Has nothing to do with
http://lists.dragonflybsd.org/pipermail/users/2016-June/thread.html#249681
Tomohiro Kusumi [Sat, 4 Jun 2016 15:27:25 +0000 (00:27 +0900)]
sbin/hammer: Make hammer blockmap check offset/space
Based on this report, which may not be a filesystem issue.
http://lists.dragonflybsd.org/pipermail/users/2016-June/thread.html#249681
Tomohiro Kusumi [Sat, 4 Jun 2016 10:36:36 +0000 (19:36 +0900)]
sbin/hammer: Remove debug printfs
These debug printfs are no longer really used for anything and
probably by anyone as /sbin/hammer is stable enough.
These printfs generate tons of output to stderr, so it would be
more convenient to just add some printfs to wherever necessary
or use gdb for whatever issues found, rather than using these.
Tomohiro Kusumi [Fri, 3 Jun 2016 11:15:14 +0000 (20:15 +0900)]
sbin/hammer: Cleanup zone statistics functions
Also remove a debug function hammer_dump_layer1_bits().
Imre Vadász [Fri, 3 Jun 2016 21:08:15 +0000 (23:08 +0200)]
if_run - Add missing RUN_LOCK/RUN_UNLOCK around a run_get_tsf() call.
* The RUN_LOCK_ASSERT in run_do_request() got triggered when running
e.g. "tcpdump -i wlan0 -y IEEE802_11_RADIO" on the interface.
Sascha Wildner [Fri, 3 Jun 2016 17:34:24 +0000 (19:34 +0200)]
Create the /etc/autofs directory via mtree.
Sascha Wildner [Fri, 3 Jun 2016 08:51:29 +0000 (10:51 +0200)]
kernel/autofs: Add some missing files to the Makefile.
Tomohiro Kusumi [Sun, 29 May 2016 04:59:24 +0000 (13:59 +0900)]
usr.sbin/autofs: Workaround namecache bug after unmount
autounmountd gets affected by the namecache bug mentioned in
https://bugs.dragonflybsd.org/issues/2908.
This can be worked around by stat(2) (or any syscall that resolves
the name once again) after unmount failed with EBUSY.
Without this workaround, a process at automounted filesystem will
see ENOTCONN after autounmountd's attempt to unmount. This must
not be removed until the namecache bug is fixed.
Tomohiro Kusumi [Tue, 24 May 2016 15:09:48 +0000 (00:09 +0900)]
sys/kern: Don't implement .vfs_sync unless sync is supported
The only reason filesystems without requirement of syncing
(e.g. no backing storage) need to implement .vfs_sync is because
those fs need a sync with a return value of 0 on unmount.
If unmount allows sync with return value of EOPNOTSUPP for fs
that do not support sync, those fs no longer have to implement
.vfs_sync with vfs_stdsync() only to pass dounmount().
The drawback is when there is a sync (other than vfs_stdnosync)
that returns EOPNOTSUPP for real errors. The existing fs in
DragonFly don't do this (and shouldn't either).
Also see https://bugs.dragonflybsd.org/issues/2912.
# grep "\.vfs_sync" sys/vfs sys/gnu/vfs -rI | grep vfs_stdsync
sys/vfs/udf/udf_vfsops.c: .vfs_sync = vfs_stdsync,
sys/vfs/portal/portal_vfsops.c: .vfs_sync = vfs_stdsync
sys/vfs/devfs/devfs_vfsops.c: .vfs_sync = vfs_stdsync,
sys/vfs/isofs/cd9660/cd9660_vfsops.c: .vfs_sync = vfs_stdsync,
sys/vfs/autofs/autofs_vfsops.c: .vfs_sync = vfs_stdsync, /* for unmount(2) */
sys/vfs/tmpfs/tmpfs_vfsops.c: .vfs_sync = vfs_stdsync,
sys/vfs/dirfs/dirfs_vfsops.c: .vfs_sync = vfs_stdsync,
sys/vfs/ntfs/ntfs_vfsops.c: .vfs_sync = vfs_stdsync,
sys/vfs/procfs/procfs_vfsops.c: .vfs_sync = vfs_stdsync
sys/vfs/hpfs/hpfs_vfsops.c: .vfs_sync = vfs_stdsync,
sys/vfs/nullfs/null_vfsops.c: .vfs_sync = vfs_stdsync,
Tomohiro Kusumi [Wed, 18 May 2016 08:01:32 +0000 (17:01 +0900)]
autofs: Port autofs from FreeBSD
Brought in basically from
FreeBSD@GitHub
cac9beab7d53f0c37ce2a2a1b893be59028928f4
with lots of changes.
Note that this commit isn't necessarily 1:1 with above commit.
Kernel code is basically a rewrite based on the FreeBSD code.
Userspace is basically 1:1 with FreeBSD except that lots of small
changes (including related commits listed below) were necessary.
This is due to autofs being dependent on FreeBSD specific interface,
command options and such.
For userspace, note that non-functional stuff (e.g. whitespace
warnings via git am) are intentionally left to be 1:1 with FreeBSD.
Userspace is basically portable, so don't try to obfuscate the real
changes made for DragonFly by fixing these for now till things are
considered stable unless it's a bug from FreeBSD.
Summary of newly added or modified files.
- sys/vfs/autofs - autofs filesystem
- usr.sbin/autofs - autofs userspace command and daemons
- etc/ - configuration files and manpages
- others - changes in misc subsystems (not independent of autofs)
Related DragonFly commits.
- usr.sbin/autofs: Workaround namecache bug after unmount
- sys/kern: Don't implement .vfs_sync unless sync is supported
- user.sbin/fstyp: Port fstyp from FreeBSD
- sys/kern: Retry nlookup if nresolve returned ESTALE
- sys/sys: Fix IOCPARM_MAX
- sys/sys: Extend IOCPARM_MAX
- usr.bin/showmount: Add -E option
- sbin/mount_nfs: Add -o retrycnt= option
- sys/kern: Add kqueue EVFILT_FS
- sys/kern: Add kstrndup()
Related DragonFly PRs.
- https://bugs.dragonflybsd.org/issues/2900
- https://bugs.dragonflybsd.org/issues/2901
- https://bugs.dragonflybsd.org/issues/2905
- https://bugs.dragonflybsd.org/issues/2907
- https://bugs.dragonflybsd.org/issues/2908
- https://bugs.dragonflybsd.org/issues/2909
- https://bugs.dragonflybsd.org/issues/2912
- https://bugs.dragonflybsd.org/issues/2913
- https://bugs.dragonflybsd.org/issues/2914
Other related resource.
- http://lists.dragonflybsd.org/pipermail/users/2016-May/thread.html#249556
- http://lists.dragonflybsd.org/pipermail/users/2016-June/thread.html#249680
- https://www.dragonflydigest.com/2016/05/06/18066.html
Tomohiro Kusumi [Wed, 18 May 2016 07:58:01 +0000 (16:58 +0900)]
usr.sbin/fstyp: Port fstyp from FreeBSD
Brought in from FreeBSD@GitHub
3e3c248f832f796881ac2ce0d45049552e8d9a9b.
Needed by autofs.
Removed ZFS and GEOM support.
Added HAMMER support.
Note that fstyp has been changed to test a filesystem type vector
fsvtypes[] in addition to the existing fstypes[]. This is a bit
ad-hoc, but was necessary to support partial volume(s) for HAMMER
without a major code rewrite.
Tomohiro Kusumi [Wed, 18 May 2016 18:07:27 +0000 (03:07 +0900)]
sys/kern: Retry nlookup if nresolve returned ESTALE
Make nlookup retry the whole thing if nresolve VOP returned ESTALE.
This will be used by autofs (in the next few commits).
This doesn't affect other filesystems, because no other filesystem
returns ESTALE.
Autofs needs this because a target filesystem may get mounted under
the root directory of autofs while running nresolve VOP of autofs.
Autofs tells nlookup the topology has changed by returning ESTALE.
Unless nlookup retries the lookup, the result is obsolete.
Tomohiro Kusumi [Sun, 29 May 2016 02:23:29 +0000 (11:23 +0900)]
sys/sys: Fix IOCPARM_MAX
Fix the previous commit brought in from from FreeBSD@GitHub
598dc07f1ee077b425c2f447aeb3dfb632a1f2a3.
The max possible size for ioctl structure is ((1<<13)-1).
(1<<13) bit overlaps IOC_VOID, so it gets cut by _IOC().
Also see L672 of sys/kern/sys_generic.c.
Tomohiro Kusumi [Sun, 8 May 2016 17:39:43 +0000 (02:39 +0900)]
sys/sys: Extend IOCPARM_MAX
Brought in from FreeBSD@GitHub
598dc07f1ee077b425c2f447aeb3dfb632a1f2a3.
Needed by autofs (and possibly other ioctls in the future).
It was originally for ZFS on FreeBSD, but autofs needed this as well.
Also see https://bugs.dragonflybsd.org/issues/2907.
Tomohiro Kusumi [Sun, 15 May 2016 13:05:15 +0000 (22:05 +0900)]
usr.bin/showmount: Add -E option
Brought in from FreeBSD@GitHub
6fee958d289745f0f52dcc0df16858cf7e093d5c.
Needed by autofs.
Also see https://bugs.dragonflybsd.org/issues/2914.
Tomohiro Kusumi [Thu, 12 May 2016 09:38:07 +0000 (18:38 +0900)]
sbin/mount_nfs: Add -o retrycnt= option
Brought in from FreeBSD@GitHub
4f094ed2b2fd36f47b04c08e320d4d006a416874.
Needed by autofs.
Also see https://bugs.dragonflybsd.org/issues/2913.
Tomohiro Kusumi [Fri, 29 Apr 2016 01:08:11 +0000 (10:08 +0900)]
sys/kern: Add kqueue EVFILT_FS
Brought in from FreeBSD@GitHub
bbaa6c3ec045b7de225f726d3c9367510b287184.
Needed by autofs.
Triggers an event on mount(2) and unmount(2).
Also see https://bugs.dragonflybsd.org/issues/2905.
Reviewed-by: sephe
Tomohiro Kusumi [Fri, 22 Apr 2016 04:18:47 +0000 (13:18 +0900)]
sys/kern: Add kstrndup()
Needed by autofs.
Also see https://bugs.dragonflybsd.org/issues/2901.
Sascha Wildner [Thu, 2 Jun 2016 20:38:33 +0000 (22:38 +0200)]
rescue image: Strip lvm(8).
It's built separately outside of the crunchgen'd stuff, for reasons
I'm yet not sure of.
So of course it also needs to be stripped separately because if -g is
added to the user's buildworld flags, it will go into the initrd with
debug symbols (filling it to 95%, opposed to the (currently) 73% when
not stripped).
Sascha Wildner [Thu, 2 Jun 2016 20:16:52 +0000 (22:16 +0200)]
rescue image: Add undo(1).
It's useful to have in there.
Dragonfly-bug: <https://bugs.dragonflybsd.org/issues/2798> (suggestion)
Imre Vadász [Fri, 27 May 2016 22:50:31 +0000 (00:50 +0200)]
if_iwm - Workaround, which fixes beacon and statistic notification issue.
Imre Vadász [Wed, 25 May 2016 17:53:15 +0000 (19:53 +0200)]
if_iwm - Add 3165 chipset ids.
* The 3165 chipset currently uses the 7265 firmware, because of issues
with the 7265D firmware.
Imre Vadász [Mon, 23 May 2016 21:43:03 +0000 (23:43 +0200)]
if_iwm - Update to support version 16 firmware.
* XXX The firmware always signals missed beacons, and doesn't give us
statistics notifications.
Taken-From: OpenBSD
Imre Vadász [Sat, 21 May 2016 21:02:28 +0000 (23:02 +0200)]
iwmfw - Update to version 16 firmware.
Sepherosa Ziehau [Thu, 2 Jun 2016 16:25:21 +0000 (00:25 +0800)]
kern: Remove debug print
Sepherosa Ziehau [Thu, 2 Jun 2016 16:15:59 +0000 (00:15 +0800)]
kern: Use objcache for file
This improves connect/accept rate bit (450Kconns/s -> 485Kconns/s).
Imre Vadász [Wed, 1 Jun 2016 22:01:37 +0000 (00:01 +0200)]
smbacpi.4: Add a manpage for smbacpi(4).
Sascha Wildner [Wed, 1 Jun 2016 18:20:55 +0000 (20:20 +0200)]
rc.conf.5: Document powerd_flags.
Sascha Wildner [Wed, 1 Jun 2016 08:54:06 +0000 (10:54 +0200)]
kernel/inet6: Fix two wrong comparisons.
Submitted-by: fenyo
Dragonfly-bug: <https://bugs.dragonflybsd.org/issues/2810>
Approved-by: sephe
Sascha Wildner [Tue, 31 May 2016 21:27:35 +0000 (23:27 +0200)]
installer: Use ioctl(DIOCGPART) for getting a disk's size.
Before this commit, the installer was grepping in /var/run/dmesg.boot.
This approach has one problem in particular, which is that it was
used with CAM attached disks in mind, which will always print their
size in MiBs. However, some drivers, such as mmcsd(4), roll their own
disk, so they are free to choose what they print in their *_attach()
function. Yet we still want to offer these disks from the installer.
For example, mmcsd(4) starts printing the size in gigabytes if the
disk is >= 10GiB.
This commit changes the installer's survey function to read the
disk's size using ioctl(DIOCGPART) to have consistent results.
Reported-by: Dmitry Postolov <dpostolov@yandex.ru>
Dragonfly-bug: <https://bugs.dragonflybsd.org/issues/2899>
Sascha Wildner [Tue, 31 May 2016 18:42:18 +0000 (20:42 +0200)]
/etc/defaults/rc.conf: Add a powerd_flags definition.
Imre Vadász [Sat, 2 Apr 2016 20:52:18 +0000 (22:52 +0200)]
smbacpi: Implement I2cSerialBus ACPI support module. For use by ig4(4).
* Registers just the ACPI operation region handler, no ACPI resource
handling yet.
Imre Vadász [Thu, 17 Mar 2016 13:20:15 +0000 (14:20 +0100)]
ig4: Add ig4_acpi.c for attaching on ACPI (needed for Bay-/Cherry- Trail).
Sepherosa Ziehau [Mon, 30 May 2016 12:38:40 +0000 (20:38 +0800)]
tcp: Don't prematurely drop receiving-only connections.
If the connection was persistent and receiving-only, several (12)
sporadic device insufficient buffers would cause the connection be
dropped prematurely:
Upon ENOBUFS in tcp_output() for an ACK, retransmission timer is
started. No one will stop this retransmission timer for receiving-
only connection, so the retransmission timer promises to expire and
t_rxtshift is promised to be increased. And t_rxtshift will not be
reset to 0, since no RTT measurement will be done for receiving-only
connection. If this receiving-only connection lived long enough,
and it suffered 12 sporadic device insufficient buffers, i.e.
t_rxtshift >= 12, this receiving-only connection would be dropped
prematurely by the retransmission timer.
We now assert that for data segments, SYNs or FINs either rexmit or
persist timer was wired upon ENOBUFS. And don't set rexmit timer
for other cases, i.e. ENOBUFS upon ACKs.
And we no longer penalize send window upon ENOBUFS.
Obtained-from: FreeBSD r300981
Sascha Wildner [Sun, 29 May 2016 19:42:55 +0000 (21:42 +0200)]
ieee80211.9: Fix .Nm
Sascha Wildner [Sun, 29 May 2016 19:41:20 +0000 (21:41 +0200)]
Remove an unused manual page.
Imre Vadász [Wed, 11 May 2016 20:11:05 +0000 (22:11 +0200)]
gpio_acpi: Turn this into a child device of gpio_intel.
* This makes gpio_intel much more independent from gpio_acpi.
* Less adjustments needed in gpio drivers for using gpio_acpi.
* Some slight cleanup, and refactoring turning device_t args to
struct gpio_acpi_softc * args.
Imre Vadász [Sat, 30 Apr 2016 16:46:11 +0000 (18:46 +0200)]
gpio_acpi: Add allocate/release functions for GpioIo pins.
* This slightly simplifies the read_pin and write_pin functions, and
configuration errors should now be found when allocating the pin,
instead of causing a panic in read_pin() or write_pin().
Imre Vadász [Sat, 28 May 2016 21:26:37 +0000 (23:26 +0200)]
gpio_acpi: Factor out gpio_acpi_check_gpioint().
* gpio_acpi_check_gpioint() can be reused for the device-driver facing
interface for dealing with gpio acpi-resources.
Matthew Dillon [Sat, 28 May 2016 22:56:13 +0000 (15:56 -0700)]
kernel - Align virtual_start, workaround possible HW VM bugs
* virtual_start is 2MB-aligned at the kernel load's end address.
The page table mappings prior to this address are 2MB mappings.
Additional SYSMAP()d space is reserved in early boot, such as
the CMAP entries and the dmesg buffer. The page table mappings
in this area should all be 4K pages.
* Kernel virtual memory beyond the SYSMAP()d space is available for
general allocation, but positioned such that only kldload modules will
try to use it specifically. Sascha (swildner) found that any initial
kldload done after boot in vmware player 7.1.4 build-3848939 running
on a i7-4770K based host would panic.
A kernel core of this panic appears to show a corrupt pte in a location
where the pte should have been read as 0.
* Doing an additional 2MB alignment of virtual_start after the SYSMAP()s
appears to work around this corruption, which is this commit. This
means that the first general allocation in the kernel load portion of
the kernel_map will be shifted to the next 2MB boundary past the SYSMAP()s.
* I can only speculate that the hardware is somehow getting confused, but
I can't really fathon how it is getting confused because the SYSMAP
reservations should all be using 4KB pages.
Sascha Wildner [Sat, 28 May 2016 11:09:15 +0000 (13:09 +0200)]
Some more cleanup in comments etc. after the an(4) removal.
Sascha Wildner [Sat, 28 May 2016 09:42:11 +0000 (11:42 +0200)]
ieee80211_vap.9: Fix date.
Sascha Wildner [Sat, 28 May 2016 01:15:50 +0000 (03:15 +0200)]
Various typo and wording fixes.
Matthew Dillon [Sat, 28 May 2016 00:51:57 +0000 (17:51 -0700)]
virtio - fix contigmalloc muff last commit
* Have to use M_WAITOK for contigmalloc, not M_INTWAIT.
Reported-by: tuxillo
Sascha Wildner [Sat, 28 May 2016 00:31:27 +0000 (02:31 +0200)]
Sync ACPICA with Intel's version
20160527.
* Temporarily reverted the new arbitrary bit length/alignment support
in AcpiHwRead/AcpiHwWrite for the Generic Address Structure. There
have been a number of regressions with the new code that need to be
fully resolved and tested before this support can be finally
integrated into ACPICA. Apologies for any inconveniences these
issues may have caused.
* The ACPI message macros are not configurable (ACPI_MSG_ERROR,
ACPI_MSG_EXCEPTION, ACPI_MSG_WARNING, ACPI_MSG_INFO,
ACPI_MSG_BIOS_ERROR, and ACPI_MSG_BIOS_WARNING). Lv Zheng.
* Fixed a couple of GCC warnings associated with the use of the
-Wcast-qual option. Adds a new return macro, return_STR.
Jung-uk Kim.
For a more detailed list, please see sys/contrib/dev/acpica/changes.txt.
Matthew Dillon [Sat, 28 May 2016 00:33:18 +0000 (17:33 -0700)]
virtio - vtblk_finish_bio() called with serializer held
* vtblk_finish_bio() was being improperly called with the
serializer held in the strategy error path.
* Note that biodone() is properly called without the
serializer held in the normal completion path.
Matthew Dillon [Sat, 28 May 2016 00:14:24 +0000 (17:14 -0700)]
virtio - Fix a few porting issues and bugs
* vtblk_maximum_segments() was really buggy. It was
adding the base min segments to blkcfg->seg_max,
miscalculating values for the case where the F_SEG_MAX
feature is not in the feature list.
This could result in virtio imploding on a too-small
sglist.
* Fix situations where M_NOWAIT is improperly used.
* At least use 16-byte alignment for contigmalloc()'s.
Imre Vadász [Sat, 31 Oct 2015 15:48:18 +0000 (16:48 +0100)]
virtio_blk: Add support for indirect buffers.
Taken-From: FreeBSD
Sascha Wildner [Fri, 27 May 2016 08:32:47 +0000 (10:32 +0200)]
wlan.4: Comment out reference to bwi(4) which we do not have.
Sascha Wildner [Thu, 26 May 2016 21:45:48 +0000 (23:45 +0200)]
Various tiny updates in wlan*.4 manual pages and other related areas.
Sascha Wildner [Thu, 26 May 2016 20:43:20 +0000 (22:43 +0200)]
ieee80211*.9: Fix some prototypes in the manual pages.
Matthew Dillon [Thu, 26 May 2016 18:22:50 +0000 (11:22 -0700)]
kernel - Augment pte assertion with additional info
* Augment the invalid PTE assertion to print additional info. This bug was
thought to have been squashed but we received a recent report of it still
occurring (on an older cpu).
Sascha Wildner [Thu, 26 May 2016 15:01:50 +0000 (17:01 +0200)]
Sync wlan driver manual pages with FreeBSD.
Imre Vadász [Wed, 25 May 2016 19:03:22 +0000 (21:03 +0200)]
if_iwm - valid_{tx,rx}_ant from radio_cfg is only needed for 8000 family.
* The "if (!data->valid_tx_ant || !data->valid_rx_ant) {" check was getting
triggered with a 3165 chipset.
Sepherosa Ziehau [Thu, 26 May 2016 13:22:58 +0000 (21:22 +0800)]
tcp: Make setsockopt(2) TCP_{NODELAY,NOPUSH,NOOPT,FASTKEEP} asynchronous
This makes all network system calls used by nginx asynchronous and greatly
improves nginx performance.
For 1 requests/connection (30K concurrent connections), this commit gives
12% improvement for 16KB web object (was 16.8Gbps, now 19.2Gbps, which
maxes out 2x10Ge). And it gives 19% improvement for 1KB web object (was
156Kreqs/s, now 186Kreqs/s).
Sascha Wildner [Thu, 26 May 2016 10:01:26 +0000 (12:01 +0200)]
Regenerate devd's usb.conf for accumulated usb driver updates.
Sascha Wildner [Wed, 25 May 2016 18:45:17 +0000 (20:45 +0200)]
Sync our ieee80211* manpages with FreeBSD (plus some adjustments by me).
Matthew Dillon [Wed, 25 May 2016 18:11:13 +0000 (11:11 -0700)]
ral - Add missing BUS_DMA_NOWAIT to bus_dmamap_load_mbuf_segment() calls
* Add missing BUS_DMA_NOWAIT to bus_dmamap_load_mbuf_segment() calls.
* NOTE: FreeBSD original code in #else not modified, but probably needs
the same change (to bus_dmamap_load_mbuf_sg()).
Sascha Wildner [Wed, 25 May 2016 17:00:51 +0000 (19:00 +0200)]
Remove an(4)/ancontrol(8) references from several manual pages.