]> CyberLeo.Net >> Repos - FreeBSD/stable/10.git/log
FreeBSD/stable/10.git
9 years agoMFC 265155, 265254:
ian [Sun, 18 May 2014 00:21:14 +0000 (00:21 +0000)]
MFC 265155, 265254:

  Omit from the universe build all config files tagged with #NO_UNIVERSE.

  Add FDT to the VYBRID kernel.

git-svn-id: svn://svn.freebsd.org/base/stable/10@266383 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC 265208: Honor the max-frequency property if it appears in the fdt data.
ian [Sun, 18 May 2014 00:15:48 +0000 (00:15 +0000)]
MFC 265208: Honor the max-frequency property if it appears in the fdt data.

git-svn-id: svn://svn.freebsd.org/base/stable/10@266382 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC 265207: Use arm_devmap_add_entry() to setup static device mapping.
ian [Sat, 17 May 2014 23:29:45 +0000 (23:29 +0000)]
MFC 265207:  Use arm_devmap_add_entry() to setup static device mapping.

git-svn-id: svn://svn.freebsd.org/base/stable/10@266381 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC 265156: Remove WANDBOARD.common, it was replaced by IMX6.
ian [Sat, 17 May 2014 23:27:02 +0000 (23:27 +0000)]
MFC 265156: Remove WANDBOARD.common, it was replaced by IMX6.

git-svn-id: svn://svn.freebsd.org/base/stable/10@266380 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC 265099, 265148, 265690:
ian [Sat, 17 May 2014 23:25:20 +0000 (23:25 +0000)]
MFC 265099, 265148, 265690:

  Add SMP support for Zedboard.

  Use edge-triggered interrupts rather than polling loops to avoid missing
  transitions of the INIT_B line.  Also, release the mutex during uiomove().

  Convert the Zynq SoC support to the new routines for static device mapping.

git-svn-id: svn://svn.freebsd.org/base/stable/10@266379 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC 265111: Make a declaration into a proper function prototype.
ian [Sat, 17 May 2014 23:21:53 +0000 (23:21 +0000)]
MFC 265111: Make a declaration into a proper function prototype.

git-svn-id: svn://svn.freebsd.org/base/stable/10@266378 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC 265059: Set the new floating point exception mask correctly.
ian [Sat, 17 May 2014 23:20:29 +0000 (23:20 +0000)]
MFC 265059: Set the new floating point exception mask correctly.

git-svn-id: svn://svn.freebsd.org/base/stable/10@266377 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC 265038:
ian [Sat, 17 May 2014 23:16:18 +0000 (23:16 +0000)]
MFC 265038:

  Move common device tree informations to separate dtsi files for A10 and
  A20 SoC. Change cubieboard1 and cubieboard2 dts files accordingly.

git-svn-id: svn://svn.freebsd.org/base/stable/10@266376 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC 265035: Move duplicated code to print l2 config into the common code.
ian [Sat, 17 May 2014 23:07:26 +0000 (23:07 +0000)]
MFC 265035: Move duplicated code to print l2 config into the common code.

git-svn-id: svn://svn.freebsd.org/base/stable/10@266375 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC 265023, 265024, 265036:
ian [Sat, 17 May 2014 23:03:04 +0000 (23:03 +0000)]
MFC 265023, 265024, 265036:

  There is no difference between IPI_STOP and IPI_STOP_HARD on ARM, so
  map them both to the same interrupt number like other arches do.

  Flush and invalidate caches on each CPU as part of handling IPI_STOP.

  Don't use multiprocessing-extensions instruction on processors that don't
  support SMP.

git-svn-id: svn://svn.freebsd.org/base/stable/10@266374 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC 264990, 264994, 265020, 265025:
ian [Sat, 17 May 2014 22:50:16 +0000 (22:50 +0000)]
MFC 264990, 264994, 265020, 265025:

  Call cpu_icache_sync_range() rather than sync_all since we know the range
  and flushing the entire icache is needlessly expensive.

  Provide a proper armv7 implementation of icache_sync_all rather than
  using armv7_idcache_wbinv_all, because wbinv_all doesn't broadcast the
  operation to other cores.  In elf_cpu_load_file() use icache_sync_all()
  and explain why it's needed (and why other sync operations aren't).

  Remove cpu_idcache_wbinv_all() from kdb_cpu_trap(), it's no longer needed.

  Explain why wbinv_all is SMP-safe when dumping, and add a missing l2 cache
  flush.  (Either it was missing here, or it isn't needed in the minidump
  case.  Adding it here seems like the safer path to consistancy.)

git-svn-id: svn://svn.freebsd.org/base/stable/10@266373 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC 264981, 264983, 264985:
ian [Sat, 17 May 2014 22:31:40 +0000 (22:31 +0000)]
MFC 264981, 264983, 264985:

  The freescale imx uart driver works for the whole i.MX family, so rename
  the header file to not have "5xx" in the name.

  Flesh out imx_uart_init() so that we're not relying on u-boot to init
  the hardware (meaning uarts other than the console will work).

  Reword a comment block a bit.

git-svn-id: svn://svn.freebsd.org/base/stable/10@266372 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC 264977:
ian [Sat, 17 May 2014 22:29:24 +0000 (22:29 +0000)]
MFC 264977:

  Stop calling imx51_ccm_foo() clock functions from imx6 code.  Instead
  define a few imx_ccm_foo() functions that are implemented by the imx51
  or imx6 ccm code.

git-svn-id: svn://svn.freebsd.org/base/stable/10@266371 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC 264696, 264721,
ian [Sat, 17 May 2014 22:19:16 +0000 (22:19 +0000)]
MFC 264696, 264721,

  Add the deprecated fp{get,set}* functions, a few ports use them.

  Rename the fp{get,set}* files so they no longer conflict with the
  softfloat version of these files.

git-svn-id: svn://svn.freebsd.org/base/stable/10@266370 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC 264702: Remove uncessary armv6 cache and TLB maintenance ops.
ian [Sat, 17 May 2014 22:05:31 +0000 (22:05 +0000)]
MFC 264702: Remove uncessary armv6 cache and TLB maintenance ops.

git-svn-id: svn://svn.freebsd.org/base/stable/10@266369 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC 264694: Fix a comment typo; conversion tables are for leap years.
ian [Sat, 17 May 2014 22:03:44 +0000 (22:03 +0000)]
MFC 264694: Fix a comment typo; conversion tables are for leap years.

git-svn-id: svn://svn.freebsd.org/base/stable/10@266368 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC 264428:
ian [Sat, 17 May 2014 22:02:26 +0000 (22:02 +0000)]
MFC 264428:

  Improve the i.MX53 / Digi DTS:

  * Fix the IPU address.
  * Fix the PATA definition.
  * Add another I2C.
  * Add more UARTs.
  * Add SATA.

git-svn-id: svn://svn.freebsd.org/base/stable/10@266367 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC 264389: Fix the style of ata_interrupt_locked().
ian [Sat, 17 May 2014 22:01:17 +0000 (22:01 +0000)]
MFC 264389: Fix the style of ata_interrupt_locked().

git-svn-id: svn://svn.freebsd.org/base/stable/10@266366 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC 264251: Updates to i.MX53:
ian [Sat, 17 May 2014 22:00:10 +0000 (22:00 +0000)]
MFC 264251:  Updates to i.MX53:

  * Define support for the SDHCI driver, although it doesn't work yet
  * Fix the memory mappings for IPU

