Commit graph

417 commits

Author SHA1 Message Date
David B. Kinder 9bcf629828 doc: fix typo in gpmrb doc
Fix typo missed during regular review

Signed-off-by: David B. Kinder <david.b.kinder@intel.com>
2019-06-05 21:13:33 -04:00
Geoffroy Van Cutsem 57728ffb27 boards/x86: scripts: build_grub.sh to use grub-2.04-rc1-17-g8e8723a6b
Newer versions of GCC (e.g. gcc 9.1.1) fail to compile the version of
Grub that is used by the Zephyr build_grub.sh script. This patch updates
the version of Grub to the latest (as of June 4 2019) which includes a
number of fixes that solve the problem.

Fixes: #16624
Signed-off-by: Geoffroy Van Cutsem <geoffroy.vancutsem@intel.com>
2019-06-04 19:32:44 -04:00
Charles E. Youse 69c01d11e5 boards/x86/gpmrb: add Gordon Peak MRB board
Add board support (and documentation) for the Intel Gordon Peak
Module Reference Board, a dev board based on the Apollo Lake SoC.

Signed-off-by: Charles E. Youse <charles.youse@intel.com>
2019-06-04 14:50:47 -04:00
Charles E. Youse 0fcc484944 boards/up_squared: soc/apollo_lake: I2C driver selection at SoC
While enabling specific I2C ports does indeed belong at the board
level Kconfig, the selection of driver (I2C_DW) is an SoC-level
choice, so it is moved accordingly.

Signed-off-by: Charles E. Youse <charles.youse@intel.com>
2019-06-01 10:00:32 -04:00
Charles E. Youse 2b01e06052 boards/up_squared: soc/apollo_lake: enable UARTs per board, not SoC
Which UARTs are broken out from the SoC on a particular board is
board-specific; don't enable UARTs blindly in the SoC Kconfig.

Also, the default UART options are specified in the driver Kconfig, so
the same defaults specified in the SoC Kconfig are redundant. Removed.

Signed-off-by: Charles E. Youse <charles.youse@intel.com>
2019-06-01 10:00:32 -04:00
Charles E. Youse c5aa535c98 boards/up_squared: soc/apollo_lake: devicetree default to status="ok"
Since Kconfig is responsible for enabling/disabling devices at build,
the devices in dt are defaulted to status="ok" to keep the output in
generated_dts_board.conf the same across configurations and simplify
the board-level dts files.

Signed-off-by: Charles E. Youse <charles.youse@intel.com>
2019-06-01 10:00:32 -04:00
Charles E. Youse c0502d9602 soc/apollo_lake: boards/up_squared: move UART fixups to SoC
The UART references in dts_fixup.h are actually SoC-specific, not
board-specific, so they are moved. Since this leaves the board fixups
empty, the file is removed.

The SoC fixups are expanded to include the additional two ports that
are present on some revisions of the Apollo Lake.

Signed-off-by: Charles E. Youse <charles.youse@intel.com>
2019-06-01 10:00:32 -04:00
Charles E. Youse 96961476c1 boards/up_squared: I2C support added (back) in
I2C support has been added back into the up_squared, leveraging the
new PCIe support in the DesignWare I2C driver.

Signed-off-by: Charles E. Youse <charles.youse@intel.com>
2019-05-21 08:23:22 -04:00
Charles E. Youse 309dfef511 drivers/i2c/i2c_dw.c: rewrite for PCI(e) support
The legacy PCI support in the DesignWare I2C driver is replaced with
the new PCIe support. The Intel Quark X1000 SoC and the galileo board
configurations are updated accordingly.

Signed-off-by: Charles E. Youse <charles.youse@intel.com>
2019-05-21 08:23:22 -04:00
Charles E. Youse a8dcb8b623 boards/up_squared: remove SBL-specific board configuration
The SBL configuration no longer differs in any detail (except its name)
from the "standard" UpSquared configuration, so it is removed.

Signed-off-by: Charles E. Youse <charles.youse@intel.com>
2019-05-21 08:23:22 -04:00
Charles E. Youse 35d0ae39d8 boards/up_squared: temporarily remove I2C support
This needs to be pushed down to the SoC level, as it's an Apollo Lake
feature, not a feature of the UpSquared. Remove the Apollo Lake
references to the PCI devices because these will not be used when I2C
support is restored.

Signed-off-by: Charles E. Youse <charles.youse@intel.com>
2019-05-21 08:23:22 -04:00
Charles E. Youse f9d7bc2977 boards/up_squared: remove CONFIG_SBL_FIXUP
This option is no longer used in the dts_fixup.h file since there
are no SBL-specific fixups.

Signed-off-by: Charles E. Youse <charles.youse@intel.com>
2019-05-21 08:23:22 -04:00
Charles Youse 65352a740d boards/x86/acrn: fix documentation to reflect "demo" nature
The ACRN board configuration is not suitable for production use,
but many people are mistakenly using it as a starting point for
real-time applications. I've added a note to clarify.

Signed-off-by: Charles Youse <charles.youse@intel.com>
2019-05-19 13:40:19 -07:00
Andrzej Puzdrowski 56be0fd5a9 boards/x86/qemu_x86: increase RAM size
Increase ram size as flash simulator need it for
emulated storage. The qemu_x86 flash size is puted back to
its original value of 4092K

Signed-off-by: Andrzej Puzdrowski <andrzej.puzdrowski@nordicsemi.no>
2019-05-13 14:39:34 -04:00
Charles E. Youse b5eba0f6bb boards/x86/up_squared: move UART configuration to apollo_lake.dtsi
The UARTs are on the SoC, not the board, so move their descriptors
to the SoC-level. Also turn on auto IRQ detection as these are PCI-
attached and their IRQs are subject to change depending upon firmware
settings.

Signed-off-by: Charles E. Youse <charles.youse@intel.com>
2019-05-04 18:29:32 -04:00
Charles E. Youse 6d30d949e5 boards/galileo: adjust PCI-related configuration
PCI and PCI enumeration aren't optional on the Galileo and should
not be treated as such.

Signed-off-by: Charles E. Youse <charles.youse@intel.com>
2019-05-04 18:29:32 -04:00
Andrew Boie 87d1f0682b boards: qemu_x86: properly enable XIP
The '#if XIP' in the DTS file never worked properly,
causing the QEMU build to think it has much more RAM
then it actually has. If RAM overflowed, this would not
be caught by the build, instead there would be strange
crashes when the data copy takes place.

The QEMU targets themselves are not XIP, everything
is actually RAM, but the first 4 megabytes are
considered to be a memory-mapped flash region. This
is done to ensure that the XIP data copying infrastructure
doesn't bit-rot on x86. We are at the point where
a lot of things depend on this, so just select it in
the board Kconfig instead of enabling in the
defconfigs.

Fixes: #15835

Signed-off-by: Andrew Boie <andrew.p.boie@intel.com>
2019-05-03 22:38:22 -04:00
Charles E. Youse 18833ac0ef drivers/pcie: verify PCI(e) assigned interrupts
A new function pcie_irq_enable() is added to be used in lieu of
irq_enable() when the target device is PCI(e)-attached. The function
attempts to use MSI, when configured in the kernel and supported by
the endpoint; failing that, it will verify that IRQ requested is in
fact routed to the device by the boot firmware before enabling it.

The NS16550 UART driver is updated to use pcie_irq_enable().

The PCI(e) shell is extended to dump information about wired IRQs.

The up_squared devicetree is fixed (reverted?) to IRQ5 for UART1.

The galileo enables MSI by default.

