Commit Graph

713 Commits

Author SHA1 Message Date
Emmanuel Vadot
82533b026a arm: Remove ALLWINNER_UP kernel config
This was needed when we GENERIC couldn't boot on UP system.
2018-08-03 22:15:58 +00:00
Emmanuel Vadot
cfe196fbed nvmem: Add nvmem interface and helpers
The nvmem interface helps provider of nvmem data to expose themselves to consumer.
NVMEM is generally present on some embedded board in a form of eeprom or fuses.
The nvmem api are helpers for consumer to read/write the cell data from a provider.

Differential Revision:	https://reviews.freebsd.org/D16419
2018-07-31 19:08:24 +00:00
Andrew Turner
e57edd3580 Remove now the cow unused CPU_ARM9 and CPU_FA526 options. These are for
ARMv4 CPUs that are no longer supported.
2018-07-28 11:00:45 +00:00
Warner Losh
7eb20343b3 This builds now, so aadd it back to Universe. 2018-07-27 21:26:32 +00:00
Warner Losh
888a313927 Remove xscale support.
As discussed in arm@.  This is a scaled back version of the prior
commit because xscale is overlaoded in places to mean armv5 or
similar.  The OLD XSCALE stuff hasn't been useful in a while. The
original committer (cognet@) was the only one that had boards for
it. He's blessed this removal. Newer XSCALE (GUMSTIX) is for hardware
that's quite old. After discussion on arm@, it was clear there was no
support for keeping it.

Noticed by: andrew@
2018-07-27 21:25:07 +00:00
Warner Losh
c81b12e0d7 Revert r336773: it removed too much.
r336773 removed all things xscale. However, some things xscale are
really armv5. Revert that entirely. A more modest removal will follow.

Noticed by: andrew@
2018-07-27 21:25:01 +00:00
Warner Losh
626930c2fd Remove xscale support
The OLD XSCALE stuff hasn't been useful in a while. The original
committer (cognet@) was the only one that had boards for it. He's
blessed this removal. Newer XSCALE (GUMSTIX) is for hardware that's
quite old. After discussion on arm@, it was clear there was no support
for keeping it.

Differential Review: https://reviews.freebsd.org/D16313
2018-07-27 18:33:09 +00:00
Warner Losh
fb3f4b7549 Make ralink compile again.
Add std.ralink to define common things across all ralink configs.
Add cpu, machine and options INTRNG to this file.
Remove RT1310.hints file reference: that file isn't in our tree.
2018-07-27 18:31:30 +00:00
Warner Losh
848c22d7b1 Remove Cavium/Econa CNS11xx support.
This port hasn't been updated since it was committed, apart from
housekeeping. There's no known users, and the known hardware for
this port is too thin to run FreeBSD/arm these days well.

This also removes the last armv4 port. We've had no reports of armv4
systems working since FreeBSD 8. All the kernel support for armv4 has
not been removed since it's too intertwined with armv5 support (which
remains in the tree).

RelNotes: Yes
No objection from: arm@
2018-07-27 18:30:01 +00:00
Warner Losh
58d5c51106 Remove Atmel AT91RM9200 and AT91SAM9 support.
The last known robust version of this code base was FreeBSD 8.2. There
are no users of this on current, and all users of it have abandoned
this platform or are in legacy mode with a prior version of FreeBSD.

All known users on arm@ approved this removal, and there were no
objections.

Differential Revision: https://reviews.freebsd.org/D16312
2018-07-27 18:28:22 +00:00
Ian Lepore
b89ff96c7d Add option MAC to armv6 and armv7 kernels by default, it needs to be
compiled-in to allow loading policy modules at runtime.
2018-07-21 18:54:24 +00:00
Warner Losh
ff9452772d Remove kernel support for armeb
Remove all the big-endian arm architectures (ixp425 and ixp435)
support in the kernel and associated drivers.

Differential Revision:  https://reviews.freebsd.org/D16257
2018-07-17 23:23:45 +00:00
Ian Lepore
0592ad0252 Oops, fix a typo: imx_snvs should be imx6_snvs. 2018-07-08 21:14:43 +00:00
Ian Lepore
638a5afda9 Move device statements out of std.imx* and into kernel config files.
In the armv4/5 world device statements in these files were common, but in
the v6/7 world, other socs don't put device statements into those files, so
this just brings imx5 and imx6 into line with the current conventions.
2018-07-08 21:09:52 +00:00
Kevin Lo
3fff2af912 Since we don't enable BUF_TRACKING and FULL_BUF_TRACKING buffer debugging
options in GENERIC kernels on arm and arm64, there's no need to disable
them.

Sponsored by:	MSI/FUNTORO
2018-06-05 05:24:42 +00:00
Conrad Meyer
a0638b33f7 Yank crufty INTR_FILTER option
It was introduced to the tree in r169320 and r169321 in May 2007.