git-svn-id: svn://svn.freebsd.org/base/stable/10@266365 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC 264230: Move dts files accidentally placed in arm dir to powerpc dir.
ian [Sat, 17 May 2014 21:55:00 +0000 (21:55 +0000)]
MFC 264230: Move dts files accidentally placed in arm dir to powerpc dir.

git-svn-id: svn://svn.freebsd.org/base/stable/10@266364 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC 264219: Move sys/arm/econa to sys/arm/cavium/cns11xx.
ian [Sat, 17 May 2014 21:53:34 +0000 (21:53 +0000)]
MFC 264219:  Move sys/arm/econa to sys/arm/cavium/cns11xx.

git-svn-id: svn://svn.freebsd.org/base/stable/10@266363 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC 264203, 264204, 264206, 264218:
ian [Sat, 17 May 2014 21:46:25 +0000 (21:46 +0000)]
MFC 264203, 264204, 264206, 264218:

  Tell VM we now have ARM platforms with physically discontiguous memory.

  Define the full 1024M of ram on the imx51 and imx53 boards.

  Use a more professional uart device description.

git-svn-id: svn://svn.freebsd.org/base/stable/10@266362 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC 264190:
ian [Sat, 17 May 2014 21:35:26 +0000 (21:35 +0000)]
MFC 264190:

  Mark __fixdfdi/__aeabi_d2lz with COMPILER_RT_ABI so it uses the correct
  calling convention for __aeabi_* functions.

git-svn-id: svn://svn.freebsd.org/base/stable/10@266361 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC 264180, 264181, 264182:
ian [Sat, 17 May 2014 21:31:58 +0000 (21:31 +0000)]
MFC 264180, 264181, 264182:

  Follow files.imx51 and add vt support for imx53.

  Add fsl,imx53 compatible string.

  Need to include machine/fdt.h in vt_early_fb.c

git-svn-id: svn://svn.freebsd.org/base/stable/10@266360 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC 264160: Remove code under PMAP_CACHE_VIVT, not compiled on armv6.
ian [Sat, 17 May 2014 21:28:49 +0000 (21:28 +0000)]
MFC 264160:  Remove code under PMAP_CACHE_VIVT, not compiled on armv6.

git-svn-id: svn://svn.freebsd.org/base/stable/10@266359 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC 264150: Exynos: Correct the end address of the video frame buffer.
ian [Sat, 17 May 2014 21:26:33 +0000 (21:26 +0000)]
MFC 264150:  Exynos: Correct the end address of the video frame buffer.

git-svn-id: svn://svn.freebsd.org/base/stable/10@266358 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC 264183: Add a couple more required TLB flushes.
ian [Sat, 17 May 2014 21:23:46 +0000 (21:23 +0000)]
MFC 264183:   Add a couple more required TLB flushes.

git-svn-id: svn://svn.freebsd.org/base/stable/10@266357 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC 264137: Switch wandboards over to the common IMX6 kernel config, which
ian [Sat, 17 May 2014 21:19:44 +0000 (21:19 +0000)]
MFC 264137:  Switch wandboards over to the common IMX6 kernel config, which
has SMP enabled.  Also switch IMX6 to use SCHED_ULE.

git-svn-id: svn://svn.freebsd.org/base/stable/10@266356 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC 264137: Switch wandboards over to the common IMX6 kernel config, which
ian [Sat, 17 May 2014 21:18:08 +0000 (21:18 +0000)]
MFC 264137:  Switch wandboards over to the common IMX6 kernel config, which
has SMP enabled.  Also switch IMX6 to use SCHED_ULE.

git-svn-id: svn://svn.freebsd.org/base/stable/10@266355 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC 264128, 264129, 264130, 264135,
ian [Sat, 17 May 2014 21:07:54 +0000 (21:07 +0000)]
MFC 264128, 264129, 264130, 264135,

  Fix TTB set operation for armv7. Perform sychronization (by "isb" barrier)
  after TTB is set.

  Fix TLB maintenance issues for armv6 and armv7.

    - Add cpu_cpwait to comply with the convention.
    - Add missing TLB invalidations, especially in pmap_kenter & pmap_kremove
      with distinguishing between D and ID pages.
    - Modify pmap init/bootstrap invalidations to ID, just to be safe.
    - Fix TLB-inv and PTE_SYNC ordering.

  Allocate per-cpu resources for doing pmap_zero_page() and pmap_copy_page().
  This is performance enhancement rather than bugfix.

  We don't support any ARM systems with an ISA bus and don't need a freelist
  of memory to support ISA addressing limitations.

git-svn-id: svn://svn.freebsd.org/base/stable/10@266353 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC 264052, 264057, 264065, 264094, 264103, 264120
ian [Sat, 17 May 2014 20:52:10 +0000 (20:52 +0000)]
MFC 264052, 264057, 264065, 264094, 264103, 264120

  Actually save the mpcore clock frequency retrieved from fdt data.

  imx6..
  - Don't call sdhci_init_slot() until after handling the FDT properties
    related to detecting card presence.
  - Flag several sysctl variables as tunables.
  - Rework the cpu frequency management code for imx6 to add "operating
    points" and min/max frequency controls.

  generic timer...
  - Setup both secure and non-secure timer IRQs.
    We don't know our ARM security state, so one of them will operate.
  - Don't set frequency, since it's unpossible in non-secure state.
    Only rely on DTS clock-frequency value or get clock from timer.

git-svn-id: svn://svn.freebsd.org/base/stable/10@266352 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC 264054, 264056
ian [Sat, 17 May 2014 20:22:22 +0000 (20:22 +0000)]
MFC 264054, 264056

  Switch imx6 to using the mpcore per-cpu event timers, but continue to use
  the GPT timer, which is fixed-frequency, as a timecounter.

  Change NO_EVENTTIMERS from an arm-specific to an MI option, so that it can
  be used in MI code.

git-svn-id: svn://svn.freebsd.org/base/stable/10@266348 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC 264019, 264041, 264048, 264049, 264050, 264051
ian [Sat, 17 May 2014 20:10:12 +0000 (20:10 +0000)]
MFC 264019, 264041, 264048, 264049, 264050, 264051

  Add support for event timers whose clock frequency can change while running.

  Apparently all ARM configs build kern_et.c, but only a few of them also
  build kern_clocksource.c, un-break the build by not referencing functions in
  kern_clocksource if NO_EVENTTIMERS is defined.

  Add variable-frequency support to the arm mpcore eventtimer driver.

  mpcore_timer: Disable the timer and clear any pending bit, then setup the
  new counter register values, then restart the timer.  Also re-nest the parens
  properly for casting the result of converting time and frequency to a count.

git-svn-id: svn://svn.freebsd.org/base/stable/10@266347 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoDocument r266165, power management bug with Intel Turbo Boost.
gjb [Sat, 17 May 2014 19:45:40 +0000 (19:45 +0000)]
Document r266165, power management bug with Intel Turbo Boost.

Sponsored by: The FreeBSD Foundation

