summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* Pull in r264335 from upstream llvm trunk:dim2016-03-241-0/+1
| | | | | | | | | | | | | | | | | | | Add <atomic> to ThreadPool.h, since std::atomic is used Summary: Apparently, when compiling with gcc 5.3.2 for powerpc64, the order of headers is such that it gets an error about std::atomic<> use in ThreadPool.h, since this header is not included explicitly. See also: https://llvm.org/bugs/show_bug.cgi?id=27058 Fix this by including <atomic>. Patch by Bryan Drewery. Reviewers: chandlerc, joker.eph Subscribers: bdrewery, llvm-commits Differential Revision: http://reviews.llvm.org/D18460
* Polish wbwd(4) driver and add more supported chips.mav2016-03-244-143/+298
| | | | MFC after: 1 month
* elfcopy: overhaul of LMA handlingemaste2016-03-242-89/+184
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Merge ELF Tool Chain r3434: Previously, elfcopy defines: VMA: section virtual address LMA: PHDR(p_vaddr) While binutils(libbfd) defines: VMA: section virtual address and PHDR(p_vaddr). LMA: PHDR(p_paddr) For elfcopy, p_paddr is considered not meaningful and is always set to the same value as p_vaddr. elfcopy was implemented that way because I thought p_paddr is not used/meaningful according to the ELF ABI. However it turned out p_paddr is at least used in some ELF files, e.g. the FreeBSD kernel. This change made elfcopy treat p_paddr as LMA, same as libbfd. (However, some VMA/LMA related command line option still need tweaking to make them compatible with binutils objcopy. This will be improved later) Ticket: #524 And typo fixes in r3435 and r3436. This fixes the Xen kernel build. Submitted by: kaiw Tested by: royger
* Space and style(9) corrections for recent mbuf changes.glebius2016-03-242-6/+8
|
* libc: stop exporting curbrk and minbrk in the private namespaceemaste2016-03-249-18/+0
| | | | | | | | | They are not used anywhere else in the base system and are an internal implementation detail that does not need to be exposed. Reviewed by: kib Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D5728
* Add 4k enabled cam quirks for Samsung SM863 Series SSDssbruno2016-03-242-0/+16
| | | | | | | Submitted by: Jason (j@nitrology.com) MFC after: 2 weeks Sponsored by: Limelight Networks Differential Revision: https://reviews.freebsd.org/D5711
* Speed up lookups in autofs(5) by using red-black trees instead of lineartrasz2016-03-244-24/+40
| | | | | | | | | searches. Reviewed by: kib@ MFC after: 1 month Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D5627
* arm64: Fixing user space boudary checking in copyinout.Swma2016-03-241-3/+5
| | | | | | | | | | | | | | Big buffer size could cause integer overflow and as a result attempt to copy beyond VM_USERMAX_ADDRESS. Fixing copyinstr boundary checking where compared value has been overwritten by accident when setting fault handler. Submitted by: Dominik Ermel <der@semihalf.com> Obtained from: Semihalf Sponsored by: Cavium Reviewed by: kib Differential Revision: https://reviews.freebsd.org/D5719
* Fix compile errors after r297225:bz2016-03-244-4/+4
| | | | | | | | | - properly V_irtualise variable access unbreaking VIMAGE kernels. - remove the volatile from the function return type to make architecture using gcc happy [-Wreturn-type] "type qualifiers ignored on function return type" I am not entirely happy with this solution putting the u_int there but it will do for now.
* Unify ignoring EEXIST from zvol_create_minor().mav2016-03-241-1/+2
| | | | | | | | This fixes creation of zvol devices for snapshots during zfs receive, that previously failed with "ZFS WARNING: Unable to create ZVOL" message. This solution is not perfect, but IMHO better then it was before. MFC after: 2 weeks
* Handle the driver KPI change from r292373. Ensure that managed devicekib2016-03-242-28/+23
| | | | | | | | | | | pagers fault routines always return with a result page, be it the proper and valid result page, or initially passed freshly allocated placeholder. Do not free the passed in page until we are able to provide the replacement, and do not assign NULL to *mres. Reported and tested by: dumbbell Reviewed by: royger (who also verified that Xen code is safe) Sponsored by: The FreeBSD Foundation
* Generalize IPI support for ARM intrng and use it for interruptskra2016-03-248-108/+147
| | | | | | | | | | | | | | | controller IPI provider. New struct intr_ipi is defined which keeps all info about an IPI: its name, counter, send and dispatch methods. Generic intr_ipi_setup(), intr_ipi_send() and intr_ipi_dispatch() functions are implemented. An IPI provider must implement two functions: (1) an intr_ipi_send_t function which is able to send an IPI, (2) a setup function which initializes itself for an IPI and calls intr_ipi_setup() with appropriate arguments. Differential Revision: https://reviews.freebsd.org/D5700
* Add more UHCI PCI IDs.hselasky2016-03-241-0/+6
| | | | Submitted by: Dmitry Luhtionov <dmitryluhtionov@gmail.com>
* Move mbuf provider under SDT to indicate that it is FreeBSD specificgnn2016-03-242-28/+24
| | | | | | | | | and not a stable interface. Reviewed by: markj MFC after: 2 weeks Sponsored by: Rubicon Communications (Netgate) Differential Revision: https://reviews.freebsd.org/D5716
* Install a usable mailer.conf for dragonfly mailer agent if sendmail is disabledbapt2016-03-241-0/+7
|
* FreeBSD previously provided route caching for TCP (and UDP). Re-addgnn2016-03-2413-41/+160
| | | | | | | | | | route caching for TCP, with some improvements. In particular, invalidate the route cache if a new route is added, which might be a better match. The cache is automatically invalidated if the old route is deleted. Submitted by: Mike Karels Reviewed by: gnn Differential Revision: https://reviews.freebsd.org/D4306
* Pass the expected struct radix_node_head * to vfs_free_netcred.bdrewery2016-03-241-1/+1
| | | | | | | | | | | | No functional change. struct radix_node_head's first element is rh so this was already referring to the same address. It was likely an unintended s/rnh/&rnh->rh/ change from r294706 as all other rnh_walktree() callers pass the expected struct radix_node_head * rather than obscurely passing the address of their first element. Sponsored by: EMC / Isilon Storage Division
* Fix M_RTABLE memory leak from r274118 (11/2014).bdrewery2016-03-241-1/+1
| | | | | | | | | | Replace free(M_RTABLE) with rn_detachhead() to match rn_inithead(). This would trigger when reloading NFS exports and was similar to problems with pf reload [1]. PR: 194078 [1] Sponsored by: EMC / Isilon Storage Division
* hyperv/vmbus: Create per-cpu fast taskqueue for msg handlingsephe2016-03-242-3/+13
| | | | | | | | | | Using one taskqueue does not work, since the EOM MSR must be written on the msg's owner CPU. Noticed by: Jun Su <junsu microsoft com> Discussed with: Jun Su <junsu microsoft com>, Dexuan Cui <decui microsoft com> MFC after: 1 week Sponsored by: Microsoft OSTC
* hyperv/utils: Allow hint to disable individual utilitysephe2016-03-244-0/+16
| | | | | | | Reviewed by: kib, Dexuan Cui <decui microsoft com> MFC after: 1 week Sponsored by: Microsoft OSTC Differential Revision: https://reviews.freebsd.org/D5714
* hyperv/vmbus: use a better retry method in hv_vmbus_post_message()sephe2016-03-242-18/+23
| | | | | | | | | | | | | | | | | | | | Most often, hv_vmbus_post_message() doesn't fail. However, it fails intermittently when GPADLs of large shared memory is to be established with the host, e.g. on the hn(4) attach path: a GPADL of 15MB sendbuf is created, for which lots of messages will be flooded to the host. The host side tries to throttle the message rate by returning HV_STATUS_INSUFFICIENT_BUFFERS. Before this commit, we do several retries for failed messages, but the delay between each retry is pretty/too low, which will cause sporadic message posting failure. We now use large delay (>=1ms) between each retry to fix the message posting failure. Submitted by: Dexuan Cui <decui microsoft com> Reviewed by: sephe MFC after: 1 week Sponsored by: Microsoft OSTC Differential Revision: https://reviews.freebsd.org/D5715
* Enable interrupts on the BSP once all PICs are initialized.jhb2016-03-243-14/+15
| | | | | | | | | | | | This moves the enabling of interrupts slightly earlier (the old location was still before devices were enumerated and probed) and does it in the interrupt code (rather than in the device configuration code). This also avoids tripping over an assertion on the first TLB shootdown with earlier AP startup. Reviewed by: kib Sponsored by: Netflix Differential Revision: https://reviews.freebsd.org/D5710
* fix incorrect usage of hid_set_data() which causes crashemax2016-03-231-17/+13
| | | | | | | | | in bthidd(8) on amd64 WITH_SSP builds Submitted by: rakuco Reviewed by: rakuco Tested by: rakuco MFC after: 1 week
* Fix support for fixed factor clocks.jmcneill2016-03-231-4/+11
| | | | | | | | | | | | - Use a different device description for fixed and fixed factor clocks. - Fix a bug where the "clock-div" property was stored in the "mult" field of the clock definition. - Get the fixed factor parent clock by index instead of by name, as a clock-names property is not required to be present here. Reviewed by: mmel, adrian (mentor) Approved by: adrian (mentor) Differential Revision: https://reviews.freebsd.org/D5703
* clk_parse_ofw_out_names is supposed to return a list of indices when thejmcneill2016-03-232-4/+4
| | | | | | | | | clock-indices property is present, so change the "uint32_t *indices" parameter to "uint32_t **indices" to allow this. Reviewed by: mmel, adrian (mentor) Approved by: adrian (mentor) Differential Revision: https://reviews.freebsd.org/D5702
* Return BUS_PROBE_GENERIC instead of 0 from ofw_clkbus_probe, givingjmcneill2016-03-231-1/+1
| | | | | | | | platform specific drivers a chance to override the generic driver. Reviewed by: mmel, adrian (mentor) Approved by: adrian (mentor) Differential Revision: https://reviews.freebsd.org/D5701
* For C++, expose long long types and functions (lldiv_t, llabs, lldiv,dim2016-03-231-1/+1
| | | | | | | etc) in stdlib.h. These will be needed for newer versions of libc++, which uses them for defining overloaded versions of abs() and div(). MFC after: 1 week
* Remove disconnected casperd, missed in r296047.bdrewery2016-03-231-23/+0
| | | | Reported by: bz
* ARM64 copyinout improvementswma2016-03-231-22/+106
| | | | | | | | | | | | | | | | | | | The first of set of patches. Use wider load/stores when aligned buffer is being copied. In a simple test: dd if=/dev/zero of=/dev/null bs=1M count=1024 the performance jumped from 410MB/s up to 3.6GB/s. TODO: - better handling of unaligned buffers (WiP) - implement similar mechanism to bzero Submitted by: Dominik Ermel <der@semihalf.com> Obtained from: Semihalf Sponsored by: Cavium Reviewed by: kib, andrew, emaste Differential Revision: https://reviews.freebsd.org/D5664
* Add const to several constants. Thanks to Nicholas Nethercote fortuexen2016-03-236-15/+15
| | | | | | | providing the patch via https://bugzilla.mozilla.org/show_bug.cgi?id=1255655 MFC after: 1 week
* Make the autofs(5) -hosts map more robust, primarily to make it correctlytrasz2016-03-233-8/+39
| | | | | | | | | | handle NFS shares containing whitespace. This also adds the -E parameter to showmount(8). Reviewed by: emaste@, jhibbits@, wblock@ MFC after: 1 month Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D5649
* Fix locking mistake in softdep_waitidle(). The surrounding codekib2016-03-231-1/+1
| | | | | | | | | expects that the loop is always exited with the SU lock owned, even on error. Reported and tested by: pho Sponsored by: The FreeBSD Foundation MFC after: 3 days
* Implement suggestion by jhb@ to have _PATH_FIRMWARE instead of hardimp2016-03-232-1/+2
| | | | coding it to be "/usr/share/firmware".
* Handle copyin failures.bdrewery2016-03-222-22/+48
| | | | | | | | | | | | | | Skip the log entry as there is nothing good to write out. Don't fail the syscall though since it already succeeded. There's no reason filemon's tracing failure should fail the already-succeeded syscall. Record the error for later to return from close(2) on the filemon devfs file descriptor. Discussed with: markj, sjg, kib (briefly with kib) Reported by: mjg MFC after: 2 weeks Sponsored by: EMC / Isilon Storage Division
* Remove unused done argument to copyinstr(9).bdrewery2016-03-221-9/+5
| | | | | MFC after: 2 weeks Sponsored by: EMC / Isilon Storage Division
* Return any log write failure encountered when closing the filemon fd.bdrewery2016-03-223-3/+32
| | | | | | | Discussed with: sjg, markj Reviewed by: sjg MFC after: 2 weeks Sponsored by: EMC / Isilon Storage Division
* Follow-up r297156: Close the log in filemon_dtr rather than in the last ↵bdrewery2016-03-221-19/+34
| | | | | | | | | | | | | | reference. If the tracer has decided to the close the log then it should be fully written, not getting more entries, when close(2) returns. This was a regression in r297156 in that it allowed a traced process to continue a traced syscall and add more entries to the log while the tracer had already closed its fd or exited. This was only really part of the daemonized process case which is abnormal. MFC after: 2 weeks Sponsored by: EMC / Isilon Storage Division
* Fix the resource_list_print_type() calls to use uintmax_t.jhibbits2016-03-2232-70/+70
| | | | Missed a bunch from r297000.
* [net80211] add missing static declarations.adrian2016-03-221-3/+3
| | | | | Submitted by: Sascha Wildner <saw@online.de> Obtained from: dragonflybsd (https://gitweb.dragonflybsd.org/dragonfly.git/commitdiff/822aeeabc8c4c074deea46383f36e6d1cdcd19f5)
* Spell out 'system calls'.bdrewery2016-03-221-2/+2
| | | | | MFC after: 2 weeks Sponsored by: EMC / Isilon Storage Division
* cxgbe(4): Be consistent and call ETHER_BPF_MTAP before writing anythingnp2016-03-221-1/+1
| | | | | to the descriptor ring no matter what path the frame takes within the driver's tx.
* to_flags is currently a 64-bit integer; however, we only use 7 bits.jtl2016-03-222-2/+2
| | | | | | | | | | | | | | | | | | | | Furthermore, there is no reason this needs to be a 64-bit integer for the forseeable future. Also, there is an inconsistency between to_flags and the mask in tcp_addoptions(). Before r195654, to_flags was a u_long and the mask in tcp_addoptions() was a u_int. r195654 changed to_flags to be a u_int64_t but left the mask in tcp_addoptions() as a u_int, meaning that these variables will only be the same width on platforms with 64-bit integers. Convert both to_flags and the mask in tcp_addoptions() to be explicitly 32-bit variables. This may save a few cycles on 32-bit platforms, and avoids unnecessarily mixing types. Differential Revision: https://reviews.freebsd.org/D5584 Reviewed by: hiren MFC after: 2 weeks Sponsored by: Juniper Networks
* Mfp4 @180378:bz2016-03-225-38/+33
| | | | | | | | | | | | Factor out nd6 and in6_attach initialization to their own files. Also move destruction into those files though still called from the central initialization. Sponsored by: CK Software GmbH Sponsored by: The FreeBSD Foundation MFC after: 2 weeks Reviewed by: gnn Differential Revision: https://reviews.freebsd.org/D5033
* Correct comment.bz2016-03-221-1/+1
| | | | MFC after: 2 weeks
* Wait for root mount tokens before showing the root mount prompt.trasz2016-03-221-0/+3
| | | | | | | | | | | | This restores the pre-r290196 behaviour, eliminating the need to manually press '.' a couple of times to get USB to finish probing. Note that there's still something wrong with the console (character echoing doesn't quite work), and there's also a reported problem with BHyVe, but those two don't seem related to the problem above. MFC after: 1 month Sponsored by: The FreeBSD Foundation
* Add an mbuf provider to DTrace.gnn2016-03-225-11/+318
| | | | | | | | | | | | | | | | | | | | | | | | | | The mbuf provider is made up of a set of Statically Defined Tracepoints which help us look into mbufs as they are allocated and freed. This can be used to inspect the buffers or for a simplified mbuf leak detector. New tracepoints are: mbuf:::m-init mbuf:::m-gethdr mbuf:::m-get mbuf:::m-getcl mbuf:::m-clget mbuf:::m-cljget mbuf:::m-cljset mbuf:::m-free mbuf:::m-freem There is also a translator for mbufs which gives some visibility into the structure, see mbuf.d for more details. Reviewed by: bz, markj MFC after: 2 weeks Sponsored by: Rubicon Communications (Netgate) Differential Revision: https://reviews.freebsd.org/D5682
* Support checksum offloading for TCP/IPV6 and UDP/IPV6.tuexen2016-03-222-7/+53
| | | | | | | | | Support SCTP checksum offloading for SCTP/IPV6. Support SCTP checksum offloading on all controllers except 82575. Reviewed by: sbruno@, erj@ MFC after: 4 weeks Differential Revision: D5193
* Adding pci_host_generic unconditionally breaks ARM boards with a PCI(e) ↵bz2016-03-221-1/+1
| | | | | | | | | | | interface. Make it a device option to be included in the kernel configs that request this file. Reported by: mmel Suggested by: mmel Reviewed by: mmel Differential Revision: https://reviews.freebsd.org/D5699
* Apparently there are some popular programs around which assume that itkib2016-03-222-2/+61
| | | | | | | | | | | | | | | | | is safe to call pthread_mutex_init() on the same shared mutex several times. POSIX claims that the behaviour in this case is undefined. Make this working by only allowing one caller to initialize the mutex. Other callers either see already completed initialization and do nothing, or busy-loop yielding while designated initializer finishes. Also make the API requirements loose by initializing mutexes on other pthread_mutex*() calls if they see uninitialized shared mutex. Only mutexes provide the hack for now, but it could be also implemented for other process shared primitives from libthr. Reported and tested by: "Oleg V. Nauman" <oleg@opentransfer.com> Sponsored by: The FreeBSD Foundation
* Use the saved program state register to detect when an exception frame isandrew2016-03-221-2/+2
| | | | | | | | | from userpsace. Previously we could have triggered a panic by trying to jump to a kernel address from userland as the trap handling code thought we received an ast in kernel mode. Obtained from: ABT Systems Ltd Sponsored by: The FreeBSD Foundation
OpenPOWER on IntegriCloud