It never got much use and never became a kernel default.  The code
duplicates the default path quite a bit, with slight modifications.  Just
yank out the cruft.  Whatever goals were being aimed for can probably be met
within the existing framework, without a flag day option.

Mostly mechanical change: 'unifdef -m -UINTR_FILTER'.

Reviewed by:	mmacy
Sponsored by:	Dell EMC Isilon
Differential Revision:	https://reviews.freebsd.org/D15546
2018-05-24 17:06:00 +00:00
Marcin Wojtas
10ebf6661e Add Marvell ArmadaXP and Armada38X to GENERIC config
Include source files and drivers for Marvell ArmadaXP and Armada38X
in GENERIC kernel config.

Submitted by: Michal Mazur <mkm@semihalf.com>
              Rafal Kozik <rk@semihalf.com>
Reviewed by: manu
Tested by: manu
Obtained from: Semihalf
Sponsored by: Stormshield
2018-05-03 01:23:42 +00:00
Warner Losh
80d19ff404 Remove 'All Rights Reserved.' from all of my Copyrights in sys/arm and
always use 'M. Warner Losh' for consistency.

'All Rights Reserved.' was prescribed by the Buenos Aires Copyright
Convention of 1910, but has been mostly dead since the early 1990's
and completely meaningless since 2000 when Nicaragua ratified the
Berne convention.

Some files not done due to ambiguity of various types.
2018-05-01 16:21:01 +00:00
Emmanuel Vadot
f1012f03d1 arm: dts: overlays: Remove the overlay module
Move the DTSO variables in the main SoC dtb file

Discussed with:		ian
2018-04-27 21:15:51 +00:00
Marcin Wojtas
a3b3bb87cc Revert r333035 due broken booting on !Marvell GENERIC platforms
Reported by: manu
2018-04-27 05:32:09 +00:00
Marcin Wojtas
e3b287fc9e Add Marvell ArmadaXP and Armada38X to GENERIC config
Include source files and drivers for Marvell ArmadaXP and Armada38X
in GENERIC kernel config.

Submitted by: Michal Mazur <mkm@semihalf.com>
	      Rafal Kozik <rk@semihalf.com>
Obtained from: Semihalf
Sponsored by: Stormshield
Differential Revision: https://reviews.freebsd.org/D14747
2018-04-26 19:23:37 +00:00
Marcin Wojtas
84678c82b1 Add support for gpioled on ARMADA38X based boards
This patch adds support for gpio and gpioled into ARMADA38X kernel
config.

Reviewed by: andrew
Obtained from: Semihalf
Sponsored by: Stormshield
Differential Revision: https://reviews.freebsd.org/D14758
2018-04-26 19:15:39 +00:00
Ruslan Bukin
05439eb571 Enable ARM PL330 DMA engine and Cadence Quad SPI flash controller on
Intel Arria 10 SoC boards.

Tested on Intel Arria 10 SoC Development Kit.

Sponsored by:	DARPA, AFRL
2018-04-23 12:23:05 +00:00
Oleksandr Tymoshenko
91cc58af37 [rpi] Add fdt_pinctrl(4) support to Raspberry Pi GPIO driver
On Raspberry Pi platform GPIO controller also responsible for pins
multiplexing. Pi code predates proper FDT support in FreeBSD so a
lot of pinmux info is hardcoded. This patch:

- Implements pinctl methods in bcm2835_gpio
- Converts all devices with ad-hoc pinmux info to proper pin control
  mechanisms and adds pinmux info in FreeBSD's custom dts files.
- Adds fdt_pinctrl option to RPI2 and RPI-B kernels
- Adds SPI pinmux config to FreeBSD's customization of GNU DTS.

Reviewed by:	imp, manu
Differential Revision:	https://reviews.freebsd.org/D14104
2018-04-08 00:56:19 +00:00
Marcin Wojtas
ccc1e6eb49 Use PLATFORM for initializing Marvell ArmadaXP and Armada38X
Spliting armv5 and armv7 machdep is necessary for adding Armada38X and
ArmadaXP to GENERIC config.
PLATFORM framework checks SOC type in FDT and will select proper
initialization function implementation during runtime.
Pointers to SoC specific implementation are stored in array of
platform_method_t and provided to framework by FDT_PLATFORM_DEF macro.
PLATFORM framework supports also reset function. To simplify implementation
cpu_reset is moved from mv_common to armv5 and armv7 machdep.

Armada38X and ArmadaXP share now common list of files, so resolve all
dependencies as well.

Submitted by: Rafal Kozik <rk@semihalf.com>
	      Marcin Wojtas <mw@semihalf.com>
