Importing usr.sbin/i2cscan

Change-Id: I7b776d6e5f3fe4f7a1af353b995ef9e2e752c7ea
libi2cdriver: library for i2c device drivers

Change-Id: Ib6d5617e4b62e0bc5b25e6fa92b44baf536b1961
cat24c256: driver for the cat24c256 i2c eeprom

Change-Id: I682d136c80fc868d3f0a5edb0cf6c33c0f3a28ea
eepromread: simple program to view eeprom contents

This program uses the i2c /dev interface to read the
contents of EEPROMs and display it to the user in
HEX and ASCII. It also has a mode that can display
data in label:value pairs. That mode is used for
board detection in the rc script to start the right
i2c drivers for the board.

Change-Id: I0bf5b13ffab5a89533c762d6881a145cf7f14914
drivers/fbd/action.c: removed some 64-bit functions

Change-Id: I6a041f7dabad3e849d868c94c4fbd0edb7fc88b7
Replace 64bit funcions with operators in at_wini.c

Change-Id: I5d4f85a55f9f9d4c2a26daca6957be8f57ba9164
Revert "drivers/fbd/action.c: removed some 64-bit functions"

This reverts commit 85e7d849c804ae9df50e29dc9c81057a83e16726.

This introduce a bug in position computing for disk bigger than 4GB.

Change-Id: I281e60e9644d995cc4643006b50c05693f939b44
Importing NetBSD "Kyua" test framework

To do so, a few dependencies have been imported:

 * external/bsd/lutok
 * external/mit/lua
 * external/public-domain/sqlite
 * external/public-domain/xz

The Kyua framework is the new generation of ATF (Automated Test
Framework), it is composed of:

 * external/bsd/atf
 * external/bsd/kyua-atf-compat
 * external/bsd/kyua-cli
 * external/bsd/kyua-tester
 * tests

Kyua/ATF being written in C++, it depends on libstdc++ which is
provided by GCC. As this is not part of the sources, Kyua is only
compiled when the native GCC utils are installed.

To install Kyua do the following:

 * In a cross-build enviromnent, add the following to the build.sh
   commandline: -V MKBINUTILS=yes -V MKGCCCMDS=yes

WARNING:
  At this point the import is still experimental, and not supported
  on native builds (a.k.a make build).

Change-Id: I26aee23c5bbd2d64adcb7c1beb98fe0d479d7ada
i2c: increase BUFLEN/CMDLEN to 128, add page flag.

128 byte reads are much more common than 32 byte reads. The message
passing + setup/teardown for a read is much more expensive, in terms
of time, than the reading itself. A slightly bigger struct is well
worth the time savings. This reduces read times for /dev/eeprom
from 57 seconds per 4KB to 14 seconds.

Additionally, make sending the page address in the eeprom driver
and utility optional. This can save a little time when reading
within the same page and allows support for smaller devices that
don't support pages (example: chips containing EDID).

Change-Id: Ie48087caee40c11fa241d1555fce9309ddd27b43
tda19988: driver for the TDA19988 HDMI Transmitter

Change-Id: Ia7750df3dd4ec4bd68624c800a0241c70eea7ca4
fxp: Add code for PCI_REV 0x83

Change-Id: I44456c72ebc041ed31327d7c4a8cb77dacaee990
Lan8710 driver initial version, after first review

Change-Id: If00cf1e098da5875eb040f8765273a6fa5e43e33
removed some 64-bit functions

Change-Id: Idbafdbf13714f984f03770bd3b39521cb1014cdb
VFS: fix access bits in device reopen calls
readclock: add support for am335x RTC

Add support for getting/setting the am335x SoC's internal real
time clock. Also, allow the power off alarm to be set.

Make readclock an "always on" driver. This is needed for setting
power-off alarms whenever the power button is pressed on the BBB.

Replace the readclock.sh script & single run driver with a
readclock program that takes the same arguments and forwards
the requests on to the always up readclock driver.

Change-Id: Ifd6c2acd80ae4b5e79d83df510df445c24e24a71
libminc: add reboot()

Change-Id: Ia604e3d57dbcdc25c96c1aa0a263384982311d09
tps65217: driver for the TPS65217 PMIC

Change-Id: Ic2259c15645816627d757c9c45560cb4c5c0156c
kernel: add support for am335x PMIC-base power-off

AM335X SoCs support power-off via a power management
chip (PMIC). An alarm in the real time clock is used
to trigger the PMIC to cut the power.

To ensure the alarm goes off when the system is in
a safe state, the RTC is frozen when the alarm is
set. At the last moment, the kernel unfreezes the RTC
to let the alarm go off.

This patch adds a mini driver for unfreezing the RTC
as well as code to handle RBT_POWEROFF on Minix/arm.

Change-Id: I7d48e75791e3a81bdd2f7704997193a269409fe8
pm: notify readclock of reboot(RBT_POWEROFF)

Some ARM chips handle power-off with RTC alarms. PM notifies
readclock (the driver for RTCs) about the impending power-off.
If the power-off mechanism is an RTC alarm, readclock will
set the alarm. If not, there is no effect.

Change-Id: Iee00066def2a0f742cdf0dbde8e32b376edf1b78
kernel: implement reboot for am335x/dm37xx

Change-Id: Ied288326b9af8f31223b2dd76a064e32c9a03c45