]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/log
FreeBSD/FreeBSD.git
10 years agoMFC vt(4) improvements / sync with HEAD
emaste [Thu, 4 Sep 2014 20:18:08 +0000 (20:18 +0000)]
MFC vt(4) improvements / sync with HEAD

These are largely dumbbell@'s changes.  Most significantly they address
the extreme performance degradation with VGA hardware.

SVN revisions in this MFC:
  269471 270290 270293 270322 270324 270329 270331 270336 270338 270340
  270341 270342 270343 270388 270390 270404 270411 270412 270413 270431
  270446 270448 270485 270587 270589 270613 270618 270620 270667 270702
  270707 270708 270720 270721 270785 270786

Detailed commit list:

r270290: Test if the cursor is shown only once

  Later, we just see if the "struct mouse_cursor" pointer is set. This
  avoids the need to mess with all the conditions several times; this
  has been error prone.

  While here, rename the variable "m" to a more meaningful "cursor",
  like it's done elsewhere in the code.

r270293: Rename the "mouse_cursor" structure to "vt_mouse_cursor"

  At the same time, "w" and "h" members are now called "width" and
  "height". The goal is to have a more "public" structure, because it
  will soon be passed as argument to a new callback, replacing
  vd_bitbltchr_t.

r269471 (ray):

  Fix vt_vga driver to draw not-8-bit-aligned fonts correctly.
  Still one bug here: mouse left some gaps on track when moving left.

r270322:

  Add new vd_bitblt_text_t callback, and implement it for vt_vga

  Compared to the deprecated vd_bitbltchr_t callback, vd_bitblt_text_t
  receives:
    o  the whole text buffer
    o  the dirty area
    o  the mouse cursor (map, position, colors)

  This allows the backend to perform optimization on how to draw things.
  The goal is to remove vd_bitbltchr_t and vd_putchar_t, once all driver
  are converted (only vt_vga is included in this commit).

  In vt_vga, this allows to draw the text and the cursor in one pass,
  without ever reading from video memory (because it has all the context).
  The main benefit is the speed improvement: no more slideshow during
  boot!

  Other bugs fixed in vt_vga are:
    o  left-most characters are drawn properly (the left-most pixels were
       missing with bold characters and some wide letters such as 'm')
    o  no more black square around the cursor
    o  no cursor flickering when the text is scrolling

  There are still many problems to fix: the known issues are marked with
  "FIXME" inside the code.

r270411:

  vt_fb: Implement vd_bitblt_text_t for vt_fb and derivatives

r270412:

  creator_fb: Implement vd_bitblt_text_t

r270413: ofwfb: Implement vd_bitblt_text_t

r270324: vt_vga: Clip the draw area to never draw offscreen

  This fixes a bug when two windows use different fonts, but a longer-
  term solution is required. The dirty area should be stored as pixels,
  not character cells, because such coordinates don't have the same
  meaning in all windows, when using different fonts.

r270329: Mark new mouse position as dirty only when it's actually displayed

r270331: Store cursor bitmap & colors in struct vt_device

  This removes the need to specify them to each call to vd_bitblt_text_t
  and, therefore, simplifies the API.

r270336: Give the window to vd_bitblt_text_t callback

  ... instead of both the buffer and the font. Again, this simplifies
  the API.

r270338: The offset to center the text area is per-window now

  The previous global offset, based on the last loaded font, had no
  meaning for other windows. This caused a shifted text area, often
  partly out-of-screen.

r270341:  vt_vga: Remove a "FIXME" comment; the issue was solved in r270338

r270340: Don't run vt_set_border() and vt_flush() concurrently

  In the case of vt_vga, the two concurrent calls were writing to the
  same VGA registers, causing incorrect refresh of the screen.

r270342: Use the actual size of the mouse when marking its position as dirty

  This fixes a bug where part of the cursor was not erased.

r270343: Remove "FIXME" about multiple locking of vt_buf in vt_flush()

  After some testing, it appears that acquiring the lock once and keeping
  it longer is slower than taking it multiple times.

  While here, fix a typo in another comment.

r270388: vt_vga: Give only the character part of term_char_t to vga_get_cp437()

  This fixes a bug where vga_get_cp437() was called with an invalid
  argument. The screen was then filled with '?' instead of the actual
  character.

r270390: Fix a crash in vt_mark_mouse_position_as_dirty() when in textmode

  In textmode, no font is loaded, thus the page fault in
  vt_mark_mouse_position_as_dirty() when it wants the font width/height.

  For now, create a fake area for the textmode. This needs to be
  modified if vt_vga gains mouse support in textmode.

  While here, fix a build failure when SC_NO_CUTPASTE is defined:
  vt_mark_mouse_position_as_dirty() must not be included in this case.

r270404: Fix cursor handling in vt_flush()

  There were situations where the cursor was not erased/redrawn or its
  position was marked as dirty even though it's not displayed. The code
  is now more straightforward.

  At the same, add a function to determine if the cursor covers a given
  area. This is used by backends to know if they need to draw the
  cursor.

  This new function should be paired with a new state in struct
  vt_device, called vd_mshown, which indicates if the cursor should be
  displayed.  This again simplifies vd_bitblt_text_t callback's API.

r270431: vt(4): Add vd_bitblt_bmp_t callback

  The code was already there in all backends, we just expose it. This is
  used to display the splash screen.

r270446: Remove vd_bitbltchr_t

  It's replaced by vd_bitblt_text_t, which gives more context to the
  backend and allows it to perform more efficiently when redrawing a
  given area.

r270448: Fix order of arguments (x <-> y) when showing the splash screen

r270485: vt_vga: Fix the display of the splash screen

r270587: Take font offset into account in vt_is_cursor_in_area()

  This fixes a "General protection fault" in vt_vga, where
  vt_is_cursor_in_area() erroneously reported that the cursor was over
  the text. This led to negative integers stored in "unsigned int" and
  chaos.

r270589: The cursor coordinates are relative to the drawn area

  ... not the whole screen. Don't use font offsets in
  vt_mark_mouse_position_as_dirty().

  This fixes a bug where the mouse position wasn't marked as dirty when
  approaching the borders of the drawn area.

r270613: Store a rectangle for the drawable area, not just the top-left corner

  This allows backends to verify they do not draw outside of this area.
  This fixes a bug in vt_vga where the text was happily drawn over the
  right and bottom margins, when using the Gallant font.