Reviewed by: mw
Obtained from: Semihalf
Sponsored by: Stormshield
Differential Revision: https://reviews.freebsd.org/D14744
2018-04-04 08:40:49 +00:00
Marcin Wojtas
244af1d4db Enable ArmadaXP using INTRNG interrupt controller
Defining INTRNG remove some necessary registers and declarations of
pic_init_secondary, pic_ipi_send, pic_ipi_read and pic_ipi_clear.
Because Marvell ArmadaXP and Armada38X always use INTRNG, include all
INTRNG code and remove code that does not use it.
Separate pic registers declarations for Armada38X are unnecessary, it
works properly with ArmadaXP config.

Submitted by: Rafal Kozik <rk@semihalf.com>
Reviewed by: andrew
Obtained from: Semihalf
Sponsored by: Stormshield
Differential Revision: https://reviews.freebsd.org/D14734
2018-04-03 21:17:19 +00:00
Emmanuel Vadot
c2f5940db3 Add dtb overlays support
DTB Overlays are useful to change/add nodes to a dtb without the need to
modify it.
Add support for building dtbo during buildkernel.
The goal of DTBO present in the FreeBSD source tree is to fill a gap in
time when we submit changes upstream (Linux). Instead of waiting 2 to 4 months
we can add a DTBO in tree in the meantime.
This is not for adding DTBO for capes/hat/addon boards, those will be
better to put in a ports.
This is also not for enabling a i2c/spi/pwm controller on certain pins,
each user have a different use case for those (which pins to use etc ...)
and we cannot have all possible configuration.

Add a dtbo for sun8i-h3-sid which add the SID node missing in upstream dts.

Reviewed by:	kevans
Differential Revision:	https://reviews.freebsd.org/D14782
2018-03-24 21:30:24 +00:00
Emmanuel Vadot
df5f14797b arm: Remove SoC Specific -MMCCAM kernelconfig
One should use the GENERIC-MMCCAM for this.
2018-03-11 23:14:50 +00:00
Emmanuel Vadot
1857bc794f arm: Add GENERIC-MMCCAM kernel config
MMCCAM is the new mmc stack currently developped by kibab@, add a kernel
configuration file that include GENERIC so it's easier to test for people.
2018-03-08 22:54:50 +00:00
Emmanuel Vadot
6151aa3860 RK3188: Mark it NO_UNIVERSE
This is an old kernel so mark it as NO_UNIVERSE so it's not built by
the universe rule or tinderbox.
2018-02-28 19:08:52 +00:00
Ian Lepore
1d01310593 Remove obsolete options from these kernel configs. The functionality these
enabled is now on by default since r313330.
2018-02-27 00:30:10 +00:00
Ian Lepore
f82eace5b3 Build modules specific to imx5/imx6 only when building those kernels.
This adds sys/modules/imx with a SUBDIR makefile to make the whole
collection of modules that are specific to these SoCs.  Initially, that
"whole collection" consists of the if_ffec and imx_i2c drivers.

The if_ffec driver is referenced in its existing home in ../ffec rather
than moving it into the imx directory, because it's used by powerpc too,
but it is no longer built for all armv6/7 systems.

The imx_i2c driver is newly added as a module.
2018-02-18 02:48:54 +00:00
Warner Losh
802baf0ba6 Cull Atmel board configs no longer relevant.
Remove most of the Atmel at91 boards. Most of them are no longer
relevant or used by people. Kept ATMEL since it should work on all the
boards that still work (I've not confirmed this, since I don't have
all these boards). Also kept SAM9G20EK, since I have several boards
that it is used on. If I've deleted a kernel in error, please let me
know.
2018-02-07 18:33:53 +00:00
Emmanuel Vadot
09ac343759 arm: lpc: Remove support
Code hasn't been touch this it's original commit in 2012 beside api changes.

Reviewed by:	ian
Differential Revision:	https://reviews.freebsd.org/D13625
Discussed with:		freebsd-arm@freebsd.org (no reply)
2018-01-24 22:04:16 +00:00
Edward Tomasz Napierala
83d02512b4 Add usb_template(4) to RPI-B kernel config. This is to support the USB OTG
functionality on Raspberry Pi 0.

Reviewed by:	hselasky@
MFC after:	2 weeks
Sponsored by:	The FreeBSD Foundation
Differential Revision:	https://reviews.freebsd.org/D13924
2018-01-20 14:00:07 +00:00
Kyle Evans
2defb358ea if_awg: Use syscon prop if it exists
The emac bindings that are landing in Linux 4.15 specify a syscon property
on the emac node that point to /soc/syscon. Use this property if it's
specified, but maintain backwards compatibility with the old method.

The older method is still used for boards that we get .dtb from u-boot, such
as pine64, that did not yet have stable emac bindings.