Signed-off-by: Charles E. Youse <charles.youse@intel.com>
2019-04-28 13:36:28 -04:00
Kamil Piszczek 5fd99f5e6a drivers: flash: simulator Kconfig cleanup
Moved the default selection of Flash simulator for qemu_x86 to the board
Kconfig.

Signed-off-by: Kamil Piszczek <Kamil.Piszczek@nordicsemi.no>
2019-04-26 04:04:19 -07:00
Kamil Piszczek 968d3a9ef4 dts: flash simulator cleanup
Moved the DT node description for Flash simulator to the board dts file.

Signed-off-by: Kamil Piszczek <Kamil.Piszczek@nordicsemi.no>
2019-04-26 04:04:19 -07:00
Kamil Piszczek d4be557fe9 boards: qemu_x86: reducing flash size
Reduced flash size for QEMU x86 so it does not consume a lot of RAM
memory where it is simulated.

Signed-off-by: Kamil Piszczek <Kamil.Piszczek@nordicsemi.no>
2019-04-24 13:05:11 -07:00
Kamil Piszczek dae15fa736 tests: storage: flash_map: adding qemu platform
Added QEMU platform to the Flash Map test and defined partitions for
QEMU dts.

Signed-off-by: Kamil Piszczek <Kamil.Piszczek@nordicsemi.no>
2019-04-24 13:05:11 -07:00
Kamil Piszczek 129936e63d boards: changing flash simulator device name alias
Changed alias used for flash simulator device name to match the real
one.

Signed-off-by: Kamil Piszczek <Kamil.Piszczek@nordicsemi.no>
2019-04-24 13:05:11 -07:00
Kamil Piszczek c837d85c2b drivers: flash: add flash_simulator driver
This commit adds a flash driver implementation that writes to RAM and
exports statistics through stats.h. It can be used to simulate flash
memory for testing purposes.

Signed-off-by: Emanuele Di Santo <emdi@nordicsemi.no>
Signed-off-by: Andrzej Puzdrowski <andrzej.puzdrowski@nordicsemi.no>
Signed-off-by: Kamil Piszczek <Kamil.Piszczek@nordicsemi.no>
2019-04-24 13:05:11 -07:00
Charles Youse fdf973de71 boards/x86/up_squared: update documentation to include HSUART info
Describe how to use devicetree to enable HSUART features on up_squared.

Signed-off-by: Charles Youse <charles.youse@intel.com>
2019-04-22 09:29:38 -07:00
Kumar Gala 9332abd3e1 boards: acrn: remove duplicated Kconfig HAS_DTS
We already select HAS_DTS at the arch level for X86 so we don't need to
duplicate it at the board level.

Signed-off-by: Kumar Gala <kumar.gala@linaro.org>
2019-04-20 08:54:27 -05:00
Carles Cufi bca3deb1e7 drivers: Bluetooth: Generalize IC-specific setup hook
In order to generalize the currently specialized nRF51 IC setup hook,
make the following changes:

- Generalize the hook to bt_ic_setup()
- Use a weak NOP version by default
- Move the currently existing one to the board folder

Signed-off-by: Carles Cufi <carles.cufi@nordicsemi.no>
2019-04-19 12:21:21 +02:00
Charles E. Youse e039053546 uart/ns16550, drivers/pcie: add PCI(e) support
A parallel PCI implementation ("pcie") is added with features for PCIe.
In particular, message-signaled interrupts (MSI) are supported, which
are essential to the use of any non-trivial PCIe device.

The NS16550 UART driver is modified to use pcie.

pcie is a complete replacement for the old PCI support ("pci"). It is
smaller, by an order of magnitude, and cleaner. Both pci and pcie can
(and do) coexist in the same builds, but the intent is to rework any
existing drivers that depend on pci and ultimately remove pci entirely.

This patch is large, but things in mirror are smaller than they appear.
Most of the modified files are configuration-related, and are changed
only slightly to accommodate the modified UART driver.

Deficiencies:

64-bit support is minimal. The code works fine with 64-bit capable
devices, but will not cooperate with MMIO regions (or MSI targets) that
have high bits set. This is not needed on any current boards, and is
unlikely to be needed in the future. Only superficial changes would
be required if we change our minds.

The method specifying PCI endpoints in devicetree is somewhat kludgey.
The "right" way would be to hang PCI devices off a topological tree;
while this would be more aesthetically pleasing, I don't think it's
worth the effort, given our non-standard use of devicetree.

Signed-off-by: Charles E. Youse <charles.youse@intel.com>
2019-04-17 10:50:05 -07:00
Andrei Emeltchenko fa5d9d20ec quark_se_c1000_devboard: Fix broken DTS configuration
Fixes broken CC2520 on quark_se_c1000_devboard configuration after
commit 25d17db.

Fixes #15070

Signed-off-by: Andrei Emeltchenko <andrei.emeltchenko@intel.com>
2019-04-11 10:39:21 -04:00
Anas Nashif 3ae52624ff license: cleanup: add SPDX Apache-2.0 license identifier
Update the files which contain no license information with the
'Apache-2.0' SPDX license identifier.  Many source files in the tree are
missing licensing information, which makes it harder for compliance
tools to determine the correct license.

By default all files without license information are under the default
license of Zephyr, which is Apache version 2.

Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2019-04-07 08:45:22 -04:00
Anas Nashif 9983710c44 boards: qemu_x86_nommu is a simulation platform
For some reason we dropped the simulation keyword and this platform is
not running any tests, we are just building the tests.

Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2019-04-03 21:33:19 -04:00
Patrik Flykt 5aecf9db37 boards: Rename reserved function names
Rename reserved function names in the boards/ subdirectory.

Signed-off-by: Patrik Flykt <patrik.flykt@intel.com>
2019-04-03 17:31:00 -04:00
Geoffroy Van Cutsem 5900a6fef3 boards/x86: scripts: unset CFLAGS when running build_grub.sh
On Clear Linux, the CFLAGS is set and defines a number of aggressive
checks and optimizations. This causes a build failure when generating a
GRUB2 boot loader image using the 'build_grub.sh' script.

Unsetting it within the script allows it to proceed and successfully
build a functional GRUB2 boot loader image to be used with Zephyr.

Fixes: #14289
Signed-off-by: Geoffroy Van Cutsem <geoffroy.vancutsem@intel.com>
2019-03-31 11:12:19 -04:00
David B. Kinder 223bbecf45 doc: fix ACRN board list format
One of the bullet list items didn't get rendered properly because
continuation line wasn't indented.

Signed-off-by: David B. Kinder <david.b.kinder@intel.com>
2019-03-23 19:26:27 -04:00
Carles Cufi cb44b7e768 doc: Bluetooth: Document the debug monitor and btmon in general
Move the original documentation in the arduino_101 board to a common
section in the Bluetooth documentation and document the use of `btmon`
in general.

Signed-off-by: Carles Cufi <carles.cufi@nordicsemi.no>
2019-03-21 17:23:08 +02:00
Charles E. Youse 27a56ad75c boards/x86: add ACRN UOS sample board configuration
Based on prior work by @dcpleung. It's suboptimal, but it provides a
working starting point for ACRN work. The x86 board/SoC abstractions
really need to be refactored to make this "board" (and other x86-based
"boards", both extant and future) cleaner and easier to maintain. Punt.

Signed-off-by: Charles E. Youse <charles.youse@intel.com>
2019-03-18 19:28:41 -04:00
Geoffroy Van Cutsem 209e92ef12 doc: up_squared: add 'west' build option to the UP2 documentation
It is also possible to use 'west' to build the 'hello_world' sample
application for the UP2 (up_squared) board. This patch makes it
explicit in the documentation.