r270618: Intialize drawable area rectangle each time a font is loaded

  This also fixes a problem where early in boot, the area was zero,
  leading to nothing displayed for a few seconds.

r270620: vt_vga: Use Write Mode 0 to draw group of 8 pixels using 3 or more colors

  This replaces the method based on Write Mode 3, which required reads
  from the video memory to load the latches.

r270667: When creating a window buffer, fill it entirely

  ... not just the visible part.

  This fixes a bug where, when switching from eg. vt_vga to vt_fb (ie.
  the resolution goes up), the originally hidden, uninitialized area of
  the buffer is displayed on the screen. This leads to a missing text
  cursor when it's over an unitialized area.

  This was also visible when selecting text: the uninitialized area was
  not highlighted.

  Internally, this area was zeroed: characters were all 0x00000000,
  meaning the foreground and background color was black. Now, everything
  is filled with a space with a gray foreground color, like the visible
  area.

  While here, remove the check for the mute flag and always use
  TERMINAL_NORM_ATTR as the character attribute (ie. gray foreground,
  black background).

r270702: Implement basic support for KDSETMODE ioctl

  With the current implementation, this allows an X11 server to tell
  the console it switches a particular window in "graphics mode". This
  information is used by the mouse handling code to ignore sysmouse events
  in the window taken by the X server: only him should receive those
  events.

r270707: Pause the vt_flush() timer when the screen is up-to-date

  The timer is restarted whenever a window buffer is marked as dirty or
  the mouse cursor moves.

  There's still room for improvement. For instance, we should not mark a
  window buffer as dirty when this window isn't displayed.

r270708: vt(4): Recompute the drawable area when the resolution changes

  This was only done when the font changed.

r270720: vt(4): Fix mouse cursor handling in vt_fb/creator_vt/ofwfb

  There were two issues:
    1. The area given to vt_is_cursor_in_area() was adding the drawable
       area offset, something already handled by this function.
    2. The cursor was shifted on the screen by the offset of this area
       and thus was misplaced or not erased. Furthermore, when reaching
       the bottom or right borders, the cursor was either totally
       removed or not erased correctly.

r270721: vt(4): If the terminal shrinks, make sure the mouse is inside
   the new area

r270785: vt(4): Change vb_history_size from "int" to "unsigned int"

  CID: 12300021230003

r270786: Indicate that KDSETRAD case falls through the next case

  CID: 1229953

Relnotes: Yes

10 years agoMFC r270710 and r270821:
hselasky [Thu, 4 Sep 2014 20:12:36 +0000 (20:12 +0000)]
MFC r270710 and r270821:
- Update the OFED Linux Emulation layer as a preparation for a
hardware driver update from Mellanox Technologies.
- Remove empty files from the OFED Linux Emulation layer.
- Fix compile warnings related to printf() and the "%lld" and "%llx"
format specifiers.
- Add some missing 2-clause BSD copyrights.
- Add "Mellanox Technologies, Ltd." to list of copyright holders.
- Add some new compatibility files.
- Fix order of uninit in the mlx4ib module to avoid crash at unload
using the new module_exit_order() function.

Sponsored by: Mellanox Technologies

10 years agoMFC r270216:
ngie [Thu, 4 Sep 2014 20:02:28 +0000 (20:02 +0000)]
MFC r270216:

  Add ${LIBC} to DPADD to fix "make checkdpadd"

  Phabric: D632
  Approved by: jmmv (mentor)

10 years agoMFC r270299 (dumbbell): vt_vga: When clearing video memory, don't read from it
emaste [Thu, 4 Sep 2014 19:22:01 +0000 (19:22 +0000)]
MFC r270299 (dumbbell): vt_vga: When clearing video memory, don't read from it

  The goal is to clear the video memory, in case an application drew to
  it. So the content shouldn't be loaded in the latches, it can't be
  trusted anyway.

  This improves a bit the window switch speed.

Sponsored by: The FreeBSD Foundation

10 years agoMFC r269685 (nwhitehorn): Retire vd_maskbitbltchr.
emaste [Thu, 4 Sep 2014 19:13:07 +0000 (19:13 +0000)]
MFC r269685 (nwhitehorn): Retire vd_maskbitbltchr.

  The same functionality can be obtained by testing for mask != NULL in
  vd_bitbltchr, which all implementations of vd_bitbltchr() were doing
  anyway.

Sponsored by: The FreeBSD Foundation

10 years agoMFC r269636 by nwhitehorn:
emaste [Thu, 4 Sep 2014 18:54:01 +0000 (18:54 +0000)]
MFC r269636 by nwhitehorn:

  Set fb_pbase properly on PowerPC in the case where we have to guess at
  the right register bank for the framebuffer. Disable the assigned-
  addresses path on SPARC since it is just a hack for IBM PPC systems
  and was neither relevant for nor worked on SPARC anyway.

Sponsored by: The FreeBSD Foundation

10 years agoMFC fbd(4) and vt_fb disentanglement:
emaste [Thu, 4 Sep 2014 18:43:40 +0000 (18:43 +0000)]
MFC fbd(4) and vt_fb disentanglement:

r268472 (ray):

  Should check fb_read method presence instead of double check for fb_write.

r269620 (nwhitehorn):

  Retire various intertwined bits of fbd(4) and vt_fb, in particular the
  pixel modification indirection. No actual drivers use it and those
  that might (e.g. creatorfb) use custom implementations of
  vd_bitbltchr().

Relnotes: No
Sponsored by: The FreeBSD Foundation

10 years agoMFC r269278 (nwhitehorn):
emaste [Thu, 4 Sep 2014 18:34:22 +0000 (18:34 +0000)]
MFC r269278 (nwhitehorn):

  Make mmap() of the console device when using ofwfb work like other
  supported framebuffer drivers. This lets ofwfb work with
  xf86-video-scfb and makes the driver much more generic and less
  PCI-centric. This changes some user-visible behavior and will require
  updates to the xorg-server port on PowerPC when using ATI graphics
  cards.

Relnotes: Yes
Sponsored by: The FreeBSD Foundation