Tested on:	Banana Pi-M3 (a83t)
Tested on:	Pine64 (a64)
Reviewed by:	manu
Differential Revision:	https://reviews.freebsd.org/D13296
2018-01-04 22:37:15 +00:00
Ian Lepore
2d09b07279 Make kernel option KERNVIRTADDR optional, remove it from std.<platform>
files that can use the default value.

It used to be required that the low-order bits of KERNVIRTADDR matched
the low-order bits of the physical load address for all arm platforms.
That hasn't been a requirement for armv6 platforms since FreeBSD 10.
There is no longer any relationship between load addr and KERNVIRTADDR
except that both must be aligned to a 2 MiB boundary.

This change makes the default KERNVIRTADDR value 0xc0000000, and removes the
options from all the platforms that can use the default value.  The default
is now defined in vmparam.h, and that file is now included in a few new
places that reference KERNVIRTADDR, since it may not come in via the
forced-include of opt_global.h on the compile command line.
2017-12-30 00:20:49 +00:00
Scott Long
c15269ccb8 It's time to retire AHC_REG_PRETTY_PRINT and AHD_REG_PRETTY_PRINT from
the standard kernels.  They are still available as custom compile
options.
2017-11-29 23:41:49 +00:00
Pedro F. Giffuni
af3dc4a7ca sys/arm: further adoption of SPDX licensing ID tags.
Mainly focus on files that use BSD 2-Clause license, however the tool I
was using misidentified many licenses so this was mostly a manual - error
prone - task.

The Software Package Data Exchange (SPDX) group provides a specification
to make it easier for automated tools to detect and summarize well known
opensource licenses. We are gradually adopting the specification, noting
that the tags are considered only advisory and do not, in any way,
superceed or replace the license texts.
2017-11-27 15:04:10 +00:00
Eitan Adler
a2aef24aa3 Update several more URLs
- Primarily http -> https
- Primarily FreeBSD project URLs
2017-10-29 08:17:03 +00:00
Bjoern A. Zeeb
8e94025b41 With r181803 on 2008-08-17 23:27:27Z the first VIMAGE commit went into
HEAD.  Enable VIMAGE in GENERIC kernels and some others (where GENERIC does
not exist) on HEAD.

Disable building LINT-VIMAGE with VIMAGE being default.

This should give it a lot more exposure in the run-up to 12 to help
us evaluate whether to keep it on by default or not.
We are also hoping to get better performance testing.
The feature can be disabled using nooptions.

Requested by:		many
Reviewed by:		kristof, emaste, hiren
X-MFC after:		never
Relnotes:		yes
Differential Revision:	https://reviews.freebsd.org/D12639
2017-10-20 21:40:59 +00:00
Bjoern A. Zeeb
14c25c2ac6 Previously there was a VIRT kernel to which I had added these options.
With that gone they need to go into GENERIC now.

Makes FreeBSD/arm usable on gem5 by default.

Reviewed by:		andrew
Differential Revision:	https://reviews.freebsd.org/D12566
2017-10-12 14:32:45 +00:00
Warner Losh
094fc1ed0f Tag all armv7 kernels as such in their machine config line.
Transition all boards that support arm cortex CPUs to armv7. This
leaves two armv6 kernels in the tree. RPI-B, which uses the BCM2835
which has a ARM1176 core, and VERSATILEPB, which is a qemu board setup
around the time RPI-B went in. Copy std.armv6 to std.armv7, even
though that duplicates a lot of stuff. More work needs to be done to
sort out the duplication.

Differential Revision: https://reviews.freebsd.org/D12027
2017-10-05 23:01:50 +00:00
Andrew Turner
5493a64ac4 Remove the VIRT kernel config, it's now useable through GENERIC.
Sponsored by:	DARPA, AFRL
2017-09-24 13:28:24 +00:00
Andrew Turner
6b81683f9e Add i.MX6 and Xilinx to GENERIC.
Merge in the missing devices from the IMX6 and ZEDBOARD kernel configs. The
Freescale sdma device has been renamed to fslsdma to mark it as a platform
specific driver.

Reviewed by:	ian
Sponsored by:	DARPA, AFRL
Differential Revision:	https://reviews.freebsd.org/D11564
2017-09-24 09:33:08 +00:00
Ilya Bakulin
a9bfc8d2ae Add MMCCAM-enabled kernel config for IMX6, reduce debug noice in MMCCAM kernels
CAM_DEBUG_TRACE results in way too much debug output than needed now.
When debugging, it's always possible to turn on trace level using camcontrol.