git-svn-id: svn://svn.freebsd.org/base/stable/10@266343 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC 263910, 263913, 263914, 263933, 263934, 263935, 263936, 263981, 263982,
ian [Sat, 17 May 2014 19:37:04 +0000 (19:37 +0000)]
MFC 263910, 263913, 263914, 263933, 263934, 263935, 263936, 263981, 263982,

  Add more flags for the fpexc register from the ARM1176JZF-S Manual

  Initialise fpscr to a sane value when we create the pcb. This sets NaNs to
  be the default NaN and for denormalised numbers to be flushed to zero.

  VFP fixes/cleanups for ARM11:
   * Save the required VFP registers on context switch. If the exception bit
     is set we need to save and restore the FPINST register, and if the fp2v
     bit is also set we need to save and restore FPINST2.
   * Move saving and restoring the floating point control registers to C.
   * Clear the fpexc exception and fp2v flags on a floating-point exception.
   * Signal a SIGFPE if the fpexc exception flag is set on an undefined
     instruction. This is how the ARM core signals to software there is a
     floating-point exception.

  Add Cortex-A15 cpu id revisions.

  Exynos/Arndale...
  - Merge SoC-common parts
  - Enable iicbus device
  - Directly call kmem_alloc_contig to allocate framebuffer memory
    and pass VM_MEMATTR_UNCACHEABLE (no-cache, no-buffer).
    This fixes screen refreshing problem when data is updated too slowly.
  - Add support for keyboard used in Samsung Chromebook (ARM machine)
    Support covers device drivers for:
    - Interrupt Combiner
    - gpio/pad, External Interrupts Controller (pad)
    - I2C Interface
    - Chrome Embedded Controller
    - Chrome Keyboard
  - Use new gpio dev class in EHCI driver
  - Expand device tree information
  - Release i2c bus on detach.

git-svn-id: svn://svn.freebsd.org/base/stable/10@266341 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC r265013
loos [Sat, 17 May 2014 19:16:45 +0000 (19:16 +0000)]
MFC r265013

Revert r258678.  Make the led gpio-specifier match again the #gpio-cells
settings from the GPIO controller, which i had broken in r258678.  Restore
the active-low flag.

git-svn-id: svn://svn.freebsd.org/base/stable/10@266340 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC 259641,259863,259924,259937,259961,259978,260380,260383,260410,260466,
jhb [Sat, 17 May 2014 19:11:08 +0000 (19:11 +0000)]
MFC 259641,259863,259924,259937,259961,259978,260380,260383,260410,260466,
260531,260532,260550,260619,261170,261453,261621,263280,263290,264516:
Add support for local APIC hardware-assist.
- Restructure vlapic access and register handling to support hardware-assist
  for the local APIC.
- Use the 'Virtual Interrupt Delivery' and 'Posted Interrupt Processing'
  feature of Intel VT-x if supported by hardware.
- Add an API to rendezvous all active vcpus in a virtual machine and use
  it to support level triggered interrupts with VT-x 'Virtual Interrupt
  Delivery'.
- Use a cheaper IPI handler than IPI_AST for nested page table shootdowns
  and avoid doing unnecessary nested TLB invalidations.

Reviewed by: neel

git-svn-id: svn://svn.freebsd.org/base/stable/10@266339 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoAdds the ADC driver for TI AM3xxx SoC family.
loos [Sat, 17 May 2014 19:06:46 +0000 (19:06 +0000)]
Adds the ADC driver for TI AM3xxx SoC family.

The ADC has a 12bit resolution and its raw output can be read via sysctl(8)
interface.

The driver allows the setup of ADC clock, samples average and open delay
(the number of clock cycles to wait before start the conversion).

The TSC_ADC module is set in the general purpose mode (no touchscreen
support).

Tested on Beaglebone-black.

Written based on AM335x TRM.

git-svn-id: svn://svn.freebsd.org/base/stable/10@266338 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC 263631, 263637, 263664, 263676, 263679, 263698, 263711,
ian [Sat, 17 May 2014 18:53:36 +0000 (18:53 +0000)]
MFC 263631, 263637, 263664, 263676, 263679, 263698, 263711,

  Implement __flt_rounds for ARMv6 hard-float. The fpscr register stores the
  current rounding mode used by the VFP unit.

  Simplify how we build MACHINE_ARCH. There are 3 options that may be set
  however only arm, armeb, armv6, and soon armv6hf will be used.

  Add the llvm/clang patch for r263619.

  Reorder the pmap macros so "ARM_MMU_V6 + ARM_MMU_V7" is first. As they are
  identical this allows us to build for both v6 and v7 together.

  Add code for enabling second CPU core for A20 SoC.
  Enable SMP on Cubieboard2.

  Switch to freebsd.org emal address in copyright.

git-svn-id: svn://svn.freebsd.org/base/stable/10@266337 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC 263250, 263251, 263424, 263425, 263426, 263427, 263430, 263431
ian [Sat, 17 May 2014 17:54:38 +0000 (17:54 +0000)]
MFC 263250, 263251, 263424, 263425, 263426, 263427, 263430, 263431

  Use the same cache terminology as the ARM docs in comments. No
  functional changes.

  Use armv7 TLB flush code, not arm11, for cortex-a processors.

  Exynos/ Arndale...
  - Disable debugging by default.
  - Add display-related and clk devices to the tree
  - Prevent resources intersection with EHCI driver
  - Add display-related and clk devices to the tree
  - Prevent resources intersection with EHCI driver
  - Add driver for Display Controller.
  - Add support for Samsung Chromebook (ARM Cortex A15 machine).
  - Rename mct and ehci drivers files to match common naming.

git-svn-id: svn://svn.freebsd.org/base/stable/10@266332 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC 263301
ian [Sat, 17 May 2014 17:34:37 +0000 (17:34 +0000)]
MFC 263301

  In kernel config files, it is supposed to be 'options<space><tab>' not
  'options<tab><tab>', per long standing (but recently not so strictly
  enforced) convention.

git-svn-id: svn://svn.freebsd.org/base/stable/10@266331 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC 261357, 261358, 261421:
ian [Sat, 17 May 2014 17:18:35 +0000 (17:18 +0000)]
MFC 261357, 261358, 261421:

  Enable SCHED_ULE for ppc book-e.

  Add driver for the ADT7460/ADT7467 fan controller found in
  later PowerBooks and iBooks.

git-svn-id: svn://svn.freebsd.org/base/stable/10@266330 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC 263246: Align all comments in config files on same column.
ian [Sat, 17 May 2014 16:57:17 +0000 (16:57 +0000)]
MFC 263246:  Align all comments in config files on same column.

git-svn-id: svn://svn.freebsd.org/base/stable/10@266329 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC 263245: Make all the comments '# ' and align to same column.
ian [Sat, 17 May 2014 16:46:15 +0000 (16:46 +0000)]
MFC 263245:  Make all the comments '# ' and align to same column.

git-svn-id: svn://svn.freebsd.org/base/stable/10@266328 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC r265850
alc [Sat, 17 May 2014 14:35:18 +0000 (14:35 +0000)]
MFC r265850
  About 9% of the pmap_protect() calls being performed by
  vm_map_copy_entry() are unnecessary.
  Eliminate the unnecessary calls.

git-svn-id: svn://svn.freebsd.org/base/stable/10@266315 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC 262989, 263210, 263230, 263231, 263239, 263242, 263243,
ian [Sat, 17 May 2014 14:22:37 +0000 (14:22 +0000)]
MFC 262989, 263210, 263230, 263231, 263239, 263242, 263243,

  Export _libc_arm_fpu_present as a private symbol to be used by other
  system libraries, for example libm.

  On armv6 access both the softfloat and, when available, the vfp to get and
  set the floating-point environment.

  Build fenv-vfp.c with the softfp float abi. Without this gcc generates an
  incorrect assembly file that doesn't allow for vfp instructions.

  Only build the vfp/softfp switching code on armv6 as we don't support vfp
  on anything earlier than this. This should fix the armeb and arm builds
  when using gcc.

  Add an optimised version of the float and double helper functions.

