summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* Add testing utility for behavior of atomic ops.ed2013-06-082-0/+135
| | | | | | | This small utility performs a sequence of atomic operations with random parameters on an atomic variable. For every type, we also create 16 variables, to ensure that we test the correctness at different alignments.
* Fix a bug introduced with r251190, in which a small hunk was forgotten indteske2013-06-081-1/+2
| | | | | | | | | | | | | | | | | | | | | the performance conversion process. The effect of this was the following error when selecting the menu "Startup"->"View/Edit Startup Configuration"->"Add New"->"Add From List": [: -eq: unexpected operator By running `bsdconfig -d' as root to enable debugging, this turns into: DEBUG: f_getvar: var=[text] value=[ Error: Expected a number for token 4 of --menu. Use --help to list options.] r=0 [: -eq: unexpected operator Indicating that the fourth token for --menu which should be $height was instead a string (the first item of $menu_list) because it was using the old size-calculation method and $size was now null (needed to use instead the new size variables of $height $width and $rows).
* Fix a bug introduced with r249751, in which a small hunk was forgotten indteske2013-06-081-1/+5
| | | | | | | | | the performance conversion process. The effect of this was, when your /etc/defaults/rc.conf file changed (based on md5(1)) and re-generating the file startup_rcconf_map.cache in /var/run/bsdconfig/ you would get a screen-dump of its contents before the menu would appear.
* Fix a typo in comments.dteske2013-06-081-1/+1
|
* Don't silently ignore errors (found whiledteske2013-06-081-8/+11
| | | | testing with `chflags schg /etc/ttys).
* Prevent getting hung-up on the following prompt (found while testing withdteske2013-06-081-1/+1
| | | | | | | | `chflags schg /etc/ttys'): override rw-r--r-- root/wheel for /etc/ttys? (y/n [n]) Simply by adding `-f' flag to mv(1).
* Fix a one-character typo. The effects of which were "Console"->"Ttys" menudteske2013-06-081-1/+1
| | | | | | | | | | | | would not launch (and gave no error). This was easily diagnosed by running `bsdconfig -d' as root and seeing the following error right after selecting the "Ttys" sub-menu: DEBUG: f_getvar: var=[text] value=[ Error: Expected at least 6 tokens for --menu, have 4. Use --help to list options.] r=0 Typo was introduced by SVN r251361.
* Add 8devices CARAMBOLA2 support.adrian2013-06-082-0/+162
| | | | | | | | | | This is based on the AR933x (Hornet) SoC from Qualcomm Atheros. It's a much nicer board to do development on - 64MB RAM, 16MB flash. The development board breaks out the GPIO pins, ethernet, serial (via a USB<->RS232 chip), USB host and of course a small wifi antenna. Everything but the wifi works thus far.
* Add support for two new winbond SPI flash parts.adrian2013-06-081-1/+5
| | | | | | | | | | | | | | The 8devices carambola 2 board uses the 16MB part. Here's how it looks: spibus0: <spibus bus> on spi0 mx25l0: <M25Pxx Flash Family> at cs 0 on spibus0 mx25l0: w25q128, sector 65536 bytes, 256 sectors Tested: * 8devices Carambola 2 board
* Add a prompt to the "Add User" and "Add Group" sub-menu items (under thedteske2013-06-083-34/+64
| | | | | | | | | | "Login Management" module): Use default values for all account details? If you select "Yes" (the default is "No"), you'll jump past all the prompts and jump straight to the review screen with all-default values. Makes adding a lot of users/groups faster/easier if you don't need to customize more than one or two different values from their defaults.
* Minor markup.pluknet2013-06-081-2/+2
|
* Curb another regression (this one introduced by r251545, itself trying todteske2013-06-082-6/+14
| | | | | | | | | | | | | | fix the regression introduced by r251544; which was trying to make things consistent w/respect to ESC versus YES versus NO in the password disable prompt in "Login Management". (need stronger coffee; very sorry for the churn) With this revision, the "YES", "NO", and implied ESC options all work as- expected. Choosing "YES" allows you to proceed and the password will be disabled. Choosing "NO" will bring back around to enter a password for the account. Pressing ESC will drop you out of either user or group input and back to the usermgmt screen.
* Update locking scheme, mostly transition from sched_lock.pluknet2013-06-081-22/+14
|
* Fix a regression introduced by r251544; if user chooses "NO" when beingdteske2013-06-082-0/+2
| | | | | asked if they would like to disable password authentication for the account, loop back to prompt them for the password again.
* Check for ESC as a separate choice from "NO" when asking if the operatordteske2013-06-082-8/+8
| | | | | | | | | | | | | would like to disable password management for an account while adding either a user or group. When being prompted to answer questions while adding a group or user, two things are trow: 1. You can hit ENTER to blast through all the questions and in the end, the group or user is created with sensible defaults for all values. 2. You can press ESC during any prompt to cancel the operation as a whole. This fix is shoring up an inconsistency in the latter (#2).
* Track defaultitem in the password and account expiry menus; if the userdteske2013-06-081-2/+6
| | | | | presses ESC or chooses Cancel/No in any of the sub-menus, we want to return to the expiry menu with that item selected.
* Fix a regression in the "Login Management" module introduced by r251242 indteske2013-06-081-4/+8
| | | | | | which choosing to cancel the manual input of expiration time (in seconds since the UNIX epoch) for either account expiration or password expiration would see the original value lost.
* Reduce verbosity in the "Console"->"Saver" module (bsdconfig syscons_saver)dteske2013-06-081-1/+1
| | | | | | | by replacing the infinitive [verb] phrase "Simply blank the screen" with a simple description of what you get; "Blank screen". PR: ports/169316
* Remove extraneous characters ('<<<') from `Exit' menutag in the "Security"dteske2013-06-082-4/+4
| | | | | | | and "Startup"->"Misc" modules to make the menus appear more consistent with the numerous other modules and look a little cleaner. PR: ports/169316
* Actually make the 2-byte atomics work.ed2013-06-081-33/+87
| | | | | | | | | Even though I tested the 1-byte operations on arbitrarily aligned bytes, it seems I did not do this for the 2-byte operations. Create easy to read functions that are used to get/put bytes and halfwords in words. To keep the compiler happy, explicitly read two bytes into a union to obtain a 16-bit value.
* Import Kevin Lo's port of urtwn(4) from OpenBSD. urtwn(4) is a driver for therpaulo2013-06-089-1/+5132
| | | | | | | | | | | | | | | | | | Realtek RTL8188CU/RTL8192CU USB IEEE 802.11b/g/n wireless cards. This driver requires microcode which is available in FreeBSD ports: net/urtwn-firmware-kmod. Hiren ported the urtwn(4) man page from OpenBSD and Glen just commited a port for the firmware. TODO: - 802.11n support - Stability fixes - the driver can sustain lots of traffic but has trouble coping with simultaneous iperf sessions. - fix debugging MFC after: 2 months Tested by: kevlo, hiren, gjb
* sigaction(2): Document various non-POSIX functions as async-signal safe.jilles2013-06-081-2/+15
|
* aio_mlock() added:glebius2013-06-0812-13/+74
| | | | | - Regen for r251526. - Bump __FreeBSD_version.
* Add new system call - aio_mlock(). The name speaks for itself. It allowsglebius2013-06-087-4/+189
| | | | | | | | to perform the mlock(2) operation, which can consume a lot of time, under control of aio(4). Reviewed by: kib, jilles Sponsored by: Nginx, Inc.
* Use improved __sync_*() intrinsics for MIPS in userspace as well.ed2013-06-088-56/+5
| | | | | r251524 introduced custom tailored versions for MIPS of these functions for kernel-space code. We can just reuse them in userspace as well.
* Add proper __sync_*() intrinsics for MIPS.ed2013-06-082-0/+438
| | | | | | | | | | | | | | | | | | | | To make <stdatomic.h> work on MIPS (and ARM) using GCC, we need to provide implementations of the __sync_*() functions. I already added these functions for 4 and 8 byte types to libcompiler-rt some time ago, based on top of <machine/atomic.h>. Unfortunately, <machine/atomic.h> only provides a subset of the features needed to implement <stdatomic.h>. This means that in some cases we had to do compare-and-exchange calls in loops, where a simple ll/sc would suffice. Also implement these functions for 1 and 2 byte types. MIPS only provides ll/sc instructions for 4 and 8 byte types, but this is of course no limitation. We can simply load 4 bytes and use some bitmask tricks to modify only the bytes affected. Discussed on: mips, arch Tested with: QEMU
* Make sys_mlock() function just a wrapper around vm_mlock() functionglebius2013-06-082-5/+11
| | | | | | | that does all the job. Reviewed by: kib, jilles Sponsored by: Nginx, Inc.
* Separate LIO_SYNC processing into a separate function aio_process_sync(),glebius2013-06-081-19/+41
| | | | | | | and rename aio_process() into aio_process_rw(). Reviewed by: kib Sponsored by: Nginx, Inc.
* MFV r251519:delphij2013-06-083-1/+31
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Illumos ZFS issue #3805 arc shouldn't cache freed blocks Quote from the Illumos issue: ZFS should proactively evict freed blocks from the cache. Even though these freed blocks will never be used again, and thus will eventually be evicted, this causes us to use memory inefficiently for 2 reasons: 1. A block that is freed has no chance of being accessed again, but will be kept in memory preferentially to a block that was accessed before it (and is thus older) but has not been freed and thus has at least some chance of being accessed again. 2. We partition the ARC into several buckets: user data that has been accessed only once (MRU) metadata that has been accessed only once (MRU) user data that has been accessed more than once (MFU) metadata that has been accessed more than once (MFU) The user data vs metadata split is somewhat arbitrary, and the primary control on how much memory is used to cache data vs metadata is to simply try to keep the proportion the same as it has been in the past (each bucket "evicts against" itself). The secondary control is to evict data before evicting metadata. Because of this bucketing, we may end up with one bucket mostly containing freed blocks that are very old, while another bucket has more recently accessed, still-allocated blocks. Data in the useful bucket (with still-allocated blocks) may be evicted in preference to data in the useless bucket (with old, freed blocks). On dcenter, we saw that the MFU metadata bucket was 230MB, while the MFU data bucket was 27GB and the MRU metadata bucket was 256GB. However, the vast majority of data in the MRU metadata bucket (256GB) was freed blocks, and thus useless. Meanwhile, the MFU metadata bucket (230MB) was constantly evicting useful blocks that will be soon needed. The problem of cache segmentation is a larger problem that needs more investigation. However, if we stop caching freed blocks, it should reduce the impact of this more fundamental issue. MFC after: 2 weeks
* cxgbe/tom: Fix bad signed/unsigned mixup in the stid allocator. Thisnp2013-06-082-3/+3
| | | | | | fixes a panic when allocating a mixture of IPv6 and IPv4 stids. MFC after: 1 week
* Merge in changes from NetBSD:andrew2013-06-081-17/+25
| | | | | | * Remove support for non-elf files. * Add the VFP setjmp magic numbers. * Add the offsets for the VFP registers within the buffer.
* Implement foreign volume handling. Allows admins to view foreign metadatasbruno2013-06-088-24/+496
| | | | | | | | | and clear or import it for use. PR: kern/172091 Submitted by: smh@freebsd.org Reviewed by: jhb@freebsd.org MFC after: 2 weeks
* Fix some recent regression issues:hselasky2013-06-071-47/+55
| | | | | | | | | | | | | 1) Only multi-TD isochronous transfers should use NORMAL type after specific type as per XHCI specification. 2) BEI bit is only available in NORMAL and ISOCHRONOUS TRB types. Don't use this bit for other types to avoid hardware asserts. Reserved bits should be don't care though ... MFC after: 1 week PR: usb/179342
* Finish pulling in the NetBSD setjmp/longjmp updates on ARM.andrew2013-06-074-4/+162
| | | | | | | | Store/restore the VFP registers in setjmp/longjmp on ARM EABI if VFP is enabled in the kernel. It checks the hw.floatingpoint sysctl to see if floating-point is available and uses this to determine if it should store them. If it does it uses a different magic value so longjmp is able to know if it should load them.
* Add WITH_DEBUG_FILESemaste2013-06-071-1/+9
| | | | | makeman currently generates a src.conf that claims every option also enforces WITHOUT_BIND_UTILS, so I applied this section by hand.
* Add a new knob WITH_DEBUG_FILES to control the building of standaloneemaste2013-06-0719-41/+180
| | | | | | | | | | | | | | | | debug files for userland programs and libraries. The "-g" debug flag is automatically applied when WITH_DEBUG_FILES is set. The debug files are now named ${prog}.debug and ${shlib}.debug for consistency with other systems and documentation. In addition they are installed under /usr/lib/debug, to simplify the process of installing them if needed after a crash. Users of bsd.{prog,lib}.mk outside of the base system place the standalone debug files in a .debug subdirectory. GDB automatically searches both of these directories for standalone debug files. Thanks to everyone who contributed changes, review, and testing during development.
* Reduce the difference to NetBSD.andrew2013-06-071-25/+27
| | | | | | | | | | | | * Stop pretending we support anything other than ELF by removing code surrounded by #ifdef __ELF__ ... #endif. * Remove _JB_MAGIC_SETJMP and _JB_MAGIC__SETJMP, they are defined in setjmp.h, which is able to be included from asm. * Fix the spelling of dependent. * Rename END _END and add END and ASEND to complement ENTRY and ASENTRY respectively * Add macros to simplify accessing the Global Offset Table, some of these will be used in the upcoming update to the setjmp functions.
* Include machine/setjmp.h to get the definition of _JB_MAGIC__SETJMP. Thisandrew2013-06-071-1/+3
| | | | allows us to remove it from the ARM copy of machine/asm.h.
* Remove an extra copy of _setjmp from libstand. We have used the libc versionandrew2013-06-071-106/+0
| | | | of this function since r183876.
* Make 'portsnap alfred' overwrite ports tree if it's not created by adelphij2013-06-071-1/+1
| | | | | | | portsnap. Discussed with: alfred Reviewed by: cperciva
* Override bmake's default MAKEFILE_PREFERENCEsjg2013-06-071-1/+1
|
* Add missing VM object unlocks in an error case.alc2013-06-071-0/+2
| | | | Reviewed by: kib
* Disable IGMPv3 link timers on a transition to IGMPv2.bms2013-06-071-0/+1
| | | | Submitted by: Alan Smithee
* FreeBSD 8.4 added.pluknet2013-06-071-10/+12
|
* Add support for polling the XHCI interrupt handler whenhselasky2013-06-073-15/+49
| | | | | | | | | | the regular interrupt handler is not working properly or in case of MSI interrupts which are not yet supported. Remove interrupt setup code for FreeBSD versions older than 700031. MFC after: 1 week PR: usb/179342
* Add libusb_get_port_numbersemaste2013-06-073-2/+13
| | | | | | libusbx deprecated libusb_get_port_path and replaced it with libusb_get_port_numbers. The latter omits an extra parameter which was unused in the FreeBSD implementation anyway.
* Properly set curvnet context in lagg_port_setlladdr() task handler.trociny2013-06-071-0/+2
| | | | | | | Reported by: Nikos Vassiliadis <nvass gmx.com> Submitted by: zec Tested by: Nikos Vassiliadis <nvass gmx.com> MFC after: 1 week
* Don't hold the node lock over the iterator.adrian2013-06-071-4/+24
| | | | | | | | | | | | | | | | The "find node" function call will increase the node reference anyway; so there's no reason to hold the node table lock during the MLME change. The only reason I could think of is to stop overlapping mlme ioctls from causing issues, but this should be fixed a different way. This fixes a whole class of LORs that creep up when nodes are being timed out or removed by hostapd. Tested: * AR5416, hostap, with nodes coming and going. No LORs or stability issues were observed.
* Bring over the initial static bluetooth coexistence configurationadrian2013-06-075-0/+355
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | for the WB195 combo NIC - an AR9285 w/ an AR3011 USB bluetooth NIC. The AR3011 is wired up using a 3-wire coexistence scheme to the AR9285. The code in if_ath_btcoex.c sets up the initial hardware mapping and coexistence configuration. There's nothing special about it - it's static; it doesn't try to configure bluetooth / MAC traffic priorities or try to figure out what's actually going on. It's enough to stop basic bluetooth traffic from causing traffic stalls and diassociation from the wireless network. To use this code, you must have the above NIC. No, it won't work for the AR9287+AR3012, nor the AR9485, AR9462 or AR955x combo cards. Then you set a kernel hint before boot or before kldload, where 'X' is the unit number of your AR9285 NIC: # kenv hint.ath.X.btcoex_profile=wb195 This will then appear in your boot messages: [100482] athX: Enabling WB195 BTCOEX This code is going to evolve pretty quickly (well, depending upon my spare time) so don't assume the btcoex API is going to stay stable. In order to use the bluetooth side, you must also load in firmware using ath3kfw and the binary firmware file (ath3k-1.fw in my case.) Tested: * AR9280, no interference * WB195 - AR9285 + AR3011 combo; STA mode; basic bluetooth inquiries were enough to cause traffic stalls and disassociations. This has stopped with the btcoex profile code. TODO: * Importantly - the AR9285 needs ASPM disabled if bluetooth coexistence is enabled. No, I don't know why. It's likely some kind of bug to do with the AR3011 sending bluetooth coexistence signals whilst the device is asleep. Since we don't actually sleep the MAC just yet, it shouldn't be a problem. That said, to be totally correct: + ASPM should be disabled - upon attach and wakeup + The PCIe powersave HAL code should never be called Look at what the ath9k driver does for inspiration. * Add WB197 (AR9287+AR3012) support * Add support for the AR9485, which is another combo like the AR9285 * The later NICs have a different signaling mechanism between the MAC and the bluetooth device; I haven't even begun to experiment with making that HAL code work. But it should be a lot more automatic. * The hardware can do much more interesting traffic weighting with bluetooth and wifi traffic. None of this is currently used. Ideally someone would code up something to watch the bluetooth traffic GPIO (via an interrupt) and then watch it go high/low; then figure out what the bluetooth traffic is and adjust things appropriately. * If I get the time I may add in some code to at least track this stuff and expose statistics. But it's up to someone else to experiment with the bluetooth coexistence support and add the interesting stuff (like "real" detection of bulk, audio, etc bluetooth traffic patterns and change wifi parameters appropriately - eg, maximum aggregate length, transmit power, using quiet time to control TX duty cycle, etc.)
* Use getnameinfo(3) instead of inet_ntop(3) to make printable versions ofae2013-06-071-1/+3
| | | | | | | sockaddr_in6 structures. getnameinfo(3) does the same thing, but it is also able to represent a scope zone id as described in the RFC 4007. MFC after: 2 weeks
OpenPOWER on IntegriCloud