Approved by:	imp (mentor)
Differential Revision:	https://reviews.freebsd.org/D12110
2017-09-13 10:56:02 +00:00
Marcin Wojtas
cb0c98fce0 Change name of Marvell Armada38x RTC driver
Two modules with the same name cannot be loaded, so Marvell specific drivers
cannot have the same name as generic drivers.
Files with the same name, even in different folder overlaps their .o files.
Change armada38x/rtc.c to armada38x/armada38x_rtc.c fix it.
Preparation for adding this driver to GENERIC config for ARMv7
Marvell platforms.

Submitted by: Rafal Kozik <rk@semihalf.com>
Obtained from: Semihalf
Sponsored by: Semihalf
Differential Revision: https://reviews.freebsd.org/D12185
2017-09-05 05:42:37 +00:00
Ian Lepore
1dc8df138d Add back the drivers for Dallas/Maxim ds13xx and Seiko S35390x now that
they've been rewritten/fixed to not cause panics by doing i2c transfers
before interrupts are available.

PR:		221227
2017-08-14 00:12:14 +00:00
Ed Maste
67d4951ddf arm: enable ARM_MANY_BOARD in NOTES for LINT build
Added in r238189, ARM_MANY_BOARD adds support for multiple ARM boards in
a single kernel. Include it for LINT builds to avoid duplicate symbol
errors when linking with lld.

Sponsored by:	The FreeBSD Foundation
2017-08-11 19:49:29 +00:00
Ian Lepore
b8c53507cb Remove the ds133x and s35390a i2c RTC drivers for now. They both do i2c
transfers in their probe() or attach() routines, and that doesn't work
when the low-level controller requires interrupts to be functional.

The DS133x family of chips is nearly identical to the DS1307 and support
for them should be added to that driver, then the ds133x driver can be
deleted.  The s35390a driver just needs a non-trivial workover.  In both
cases that work will be done and committed separately.
2017-08-08 22:58:34 +00:00
Emmanuel Vadot
c31654c5b6 arm: Add a GENERIC-NODEBUG kernel config
Like amd64 or arm64 provide a GENERIC-NODEBUG configuration file that
remove WITNESS and INVARIANTS etc ...
2017-08-03 19:01:46 +00:00
Ian Lepore
854519fdd9 Add an ahci driver for imx6.
This was submitted by Rogiel Sulzbach (thank you!) but has a few last-minute
changes by me, mostly where the code interfaces to my still-utterly-deficient
imx6_ccm clocks implementation.  So blame me for any mistakes.

Submitted by:	Rogiel Sulzbach <rogiel@rogiel.com>
Differential Revision:	https://reviews.freebsd.org/D11177
2017-08-03 14:43:41 +00:00
Ian Lepore
0f5da9cd8c Add the i2c RTC drivers found on various arm systems. 2017-07-30 00:25:29 +00:00
Andrew Turner
75f48c23ea Add external PLATFORM access on arm, and use it in the pl310 driver.
This allows multiple instances of SoCs that use the pl310 driver to be
built within the same kernel:

 * Add access to the platform_t object from outside platform.c
 * Use this with the pl310 driver

There is a new platform_pl310 interface to replace the existing code. SoCs
need to implement the init method, and if they have special requirements to
write to the two registers we care about will also need to implement the
write_ctrl and write_debug methods.

Differential Revision:	https://reviews.freebsd.org/D11546
2017-07-11 16:30:16 +00:00
Warner Losh
a94a63f0a6 An MMC/SD/SDIO stack using CAM
Implement the MMC/SD/SDIO protocol within a CAM framework. CAM's
flexible queueing will make it easier to write non-storage drivers
than the legacy stack. SDIO drivers from both the kernel and as
userland daemons are possible, though much of that functionality will
come later.

Some of the CAM integration isn't complete (there are sleeps in the
device probe state machine, for example), but those minor issues can
be improved in-tree more easily than out of tree and shouldn't gate
progress on other fronts. Appologies to reviews if specific items
have been overlooked.

Submitted by: Ilya Bakulin
Reviewed by: emaste, imp, mav, adrian, ian
Differential Review: https://reviews.freebsd.org/D4761