10 years agoMFC r268350 (nwhitehorn):
emaste [Thu, 4 Sep 2014 18:30:33 +0000 (18:30 +0000)]
MFC r268350 (nwhitehorn):

  Use common vt_fb parts in ofwfb as far as we are able without
  sacrificing performance.

Sponsored by: The FreeBSD Foundation

10 years agoMFC r265883,268898:
nwhitehorn [Thu, 4 Sep 2014 18:28:30 +0000 (18:28 +0000)]
MFC r265883,268898:

Repair bitrot in PS3 memory and interrupt allocation.

10 years agoMFC r268880:
nwhitehorn [Thu, 4 Sep 2014 18:24:47 +0000 (18:24 +0000)]
MFC r268880:
Allow mappings of memory not previously direct-mapped by the kernel when
calling mmap on /dev/mem and add a handler for the possible userland
machine checks that may result. Remove some pointless and wrong copy/paste
that has been in here for a decade as well.

This results in a /dev/mem with identical semantics to the x86 version.

10 years agoMFC vt(4) driver for Sun creator(4) framebuffers
emaste [Thu, 4 Sep 2014 18:18:29 +0000 (18:18 +0000)]
MFC vt(4) driver for Sun creator(4) framebuffers

r269601 (nwhitehorn):

  Add a simple unaccelerated vt(4) framebuffer driver for Sun
  framebuffers handled by creator(4) (Sun Creator 3D, Elite 3D, etc.).
  This provides vt(4) consoles on all devices currently supported by
  syscons on sparc64.  The driver should also be easily adaptable to
  support newer Sun framebuffers such as the XVR-500 and higher.

  Many thanks to dumbbell@ (Jean-Sebastien Pedron) for testing this
  remotely during development.

r269783 (dumbbell):

  vt(4): Colors are indexed against a console palette, not a VGA palette

Sponsored by: The FreeBSD Foundation

10 years agoMFC PS3 vt(4) console support
emaste [Thu, 4 Sep 2014 18:15:36 +0000 (18:15 +0000)]
MFC PS3 vt(4) console support

r265871 (nwhitehorn):

  Move the PS3 framebuffer console to use vt instead of syscons and
  adjust GENERIC64 for PowerPC to use vt with it.

  Much to my chagrin, PS3 support seems to have bitrotted somewhat since
  the last time I tried it. ehci panics on attach and interrupt handling
  seems to be faulty. This should be fixed soon...

r269783 (dumbbell):

  Fix two files forgotten in r269783 (vt_generate_cons_palette)

r268895 (nwhitehorn):

  Enable X11 via xf86-video-scfb on the Playstation 3. This commit made
  from an xterm running for the first time on said Playstation.

Approved by: nwhitehorn
Relnotes: yes

10 years agoFix debug output that has erroneously been committed with the last update.
se [Thu, 4 Sep 2014 17:21:54 +0000 (17:21 +0000)]
Fix debug output that has erroneously been committed with the last update.

Obtained from: Jan Beich

10 years agoMFC r270512 r270513 r270754
rodrigc [Thu, 4 Sep 2014 16:55:01 +0000 (16:55 +0000)]
MFC r270512 r270513 r270754
   - add comments which describe exit status codes of /usr/sbin/bhyve
   - move bhyvectl --destroy outside of the while loop
   - Use "file -s" so that we can run vmrun.sh against special devces such as
     /dev/md memory files systems or zvols

10 years agoMFC r260047: Clean up license text
emaste [Thu, 4 Sep 2014 16:51:45 +0000 (16:51 +0000)]
MFC r260047: Clean up license text

  - Renumber Regents clauses
  - Remove clause 3 and 4 from TNF license, following upstream change

Sponsored by: The FreeBSD Foundation

10 years agoMFC r270757:
tijl [Thu, 4 Sep 2014 16:05:12 +0000 (16:05 +0000)]
MFC r270757:

In r253839 the default behaviour of ld(1) was changed such that all
libraries that need to be linked into an executable or library have to be
listed on the command line explicitly.  This commit fixes a bug in ld(1)
where it would scan dependencies of the libraries on the command line and
link them if needed if they were also found in ld.so.cache.

The important bit of the patch is the initialisation of needed.by such that
libraries found by scanning dependencies are marked as such and not used in
the link.

The patch is a backport of binutils git commit
d5c8b1f8561426b41aa5330ed60f578178fe6be2

The author gave permission to use it under GPLv2 terms.

PR: 192062

10 years agoMFC r270931: Fix typo ("by" -> "be").
se [Thu, 4 Sep 2014 13:47:55 +0000 (13:47 +0000)]
MFC r270931: Fix typo ("by" -> "be").

10 years agoMFC r270647: Add references to vt(4) and the configuration files in /usr/sha
se [Thu, 4 Sep 2014 13:45:16 +0000 (13:45 +0000)]
MFC r270647: Add references to vt(4) and the configuration files in /usr/sha
MFC r270653: Update man-pages to correctly refer to changed pathes and namin
MFC r270657: More man pages that need to know about vt in addition to syscon
MFC r270659: (by pluknet@) Missed comma.
MFC r270660: Back-out the references to vt(4) from this man-page. It appears
MFC r270933: Add references to vt(4) to further man-pages.
MFC r270934: Final patches to the tools used to convert syscons keymaps for
MFC r270935: Add vt(4) support to the console initialisation script, specifi

Second batch of MFCs to add support for Unicode keymaps for use with vt(4).

It contains the following changes:

- Add references to vt(4) to relevant man-pages.
- Update comment in defaults/rc.conf to mention vt
- Update rc.d/syscons to warn about syscons keymaps used under vt.
  An attempt is made to identify the vt keymap to load instead.
- Minor changes to the conversion tool based on mail comments on keymaps.

Relnotes: yes

10 years agoDocument r271069, Mac Mini 3,1 support added to asmc(4).
gjb [Thu, 4 Sep 2014 11:15:38 +0000 (11:15 +0000)]
Document r271069, Mac Mini 3,1 support added to asmc(4).

Sponsored by: The FreeBSD Foundation

10 years agodrm/radeon: Fix a memory leak when radeonkms is unloaded
dumbbell [Thu, 4 Sep 2014 09:42:36 +0000 (09:42 +0000)]
drm/radeon: Fix a memory leak when radeonkms is unloaded

This an MFC of r270750.