git-svn-id: svn://svn.freebsd.org/base/stable/10@266314 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC 263199, 263207
ian [Sat, 17 May 2014 14:03:46 +0000 (14:03 +0000)]
MFC 263199, 263207

  Fix error mesasge in dtc.

  Add tmpfs, mbr, and bsdlabel options back to wandboard kernel config.

git-svn-id: svn://svn.freebsd.org/base/stable/10@266313 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC 263036, 263059: delete advertising clause in licenses, renumber.
ian [Sat, 17 May 2014 13:59:11 +0000 (13:59 +0000)]
MFC 263036, 263059: delete advertising clause in licenses, renumber.

git-svn-id: svn://svn.freebsd.org/base/stable/10@266312 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC 262952, 262958, 262966, 262979, 262980, 262986, 262987, 262995, 262997,
ian [Sat, 17 May 2014 13:53:38 +0000 (13:53 +0000)]
MFC 262952, 262958, 262966, 262979, 262980, 262986, 262987, 262995, 262997,
    263030, 263033, 263034, 263056, 263057,

  Remove all the redundant external declarations of exception vectors and
  runtime setting of the pointers that's scattered around various places.

  Remove all traces of support for ARM chips prior to the arm9 series.

  Make the default exception handler vectors point to where I thought they
  were already pointing: the default handlers (not a panic that says there
  is no default handler).

  Eliminate irq_dispatch.S.  Move the data items it contained into
  arm/intr.c and the functionality it provided into arm/exception.S.

  Move the exception vector table (so-called "page0" data) into exception.S
  and eliminate vectors.S.

  Change the way the asm GET_CURTHREAD_PTR() macro is defined so that code
  using it doesn't have to have an "AST_LOCALS" macro somewhere in the file.

  Arrange for arm fork_trampoline() to return to userland via the standard
  swi_exit code in exception.S instead of having its own inline expansion
  of the DO_AST and PULLFRAME macros.

  Now that the PUSHFRAME and PULLFRAME macros are used only in the swi
  entry/exit code, they don't need to be macros.  Except that didn't work
  and the whole change was reverted.

  Remove some unnecessary indirection and jump right to the handler functions.

  Use panic rather than printf to "handle" an arm26 address exception
  (should never happen on arm32).

  Remove the unreferenced DATA() macro.

  Remove #include <machine/asmacros.h> from files that don't need it.

git-svn-id: svn://svn.freebsd.org/base/stable/10@266311 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC r266053:
dim [Sat, 17 May 2014 12:47:11 +0000 (12:47 +0000)]
MFC r266053:

Use the new -d option that was added to tblgen between llvm/clang 3.3
and 3.4 to generate dependency files for the '.inc.h' files generated
from .td files, and .sinclude those dependency files in clang.build.mk.

This will make future incremental builds of lib/clang and usr.bin/clang
work correctly, whenever any of the .td files get modified.

Note that this will not fix any problems with incremental builds from
*before* this revision, since there will not yet be any generated
dependency files.  A quick workaround is to run the following:

  find /usr/obj -type f -name '*.inc.h' | xargs rm

and then a regular incremental buildworld (e.g. with -DNO_CLEAN).

git-svn-id: svn://svn.freebsd.org/base/stable/10@266309 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC r265847:
kib [Sat, 17 May 2014 11:43:14 +0000 (11:43 +0000)]
MFC r265847:
Fix sem_unlink(3) to properly invalidate the semaphores name cache.

PR: standards/189353

git-svn-id: svn://svn.freebsd.org/base/stable/10@266306 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC r265845:
kib [Sat, 17 May 2014 11:38:26 +0000 (11:38 +0000)]
MFC r265845:
Style.

git-svn-id: svn://svn.freebsd.org/base/stable/10@266305 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC r265843:
kib [Sat, 17 May 2014 11:36:31 +0000 (11:36 +0000)]
MFC r265843:
For the upgrade case in vm_fault_copy_entry(), when the entry does not
need COW and is writeable, do not create a new backing object for the entry.

MFC r265887:
Fix locking.

git-svn-id: svn://svn.freebsd.org/base/stable/10@266304 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC r265825:
kib [Sat, 17 May 2014 11:29:32 +0000 (11:29 +0000)]
MFC r265825:
When printing the map with the ddb 'show procvm' command, do not dump
page queues for the backing objects.

git-svn-id: svn://svn.freebsd.org/base/stable/10@266302 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC r265824:
kib [Sat, 17 May 2014 11:24:29 +0000 (11:24 +0000)]
MFC r265824:
Print the entry address in addition to the object.

git-svn-id: svn://svn.freebsd.org/base/stable/10@266299 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC r264841: Update zfsboot to coincide with MFC of r264840
dteske [Sat, 17 May 2014 03:59:01 +0000 (03:59 +0000)]
MFC r264841: Update zfsboot to coincide with MFC of r264840
adding GEOM support.

git-svn-id: svn://svn.freebsd.org/base/stable/10@266294 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC r264840: Implement GEOM based media device classification.
dteske [Sat, 17 May 2014 03:28:43 +0000 (03:28 +0000)]
MFC r264840: Implement GEOM based media device classification.

git-svn-id: svn://svn.freebsd.org/base/stable/10@266290 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC r265267:
bdrewery [Sat, 17 May 2014 02:45:59 +0000 (02:45 +0000)]
MFC r265267:

  Fix width/alignment of JID column. Make it support up to the maximum 7-wide
  JIDs. On a system using jails for common tasks the JID can quickly increase.

git-svn-id: svn://svn.freebsd.org/base/stable/10@266282 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC r265249,r265250,r265251:
bdrewery [Sat, 17 May 2014 02:39:20 +0000 (02:39 +0000)]
MFC r265249,r265250,r265251:

    - Add -J command/flag to filter by jail name/jid. This will automatically
      display the JID as well (the -j command/flag).
    - Add a hint for 'u' and 'J' command that '+' displays all.
    - Add J command to help.

git-svn-id: svn://svn.freebsd.org/base/stable/10@266280 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC r265229,r265239:
bdrewery [Sat, 17 May 2014 02:32:47 +0000 (02:32 +0000)]
MFC r265229,r265239:

    Add -J to filter by matching jail IDs and names.