merge with first commit, various compile hacks.
2017-07-09 16:57:24 +00:00
Andrew Turner
9ce763a0db Remove the MULTIDELAY option from arm. It's now enabled when PLATFORM is
enabled.
2017-07-07 13:55:11 +00:00
Andrew Turner
83ad38643c Make MULTIDELAY a requirement in the MPCore Timer driver when using
PLATFORM. This will help with removing the MULTIDELAY option, enabling
it when PLATFORM is enabled.
2017-07-05 10:29:05 +00:00
Andrew Turner
88fd0c95a3 Require the ARM Generic Timer driver is built for MULTIDELAY on 32bit arm.
As this driver is also used for DELAY on arm64 we need to keep the existing
DELAY code for it to use.
2017-07-05 09:27:18 +00:00
Andrew Turner
89ea89de85 Move the simple armv6 only timer drivers to require MULTIDELAY to help
move all armv6 configs it.
2017-07-04 18:07:09 +00:00
Andrew Turner
3d814b4cf9 Remove PLATFORM_SMP. It's unneeded as all configs with both PLATFORM and
SMP use it so we can switch to the combination of these as the check.
2017-07-04 16:52:55 +00:00
Andrew Turner
c20963ad19 Add PLATFORM and PLATFORM_SMP support to the ALPINE kernel configuration.
This will help move it to be part of GENERIC.
2017-07-04 12:26:47 +00:00
Andrew Turner
b77a75e4a6 Teach VERSATILEPB about PLATFORM. This will help move it into the GENERIC
kernel configuration.
2017-07-04 12:17:49 +00:00
Emmanuel Vadot
ac485d3178 Remove ALLWINNER kernel config file, all release image for SMP Allwinner
board uses GENERIC and it's not updated for newer SoC.
2017-06-25 11:31:39 +00:00
Emmanuel Vadot
7f61394200 Allwinner: Add support for H2 Plus SoC
H2+ SoC is a stripped down version of H3 without gigabit ethernet and 4K HDMI.
Also add sun8i-h2-plus-orangepi-zero.dts to the build as we run on this board.
2017-06-24 16:41:26 +00:00
Warner Losh
4558167c59 Put ARM_USE_V6_BUSDMA into the SAM9G20EK reference kernel to try to
track down the unaligned I/O issues we have with at least USB on that
platform.
2017-06-18 21:03:53 +00:00
Zbigniew Bodek
824e6d6bc4 Enable neta controller support in ARMADA38X
Submitted by: Marcin Wojtas <mw@semihalf.com>
Obtained from: Semihalf
Sponsored by: Stormshield
Differential revision: https://reviews.freebsd.org/D10707
2017-06-13 18:47:42 +00:00
Andrew Turner
d9f504454a Port the Vybrid code to PLATFORM to help move it into GENERIC. 2017-06-03 20:14:46 +00:00
Andrew Turner
6f5db7909a Port the Samsung ARM code to use PLATFORM and PLATFORM_SMP. This will help
move it into the GENERIC kernel config.
2017-06-03 20:02:12 +00:00
Andrew Turner
dc59c854ca Port the Xilinx code to use PLATFORM and PLATFORM_SMP. This will help move
it to be part of the armv6 GENERIC kernel.
2017-06-03 19:11:32 +00:00
Andrew Turner
35c4874e8d Add MULTIDELAY to the Beaglebone kenrel config to help moving it to GENERIC. 2017-06-03 15:40:34 +00:00
Andrew Turner
b32611238e Enable MULTIDELAY in the i.MX5 kernel configs. This will help adding them
to GENERIC.
2017-06-03 15:39:23 +00:00
Andrew Turner
62e2e02278 Remove RT1310 from universe as it fails to build. 2017-06-03 14:45:46 +00:00
Andrew Turner
5dc97550fb Mark the non-INTRNG armv6 configs with NO_UNIVERSE to prepare for INTRNG
being always enabled on armv6.
2017-06-03 10:38:41 +00:00
Wojciech Macek
e6a54e228a Enable wireless Atheros cards in ARMADA38X
Submitted by:   Bartosz Szczepanek <bsz@semihalf.com>
                Dominik Ermel <der@semihalf.com>
Obtained from:  Semihalf
Sponsored by:   Stormshield
Differential revision: https://reviews.freebsd.org/D10904
2017-05-29 09:20:20 +00:00
John Baldwin
1ec22b4425 Exclude ccr(4) from arm LINT since it excludes cxgbe(4). 2017-05-19 22:54:45 +00:00
Luiz Otavio O Souza
018101a836 Add the Marvell SDHCI controller to the list of supported devices in
sdhci_fdt.

Enable the SDHCI controller, bus and devices on ARMADA38X kernel.

Tested on:	ClearFog Pro
Reviewed by:	Marcin Wojtas <mw at semihalf.com>
Sponsored by:	Rubicon Communications, LLC (Netgate)
Differential Revision:	https://reviews.freebsd.org/D10606
2017-05-16 05:10:15 +00:00
Luiz Otavio O Souza
34238cb7b3 Disable the build of the static/embedded DTB for the ARMADA38X kernel.
Build the supported DTBs as part of modules build.