Signed-off-by: Geoffroy Van Cutsem <geoffroy.vancutsem@intel.com>
2019-03-15 07:16:50 -05:00
David B. Kinder 6000a6205a doc: prepare for improving doc API linking
Linking to API material requires knowing the pecularities of how
doxygen, sphinx, and breathe work. In an attempt to hide some of this
we're preparing the current docs to allow use of configuration defaults
that will let us more simply use a default role that will hunt for a
reference target in the various domains that are available by using a
default "role" of "all".  This will let us use the simple notation
`functionname` or `typename` without fully specifying the reference as
:c:func:`functionname`.

This patch cleans up exising docs that were (incorrectly) using single
backtics where double backtics should have been used, and also found
some typos (such as a space between the role name and the reference,
such as :file: `filename`, and a missing colon such as
c:func:`functionname`)

This is a start to address issue #14313

Signed-off-by: David B. Kinder <david.b.kinder@intel.com>
2019-03-15 05:47:19 +01:00
Geoffroy Van Cutsem 96235c5027 boards/x86: scripts: build_grub.sh to use grub-2.02-285-g5bc41db75
The build_grub.sh script cherry-picks 3 commits from the master branch
of grub because more recent build tools fail to build the latest stable
release (which is 2.02). This solves the problem on Fedora 29 for
example, but is not sufficient for Clear Linux.

This patch modifies the build_grub.sh script to use
grub-2.02-285-g5bc41db75 (latest from master as of 13 of March 2019).
That version compiles 'out-of-the-box' in the latest Ubuntu, Fedora and
Clear Linux.

There are additional tools required on the host system and the
documentation has been updated accordingly.

Signed-off-by: Geoffroy Van Cutsem <geoffroy.vancutsem@intel.com>
2019-03-14 19:20:24 -05:00
Ulf Magnusson 53376394b7 kconfig: Remove blank lines at the beginning/end of files
Maybe this is some "just in case" thing that got copied around. There's
no need to have a blank line at the beginning or end of Kconfig files.

Signed-off-by: Ulf Magnusson <Ulf.Magnusson@nordicsemi.no>
2019-03-13 07:29:42 -05:00
Andrew Boie 67c4c2e6f0 qemu_x86_iamcu: disable spec execution mitigations
This build target is intended to verify that enabling the
IAMCU ABI doesn't have any bit-rot since we can easily
run this under emulation.

However, the QEMU boards all derive from the generic IA32
SOC definition, which is any pc-like hardware. We need
to disable these mitigations for this target since the
IAMCU compiler doesn't even recognize instructions like
'lfence'.

Fixes: #14315

Signed-off-by: Andrew Boie <andrew.p.boie@intel.com>
2019-03-12 18:39:49 -05:00
Geoffroy Van Cutsem 0590fd528c x86: grub_build.sh: fix compilation failures on Fedora 29
Fedora 29 (and possibly other disctributions) are nowadays coming with
very recent versions of gcc (8.x) and binutils. These will cause some
compilation error when running the 'grub_build.sh' script to create a
GRUB2 boot loader image.

Fortunately, both issues have been fixed and merged in the upstream
project. This patch modifies the build script to cherry-pick those to
the local cloned version of grub before building it.

Signed-off-by: Geoffroy Van Cutsem <geoffroy.vancutsem@intel.com>
2019-03-12 11:30:31 +01:00
David B. Kinder 505cc2bb0e doc: use :zephyr_file: where appropriate
A new role :zephyr_file: is available that renders to a link to the file
or folder in GitHub.  Find appropriate references using :file: and
convert to :zephyr_file: to take advantage of its linking capability.

Signed-off-by: David B. Kinder <david.b.kinder@intel.com>
2019-03-09 09:50:27 -05:00
Ulf Magnusson 7089ec76b9 kconfig: pinmux: Remove lots of redundant PINMUX dependencies
Most of these are from source'ing a file within an 'if PINMUX', and then
adding another 'depends on PINMUX' within it.

'if FOO' is just shorthand for adding 'depends on FOO' to each item
within the 'if'. There are no "conditional includes" in Kconfig, so
'if FOO' has no special meaning around a 'source'. Conditional includes
wouldn't be possible, because an 'if' condition could include (directly
or indirectly) forward references to symbols not defined yet.

Tip: When adding a symbol, check its dependencies in the menuconfig
('ninja menuconfig', then / to jump to the symbol). The menuconfig also
shows how the file with the symbol got included, so if you see
duplicated dependencies, it's easy to hunt down where they come from.

Signed-off-by: Ulf Magnusson <Ulf.Magnusson@nordicsemi.no>
2019-03-07 08:47:31 -05:00
Flavio Ceolin 051a7057a9 boards: galileo: Fix switch usage
According with MISRA-C every switch-clause must terminate with an
unconditional break.

MISRA-C rules 16.1 and 16.3

Signed-off-by: Flavio Ceolin <flavio.ceolin@intel.com>
2019-03-05 14:58:58 -08:00
Anas Nashif ed20fc9f30 doc: remove CONFIG_UART_QMSI_1_BAUDRATE from doc
This is now set by DTS.