git-svn-id: svn://svn.freebsd.org/base/stable/10@266279 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC 257774, 256760, 262916, 262905, 262918, 262919, 262920, 262921, 262924,
ian [Sat, 17 May 2014 00:53:12 +0000 (00:53 +0000)]
MFC 257774, 256760, 262916, 262905, 262918, 262919, 262920, 262921, 262924,
    262925, 262929, 262932, 262935, 262940, 262941, 262942, 262948, 262949,
    262950

  Strip arm/conf/DEFAULTS down to just items that are mandatory for running
  the architecture.

  Move all the files named foo/common.c to foo/foo_common.c

  Initial cut for DTS on the hl201 board.

  Add commented out dts for sam9260ek as well as early printf support.

  Make clock optional on uart nodes, then back it out ("I don't know what I
  was thinking, but it is lame.")

  Set the baud rate if it isn't 0

  Make at91_soc_id() public.

  Properly round at91 resource on unmapping.

  Move AT91 AIC related stuff to own file.

  Fix another bug in multicast filtering.  i.MX uses 6 bits from MSB in
  LE CRC32 for the hash value, not the lowest 6 bits in BE CRC32.

  Follow r262916 with one more config file that references a renamed common.c

  Remove bogus AT91 define that causes compile errors.  Most of the defines
  for SAM9X are going away soonish anyway (once FDT works), but until
  then...

  Remove all dregs of a per-thread undefined-exception-mode stack.

  Rework the VFP code that handles demand-based save and restore of state.

  Always call vfp_discard() on thread death.

  When a thread begins life it doesn't own the VFP hardware state on any cpu.

  Make undefined exception entry MP-safe.

git-svn-id: svn://svn.freebsd.org/base/stable/10@266277 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC 258211, 257775, 258096,
ian [Fri, 16 May 2014 23:49:40 +0000 (23:49 +0000)]
MFC 258211, 257775, 258096,

  Add mbox and pruss drivers to ti build.

  Use common bus_space-v6 instead of local copies.

git-svn-id: svn://svn.freebsd.org/base/stable/10@266275 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC 262695, 262708, 262709, 262710, 262711, 262728, 262870, 262877, 262880,
ian [Fri, 16 May 2014 23:27:18 +0000 (23:27 +0000)]
MFC 262695, 262708, 262709, 262710, 262711, 262728, 262870, 262877, 262880,
    262885, 262891, 262903,

  imx6: Add a tunable to set the number of active cores, enable SMP by default.

  ffec: Fix multicast filtering.

  Allwinner a10/a20...
  - Add gpio and clock bits for A10/A20's EMAC ethernet controller driver
    - EMAC gpio configuration
    - EMAC clock activation
  - Add Static Random Access Memory controller driver for A10/A20.
      A10/A20's SRAM is used by devices, such as CPU, EMAC,
      for extra fast memory or as cache.
  - Add EMAC 10/100 Ethernet controller driver for A10/A20.
      It is available mostly in A10 devices like Hackberry, Marsboard,
      Mele A1000, A2000, A100 HTPC, cubieboard1 and A20 device
      like cubieboard2.
      TX performance can be improved using both channels 0 and 1.
      RX performance is poor and needs improvement with the assistance of
      external DMA controller in case there
  - Add EMAC and SRAM controller entries to FDT.
  - Add EMAC device to kernel config files and enable EMAC, SRAM drivers.

  OMAP: When calculating the MPU freq, make sure not to overflow.

  Vybrid:
  - Add driver for Port control and interrupts (PORT).
  - Export panel info to DTS
  - Reset all the layers before setup first one
  - Enable display

  nandfs: Slight code reordering to make error branch last.

  Add option TMPFS to arm/conf/DEFAULTS, remove it from the few configs
  that have it individually.  Concensus on freebsd-arm@ is that it should
  be included in all ARM kernels.

  Fix the arm sys_sigreturn(): its argument is a struct ucontext, not a
  struct sigframe containing the struct ucontext.

git-svn-id: svn://svn.freebsd.org/base/stable/10@266274 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC 264304: Really only allow IMGACT_BINMISC for amd64/i386 builds.
ian [Fri, 16 May 2014 22:55:01 +0000 (22:55 +0000)]
MFC 264304: Really only allow IMGACT_BINMISC for amd64/i386 builds.

git-svn-id: svn://svn.freebsd.org/base/stable/10@266273 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC r264269, r264282, r264280, r264291, r264276, r264314
sbruno [Fri, 16 May 2014 21:56:33 +0000 (21:56 +0000)]
MFC r264269, r264282, r264280, r264291, r264276, r264314

Merge sson's binmiscctl and image activator features to stable/10

Submitted by: sson@freebsd.org

git-svn-id: svn://svn.freebsd.org/base/stable/10@266272 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC r265779:
hselasky [Fri, 16 May 2014 16:11:14 +0000 (16:11 +0000)]
MFC r265779:
Fix for NULL pointer.

git-svn-id: svn://svn.freebsd.org/base/stable/10@266257 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC: r265585
brueffer [Fri, 16 May 2014 16:06:31 +0000 (16:06 +0000)]
MFC: r265585

Generate hardware notes for mrsas(4).

git-svn-id: svn://svn.freebsd.org/base/stable/10@266255 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC: r265583, r265716
brueffer [Fri, 16 May 2014 16:03:26 +0000 (16:03 +0000)]
MFC: r265583, r265716

First cleanup pass: new sentence -> new line, mdoc, typos and style.

Fix two more typos. (1)

Submitted by: Trond Endrestol (1)

git-svn-id: svn://svn.freebsd.org/base/stable/10@266253 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC 262614, 262625, 262626, 262627, 262682, 262714, 262725, 262736
ian [Fri, 16 May 2014 15:56:34 +0000 (15:56 +0000)]
MFC 262614, 262625, 262626, 262627, 262682, 262714, 262725, 262736

  Integrate device-tree upstream files into the build process:
  (1) Invoke cpp to bring in files via #include (although the old
      /include/ stuff is supported still).
  (2) bring in files from either vendor tree or freebsd-custom files
      when building.
  (3) move all dts* files from sys/boot/fdt/dts to
      sys/boot/fdt/dts/${MACHINE} as appropriate.
  (4) encode all the magic to do the build in sys/tools/fdt/make_dtb.sh
      so that the different places in the tree use the exact same logic.
  (5) switch back to gpl dtc by default. the bsdl one in the tree has
      significant issues not easily addressed by those unfamiliar with
      the code.

  Only try to build the static dtb when we're building a static dtb.

  Use proper include path for dtc as well as cpp.

  Fix syntax errors (missing ; other minor glitches) in existing dts files.

git-svn-id: svn://svn.freebsd.org/base/stable/10@266251 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC: r265238, r265240
brueffer [Fri, 16 May 2014 15:48:45 +0000 (15:48 +0000)]
MFC: r265238, r265240

Properly free resources in case of error.

CID: 1007032
Found with: Coverity Prevent(tm)

git-svn-id: svn://svn.freebsd.org/base/stable/10@266243 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC 252439: Fix the led 'gpios' definition to match the documented binding
ian [Fri, 16 May 2014 15:39:11 +0000 (15:39 +0000)]
MFC 252439: Fix the led 'gpios' definition to match the documented binding

git-svn-id: svn://svn.freebsd.org/base/stable/10@266240 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC 258547, 259122
ian [Fri, 16 May 2014 15:34:23 +0000 (15:34 +0000)]
MFC 258547, 259122

  Add clock frequency for rk3188 watchdog.
  Replace "clocks" to "clock-frequency".
  Add gpio config for usb1 in dts.

git-svn-id: svn://svn.freebsd.org/base/stable/10@266239 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC r260522, r260523, r261439, r261440, r261586, r264504, r264769, r265193,
loos [Fri, 16 May 2014 14:28:55 +0000 (14:28 +0000)]
MFC r260522, r260523, r261439, r261440, r261586, r264504, r264769, r265193,
    r265194, r265197

r260522:
Add the manual page for geom_uncompress(4).

r260523:
Build the geom_uncompress(4) module by default.

Fix geom_uncompress(4) module loading.  Don't link zlib.c (which is a module
itself) directly.

r261439:
Remove some unnecessary code.  The offsets read from the first block are
overwritten a few lines bellow.

r261440:
Fix a logic error.  Because of this inflateReset() wasn't being called and
the output buffer wasn't being cleared between the inflate() calls,
producing zeroed output after the first inflate() call.

This fixes the read of mkuzip(8) images with geom_uncompress(4).

r261586:
Fix the build with DEBUG enabled.  Where possible, fix style(9) issues.

