summaryrefslogtreecommitdiffstats
path: root/sys/arch/armv7/omap (follow)
Commit message (Collapse)AuthorAgeFilesLines
* Fix Dale's email addresstb2021-04-021-2/+2
| | | | ok drahn
* remove uneeded includes in md armv7 filesjsg2021-03-2517-79/+17
| | | | based on include-what-you-use suggestions
* spellingjsg2021-03-113-6/+6
|
* timecounting: use C99-style initialization for all timecounter structscheloha2021-02-232-4/+17
| | | | | | | | | | | | | | | | | | The timecounter struct is large and I think it may change in the future. Changing it later will be easier if we use C99-style initialization for all timecounter structs. It also makes reading the code a bit easier. For reasons I cannot explain, switching to C99-style initialization sometimes changes the hash of the resulting object file, even though the resulting struct should be the same. So there is a binary change here, but only sometimes. No behavior should change in either case. I can't compile-test this everywhere but I have been staring at the diff for days now and I'm relatively confident this will not break compilation. Fingers crossed. ok gnezdo@
* s/KHZ/kHz/ and reduce dmesg spam a bitkettenis2021-01-195-12/+12
| | | | ok tb@, deraadt@
* Remove some unused #defines and remove some commented-out variables.kettenis2021-01-191-6/+1
|
* Extend the interrupt API on arm64 and armv7 to be able to pass aroundpatrick2020-07-142-10/+16
| | | | | | | | | | | | | | | | | | | | | | | | a struct cpu_info *. From a driver point of view the fdt_intr_establish_* API now also exist same functions with a *_cpu suffix. Internally the "old" functions now call their *_cpu counterparts, passing NULL as ci. NULL will be interpreted as primary CPU in the interrupt controller code. The internal framework for interrupt controllers has been changed so that the establish methods provided by an interrupt controller function always takes a struct cpu_info *. Some drivers, like imxgpio(4) and rkgpio(4), only have a single interrupt line for multiple pins. On those we simply disallow trying to establish an interrupt on a non-primary CPU, returning NULL. Since we do not have MP yet on armv7, all armv7 interrupt controllers do return NULL if an attempt is made to establish an interrupt on a different CPU. That said, so far there's no way this can happen. If we ever gain MP support, this is a reminder that the interrupt controller drivers have to be adjusted. Prompted by dlg@ ok kettenis@
* Use the full 32 bits for the miscellaneous armv7 timecounters.naddy2020-07-121-2/+2
| | | | | | | | | Checked against * ARM Architecture Reference Manual (agtimer) * ARM Cortex-A9 MPCore Technical Reference Manual (amptimer) * OMAP35x Applications Processor Technical Reference Manual (gptimer) Artturi Alm had independently suggested this in the past.
* Change users of IFQ_SET_MAXLEN() and IFQ_IS_EMPTY() to use the "new" API.patrick2020-07-101-3/+3
| | | | ok dlg@ tobhe@
* Change users of IFQ_DEQUEUE(), IFQ_ENQUEUE() and IFQ_LEN() to use thepatrick2020-07-101-2/+2
| | | | | | "new" API. ok dlg@ tobhe@
* Add support for timeconting in userland.pirofti2020-07-061-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | This diff exposes parts of clock_gettime(2) and gettimeofday(2) to userland via libc eliberating processes from the need for a context switch everytime they want to count the passage of time. If a timecounter clock can be exposed to userland than it needs to set its tc_user member to a non-zero value. Tested with one or multiple counters per architecture. The timing data is shared through a pointer found in the new ELF auxiliary vector AUX_openbsd_timekeep containing timehands information that is frequently updated by the kernel. Timing differences between the last kernel update and the current time are adjusted in userland by the tc_get_timecount() function inside the MD usertc.c file. This permits a much more responsive environment, quite visible in browsers, office programs and gaming (apparently one is are able to fly in Minecraft now). Tested by robert@, sthen@, naddy@, kmos@, phessler@, and many others! OK from at least kettenis@, cheloha@, naddy@, sthen@
* match on "ti,am335-sdhci" used since linux 5.8-rc3jsg2020-07-051-3/+5
|
* use correct node when enabling phyjsg2020-06-021-3/+2
| | | | ok kettenis@
* dev/rndvar.h no longer has statistical interfaces (removed during variousderaadt2020-05-291-2/+1
| | | | | | conversion steps). it only contains kernel prototypes for 4 interfaces, all of which legitimately belong in sys/systm.h, which are already included by all enqueue_randomness() users.
* change wsdisplay attribute type from long to uint32_tjsg2020-05-252-6/+6
| | | | | | | | miod explained it was initially a long as it was thought drivers may need to allocate storage but in practice they don't need more than 32 bits for an attribute. suggested and reviewed by miod@
* rename wsdisplay alloc_attr() to pack_attr()jsg2020-05-251-2/+2
| | | | | | | | Suggested by John Carmack. miod agrees a rename would make sense and explained it was initially thought drivers may need to allocate storage but in practice they don't need more than 32 bits for an attribute. ok mpi@
* fix SDHC_DEBUG build, remove procname printf'sians2020-04-271-5/+4
| | | | ok kettenis@
* Add omcm(4), omclock(4) and omsysc(4) drivers that support the new buskettenis2020-04-107-11/+323
| | | | | | structure that is used in current mainline Linux device trees. ok jsg@
* Use PHY framework to replace hardcoded board-specific GPIO poking.kettenis2020-04-071-67/+5
| | | | ok jsg@
* Remove entry that is no longer needed.kettenis2020-04-071-28/+1
| | | | ok jsg@
* Add support for the cd-gpios property.kettenis2020-04-061-1/+23
| | | | ok jsg@
* Register controller with the gpio "framework".kettenis2020-04-061-1/+61
| | | | ok jsg@
* Use OF_is_compatible() to simplify the initialization for the "mdio" node.kettenis2020-04-051-10/+6
| | | | | | Add code to enable the clock which is present in new device trees. ok jsg@
* Add omrng(4), a driver for te random number generator found on TI OMAP SoCs.kettenis2020-04-055-4/+170
| | | | ok jsg@
* Remove leftover that should have been removed in the previous commit.kettenis2020-03-311-3/+1
|
* Newer device trees no longer put the full physical address in the "reg"kettenis2020-03-311-4/+9
| | | | | | | | property; it contains on offset in the parent's address space instead. Since the driver needs the address of the CPPI RAM to program the descriptors, use bus_space_vaddr(9) and pmap_extract(9) to get it. ok jsg@
* Remove unused code. The padconf code has been replaced with thekettenis2020-03-317-959/+3
| | | | | | | generic pinctrl(4) driver and intc(4) now attaches using the device tree. ok jsg@
* Cleanup <sys/kthread.h> and <sys/proc.h> includes.mpi2020-02-181-2/+1
| | | | | | | Do not include <sys/kthread.h> where it is not needed and stop including <sys/proc.h> in it. ok visa@, anton@
* Convert to tsleep_nsec(9), while here fix a bug where the value specifiedmpi2020-01-131-4/+5
| | | | | | in ticks was meant to be in msecs. Pointed out by and ok patrick@
* Timeouts are all specified in multiple of `hz' so define them in term ofmpi2020-01-131-7/+7
| | | | | | seconds and use tsleep_nsec(9). ok patrick@
* WSDISPLAYIO_GTYPE is u_int not intjsg2019-12-251-2/+2
|
* Use mask to extract IPL; should have been part of the earlier diff thatkettenis2019-10-051-2/+2
| | | | added IPI support on armv7.
* Whitespace removalmlarkin2019-05-0612-41/+41
| | | | Pointed out by Jerome Pinot
* Whitespace and extra semicolon removal.mlarkin2019-05-061-2/+2
| | | | Pointed out by Jerome Pinot
* KNF per naddy@ians2019-04-101-8/+22
|
* Adjust cpsw for linux 4.20 device tree changes. The location of the phyjsg2018-12-241-2/+9
| | | | is now found via phy-handle instead of phy_id.
* Free edid_buf after use so to fix possible memory leak.claudio2018-09-191-2/+3
| | | | With and ok jsg@
* ompinmux has been replaced by pinctrljsg2018-08-272-142/+1
|
* prune files.* entries that refer to files not in treejsg2018-02-141-15/+1
| | | | ok krw@ mpi@
* OMAP4 has two watchdog timers timer 2/MPU and timer 3/IVA.jsg2017-11-271-2/+7
| | | | | | | | | Previously the device tree only described one but now it describes both. Do not attempt to set the global variable that points to a softc or register a watchdog if this has already been done. Fixes rebooting on the OMAP4 based PandaBoard-ES with a device tree from linux 4.15-rc1.
* Storing the address of a stack variable in a global variable is a bad idea.kettenis2017-10-251-15/+9
| | | | | | | | Rework the code to store the relevant information in the softc. As a bonus, this reduces the stack space that is used such that this file compiles with clang. ok ians@
* Avoid using an uninitialised variable. Found by the clang static analyser.jsg2017-09-111-2/+2
| | | | ok ians@
* Don't test if an array is NULL. Fixes the build with clang which raisedjsg2017-09-111-2/+2
| | | | | | a -Wtautological-pointer-compare warning. ok ians@
* If you use sys/param.h, you don't need sys/types.hderaadt2017-09-089-18/+9
|
* Add OpenBSD CVS tags at the top of amdisplay/nxphdmi(4) files.ians2017-08-314-0/+4
| | | | thanks Artturi Alm, ok patrick@
* change email address in licenses to ians@openbsd.orgians2017-08-184-4/+4
|
* Convert to FDT-based interrupt establish API.patrick2017-08-151-4/+3
|
* Apply KNF and fix whitespaces.patrick2017-08-151-44/+43
|
* Apply KNF and fix whitespaces.patrick2017-08-152-102/+100
|
* Add the amdisplay(4) and nxphdmi(4) drivers.ians2017-08-148-5/+1655
| | | | ok kettenis@ patrick@