10 years agoDocument r262566, sshd(8) startup script creates ed25519 keys
gjb [Thu, 4 Sep 2014 02:14:57 +0000 (02:14 +0000)]
Document r262566, sshd(8) startup script creates ed25519 keys
if ENOENT on startup.

Sponsored by: The FreeBSD Foundation

10 years agoDocument r264438, mdconfig(8) rc.conf(5) listing is no longer
gjb [Thu, 4 Sep 2014 02:14:55 +0000 (02:14 +0000)]
Document r264438, mdconfig(8) rc.conf(5) listing is no longer
required to be sequential.

Sponsored by: The FreeBSD Foundation

10 years agoDocument r259141, jail(8) ipv6 allocation startup bug.
gjb [Thu, 4 Sep 2014 02:14:53 +0000 (02:14 +0000)]
Document r259141, jail(8) ipv6 allocation startup bug.

Sponsored by: The FreeBSD Foundation

10 years agoMFC r270289:
neel [Thu, 4 Sep 2014 01:38:31 +0000 (01:38 +0000)]
MFC r270289:
Change file permissions for some setuid executables so they are "o+r".
The executable itself doesn't contain any privileged information.

An example of where this is useful is when makefs(8) is creating an image
that includes /sbin/shutdown. This can now be done without root privileges.

10 years agoMFC r270844:
pfg [Thu, 4 Sep 2014 00:40:41 +0000 (00:40 +0000)]
MFC r270844:
Minor space/tab cleanups.

Most of them were ripped from the GSoC 2104
SMAP + kpatch project (but unrelated).
Only cosmetic changes.

Taken from: Oliver Pinter (op@)

10 years agoMerge r268303 from head:
gavin [Wed, 3 Sep 2014 23:29:06 +0000 (23:29 +0000)]
Merge r268303 from head:

  Add support to asmc(4) for Macmini 3,1.

PR: 190195
Submitted by: fbsdbugs2 sentry.org
Relnotes: yes

10 years agoMerge r270677 from head:
gavin [Wed, 3 Sep 2014 23:18:13 +0000 (23:18 +0000)]
Merge r270677 from head:

  Fix xref, pam(8) -> pam(3)

PR: 193045
Submitted by: rsimmons0 gmail com

10 years agoMerge r270259 from head:
gavin [Wed, 3 Sep 2014 23:15:54 +0000 (23:15 +0000)]
Merge r270259 from head:

  Add a missing brace to callout_init_rm() to fix syntax.

10 years agoMerge r270251 from head:
gavin [Wed, 3 Sep 2014 23:14:26 +0000 (23:14 +0000)]
Merge r270251 from head:

  Fix return type of callout_init_rm() and add return type to
  callout_deactivate().

PR: 192520
Submitted by: ngie

10 years agoMerge r269871 from head:
gavin [Wed, 3 Sep 2014 23:11:39 +0000 (23:11 +0000)]
Merge r269871 from head:

  Clarify descriptions of pthread_cond_wait() and pthread_cond_timedwait()

Submitted by: Malcolm Douglas via freebsd-doc
Reviewed by: jhb

10 years agoMerge r269488 from head:
gavin [Wed, 3 Sep 2014 23:08:21 +0000 (23:08 +0000)]
Merge r269488 from head:

  For reasons which are not clear, r254263 broke some PCMCIA and CardBus
  bridges in strange ways, either rendering them unable to detect
  insertion and removal events, or possibly unable to read from the
  device behind the bridge.

  This fixes at least one laptop, a Toshiba Tecra M5 with a Texas
  Instruments PCxx12 (d=0x8039 v=0c104c) bridge.  The very similar
  Tecra M9 has the same bridge, but worked fine without this change.

  The bridge chip has no I/O port BAR, and there is nothing in the spec
  to suggest I/O decoding should be enabled; however enabling it fixes
  the issue.  Add an XXX comment to this effect.

Discussed with: jhb, imp

10 years agoMerge 270872 from head:
gavin [Wed, 3 Sep 2014 23:04:23 +0000 (23:04 +0000)]
Merge 270872 from head:

  Fix character case in examples for "camcontrol security" - should be
  "-U user" not "-u user".

PR: 193179
Submitted by: milios ccsys com

10 years agoDocument libc updates from illumos and Apple.
gjb [Wed, 3 Sep 2014 20:53:11 +0000 (20:53 +0000)]
Document libc updates from illumos and Apple.

Submitted by: pfg
Sponsored by: The FreeBSD Foundation

10 years agoMFC: r270885, r270948
marius [Wed, 3 Sep 2014 20:07:26 +0000 (20:07 +0000)]
MFC: r270885, r270948

- Nuke unused sdhci_softc.
- Static'ize sdhci_debug local to sdhci.c.
- Const'ify PCI device description strings.
- Nuke redundant resource ID members from sdhci_pci_softc.
- Nuke unused hw.sdhci_pci.debug tunable.
- Add support for using MSI instead of INTx, controllable via the tunable
  hw.sdhci.enable_msi (defaulting to on) and tested with a RICOH R5CE823 SD
  controller.
- Use NULL instead of 0 for pointers.

10 years agoMinor rewording to the r260387 entry.
gjb [Wed, 3 Sep 2014 16:48:33 +0000 (16:48 +0000)]
Minor rewording to the r260387 entry.

Sponsored by: The FreeBSD Foundation

10 years agoDocument r270890, pathchk(1): Ensure bytes >= 128 are considered
gjb [Wed, 3 Sep 2014 16:46:45 +0000 (16:46 +0000)]
Document r270890, pathchk(1): Ensure bytes >= 128 are considered
non-portable characters.

Sponsored by: The FreeBSD Foundation

10 years agoDocument r270997, zdb(8) included in /rescue.
gjb [Wed, 3 Sep 2014 16:46:43 +0000 (16:46 +0000)]
Document r270997, zdb(8) included in /rescue.

Sponsored by: The FreeBSD Foundation

10 years agoDocument r270810, hptnr(4) update to 1.0.1.
gjb [Wed, 3 Sep 2014 16:46:41 +0000 (16:46 +0000)]
Document r270810, hptnr(4) update to 1.0.1.

Sponsored by: The FreeBSD Foundation

10 years agoDocument r270892, autofs(5)
gjb [Wed, 3 Sep 2014 16:46:39 +0000 (16:46 +0000)]
Document r270892, autofs(5)