r264504:
Make sure not to do I/O for more than MAXPHYS bytes. Doing so can cause
problems in our providers, such as a KASSERT in md(4). We can initiate
I/O for more than MAXPHYS bytes if we've been given a BIO for MAXPHYS
bytes, the blocks from which we're reading couldn't be compressed and
we had compression in preceeding blocks resulting in misalignment of
the blocks we're trying to read relative to the sector. We're forced to
round up the I/O length to make it an multiple of the sector size.

When we detect the condition, we'll reduce the block count and perform
a "short" read. In g_uzip_done() we need to consider the original I/O
length and stop early if we're about to deflate a block that we didn't
read. By using bio_completed in the cloned BIO and not bio_length to
check for this, we automatically and gracefully handle short reads that
our providers may be doing on top of the short reads we may initiate
ourselves.

r264769:
Keep geom_uncompress(4) in line with geom_uzip(4), bring in the r264504 fix.

Make sure not to start I/O bigger than MAXPHYS bytes.

r265193:
Some style and whitespace fixes.  Reduce the difference between geom_uzip(4)
and geom_uncompress(4).  Now, they produce an almost clean diff(1) output.

Remove a duplicated variable from g_uncompress.c and an unnecessary header
from g_uzip.c.

r265194:
Actually the FEATURE() macro is defined on sys/sysctl.h.

r265197:
Fix a leak in g_uzip_taste().  After retrieve all the block offsets from
the uzip image, free the last data read.

git-svn-id: svn://svn.freebsd.org/base/stable/10@266220 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC r262591, r262592, r262593, r262597, r262598, r262599, r262600, r262601,
ian [Fri, 16 May 2014 12:43:45 +0000 (12:43 +0000)]
MFC r262591, r262592, r262593, r262597, r262598, r262599, r262600, r262601,
    r262606

  Initial import of Linux/Vendor DTS files for various embedded boards.

  Initial import of DTS files from Linux

  Correct initial import script

  New AT91 devices or fdt probe added to existing devices.  Some of these
  are just stubs for testing the new dts.
  - nand
  - SDRAMC
  - shdwc
  - tcb
  - usb host and gadget

git-svn-id: svn://svn.freebsd.org/base/stable/10@266217 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC r265943:
yongari [Fri, 16 May 2014 05:10:16 +0000 (05:10 +0000)]
MFC r265943:
  Disable TX IP/TCP/UDP checksum offloading for RTL8168C/RTL8168CP.
  Previously only TX IP checksum offloading was disabled but it's
  reported that TX checksum offloading for UDP datagrams with IP
  options also generates corrupted frames.  Reporter's controller is
  RTL8168CP but I guess RTL8168C also have the same issue since it
  shall share the same core.

git-svn-id: svn://svn.freebsd.org/base/stable/10@266212 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC r265942:
yongari [Fri, 16 May 2014 05:05:53 +0000 (05:05 +0000)]
MFC r265942:
  Fix checksum computation.  Previously it didn't include carry.

git-svn-id: svn://svn.freebsd.org/base/stable/10@266210 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC r262534, r262548, r262549, r262552, r262568, r262581, r262583, r262584,
ian [Fri, 16 May 2014 02:21:51 +0000 (02:21 +0000)]
MFC r262534, r262548, r262549, r262552, r262568, r262581, r262583, r262584,
    r262585, r262587, r262696, r262712

  Replace many pasted identical definitions of cpu_initclocks() with a common
  implementation in arm/machdep.c.

  aicasm: Don't complain about missing prototypes to ease bootstrap issues.

  Vybrid: Add driver for Inter-Integrated Circuit (I2C).

  imx6: Initialize the Low Power Mode bits to keep the ARM cores running
  during WFI.

  All our current ARM multi-core systems have all cores in one package with
  a shared L2 cache, reflect that in the common cpu_topo() routine.

  mpcore timer: Supply a DELAY() implementation via weak linkage, so that
  SoC-specific code can supply a better implementation.

  imx6: Add some rudimentary voltage control.

  Add an armv7 implementation of cpu_sleep().

  Add __used attribute so that the DELAY implementation doesn't get
  optimized away as unreferenced, causing linker errors when trying to
  resolve the weak reference to the missing function.

git-svn-id: svn://svn.freebsd.org/base/stable/10@266207 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC r257854 (discussed with alc@)
ian [Fri, 16 May 2014 01:30:30 +0000 (01:30 +0000)]
MFC r257854 (discussed with alc@)

  As of r257209, all architectures have defined
  VM_KMEM_SIZE_SCALE.  In other words, every architecture is now
  auto-sizing the kmem arena.  This revision changes kmeminit() so
  that the definition of VM_KMEM_SIZE_SCALE becomes mandatory and
  the definition of VM_KMEM_SIZE becomes optional.

  Replace or eliminate all existing definitions of VM_KMEM_SIZE.
  With auto-sizing enabled, VM_KMEM_SIZE effectively became an
  alternate spelling for VM_KMEM_SIZE_MIN on most architectures.
  Use VM_KMEM_SIZE_MIN for clarity.

git-svn-id: svn://svn.freebsd.org/base/stable/10@266204 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC r262409, r262411, r262413, r262420, r262426, r262427, r262440, r262456,
ian [Fri, 16 May 2014 00:14:50 +0000 (00:14 +0000)]
MFC r262409, r262411, r262413, r262420, r262426, r262427, r262440, r262456,
    r262482, r262483, r262531,

  Move the declaration for mpentry() into a header file instead of pasting
  it into a bunch of different .c files.

  If the L2 cache type is PIPT, pass a physical address for a flush.

  Actually set the proper bit to indicate TTB shared memory.

  Add a new cache maintenance function, idcache_inv_all, to the table, and
  implementations for each of the chips we support.

  Invalidate caches immediately upon entry to init_secondary().  Also set
  the Bufferable bit in the PDE entries of the secondary processor startup
  pagetables.

  Add the bits needed to run SMP on imx6.

  Invalidate the SCU cache tag ram on all 4 cores, not just 1-3.

  Minor tweaks to the imx GPT timer

  Vybrid enhancements...
  - Pin configuration is a complete iomux register now and includes
    drive strength, pull mode, mux mode, speed, etc.
  - Add i2c devices to the tree
  - Add IPG clock
  - Add support for Quartz Module.
  - Pin configuration is a complete iomux register now and includes
    drive strength, pull mode, mux mode, speed, etc.
  - Add i2c devices to the tree
  - Add IPG clock

git-svn-id: svn://svn.freebsd.org/base/stable/10@266203 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC r262394: Fix parsing multiple roots with whitespace between them.
ian [Thu, 15 May 2014 22:51:14 +0000 (22:51 +0000)]
MFC r262394:  Fix parsing multiple roots with whitespace between them.

git-svn-id: svn://svn.freebsd.org/base/stable/10@266202 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC r261982, r261987, r262123, r262244, r262278, r262280, r262353, r262354,
ian [Thu, 15 May 2014 22:50:06 +0000 (22:50 +0000)]
MFC r261982, r261987, r262123, r262244, r262278, r262280, r262353, r262354,
    r262355, r262419,

  Add Vybrid driver for Synchronous Audio Interface (SAI).

  Decrease SAI buffer size. Handle eDMA interrupt on running channel only.

  Give the physmem fdt helper routines static linkage since no global
  definition of them is provided anywhere.

  Add imx6 early printf support, wrapped in #if 0 because it's rarely needed.

  Add basic cpu frequency control and temperature monitoring to imx6_anatop.

  Add the FREEBSD_BOOT_LOADER option so that a loaded DTB passed in from
  ubldr will actually get used.

  Create a generic IMX6 kernel config, then fix it to have an ident line.

  Don't force imx6 bootverbose on anymore, it can be set from ubldr now.

