summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* Add a generic firmware dependent handle to pass from the loader to theimp2015-12-181-0/+1
| | | | | | kernel. This will be used for passing in things like the system table from EFI or other similar metadata that can be used by the kernel to communicate with the firmware.
* No need to test command values this way. There can be only one, evenimp2015-12-182-13/+13
| | | | though the encoding is bit-wise today...
* Use variable names that aren't as prone to dyslexic confusion.imp2015-12-181-2/+2
| | | | Suggested by: jmallet@
* [intrng] Migrate the intrng code from sys/arm/arm to sys/kern/subr_intr.c.adrian2015-12-1822-389/+386
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The ci20 port (by kan@) is going to reuse almost all of the intrng code since the SoC in question looks suspiciously like someone took an ARM SoC design and replaced the ARM core with a MIPS core. * migrate out the code; * rename ARM_ -> INTR_; * rename arm_ -> intr_; * move the interrupt flush routine from intr.c / intrng.c into arm/machdep_intr.c - removing the code duplication and removing the ARM specific bits from here. Thanks to the Star Wars: The Force Awakens premiere line for allowing me a couple hours of quiet time to finish the universe builds. Tested: * make universe TODO: * The structure definitions in subr_intr.c still includes machine/intr.h which requires one duplicates all of the intrng definitions in the platform code (which kan has done, and I think we don't have to.) Instead I should break out the generic things (function declarations, common intr structures, etc) into a separate header. * Kan has requested I make the PIC based IPI stuff optional.
* Scheduling module to introduce a fixed delay into the I/O path.imp2015-12-183-1/+273
|
* Create a simplebus PNP info wrapper.imp2015-12-182-0/+5
| | | | Differential Review: https://reviews.freebsd.org/D4517
* Flag sysctl hw.mmc.debug as a tunable, since often you want to debug theian2015-12-181-1/+1
| | | | bus probing during system startup.
* Fix the clock divisor calc for imx6 sdcard bus speed.ian2015-12-181-2/+9
| | | | | | | | I don't know what alternate universe I was inhabiting when I wrote it originally, but apparently the basic workings of mathematics were different than in this universe. I also can't explain how it ever worked, except "by accident", because completely bogus values were being written into the divisor register.
* ioat(4): Add an API to get HW revisioncem2015-12-174-4/+23
| | | | | | | | Different revisions support different operations. Refer to Intel External Design Specifications to figure out what your hardware supports. Sponsored by: EMC / Isilon Storage Division
* Fix regression in if_ndis in r280347.glebius2015-12-171-2/+1
| | | | | | | Submitted by: avos Reported by: Ev Bogdanov <evbogdanov yahoo.com> Tested by: Ivan Kormachev <ikormachev depit.ru> MFC after: 3 days
* Exit cleanly if malloc() fails to allocate a buffer for a copy of thejhb2015-12-171-0/+2
| | | | | | | | current MBR. PR: 205322 Submitted by: Alexander Kuleshov <kuleshovmail@gmail.com> MFC after: 1 week
* t seems certain Intel GPUs use GPIO bitbanging over a child devicejhb2015-12-171-1/+1
| | | | | | | | | | | | | instead of GMBUS access for I2C transfers. The GMBUS driver falls back to this mode when a transfer times out. However, the first transfer to timeout was sending the request back to itself resulting in an panic due to recursing on a lock. Fix it to forward the request on to the proper device. This appears to have been accidentally changed in r277487. Reported by: Joe Maloney <jmaloney@pcbsd.org> Reviewed by: adrian, dumbbell, imp MFC after: 1 week Differential Revision: https://reviews.freebsd.org/D4599
* Incorrect length in calloc() call, already fixed upstream.des2015-12-171-1/+1
| | | | | | PR: 204769 Submitted by: David Binderman <dcb314@hotmail.com> MFC after: 1 week
* Import RISC-V machine headers. This is a minimal set required to compilebr2015-12-1757-0/+4616
| | | | | | | | | kernel and userland. Reviewed by: andrew, imp, kib Sponsored by: DARPA, AFRL Sponsored by: HEIF5 Differential Revision: https://reviews.freebsd.org/D4554
* vm_page_replace: add wrapper to KASSERT about old pagecem2015-12-173-4/+17
| | | | | | | | | | | | | It turns out the callers of vm_page_replace know exactly which page they are replacing and would like to assert about it. Change those from hard panics to KASSERTs, and provide them with a wrapper so they don't have to deal with warnings from an INVARIANTS-dependent dead store of the return value of vm_page_replace. Submitted by: Ryan Libby <rlibby@gmail.com> Reviewed by: alc, kib (earlier version) Sponsored by: EMC / Isilon Storage Division Differential Revision: https://reviews.freebsd.org/D4497
* Support the variant of the interrupt-map property where the parent bus hasandrew2015-12-172-2/+18
| | | | | | | | | | | | | the #address-cells property set. For this we need to read more data before the parent interrupt description. this is only enabled on arm64 for now as it's not quite compliant with the ePAPR spec. We should use a default of 2 where the #address-cells property is missing, however this will need further testing across architectures. Obtained from: ABT Systems Ltd Sponsored by: SoftIron Inc Differential Revision: https://reviews.freebsd.org/D4518
* Revert r292275 & r292379smh2015-12-1713-289/+66
| | | | | | | glebius has concerns about these changes so reverting those can be discussed and addressed. Sponsored by: Multiplay
* RIP Juergen Lock (nox@FreeBSD.org), you and your contributions won't be ↵brueffer2015-12-171-0/+1
| | | | forgotten.
* Switch the IPsec related statistics to using the built in sysctlgnn2015-12-172-14/+24
| | | | | | | | | variable set rather than reading from kernel memory. This also makes the -z (zero) flag work correctly MFC after: 1 week Sponsored by: Rubicon Communications, LLC (Netgate) Differential Revision: https://reviews.freebsd.org/D4591
* Consistently use ${AWK} instead of hard-coding the program name.markj2015-12-171-1/+1
| | | | MFC after: 3 days
* Support an arbitrary number of arguments to DTrace syscall probes.markj2015-12-174-62/+68
| | | | | | | | | | Rather than pushing all eight possible arguments into dtrace_probe()'s stack frame, make the syscall_args struct for the current syscall available via the current thread. Using a custom getargval method for the systrace provider, this allows any syscall argument to be fetched, even in kernels that have modified the maximum number of system call arguments. Sponsored by: EMC / Isilon Storage Division
* Fix breakage caused by r292373 in ZFS/FUSE/NFS/SMBFS.glebius2015-12-164-60/+47
| | | | | | | | | | With the new VOP_GETPAGES() KPI the "count" argument counts pages already, and doesn't need to be translated from bytes to pages. While here make it consistent that *rbehind and *rahead are updated only if we doesn't return error. Pointy hat to: glebius
* Remove the unused systrace device file and fix style bugs.markj2015-12-161-61/+41
| | | | MFC after: 1 week
* Fix style issues around existing SDT probes.markj2015-12-1615-152/+145
| | | | | | | | | - Use SDT_PROBE<N>() instead of SDT_PROBE(). This has no functional effect at the moment, but will be needed for some future changes. - Don't hardcode the module component of the probe identifier. This is set automatically by the SDT framework. MFC after: 1 week
* vm_page.h: page busy macro fixupscem2015-12-161-8/+9
| | | | | | | | | | | Minor changes to: - delete extraneous trailing semicolons from macro definitions, and - correct spelling of "busying" in panic messages Submitted by: Ryan Libby <rlibby@gmail.com> Reviewed by: alc, kib Sponsored by: EMC / Isilon Storage Division Differential Revision: https://reviews.freebsd.org/D4577
* Fix issues introduced by r292275smh2015-12-164-6/+11
| | | | | | | | | | | | * Fix panic for etherswitches which don't have a LLADDR. * Disabled DELAY in unsolicited NDA, which needs further work. * Fixed missing DELAY in carp_send_na. * style(9) fix. Reported by: kp & melifaro X-MFC-With: r292275 MFC after: 1 month Sponsored by: Multiplay
* A change to KPI of vm_pager_get_pages() and underlying VOP_GETPAGES().glebius2015-12-1629-805/+505
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | o With new KPI consumers can request contiguous ranges of pages, and unlike before, all pages will be kept busied on return, like it was done before with the 'reqpage' only. Now the reqpage goes away. With new interface it is easier to implement code protected from race conditions. Such arrayed requests for now should be preceeded by a call to vm_pager_haspage() to make sure that request is possible. This could be improved later, making vm_pager_haspage() obsolete. Strenghtening the promises on the business of the array of pages allows us to remove such hacks as swp_pager_free_nrpage() and vm_pager_free_nonreq(). o New KPI accepts two integer pointers that may optionally point at values for read ahead and read behind, that a pager may do, if it can. These pages are completely owned by pager, and not controlled by the caller. This shifts the UFS-specific readahead logic from vm_fault.c, which should be file system agnostic, into vnode_pager.c. It also removes one VOP_BMAP() request per hard fault. Discussed with: kib, alc, jeff, scottl Sponsored by: Nginx, Inc. Sponsored by: Netflix
* Flag the first port on a Sheevaplug ftdi serial device as jtag.ian2015-12-161-1/+1
|
* sh: Fix use-after-free when attempting to modify a read-only variable.jilles2015-12-161-1/+1
| | | | | Reported by: bapt MFC after: 1 week
* Remove lldb(1) files if WITHOUT_LLDB is setemaste2015-12-161-0/+5
| | | | Sponsored by: The FreeBSD Foundation
* Enable LLDB by default on amd64 and arm64emaste2015-12-161-1/+5
| | | | | | | | | | | | | | | | | LLDB is usable for userland core file and live debugging on amd64, and for userland core file debugging on arm64. In general it works at least as well on FreeBSD as our in-tree gdb version, so enable it by default to allow for broader use and testing. An LLDB tutorial is available at http://lldb.llvm.org/tutorial.html, and a table mapping GDB commands to LLDB commands can be found at http://lldb.llvm.org/lldb-gdb.html . LLDB also has some level of support for FreeBSD on arm, mips, i386, and powerpc, but is not yet ready to have them enabled by default. Reviewed by: gnn Relnotes: Yes
* Use human readable representation of ip for the pxeboot.ip kenvbapt2015-12-161-3/+2
| | | | | | While here use colon as a separator for pxeboot.hwaddr kenv Sponsored by: Gandi.net
* pxeboot: make the tftp loader use the option root-path directivebapt2015-12-165-32/+26
| | | | | | | | | | | | | | | | | | | | pxeboot in tftp loader mode (when built with LOADER_TFTP_SUPPORT) now prefix all the path to open with the path obtained via the option 'root-path' directive. This allows to be able to use the traditional content /boot out of box. Meaning it now works pretty much like all other loaders. It simplifies hosting hosting multiple version of FreeBSD on a tftp server. As a consequence, pxeboot does not look anymore for a pxeboot.4th (which was never provided) Note: that pxeboot in tftp loader mode is not built by default. Reviewed by: rpokala Relnotes: yes Sponsored by: Gandi.net Differential Revision: https://reviews.freebsd.org/D4590
* UEFI: combine GetMemoryMap and ExitBootServices and retry on erroremaste2015-12-165-38/+39
| | | | | | | | | | | | | | | | | | | | | | | | | | The EFI memory map may change before or during the first ExitBootServices call. In that case ExitBootServices returns an error, and GetMemoryMap and ExitBootServices must be retried. Glue together calls to GetMemoryMap(), ExitBootServices() and storage of (now up-to-date) MODINFOMD_EFI_MAP metadata within a single function. That new function - bi_add_efi_data_and_exit() - uses space previously allocated in bi_load_efi_data() to store the memory map (it will fail if that space is too short). It handles re-calling GetMemoryMap() once to update the map key if necessary. Finally, if ExitBootServices() is successful, it stores the memory map and its header as MODINFOMD_EFI_MAP metadata. ExitBootServices() calls are now done earlier, from within arch- independent bi_load() code. PR: 202455 Submitted by: Ganael LAPLANCHE Reviewed by: kib MFC after: 2 weeks Relnotes: Yes Differential Revision: https://reviews.freebsd.org/D4296
* Build mount_smbfs for arm. Also sort the subdirs.ian2015-12-161-1/+2
|
* Remove redundant extern's that make the ppc compile fail.rrs2015-12-161-25/+0
| | | | Thanks Ed Maste for the heads up.
* Adopt assert from amd64 in pmap_remove_pages().skra2015-12-161-3/+18
| | | | | Suggested by: kib Approved by: kib (mentor)
* Provide additional lle data in IPv6 lltable dump used by ndp(8).melifaro2015-12-164-45/+49
| | | | | | | | | | | | | | | Before the change, things like lle state were queried via SIOCGNBRINFO_IN6 by ndp(8) for _each_ lle entry in dump. This ioctl was added in 1999, probably to avoid touching rtsock code. This change maps SIOCGNBRINFO_IN6 data to standard rtsock dump the following way: expire (already) maps to rtm_rmx.rmx_expire isrouter -> rtm_flags & RTF_GATEWAY asked -> rtm_rmx.rmx_pksent state -> rtm_rmx.rmx_state (maps to rmx_weight via define) Reviewed by: ae
* As a followup to r292330, standardize on size_t and add a few comments.des2015-12-161-2/+5
|
* Convert if_stf(4) to new routing api.melifaro2015-12-161-20/+8
|
* Reset bufpos to 0 immediately after refilling the buffer. Otherwise, wedes2015-12-161-3/+2
| | | | | | | | | | risk leaving the connection in an indeterminate state if the server fails to send a chunk delimiter. Depending on the application and on the sizes of the preceding chunks, the result can be anything from missing data to a segfault. With this patch, it will be reported as a protocol error. PR: 204771 MFC after: 1 week
* Fix ARP reply handling changed in r286955.melifaro2015-12-161-4/+12
| | | | | | | | If source of ARP request didn't pass the routing check (e.g. not in directly connected network), be polite and still answer the request instead of dropping frame. Reported by: quadro at irc@rusnet
* Integrate a number of testcases from tools/regression/lib/msunngie2015-12-1629-136/+27
| | | | | | | | | | | | | | into the FreeBSD test suite There's no functional change with these testcases; they're purposely being left in TAP format for the time being Other testcases which crash on amd64/i386 as-is have not been integrated yet (they need to be retested on a later version of CURRENT, as I haven't used i386 in some time) MFC after: 3 weeks Sponsored by: EMC / Isilon Storage Division
* Use fabsl instead of fabs to mute -Wabsolute-value warnings from clangngie2015-12-161-4/+4
| | | | | | | because `nums[]` is an array of long doubles MFC after: 1 week Sponsored by: EMC / Isilon Storage Division
* Optimize vop_stdadvise(POSIX_FADV_DONTNEED). Instead of looking up akib2015-12-163-29/+54
| | | | | | | | | | | | | | buffer for each block number in the range with gbincore(), look up the next instantiated buffer with the logical block number which is greater or equal to the next lblkno. This significantly speeds up the iteration for sparce-populated range. Move the iteration into new helper bnoreuselist(), which is structured similarly to flushbuflist(). Reported and tested by: pho Reviewed by: markj Sponsored by: The FreeBSD Foundation
* Simplify the loop step in the flushbuflist() and make it independed onkib2015-12-161-4/+3
| | | | | | | | | | the type stability of the buffers memory. Instead of memoizing pointer to the next buffer and validating it, remember the next logical block number in the bo list and re-lookup. Reviewed by: markj Tested by: pho Sponsored by: The FreeBSD Foundation
* Iterate down lib/libc/tests/nss...ngie2015-12-161-0/+1
| | | | | | MFC after: 1 week X-MFC with: r292323 Sponsored by: EMC / Isilon Storage Division
* Integrate tools/regression/lib/libc/nss into the FreeBSD test suite asngie2015-12-1623-2515/+2486
| | | | | | | | | | | | | | | | | lib/libc/tests/nss - Convert the testcases to ATF - Do some style(9) cleanups: -- Sort headers -- Apply indentation fixes -- Remove superfluous parentheses - Explicitly print out debug printfs for use with `kyua {debug,report}`; for items that were overly noisy, they've been put behind #ifdef DEBUG conditionals - Fix some format strings MFC after: 1 week Sponsored by: EMC / Isilon Storage Division
* Add ATF_REQUIRE_FEATURE and PLAIN_REQUIRE_FEATURE macros forngie2015-12-161-0/+15
| | | | | | | | | | | testing for kernel features via the feature_present(3) libcall The semantics are similar to the other macros in the header (skip testcase with ATF macro; exit with appropriate exit code with the PLAIN macro) MFC after: 1 week Sponsored by: EMC / Isilon Storage Division
* Add Makefile accidentally missed in r292317ngie2015-12-161-0/+15
| | | | | | MFC after: 1 week X-MFC with: r292317 Sponsored by: EMC / Isilon Storage Division
OpenPOWER on IntegriCloud