Sponsored by: The FreeBSD Foundation

10 years agoMinor rewording to the r260385 entry.
gjb [Wed, 3 Sep 2014 16:46:37 +0000 (16:46 +0000)]
Minor rewording to the r260385 entry.

Sponsored by: The FreeBSD Foundation

10 years agoRemove a generalized sentence regarding iSCSI updates that
gjb [Wed, 3 Sep 2014 16:46:35 +0000 (16:46 +0000)]
Remove a generalized sentence regarding iSCSI updates that
should be covered by the past few commits.

Sponsored by: The FreeBSD Foundation

10 years agoExpand r262855 to illustrate how to enable the test suite.
gjb [Wed, 3 Sep 2014 16:46:33 +0000 (16:46 +0000)]
Expand r262855 to illustrate how to enable the test suite.

Submitted by: jmmv
Sponsored by: The FreeBSD Foundation

10 years agoDocument r265524, iSCSI performance optimizations.
gjb [Wed, 3 Sep 2014 16:46:31 +0000 (16:46 +0000)]
Document r265524, iSCSI performance optimizations.

Submitted by: trasz
Sponsored by: The FreeBSD Foundation

10 years agoDocument r265524, iSCSI lock contention optimizations.
gjb [Wed, 3 Sep 2014 16:46:29 +0000 (16:46 +0000)]
Document r265524, iSCSI lock contention optimizations.

Submitted by: trasz
Sponsored by: The FreeBSD Foundation

10 years agoDocument r265523, kern.iscsi.fail_on_disconnection
gjb [Wed, 3 Sep 2014 16:46:27 +0000 (16:46 +0000)]
Document r265523, kern.iscsi.fail_on_disconnection

Submitted by: trasz
Sponsored by: The FreeBSD Foundation

10 years agoDocument r269065, iSCSI redirection handling
gjb [Wed, 3 Sep 2014 16:46:25 +0000 (16:46 +0000)]
Document r269065, iSCSI redirection handling

Submitted by: trasz
Sponsored by: The FreeBSD Foundation

10 years agoMFC r270288 by dumbbell: vt(4): Constify vt_buf argument of vtbuf_iscursor()
emaste [Wed, 3 Sep 2014 14:06:12 +0000 (14:06 +0000)]
MFC r270288 by dumbbell: vt(4): Constify vt_buf argument of vtbuf_iscursor()

Sponsored by: The FreeBSD Foundation

10 years agoMFC r270280 by dumbbell: vt(4): Pause the flush timer while swithing window
emaste [Wed, 3 Sep 2014 14:00:37 +0000 (14:00 +0000)]
MFC r270280 by dumbbell: vt(4): Pause the flush timer while swithing window

  This fixes bad looking refresh when switching window: squares instead
  of text, flashing screen, and so on. In the worst case, vt_flush() came
  at a very inappropriate timing and the screen was not refreshed at all
  (leaving squares all over the place).

  This doesn't fix the flickering of the screen with vt_vga, because the
  sync signal is temporarily stopped and the video memory is cleared.

Sponsored by: The FreeBSD Foundation

10 years agoMFC vt(4) mouse cursor improvements from dumbbell:
emaste [Wed, 3 Sep 2014 13:40:02 +0000 (13:40 +0000)]
MFC vt(4) mouse cursor improvements from dumbbell:

r270269:

  vt(4): Handle global and per-window mouse cursor toggle in one place

  Before the global flag was set/unset using the CONS_MOUSECTL ioctl,
  and the per-window flag through the MOUSE_SETLEVEL or MOUSE_SETMODE
  ioctls.

  Also, if the cursor is already enabled/disabled, return immediatly.
  This avoids to reset the cursor's position to the center of the
  screen.

  This matches syscons' behavior.

  While here, remove a trailing space and a redundant variable
  declaration.

r270271:

  vt(4): Mark cursor old position as dirty before reading the dirty area

  Otherwise, the redraw is done during the next vt_flush run.

r270272:

  vt(4): If the cursor is globally disabled, don't mark its position as dirty

  This avoids unnecessary redraw. In particular, during boot, where the
  cursor is disabled and its fake position is [0;0], this triggered a
  refresh of the whole screen each time vt_flush() is called.

r270273:

  vt(4): If the cursor didn't move, don't mark its position as dirty

  Currently, this has no effect, because the cursor is always redrawn
  anyway. But this will be useful after improvements to the
  vd_bitbltchr_t callback API.

  The vt_device structure members used to store the position of the
  cursor as of the last redraw are renamed from vd_mdirty{x,y} to
  vd_mold{x,y}.  The associated comment is fixed too. Also, their value
  is now expressed in pixels, not in character columns/row.

r270275:

  vt(4): Mark the current cursor position as dirty

  Like r270273, this has no effect for now, because the cursor is always
  drawn. This is in preparation of future changes to vd_bitbltchr_t API.

r270278:

  vt(4): Mark cursor position as dirty when we enable/disable it

Sponsored by: The FreeBSD Foundation

10 years agoMFC r270265 by dumbbell:
emaste [Wed, 3 Sep 2014 13:31:08 +0000 (13:31 +0000)]
MFC r270265 by dumbbell:

  vt(4): Fix an inconsistency between the mouse cursor bitmap and its mask

10 years agoMFC r269437 by nwhitehorn:
emaste [Wed, 3 Sep 2014 13:22:50 +0000 (13:22 +0000)]
MFC r269437 by nwhitehorn:

  Don't assume that the framebuffer driver is using vt_fb_blank() when
  blanking the screen during init.

10 years agoMFC vt(4) work from ray@:
emaste [Wed, 3 Sep 2014 13:17:44 +0000 (13:17 +0000)]
MFC vt(4) work from ray@:

r269188: [Rework vb_buffer and vb_rows assignment]

r269192: Remove special handling of console window size.

  It's done in vt_upgrade() for all windows.

r269193: Update comments.

r269194: Revise font initialization handling.

Sponsored by: The FreeBSD Foundation

10 years agoRegen.
kib [Wed, 3 Sep 2014 09:05:37 +0000 (09:05 +0000)]
Regen.