git-svn-id: svn://svn.freebsd.org/base/stable/10@266201 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC r261938, r261939, r261940, r261944, r261945, r261946, r261947, r261956, r261957...
ian [Thu, 15 May 2014 22:35:04 +0000 (22:35 +0000)]
MFC r261938, r261939, r261940, r261944, r261945, r261946, r261947, r261956, r261957, r261983, r261094,
    r261955, r261958,

  Add a driver to provide access to imx6 on-chip one-time-programmble data.

  Make it possible to access the ocotp registers before the ocotp device
  is attached, by establishing a temporary mapping of the registers when
  necessary.

  It turns out Freescale cleverly made the ocotp device compatible across
  several different families of SoCs, so move it to the freescale directory
  and prefix everything with fsl rather than imx6.

  Convert the imx6 sdhci "R1B fix" from a busy-loop in the interrupt handler
  to a callout.

  Increase the wait time for acquiring the SD bus from 10 to 250ms.

  If no compatible cards were found after probing the SD bus, say so.

  Add timeout logic to sdhci, separate from the timeouts done by the hardware.

  After a timeout, reset the controller using SDHCI_RESET_CMD|SDHCI_RESET_DATA
  rather than SDHCI_RESET_ALL; the latter turns off clocks and power, removing
  any possibility of recovering from the error.

  Add a helper routine to depth-search the device tree for a node with a
  matching 'compatible' property.

git-svn-id: svn://svn.freebsd.org/base/stable/10@266200 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC r261917, r261918, r261919, r261920, r261921, r261922
ian [Thu, 15 May 2014 22:11:48 +0000 (22:11 +0000)]
MFC r261917, r261918, r261919, r261920, r261921, r261922

  Always clear L1 PTE descriptor when removing superpage on ARM

  Invalidate L1 PTE regardles of existance of the corresponding l2_bucket.

  Ensure proper TLB invalidation on superpage promotion and demotion on ARM

  Base pages within newly created superpage need to be invalidated so that
  new mapping is "visible" immediately after creation.

  Fix superpage promotion on ARM with respect to RO/RW and wired attributes

  Avoid redundant superpage promotion attempts on ARM

  Remove spurious assertion from pmap_extract_locked() on ARM

  Handle pmap_enter() on already promoted mappings for ARMv6/v7

git-svn-id: svn://svn.freebsd.org/base/stable/10@266199 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC r261803, r261808, r261814, r261815, r261816, r261817, r261818, r261826,
ian [Thu, 15 May 2014 22:03:24 +0000 (22:03 +0000)]
MFC r261803, r261808, r261814, r261815, r261816, r261817, r261818, r261826,
    r261848, r261855

  On armv6 and later, use the WriteNotRead bit of the fault status register
  to decide what protections are required by the faulting access.

  Use the right symbols for determining arm architecture.  Include the
  necessary header file which has the new FAULT_WNR symbol defined in it.

  Allow the kernel to be loaded at any 1MiB address. This requirement is
  because we use the 1MiB section maps as they only need a single pagetable.

  Add function for configuring Vybrid PLL4 (Audio) clock frequency output.

  imx6 changes ...

  - Fix the definition of the SDHCI_STATE_DAT and SDHCI_STATE_CMD fields,
    and add SDHCI_RETUNE_REQUEST.  None of these are actually used in the
    code yet.

  - Write translation code for the SDHCI_PRESENT_STATE register.
    Freescale moved some bits around in their version of the register,
    adjust things so that the sdhci code sees the standard layout.

  - Add standard non-removable and cd-gpios properties to the usdhc
    devices.  That generates references to gpio devices, so uncomment them
    even though there isn't a gpio driver to do anything with them yet.

  - Add handling of standard "non-removable" property, and also some
    workaround code so that if card detect is wired to a gpio pin, for now
    we just treat it the same as non-removable (because there isn't a gpio
    driver yet).

  - Enable both sdcard slots, but not the sdio-based wifi that we don't
    yet have a driver for.

  - Remove a couple obsolete function declarations.

git-svn-id: svn://svn.freebsd.org/base/stable/10@266198 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC r261786, r261789
ian [Thu, 15 May 2014 21:41:32 +0000 (21:41 +0000)]
MFC r261786, r261789

  Rework the EARLY_PRINTF mechanism.  Instead of defining a special eprintf()
  routine, now a platform can provide a pointer to an early_putc() routine
  which is used instead of cn_putc().  Control can be handed off from early
  printf support to standard console support by NULLing out the pointer
  during standard console init.

  Convert two while(1); statements into proper panics.

git-svn-id: svn://svn.freebsd.org/base/stable/10@266197 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC r261681, r261682, r261683, r261684, r261685, r261686, r261687, r261688,
ian [Thu, 15 May 2014 21:21:47 +0000 (21:21 +0000)]
MFC r261681, r261682, r261683, r261684, r261685, r261686, r261687, r261688,
    r261689, r261690, r261783, r261791, r261836, r261837, r261841,

  Add FDT matching code to AT91 device drivers.

  Better nomatch messages: include compat string.  Also, flag devices as
  disabled in the successful probe message, but leave what that means to
  the actual driver (no semantic changes).

  Fix Embest board name and id.

  Honor the disabled status by only grabbing resources and returning
  when running under FDT in the AT91 SPI driver.

git-svn-id: svn://svn.freebsd.org/base/stable/10@266196 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC r261643, r261646, r261648, r261649, r261651, r261656, r261657, r261663,
ian [Thu, 15 May 2014 20:58:23 +0000 (20:58 +0000)]
MFC r261643, r261646, r261648, r261649, r261651, r261656, r261657, r261663,
    r261676, r261677, r261698, r261778

  Consolidate code related to setting up physical memory configuration into
  a new physmem.c file.

  Replace compile-time constant KERNPHYSADDR with abp_physaddr

  Calculate the kernel's load address from the PC in the elf / gzip
  trampoline instead of relying on KERNPHYSADDR as a compile-time constant.

  It turns out a global variable is the only straightforward way to
  communicate the kernel's physical load address from where it's known in
  initarm() into cpu_mp_start() which is called from non-arm code and
  takes no parameters.

  Remove the now unused MMU_INIT macro.

  Use vm_paddr_t, not vm_offset_t, when dealing with physical addresses.

  No need to set physmem in each initarm() instance anymore, it's handled
  in common code now.

  Pass the pagetable used from locore.S to initarm to allow it to map data
  in as required.

  Fix the physmem exclude-region clipping logic for the edge-trim case.

  Add some extra debugging output when DEBUG is defined.

  Update legacy platforms to use new arm_physmem helper routines.

git-svn-id: svn://svn.freebsd.org/base/stable/10@266194 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC r256672
ian [Thu, 15 May 2014 19:28:52 +0000 (19:28 +0000)]
MFC r256672

If we avoid to use the page at addr 0, we should adjust the size to reflect it.

git-svn-id: svn://svn.freebsd.org/base/stable/10@266178 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC r257549, r261642
ian [Thu, 15 May 2014 19:09:31 +0000 (19:09 +0000)]
MFC r257549, r261642