MFC after:	2 weeks
Sponsored by:	Rubicon Communications, LLC (Netgate)
2017-05-09 18:12:05 +00:00
Michal Meloun
39d24078f8 Revert accidentally changed std.armv6 in r318024.
MFC with:	r318024
MFC after:	2 weeks
2017-05-09 12:32:31 +00:00
Michal Meloun
19600bd917 Fix _Unwind_Backtrace symbol version for ARM.
In real GNU libgcc, _Unwind_Backtrace is published with GCC_3.3 version
for all architectures but ARM. For ARM it's publishes with GCC_4.3.0
version.
This exception is not implement in your version of libggc, thus we
export _Unwind_Backtrace with bad version. To maintain backward
compatibility, publish _Unwind_Backtrace twice, once as compatible
symbol with GCC_3.3 version, and once as default symbol with
GCC_4.3.0 version.

While I'm in, fix typo in GCC_4.2.0 to GCC_4.3.0 inheritance declaration.

MFC after:	2 weeks
2017-05-09 12:14:00 +00:00
Adrian Chadd
5c99cda025 [arm] [rt1310] add initial RT1310 SoC code.
This code base on lpc code. Ralink RT1310 is oem from 5V Technologies.
RT1310 is ARM926EJS(arm5t).

Tested:

* Buffalo WZR2-G300N

Submitted by:	Hiroki Mori <yamori813@yahoo.co.jp>
Reviewed by:	mizhka
Differential Revision:	https://reviews.freebsd.org/D7238
2017-05-06 06:14:46 +00:00
Zbigniew Bodek
3d9dcb4574 Add PL310 device in ARMADA38X config
Submitted by: Arnaud Ysmal <arnaud.ysmal@stormshield.eu>
Obtained from: Stormshield
Sponsored by: Stormshield
Differential revision: https://reviews.freebsd.org/D10222
2017-04-18 10:35:30 +00:00
Zbigniew Bodek
c7df7863ae Reduce kmem_arena maximum size for Armada38x
VM_KMEM_SIZE_MAX allows to limit kmem arena size. In our case this was
necessary, as decreasing size of kmem_arena leaves more space for
kernel_arena.

kernel_arena is pool used for contigmalloc (in effect, DMA) allocations,
which failed on Armada38x. This resulted in 'no memory errors'
(e.g. USB_ERR_NOMEM errors) and failure of whole system. The need for
greater size of kernel_arena probably comes from more peripherals making
use of busdma.

Value used as upper limit is half of the default value
(0x1399a000).

Submitted by: Wojciech Macek <wma@semihalf.com>
Obtained from: Semihalf
Sponsored by: Stormshield
Differential revision: https://reviews.freebsd.org/D10216
2017-04-18 10:20:42 +00:00
Andrew Turner
4bd9887cd5 Port the IMX6 kernel configuration to use MULTIDELAY. This will help adding
the i.MX series of SoCs to the armv6 GENERIC kernel.

This uses updated times from ian@.

Reviewed by:	ian
Sponsored by:	ABT Systems Ltd
2017-04-10 12:35:58 +00:00
Oleksandr Tymoshenko
87d2359388 [versatilepb] Convert VERSATILEPB kernel to INTRNG and switch to upstream DTB
Scope of this change is somewhat larger than just converting to INTRNG.
The reason for this is that INTRNG support required switching from custom
to upstream DTS because custom DTS didn't have interrup routing information.
This switch caused rewrite of PCI and CLCD drivers and adding SCM module.
List of changes in this commit:

- Enable INTRNG and switch to versatile-pb.dts

- Add SCM driver that controls various peripheral devices like LCD or
  PCI controller. Previously registers required for power-up and
  configuring peripherals were part of their respective nodes. Upstream
  DTS has dedicated node for SCM

- Convert PL190 driver to INTRNG

- Convert Versatile SIC (secondary interrupt controller) to INTRNG

- Refactor CLCD driver to use SCM API to power up and configuration

- Refactor PCI driver to use SCM API to enable controller

- Refactor PCI driver to use interrupt map provided in DTS for
  interrupt routing. As a result it fixes broken IRQ routing and
  it's no longer required to run QEMU with "-global versatile_pci.broken-irq-mapping=1"
  command-line arguments
2017-04-01 20:10:08 +00:00
Ed Maste
a3cfc94601 Remove usfs(4) from arm kernel configs
cfumass(4) is not usable if usfs(4) is loaded or compiled into the
kernel. Remove usfs so that the user may kldload the USB mass storage
target they prefer.