10 years agoMFC r270691:
kib [Wed, 3 Sep 2014 09:05:16 +0000 (09:05 +0000)]
MFC r270691:
Fix handling of the third argument for fcntl(2).  The native syscall
uses long for arg, which needs translation.

10 years agoMFC r270661:
ae [Wed, 3 Sep 2014 08:27:05 +0000 (08:27 +0000)]
MFC r270661:
  Remove leading '/' from hardlink name when removing them from the
  regular file name. This fixes the problem, when bsdtar can not create
  hardlinks to extracted files.

10 years agoMFC r270260:
delphij [Wed, 3 Sep 2014 08:24:11 +0000 (08:24 +0000)]
MFC r270260:

Provide compatibility shim for atomic_dec_64_nv.

10 years agoMFC r270248: MFV r270196:
delphij [Wed, 3 Sep 2014 08:21:21 +0000 (08:21 +0000)]
MFC r270248: MFV r270196:

Illumos issue:
    5047 don't use atomic_*_nv if you discard the return value

10 years agoMFC r270247: MFV r270195:
delphij [Wed, 3 Sep 2014 08:18:09 +0000 (08:18 +0000)]
MFC r270247: MFV r270195:

Illumos issue:
    5045 use atomic_{inc,dec}_* instead of atomic_add_*

10 years agoMFC r270239: MFV r270193:
delphij [Wed, 3 Sep 2014 08:13:46 +0000 (08:13 +0000)]
MFC r270239: MFV r270193:

Illumos issues:
    5042 stop using deprecated atomic functions

10 years agoMFC r270189:
delphij [Wed, 3 Sep 2014 08:03:26 +0000 (08:03 +0000)]
MFC r270189:

Add zdb into rescue environment.

On amd64, this would increase the binary size by 1.1MiB and
make it possible to examine zpool status offline, useful for
recovery and diagnostic purposes.

Submitted by: sef
Obtained from: FreeNAS

10 years agoThis is a direct commit to account for the renaming of 'cnt' to 'vm_cnt'
alc [Wed, 3 Sep 2014 07:20:09 +0000 (07:20 +0000)]
This is a direct commit to account for the renaming of 'cnt' to 'vm_cnt'
in HEAD but not stable/10.

10 years agoMFC r270666
alc [Wed, 3 Sep 2014 06:47:05 +0000 (06:47 +0000)]
MFC r270666
  Back in the days when the kernel was single threaded, testing
  "vm_paging_target() > 0" was a reasonable way of determining if the
  inactive queue scan met its target.  However, now that other threads
  can be allocating pages while the inactive queue scan is running, it's
  an unreliable method.  The effect of it being unreliable is that we
  can start swapping out processes when we didn't intend to.

  This issue has existed since the kernel was multithreaded, but the
  changes to the inactive queue target in 10.0-RELEASE have made its
  effects visible.

  This change introduces a more direct method for determining if the
  inactive queue scan met its target that is not affected by the actions
  of other threads.

10 years agoMFC automatic vt(4) selection for UEFI boot
emaste [Tue, 2 Sep 2014 22:01:14 +0000 (22:01 +0000)]
MFC automatic vt(4) selection for UEFI boot

r268158: Prefer vt(4) for UEFI boot

  The UEFI framebuffer driver vt_efifb requires vt(4), so add a
  mechanism for the startup routine to set the preferred console.
  This change is ugly because console init happens very early in the
  boot, making a cleaner interface difficult.  This change is intended
  only to facilitate the sc(4) / vt(4) transition, and can be reverted
  once vt(4) is the default.

r268160: Fix typos in VTY constant names from r268158

r268982: Don't pass null kmdp to preload_search_info

  On Xen PVH guests kmdp == NULL.

Sponsored by: The FreeBSD Foundation

10 years agoMFC r269186 by ray@: Remove useless debug string.
emaste [Tue, 2 Sep 2014 21:50:14 +0000 (21:50 +0000)]
MFC r269186 by ray@: Remove useless debug string.

  Fix indent.

Sponsored by: The FreeBSD Foundation

10 years agoMFC r269185 by ray@: Remove unused macro VT_CONSDEV_DECLARE.
emaste [Tue, 2 Sep 2014 21:05:45 +0000 (21:05 +0000)]
MFC r269185 by ray@: Remove unused macro VT_CONSDEV_DECLARE.

Sponsored by: The FreeBSD Foundation

10 years agoMFC r268772 by nwhitehorn:
emaste [Tue, 2 Sep 2014 19:57:33 +0000 (19:57 +0000)]
MFC r268772 by nwhitehorn:

  Allow efifb to be used with xf86-video-scfb. This is important for EFI
  systems without either a CSM or real graphics drivers, such as my
  Lenovo Haswell laptop.

  This provides working X with the small complication of a console
  cursor permanently overlaid on the upper-left corner of the screen
  that will be dealt with later.

  Also remove some redundant screen clearing.

Sponsored by: The FreeBSD Foundation

10 years agoMFC r268771, r268796 by nwhitehorn:
emaste [Tue, 2 Sep 2014 19:56:37 +0000 (19:56 +0000)]
MFC r268771, r268796 by nwhitehorn:

r268771:
  Allow console drivers active from early boot to be used with
  xf86-video-scfb, rather than only drivers attached later on. This
  involves a small amount of code duplication with dev/fb/fbd.c, which
  will fixed later on.

  Also improve performance of vt_blank() by making it not read from the
  framebuffer unnecessarily.

r268796:
  Fix embarassing typos I made.

Sponsored by: The FreeBSD Foundation

10 years agoMFC part of r267973: remove redundant "" assignment for string in BSS.
emaste [Tue, 2 Sep 2014 19:48:37 +0000 (19:48 +0000)]
MFC part of r267973: remove redundant "" assignment for string in BSS.

Sponsored by: The FreeBSD Foundation

10 years agoMFC r268624 by nwhitehorn:
emaste [Tue, 2 Sep 2014 19:36:18 +0000 (19:36 +0000)]
MFC r268624 by nwhitehorn:

  On my Lenovo laptop, the firmware maps the EFI framebuffer with MTRRs
  set to uncacheable. This leads to execrable console performance. Once
  PMAP is up, remap the framebuffer as write-combining. This reduces
  boot time on my laptop by 60% when booting with EFI.