Don't create a distinct free page pool for segregating allocations that are
accessed through the direct map unless the kernel configuration actually
includes a direct map.  Only a few configurations do, and for the rest the
unnecessary free page pool is a small pessimization.

Remove the ARM_USE_SMALL_ALLOC option and code related to it.

git-svn-id: svn://svn.freebsd.org/base/stable/10@266175 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC r261616, r261639
ian [Thu, 15 May 2014 18:38:19 +0000 (18:38 +0000)]
MFC r261616, r261639

  Remove FreeBSD 6 support from atmel usb controllers.

  Add Vybrid drivers for:
  - Enhanced Direct Memory Access Controller (eDMA)
  - Direct Memory Access Multiplexer (DMAMUX)

git-svn-id: svn://svn.freebsd.org/base/stable/10@266170 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC r259270
loos [Thu, 15 May 2014 18:18:53 +0000 (18:18 +0000)]
MFC r259270

After r266105 ofw_iicbuc.c will be built by default for any kernel which
includes options 'iicbus' and 'fdt'.  Remove the (now) unnecessary entries.

git-svn-id: svn://svn.freebsd.org/base/stable/10@266168 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC r265876:
cperciva [Thu, 15 May 2014 18:07:35 +0000 (18:07 +0000)]
MFC r265876:
  In cf_get_method, when we don't already know what clock speed the CPU is
  running at, guess the nearest value instead of looking for a value within
  25 MHz of the observed frequency.

  Prior to this change, if a system booted with Intel Turbo Boost enabled,
  the dev.cpu.0.freq sysctl is nonfunctional, since the ACPI-reported
  frequency for Turbo Boost states does not match the actual clock frequency
  (and thus no levels are within 25 MHz of the observed frequency) and the
  current performance level is read before a new level is set.

Relnotes: Bug fix in power management on CPUs with Intel Turbo Boost

git-svn-id: svn://svn.freebsd.org/base/stable/10@266165 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC r256871, r259034, r266010
loos [Thu, 15 May 2014 18:05:51 +0000 (18:05 +0000)]
MFC r256871, r259034, r266010

r256871:
Implement watchdog function and register it with watchdog list.

r259034:
Make the sysctl node read-only.

r266010:
Remove extra newlines.
No functional changes.

git-svn-id: svn://svn.freebsd.org/base/stable/10@266164 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC r261570, r261572
ian [Thu, 15 May 2014 17:53:42 +0000 (17:53 +0000)]
MFC r261570, r261572

  Revert r260440 (add USB_HOST_ALIGN to all configs, it's only needed for
  platforms with a 64-byte cacheline size).

  Add option USB_HOST_ALIGN=64 for all SoCs that have 64 byte cache lines.

git-svn-id: svn://svn.freebsd.org/base/stable/10@266162 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC r261423, r261424, r261516, r261513, r261562, r261563, r261564, r261565,
ian [Thu, 15 May 2014 17:30:16 +0000 (17:30 +0000)]
MFC r261423, r261424, r261516, r261513, r261562, r261563, r261564, r261565,
    r261596, r261606

  Add the imx sdhci controller.

  Move Open Firmware device root on PowerPC, ARM, and MIPS systems to
  a sub-node of nexus (ofwbus) rather than direct attach under nexus. This
  fixes FDT on x86 and will make coexistence with ACPI on ARM systems easier.
  SPARC is unchanged.

  Add the missing ')' at end of sentence.  Reword it to use a more common idiom.

  Pass the kernel physical address to initarm through the boot param struct.

  Make functions only used in vfp.c static, and remove vfp_enable.

  Fix __syscall on armeb EABI. As it returns a 64-bit value it needs to
  place 32-bit data in r1, not r0. 64-bit data is already packed correctly.

  Use abp_physaddr for the physical address over KERNPHYSADDR. This helps us
  remove the need to load the kernel at a fixed address.

  Remove references to PHYSADDR where it's used only in debugging output.

  Dynamically generate the page table. This will allow us to detect the
  physical address we are loaded at to change the mapping.

git-svn-id: svn://svn.freebsd.org/base/stable/10@266160 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC r261414, r261415, r261417, r261418, r261419
ian [Thu, 15 May 2014 16:59:47 +0000 (16:59 +0000)]
MFC r261414, r261415, r261417, r261418, r261419

  Don't call device_set_ivars() for the mmchs

  Change the way pcpu and curthread are stored per-core

  Invalidate cachelines for bounce pages on PREREAD too, there may still be
  stale entries from a previous transfer.

  Only use the CPU ID register if SMP is defined. Some non-MPCore armv6 cpu,
  such as the one found in the RPi, don't have it, and just hang when we try
  to access it.

git-svn-id: svn://svn.freebsd.org/base/stable/10@266159 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC r261411, r261413, r261416:
ian [Thu, 15 May 2014 16:23:24 +0000 (16:23 +0000)]
MFC r261411, r261413, r261416:

  Add support for Colibri VF50 Evaluation Board.

  Add driver for Display Control Unit (DCU4).

  Add prototype for tcon_bypass() used by dcu4.
  Add register definition.

git-svn-id: svn://svn.freebsd.org/base/stable/10@266155 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC r261410
ian [Thu, 15 May 2014 16:11:06 +0000 (16:11 +0000)]
MFC r261410

  Follow r261352 by updating all drivers which are children of simplebus
  to check the status property in their probe routines.

git-svn-id: svn://svn.freebsd.org/base/stable/10@266152 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC r259125, r264019, r264083, r264153, r264197
loos [Thu, 15 May 2014 15:47:52 +0000 (15:47 +0000)]
MFC r259125, r264019, r264083, r264153, r264197

r259125:
Fix a few typos on the scm (control module) pin mux definitions.

r264019:
Fix some of the style(9) problems on ti_gpio.

Remove redundant code and declarations.

r264083:
Move the GPIO bank initialization to a new function to make easier to detect
errors.

Reset the GPIO module during the initialization.  This is guaranteed to be
the same as a hardware reset.  Tested on AM335x (BBB) and checked against
the omap3 and omap4 TRM.

Do a better job freeing resources when there are errors and on
ti_gpio_detach().

r264153:
- Fix the setup of interrupts for banks 2 and 3 on AM335x.

    On AM335x each one of the four GPIO banks has two physical interrupt
    lines, so we now allocate resources and setup our interrupt handler for
    all the (8) available interrupts.

    On OMAP3 and OMAP4 there is only one interrupt for each GPIO bank (6
    banks, 6 interrupts), but there are two set of registers where the
    first one is used to setup the delivery of interrupts to the MPU and
    the second set, setup the delivery of interrupts to the DSP.

    On AM335x, each set of registers controls each one of the interrupt
    lines.

- Remove nonexistent registers for OMAP4 and AM335x, replace their use with
  the correct ones for these SoCs.

- Remove stray whitespace.

r264197:
Partially revert r264083.

While it is the recommended initialization procedure, it hangs on the reset
of the second GPIO module on pandaboard.

Removes the module reset for now as more investigation is needed.

git-svn-id: svn://svn.freebsd.org/base/stable/10@266148 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

9 years agoMFC r261406, r261409: enhance Vybrid support...
ian [Thu, 15 May 2014 15:43:33 +0000 (15:43 +0000)]
MFC r261406, r261409: enhance Vybrid support...

  o Expand device tree information
  o Export iomuxc (pins) configuration to DTS
  o Allow devices to assign clocks in DTS
  o Split kernel configuration to chip common and board specific parts.

git-svn-id: svn://svn.freebsd.org/base/stable/10@266146 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f