PR:		218169
Reviewed by:	trasz, hselasky (no objection)
Relnotes:	Yes
Sponsored by:	The FreeBSD Foundation
Differential Revision:	https://reviews.freebsd.org/D10153
2017-03-28 00:57:33 +00:00
Ian Lepore
d32c1ca43c Add INTRNG option to EFIKA_MX config, it is an imx5-based platform. 2017-03-19 18:38:08 +00:00
Ian Lepore
d32f00077b Remove kernel config for DIGI-CCWMX53 devel board. It was just standard
IMX53 with static dtb added, and now that imx53 can use vendor-supplied dts
files and ubldr, there is no need for a static-dtb variant.
2017-03-19 18:35:20 +00:00
Ian Lepore
cde8ef4d96 Convert the imx5 interrupt controller driver to INTRNG. 2017-03-19 18:30:38 +00:00
Ian Lepore
e04a4275b2 Add dtb/imx5 module build to the imx53 kernel config. 2017-03-19 18:28:38 +00:00
Ian Lepore
76fedc062f Remove kernel config for IMX53-QSB (quickstart board). It was just
standard IMX53 with static dtb added, and now that imx53 can use vendor-
supplied dts files and ubldr, there is no need for a static-dtb variant.
2017-03-19 18:26:52 +00:00
Andrew Turner
0960989f8f Move the IMX6 kernels to use PLATFORM_SMP. This is the last SMP config to
be migrated to this and will allow the removal of this option.

Reviewed by:	ian
Sponsored by:	ABT Systems Ltd
Differential Revision:	https://reviews.freebsd.org/D9907
2017-03-17 12:34:56 +00:00
Ruslan Bukin
6414b02d0c Add SOC_ALTERA_* kernel options per each SoC and use it to
conditionally compile the code.

Reviewed by:	andrew
Sponsored by:	DARPA, AFRL
Differential Revision:	https://reviews.freebsd.org/D9836
2017-02-28 16:20:33 +00:00
Ruslan Bukin
428157830b Add support for Intel Arria 10 SoC Development Kit.
Use standard DTS files for SOCKIT and SOCDK.

Sponsored by:	DARPA, AFRL
2017-02-28 14:02:16 +00:00
Andrew Turner
5267f6243d Add support for PLATFORM and PLATFORM_SMP to the Altera SOCFPGA SoC. This
will help with moving it to GENERIC.

Reviewed by:	br
Sponsored by:	ABT Systems Ltd
Differential Revision:	https://reviews.freebsd.org/D9461
2017-02-07 12:04:04 +00:00
Michal Meloun
93a065e749 Remake support for SMP kernel on UP cpu:
- Use new option SMP_ON_UP instead of (mis)using specific CPU type.
   By this, any SMP kernel can be compiled with SMP_ON_UP support.
 - Enable runtime detection of CPU multiprocessor extensions only
   if SMP_ON_UP option is used. In other cases (pure SMP or UP),
   statically compile only required variant.
 - Don't leak multiprocessor instructions to UP kernel.
 - Correctly handle data cache write back to point of unification.
   DCCMVAU is supported on all armv7 cpus.
 - For SMP_ON_UP kernels, detect proper TTB flags on runtime.

Differential Revision: https://reviews.freebsd.org/D9133
2017-02-02 06:14:44 +00:00
Wojciech Macek
5f55eefb91 Add support for AHCI on ARMADA38X
This file provides support for AHCI mode on Armada38x
and adds new optional AHCI device to arm/mv/files.mv.

Submitted by:          Konrad Adamczyk <ka@semihalf.com>
Obtained from:         Semihalf
Sponsored by:          Stormshield
Reviewed by:           zbb
Differential revision: https://reviews.freebsd.org/D9222
2017-01-25 10:34:37 +00:00
Zbigniew Bodek
b3d8a7757b Include e6000sw driver in ARMADA38X configuration
e6000sw Marvell switch driver was added to files
and Armada38x kernel configuration file.

Submitted by:	Bartosz Szczepanek <bsz@semihalf.com>
Obtained from:	Semihalf
Sponsored by:	Stormshield
Differential revision: https://reviews.freebsd.org/D8178
2017-01-05 17:10:52 +00:00
Emmanuel Vadot
358e989f83 ARM GENERIC: Add support for Allwinner A33 SoC 2017-01-04 03:37:00 +00:00
Michal Meloun
a0a23564a3 Implement drivers for NVIDIA tegra124 display controller, HDMI source
and host1x module. Unfortunately, tegra124 SoC doesn't have 2D acceleration
engine and 3D requires not yet started nouveau driver.

These drivers forms a first non-x86 DRM2 enabled graphic stack.

Note, there are 2 outstanding issues:
 - The code uses gross hack in order to be comply with
   OBJT_MGTDEVICE pager. (See tegra_bo_init_pager() in tegra_bo.c)
 - Due to improper(probably) refcounting in drm_gem_mmap_single()
   (in drm_gem.c), the gem objects are never released.
I hope that I will be able to address both issues in finite time,
but I don't want to touch x86 world now.

MFC after: 1 month
2016-12-26 14:36:05 +00:00
Ganbold Tsagaankhuu
a89938019a Switch Rockchip RK3188 SoC to use the platform code.
Reviewed by:	andrew, manu
Differential Revision:	https://reviews.freebsd.org/D8769
2016-12-13 11:43:46 +00:00