summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
...
* | Make the probe routine fail when no compatible is found.Luiz Souza2017-06-221-0/+2
| |
* | Convert gpioc to use the make_dev_s(9) KPI. This fix a possible race whereloos2017-06-221-5/+12
| | | | | | | | | | | | | | | | | | | | si_drv1 can be accessed before it gets set. This is inspired on r311700. MFC after: 3 days (cherry picked from commit bc99dd22606c6c602e681adfff2b42db0158e7d6)
* | Add initial support to is31fl319x RGB LED driver.Luiz Souza2017-06-203-0/+436
| |
* | Add initial GPIO PWM support.Luiz Souza2017-06-206-15/+245
| |
* | Add support for the PCA9552 16-bit LED driver with programmable blink rates.Luiz Souza2017-06-203-0/+457
| |
* | Always ignore the START and STOP bits whenever the control register isloos2017-06-201-4/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | being overwritten, they are set only bits (cleared by hardware). Disable the Acknowledge of the controller slave address. The slave mode is not supported. Make sure the interrupt flag bit is being cleared as recommended, add a delay() _after_ clear the interrupt bit. Sponsored by: Rubicon Communications, LLC (Netgate) (cherry picked from commit a514510c057d6d853efa9c9558112f91760688ad)
* | Make ofw_iicbus attach to twsi I2C controllers.loos2017-06-202-1/+15
| | | | | | | | | | | | | | | | | | Add the ofw_bus_get_node() callback in mv_twsi, it is mandatory for the ofw_iicbus usage. Sponsored by: Rubicon Communications, LLC (Netgate) (cherry picked from commit 63d5603d622c5bb69f74644f066faa68709e87fb)
* | Add support to 2.5G uplink for the MV88E6141 and MV88E6341 switches.loos2017-06-202-43/+111
| | | | | | | | | | | | | | | | | | Force the switch port settings for fixed media types. Tested with: 88E6176, 88E6141 Sponsored by: Rubicon Communications, LLC (Netgate) (cherry picked from commit 3ba75ba1dd1d3a57786548860363a11f012f78c6)
* | Prevent multiple lock initialization in e6000sw probezbb2017-06-191-3/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | r319886 ("Add the initial support for the Marvell 88E6141 and 88E6341 switches.") unveiled a problem with possible multiple lock creation. Move its initialization to the driver attach and for obtaining the switch ID create a temprorary one, which is immediately destroyed after the check. Submitted by: Zbigniew Bodek <zbb@semihalf.com> Marcin Wojtas <mw@semihalf.com> Obtained from: Semihalf (cherry picked from commit de899400f853ef674c219fd03a48215aadbcf647)
* | Add the initial support for the Marvell 88E6141 and 88E6341 switches.loos2017-06-191-18/+66
| | | | | | | | | | | | | | | | | | | | | | | | Right now the driver only supports port VLANs, so make sure etherswitch_getinfo() return the proper switch capabilities. Handle the cases where not all ports are in use (that will also require etherswitch cooperation). Sponsored by: Rubicon Communications, LLC (Netgate) (cherry picked from commit c91f28aeedeb85cccd12ab1a8af23675a563b6fe)
* | [etherswitch] add in an initial API for controlling per-port LED behaviour.adrian2017-06-195-4/+146
| | | | | | | | | | | | | | | | This is just implemented for the AR8327 for now. Submitted by: Dan Nelson <dnelson_1901@yahoo.com> (cherry picked from commit d57c6dcdab1f6ac68de08e6d3bcc58ba374afbb2)
* | Convert etherswitch to use the make_dev_s(9) KPI. This fix a possible raceloos2017-06-191-6/+13
| | | | | | | | | | | | | | | | | | | | where si_drv1 can be accessed before it gets set. MFC after: 3 days Suggested by: kib Sponsored by: Rubicon Communications, LLC (Netgate) (cherry picked from commit 5ff8fca6052cd72049ea8ddc53ba5c053a6990aa)
* | Allow simultaneous access to switch device, there is no reason to preventloos2017-06-191-2/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | it. Remove bogus wrappers and use the kernel defaults. While here, use DEVMETHOD_END. Obtained from: pfSense MFC after: 2 weeks Sponsored by: Rubicon Communications, LLC (Netgate) (cherry picked from commit d326b0be0ed381687423602f4beefdfa386c24fa)
* | Remove an unnecessary variable from the switch softc structure and make theloos2017-06-101-19/+22
| | | | | | | | | | | | | | | | functions that are used as booleans return real boolean values. Sponsored by: Rubicon Communications, LLC (Netgate) (cherry picked from commit 0241533b047cb699a0736699204be77d47404608)
* | style(9) fixes, remove unnecessary headers, remove duplicate #defines andloos2017-06-102-136/+88
| | | | | | | | | | | | | | | | | | | | in some cases, shuffle the code around to simplify locking. No functional changes. Sponsored by: Rubicon Communications, LLC (Netgate) (cherry picked from commit 228e64ca6d855785d04d95b1dbab516e0cdcc2ef)
* | Poll PHY status using internal e6000sw registerswma2017-06-102-6/+53
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | e6000sw family automatically reflects PHY status in each port's registers. Therefore it is not necessary to do a full PHY polling squence, which results in much quicker operation and much less significant usage of the SMI bus. Care must be taken that the resulting ifmedia_active is identical to what the PHY will compute, or gratuitous link status changes will occur whenever the PHYs update function is called. This patch implements above improvement. On the occasion set a pointer to the proc structure to be part of software context instead of being a global variable. Submitted by: Marcin Wojtas <mw@semihalf.com> Obtained from: Semihalf Sponsored by: Stormshield Reviewed by: loos Differential revision: https://reviews.freebsd.org/D10714 (cherry picked from commit 63843c9be40aba2fb7e803960fb7d4fcee1d3eeb)
* | Improve busy-wait loop during switch phy access in e6000swwma2017-06-101-8/+39
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Hitherto implementation of PHY polling resulted in a risk of an endless loop and very high occupation of the SMI bus. Improve the operation by limiting the polling tries and adding sleepable pause. Submitted by: Marcin Wojtas <mw@semihalf.com> Obtained from: Semihalf Sponsored by: Stormshield Reviewed by: loos Differential revision: https://reviews.freebsd.org/D10713 (cherry picked from commit b854df5591d7a547679e3e8ee25f39492442b21f)
* | Add missing unlock in e6000sw driverzbb2017-06-101-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | This patch adds missing unlock on attach failure. Submitted by: Zbigniew Bodek <zbb@semihalf.com> Obtained from: Semihalf Sponsored by: Stormshield Reviewed by: loos Differential revision: https://reviews.freebsd.org/D10712 (cherry picked from commit 13060c90f906f6feb26bdfb2f1b8304de0f6886a)
* | Fix broken malloc in e6000swzbb2017-06-101-2/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Malloc should always return something when M_WAITOK flag is used, but keep this code and change flag to M_NOWAIT as it is under a lock (allows for possible future change). Free ifnet structure to avoid memory leak on failure. Submitted by: Zbigniew Bodek <zbb@semihalf.com> Obtained from: Semihalf Sponsored by: Stormshield Reviewed by: loos Differential revision: https://reviews.freebsd.org/D10711 (cherry picked from commit 9701ccf52d7dd27cf6b73be152060fa3983afbee)
* | When the switch is set to operate in the Multi Chip Addressing Mode weloos2017-06-101-13/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | cannot access the GLOBAL2 register directly. Despite the comment in code (which was misleading), the indirect access is only used to read the switch CONFIG data from the scrap register and not for the GLOBAL2 access. Use the dsa data to define when the switch is in the Multi Chip Addressing Mode (a even address different than zero). While here fix a typo. Sponsored by: Rubicon Communications, LLC (Netgate) (cherry picked from commit b0b3a756887e79e36f010e8aaa8f3032d73e1f7c)
* | Improve ports handling in e6000sw driverzbb2017-06-102-80/+286
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - recognize ports and vlangroups based on DTS file - support multi-chip addresing mode (required in upcoming Armada-388-Clearfog support) - refactor attachment function Each port in 'dsa' node should have 'vlangroup' property. Otherwise, e6000sw will fail to attach. Submitted by: Bartosz Szczepanek <bsz@semihalf.com> Konrad Adamczyk <ka@semihalf.com> Obtained from: Semihalf Sponsored by: Stormshield Differential revision: https://reviews.freebsd.org/D7328 (cherry picked from commit 33ec32197181bff1a652a23fd0a470589ca1a520)
* | Add a bitmask field to keep the enabled ports of a switch, not all switches ↵Luiz Souza2017-06-092-0/+16
| | | | | | | | | | | | will use all the ports, so looping on all ports starting from port 0 was wrong, this commit fixes it. This is an optional feature, so there is now a switch capabilities to keep the state and availability of optional switch features.
* | Add the Denverton HSUART device ID.Luiz Souza2017-06-041-0/+2
| |
* | MFC r312346:loos2017-05-241-2/+6
| | | | | | | | | | | | | | | | | | | | Set the the wp_disabled flag when asked to. While here, add the missing new line. Sponsored by: Rubicon Communications, LLC (Netgate) (cherry picked from commit 1cdfa4777c42f16b131b55a08365ec7cbc84ac7b)
* | Persistently store NIC's hardware MAC address, and add a way to retrive itrpokala2017-05-191-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | jhb pointed out that (struct ifnet) is part of the network driver KBI, and thus the offsets of internal fields must not change. Therefore, move the new "if_hw_addr" field to the end, and consume one of the "if_pspare"s; that's what they're there for. The new field replaces the *last* element of that array; that way, offsetof(if_pspare) and offsetof(if_ispare) are unchanged compared to before r318397. PR: 194386 Reviewed by: jhb Pointyhat to: rpokala Sponsored by: Panasas (cherry picked from commit 53168a58b2d5e27ea918b00e0398e6629c91864c)
* | MFC r308187, r311660, r311693, r311727, r311797:ian2017-05-123-38/+110
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Toggle card insert/remove interrupt enable bits on events. Add a new sdhci interface method, get_card_present(). Now that the PRESENT_STATE register is only used for the inhibit bits loop in this function, sdhci_start_command(), eliminate the state variable and restructure the loop to read the register just once at the top of the loop. Add support for non-removable media, and a quirk to use polling to detect card insert/remove events on controllers that don't implement the insert and remove interrupts. Add sdhci_handle_card_present_locked() that can be called from the interrupt handler which already holds the mutex, and have sdhci_handle_card_present() be just a tiny wrapper that does the locking for external callers. (cherry picked from commit 6868bda4bad5820f9bb79562db7184320af04c30)
* | Revert this change.Luiz Souza2017-05-111-1/+1
| |
* | Export more information about ARM CPUs and SoCs.Luiz Souza2017-05-113-11/+30
| |
* | Remove the extra '\n' at end of the sysctl string.Luiz Souza2017-05-111-1/+1
| |
* | Fix hw.model sysctl on ARM.Luiz Souza2017-05-111-9/+7
| |
* | Persistently store NIC's hardware MAC address, and add a way to retrive itrpokala2017-05-111-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | An earlier version of r318160 allocated if_hw_addr unconditionally; when it became conditional, I forgot to check for NULL in ether_ifattach(). Reviewed by: kp MFC after: 1 week MFC with: r318160 Sponsored by: Panasas Differential Revision: https://reviews.freebsd.org/D10678 Pointy-hat to: rpokala (cherry picked from commit 22bc11147b048ef4ae05cca49ca9c6baf8fe9993)
* | Persistently store NIC's hardware MAC address, and add a way to retrive itrpokala2017-05-115-1/+83
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The MAC address reported by `ifconfig ${nic} ether' does not always match the address in the hardware, as reported by the driver during attach. In particular, NICs which are components of a lagg(4) interface all report the same MAC. When attaching, the NIC driver passes the MAC address it read from the hardware as an argument to ether_ifattach(). Keep a second copy of it, and create ioctl(SIOCGHWADDR) to return it. Teach `ifconfig' to report it along with the active MAC address. PR: 194386 Reviewed by: glebius MFC after: 1 week Sponsored by: Panasas Differential Revision: https://reviews.freebsd.org/D10609 (cherry picked from commit 0cfdb3c3056d9ea5b7a14292e663a5a0afd1f5a4)
* | Merge remote-tracking branch 'origin/releng/11.0' into RELENG_2_4Renato Botelho2017-05-11411-73546/+16368
|\ \ | |/
| * Fix ipfilter(4) fragment handling panic.delphij2017-04-273-2/+6
| | | | | | | | | | Security: FreeBSD-SA-17:04.ipfilter Approved by: so
| * Fix multiple vulnerabilities of ntp. [SA-17:03]delphij2017-04-12410-73545/+16363
| | | | | | | | | | | | Xen migration enhancements. [EN-17:05] Approved by: so
* | Reimplement the commit 3a10a90e55b9cd00bf9c1343ff5df940cdd16a19 to export ↵Luiz Souza2017-05-091-1/+13
| | | | | | | | the ARM CPU model as hw.model.
* | MFC r304285:kib2017-05-0924-171/+246
| | | | | | | | | | | | Implement userspace gettimeofday(2) with HPET timecounter. (cherry picked from commit dddfacf75a4db48e5a557d2ca395fcf246f37b70)
* | MFC r303548:kib2017-05-091-10/+8
| | | | | | | | | | | | Cache getbintime(9) answer in timehands. (cherry picked from commit 5557ede983360bb766926977b87aff4d9272febb)
* | MFC r303382:kib2017-05-0916-52/+140
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Provide the getboottime(9) and getboottimebin(9) KPI. MFC r303387: Prevent parallel tc_windup() calls. Keep boottime in timehands, and adjust it from tc_windup(). MFC notes: The boottime and boottimebin globals are still exported from the kernel dyn symbol table in stable/11, but their declarations are removed from sys/time.h. This preserves KBI but not KPI, while all in-tree consumers are converted to getboottime(). The variables are updated after tc_setclock_mtx is dropped, which gives approximately same unlocked bugs as before. The boottime and boottimebin locals in several sys/kern_tc.c functions were renamed by adding the '_x' suffix to avoid name conficts. (cherry picked from commit 5eaf5813abcaf71c35e1006aab0a861cd104f3aa)
* | MFC r303384:kib2017-05-091-2/+2
| | | | | | | | | | | | Style. (cherry picked from commit d2bf5cdb2ac14be8bf1ba76be358e7043e191610)
* | MFC r303383:kib2017-05-091-18/+8
| | | | | | | | | | | | Reduce number of timehands to just two. (cherry picked from commit fab6e3490fccc1cdec8af77e3ad6ed000a7ed4e6)
* | MFC r313933, r313939, r313966:kib2017-05-083-9/+8
| | | | | | | | | | | | | | Microoptimize pmap_protect_pde() on amd64, i386 and pmap_protect_pte1() on armv6. (cherry picked from commit 9819b36e61acfd5bb1d5649008d08e8a4426eb55)
* | MFC r308569,r308570:skra2017-05-081-15/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | r308569: Always call PHYS_TO_VM_PAGE() in is_managed(). Fast road for addresses under first_page cannot be taken as this variable is connected only to vm_page_array segment. There could be more segments in system like the ones for various fictitious page ranges. These can be situated under vm_page_array segment and so, they could be skipped before this fix. However, as far as I know, there is no report associated with it. r308570: The return type of is_managed() was changed from boolean_t to bool type in r308569. Now, propagate this change further for consistency sake. (cherry picked from commit 28e785bd9db197f512ffc1a04b12abc7282958b0)
* | MFC r315900,r315973,r315974:mmel2017-05-0810-221/+221
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | r315900: Cleanup structures related to VFP and/or mcontext_t. - in mcontext_t, rename newer used 'union __vfp' to equaly sized 'mc_spare'. Space allocated by 'union __vfp' is too small and cannot hold full VFP context. - move structures defined in fp.h to more appropriate headers. - remove all unused VFP structures. r315973: Save VFP state on fork(). Update the copy of VFP state in PCB before it is cloned for new process. r315974: Preserve VFP state across signal delivery. (cherry picked from commit 2d4b5ed3310ee2a108a26c0817ed03a5aeb0874d)
* | MFC r303261,r315059:mmel2017-05-0812-886/+1039
| | | | | | | | | | | | | | | | | | | | r303261: Add more UEFI/e820 memory types from latest specifications. r315059: Split overbloated machep.c to multiple files and do basic cleanup of these fragments. (cherry picked from commit 2589e5f69f04cfa8fcf63ea99bd8a5914762ab67)
* | MFC r306704,r308406:mmel2017-05-083-15/+6
| | | | | | | | | | | | | | | | | | r306704: ARM: Remove next bunch of unused cpu_functions from ARMv6. r308406: Only include sys/boot.h if LINUX_BOOT_ABI is defined (cherry picked from commit 2f97dffc6bbcc68082bbc2eeb847ee0f688fb86d)
* | MFC r306631,r306640,r306641,r306650,r306656:mmel2017-05-084-119/+44
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | r306631: Use C99 designated initializers to create the armv6 cpu_functions structs. This will help with a later cleanup of what functions we implement. r306640: Only define the CF_* macros on ARMv4/v5. They are unused on armv6. r306641: Remove the parts of cpu_functions from armv6 that are unused on that architecture. r306650: Add the Cortex-A{53,57,72} ID register values. These can all run 32-bit code so could run a 32-bit kernel. r306656: Use the cortex functions when booting on one of the Cortex-A ARMv8 CPUs. This list is incomplete, however we don't have the ID values for the missing Cortex-A32 or A35. (cherry picked from commit 494cee5e42e008efa706b7e2a8495c4f3c25b691)
* | MFC r310189:ian2017-05-081-1/+1
| | | | | | | | | | | | | | Fix sscanf() format string to match an argument. This also fixes kernel build after r310171. (cherry picked from commit 543014be4d5e27cffeb396b9b307d7b72d3f35e1)
* | MFC r312292, r313573:ian2017-05-0813-208/+28
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Stop including sys/types.h from arm's machine/atomic.h, fix the places where atomic.h was being included without ensuring that types.h (via param.h) was included first, as required by atomic(9). Remove arm's cpuconf.h, and references to it, after moving a few lines from it into pmap-v4.h where they are used. Other than those few lines of support for different MMU types, nothing in cpuconf.h has been used in our code for quite a while. The file existed to set up a variety of symbols to describe the architecture. Over the past few years we have converted all of our source to use the new architecture symbols standardized by ARM Inc, and predefined by both clang and gcc. (cherry picked from commit acd168923c104fa26f6d48db142fa778b5cbc7b1)
* | MFC r312251:ian2017-05-081-4/+0
| | | | | | | | | | | | | | Remove a bit of armv6 support that didn't get deleted when this file was split from trap.c into trap-v4.c and trap-v6.c. (cherry picked from commit 15dbec6aad227bffd6f15e2b6dd76a618e2528b2)
OpenPOWER on IntegriCloud