10 years agoRevert r268372 - enable vt_efifb vt(4) driver again.
emaste [Tue, 2 Sep 2014 19:14:33 +0000 (19:14 +0000)]
Revert r268372 - enable vt_efifb vt(4) driver again.

It was disabled as some parts of UEFI support had not yet been merged to
stable/10.

Sponsored by: The FreeBSD Foundation

10 years agoMFC r263826: Update EFI framebuffer handoff from loader
emaste [Tue, 2 Sep 2014 18:54:40 +0000 (18:54 +0000)]
MFC r263826: Update EFI framebuffer handoff from loader

Sponsored by: The FreeBSD Foundation

10 years agoMFC r270179:
ngie [Tue, 2 Sep 2014 16:14:16 +0000 (16:14 +0000)]
MFC r270179:

  Add missing libraries to DPADD; sort DPADD so DPADD and LDADD match up

  This fixes "make checkdpadd"

  Approved by: jmmv (mentor)
  Phabric: D630
  PR: 192765

10 years agoMFC elfdump improvements
emaste [Tue, 2 Sep 2014 15:49:33 +0000 (15:49 +0000)]
MFC elfdump improvements

r269092: Improve section type reporting

  The SHT range 0x70000000-0x7fffffff is processor-specific.  Pass the
  ELF machine type header to sh_types so the section header type name can
  be reported correctly for the given processor.

  For all ranges report the actual value for unknown types.

  Add MIPS-specific type SHT_MIPS_OPTIONS.

r269143 (andreast): Further improvements on elfdump, to follow up r269092:

  - Add ARM specific section header types.
  - Add SHT_GNU_HASH section header type.
  - Improve reporting of undefined tags in d_tags.
  - Add DT_GNU_HASH tag.

  Reviewed by: emaste

r269337: add EM_AARCH64 64-bit ARM machine architecture

r269338: use existing ELF constants where available

r270303: Rename DT_FEATURE_1 to DT_FEATURE

  This provides a minor cleanup in elfdump; there are otherwise no
  consumers in the tree.  Old SUN documentation can be found for either
  variant, but GNU binutils switched to DT_FEATURE around 2000.

r270304: Remove extraneous _SUNW_ in reported DT_ names

Sponsored by: The FreeBSD Foundation

10 years agoFix ABI broken in r270576. This is direct commit to stable/10.
glebius [Mon, 1 Sep 2014 08:34:39 +0000 (08:34 +0000)]
Fix ABI broken in r270576. This is direct commit to stable/10.

Reported by: kib

10 years agoMFC r257985:
ae [Mon, 1 Sep 2014 08:33:38 +0000 (08:33 +0000)]
MFC r257985:
  Fix panic with RADIX_MPATH, when RTFREE_LOCKED() called for already
  unlocked route. Use in6_rtalloc() instead of in6_rtalloc1. This helps
  simplify the code and remove several now unused variables.

  PR: 156283

10 years agoMFC r270135:
trasz [Mon, 1 Sep 2014 08:08:32 +0000 (08:08 +0000)]
MFC r270135:

Remove vestiges of previous autofs.

Discussed with: alfred@
Sponsored by: The FreeBSD Foundation

10 years agoMFC r270803:
kib [Mon, 1 Sep 2014 08:02:23 +0000 (08:02 +0000)]
MFC r270803:
Document the whole settings needed to build a debug version of rtld.

10 years agoFix a leak of the wired pages when unwiring of the PROT_NONE-mapped
kib [Mon, 1 Sep 2014 07:58:15 +0000 (07:58 +0000)]
Fix a leak of the wired pages when unwiring of the PROT_NONE-mapped
wired region.  Rework the handling of unwire to do the it in batch,
both at pmap and object level.

All commits below are by alc.

MFC r268327:
Introduce pmap_unwire().

MFC r268591:
Implement pmap_unwire() for powerpc.

MFC r268776:
Implement pmap_unwire() for arm.

MFC r268806:
pmap_unwire(9) man page.

MFC r269134:
When unwiring a region of an address space, do not assume that the
underlying physical pages are mapped by the pmap.  This fixes a leak
of the wired pages on the unwiring of the region mapped with no access
allowed.

MFC r269339:
In the implementation of the new function pmap_unwire(), the call to
MOEA64_PVO_TO_PTE() must be performed before any changes are made to the
PVO. Otherwise, MOEA64_PVO_TO_PTE() will panic.

MFC r269365:
Correct a long-standing problem in moea{,64}_pvo_enter() that was revealed
by the combination of r268591 and r269134: When we attempt to add the
wired attribute to an existing mapping, moea{,64}_pvo_enter() do nothing.
(They only set the wired attribute on newly created mappings.)

MFC r269433:
Handle wiring failures in vm_map_wire() with the new functions
pmap_unwire() and vm_object_unwire().
Retire vm_fault_{un,}wire(), since they are no longer used.

MFC r269438:
Rewrite a loop in vm_map_wire() so that gcc doesn't think that the variable
"rv" is uninitialized.

MFC r269485:
Retire pmap_change_wiring().

Reviewed by: alc

10 years agoMFC of 270755, 270772, 270773, 270775, 270799, 270806, 270807, 270820
jfv [Mon, 1 Sep 2014 07:54:30 +0000 (07:54 +0000)]
MFC of 270755, 270772, 270773, 270775, 270799, 270806, 270807, 270820
Enable the build of the Intel XL710 drivers, and fixes for that build.

10 years agoMFC r270445:
ae [Mon, 1 Sep 2014 07:34:16 +0000 (07:34 +0000)]
MFC r270445:
  The size of the GPT table can not be less than one sector.

MFC r270521:
  Since the size of GPT entry may differ from the sizeof(struct gpt_ent),
  use the size from GPT header to iterate entries.

10 years agoMFC r270433:
ngie [Mon, 1 Sep 2014 03:22:47 +0000 (03:22 +0000)]
MFC r270433:

  Garbage collect libl dependency

  The application links and runs without libl

  Approved by: rpaulo (mentor)
  Phabric: D673
  Submitted by: trociny

10 years agoMFC r270117:
ngie [Mon, 1 Sep 2014 03:20:10 +0000 (03:20 +0000)]
MFC r270117:

  Add -ll to LDADD to fix "make checkdpadd"

  Phabric: D622
  Approved by: rpaulo (mentor)