Fixes #13752

Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2019-03-03 13:09:48 -08:00
Ulf Magnusson 9fb4ec6a93 arduino_101_mcuboot: Remove CONFIG_UART_QMSI_0_BAUDRATE - moved to DTS
UART_QMSI_0_BAUDRATE was removed by commit 17c6456678 ("drivers/uart:
Use dts to set uart priorities for QMSI driver").

There's a reference to CONFIG_UART_QMSI_1_BAUDRATE as well, but getting
rid of it requires documentation updates.

Signed-off-by: Ulf Magnusson <Ulf.Magnusson@nordicsemi.no>
2019-03-02 03:46:10 +01:00
Daniel Leung ee50b49621 boards: up_squared: turn on PCI enumeration
The MMIO addresses for peripherals are being assigned by BIOS
at boot. Different BIOS versions and number of enabled peripherals
affect how those addresses are assigned. This invalidates
the addresses for UART defined in DTS. Turn on PCI enumeration
so UART addresses are probed at boot to avoid non-usable
UART and black console.

Signed-off-by: Daniel Leung <daniel.leung@intel.com>
2019-02-28 18:13:43 +01:00
Daniel Leung 603f068690 uart/ns16550: Use DT_ prefix for remaining device configs
Previous rename from CONFIG_* to DT_* left a few remaining
CONFIG_*. So rename them manually now.

Fix #13753

Signed-off-by: Daniel Leung <daniel.leung@intel.com>
2019-02-26 20:06:26 -06:00
Charles E. Youse d3adba8379 boards/x86: scripts: build_grub.sh fix for newer GCC versions
Recent versions of GCC won't build grub-2.02 because they're more
pedantic about warnings. This has been fixed upstream but is not
yet part of any release. The build script is modified to apply the
relevant commits before building.

Signed-off-by: Charles E. Youse <charles.youse@intel.com>
2019-02-22 12:20:07 -06:00
Jukka Rissanen 41d17433f0 doc: net: Add more info for network connectivity with host
Added more detailed information how to connect Zephyr instance
to host system like Linux desktop.

Signed-off-by: Jukka Rissanen <jukka.rissanen@linux.intel.com>
2019-02-20 07:32:42 -05:00
Kumar Gala 8bd360fa14 boards: galileo: Fix I2C device name defaults
Fix setting of the I2C bus master device name for the GPIO_PCAL9535A
device and PWM_PCA9685.  We need to extract them from the dts otherwise
they will just get set to "".

Fixes #13458

Signed-off-by: Kumar Gala <kumar.gala@linaro.org>
2019-02-18 23:39:12 -05:00
Anas Nashif d448726aba boards: minnowboard: add image to qemu boards
Add board image and expand intro section.

Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2019-02-11 07:45:21 -05:00
Anas Nashif 762f4f26ad boards: qemu: add image to qemu boards
Add Qemu logo to qemu boards and expand intro.

Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2019-02-11 07:45:21 -05:00
Anas Nashif 99921cb917 boards: galileo: add image
Add image and expand intro section.

Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2019-02-11 07:45:21 -05:00
Anas Nashif 75e91bfbda boards: up_squared: add intro and image
Expand overview and add image of board.

Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2019-02-11 07:45:21 -05:00
Anas Nashif acaae579cc doc: boards: make board images consistent with board name
Having the image use the same name will help us script listing the
boards.

Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2019-02-10 17:48:08 -05:00
Anas Nashif dd95d2ffb9 board: up_squared_sbl: fix board identifier
This board had the wrong identifier.

Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2019-02-10 17:48:08 -05:00
Anas Nashif 0e4ff809d7 doc: boards: move all board docs to be index.rst
Be consistent in how board docs are named and move all to index.rst.
This will make the URL to the board documentation predictable and easier
to remember.

Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2019-02-09 17:22:08 -06:00
Kumar Gala 4c51684918 drivers: i2c: dw: Convert to new DT_<COMPAT>_<INSTANCE> defines
Convert designware i2c driver to use new defines so we can remove the
dts_fixup.h code for it.

Signed-off-by: Kumar Gala <kumar.gala@linaro.org>
2019-02-08 22:50:07 -05:00
Kumar Gala 33ab2fa42e boards: Change supported 'rtc' to 'counter' for QMSI RTC based boards
We've removed the QMSI RTC driver as part of the new counter API.  So
any old rtc tests don't build for QMSI based boards anymore.  Switch
this from 'rtc' to 'counter' in the board.yaml.

Signed-off-by: Kumar Gala <kumar.gala@linaro.org>
2019-02-08 07:31:21 -05:00
Daniel Leung f7a42a70f8 gpio: intel_apl: rework driver for pin_mask callback
To avoid confusion, callbacks using ordinal pin numbers
is going to be reverted. So the driver has to be re-worked
to expose multiple devices so each device has 32 pins.

Also fixes #12765

Signed-off-by: Daniel Leung <daniel.leung@intel.com>
2019-02-06 07:18:15 -05:00
Daniel Leung 7695a72e3c drivers/interrupt_controller: shared_irq: configure by device tree
This allows the shared_irq driver to be configured by device tree.
With previous implementation, only the board configuration can
override the IRQ trigger, as the trigger config is a "choice" rather
than "config". With this patch, the driver can be fully configued at
the SoC level.

Signed-off-by: Daniel Leung <daniel.leung@intel.com>
2019-02-06 07:18:15 -05:00
Andrew Boie 2d9bbdf5f3 x86: remove support for non-PAE page tables
PAE tables introduce the NX bit which is very desirable
from a security perspetive, back in 1995.

PAE tables are larger, but we are not targeting x86 memory
protection for RAM constrained devices.

Remove the old style 32-bit tables to make the x86 port
easier to maintain.

Renamed some verbosely named data structures, and fixed
incorrect number of entries for the page directory
pointer table.

Signed-off-by: Andrew Boie <andrew.p.boie@intel.com>
2019-02-05 20:51:21 -08:00
Kumar Gala f054ba2b65 flash: w25qxxdv: Convert to new DT_<COMPAT>_<INSTANCE> defines
Convert w25qxxdv driver to use new defines so we can remove the
dts_fixup.h code for it.

Signed-off-by: Kumar Gala <kumar.gala@linaro.org>
2019-01-28 10:40:31 -06:00
Kumar Gala 2492d52f5c ieee802154: cc2520: Convert to new DT_<COMPAT>_<INSTANCE> defines
Convert cc5250 driver to use new defines so we can remove the
dts_fixup.h code for it.

Signed-off-by: Kumar Gala <kumar.gala@linaro.org>
2019-01-28 10:40:14 -06:00
Kumar Gala b7cda2d33a boards: x86: arduino_101: Fix SPI dts node
We are utilizing CS0 for the flash, so the reg address should be 0 to
match.

Signed-off-by: Kumar Gala <kumar.gala@linaro.org>
2019-01-23 09:45:32 -06:00
Anas Nashif d9ec5eca24 hpet: remove HPET_TIMER_*_EDGE and HPET_TIMER_LEVEL_*
This option is not used anywhere and was removed when the hpet driver
was rewritten.

Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2019-01-22 07:45:22 -05:00
Anas Nashif 1d11945739 hpet: remove unused HPET_TIMER_LEGACY_EMULATION
This option is not used anywhere and was removed when the hpet
driver was rewritten.

Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2019-01-22 07:45:22 -05:00
Adithya Baglody 777407b9ea gcov: Add coverage supported boards.
Not all boards can get the coverage reports. The report generation
needs minimum of 64KB SRAM. This patch added support for mps2_an385,
qemu_cortex_m3, qemu_x86. This is just a subset. Also the previously
supported board native_posix is included in this patch.

If a board has 64KB RAM, it can generate reports by just
adding HAS_COVERAGE_SUPPORT in Kconfig.board.

Signed-off-by: Adithya Baglody <adithya.nagaraj.baglody@intel.com>
2019-01-16 06:12:33 -05:00
Kumar Gala a4c3feced4 dts: flash: w25qxxdv: Add Device Tree Support for SPI FLASH w25qxxdv
Convert the w25qxxdv driver to use device tree for SPI device params.
Updated the Arduino 101 config to use device tree to specify the SPI
flash.  Update the arduino_101_sss to drop Kconfig support for the
w25qxxdv flash.

Signed-off-by: Kumar Gala <kumar.gala@linaro.org>
2019-01-09 10:26:10 -06:00
Jakub Rzeszutko f8178dcb05 shell: remove Console dependencies
Removed Console dependencies from shell uart backend.
Generated define: CONFIG_UART_SHELL_ON_DEV_NAME for each board.

Fixes #10191

Signed-off-by: Jakub Rzeszutko <jakub.rzeszutko@nordicsemi.no>
2018-12-07 12:11:11 +01:00
Patrik Flykt 25e8e4d4e7 boards: Add 'U' to unsigned variable assignments
Add 'U' to a value when assigning it to an unsigned variable.
MISRA-C rule 7.2

Signed-off-by: Patrik Flykt <patrik.flykt@intel.com>
2018-12-04 22:51:56 -05:00
Andrei Emeltchenko 1bf0870d2a doc: up_squared: Add network booting documentation
Add instructions for booting Zephyr over network.

Signed-off-by: Andrei Emeltchenko <andrei.emeltchenko@intel.com>
2018-12-04 00:01:35 -05:00
Andrei Emeltchenko 9c144e9c0a doc: up_squared: Use contents instead of hardcoded toc
Use contents instead of hardcoded chapters in TOC.

Signed-off-by: Andrei Emeltchenko <andrei.emeltchenko@intel.com>
2018-12-04 00:01:35 -05:00
Andrei Emeltchenko 32655ae2e7 doc: up_squared: Clean up documentation
Cleanup documentation following common standards

Signed-off-by: Andrei Emeltchenko <andrei.emeltchenko@intel.com>
2018-12-04 00:01:35 -05:00
Andrei Emeltchenko b05c6834ad scripts: Add net and tftp to grub
This allows to boot over network for up_squared board.

Signed-off-by: Andrei Emeltchenko <andrei.emeltchenko@intel.com>
2018-12-04 00:01:35 -05:00
Andrew Boie 1c5642a402 boards: x86: don't turn on mem protection
This is not enabled at the board level.
tests/Kconfig turns this on for test cases.

Signed-off-by: Andrew Boie <andrew.p.boie@intel.com>
2018-11-28 15:33:11 -08:00
Paul Sokolovsky 182ede4912 boards: qemu_x86: Remove QEMU options which break eth_e1000 driver
"-machine type=pc-0.14" appears to be the option which leads to
broken PCI emulation in QEMU, where PCI enumeration reports one
IRQ number (11), while actually IRQ 10 is emulated by QEMU.

"-vga none" and "-display none" appear to be just subordinate of
"-machine type=pc-0.14" and are required to get qemu_x86 into
bootable state.

Fixes: #11706

Signed-off-by: Paul Sokolovsky <paul.sokolovsky@linaro.org>
2018-11-28 11:00:09 -08:00
David B. Kinder 096e18c2f8 doc: fix broken link in upsquared board doc
Link to upsquared specifications was incorrect

Signed-off-by: David B. Kinder <david.b.kinder@intel.com>
2018-11-27 18:19:21 +01:00
Anas Nashif e4505892bc boards: add docs for quark_se_c1000_devboard
Add documentation for the quark_se_c1000_devboard with links to platform
guidelines and other details.

Fixes #11166

Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2018-11-22 15:10:47 -05:00
Anas Nashif 8f807946b1 boards: quark_d2000_crb: fix board name
Fixed typo in documentation.

Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2018-11-22 15:10:47 -05:00
Kumar Gala a1a321431b boards: up_squared: Rework dts_fixup.h to work w/o BOARD_DIR include
Merge up_squared_dts_fixup.h and up_squared_sbl_dts_fixup.h into
dts_fixup.h.  This allows us to remove BOARD_DIR from being included
everywhere.

Signed-off-by: Kumar Gala <kumar.gala@linaro.org>
2018-11-20 14:08:01 -05:00
David B. Kinder e4759cbc41 doc: fix links in Galileo doc
Fix link text to remove substitutions that are ignored by Sphinx.  Also
replace link to Quark SOC HW ref manual to be from an Intel site (not
Russian).

Fixes: #11516

Signed-off-by: David B. Kinder <david.b.kinder@intel.com>
2018-11-19 21:36:22 -05:00
Kumar Gala 25d17db96b ieee802154: cc2520: quark_se_c1000_devboard: Move all GPIOs to DTS
Added support to the ti,cc2520 binding for optional GPIO signals and
moved the quark_se_c1000_devboard to define those signals in the DTS.
This lets us remove board.h and some #defines & fake Kconfig symbols
from the quark_se_c1000_devboard board.

Signed-off-by: Kumar Gala <kumar.gala@linaro.org>
2018-11-16 14:02:00 -05:00
Kumar Gala 27469810ac board: quark_se_c1000_devboard: Move the CC2520 DTS node to the board
The CC2520 device is specific to the quark_se_c1000_devboard not the
intel curie SoC.  Move the device node where it belongs.

Signed-off-by: Kumar Gala <kumar.gala@linaro.org>
2018-11-16 14:02:00 -05:00
Kumar Gala f249a0f4f2 ieee802154: cc2520: Move to DT only config support
Now that the in tree user of cc2520 uses device tree to configure SPI
and GPIO params, we can remove and convert the driver to utilize DT
only.  This means removing the Kconfig options that come from DT and
rename CONFIG_ to DT_ for those options.

Signed-off-by: Kumar Gala <kumar.gala@linaro.org>
2018-11-16 14:02:00 -05:00
Tomasz Bursztyka 1b3b0153a6 boards/x86: Use dts for configuring the cc2520 device
Only the SPI bus for now.
Make cc2520's Kconfig aware of DTS on these settings.

Signed-off-by: Tomasz Bursztyka <tomasz.bursztyka@linux.intel.com>
2018-11-16 14:02:00 -05:00
Kumar Gala fd6e9c6f58 dts: i2c: cleanup CONFIG_I2C_x_IRQ_PRI
The majority of cases of CONFIG_I2C_x_IRQ_PRI should be
DT_I2C_x_IRQ_PRI.  So go ahead and fix them up.  Only the i2c_nios
driver still uses Kconfig for getting priority.

Signed-off-by: Kumar Gala <kumar.gala@linaro.org>
2018-11-16 13:57:02 -05:00
Aiden Park 16dca3773f boards/x86: up_squared: add support for SBL(Slim Bootloader)
This adds a primitive board configuration for the UP Squared board to
work properly with SBL(Slim Bootloader).
- https://github.com/slimbootloader/slimbootloader
- https://slimbootloader.github.io/

BOARD shall be 'up_squared_sbl'
  cmake -GNinja -DBOARD=up_squared_sbl ..
  ninja

Signed-off-by: Aiden Park <aiden.park@intel.com>
2018-11-15 17:51:51 -05:00
Kumar Gala f210d11970 boards: Remove including soc.h in board.h
We should let drivers or board code include soc.h directly so we can keep
board.h to local info for board specific code.

Signed-off-by: Kumar Gala <kumar.gala@linaro.org>
2018-11-14 06:44:02 -06:00
Kumar Gala 758d5b14a9 boards: Remove board.h from boards that don't need it
These boards don't need board.h to work so remove it.

Signed-off-by: Kumar Gala <kumar.gala@linaro.org>
2018-11-14 06:44:02 -06:00
Ulf Magnusson 4638652214 Kconfig: Use 'default' instead of 'def_bool' in Kconfig.defconfig files
This can help find unused symbols. Those end up without a type if
'default' is used instead of 'def_bool', which generates a warning.

Search for "Kconfig.defconfig" in
https://docs.zephyrproject.org/latest/application/kconfig-tips.html for
a longer explanation.

Keep the 'def_bool' for the following symbols, which seem to be
deliberately defined only in Kconfig.defconfig files:

 - ALTERA_AVALON_I2C
 - ALTERA_AVALON_MSGDMA
 - ALTERA_AVALON_PIO
 - ALTERA_AVALON_QSPI
 - ALTERA_AVALON_SYSID
 - CLOCK_CONTROL_IMX_CCM
 - CPU_EM4_DMIPS
 - CPU_EM4_FPUDA
 - CPU_EM4_FPUS
 - FP_FPU_DA
 - I2C_GECKO

Signed-off-by: Ulf Magnusson <Ulf.Magnusson@nordicsemi.no>
2018-11-13 16:04:01 -05:00
Andrzej Głąbek 20202902f2 dts_fixups: Use DT_ prefix in all defined labels not related to Kconfig
These changes were obtained by running a script  created by
Ulf Magnusson <Ulf.Magnusson@nordicsemi.no> for the following
specification:

1. Read the contents of all dts_fixup.h files in Zephyr
2. Check the left-hand side of the #define macros (i.e. the X in
   #define X Y)
3. Check if that name is also the name of a Kconfig option
   3.a If it is, then do nothing
   3.b If it is not, then replace CONFIG_ with DT_ or add DT_ if it
       has neither of these two prefixes
4. Replace the use of the changed #define in the code itself
   (.c, .h, .ld)

Additionally, some tweaks had to be added to this script to catch some
of the macros used in the code in a parameterized form, e.g.:
- CONFIG_GPIO_STM32_GPIO##__SUFFIX##_BASE_ADDRESS
- CONFIG_UART_##idx##_TX_PIN
- I2C_SBCON_##_num##_BASE_ADDR
and to prevent adding DT_ prefix to the following symbols:
- FLASH_START
- FLASH_SIZE
- SRAM_START
- SRAM_SIZE
- _ROM_ADDR
- _ROM_SIZE
- _RAM_ADDR
- _RAM_SIZE
which are surprisingly also defined in some dts_fixup.h files.

Finally, some manual corrections had to be done as well:
- name##_IRQ -> DT_##name##_IRQ in uart_stm32.c

Signed-off-by: Andrzej Głąbek <andrzej.glabek@nordicsemi.no>
2018-11-13 10:44:42 -06:00
Andrzej Głąbek f39ba7230d dts_fixups: Update labels generated from DTS with DT_ prefix
All labels containing "_<8-hex-digits>_" or "16550_<3or6-hex-digits>_"
in their names, assumed to be generated by the extracting script,
are updated with the DT_ prefix, to reflect the recent changes made
to the script.

Signed-off-by: Andrzej Głąbek <andrzej.glabek@nordicsemi.no>
2018-11-13 10:44:42 -06:00
Kumar Gala e8587f4493 usb: Make USB_VBUS_GPIO a Kconfig option
Previously we had a set of magic #define's in board.h that would both
enable and set the GPIO controller & pin if a given board used a GPIO
for USB VBUS.  Now we make it a proper Kconfig set of options that
specify if the feature is needed, the GPIO controller device name, and
pin number.  In the future this should move to devicetree.

Updated the related boards that used this feature to set the Kconfig
options in the Kconfig.defconfig

Signed-off-by: Kumar Gala <kumar.gala@linaro.org>
2018-11-13 07:10:04 -06:00
Jukka Rissanen 421505c7e3 net: qemu: Allow SLIP or normal ethernet connectivity
Introduce new Kconfig option for selecting either slip or ethernet
connectivity to host.

Signed-off-by: Jukka Rissanen <jukka.rissanen@linux.intel.com>
2018-11-10 09:13:45 -05:00
Tomasz Bursztyka d658e03488 drivers/spi: Remove unused legacy options
These have been osbolete for some time already.

Fixes #11064

Signed-off-by: Tomasz Bursztyka <tomasz.bursztyka@linux.intel.com>
2018-11-09 05:25:11 -06:00
Tomasz Bursztyka 3792728582 boards/galileo: Enable SPI port 0 by default
As it used to be before in relevant quark_x1000 soc's Kconfig.

Fixes #11064

Signed-off-by: Tomasz Bursztyka <tomasz.bursztyka@linux.intel.com>
2018-11-09 05:25:11 -06:00
Tomasz Bursztyka 79e24fe7f0 boards/x86: Removing cc1200 support on quark_se_c1000_devboard
This required wiring external daughter board by hand, it's not provided
by the board directly, let's remove this.

Applying the change on relevant samples.

Signed-off-by: Tomasz Bursztyka <tomasz.bursztyka@linux.intel.com>
2018-11-09 05:25:11 -06:00
Kumar Gala 37f911375a Kconfig: dts: Move HAS_DTS to arch level
Remove either duplicate settings between arch & board, or just set
HAS_DTS at the arch level since all the boards for a given arch support
DTS now.

Signed-off-by: Kumar Gala <kumar.gala@linaro.org>
2018-11-06 18:35:39 -05:00
Anas Nashif e25d67b7b0 boards: qemu_x86: remove deprecated qemu options
Options "-clock dynticks" and  "-balloon none" are deprecated and
produce warning in recent Qemu versions, so remove them.

Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2018-11-06 12:42:08 -05:00
Anas Nashif 8d138ede02 boards: dts: define default console only
When using USB CDC, set that via an overlay instead of in the board DTS.

Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2018-11-05 12:07:30 -06:00
Daniel Leung 7ad0dd0eec boards: up_squared: dts: fix a typo in I2C address
The address to the I2C6 controller has a typo. So fix it.

Signed-off-by: Daniel Leung <daniel.leung@intel.com>
2018-11-02 21:58:02 -04:00
Kumar Gala aacdd64584 boards: Cleanup include of board.h
Remove some references <board.h> that aren't need or replace them with
<soc.h> where that is the proper include to pull in.  Also use "board.h"
instead of <board.h> for how we include the file when its local to the
board code itself.

Signed-off-by: Kumar Gala <kumar.gala@linaro.org>
2018-11-01 13:15:18 +01:00
Kumar Gala 7ae220c845 dts: x86: Fix dts warnings when building up_squared
Fix the following dts warnings:

up_squared.dts_compiled: Warning (simple_bus_reg): /soc/gpio@0:
	simple-bus unit address format error, expected "d0c50000"
up_squared.dts_compiled: Warning (simple_bus_reg): /soc/i2c@91528000:
	simple-bus unit address format error, expected "9158000"

Signed-off-by: Kumar Gala <kumar.gala@linaro.org>
2018-10-18 07:02:32 -05:00
Andy Ross 25863549be kernel: Remove clock_always_on control from k_busy_wait()
This feature was a useless noop based on mistaken API understanding.

The idea seems to have been that k_busy_wait() included guards to
ensure "clock_always_on" was true duing the loop, presumably because
the original author was afraid that "turning the clock off" would
affect the operation of k_cycle_get_32().

Then later someone came around and "optimized" this for Quark SE,
where the cycle counter is the RTC and unrelated to the timer driver
used by the clock_always_on feature.  (Except even there it presumably
should have been done at the SoC level and not just in the C1000
devboard -- note that Arduino 101 never would have gotten this).

But it was all a mistake: "clock_always_on" has nothing to do with
en/disabling the system cycle timer (which never happens when the
system is active, that's a feature of idle), it's a control over the
delivery of timer interrupts.  And needless to say we don't care about
timer interrupts when we're spinning on a cycle counter.

Yank the whole mess.

Signed-off-by: Andy Ross <andrew.j.ross@intel.com>
2018-10-16 15:03:10 -04:00
Oleg Zhurakivskyy 2f6961b778 boards/qemu_x86: Rename dts.fixup to dts_fixup.h
Use the new naming for DT fixup.

Signed-off-by: Oleg Zhurakivskyy <oleg.zhurakivskyy@intel.com>
2018-10-10 13:57:02 +03:00
Tomasz Bursztyka 6ebc766043 boards/qemu_x86: Add a dts entry for the e1000 Ethernet controller
With approriate fixups.

Signed-off-by: Tomasz Bursztyka <tomasz.bursztyka@linux.intel.com>
Signed-off-by: Oleg Zhurakivskyy <oleg.zhurakivskyy@intel.com>
2018-10-10 04:17:15 -04:00
Tomasz Bursztyka a804a4f119 dts: Add a dedicated config option for Ethernet DTS based entries
This will be usefull to tell when Ethernet device has its attributes
filled in by DTS rather than by Kconfig.

Signed-off-by: Tomasz Bursztyka <tomasz.bursztyka@linux.intel.com>
2018-10-10 04:17:15 -04:00
Kumar Gala 0d1203118f boards: x86: Convert boards to use device tree for LEDs & Buttons
Convert over x86 based boards to use device tree instead of board.h to
describe buttons & LEDs.  There are a few boards that the button gpio
flags need validation.

Signed-off-by: Kumar Gala <kumar.gala@linaro.org>
2018-10-09 11:48:54 -04:00
Sebastian Bøe 8eb734cd82 DT: Rename from dts.fixup to dts_fixup.h
The Zephyr configuration system uses many different files in many
different formats. It makes it a lot easier for users to understand
what these files do if when we use the correct file extensions.

To this end we rename the dts.fixup files to the correct file
extension '.h'.

This is a breaking change for out-of-tree fixup files. Such files will
be detected and given an appropriate error message.

Signed-off-by: Sebastian Bøe <sebastian.boe@nordicsemi.no>
2018-10-08 11:38:56 -04:00
Maureen Helm 55caa7b743 drivers: spi: Select HAS_DTS_SPI in designware driver
Makes the designware spi driver consistent with other spi drivers by
selecting HAS_DTS_SPI in the driver. This required adding spi nodes and
dts fixups to several arc and x86 socs, as well as enabling those nodes
in associated boards.

Also refactors the driver to use the base address, interrupt number, and
interrupt priority from dts.

Signed-off-by: Maureen Helm <maureen.helm@nxp.com>
2018-09-28 06:27:06 +05:30
Maureen Helm 8d89815084 boards: Remove redundant "select HAS_DTS_I2C"
The i2c drivers now consistently select HAS_DTS_I2C, so we no longer
need to select it at the board level.

Signed-off-by: Maureen Helm <maureen.helm@nxp.com>
2018-09-27 05:54:54 +05:30
Daniel Leung d328a4fede boards/x86: up_squared: add GPIO dts configuration
This adds the necessary dts entires to enable GPIO controller
on the UP Squared board.

Signed-off-by: Daniel Leung <daniel.leung@intel.com>
2018-09-19 21:36:16 -04:00
Daniel Leung 2f0282a239 boards/x86: up_squared: updates SYS_CLOCK_HW_CYCLES_PER_SEC
Sets the HPET timer frequency (enabled by default) to 19.2MHz.
And also sets the local APIC timer frequencies according to
the SoC variant.

Signed-off-by: Daniel Leung <daniel.leung@intel.com>
2018-09-19 21:36:16 -04:00
Daniel Leung 6802534d81 boards/x86: up_squared: add board option for SoC variants
There are currently three SoC variants for the UP Squared board:
Pentium, Celeron and Atom. This adds a board option to specify
for which variant is being built.

Signed-off-by: Daniel Leung <daniel.leung@intel.com>
2018-09-19 21:36:16 -04:00
Kumar Gala 6e240da26f dts: Use new DT_SIZE_{K,M} macros
Now that we have a common DT_SIZE_K macro use it instead of defining
__SIZE_K eveywhere.  We also have DT_SIZE_M, so use that in a few
places as well.

Signed-off-by: Kumar Gala <kumar.gala@linaro.org>
2018-09-15 09:23:07 -05:00
Daniel Leung c1db146b27 Revert "boards: quark_d2000_crb: Remove adc support"
This reverts commit b0d3b560238fac09e63064620de9ff820cf8cc47.

Since we now have a working ADC driver for Quark D2000,
re-add the tag.

Signed-off-by: Daniel Leung <daniel.leung@intel.com>
2018-09-05 18:38:57 -04:00
Daniel Leung 8708611fab adc: add native driver for Quark D2000
This adds a native ADC driver for Quark D2000.

Original: origin

Signed-off-by: Daniel Leung <daniel.leung@intel.com>
2018-09-05 18:38:57 -04:00
Anas Nashif d3bdc85112 boards: arduino_101: remove mention of boot stub
The stub is used for testing only and is not compatible anymore with the
usage documented here.

Fixed #9772

Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2018-09-05 12:06:37 -04:00
Punit Vara ea4305a469 boards: quark_d2000_crb: Remove adc support
Remove ADC support from d2000 as it is not migrated to
new ADC apis.

Signed-off-by: Punit Vara <punit.vara@intel.com>
2018-08-29 13:46:57 -04:00
Savinay Dharmappa 8c91001ada boards: x86: arduino_101: set DISK_FLASH_MAX_RW_SIZE to 256
set DISK_FLASH_MAX_RW_SIZE to 256, as maximum bytes that can be
programed to SPI FLASH by Page Program Command is 256.

Fixes #8506

Signed-off-by: Savinay Dharmappa <savinay.dharmappa@intel.com>
2018-08-29 07:54:55 -04:00
Daniel Leung 7b0c7aab22 boards/x86: up_squared: support new devices and Atom SoC
The board config has been verified to boot with serial console
on the Atom version of the UP Squared board. So the references
to Pentium/Celeron can be removed. Moreover, add some notes on
BIOS settings, as it may change the MMIO addresses for various
IP blocks.

Signed-off-by: Daniel Leung <daniel.leung@intel.com>
2018-07-27 17:16:18 -04:00
Daniel Leung bcc95235c5 boards/x86: up_squared: add I2C configurations
Add the necessary bits to enable the I2C controllers on
the UP Squared board. Only the ones exposed through the HAT
connector(s) are enabled by default.

Signed-off-by: Daniel Leung <daniel.leung@intel.com>
2018-07-27 17:16:18 -04:00
Zide Chen 98775f34c3 kconfig: decouple realmode boot from CONFIG_JAIHOUSE
Add CONFIG_REALMODE item so that it's possible to configure other
x86 boards to boot from real mode.

Signed-off-by: Zide Chen <zide.chen@intel.com>
2018-07-24 15:37:09 -07:00
Daniel Leung efb0080d8b boards/x86: up_squared: fix UART interrupt triggers
The triggers for UART interrupts are actually active-low.

Signed-off-by: Daniel Leung <danielcp@gmail.com>
2018-07-23 17:20:10 -04:00
Daniel Leung 04d1a38b45 boards: x86: add support for UP Squared (Pentium/Celeron)
This adds a primitive board configuration for the UP Squared board
containing Apollo Lake based Pentinum and Celeron SoC. This has
been tested on model UPS-APLP4-A10-0432.

This starts from the minnowboard configuration, and document
from galileo.

Origin: Original

Signed-off-by: Daniel Leung <daniel.leung@intel.com>
2018-07-17 16:27:52 -04:00
Daniel Leung 2bda5cf1a7 boards/x86: scripts: extend build_grub.sh for 64-bit UEFI
This extends the build_grub.sh script so that it can build 64-bit
Grub UEFI application, and thus enabling us to boot on systems
with 64-bit BIOS.

Also updated the script to checkout the tag grub-2.02 since
v2.02 has been out.

Signed-off-by: Daniel Leung <daniel.leung@intel.com>
2018-07-17 16:27:52 -04:00
Ulf Magnusson ef1544301f boards: arduino_101_mcuboot: Remove Kconfig settings moved to DTS
The PHYS_LOAD_ADDR Kconfig symbol was removed by commit b8ea7c889d
("x86: remove HAS_DTS checking"). The ROM_SIZE Kconfig symbol was
removed by commit e524f0b846 ("dts: x86: derive RAM and ROM size from
dts instead of Kconfig").

Signed-off-by: Ulf Magnusson <Ulf.Magnusson@nordicsemi.no>
2018-07-10 08:17:20 -04:00
Anas Nashif ae5105c08b boards: more boards with xtools support
Add first set of boards which can be built with xtools, this will
include all boards at some point, so we might need a better way to
whitelist toolchains that does not include changing every single board
definition file. For now enabling those needed for testing the new
toolchain.

Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2018-07-08 15:39:35 -04:00
Andy Ross 225c74bbdf kernel/Kconfig: Reorgnize wait_q and sched algorithm choices
Make these "choice" items instead of a single boolean that implies the
element unset.

Also renames WAITQ_FAST to WAITQ_SCALABLE, as the rbtree is really
only "fast" for large queue sizes (it's constant factor overhead is
bigger than a list's!)

Signed-off-by: Andy Ross <andrew.j.ross@intel.com>
2018-07-03 17:09:15 -04:00
Ulf Magnusson fb0366b339 boards: Kconfig: Remove redundant 'default n' properties
Bool symbols implicitly default to 'n'.

A 'default n' can make sense e.g. in a Kconfig.defconfig file, if you
want to override a 'default y' on the base definition of the symbol. It
isn't used like that for any of the removed properties though.

Signed-off-by: Ulf Magnusson <Ulf.Magnusson@nordicsemi.no>
2018-06-27 17:15:31 -05:00
Alex Tereschenko 3c1a78ea0d cmake: replace PROJECT_SOURCE_DIR with ZEPHYR_BASE
Both variables were used (with the same value) interchangeably
throughout CMake files and per the discussion in GH issue,
ZEPHYR_BASE is preferred.

Also add a comment with explanation of one vs. the other.

Tested by building hello_world for several boards ensuring no errors.

Fixes #7173.

Signed-off-by: Alex Tereschenko <alext.mkrs@gmail.com>
2018-06-18 15:25:55 -04:00
Tomasz Bursztyka 2fe51996db drivers/flash: Remove irrelevant option in w25qxxdv driver
CONFIG_SPI_FLASH_W25QXXDV_MAX_DATA_LEN is a left-over from old SPI API
usage. Now, there is no limit (besides the flash size) in SPI data
transaction.

Fixes #8327

Signed-off-by: Tomasz Bursztyka <tomasz.bursztyka@linux.intel.com>
2018-06-14 14:41:52 -04:00
Ulf Magnusson 02b5f3edc8 drivers: gpio: Fix GPIO_QMSI_{0,1}_NAME Kconfig references
These symbols were removed by commit ed26b95 ("drivers/gpio:
Removing dts generated options in QMSI Kconfig"). The settings should
come from DTS now.

Commit 9611002f7a ("boards/x86: Use right GPIO names for CC2520")
fixed some of the references, but there are still others left. Guess
that the same fix is appropriate in those spots (hardcoded
"GPIO_0"/"GPIO_1" names).

Signed-off-by: Ulf Magnusson <Ulf.Magnusson@nordicsemi.no>
2018-06-13 13:35:56 -04:00
Tomasz Bursztyka 9611002f7a boards/x86: Use right GPIO names for CC2520
GPIO_QMSI_<0/1>_NAME are now generated through DTS. Until CC2520
settings are generated through DTS, let's use direct gpio names
instead.

Fixes #8086

Signed-off-by: Tomasz Bursztyka <tomasz.bursztyka@linux.intel.com>
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2018-06-04 14:34:00 -04:00
Tomasz Bursztyka 538db99882 boards/x86: Removing undefined Kconfig symbol in quark_se_c1000_devboard
CONFIG_UART_QMSI_1_NAME is not generated via Kconfig anymore.

Fixes #7799

Signed-off-by: Tomasz Bursztyka <tomasz.bursztyka@linux.intel.com>
2018-06-04 08:24:28 -04:00
Tomasz Bursztyka af411f316e boards/x86: Fix support for w25qxxdv on arduino_101
It requires to use w25qxxdv spi gpio cs settings.

Fixes #7766

Signed-off-by: Tomasz Bursztyka <tomasz.bursztyka@linux.intel.com>
2018-05-29 16:21:08 -04:00
Ulf Magnusson a3128e6a2c boards: defconfig: Consistently quote string defaults
In preparation for introducing a warning.

Unquoted string defaults work through a quirk of Kconfig (undefined
symbols get their name as their string value), but look confusing. It's
done inconsistently now too.

Suggested by Kumar Gala.

Signed-off-by: Ulf Magnusson <Ulf.Magnusson@nordicsemi.no>
2018-05-26 19:17:48 -04:00
Leandro Pereira a85c546203 boards: x86: minnowboard: Unset CONFIG_X86_NO_SPECTRE_V4 by default
According to INTEL-SA-00115[1], Intel(r) Atom(tm) Processor E Series
are affected.  All Minnowboards sports one of these processors.

[1]: https://goo.gl/CKyLQy

Signed-off-by: Leandro Pereira <leandro.pereira@intel.com>
2018-05-24 13:07:12 -04:00
Sebastian Bøe cde6bef778 kconfig: Drop support for CONFIG_TOOLCHAIN_VARIANT
The Kconfig option TOOLCHAIN_VARIANT (not to be confused with
ZEPHYR_TOOLCHAIN_VARIANT) is a legacy configuration option that has
very few use-cases and can easily be dropped.

It's functionality is easily covered by CONFIG_X86_IAMCU and
ZEPHYR_TOOLCHAIN_VARIANT.

This commit removes all references of it from Zephyr.

Signed-off-by: Sebastian Bøe <sebastian.boe@nordicsemi.no>
2018-05-22 11:15:36 -04:00
Marti Bolivar 59dc82e0d2 boards: adjust openocd runner arg syntax
The current method of setting the openocd runner arguments works for
direct invocation from the command line, but the values that are
written to the CMake cache are not properly separated and are
difficult to parse, due to the fact that in several cases, option
values contain spaces.

Adjust these runner arguments so that the options and their values are
separate list items. This makes it possible to parse them accurately
from the CMake cache.

No functional changes.

Signed-off-by: Marti Bolivar <marti@opensourcefoundries.com>
2018-05-19 07:01:39 +03:00
Andy Ross f8288abd22 boards/qemu_x86: Enable fast scheduler options
This target is already using the rbtree as part of CONFIG_USERSPACE,
so it incurs no code size overhead (actually it's a little smaller)
when using the scalable scheduler and waitq implementations.

The change also gets us test coverage of those choices on a default CI
target.

Signed-off-by: Andy Ross <andrew.j.ross@intel.com>
2018-05-19 07:00:55 +03:00
Anas Nashif 103cbe8c90 boards: minnowboard: do not run net/bluetooth tests
This board does not support both bluetooth and networking, so skip those
tests for now.

Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2018-05-16 23:10:30 +03:00
Savinay Dharmappa e524f0b846 dts: x86: derive RAM and ROM size from dts instead of Kconfig
patch removes Kconfig defines for RAM and ROM size in x86. Instead
these values are derived from dts.

Signed-off-by: Savinay Dharmappa <savinay.dharmappa@intel.com>
2018-05-14 17:19:23 -04:00
Ulf Magnusson 9c032eb14d boards/arduino101: Enable UART 0 controller
boards/x86/arduino_101/arduino_101_defconfig currently enables
CONFIG_UART_QMSI_0_HW_FC (HW flow control on UART 0), but doesn't enable
CONFIG_UART_QMSI_0 (the UART itself), which is a direct dependency.

This means CONFIG_UART_QMSI_0_HW_FC remains disabled despite the request
to enable it, and kconfig.py prints a warning.

Enable CONFIG_UART_QMSI_0 in the arduino_101_defconfig.

Signed-off-by: Ulf Magnusson <ulfalizer@gmail.com>
2018-04-12 17:55:46 -05:00
Kumar Gala c542c0e33e boards: dts: Cleanup aliases
Underscore ('_') isn't a valid char for alias names based on the device
tree spec.  Newer dtc compilers flag this as a warning so lets clean it
up.  Replaced '_' with '-' to keep things simple.

Signed-off-by: Kumar Gala <kumar.gala@linaro.org>
2018-04-12 04:03:46 -05:00
Anas Nashif 973ec4ea62 boards: reduce testing on the same platform with variations
We are testing and building this already using qemu_x86, no need to
build the same thing all over again.

Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2018-04-09 22:55:20 -04:00
Anas Nashif 2ee6dff77b boards: fix yaml syntax and reduce indentation
Minor indentation fix

Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2018-04-09 22:55:20 -04:00