diff options
author | Renato Botelho <renato@netgate.com> | 2016-02-15 09:46:16 -0200 |
---|---|---|
committer | Renato Botelho <renato@netgate.com> | 2016-02-15 09:46:16 -0200 |
commit | 51145f6d236c6fef7e3df24ff1ed1947de914e58 (patch) | |
tree | 461add4658cb859338055f2682faabe5ac7b1c37 | |
parent | c5df3d0f11ca3b170da878cdd4782fc603c15460 (diff) | |
parent | 744ea196e52f4821042acc2a9b289ee54aea5202 (diff) | |
download | FreeBSD-src-51145f6d236c6fef7e3df24ff1ed1947de914e58.zip FreeBSD-src-51145f6d236c6fef7e3df24ff1ed1947de914e58.tar.gz |
Merge remote-tracking branch 'origin/stable/10' into devel
-rwxr-xr-x | etc/rc.d/ntpd | 8 | ||||
-rw-r--r-- | share/man/man8/uefi.8 | 13 | ||||
-rw-r--r-- | sys/dev/drm2/drmP.h | 6 | ||||
-rw-r--r-- | sys/dev/drm2/drm_fops.c | 2 | ||||
-rw-r--r-- | sys/dev/drm2/drm_stub.c | 6 | ||||
-rw-r--r-- | sys/dev/drm2/i915/i915_dma.c | 2 | ||||
-rw-r--r-- | sys/dev/drm2/i915/intel_opregion.c | 4 | ||||
-rw-r--r-- | sys/fs/devfs/devfs_devs.c | 7 | ||||
-rw-r--r-- | sys/kern/tty.c | 15 | ||||
-rw-r--r-- | sys/kern/vfs_vnops.c | 5 |
10 files changed, 43 insertions, 25 deletions
diff --git a/etc/rc.d/ntpd b/etc/rc.d/ntpd index 7f28358..fe2fc4b 100755 --- a/etc/rc.d/ntpd +++ b/etc/rc.d/ntpd @@ -28,14 +28,14 @@ ntpd_precmd() rc_flags="-g $rc_flags" fi - if [ -z "$ntpd_chrootdir" ]; then - return 0; - fi - if [ ! -f $ntp_db_leapfile ]; then ntpd_fetch_leapfile fi + if [ -z "$ntpd_chrootdir" ]; then + return 0; + fi + # If running in a chroot cage, ensure that the appropriate files # exist inside the cage, as well as helper symlinks into the cage # from outside. diff --git a/share/man/man8/uefi.8 b/share/man/man8/uefi.8 index 94000dd..8907ef3 100644 --- a/share/man/man8/uefi.8 +++ b/share/man/man8/uefi.8 @@ -24,7 +24,7 @@ .\" .\" $FreeBSD$ .\" -.Dd February 26, 2015 +.Dd February 14, 2016 .Dt UEFI 8 .Os .Sh NAME @@ -73,6 +73,16 @@ as .Pa /EFI/BOOT/BOOTX64.EFI . .It .Pa boot1.efi +reads boot configuration from +.Pa /boot.config +or +.Pa /boot/config . +Unlike other first-stage boot loaders, +.Pa boot1.efi +passes the configuration to the next stage boot loader and does not +itself act on the contents of the file. +.It +.Pa boot1.efi locates the first partition with the type .Li freebsd-ufs , and from it loads @@ -112,6 +122,7 @@ typical non-default kernel (optional) .El .Sh SEE ALSO .Xr vt 4 , +.Xr boot.config 5 , .Xr msdosfs 5 , .Xr boot 8 , .Xr gpart 8 , diff --git a/sys/dev/drm2/drmP.h b/sys/dev/drm2/drmP.h index f028d81..5d625a7 100644 --- a/sys/dev/drm2/drmP.h +++ b/sys/dev/drm2/drmP.h @@ -1757,12 +1757,6 @@ void drm_driver_irq_preinstall(struct drm_device *dev); void drm_driver_irq_postinstall(struct drm_device *dev); void drm_driver_irq_uninstall(struct drm_device *dev); -/* AGP/PCI Express/GART support (drm_agpsupport.c) */ -void *drm_agp_allocate_memory(size_t pages, u32 type); -int drm_agp_free_memory(void *handle); -int drm_agp_bind_memory(void *handle, off_t start); -int drm_agp_unbind_memory(void *handle); - /* sysctl support (drm_sysctl.h) */ extern int drm_sysctl_init(struct drm_device *dev); extern int drm_sysctl_cleanup(struct drm_device *dev); diff --git a/sys/dev/drm2/drm_fops.c b/sys/dev/drm2/drm_fops.c index b73cec6..3b3be06 100644 --- a/sys/dev/drm2/drm_fops.c +++ b/sys/dev/drm2/drm_fops.c @@ -136,7 +136,7 @@ int drm_open(struct cdev *kdev, int flags, int fmt, DRM_STRUCTPROC *p) sx_xlock(&drm_global_mutex); /* - * FIXME Linux<->FreeBSD: On Linux, counter updated outisde + * FIXME Linux<->FreeBSD: On Linux, counter updated outside * global mutex. */ if (!dev->open_count++) diff --git a/sys/dev/drm2/drm_stub.c b/sys/dev/drm2/drm_stub.c index d7ec6cb..06663ac 100644 --- a/sys/dev/drm2/drm_stub.c +++ b/sys/dev/drm2/drm_stub.c @@ -94,9 +94,9 @@ static int drm_minor_get_id(struct drm_device *dev, int type) if (type == DRM_MINOR_CONTROL) { new_id += 64; - } else if (type == DRM_MINOR_RENDER) { - new_id += 128; - } + } else if (type == DRM_MINOR_RENDER) { + new_id += 128; + } return new_id; } diff --git a/sys/dev/drm2/i915/i915_dma.c b/sys/dev/drm2/i915/i915_dma.c index 910b35a..353c081 100644 --- a/sys/dev/drm2/i915/i915_dma.c +++ b/sys/dev/drm2/i915/i915_dma.c @@ -1458,6 +1458,8 @@ i915_driver_load(struct drm_device *dev, unsigned long flags) } } + pci_enable_busmaster(dev->dev); + intel_opregion_init(dev); callout_init(&dev_priv->hangcheck_timer, 1); diff --git a/sys/dev/drm2/i915/intel_opregion.c b/sys/dev/drm2/i915/intel_opregion.c index 411e530..397c559 100644 --- a/sys/dev/drm2/i915/intel_opregion.c +++ b/sys/dev/drm2/i915/intel_opregion.c @@ -533,11 +533,9 @@ void intel_opregion_fini(struct drm_device *dev) opregion->vbt = NULL; } #else -int +void intel_opregion_init(struct drm_device *dev) { - - return (0); } void diff --git a/sys/fs/devfs/devfs_devs.c b/sys/fs/devfs/devfs_devs.c index 5070985..4723a63 100644 --- a/sys/fs/devfs/devfs_devs.c +++ b/sys/fs/devfs/devfs_devs.c @@ -304,6 +304,13 @@ devfs_vmkdir(struct devfs_mount *dmp, char *name, int namelen, struct devfs_dire void devfs_dirent_free(struct devfs_dirent *de) { + struct vnode *vp; + + vp = de->de_vnode; + mtx_lock(&devfs_de_interlock); + if (vp != NULL && vp->v_data == de) + vp->v_data = NULL; + mtx_unlock(&devfs_de_interlock); free(de, M_DEVFS3); } diff --git a/sys/kern/tty.c b/sys/kern/tty.c index ddde7b3..0e352a6 100644 --- a/sys/kern/tty.c +++ b/sys/kern/tty.c @@ -215,7 +215,7 @@ ttydev_leave(struct tty *tp) ttydisc_close(tp); - /* Destroy associated buffers already. */ + /* Free i/o queues now since they might be large. */ ttyinq_free(&tp->t_inq); tp->t_inlow = 0; ttyoutq_free(&tp->t_outq); @@ -1052,10 +1052,15 @@ tty_dealloc(void *arg) { struct tty *tp = arg; - /* Make sure we haven't leaked buffers. */ - MPASS(ttyinq_getsize(&tp->t_inq) == 0); - MPASS(ttyoutq_getsize(&tp->t_outq) == 0); - + /* + * ttyydev_leave() usually frees the i/o queues earlier, but it is + * not always called between queue allocation and here. The queues + * may be allocated by ioctls on a pty control device without the + * corresponding pty slave device ever being open, or after it is + * closed. + */ + ttyinq_free(&tp->t_inq); + ttyoutq_free(&tp->t_outq); seldrain(&tp->t_inpoll); seldrain(&tp->t_outpoll); knlist_destroy(&tp->t_inpoll.si_note); diff --git a/sys/kern/vfs_vnops.c b/sys/kern/vfs_vnops.c index d4c8693..e35fd35 100644 --- a/sys/kern/vfs_vnops.c +++ b/sys/kern/vfs_vnops.c @@ -733,12 +733,13 @@ get_advice(struct file *fp, struct uio *uio) int ret; ret = POSIX_FADV_NORMAL; - if (fp->f_advice == NULL) + if (fp->f_advice == NULL || fp->f_vnode->v_type != VREG) return (ret); mtxp = mtx_pool_find(mtxpool_sleep, fp); mtx_lock(mtxp); - if (uio->uio_offset >= fp->f_advice->fa_start && + if (fp->f_advice != NULL && + uio->uio_offset >= fp->f_advice->fa_start && uio->uio_offset + uio->uio_resid <= fp->f_advice->fa_end) ret = fp->f_advice->fa_advice; mtx_unlock(mtxp); |