10 years agoMFC r270146:
ngie [Mon, 1 Sep 2014 03:04:59 +0000 (03:04 +0000)]
MFC r270146:

  Add LIBCRYPTO and LIBSSL to DPADD

  This fixes "make checkdpadd"

  Phabric: D621
  PR: 192761
  Approved by: rpaulo (mentor)

10 years agoMFC r270145:
ngie [Mon, 1 Sep 2014 02:53:32 +0000 (02:53 +0000)]
MFC r270145:

  Replace DPADD with DPSRCS to fix "make checkdpadd"

  Phabric: D625
  Approved by: jmmv (mentor)
  Reviewed by: dim
  PR: 192734

10 years agoMFC r270432:
ngie [Mon, 1 Sep 2014 01:39:20 +0000 (01:39 +0000)]
MFC r270432:

  Fix "make checkdpadd" in usr.bin/iscsictl by removing -lfl dependency

  Approved by: rpaulo (mentor)
  MFC after: 1 week

10 years agoMFC r266650, r267172 (both by jmmv):
ngie [Sun, 31 Aug 2014 23:09:23 +0000 (23:09 +0000)]
MFC r266650, r267172 (both by jmmv):

r266650:

  Change libatf-c and libatf-c++ to be private libraries.

  We should not be leaking these interfaces to the outside world given
  that it's much easier for third-party components to use the devel/atf
  package from ports.

  As a side-effect, we can also drop the ATF pkgconfig and aclocal files
  from the base system.  Nothing in the base system needs these, and it
  was quite ugly to have to get them installed only so that a few ports
  could build.  The offending ports have been fixed to depend on
  devel/atf explicitly.

  Reviewed by:  bapt

r267172:

  Homogenize libatf-* version numbers with upstream.

  The libatf-* major version numbers in FreeBSD were one version ahead of
  upstream because, when atf was first imported into FreeBSD, the upstream
  numbers were not respected.  This is just confusing and bound to cause
  problems down the road.

  Fix this by taking advantage of the fact that libatf-* are now private
  and that atf is not yet built by default.  However, and unfortunately, a
  clean build is needed for tests to continue working once "make
  delete-old-libs" has been run; hence the note in UPDATING.

Phabric: D701
Approved by: jmmv (maintainer, mentor)

10 years agoMFC r270507:
trasz [Sun, 31 Aug 2014 21:58:07 +0000 (21:58 +0000)]
MFC r270507:

Fix bug that, assuming a/ is a root of NFS filesystem mounted on autofs,
prevented "mv a/from a/to" from working, while "cd a && mv from to" was ok.

PR: 192948
Sponsored by: The FreeBSD Foundation

10 years agoMFC r270454:
trasz [Sun, 31 Aug 2014 21:56:42 +0000 (21:56 +0000)]
MFC r270454:

Fix handling of keys in executable maps.  Previously it was broken for keys
containing whitespace.

PR: 192947
Sponsored by: The FreeBSD Foundation

10 years agoMFC r270406:
trasz [Sun, 31 Aug 2014 21:55:08 +0000 (21:55 +0000)]
MFC r270406:

Add "nobrowse" option.  Previously automountd(8) always behaved as if
it was set, now it's conditional.

PR: 192862
Sponsored by: The FreeBSD Foundation

10 years agoMFC r270405:
trasz [Sun, 31 Aug 2014 21:53:42 +0000 (21:53 +0000)]
MFC r270405:

Don't fail on executable maps that return no entries.  This turns useless
error message into useful one.

Sponsored by: The FreeBSD Foundation

10 years agoMFC r270402:
trasz [Sun, 31 Aug 2014 21:52:26 +0000 (21:52 +0000)]
MFC r270402:

Autofs softc needs to be global anyway, so don't pass it as a local
variable, and don't store in autofs_mount.  Also rename it from 'sc'
to 'autofs_softc', since it's global and extern.

Sponsored by: The FreeBSD Foundation

10 years agoMFC r270399:
trasz [Sun, 31 Aug 2014 21:51:01 +0000 (21:51 +0000)]
MFC r270399:

Add comment explaining one of the quirks in autofs.

Sponsored by: The FreeBSD Foundation

10 years agoMFC r270281:
trasz [Sun, 31 Aug 2014 21:49:45 +0000 (21:49 +0000)]
MFC r270281:

Fix includes.

Suggested by: pluknet@
Sponsored by: The FreeBSD Foundation

10 years agoMFC r270276:
trasz [Sun, 31 Aug 2014 21:48:12 +0000 (21:48 +0000)]
MFC r270276:

Use __FBSDID() properly.

Suggested by: pluknet@
Sponsored by: The FreeBSD Foundation

10 years agoMFC r270210:
trasz [Sun, 31 Aug 2014 21:46:32 +0000 (21:46 +0000)]
MFC r270210:

Remove useless - and buggy, it resulted in spurious warnings in logs - code.

Sponsored by: The FreeBSD Foundation

10 years agoMFC r270209:
trasz [Sun, 31 Aug 2014 21:45:07 +0000 (21:45 +0000)]
MFC r270209:

Add description for the "automounted" mount flag.

Reviewed by: emaste@
Sponsored by: The FreeBSD Foundation

10 years agoMFC r270207:
trasz [Sun, 31 Aug 2014 21:43:28 +0000 (21:43 +0000)]
MFC r270207:

Rework ".." lookup; previous one failed to properly busy the mountpoint.

Reviewed by: kib@
Sponsored by: The FreeBSD Foundation

10 years agoMFC r270096:
trasz [Sun, 31 Aug 2014 21:18:23 +0000 (21:18 +0000)]
MFC r270096:

Bring in the new automounter, similar to what's provided in most other
UNIX systems, eg. MacOS X and Solaris.  It uses Sun-compatible map format,
has proper kernel support, and LDAP integration.

There are still a few outstanding problems; they will be fixed shortly.

Reviewed by: allanjude@, emaste@, kib@, wblock@ (earlier versions)
Phabric: D523
Relnotes: yes
Sponsored by: The FreeBSD Foundation

10 years agoMFC r270282:
trasz [Sun, 31 Aug 2014 20:47:10 +0000 (20:47 +0000)]
MFC r270282:

Use proper include paths in kernel iSCSI code.

Sponsored by: The FreeBSD Foundation