svn commit: r256878 - head/etc/rc.d
Author: des Date: Tue Oct 22 07:44:26 2013 New Revision: 256878 URL: http://svnweb.freebsd.org/changeset/base/256878 Log: Add a reload command. Reviewed by: hrs MFC after:3 days Modified: head/etc/rc.d/rtadvd Modified: head/etc/rc.d/rtadvd == --- head/etc/rc.d/rtadvdTue Oct 22 07:17:22 2013(r256877) +++ head/etc/rc.d/rtadvdTue Oct 22 07:44:26 2013(r256878) @@ -14,6 +14,8 @@ name="rtadvd" rcvar="rtadvd_enable" command="/usr/sbin/${name}" +extra_commands="reload" +reload_cmd="rtadvd_reload" start_precmd="rtadvd_precmd" rtadvd_precmd() @@ -62,5 +64,9 @@ rtadvd_precmd() return 0 } +rtadvd_reload() { + /usr/sbin/rtadvctl reload +} + load_rc_config $name run_rc_command "$1" ___ svn-src-head@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
svn commit: r256880 - in head/sys: cam/ata cam/scsi cddl/contrib/opensolaris/uts/common/fs/zfs dev/md geom geom/concat geom/gate geom/mirror geom/multipath geom/nop geom/part geom/raid geom/stripe ...
Author: mav Date: Tue Oct 22 08:22:19 2013 New Revision: 256880 URL: http://svnweb.freebsd.org/changeset/base/256880 Log: Merge GEOM direct dispatch changes from the projects/camlock branch. When safety requirements are met, it allows to avoid passing I/O requests to GEOM g_up/g_down thread, executing them directly in the caller context. That allows to avoid CPU bottlenecks in g_up/g_down threads, plus avoid several context switches per I/O. The defined now safety requirements are: - caller should not hold any locks and should be reenterable; - callee should not depend on GEOM dual-threaded concurency semantics; - on the way down, if request is unmapped while callee doesn't support it, the context should be sleepable; - kernel thread stack usage should be below 50%. To keep compatibility with GEOM classes not meeting above requirements new provider and consumer flags added: - G_CF_DIRECT_SEND -- consumer code meets caller requirements (request); - G_CF_DIRECT_RECEIVE -- consumer code meets callee requirements (done); - G_PF_DIRECT_SEND -- provider code meets caller requirements (done); - G_PF_DIRECT_RECEIVE -- provider code meets callee requirements (request). Capable GEOM class can set them, allowing direct dispatch in cases where it is safe. If any of requirements are not met, request is queued to g_up or g_down thread same as before. Such GEOM classes were reviewed and updated to support direct dispatch: CONCAT, DEV, DISK, GATE, MD, MIRROR, MULTIPATH, NOP, PART, RAID, STRIPE, VFS, ZERO, ZFS::VDEV, ZFS::ZVOL, all classes based on g_slice KPI (LABEL, MAP, FLASHMAP, etc). To declare direct completion capability disk(9) KPI got new flag equivalent to G_PF_DIRECT_SEND -- DISKFLAG_DIRECT_COMPLETION. da(4) and ada(4) disk drivers got it set now thanks to earlier CAM locking work. This change more then twice increases peak block storage performance on systems with manu CPUs, together with earlier CAM locking changes reaching more then 1 million IOPS (512 byte raw reads from 16 SATA SSDs on 4 HBAs to 256 user-level threads). Sponsored by: iXsystems, Inc. MFC after:2 months Modified: head/sys/cam/ata/ata_da.c head/sys/cam/scsi/scsi_da.c head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/vdev_geom.c head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zvol.c head/sys/dev/md/md.c head/sys/geom/concat/g_concat.c head/sys/geom/concat/g_concat.h head/sys/geom/gate/g_gate.c head/sys/geom/geom.h head/sys/geom/geom_dev.c head/sys/geom/geom_disk.c head/sys/geom/geom_disk.h head/sys/geom/geom_int.h head/sys/geom/geom_io.c head/sys/geom/geom_kern.c head/sys/geom/geom_slice.c head/sys/geom/geom_vfs.c head/sys/geom/mirror/g_mirror.c head/sys/geom/mirror/g_mirror.h head/sys/geom/multipath/g_multipath.c head/sys/geom/nop/g_nop.c head/sys/geom/nop/g_nop.h head/sys/geom/part/g_part.c head/sys/geom/raid/g_raid.c head/sys/geom/raid/md_ddf.c head/sys/geom/raid/md_intel.c head/sys/geom/raid/md_jmicron.c head/sys/geom/raid/md_nvidia.c head/sys/geom/raid/md_promise.c head/sys/geom/raid/md_sii.c head/sys/geom/stripe/g_stripe.c head/sys/geom/stripe/g_stripe.h head/sys/geom/zero/g_zero.c head/sys/kern/subr_devstat.c head/sys/sys/proc.h Modified: head/sys/cam/ata/ata_da.c == --- head/sys/cam/ata/ata_da.c Tue Oct 22 07:59:14 2013(r256879) +++ head/sys/cam/ata/ata_da.c Tue Oct 22 08:22:19 2013(r256880) @@ -1253,7 +1253,7 @@ adaregister(struct cam_periph *periph, v maxio = min(maxio, 256 * softc->params.secsize); softc->disk->d_maxsize = maxio; softc->disk->d_unit = periph->unit_number; - softc->disk->d_flags = 0; + softc->disk->d_flags = DISKFLAG_DIRECT_COMPLETION; if (softc->flags & ADA_FLAG_CAN_FLUSHCACHE) softc->disk->d_flags |= DISKFLAG_CANFLUSHCACHE; if (softc->flags & ADA_FLAG_CAN_TRIM) { Modified: head/sys/cam/scsi/scsi_da.c == --- head/sys/cam/scsi/scsi_da.c Tue Oct 22 07:59:14 2013(r256879) +++ head/sys/cam/scsi/scsi_da.c Tue Oct 22 08:22:19 2013(r256880) @@ -2125,7 +2125,7 @@ daregister(struct cam_periph *periph, vo else softc->disk->d_maxsize = cpi.maxio; softc->disk->d_unit = periph->unit_number; - softc->disk->d_flags = 0; + softc->disk->d_flags = DISKFLAG_DIRECT_COMPLETION; if ((softc->quirks & DA_Q_NO_SYNC_CACHE) == 0) softc->disk->d_flags |= DISKFLAG_CANFLUSHCACHE; if ((cpi.hba_misc & PIM_UNMAPPED) != 0) Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/vdev_geom.c == --- head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/vdev_ge
svn commit: r256884 - in head: share/man/man9 sys/geom
Author: mav Date: Tue Oct 22 10:21:20 2013 New Revision: 256884 URL: http://svnweb.freebsd.org/changeset/base/256884 Log: Remove Giant-locked drivers support (DISKFLAG_NEEDSGIANT flag) from disk(9). Since at least FreeBSD 7 we had only four of them in the base tree, and in head branch, thanks to jhb@, we have no any for more then a year. Modified: head/share/man/man9/disk.9 head/sys/geom/geom_disk.c head/sys/geom/geom_disk.h Modified: head/share/man/man9/disk.9 == --- head/share/man/man9/disk.9 Tue Oct 22 10:10:34 2013(r256883) +++ head/share/man/man9/disk.9 Tue Oct 22 10:21:20 2013(r256884) @@ -106,8 +106,6 @@ and may not be subsequently changed: Optional flags indicating to the storage framework what optional features or descriptions the storage device driver supports. Currently supported flags are -.Dv DISKFLAG_NEEDSGIANT -(maintained by device driver), .Dv DISKFLAG_OPEN (maintained by storage framework), .Dv DISKFLAG_CANDELETE Modified: head/sys/geom/geom_disk.c == --- head/sys/geom/geom_disk.c Tue Oct 22 10:10:34 2013(r256883) +++ head/sys/geom/geom_disk.c Tue Oct 22 10:21:20 2013(r256884) @@ -91,22 +91,6 @@ static SYSCTL_NODE(_kern_geom, OID_AUTO, DECLARE_GEOM_CLASS(g_disk_class, g_disk); -static void __inline -g_disk_lock_giant(struct disk *dp) -{ - - if (dp->d_flags & DISKFLAG_NEEDSGIANT) - mtx_lock(&Giant); -} - -static void __inline -g_disk_unlock_giant(struct disk *dp) -{ - - if (dp->d_flags & DISKFLAG_NEEDSGIANT) - mtx_unlock(&Giant); -} - static int g_disk_access(struct g_provider *pp, int r, int w, int e) { @@ -133,12 +117,10 @@ g_disk_access(struct g_provider *pp, int error = 0; if ((pp->acr + pp->acw + pp->ace) == 0 && (r + w + e) > 0) { if (dp->d_open != NULL) { - g_disk_lock_giant(dp); error = dp->d_open(dp); if (bootverbose && error != 0) printf("Opened disk %s -> %d\n", pp->name, error); - g_disk_unlock_giant(dp); if (error != 0) return (error); } @@ -161,12 +143,10 @@ g_disk_access(struct g_provider *pp, int dp->d_flags |= DISKFLAG_OPEN; } else if ((pp->acr + pp->acw + pp->ace) > 0 && (r + w + e) == 0) { if (dp->d_close != NULL) { - g_disk_lock_giant(dp); error = dp->d_close(dp); if (error != 0) printf("Closed disk %s -> %d\n", pp->name, error); - g_disk_unlock_giant(dp); } sc->state = G_STATE_ACTIVE; if (sc->led[0] != 0) @@ -287,9 +267,7 @@ g_disk_ioctl(struct g_provider *pp, u_lo if (dp->d_ioctl == NULL) return (ENOIOCTL); - g_disk_lock_giant(dp); error = dp->d_ioctl(dp, cmd, data, fflag, td); - g_disk_unlock_giant(dp); return (error); } @@ -328,9 +306,7 @@ g_disk_start(struct bio *bp) mtx_lock(&sc->start_mtx); devstat_start_transaction_bio(dp->d_devstat, bp); mtx_unlock(&sc->start_mtx); - g_disk_lock_giant(dp); dp->d_strategy(bp); - g_disk_unlock_giant(dp); break; } off = 0; @@ -384,9 +360,7 @@ g_disk_start(struct bio *bp) mtx_lock(&sc->start_mtx); devstat_start_transaction_bio(dp->d_devstat, bp2); mtx_unlock(&sc->start_mtx); - g_disk_lock_giant(dp); dp->d_strategy(bp2); - g_disk_unlock_giant(dp); bp2 = bp3; bp3 = NULL; } while (bp2 != NULL); @@ -442,9 +416,7 @@ g_disk_start(struct bio *bp) bp->bio_disk = dp; bp->bio_to = (void *)bp->bio_done; bp->bio_done = g_disk_done_single; - g_disk_lock_giant(dp); dp->d_strategy(bp); - g_disk_unlock_giant(dp); break; default: error = EOPNOTSUPP; Modified: head/sys/geom/geom_disk.h == --- head/sys/geom/geom_disk.h Tue Oct 22 10:10:34 2013(r256883) +++ head/sys/geom/geom_disk.h Tue Oct 22 10:21:20 2013(r256884) @@ -102,7 +102,6 @@ struct disk { void*d_drv1; }; -#define DISKFLAG_NEE
svn commit: r256885 - head/sys/kern
Author: mav Date: Tue Oct 22 10:40:26 2013 New Revision: 256885 URL: http://svnweb.freebsd.org/changeset/base/256885 Log: Remove global device lock acquisition from dev_relthread(), replacing it with atomics on per-device data. Modified: head/sys/kern/kern_conf.c Modified: head/sys/kern/kern_conf.c == --- head/sys/kern/kern_conf.c Tue Oct 22 10:21:20 2013(r256884) +++ head/sys/kern/kern_conf.c Tue Oct 22 10:40:26 2013(r256885) @@ -193,7 +193,7 @@ dev_refthread(struct cdev *dev, int *ref if (csw != NULL) { cdp = cdev2priv(dev); if ((cdp->cdp_flags & CDP_SCHED_DTR) == 0) - dev->si_threadcount++; + atomic_add_long(&dev->si_threadcount, 1); else csw = NULL; } @@ -234,7 +234,7 @@ devvn_refthread(struct vnode *vp, struct if ((cdp->cdp_flags & CDP_SCHED_DTR) == 0) { csw = dev->si_devsw; if (csw != NULL) - dev->si_threadcount++; + atomic_add_long(&dev->si_threadcount, 1); } dev_unlock(); if (csw != NULL) { @@ -251,11 +251,9 @@ dev_relthread(struct cdev *dev, int ref) mtx_assert(&devmtx, MA_NOTOWNED); if (!ref) return; - dev_lock(); KASSERT(dev->si_threadcount > 0, ("%s threadcount is wrong", dev->si_name)); - dev->si_threadcount--; - dev_unlock(); + atomic_subtract_rel_long(&dev->si_threadcount, 1); } int ___ svn-src-head@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
svn commit: r256886 - head/share/man/man4
Author: mav Date: Tue Oct 22 11:56:46 2013 New Revision: 256886 URL: http://svnweb.freebsd.org/changeset/base/256886 Log: Update ahci(4), respecting recent driver changes. Modified: head/share/man/man4/ahci.4 Modified: head/share/man/man4/ahci.4 == --- head/share/man/man4/ahci.4 Tue Oct 22 10:40:26 2013(r256885) +++ head/share/man/man4/ahci.4 Tue Oct 22 11:56:46 2013(r256886) @@ -1,4 +1,4 @@ -.\" Copyright (c) 2009-2012 Alexander Motin +.\" Copyright (c) 2009-2013 Alexander Motin .\" All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without @@ -24,7 +24,7 @@ .\" .\" $FreeBSD$ .\" -.Dd July 25, 2012 +.Dd October 22, 2013 .Dt AHCI 4 .Os .Sh NAME @@ -57,9 +57,9 @@ controls Message Signaled Interrupts (MS .It 0 MSI disabled; .It 1 -single MSI vector used, if supported (default); +single MSI vector used, if supported; .It 2 -multiple MSI vectors used, if supported; +multiple MSI vectors used, if supported (default); .El .It Va hint.ahci. Ns Ar X Ns Va .ccc controls Command Completion Coalescing (CCC) usage by the specified controller. @@ -68,6 +68,11 @@ for interrupt, if there are some more re CCC reduces number of context switches on systems with many parallel requests, but it can decrease disk performance on some workloads due to additional command latency. +.It Va hint.ahci. Ns Ar X Ns Va .direct +controls whether the driver should use direct command completion from +interrupt thread(s), or queue them to CAM completion threads. +Default value depends on number of MSI interrupts supported and number of +implemented SATA ports. .It Va hint.ahcich. Ns Ar X Ns Va .pm_level controls SATA interface Power Management for the specified channel, allowing some power to be saved at the cost of additional command ___ svn-src-head@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
svn commit: r256887 - head/sys/dev/aha
Author: mav Date: Tue Oct 22 12:42:49 2013 New Revision: 256887 URL: http://svnweb.freebsd.org/changeset/base/256887 Log: Fix memory and references leak due to unfreed path. Coverity CID: 1109817 Modified: head/sys/dev/aha/aha.c Modified: head/sys/dev/aha/aha.c == --- head/sys/dev/aha/aha.c Tue Oct 22 11:56:46 2013(r256886) +++ head/sys/dev/aha/aha.c Tue Oct 22 12:42:49 2013(r256887) @@ -1168,8 +1168,10 @@ ahadone(struct aha_softc *aha, struct ah cam_sim_path(aha->sim), accb->hccb.target, CAM_LUN_WILDCARD); - if (error == CAM_REQ_CMP) + if (error == CAM_REQ_CMP) { xpt_async(AC_SENT_BDR, path, NULL); + xpt_free_path(path); + } ccb_h = LIST_FIRST(&aha->pending_ccbs); while (ccb_h != NULL) { ___ svn-src-head@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
svn commit: r256888 - head/sys/cam
Author: mav Date: Tue Oct 22 12:58:22 2013 New Revision: 256888 URL: http://svnweb.freebsd.org/changeset/base/256888 Log: Unconditionally acquire periph reference on CCB allocation failure. cam_periph_acquire() can return error if periph already invalidated, but that may be unacceptable and cause deadlock if the invalidated periph can't be destroyed without "executing" the scheduled request. Coverity CID: 1109822 MFC after:2 months Modified: head/sys/cam/cam_xpt.c Modified: head/sys/cam/cam_xpt.c == --- head/sys/cam/cam_xpt.c Tue Oct 22 12:42:49 2013(r256887) +++ head/sys/cam/cam_xpt.c Tue Oct 22 12:58:22 2013(r256888) @@ -3163,10 +3163,11 @@ restart: ccb = xpt_get_ccb(periph); goto restart; } - if (periph->flags & CAM_PERIPH_RUN_TASK) { + if (periph->flags & CAM_PERIPH_RUN_TASK) break; - } - cam_periph_acquire(periph); + xpt_lock_buses(); + periph->refcount++; /* Unconditionally acquire */ + xpt_unlock_buses(); periph->flags |= CAM_PERIPH_RUN_TASK; taskqueue_enqueue(xsoftc.xpt_taskq, &periph->periph_run_task); ___ svn-src-head@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
svn commit: r256889 - head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs
Author: smh Date: Tue Oct 22 13:31:36 2013 New Revision: 256889 URL: http://svnweb.freebsd.org/changeset/base/256889 Log: Use the vdev's ashift to calculate the supported min block size passed to zio_compress_data(..) when compressing l2arc buffers. This eliminates l2arc I/O errors, which resulted in very poor performance on vdev's configured with block size greater than 512b due to compression assuming a smaller min block size than the vdev supports. MFC after:2 days Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/arc.c Modified: head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/arc.c == --- head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/arc.c Tue Oct 22 12:58:22 2013(r256888) +++ head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/arc.c Tue Oct 22 13:31:36 2013(r256889) @@ -5147,7 +5147,7 @@ l2arc_compress_buf(l2arc_buf_hdr_t *l2hd len = l2hdr->b_asize; cdata = zio_data_buf_alloc(len); csize = zio_compress_data(ZIO_COMPRESS_LZ4, l2hdr->b_tmp_cdata, - cdata, l2hdr->b_asize, (size_t)SPA_MINBLOCKSIZE); + cdata, l2hdr->b_asize, (size_t)(1ULL << l2hdr->b_dev->l2ad_vdev->vdev_ashift)); if (csize == 0) { /* zero block, indicate that there's nothing to write */ ___ svn-src-head@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
svn commit: r256893 - head/sys/dev/buslogic
Author: mav Date: Tue Oct 22 13:52:20 2013 New Revision: 256893 URL: http://svnweb.freebsd.org/changeset/base/256893 Log: Fix memory and references leak due to unfreed path. Coverity CID: 1109815 Modified: head/sys/dev/buslogic/bt.c Modified: head/sys/dev/buslogic/bt.c == --- head/sys/dev/buslogic/bt.c Tue Oct 22 13:50:54 2013(r256892) +++ head/sys/dev/buslogic/bt.c Tue Oct 22 13:52:20 2013(r256893) @@ -1586,8 +1586,10 @@ btdone(struct bt_softc *bt, struct bt_cc bccb->hccb.target_id, CAM_LUN_WILDCARD); - if (error == CAM_REQ_CMP) + if (error == CAM_REQ_CMP) { xpt_async(AC_SENT_BDR, path, NULL); + xpt_free_path(path); + } ccb_h = LIST_FIRST(&bt->pending_ccbs); while (ccb_h != NULL) { ___ svn-src-head@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
svn commit: r256895 - head/sys/cam
Author: mav Date: Tue Oct 22 13:56:30 2013 New Revision: 256895 URL: http://svnweb.freebsd.org/changeset/base/256895 Log: Fix memory and references leak due to unfreed path. Coverity CID: 1054773 Modified: head/sys/cam/cam_periph.c Modified: head/sys/cam/cam_periph.c == --- head/sys/cam/cam_periph.c Tue Oct 22 13:53:58 2013(r256894) +++ head/sys/cam/cam_periph.c Tue Oct 22 13:56:30 2013(r256895) @@ -1768,9 +1768,11 @@ cam_periph_error(union ccb *ccb, cam_fla scan_ccb->ccb_h.func_code = XPT_SCAN_TGT; scan_ccb->crcn.flags = 0; xpt_rescan(scan_ccb); - } else + } else { xpt_print(newpath, "Can't allocate CCB to rescan target\n"); + xpt_free_path(newpath); + } } } ___ svn-src-head@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
svn commit: r256898 - in head/sys: conf dev/fdt powerpc/mambo powerpc/ofw powerpc/powermac powerpc/powerpc
Author: nwhitehorn Date: Tue Oct 22 14:07:57 2013 New Revision: 256898 URL: http://svnweb.freebsd.org/changeset/base/256898 Log: Standards-conformance and code deduplication: - Use bus reference phandles in place of FDT offsets as IRQ domain keys - Unify the identical macio/fdt/mambo OpenPIC drivers into one - Be more forgiving (following ePAPR) about what we need from the device tree to identify an OpenPIC - Correctly map all IRQs into an interrupt domain - Set IRQ_*_CONFORM for interrupts on an unknown PIC type instead of failing attachment for that device. Added: head/sys/powerpc/ofw/openpic_ofw.c - copied, changed from r256886, head/sys/powerpc/powermac/openpic_macio.c Deleted: head/sys/powerpc/mambo/mambo_openpic.c head/sys/powerpc/powermac/openpic_macio.c head/sys/powerpc/powerpc/openpic_fdt.c Modified: head/sys/conf/files.powerpc head/sys/dev/fdt/fdt_common.c head/sys/dev/fdt/fdt_pci.c head/sys/dev/fdt/fdt_powerpc.c Modified: head/sys/conf/files.powerpc == --- head/sys/conf/files.powerpc Tue Oct 22 14:00:46 2013(r256897) +++ head/sys/conf/files.powerpc Tue Oct 22 14:07:57 2013(r256898) @@ -124,7 +124,6 @@ powerpc/mambo/mambocall.S optionalmambo powerpc/mambo/mambo.c optionalmambo powerpc/mambo/mambo_console.c optionalmambo powerpc/mambo/mambo_disk.c optionalmambo -powerpc/mambo/mambo_openpic.c optionalmambo powerpc/mpc85xx/atpic.coptionalmpc85xx isa powerpc/mpc85xx/ds1553_bus_fdt.c optionalds1553 fdt powerpc/mpc85xx/ds1553_core.c optionalds1553 @@ -143,6 +142,7 @@ powerpc/ofw/ofw_syscons.c optionalsc ai powerpc/ofw/ofwcall32.Soptionalaim powerpc powerpc/ofw/ofwcall64.Soptionalaim powerpc64 powerpc/ofw/ofwmagic.S optionalaim +powerpc/ofw/openpic_ofw.c optionalaim | fdt powerpc/ofw/rtas.c optionalaim powerpc/powermac/ata_kauai.c optionalpowermac ata | powermac atamacio powerpc/powermac/ata_macio.c optionalpowermac ata | powermac atamacio @@ -158,7 +158,6 @@ powerpc/powermac/kiic.c optionalpowerm powerpc/powermac/macgpio.c optionalpowermac pci powerpc/powermac/macio.c optionalpowermac pci powerpc/powermac/nvbl.coptionalpowermac nvbl -powerpc/powermac/openpic_macio.c optional powermac pci powerpc/powermac/platform_powermac.c optional powermac powerpc/powermac/powermac_thermal.c optional powermac powerpc/powermac/pswitch.c optionalpowermac pswitch @@ -196,7 +195,6 @@ powerpc/powerpc/mmu_if.mstandard powerpc/powerpc/mp_machdep.c optionalsmp powerpc/powerpc/nexus.cstandard powerpc/powerpc/openpic.c standard -powerpc/powerpc/openpic_fdt.c optionalfdt powerpc/powerpc/pic_if.m standard powerpc/powerpc/pmap_dispatch.cstandard powerpc/powerpc/platform.c standard Modified: head/sys/dev/fdt/fdt_common.c == --- head/sys/dev/fdt/fdt_common.c Tue Oct 22 14:00:46 2013 (r256897) +++ head/sys/dev/fdt/fdt_common.c Tue Oct 22 14:07:57 2013 (r256898) @@ -478,21 +478,31 @@ fdt_intr_decode(phandle_t intr_parent, p int *trig, int *pol) { fdt_pic_decode_t intr_decode; + phandle_t intr_offset; int i, rv; + intr_offset = OF_xref_phandle(intr_parent); + for (i = 0; fdt_pic_table[i] != NULL; i++) { /* XXX check if pic_handle has interrupt-controller prop? */ intr_decode = fdt_pic_table[i]; - rv = intr_decode(intr_parent, intr, interrupt, trig, pol); + rv = intr_decode(intr_offset, intr, interrupt, trig, pol); - if (rv == 0) + if (rv == 0) { /* This was recognized as our PIC and decoded. */ + *interrupt = FDT_MAP_IRQ(intr_parent, *interrupt); return (0); + } } - return (ENXIO); + /* Not in table, so guess */ + *interrupt = FDT_MAP_IRQ(intr_parent, fdt32_to_cpu(*intr)); + *trig = INTR_TRIGGER_CONFORM; + *pol = INTR_POLARITY_CONFORM; + + return (0); } int @@ -500,7 +510,7 @@ fdt_intr_to_rl(phandle_t node, struct re struct fdt_sense_level *intr_sl) { phandle_t intr_par; - ihandle_t iph; + phandle_t iph; pcell_t *intr; pcell_t intr_cells; int interrupt, trig, pol; @@ -517,8 +527,7 @@ fdt_intr_to_rl(phandle_t node, struct re debugf("no intr-parent phandle\n"); intr_par = OF_parent(node); } else { - iph = fdt32_to_cpu(iph); -
svn commit: r256899 - head/sys/dev/fdt
Author: nwhitehorn Date: Tue Oct 22 14:08:57 2013 New Revision: 256899 URL: http://svnweb.freebsd.org/changeset/base/256899 Log: Allow lots of interrupts (useful on multi-domain platforms) and do not set device_quiet() on all devices attached under nexus(4). Modified: head/sys/dev/fdt/fdtbus.c Modified: head/sys/dev/fdt/fdtbus.c == --- head/sys/dev/fdt/fdtbus.c Tue Oct 22 14:07:57 2013(r256898) +++ head/sys/dev/fdt/fdtbus.c Tue Oct 22 14:08:57 2013(r256899) @@ -158,9 +158,7 @@ fdtbus_probe(device_t dev) debugf("%s(dev=%p); pass=%u\n", __func__, dev, bus_current_pass); - device_set_desc(dev, "FDT main bus"); - if (!bootverbose) - device_quiet(dev); + device_set_desc(dev, "Flattened Device Tree"); return (BUS_PROBE_NOWILDCARD); } @@ -182,7 +180,7 @@ fdtbus_attach(device_t dev) * IRQ rman. */ start = 0; - end = FDT_INTR_MAX - 1; + end = ~0; sc->sc_irq.rm_start = start; sc->sc_irq.rm_end = end; sc->sc_irq.rm_type = RMAN_ARRAY; ___ svn-src-head@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
svn commit: r256900 - head/sys/dev/cfi
Author: nwhitehorn Date: Tue Oct 22 14:10:00 2013 New Revision: 256900 URL: http://svnweb.freebsd.org/changeset/base/256900 Log: Set BUS_PROBE_NOWILDCARD on this attachment as a stopgap. Unconditionally poking at registers in unknown devices is not the best probe mechanism. This should be reverted and a better solution found later. Modified: head/sys/dev/cfi/cfi_bus_nexus.c Modified: head/sys/dev/cfi/cfi_bus_nexus.c == --- head/sys/dev/cfi/cfi_bus_nexus.cTue Oct 22 14:08:57 2013 (r256899) +++ head/sys/dev/cfi/cfi_bus_nexus.cTue Oct 22 14:10:00 2013 (r256900) @@ -50,14 +50,25 @@ __FBSDID("$FreeBSD$"); static int cfi_nexus_probe(device_t dev) { + return (BUS_PROBE_NOWILDCARD); +} + +static int +cfi_nexus_attach(device_t dev) +{ + int error; + + error = cfi_probe(dev); + if (error != 0) + return (error); - return cfi_probe(dev); + return cfi_attach(dev); } static device_method_t cfi_nexus_methods[] = { /* device interface */ DEVMETHOD(device_probe, cfi_nexus_probe), - DEVMETHOD(device_attach,cfi_attach), + DEVMETHOD(device_attach,cfi_nexus_attach), DEVMETHOD(device_detach,cfi_detach), {0, 0} ___ svn-src-head@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
svn commit: r256901 - head/sys/powerpc/powerpc
Author: nwhitehorn Date: Tue Oct 22 14:11:16 2013 New Revision: 256901 URL: http://svnweb.freebsd.org/changeset/base/256901 Log: Catch up on 6 years of improvements in Open Firmware nexus devices by importing the sparc64 one. At least 90% of this code is MI and will be moved into /sys/dev/ofw at some point in the future. Modified: head/sys/powerpc/powerpc/nexus.c Modified: head/sys/powerpc/powerpc/nexus.c == --- head/sys/powerpc/powerpc/nexus.cTue Oct 22 14:10:00 2013 (r256900) +++ head/sys/powerpc/powerpc/nexus.cTue Oct 22 14:11:16 2013 (r256901) @@ -1,5 +1,8 @@ /*- * Copyright 1998 Massachusetts Institute of Technology + * Copyright 2001 by Thomas Moestl . + * Copyright 2006 by Marius Strobl . + * All rights reserved. * * Permission to use, copy, modify, and distribute this software and * its documentation for any purpose and without fee is hereby @@ -25,30 +28,6 @@ * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. - */ -/*- - * Copyright 2001 by Thomas Moestl . All rights reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * 1. Redistributions of source code must retain the above copyright - *notice, this list of conditions and the following disclaimer. - * 2. Redistributions in binary form must reproduce the above copyright - *notice, this list of conditions and the following disclaimer in the - *documentation and/or other materials provided with the distribution. - * - * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND - * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE - * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE - * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL - * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS - * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) - * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT - * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY - * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. * * from: FreeBSD: src/sys/i386/i386/nexus.c,v 1.43 2001/02/09 */ @@ -58,81 +37,71 @@ __FBSDID("$FreeBSD$"); #include #include -#include #include -#include #include #include +#include +#include +#include + +#include +#include #include #include #include #include -#include #include #include -#include - -#include "ofw_bus_if.h" -#include "pic_if.h" - /* * The nexus (which is a pseudo-bus actually) iterates over the nodes that - * exist in Open Firmware and adds them as devices to this bus so that drivers - * can be attached to them. + * hang from the Open Firmware root node and adds them as devices to this bus + * (except some special nodes which are excluded) so that drivers can be + * attached to them. + * + * Additionally, interrupt setup/teardown and some resource management are + * done at this level. * * Maybe this code should get into dev/ofw to some extent, as some of it should * work for all Open Firmware based machines... */ -static MALLOC_DEFINE(M_NEXUS, "nexus", "nexus device information"); - struct nexus_devinfo { - struct ofw_bus_devinfo ndi_ofwinfo; + struct ofw_bus_devinfo ndi_obdinfo; + struct resource_listndi_rl; }; struct nexus_softc { - struct rman sc_rman; + uint32_tacells, scells; + struct rman sc_intr_rman; + struct rman sc_mem_rman; }; -/* - * Device interface - */ -static int nexus_probe(device_t); -static int nexus_attach(device_t); - -/* - * Bus interface - */ -static device_t nexus_add_child(device_t, u_int, const char *, int); -static voidnexus_probe_nomatch(device_t, device_t); +static device_probe_t nexus_probe; +static device_attach_t nexus_attach; +static bus_print_child_t nexus_print_child; +static bus_add_child_t nexus_add_child; +static bus_probe_nomatch_t nexus_probe_nomatch; +static bus_setup_intr_t nexus_setup_intr; +static bus_teardown_intr_t nexus_teardown_intr; +static bus_alloc_resource_t nexus_alloc_resource; +static bus_activate_resource_t nexus_activate_resource; +static bus_deactivate_resource_t nexus_deactivate_resource; +static bus_adjust_resource_t nexus_adjust_resource; +static bus_release_resource_t nexus_release_resource; +static bus_get_resource_list_t nexus_get_resource_list; #ifdef SMP -static int nexus_bind_intr(device_t dev, device_t child, - struct resource *irq, int cpu); +static bus_bind_intr
svn commit: r256911 - in head/sys: dev/fdt mips/beri
Author: brooks Date: Tue Oct 22 15:29:59 2013 New Revision: 256911 URL: http://svnweb.freebsd.org/changeset/base/256911 Log: MFP4: 223121 (PIC portion), 225861, 227822, 229692 (PIC only), 229693, 230523, 1123614 Implement a driver for Robert Norton's PIC as an FDT interrupt controller. Devices whose interrupt-parent property points to a beripic device will have their interrupt allocation, activation , and setup operations routed through the IC rather than down the traditional bus hierarchy. This driver largely abstracts the underlying CPU away allowing the PIC to be implemented on CPU's other than BERI. Due to insufficient abstractions a small amount of MIPS specific code is currently required in fdt_mips.c and to implement counters. MFC after:3 days Sponsored by: DARPA/AFRL Added: head/sys/mips/beri/beri_pic.c (contents, props changed) Modified: head/sys/dev/fdt/fdt_mips.c head/sys/mips/beri/files.beri Modified: head/sys/dev/fdt/fdt_mips.c == --- head/sys/dev/fdt/fdt_mips.c Tue Oct 22 15:09:31 2013(r256910) +++ head/sys/dev/fdt/fdt_mips.c Tue Oct 22 15:29:59 2013(r256911) @@ -68,7 +68,26 @@ fdt_pic_decode_mips4k_cp0(phandle_t node return (0); } +/* + * CHERI PIC decoder. + */ +static int +fdt_pic_decode_beri(phandle_t node, pcell_t *intr, int *interrupt, +int *trig, int *pol) +{ + + if (!fdt_is_compatible(node, "sri-cambridge,beri-pic")) + return (ENXIO); + + *interrupt = fdt32_to_cpu(intr[0]); + *trig = INTR_TRIGGER_CONFORM; + *pol = INTR_POLARITY_CONFORM; + + return (0); +} + fdt_pic_decode_t fdt_pic_table[] = { &fdt_pic_decode_mips4k_cp0, + &fdt_pic_decode_beri, NULL }; Added: head/sys/mips/beri/beri_pic.c == --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/sys/mips/beri/beri_pic.c Tue Oct 22 15:29:59 2013 (r256911) @@ -0,0 +1,706 @@ +/*- + * Copyright (c) 2013 SRI International + * All rights reserved. + * + * This software was developed by SRI International and the University of + * Cambridge Computer Laboratory under DARPA/AFRL contract (FA8750-10-C-0237) + * ("CTSRD"), as part of the DARPA CRASH research programme. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + *notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + *notice, this list of conditions and the following disclaimer in the + *documentation and/or other materials provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND + * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE + * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE + * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE + * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL + * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS + * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) + * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY + * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF + * SUCH DAMAGE. + */ + +#include +__FBSDID("$FreeBSD$"); + +#include +#include +#include +#include +#include +#include +#include +#include + +#include +#include + +#include +#include + +#include + +#include "fdt_ic_if.h" + +struct beripic_softc; + +static uint64_tbp_read_cfg(struct beripic_softc *, int); +static voidbp_write_cfg(struct beripic_softc *, int, uint64_t); +static voidbp_detach_resources(device_t); +static char*bp_strconfig(uint64_t, char *, size_t); +static voidbp_config_source(device_t, int, int, u_long, u_long); +#ifdef __mips__ +static voidbp_set_counter_name(device_t, device_t, int); +#endif + +static int beripic_fdt_probe(device_t); +static int beripic_fdt_attach(device_t); + +static int beripic_activate_intr(device_t, struct resource *); +static struct resource * + beripic_alloc_intr(device_t, device_t, int *, u_long, u_int); +static int beripic_config_intr(device_t, int, enum intr_trigger, + enum intr_polarity); +static int beripic_release_intr(device_t, struct resource *); +static int beripic_setup_intr(device_t, device_t, struct resource *, + int, driver_filter_t *, driver_intr_t *, void *, void **); +static int beripic_teardown_intr(device_t,
svn commit: r256912 - in head/sys: boot/fdt/dts mips/conf
Author: brooks Date: Tue Oct 22 15:45:31 2013 New Revision: 256912 URL: http://svnweb.freebsd.org/changeset/base/256912 Log: Sync BERI kernel configs with P4: Switch the majority of device configuration to FDT from hints. Add BERI_*_BASE configs to reduce duplication in the MDROOT and SDROOT kernels. Add NFS and GSSAPI support by default. MFC after:3 days Sponsored by: DARPA/AFRL Added: head/sys/boot/fdt/dts/beri-sim.dts (contents, props changed) head/sys/boot/fdt/dts/beripad-de4.dts (contents, props changed) head/sys/mips/conf/BERI_DE4_BASE (contents, props changed) head/sys/mips/conf/BERI_SIM_BASE (contents, props changed) head/sys/mips/conf/BERI_SIM_SDROOT (contents, props changed) Modified: head/sys/mips/conf/BERI_DE4.hints head/sys/mips/conf/BERI_DE4_MDROOT head/sys/mips/conf/BERI_DE4_SDROOT head/sys/mips/conf/BERI_SIM_MDROOT head/sys/mips/conf/BERI_TEMPLATE Added: head/sys/boot/fdt/dts/beri-sim.dts == --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/sys/boot/fdt/dts/beri-sim.dts Tue Oct 22 15:45:31 2013 (r256912) @@ -0,0 +1,144 @@ +/*- + * Copyright (c) 2012-2013 Robert N. M. Watson + * Copyright (c) 2013 SRI International + * All rights reserved. + * + * This software was developed by SRI International and the University of + * Cambridge Computer Laboratory under DARPA/AFRL contract (FA8750-10-C-0237) + * ("CTSRD"), as part of the DARPA CRASH research programme. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + *notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + *notice, this list of conditions and the following disclaimer in the + *documentation and/or other materials provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND + * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE + * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE + * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE + * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL + * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS + * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) + * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY + * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF + * SUCH DAMAGE. + * + * $FreeBSD$ + */ + +/dts-v1/; + +/* + * Device names here have been largely made up on the spot, especially for the + * "compatible" strings, and might want to be revised. + * + * For now, use 32-bit addressing as our Avalon bus is 32-bit. However, in + * the future, we should likely change to 64-bit. + */ + +/ { + model = "SRI/Cambridge BERI simulation"; + compatible = "sri-cambridge,beri-sim"; + #address-cells = <1>; + #size-cells = <1>; + + cpus { + #address-cells = <1>; + #size-cells = <1>; + + /* +* Secondary CPUs all start disabled and use the +* spin-table enable method. cpu-release-addr must be +* specified for each cpu other than cpu@0. Values of +* cpu-release-addr grow down from 0x10 (kernel). +*/ + status = "disabled"; + enable-method = "spin-table"; + + cpu@0 { + device-type = "cpu"; + compatible = "sri-cambridge,beri"; + + reg = <0>; + status = "okay"; + }; + +/* + cpu@1 { + device-type = "cpu"; + compatible = "sri-cambridge,beri"; + + reg = <1>; + // XXX: should we need cached prefix? + cpu-release-addr = <0x 0x800fffe0>; + }; +*/ + }; + + soc { + #address-cells = <1>; + #size-cells = <1>; + #interrupt-cells = <1>; + + /* +* Declare mips,mips4k since BERI doesn't (yet) have a PIC, so +* we use mips4k coprocessor 0 interrupt management directly. +*/ + compatible = "simple-bus", "mips,mips4k"; + ranges = <>; + + memory { + device_type = "memory"; + reg = <0x0 0x400>; // 64M at 0x0 + }; + +
svn commit: r256914 - head/sys/powerpc/powerpc
Author: nwhitehorn Date: Tue Oct 22 15:47:13 2013 New Revision: 256914 URL: http://svnweb.freebsd.org/changeset/base/256914 Log: Ignore registers on devices where the reg property is malformed. Issue a warning if this happens under bootverbose. This prevents some strange-looking entries in dmesg for SMU devices on Apple G5 systems. Modified: head/sys/powerpc/powerpc/nexus.c Modified: head/sys/powerpc/powerpc/nexus.c == --- head/sys/powerpc/powerpc/nexus.cTue Oct 22 15:46:21 2013 (r256913) +++ head/sys/powerpc/powerpc/nexus.cTue Oct 22 15:47:13 2013 (r256914) @@ -567,6 +567,12 @@ nexus_setup_dinfo(device_t dev, phandle_ nreg = OF_getprop_alloc(node, "reg", sizeof(*reg), (void **)®); if (nreg == -1) nreg = 0; + if (nreg % (sc->acells + sc->scells) != 0) { + if (bootverbose) + device_printf(dev, "Malformed reg property on <%s>\n", + ndi->ndi_obdinfo.obd_name); + nreg = 0; + } for (i = 0; i < nreg; i += sc->acells + sc->scells) { phys = size = 0; ___ svn-src-head@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
svn commit: r256915 - in head: . share/mk
Author: brooks Date: Tue Oct 22 15:53:29 2013 New Revision: 256915 URL: http://svnweb.freebsd.org/changeset/base/256915 Log: Stop conflating WITHOUT_CLANG with WITHOUT_CLANG_IS_CC. This allows bootstrapping a copy of clang without building clang for the base system which is useful for nanobsd and similar setups. It's still probably wrong to conflate what is installed as /usr/bin/cc with the selection of a bootstrap compiler under WITH*_CLANG_IS_CC, but that's for another day. MFC after:1 week Sponsored by: DARPA/AFRL Modified: head/Makefile.inc1 head/share/mk/bsd.own.mk Modified: head/Makefile.inc1 == --- head/Makefile.inc1 Tue Oct 22 15:47:13 2013(r256914) +++ head/Makefile.inc1 Tue Oct 22 15:53:29 2013(r256915) @@ -1377,12 +1377,10 @@ _binutils= gnu/usr.bin/binutils # If an full path to an external cross compiler is given, don't build # a cross compiler. .if ${XCC:M/*} == "" && ${MK_CROSS_COMPILER} != "no" -.if ${MK_CLANG} != "no" && (${MK_CLANG_IS_CC} != "no" || ${CC:T:Mclang} == "clang") +.if (${MK_CLANG_IS_CC} != "no" || ${CC:T:Mclang} == "clang") && ${TARGET} != "pc98" _clang=usr.bin/clang _clang_libs= lib/clang -.endif - -.if ${MK_GCC} != "no" && (${MK_CLANG_IS_CC} == "no" || ${TARGET} == "pc98") +.else _cc= gnu/usr.bin/cc .endif .endif Modified: head/share/mk/bsd.own.mk == --- head/share/mk/bsd.own.mkTue Oct 22 15:47:13 2013(r256914) +++ head/share/mk/bsd.own.mkTue Oct 22 15:53:29 2013(r256915) @@ -554,7 +554,6 @@ MK_GDB:=no .if ${MK_CLANG} == "no" MK_CLANG_EXTRAS:= no MK_CLANG_FULL:= no -MK_CLANG_IS_CC:= no .endif .if ${MK_CLANG_IS_CC} == "no" ___ svn-src-head@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
svn commit: r256919 - head/sys/dev/ffec
Author: ian Date: Tue Oct 22 18:14:06 2013 New Revision: 256919 URL: http://svnweb.freebsd.org/changeset/base/256919 Log: Mask out non-address bits in the mac address register, for proper detection of an all-zeroes address. Also remove a misplaced return. Reviewed by: br@ Modified: head/sys/dev/ffec/if_ffec.c Modified: head/sys/dev/ffec/if_ffec.c == --- head/sys/dev/ffec/if_ffec.c Tue Oct 22 18:07:49 2013(r256918) +++ head/sys/dev/ffec/if_ffec.c Tue Oct 22 18:14:06 2013(r256919) @@ -883,7 +883,7 @@ ffec_get_hwaddr(struct ffec_softc *sc, u * assigned bit set, and the broadcast/multicast bit clear. */ palr = RD4(sc, FEC_PALR_REG); - paur = RD4(sc, FEC_PAUR_REG); + paur = RD4(sc, FEC_PAUR_REG) & FEC_PAUR_PADDR2_MASK; if ((palr | paur) != 0) { hwaddr[0] = palr >> 24; hwaddr[1] = palr >> 16; @@ -891,7 +891,6 @@ ffec_get_hwaddr(struct ffec_softc *sc, u hwaddr[3] = palr >> 0; hwaddr[4] = paur >> 24; hwaddr[5] = paur >> 16; - return; } else { rnd = arc4random() & 0x00ff; hwaddr[0] = 'b'; ___ svn-src-head@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
svn commit: r256920 - head/sys/netinet
Author: andre Date: Tue Oct 22 18:24:34 2013 New Revision: 256920 URL: http://svnweb.freebsd.org/changeset/base/256920 Log: The TCP delayed ACK logic isn't aware of LRO passing up large aggregated segments thinking it received only one segment. This causes it to enable the delay the ACK for 100ms to wait for another segment which may never come because all the data was received already. Doing delayed ACK for LRO segments is bogus for two reasons: a) it pushes us further away from acking every other packet; b) it introduces additional delay in responding to the sender. The latter is especially bad because it is in the nature of LRO to aggregated all segments of a burst with no more coming until an ACK is sent back. Change the delayed ACK logic to detect LRO segments by being larger than the MSS for this connection and issuing an immediate ACK for them to keep the ACK clock ticking without interruption. Reported by: julian, cperciva Tested by:cperciva Reviewed by: lstewart MFC after:3 days Modified: head/sys/netinet/tcp_input.c Modified: head/sys/netinet/tcp_input.c == --- head/sys/netinet/tcp_input.cTue Oct 22 18:14:06 2013 (r256919) +++ head/sys/netinet/tcp_input.cTue Oct 22 18:24:34 2013 (r256920) @@ -508,10 +508,13 @@ do { \ * the ack that opens up a 0-sized window and * - delayed acks are enabled or * - this is a half-synchronized T/TCP connection. + * - the segment size is not larger than the MSS and LRO wasn't used + * for this segment. */ -#define DELAY_ACK(tp) \ +#define DELAY_ACK(tp, tlen)\ ((!tcp_timer_active(tp, TT_DELACK) && \ (tp->t_flags & TF_RXWIN0SENT) == 0) && \ + (tlen <= tp->t_maxopd) && \ (V_tcp_delack_enabled || (tp->t_flags & TF_NEEDSYN))) /* @@ -1863,7 +1866,7 @@ tcp_do_segment(struct mbuf *m, struct tc } /* NB: sorwakeup_locked() does an implicit unlock. */ sorwakeup_locked(so); - if (DELAY_ACK(tp)) { + if (DELAY_ACK(tp, tlen)) { tp->t_flags |= TF_DELACK; } else { tp->t_flags |= TF_ACKNOW; @@ -1954,7 +1957,7 @@ tcp_do_segment(struct mbuf *m, struct tc * If there's data, delay ACK; if there's also a FIN * ACKNOW will be turned on later. */ - if (DELAY_ACK(tp) && tlen != 0) + if (DELAY_ACK(tp, tlen) && tlen != 0) tcp_timer_activate(tp, TT_DELACK, tcp_delacktime); else @@ -2926,7 +2929,7 @@ dodata: /* XXX */ if (th->th_seq == tp->rcv_nxt && LIST_EMPTY(&tp->t_segq) && TCPS_HAVEESTABLISHED(tp->t_state)) { - if (DELAY_ACK(tp)) + if (DELAY_ACK(tp, tlen)) tp->t_flags |= TF_DELACK; else tp->t_flags |= TF_ACKNOW; ___ svn-src-head@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
svn commit: r256921 - head
Author: cperciva Date: Tue Oct 22 18:36:39 2013 New Revision: 256921 URL: http://svnweb.freebsd.org/changeset/base/256921 Log: Thou shalt not leak build host state into the system being compiled. The VERSION variable is encoded into the SUNW_ctf sections of the kernel and every kernel module when dtrace is enabled; starting with 9.2-RELEASE (when dtrace was turned on in GENERIC) this means that different host kernels will result in very different kernel binaries being generated. This tripped up freebsd-update builds after the build boxes were updated from 9.x to 10.x. MFC after:3 days (stable/9) X-MFC after: 0 days (stable/10) Security: Rendered two members of so@ temporarily insane Modified: head/Makefile.inc1 Modified: head/Makefile.inc1 == --- head/Makefile.inc1 Tue Oct 22 18:24:34 2013(r256920) +++ head/Makefile.inc1 Tue Oct 22 18:36:39 2013(r256921) @@ -128,8 +128,11 @@ OSRELDATE= 0 .endif .if !defined(VERSION) -VERSION!= uname -srp -VERSION+= ${OSRELDATE} +REVISION!= make -C ${.CURDIR}/release -V REVISION +BRANCH!= make -C ${.CURDIR}/release -V BRANCH +SRCRELDATE!= awk '/^\#define[[:space:]]*__FreeBSD_version/ { print $$3 }' \ + ${.CURDIR}/sys/sys/param.h +VERSION= FreeBSD ${REVISION}-${BRANCH} ${TARGET_ARCH} ${SRCRELDATE} .endif KNOWN_ARCHES?= amd64 arm armeb/arm armv6/arm i386 i386/pc98 ia64 mips mipsel/mips mips64el/mips mips64/mips mipsn32el/mips mipsn32/mips powerpc powerpc64/powerpc sparc64 ___ svn-src-head@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
Re: svn commit: r256884 - in head: share/man/man9 sys/geom
On Tuesday, October 22, 2013 6:21:21 am Alexander Motin wrote: > Author: mav > Date: Tue Oct 22 10:21:20 2013 > New Revision: 256884 > URL: http://svnweb.freebsd.org/changeset/base/256884 > > Log: > Remove Giant-locked drivers support (DISKFLAG_NEEDSGIANT flag) from disk(9). > > Since at least FreeBSD 7 we had only four of them in the base tree, and > in head branch, thanks to jhb@, we have no any for more then a year. I had this additional change in my local branch, what do you think of it? We should probably keep it unless we bump DISK_VERSION and drop support for older disk structures. I think we could probably merge it to 10 along with your change as well: --- //depot/vendor/freebsd/src/sys/geom/geom_disk.c +++ //depot/user/jhb/cleanup/sys/geom/geom_disk.c @@ -654,6 +654,13 @@ dp->d_name, dp->d_unit); return; } + if (dp->d_flags & DISKFLAG_RESERVED) { + printf("WARNING: Attempt to add non-MPSAFE disk %s%d\n", + dp->d_name, dp->d_unit); + printf("WARNING: Ignoring disk %s%d\n", + dp->d_name, dp->d_unit); + return; + } KASSERT(dp->d_strategy != NULL, ("disk_create need d_strategy")); KASSERT(dp->d_name != NULL, ("disk_create need d_name")); KASSERT(*dp->d_name != 0, ("disk_create need d_name")); --- //depot/vendor/freebsd/src/sys/geom/geom_disk.h +++ //depot/user/jhb/cleanup/sys/geom/geom_disk.h @@ -102,6 +102,7 @@ void*d_drv1; }; +#define DISKFLAG_RESERVED 0x1 /* Was NEEDSGIANT */ #define DISKFLAG_OPEN 0x2 #define DISKFLAG_CANDELETE 0x4 #define DISKFLAG_CANFLUSHCACHE 0x8 -- John Baldwin ___ svn-src-head@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
Re: svn commit: r256884 - in head: share/man/man9 sys/geom
Hi, I definitely agree with marking 0x1 as being reserved, at least for the lifecycle of 10.x up until 11.x. -adrian On 22 October 2013 11:47, John Baldwin wrote: > On Tuesday, October 22, 2013 6:21:21 am Alexander Motin wrote: > > Author: mav > > Date: Tue Oct 22 10:21:20 2013 > > New Revision: 256884 > > URL: http://svnweb.freebsd.org/changeset/base/256884 > > > > Log: > > Remove Giant-locked drivers support (DISKFLAG_NEEDSGIANT flag) from > disk(9). > > > > Since at least FreeBSD 7 we had only four of them in the base tree, and > > in head branch, thanks to jhb@, we have no any for more then a year. > > I had this additional change in my local branch, what do you think of it? > We > should probably keep it unless we bump DISK_VERSION and drop support for > older > disk structures. I think we could probably merge it to 10 along with your > change as well: > > --- //depot/vendor/freebsd/src/sys/geom/geom_disk.c > +++ //depot/user/jhb/cleanup/sys/geom/geom_disk.c > @@ -654,6 +654,13 @@ > dp->d_name, dp->d_unit); > return; > } > + if (dp->d_flags & DISKFLAG_RESERVED) { > + printf("WARNING: Attempt to add non-MPSAFE disk %s%d\n", > + dp->d_name, dp->d_unit); > + printf("WARNING: Ignoring disk %s%d\n", > + dp->d_name, dp->d_unit); > + return; > + } > KASSERT(dp->d_strategy != NULL, ("disk_create need d_strategy")); > KASSERT(dp->d_name != NULL, ("disk_create need d_name")); > KASSERT(*dp->d_name != 0, ("disk_create need d_name")); > --- //depot/vendor/freebsd/src/sys/geom/geom_disk.h > +++ //depot/user/jhb/cleanup/sys/geom/geom_disk.h > @@ -102,6 +102,7 @@ > void*d_drv1; > }; > > +#define DISKFLAG_RESERVED 0x1 /* Was NEEDSGIANT */ > #define DISKFLAG_OPEN 0x2 > #define DISKFLAG_CANDELETE 0x4 > #define DISKFLAG_CANFLUSHCACHE 0x8 > > -- > John Baldwin > ___ svn-src-head@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
svn commit: r256923 - head/usr.sbin/portsnap/portsnap
Author: gavin Date: Tue Oct 22 18:55:52 2013 New Revision: 256923 URL: http://svnweb.freebsd.org/changeset/base/256923 Log: Rename the "alfred" command to "auto", and document it. Retain support for "portsnap alfred" for now. Discussed:many times, most recently on svn-src-all MFC after:1 week Modified: head/usr.sbin/portsnap/portsnap/portsnap.8 head/usr.sbin/portsnap/portsnap/portsnap.sh Modified: head/usr.sbin/portsnap/portsnap/portsnap.8 == --- head/usr.sbin/portsnap/portsnap/portsnap.8 Tue Oct 22 18:39:43 2013 (r256922) +++ head/usr.sbin/portsnap/portsnap/portsnap.8 Tue Oct 22 18:55:52 2013 (r256923) @@ -25,7 +25,7 @@ .\" .\" $FreeBSD$ .\" -.Dd October 14, 2012 +.Dd October 22, 2013 .Dt PORTSNAP 8 .Os FreeBSD .Sh NAME @@ -161,6 +161,18 @@ or commands. Again, note that in the parts of the ports tree which are being updated, any local changes or additions will be removed. +.It auto +Run +.Cm fetch +or +.Cm cron +depending on whether stdin is a terminal; then run +.Cm update +or +.Cm extract +depending on whether +.Ar portsdir +exists. .El .Sh TIPS .Bl -bullet Modified: head/usr.sbin/portsnap/portsnap/portsnap.sh == --- head/usr.sbin/portsnap/portsnap/portsnap.sh Tue Oct 22 18:39:43 2013 (r256922) +++ head/usr.sbin/portsnap/portsnap/portsnap.sh Tue Oct 22 18:55:52 2013 (r256923) @@ -61,6 +61,8 @@ Commands: files and directories. update -- Update ports tree to match current snapshot, replacing files and directories which have changed. + auto -- Fetch updates, and either extract a new ports tree or + update an existing tree. EOF exit 0 } @@ -147,12 +149,15 @@ parse_cmdline() { if [ ! -z "${SERVERNAME}" ]; then usage; fi shift; SERVERNAME="$1" ;; - cron | extract | fetch | update | alfred) + cron | extract | fetch | update | auto) COMMANDS="${COMMANDS} $1" ;; up) COMMANDS="${COMMANDS} update" ;; + alfred) + COMMANDS="${COMMANDS} auto" + ;; *) if [ $# -gt 1 ]; then usage; fi if echo ${COMMANDS} | grep -vq extract; then @@ -1104,10 +1109,10 @@ cmd_update() { update_run || exit 1 } -# Alfred command. Run 'fetch' or 'cron' depending on +# Auto command. Run 'fetch' or 'cron' depending on # whether stdin is a terminal; then run 'update' or # 'extract' depending on whether ${PORTSDIR} exists. -cmd_alfred() { +cmd_auto() { if [ "${INTERACTIVE}" = "YES" ]; then cmd_fetch else ___ svn-src-head@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
Re: svn commit: r256884 - in head: share/man/man9 sys/geom
On 22.10.2013 21:47, John Baldwin wrote: On Tuesday, October 22, 2013 6:21:21 am Alexander Motin wrote: Author: mav Date: Tue Oct 22 10:21:20 2013 New Revision: 256884 URL: http://svnweb.freebsd.org/changeset/base/256884 Log: Remove Giant-locked drivers support (DISKFLAG_NEEDSGIANT flag) from disk(9). Since at least FreeBSD 7 we had only four of them in the base tree, and in head branch, thanks to jhb@, we have no any for more then a year. I had this additional change in my local branch, what do you think of it? We should probably keep it unless we bump DISK_VERSION and drop support for older disk structures. I think we could probably merge it to 10 along with your change as well: It looks good to me, while I don't know how much useful can it be. I am not sure how many old binary drivers are there and how many of them survive switch from earlier FreeBSD versions to 10.x. But since it cost almost nothing I have no objections. --- //depot/vendor/freebsd/src/sys/geom/geom_disk.c +++ //depot/user/jhb/cleanup/sys/geom/geom_disk.c @@ -654,6 +654,13 @@ dp->d_name, dp->d_unit); return; } + if (dp->d_flags & DISKFLAG_RESERVED) { + printf("WARNING: Attempt to add non-MPSAFE disk %s%d\n", + dp->d_name, dp->d_unit); + printf("WARNING: Ignoring disk %s%d\n", + dp->d_name, dp->d_unit); + return; + } KASSERT(dp->d_strategy != NULL, ("disk_create need d_strategy")); KASSERT(dp->d_name != NULL, ("disk_create need d_name")); KASSERT(*dp->d_name != 0, ("disk_create need d_name")); --- //depot/vendor/freebsd/src/sys/geom/geom_disk.h +++ //depot/user/jhb/cleanup/sys/geom/geom_disk.h @@ -102,6 +102,7 @@ void*d_drv1; }; +#define DISKFLAG_RESERVED 0x1 /* Was NEEDSGIANT */ #define DISKFLAG_OPEN 0x2 #define DISKFLAG_CANDELETE0x4 #define DISKFLAG_CANFLUSHCACHE0x8 -- Alexander Motin ___ svn-src-head@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
svn commit: r256925 - head/include
Author: tijl Date: Tue Oct 22 19:53:52 2013 New Revision: 256925 URL: http://svnweb.freebsd.org/changeset/base/256925 Log: Add a dummy statement to the beginning of the pthread_cleanup_pop() macro to allow a call of the macro to be labelled as in: label: pthread_cleanup_pop(); Reviewed by: imp MFC after:3 days Modified: head/include/pthread.h Modified: head/include/pthread.h == --- head/include/pthread.h Tue Oct 22 19:49:19 2013(r256924) +++ head/include/pthread.h Tue Oct 22 19:53:52 2013(r256925) @@ -175,6 +175,7 @@ int pthread_barrierattr_setpshared(pthr { #definepthread_cleanup_pop(execute) \ + (void)0; \ } \ __pthread_cleanup_pop_imp(execute); \ } ___ svn-src-head@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
svn commit: r256926 - head/usr.sbin/bhyve
Author: grehan Date: Tue Oct 22 19:55:04 2013 New Revision: 256926 URL: http://svnweb.freebsd.org/changeset/base/256926 Log: Fix AHCI ATAPI emulation when backed with /dev/cd0 - remove assumption that the backing file/device had 512-byte sectors - fix incorrect iovec size variable that would result in a buffer overrun when an o/s issued an i/o request with more s/g elements than the blockif api Reviewed by: Zhixiang Yu (zxyu.c...@gmail.com) MFC after:3 days Modified: head/usr.sbin/bhyve/pci_ahci.c Modified: head/usr.sbin/bhyve/pci_ahci.c == --- head/usr.sbin/bhyve/pci_ahci.c Tue Oct 22 19:53:52 2013 (r256925) +++ head/usr.sbin/bhyve/pci_ahci.c Tue Oct 22 19:55:04 2013 (r256926) @@ -663,8 +663,7 @@ atapi_read_capacity(struct ahci_port *p, uint8_t buf[8]; uint64_t sectors; - sectors = blockif_size(p->bctx) / blockif_sectsz(p->bctx); - sectors >>= 2; + sectors = blockif_size(p->bctx) / 2048; be32enc(buf, sectors - 1); be32enc(buf + 4, 2048); cfis[4] = (cfis[4] & ~7) | ATA_I_CMD | ATA_I_IN; @@ -908,9 +907,9 @@ atapi_read(struct ahci_port *p, int slot /* * Build up the iovec based on the prdt */ - for (i = 0; i < hdr->prdtl; i++) { + for (i = 0; i < iovcnt; i++) { breq->br_iov[i].iov_base = paddr_guest2host(ahci_ctx(sc), - prdt->dba, prdt->dbc + 1); + prdt->dba, prdt->dbc + 1); breq->br_iov[i].iov_len = prdt->dbc + 1; aior->done += (prdt->dbc + 1); prdt++; ___ svn-src-head@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
svn commit: r256927 - head/share/man/man9
Author: jhb Date: Tue Oct 22 20:10:38 2013 New Revision: 256927 URL: http://svnweb.freebsd.org/changeset/base/256927 Log: Add a manpage for the getenv() family of functions in the kernel. Added: head/share/man/man9/getenv.9 (contents, props changed) Modified: head/share/man/man9/Makefile Modified: head/share/man/man9/Makefile == --- head/share/man/man9/MakefileTue Oct 22 19:55:04 2013 (r256926) +++ head/share/man/man9/MakefileTue Oct 22 20:10:38 2013 (r256927) @@ -118,6 +118,7 @@ MAN=accept_filter.9 \ g_consumer.9 \ g_data.9 \ get_cyclecount.9 \ + getenv.9 \ getnewvnode.9 \ g_event.9 \ g_geom.9 \ @@ -677,6 +678,14 @@ MLINKS+=g_consumer.9 g_destroy_consumer. g_consumer.9 g_new_consumer.9 MLINKS+=g_data.9 g_read_data.9 \ g_data.9 g_write_data.9 +MLINKS+=getenv.9 freeenv.9 \ + getenv.9 getenv_int.9 \ + getenv.9 getenv_long.9 \ + getenv.9 getenv_string.9 \ + getenv.9 getenv_quad.9 \ + getenv.9 getenv_uint.9 \ + getenv.9 getenv_ulong.9 \ + getenv.9 testenv.9 MLINKS+=g_event.9 g_cancel_event.9 \ g_event.9 g_post_event.9 \ g_event.9 g_waitfor_event.9 Added: head/share/man/man9/getenv.9 == --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/share/man/man9/getenv.9Tue Oct 22 20:10:38 2013 (r256927) @@ -0,0 +1,210 @@ +.\" -*- nroff -*- +.\" +.\" Copyright (c) 2013 Advanced Computing Technologies LLC +.\" Written by: John H. Baldwin +.\" All rights reserved. +.\" +.\" Redistribution and use in source and binary forms, with or without +.\" modification, are permitted provided that the following conditions +.\" are met: +.\" 1. Redistributions of source code must retain the above copyright +.\"notice, this list of conditions and the following disclaimer. +.\" 2. Redistributions in binary form must reproduce the above copyright +.\"notice, this list of conditions and the following disclaimer in the +.\"documentation and/or other materials provided with the distribution. +.\" +.\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND +.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +.\" ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE +.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS +.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) +.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +.\" SUCH DAMAGE. +.\" +.\" $FreeBSD$ +.\" +.Dd October 22, 2013 +.Dt getenv 9 +.Os +.Sh NAME +.Nm freeenv , +.Nm getenv , +.Nm getenv_int , +.Nm getenv_long , +.Nm getenv_string , +.Nm getenv_quad , +.Nm getenv_uint , +.Nm getenv_ulong , +.Nm setenv , +.Nm testenv , +.Nm unsetenv +.Nd kernel environment variable functions +.Sh SYNOPSIS +.In sys/param.h +.In sys/systm.h +.Ft void +.Fn freeenv "char *env" +.Ft char * +.Fn getenv "const char *name" +.Ft int +.Fn getenv_int "const char *name" "int *data" +.Ft int +.Fn getenv_long "const char *name" "long *data" +.Ft int +.Fn getenv_string "const char *name" "char *data" "int size" +.Ft int +.Fn getenv_quad "const char *name" "quad_t *data" +.Ft int +.Fn getenv_uint "const char *name" "unsigned int *data" +.Ft int +.Fn getenv_ulong "const char *name" "unsigned long *data" +.Ft int +.Fn setenv "const char *name" "const char *value" +.Ft int +.Fn testenv "const char *name" +.Ft int +.Fn unsetenv "const char *name" +.Sh DESCRIPTION +These functions set, unset, fetch, and parse variables from the kernel's +environment. +.Pp +The +.Fn getenv +function obtains the current value of the kernel environment variable +.Fa name +and returns a pointer to the string value. +The caller should not modify the string pointed to by the return value. +.Pp +The +.Fn getenv +function may allocate temporary storage, +so the +.Fn freeenv +function must be called to release any allocated resources when the value +returned by +.Fn getenv +is no longer needed. +The +.Fa env +argument passed to +.Fn freeenv +is the pointer returned by the earlier call to +.Fn getenv . +.Pp +The +.Fn setenv +function inserts or resets the kernel environment variable +.Fa name +to +.Fa value . +If the variable +.Fa name +already exists, +its value is replaced. +This function can fail if an internal limit on the number of environment +variables is exceeded. +.Pp +The +.Fn unsetenv +function deletes the kernel
svn commit: r256931 - head/sys/mips/conf
Author: brooks Date: Tue Oct 22 20:50:41 2013 New Revision: 256931 URL: http://svnweb.freebsd.org/changeset/base/256931 Log: Enable ATSE_CFI_HACK in BERI configs, stable MAC addresses are useful. MFC after:3 days Sponsored by: DARPA/AFRL Modified: head/sys/mips/conf/BERI_DE4_BASE Modified: head/sys/mips/conf/BERI_DE4_BASE == --- head/sys/mips/conf/BERI_DE4_BASETue Oct 22 20:31:59 2013 (r256930) +++ head/sys/mips/conf/BERI_DE4_BASETue Oct 22 20:50:41 2013 (r256931) @@ -32,6 +32,7 @@ devicebpf device cfi device cfid optionsCFI_SUPPORT_STRATAFLASH +optionsATSE_CFI_HACK device sc device uart ___ svn-src-head@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
svn commit: r256932 - head/sys/dev/ofw
Author: nwhitehorn Date: Tue Oct 22 20:57:24 2013 New Revision: 256932 URL: http://svnweb.freebsd.org/changeset/base/256932 Log: Add a new function (OF_getencprop()) that undoes the transformation applied by encode-int. Specifically, it takes a set of 32-bit cell values and changes them to host byte order. Most non-string instances of OF_getprop() should be using this function, which is a no-op on big-endian platforms. Modified: head/sys/dev/ofw/openfirm.c head/sys/dev/ofw/openfirm.h Modified: head/sys/dev/ofw/openfirm.c == --- head/sys/dev/ofw/openfirm.c Tue Oct 22 20:50:41 2013(r256931) +++ head/sys/dev/ofw/openfirm.c Tue Oct 22 20:57:24 2013(r256932) @@ -64,6 +64,7 @@ __FBSDID("$FreeBSD$"); #include #include #include +#include #include @@ -280,6 +281,21 @@ OF_getprop(phandle_t package, const char return (OFW_GETPROP(ofw_obj, package, propname, buf, buflen)); } +ssize_t +OF_getencprop(phandle_t node, const char *propname, pcell_t *buf, size_t len) +{ + ssize_t retval; + int i; + + KASSERT(len % 4 == 0, "Need a multiple of 4 bytes"); + + retval = OF_getprop(node, propname, buf, len); + for (i = 0; i < len/4; i++) + buf[i] = be32toh(buf[i]); + + return (retval); +} + /* * Recursively search the node and its parent for the given property, working * downward from the node to the device tree root. Returns the value of the Modified: head/sys/dev/ofw/openfirm.h == --- head/sys/dev/ofw/openfirm.h Tue Oct 22 20:50:41 2013(r256931) +++ head/sys/dev/ofw/openfirm.h Tue Oct 22 20:57:24 2013(r256932) @@ -105,6 +105,8 @@ phandle_t OF_parent(phandle_t node); ssize_tOF_getproplen(phandle_t node, const char *propname); ssize_tOF_getprop(phandle_t node, const char *propname, void *buf, size_t len); +ssize_tOF_getencprop(phandle_t node, const char *prop, pcell_t *buf, + size_t len); /* Same as getprop, but maintains endianness */ intOF_hasprop(phandle_t node, const char *propname); ssize_tOF_searchprop(phandle_t node, const char *propname, void *buf, size_t len); ___ svn-src-head@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
svn commit: r256934 - head/sys/mips/include
Author: brooks Date: Tue Oct 22 21:06:27 2013 New Revision: 256934 URL: http://svnweb.freebsd.org/changeset/base/256934 Log: MFP4: Change 221534 by rwatson@rwatson_zenith_cl_cam_ac_uk on 2013/01/27 16:05:30 FreeBSD/mips stores page-table entries in a near-identical format to MIPS TLB entries -- only it overrides certain "reserved" bits in the MIPS-defined EntryLo register to hold software-defined bits (swbits) to avoid significantly increasing the page table memory footprint. On n32 and n64, these bits were (a) colliding with MIPS64r2 physical memory extensions and (b) being improperly cleared. Attempt to fix both of these problems by pushing swbits further along 64-bit EntryLo registers into the reserved space, and improving consistency between C-based and assembly-based clearing of swbits -- in particular, to use the same definition. This should stop swbits from leaking into TLB entries -- while ignored by most current MIPS hardware, this would cause a problem with (much) larger physical memory sizes, and also leads to confusing hardware-level tracing as physical addresses contain unexpected (and inconsistent) higher bits. Discussed with: imp, jmallett MFC after:3 days Sponsored by: DARPA/AFRL Modified: head/sys/mips/include/pte.h Modified: head/sys/mips/include/pte.h == --- head/sys/mips/include/pte.h Tue Oct 22 20:58:23 2013(r256933) +++ head/sys/mips/include/pte.h Tue Oct 22 21:06:27 2013(r256934) @@ -56,16 +56,26 @@ typedef pt_entry_t *pd_entry_t; #defineTLBMASK_MASK((PAGE_MASK >> TLBMASK_SHIFT) << TLBMASK_SHIFT) /* - * PFN for EntryLo register. Upper bits are 0, which is to say that - * bit 28 is the last hardware bit; Bits 29 and upwards (EntryLo is - * 64 bit though it can be referred to in 32-bits providing 3 software - * bits safely. We use it as 64 bits to get many software bits, and - * god knows what else.) are unacknowledged by hardware. They may be - * written as anything, but otherwise they have as much meaning as - * other 0 fields. + * FreeBSD/mips page-table entries take a near-identical format to MIPS TLB + * entries, each consisting of two 32-bit or 64-bit values ("EntryHi" and + * "EntryLo"). MIPS4k and MIPS64 both define certain bits in TLB entries as + * reserved, and these must be zero-filled by software. We overload these + * bits in PTE entries to hold PTE_ flags such as RO, W, and MANAGED. + * However, we must mask these out when writing to TLB entries to ensure that + * they do not become visible to hardware -- especially on MIPS64r2 which has + * an extended physical memory space. + * + * When using n64 and n32, shift software-defined bits into the MIPS64r2 + * reserved range, which runs from bit 55 ... 63. In other configurations + * (32-bit MIPS4k and compatible), shift them out to bits 29 ... 31. + * + * NOTE: This means that for 32-bit use of CP0, we aren't able to set the top + * bit of PFN to a non-zero value, as software is using it! This physical + * memory size limit may not be sufficiently enforced elsewhere. */ #if defined(__mips_n64) || defined(__mips_n32) /* PHYSADDR_64_BIT */ -#defineTLBLO_SWBITS_SHIFT (34) +#defineTLBLO_SWBITS_SHIFT (55) +#defineTLBLO_SWBITS_CLEAR_SHIFT(9) #defineTLBLO_PFN_MASK 0x3FFC0ULL #else #defineTLBLO_SWBITS_SHIFT (29) @@ -133,6 +143,9 @@ typedef pt_entry_t *pd_entry_t; * listen to requests to write to it. * W: Wired. ??? * MANAGED:Managed. This PTE maps a managed page. + * + * These bits should not be written into the TLB, so must first be masked out + * explicitly in C, or using CLEAR_PTE_SWBITS() in assembly. */ #definePTE_RO ((pt_entry_t)0x01 << TLBLO_SWBITS_SHIFT) #definePTE_W ((pt_entry_t)0x02 << TLBLO_SWBITS_SHIFT) @@ -162,7 +175,7 @@ typedef pt_entry_t *pd_entry_t; #definePTESIZE 4 #definePTE_L lw #definePTE_MTC0mtc0 -#defineCLEAR_PTE_SWBITS(r) sll r, 3; srl r, 3 /* remove 3 high bits */ +#defineCLEAR_PTE_SWBITS(r) LONG_SLL r, TLBLO_SWBITS_CLEAR_SHIFT; LONG_SRL r, TLBLO_SWBITS_CLEAR_SHIFT /* remove swbits */ #endif /* defined(__mips_n64) || defined(__mips_n32) */ #if defined(__mips_n64) ___ svn-src-head@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
svn commit: r256935 - in head/sys: conf mips/beri mips/include mips/mips
Author: brooks Date: Tue Oct 22 21:08:25 2013 New Revision: 256935 URL: http://svnweb.freebsd.org/changeset/base/256935 Log: MFP4: Change 228019 by bz@bz_zenith on 2013/04/23 13:55:30 Add kernel side support for large TLB on BERI/CHERI. Modelled similar to NLM MFC after:3 days Sponsored by: DAPRA/AFRL Modified: head/sys/conf/options.mips head/sys/mips/beri/std.beri head/sys/mips/include/cpufunc.h head/sys/mips/mips/cpu.c Modified: head/sys/conf/options.mips == --- head/sys/conf/options.mips Tue Oct 22 21:06:27 2013(r256934) +++ head/sys/conf/options.mips Tue Oct 22 21:08:25 2013(r256935) @@ -81,6 +81,11 @@ OCTEON_VENDOR_GEFES opt_cvmx.h OCTEON_BOARD_CAPK_0100ND opt_cvmx.h # +# Options specific to the BERI platform. +# +BERI_LARGE_TLB opt_global.h + +# # Options that control the Atheros SoC peripherals # ARGE_DEBUG opt_arge.h Modified: head/sys/mips/beri/std.beri == --- head/sys/mips/beri/std.beri Tue Oct 22 21:06:27 2013(r256934) +++ head/sys/mips/beri/std.beri Tue Oct 22 21:08:25 2013(r256935) @@ -2,3 +2,5 @@ files "../beri/files.beri" cpuCPU_MIPS4KC + +optionsBERI_LARGE_TLB Modified: head/sys/mips/include/cpufunc.h == --- head/sys/mips/include/cpufunc.h Tue Oct 22 21:06:27 2013 (r256934) +++ head/sys/mips/include/cpufunc.h Tue Oct 22 21:08:25 2013 (r256935) @@ -242,8 +242,13 @@ MIPS_RW32_COP0_SEL(config3, MIPS_COP_0_C #ifdef CPU_CNMIPS MIPS_RW32_COP0_SEL(config4, MIPS_COP_0_CONFIG, 4); #endif -#ifdef CPU_NLM +#ifdef BERI_LARGE_TLB +MIPS_RW32_COP0_SEL(config5, MIPS_COP_0_CONFIG, 5); +#endif +#if defined(CPU_NLM) || defined(BERI_LARGE_TLB) MIPS_RW32_COP0_SEL(config6, MIPS_COP_0_CONFIG, 6); +#endif +#ifdef CPU_NLM MIPS_RW32_COP0_SEL(config7, MIPS_COP_0_CONFIG, 7); #endif MIPS_RW32_COP0(count, MIPS_COP_0_COUNT); Modified: head/sys/mips/mips/cpu.c == --- head/sys/mips/mips/cpu.cTue Oct 22 21:06:27 2013(r256934) +++ head/sys/mips/mips/cpu.cTue Oct 22 21:08:25 2013(r256935) @@ -99,17 +99,29 @@ mips_get_identity(struct mips_cpuinfo *c /* Learn TLB size and L1 cache geometry. */ cfg1 = mips_rd_config1(); -#ifndef CPU_NLM - cpuinfo->tlb_nentries = - ((cfg1 & MIPS_CONFIG1_TLBSZ_MASK) >> MIPS_CONFIG1_TLBSZ_SHIFT) + 1; -#else + +#if defined(CPU_NLM) /* Account for Extended TLB entries in XLP */ tmp = mips_rd_config6(); cpuinfo->tlb_nentries = ((tmp >> 16) & 0x) + 1; +#elif defined(BERI_LARGE_TLB) + /* Check if we support extended TLB entries and if so activate. */ + tmp = mips_rd_config5(); +#defineBERI_CP5_LTLB_SUPPORTED 0x1 + if (tmp & BERI_CP5_LTLB_SUPPORTED) { + /* See how many extra TLB entries we have. */ + tmp = mips_rd_config6(); + cpuinfo->tlb_nentries = (tmp >> 16) + 1; + /* Activate the extended entries. */ + mips_wr_config6(tmp|0x4); + } else +#endif +#if !defined(CPU_NLM) + cpuinfo->tlb_nentries = + ((cfg1 & MIPS_CONFIG1_TLBSZ_MASK) >> MIPS_CONFIG1_TLBSZ_SHIFT) + 1; #endif - - /* Add extended TLB size information from config4. */ #if defined(CPU_CNMIPS) + /* Add extended TLB size information from config4. */ cfg4 = mips_rd_config4(); if ((cfg4 & MIPS_CONFIG4_MMUEXTDEF) == MIPS_CONFIG4_MMUEXTDEF_MMUSIZEEXT) cpuinfo->tlb_nentries += (cfg4 & MIPS_CONFIG4_MMUSIZEEXT) * 0x40; @@ -124,8 +136,8 @@ mips_get_identity(struct mips_cpuinfo *c 1 << (((cfg1 & MIPS_CONFIG1_IS_MASK) >> MIPS_CONFIG1_IS_SHIFT) + 6); } -#ifndef CPU_CNMIPS /* L1 data cache. */ +#ifndef CPU_CNMIPS tmp = (cfg1 & MIPS_CONFIG1_DL_MASK) >> MIPS_CONFIG1_DL_SHIFT; if (tmp != 0) { cpuinfo->l1.dc_linesize = 1 << (tmp + 1); ___ svn-src-head@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
svn commit: r256936 - head/sys/mips/beri
Author: brooks Date: Tue Oct 22 21:13:02 2013 New Revision: 256936 URL: http://svnweb.freebsd.org/changeset/base/256936 Log: Remove a bit of debugging output that slipped into r256911. MFC after:3 days Sponsored by: DARPA/AFRL Modified: head/sys/mips/beri/beri_pic.c Modified: head/sys/mips/beri/beri_pic.c == --- head/sys/mips/beri/beri_pic.c Tue Oct 22 21:08:25 2013 (r256935) +++ head/sys/mips/beri/beri_pic.c Tue Oct 22 21:13:02 2013 (r256936) @@ -646,15 +646,9 @@ beripic_send_ipi(device_t ic, u_int tid) KASSERT(tid < sc->bp_nsoft, ("tid (%d) too large\n", tid)); - printf("sending ipi to %d soft intrs %jx\n", tid, - bus_space_read_8(sc->bp_read_bst, sc->bp_read_bsh, 8)); - bit = 1ULL << (tid % 64); bus_space_write_8(sc->bp_set_bst, sc->bp_set_bsh, (BP_FIRST_SOFT / 8) + (tid / 64), bit); - - printf("sent ipi to %d soft intrs %jx\n", tid, - bus_space_read_8(sc->bp_read_bst, sc->bp_read_bsh, 8)); } static void ___ svn-src-head@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
svn commit: r256937 - in head/sys: conf mips/mips
Author: brooks Date: Tue Oct 22 21:16:57 2013 New Revision: 256937 URL: http://svnweb.freebsd.org/changeset/base/256937 Log: MFP4: Change 231031 by brooks@brooks_zenith on 2013/07/11 16:22:08 Turn the unused and uncompilable MIPS_DISABLE_L1_CACHE define in cache.c into an option and when set force I- and D-cache line sizes to 0 (the latter part might be better as a tunable). Fix some casts in an #if 0'd bit of code which attempts to disable L1 cache ops when the cache is coherent. Sponsored by: DARPA/AFRL Modified: head/sys/conf/options.mips head/sys/mips/mips/cache.c head/sys/mips/mips/cpu.c Modified: head/sys/conf/options.mips == --- head/sys/conf/options.mips Tue Oct 22 21:13:02 2013(r256936) +++ head/sys/conf/options.mips Tue Oct 22 21:16:57 2013(r256937) @@ -71,6 +71,11 @@ TICK_USE_MALTA_RTC opt_global.h MAXMEM opt_global.h # +# Manual override of cache config +# +MIPS_DISABLE_L1_CACHE opt_global.h + +# # Options that control the Cavium Simple Executive. # OCTEON_MODEL opt_cvmx.h Modified: head/sys/mips/mips/cache.c == --- head/sys/mips/mips/cache.c Tue Oct 22 21:13:02 2013(r256936) +++ head/sys/mips/mips/cache.c Tue Oct 22 21:16:57 2013(r256937) @@ -116,11 +116,9 @@ mips_config_cache(struct mips_cpuinfo * #ifdef MIPS_DISABLE_L1_CACHE case 0: - mips_cache_ops.mco_icache_sync_all = cache_noop; - mips_cache_ops.mco_icache_sync_range = - (void (*)(vaddr_t, vsize_t))cache_noop; - mips_cache_ops.mco_icache_sync_range_index = - (void (*)(vaddr_t, vsize_t))cache_noop; + mips_cache_ops.mco_icache_sync_all = (void (*)(void))cache_noop; + mips_cache_ops.mco_icache_sync_range = cache_noop; + mips_cache_ops.mco_icache_sync_range_index = cache_noop; break; #endif default: @@ -193,20 +191,16 @@ mips_config_cache(struct mips_cpuinfo * #endif #ifdef MIPS_DISABLE_L1_CACHE case 0: - mips_cache_ops.mco_pdcache_wbinv_all = cache_noop; - mips_cache_ops.mco_intern_pdcache_wbinv_all = cache_noop; - mips_cache_ops.mco_pdcache_wbinv_range = - (void (*)(vaddr_t, vsize_t))cache_noop; - mips_cache_ops.mco_pdcache_wbinv_range_index = - (void (*)(vaddr_t, vsize_t))cache_noop; + mips_cache_ops.mco_pdcache_wbinv_all = + mips_cache_ops.mco_intern_pdcache_wbinv_all = + (void (*)(void))cache_noop; + mips_cache_ops.mco_pdcache_wbinv_range = cache_noop; + mips_cache_ops.mco_pdcache_wbinv_range_index = cache_noop; mips_cache_ops.mco_intern_pdcache_wbinv_range_index = - (void (*)(vaddr_t, vsize_t))cache_noop; - mips_cache_ops.mco_pdcache_inv_range = - (void (*)(vaddr_t, vsize_t))cache_noop; - mips_cache_ops.mco_pdcache_wb_range = - (void (*)(vaddr_t, vsize_t))cache_noop; - mips_cache_ops.mco_intern_pdcache_wb_range = - (void (*)(vaddr_t, vsize_t))cache_noop; + cache_noop; + mips_cache_ops.mco_pdcache_inv_range = cache_noop; + mips_cache_ops.mco_pdcache_wb_range = cache_noop; + mips_cache_ops.mco_intern_pdcache_wb_range = cache_noop; break; #endif default: @@ -222,26 +216,22 @@ mips_config_cache(struct mips_cpuinfo * #ifdef CACHE_DEBUG printf(" Dcache is coherent\n"); #endif - mips_cache_ops.mco_pdcache_wbinv_all = cache_noop; - mips_cache_ops.mco_pdcache_wbinv_range = - (void (*)(vaddr_t, vsize_t))cache_noop; - mips_cache_ops.mco_pdcache_wbinv_range_index = - (void (*)(vaddr_t, vsize_t))cache_noop; - mips_cache_ops.mco_pdcache_inv_range = - (void (*)(vaddr_t, vsize_t))cache_noop; - mips_cache_ops.mco_pdcache_wb_range = - (void (*)(vaddr_t, vsize_t))cache_noop; + mips_cache_ops.mco_pdcache_wbinv_all = + (void (*)(void))cache_noop; + mips_cache_ops.mco_pdcache_wbinv_range = cache_noop; + mips_cache_ops.mco_pdcache_wbinv_range_index = cache_noop; + mips_cache_ops.mco_pdcache_inv_range = cache_noop; + mips_cache_ops.mco_pdcache_wb_range = cache_noop; } if (mips_cpu_flags & CPU_MIPS_I_D_CACHE_COHERENT) { #ifdef CACHE_DEBUG printf(" Icache is coherent against Dcache\n"); #endif mips_cache_ops.mco_
svn commit: r256938 - head/sys/dev/ofw
Author: nwhitehorn Date: Tue Oct 22 21:20:05 2013 New Revision: 256938 URL: http://svnweb.freebsd.org/changeset/base/256938 Log: A few other common cases for encode-int decoding: OF_getencprop_alloc() and OF_searchencprop(). I thought about using the element size parameter to OF_getprop_alloc() to do endian-switching automatically, but it breaks use with structs and a *lot* of FDT code (which can hopefully be moved to these new APIs). MFC after:2 weeks Modified: head/sys/dev/ofw/openfirm.c head/sys/dev/ofw/openfirm.h Modified: head/sys/dev/ofw/openfirm.c == --- head/sys/dev/ofw/openfirm.c Tue Oct 22 21:16:57 2013(r256937) +++ head/sys/dev/ofw/openfirm.c Tue Oct 22 21:20:05 2013(r256938) @@ -312,6 +312,17 @@ OF_searchprop(phandle_t node, const char return (-1); } +ssize_t +OF_searchencprop(phandle_t node, const char *propname, void *buf, size_t len) +{ + ssize_t rv; + + for (; node != 0; node = OF_parent(node)) + if ((rv = OF_getencprop(node, propname, buf, len)) != -1) + return (rv); + return (-1); +} + /* * Store the value of a property of a package into newly allocated memory * (using the M_OFWPROP malloc pool and M_WAITOK). elsz is the size of a @@ -336,6 +347,26 @@ OF_getprop_alloc(phandle_t package, cons return (len / elsz); } +ssize_t +OF_getencprop_alloc(phandle_t package, const char *name, int elsz, void **buf) +{ + ssize_t retval; + pcell_t *cell; + int i; + + KASSERT(elsz % 4 == 0, "Need a multiple of 4 bytes"); + + retval = OF_getprop_alloc(package, name, elsz, buf); + if (retval == -1) + return (retval); + + cell = *buf; + for (i = 0; i < retval*elsz/4; i++) + cell[i] = be32toh(cell[i]); + + return (retval); +} + /* Get the next property of a package. */ int OF_nextprop(phandle_t package, const char *previous, char *buf, size_t size) Modified: head/sys/dev/ofw/openfirm.h == --- head/sys/dev/ofw/openfirm.h Tue Oct 22 21:16:57 2013(r256937) +++ head/sys/dev/ofw/openfirm.h Tue Oct 22 21:20:05 2013(r256938) @@ -110,8 +110,12 @@ ssize_tOF_getencprop(phandle_t node, c intOF_hasprop(phandle_t node, const char *propname); ssize_tOF_searchprop(phandle_t node, const char *propname, void *buf, size_t len); +ssize_tOF_searchencprop(phandle_t node, const char *propname, + void *buf, size_t len); ssize_tOF_getprop_alloc(phandle_t node, const char *propname, int elsz, void **buf); +ssize_tOF_getencprop_alloc(phandle_t node, const char *propname, + int elsz, void **buf); intOF_nextprop(phandle_t node, const char *propname, char *buf, size_t len); intOF_setprop(phandle_t node, const char *name, const void *buf, ___ svn-src-head@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
svn commit: r256939 - head/sys/mips/mips
Author: brooks Date: Tue Oct 22 21:27:22 2013 New Revision: 256939 URL: http://svnweb.freebsd.org/changeset/base/256939 Log: MFP4: Change 221767 by rwatson@rwatson_zenith_cl_cam_ac_uk on 2013/02/05 14:18:53 When printing out information on a TLB MOD exception for a user process (e.g., an attempt to write to a read-only page), report it as a "write" in the console message, rather than "unknown". Change 221768 by rwatson@rwatson_zenith_cl_cam_ac_uk on 2013/02/05 14:28:00 Fix post-compile but pre-commit typo in last changeset. MFC after:3 days Sponsored by: DARPA/AFRL Modified: head/sys/mips/mips/trap.c Modified: head/sys/mips/mips/trap.c == --- head/sys/mips/mips/trap.c Tue Oct 22 21:20:05 2013(r256938) +++ head/sys/mips/mips/trap.c Tue Oct 22 21:27:22 2013(r256939) @@ -1520,6 +1520,7 @@ log_bad_page_fault(char *msg, struct tra printf("cpuid = %d\n", PCPU_GET(cpuid)); #endif switch (trap_type) { + case T_TLB_MOD: case T_TLB_ST_MISS: case T_ADDR_ERR_ST: read_or_write = "write"; ___ svn-src-head@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
svn commit: r256940 - head/sys/boot/i386/libi386
Author: jkim Date: Tue Oct 22 21:32:28 2013 New Revision: 256940 URL: http://svnweb.freebsd.org/changeset/base/256940 Log: Allow users to set UUID in network byte order regardless of SMBIOS version. Define BOOT_NETWORK_ENDIAN_UUID in make.conf(5) to enable this feature. Modified: head/sys/boot/i386/libi386/Makefile head/sys/boot/i386/libi386/smbios.c Modified: head/sys/boot/i386/libi386/Makefile == --- head/sys/boot/i386/libi386/Makefile Tue Oct 22 21:27:22 2013 (r256939) +++ head/sys/boot/i386/libi386/Makefile Tue Oct 22 21:32:28 2013 (r256940) @@ -36,6 +36,9 @@ CFLAGS+= -DSMBIOS_SERIAL_NUMBERS .if defined(BOOT_LITTLE_ENDIAN_UUID) # Use little-endian UUID format as defined in SMBIOS 2.6. CFLAGS+= -DSMBIOS_LITTLE_ENDIAN_UUID +.elif defined(BOOT_NETWORK_ENDIAN_UUID) +# Use network-endian UUID format for backward compatibility. +CFLAGS+= -DSMBIOS_NETWORK_ENDIAN_UUID .endif .endif Modified: head/sys/boot/i386/libi386/smbios.c == --- head/sys/boot/i386/libi386/smbios.c Tue Oct 22 21:27:22 2013 (r256939) +++ head/sys/boot/i386/libi386/smbios.c Tue Oct 22 21:32:28 2013 (r256940) @@ -122,7 +122,7 @@ static void smbios_setuuid(const char *name, const caddr_t addr, const int ver) { charuuid[37]; - int i, ones, zeros; + int byteorder, i, ones, zeros; UUID_TYPE n; uint32_tf1; uint16_tf2, f3; @@ -152,14 +152,18 @@ smbios_setuuid(const char *name, const c * Note: We use network byte order for backward compatibility * unless SMBIOS version is 2.6+ or little-endian is forced. */ -#ifndef SMBIOS_LITTLE_ENDIAN_UUID - if (ver < 0x0206) { +#if defined(SMBIOS_LITTLE_ENDIAN_UUID) + byteorder = LITTLE_ENDIAN; +#elif defined(SMBIOS_NETWORK_ENDIAN_UUID) + byteorder = BIG_ENDIAN; +#else + byteorder = ver < 0x0206 ? BIG_ENDIAN : LITTLE_ENDIAN; +#endif + if (byteorder != LITTLE_ENDIAN) { f1 = ntohl(SMBIOS_GET32(addr, 0)); f2 = ntohs(SMBIOS_GET16(addr, 4)); f3 = ntohs(SMBIOS_GET16(addr, 6)); - } else -#endif - { + } else { f1 = le32toh(SMBIOS_GET32(addr, 0)); f2 = le16toh(SMBIOS_GET16(addr, 4)); f3 = le16toh(SMBIOS_GET16(addr, 6)); ___ svn-src-head@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
svn commit: r256941 - head/sys/arm/arm
Author: cognet Date: Tue Oct 22 21:47:34 2013 New Revision: 256941 URL: http://svnweb.freebsd.org/changeset/base/256941 Log: Try to make sure the frame is indeed in the kernel memory. Modified: head/sys/arm/arm/stack_machdep.c Modified: head/sys/arm/arm/stack_machdep.c == --- head/sys/arm/arm/stack_machdep.cTue Oct 22 21:32:28 2013 (r256940) +++ head/sys/arm/arm/stack_machdep.cTue Oct 22 21:47:34 2013 (r256941) @@ -43,13 +43,16 @@ __FBSDID("$FreeBSD$"); * APCS where it lays out the stack incorrectly. Because of this we disable * this when building for ARM EABI or when building with clang. */ + +extern vm_offset_t kernel_vm_end; + static void stack_capture(struct stack *st, u_int32_t *frame) { #if !defined(__ARM_EABI__) && !defined(__clang__) vm_offset_t callpc; - while (INKERNEL(frame)) { + while (INKERNEL(frame) && (vm_offset_t)frame < kernel_vm_end) { callpc = frame[FR_SCP]; if (stack_put(st, callpc) == -1) break; ___ svn-src-head@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
svn commit: r256942 - head/sys/arm/xscale/ixp425
Author: cognet Date: Tue Oct 22 21:49:58 2013 New Revision: 256942 URL: http://svnweb.freebsd.org/changeset/base/256942 Log: Typo fix. Modified: head/sys/arm/xscale/ixp425/ixp425_mem.c Modified: head/sys/arm/xscale/ixp425/ixp425_mem.c == --- head/sys/arm/xscale/ixp425/ixp425_mem.c Tue Oct 22 21:47:34 2013 (r256941) +++ head/sys/arm/xscale/ixp425/ixp425_mem.c Tue Oct 22 21:49:58 2013 (r256942) @@ -76,7 +76,7 @@ ixp425_sdram_size(void) size = sdram_other[MCU_SDR_CONFIG_MCONF(sdr_config)]; if (size == 0) { - printf("** SDR_CONFIG retuns unknown value, using 32M\n"); + printf("** SDR_CONFIG returns unknown value, using 32M\n"); size = 32 * 1024 * 1024; } ___ svn-src-head@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
svn commit: r256943 - head/sys/arm/xscale/ixp425
Author: cognet Date: Tue Oct 22 21:51:07 2013 New Revision: 256943 URL: http://svnweb.freebsd.org/changeset/base/256943 Log: - Use bus_dmamap_unload(), it is not optional. - The new allocator won't return coherent memory for any size > PAGE_SIZE, so don't assume we have coherent memory, and explicitely use bus_dmamap_sync(). Modified: head/sys/arm/xscale/ixp425/if_npe.c Modified: head/sys/arm/xscale/ixp425/if_npe.c == --- head/sys/arm/xscale/ixp425/if_npe.c Tue Oct 22 21:49:58 2013 (r256942) +++ head/sys/arm/xscale/ixp425/if_npe.c Tue Oct 22 21:51:07 2013 (r256943) @@ -507,7 +507,6 @@ npe_dma_setup(struct npe_softc *sc, stru dma->name, error); return error; } - /* XXX COHERENT for now */ if (bus_dmamem_alloc(dma->buf_tag, (void **)&dma->hwbuf, BUS_DMA_NOWAIT | BUS_DMA_ZERO | BUS_DMA_COHERENT, &dma->buf_map) != 0) { @@ -1073,6 +1072,7 @@ npe_rxbuf_init(struct npe_softc *sc, str m->m_pkthdr.len = m->m_len = 1536; /* backload payload and align ip hdr */ m->m_data = m->m_ext.ext_buf + (m->m_ext.ext_size - (1536+ETHER_ALIGN)); + bus_dmamap_unload(dma->mtag, npe->ix_map); error = bus_dmamap_load_mbuf_sg(dma->mtag, npe->ix_map, m, segs, &nseg, 0); if (error != 0) { @@ -1085,6 +1085,8 @@ npe_rxbuf_init(struct npe_softc *sc, str /* NB: buffer length is shifted in word */ hw->ix_ne[0].len = htobe32(segs[0].ds_len << 16); hw->ix_ne[0].next = 0; + bus_dmamap_sync(dma->buf_tag, dma->buf_map, + BUS_DMASYNC_PREREAD|BUS_DMASYNC_PREWRITE); npe->ix_m = m; /* Flush the memory in the mbuf */ bus_dmamap_sync(dma->mtag, npe->ix_map, BUS_DMASYNC_PREREAD); @@ -1110,6 +1112,8 @@ npe_rxdone(int qid, void *arg) struct npebuf *npe = P2V(NPE_QM_Q_ADDR(entry), dma); struct mbuf *m; + bus_dmamap_sync(dma->buf_tag, dma->buf_map, + BUS_DMASYNC_POSTREAD); DPRINTF(sc, "%s: entry 0x%x neaddr 0x%x ne_len 0x%x\n", __func__, entry, npe->ix_neaddr, npe->ix_hw->ix_ne[0].len); /* @@ -1130,7 +1134,6 @@ npe_rxdone(int qid, void *arg) bus_dmamap_sync(dma->mtag, npe->ix_map, BUS_DMASYNC_POSTREAD); - /* XXX flush hw buffer; works now 'cuz coherent */ /* set m_len etc. per rx frame size */ mrx->m_len = be32toh(hw->ix_ne[0].len) & 0x; mrx->m_pkthdr.len = mrx->m_len; @@ -1313,6 +1316,7 @@ npestart_locked(struct ifnet *ifp) return; } npe = sc->tx_free; + bus_dmamap_unload(dma->mtag, npe->ix_map); error = bus_dmamap_load_mbuf_sg(dma->mtag, npe->ix_map, m, segs, &nseg, 0); if (error == EFBIG) { @@ -1355,7 +1359,8 @@ npestart_locked(struct ifnet *ifp) next += sizeof(hw->ix_ne[0]); } hw->ix_ne[i-1].next = 0;/* zero last in chain */ - /* XXX flush descriptor instead of using uncached memory */ + bus_dmamap_sync(dma->buf_tag, dma->buf_map, + BUS_DMASYNC_PREREAD|BUS_DMASYNC_PREWRITE); DPRINTF(sc, "%s: qwrite(%u, 0x%x) ne_data %x ne_len 0x%x\n", __func__, sc->tx_qid, npe->ix_neaddr, ___ svn-src-head@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
svn commit: r256945 - head/sys/kern
Author: brooks Date: Tue Oct 22 22:03:01 2013 New Revision: 256945 URL: http://svnweb.freebsd.org/changeset/base/256945 Log: MFP4: Change 221669 by bz@bz_zenith on 2013/02/01 12:26:04 Run the initialization for polling earlier along with INTRs so that we can put network interface into polling mode by default if DEVICE_POLLING is compiled in and no interrupts are available. MFC after:3 days Sponsored by: DARPA/AFRL Modified: head/sys/kern/kern_poll.c Modified: head/sys/kern/kern_poll.c == --- head/sys/kern/kern_poll.c Tue Oct 22 21:53:32 2013(r256944) +++ head/sys/kern/kern_poll.c Tue Oct 22 22:03:01 2013(r256945) @@ -267,7 +267,7 @@ init_device_poll(void) EVENTHANDLER_REGISTER(shutdown_post_sync, poll_shutdown, NULL, SHUTDOWN_PRI_LAST); } -SYSINIT(device_poll, SI_SUB_CLOCKS, SI_ORDER_MIDDLE, init_device_poll, NULL); +SYSINIT(device_poll, SI_SUB_SOFTINTR, SI_ORDER_MIDDLE, init_device_poll, NULL); /* ___ svn-src-head@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
svn commit: r256946 - head/tools/tools/atsectl
Author: brooks Date: Tue Oct 22 22:17:48 2013 New Revision: 256946 URL: http://svnweb.freebsd.org/changeset/base/256946 Log: MFP4: 1187103, 222076, 222057, 222051, 221799 Add atsectl, a simple utility to read and update MAC addresses stored in the default flash location on Altera DE4 boards. Typically used once when setting up a board so leaving in tools rather than inflicting on all users. To build with world add LOCAL_DIRS=tools/tools/atsectl to the make command line. MFC after:3 days Sponsored by: DARPA/AFRL Added: head/tools/tools/atsectl/ head/tools/tools/atsectl/Makefile (contents, props changed) head/tools/tools/atsectl/atsectl.c (contents, props changed) Added: head/tools/tools/atsectl/Makefile == --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/tools/tools/atsectl/Makefile Tue Oct 22 22:17:48 2013 (r256946) @@ -0,0 +1,12 @@ +# $FreeBSD$ + +PROG= atsectl + +DPADD= ${LIBMD} +LDADD= -lmd + +BINDIR?= /usr/sbin + +NO_MAN= + +.include Added: head/tools/tools/atsectl/atsectl.c == --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/tools/tools/atsectl/atsectl.c Tue Oct 22 22:17:48 2013 (r256946) @@ -0,0 +1,327 @@ +/*- + * Copyright (c) 2012 SRI International + * Copyright (c) 2013 Bjoern A. Zeeb + * All rights reserved. + * + * This software was developed by SRI International and the University of + * Cambridge Computer Laboratory under DARPA/AFRL contract (FA8750-10-C-0237) + * ("CTSRD"), as part of the DARPA CRASH research programme. + * + * This software was developed by SRI International and the University of + * Cambridge Computer Laboratory under DARPA/AFRL contract (FA8750-11-C-0249) + * ("MRC2"), as part of the DARPA MRC research programme. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + *notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + *notice, this list of conditions and the following disclaimer in the + *documentation and/or other materials provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND + * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE + * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE + * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE + * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL + * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS + * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) + * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY + * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF + * SUCH DAMAGE. + * + * $ FreeBSD: head/usr.sbin/isfctl/isfctl.c 239685 2012-08-25 18:08:20Z brooks $ + * $FreeBSD$ + */ + +#include +#include +#include +#include +#include + +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +#include +#include + + +#defineCONFIG_BLOCK (128 * 1024) +#defineDEV_CFI0_PATH "/dev/cfi0" + +static u_char block[CONFIG_BLOCK]; + +#defineUNKNOWN 0 +#defineCFI 1 +static int fdev= UNKNOWN; +static const char *fdevs[] = { + "UNKNOWN", + "CFI" +}; +static int gflag; + +/* XXX-BZ should include if_atsereg.h. */ +#defineALTERA_ETHERNET_OPTION_BITS_OFF 0x8000 +#defineALTERA_ETHERNET_OPTION_BITS_LEN 0x7fff + + +static void +usage(int rc) +{ + + fprintf(stderr, "usage: atsectl [-ghlu] [-s ]\n"); + exit(rc); +} + +static void +read_block(void) +{ + int fd; + + fd = open(DEV_CFI0_PATH, O_RDONLY, 0); + if (fd == -1) + errx(1, "Failed to open " DEV_CFI0_PATH); + else + fdev = CFI; + + if (read(fd, block, sizeof(block)) != CONFIG_BLOCK) + errx(1, "Short read from %s", fdevs[fdev]); + + close(fd); +} + +static void +write_block(void) +{ + int fd; + + assert(fdev == CFI); + + fd = open(DEV_CFI0_PATH, O_WRONLY, 0); + if (fd == -1) + errx(1, "Failed to open " DEV_CFI0_PATH); + + if (write(fd, block, sizeof(block)) != CONFIG_BLOCK) + errx(1, "Short write on %s", fdevs[fdev]); + + close(fd); +} + +static void +print_eaddr(void) +{ + uint32_t safe; + + /* +* XXX-BZ we are on our own: keep
Re: svn commit: r256943 - head/sys/arm/xscale/ixp425
On Tue, 2013-10-22 at 21:51 +, Olivier Houchard wrote: > Author: cognet > Date: Tue Oct 22 21:51:07 2013 > New Revision: 256943 > URL: http://svnweb.freebsd.org/changeset/base/256943 > > Log: > - Use bus_dmamap_unload(), it is not optional. > - The new allocator won't return coherent memory for any size > PAGE_SIZE, > so don't assume we have coherent memory, and explicitely use > bus_dmamap_sync(). > > Modified: > head/sys/arm/xscale/ixp425/if_npe.c > [snip] Whoa, not true! If you ask for BUS_DMA_COHERENT memory on arm you are g'teed to get uncached memory. If the size you ask for is under one page it comes from the uma allocator, if you want a page or more it comes from either kmem_alloc_attr() or kmem_alloc_contig() using the VM_MEMATTR_UNCACHEABLE flag, which is handled in arm/pmap[-v6].c by turning off the cache and buffered bits on the pages. -- Ian ___ svn-src-head@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
svn commit: r256948 - head/sys/boot/fdt/dts
Author: ganbold (doc committer) Date: Wed Oct 23 00:35:58 2013 New Revision: 256948 URL: http://svnweb.freebsd.org/changeset/base/256948 Log: Add FDT for Radxa Rock board and Rockchip RK3188 SoC. Reviewed by: ray@ Added: head/sys/boot/fdt/dts/rk3188-radxa.dts (contents, props changed) head/sys/boot/fdt/dts/rk3188.dtsi (contents, props changed) Added: head/sys/boot/fdt/dts/rk3188-radxa.dts == --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/sys/boot/fdt/dts/rk3188-radxa.dts Wed Oct 23 00:35:58 2013 (r256948) @@ -0,0 +1,59 @@ +/*- + * Copyright (c) 2013 Ganbold Tsagaankhuu + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + *notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + *notice, this list of conditions and the following disclaimer in the + *documentation and/or other materials provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND + * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE + * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE + * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE + * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL + * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS + * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) + * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY + * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF + * SUCH DAMAGE. + * + * $FreeBSD$ + */ + +/dts-v1/; + +/include/ "rk3188.dtsi" + +/ { + model = "Radxa RadxaRock"; + + memory { + device_type = "memory"; + reg = < 0x6000 0x8000 >;/* 2GB RAM */ + }; + + aliases { + soc = &SOC; + }; + + SOC: rk3188 { + + uart2: serial@20064000 { + status = "okay"; + }; + + }; + + chosen { + bootargs = "-v"; + stdin = &uart2; + stdout = &uart2; + }; +}; + Added: head/sys/boot/fdt/dts/rk3188.dtsi == --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/sys/boot/fdt/dts/rk3188.dtsi Wed Oct 23 00:35:58 2013 (r256948) @@ -0,0 +1,251 @@ +/*- + * Copyright (c) 2013 Ganbold Tsagaankhuu + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + *notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + *notice, this list of conditions and the following disclaimer in the + *documentation and/or other materials provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND + * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE + * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE + * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE + * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL + * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS + * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) + * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY + * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF + * SUCH DAMAGE. + * + * $FreeBSD$ + */ + +/ { + compatible = "rockchip,rk3188"; + #address-cells = <1>; + #size-cells = <1>; + + aliases { + soc = &SOC; + }; + + SOC: rk3188 { + #address-cells = <1>; + #size-cells = <1>; + compatible = "simple-bus"; + ranges; + bus-frequency = <0>; + + GIC: interrupt-controller@1013d000 { + compatible = "arm,gic"; + reg = <0x1013d000 0x1000>,/* Distributor Registers */ + <0x1013c100 0x0100>;/* CPU Interface Registers */ + interrupt-cont
svn commit: r256949 - head/sys/arm/rockchip
Author: ganbold (doc committer) Date: Wed Oct 23 00:39:43 2013 New Revision: 256949 URL: http://svnweb.freebsd.org/changeset/base/256949 Log: Import basic support for Rockchip RK3188 SoC. Reviewed by: ray@ Added: head/sys/arm/rockchip/ head/sys/arm/rockchip/bus_space.c (contents, props changed) head/sys/arm/rockchip/common.c (contents, props changed) head/sys/arm/rockchip/files.rk30xx (contents, props changed) head/sys/arm/rockchip/rk30xx_gpio.c (contents, props changed) head/sys/arm/rockchip/rk30xx_grf.c (contents, props changed) head/sys/arm/rockchip/rk30xx_grf.h (contents, props changed) head/sys/arm/rockchip/rk30xx_machdep.c (contents, props changed) head/sys/arm/rockchip/rk30xx_pmu.c (contents, props changed) head/sys/arm/rockchip/rk30xx_pmu.h (contents, props changed) head/sys/arm/rockchip/std.rk30xx (contents, props changed) Added: head/sys/arm/rockchip/bus_space.c == --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/sys/arm/rockchip/bus_space.c Wed Oct 23 00:39:43 2013 (r256949) @@ -0,0 +1,113 @@ +/*- + * Copyright (C) 2012 FreeBSD Foundation + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + *notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + *notice, this list of conditions and the following disclaimer in the + *documentation and/or other materials provided with the distribution. + * 3. Neither the name of MARVELL nor the names of contributors + *may be used to endorse or promote products derived from this software + *without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY AUTHOR AND CONTRIBUTORS ``AS IS'' AND + * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE + * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE + * ARE DISCLAIMED. IN NO EVENT SHALL AUTHOR OR CONTRIBUTORS BE LIABLE + * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL + * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS + * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) + * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY + * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF + * SUCH DAMAGE. + */ + +#include +__FBSDID("$FreeBSD$"); + +#include +#include +#include +#include +#include + +#include + +/* Prototypes for all the bus_space structure functions */ +bs_protos(generic); +bs_protos(generic_armv4); + +struct bus_space _base_tag = { + /* cookie */ + .bs_cookie = (void *) 0, + + /* mapping/unmapping */ + .bs_map = generic_bs_map, + .bs_unmap = generic_bs_unmap, + .bs_subregion = generic_bs_subregion, + + /* allocation/deallocation */ + .bs_alloc = generic_bs_alloc, + .bs_free= generic_bs_free, + + /* barrier */ + .bs_barrier = generic_bs_barrier, + + /* read (single) */ + .bs_r_1 = generic_bs_r_1, + .bs_r_2 = generic_armv4_bs_r_2, + .bs_r_4 = generic_bs_r_4, + .bs_r_8 = NULL, + + /* read multiple */ + .bs_rm_1= generic_bs_rm_1, + .bs_rm_2= generic_armv4_bs_rm_2, + .bs_rm_4= generic_bs_rm_4, + .bs_rm_8= NULL, + + /* read region */ + .bs_rr_1= generic_bs_rr_1, + .bs_rr_2= generic_armv4_bs_rr_2, + .bs_rr_4= generic_bs_rr_4, + .bs_rr_8= NULL, + + /* write (single) */ + .bs_w_1 = generic_bs_w_1, + .bs_w_2 = generic_armv4_bs_w_2, + .bs_w_4 = generic_bs_w_4, + .bs_w_8 = NULL, + + /* write multiple */ + .bs_wm_1= generic_bs_wm_1, + .bs_wm_2= generic_armv4_bs_wm_2, + .bs_wm_4= generic_bs_wm_4, + .bs_wm_8= NULL, + + /* write region */ + .bs_wr_1= generic_bs_wr_1, + .bs_wr_2= generic_armv4_bs_wr_2, + .bs_wr_4= generic_bs_wr_4, + .bs_wr_8= NULL, + + /* set multiple */ + /* XXX not implemented */ + + /* set region */ + .bs_sr_1= NULL, + .bs_sr_2= generic_armv4_bs_sr_2, + .bs_sr_4= generic_bs_sr_4, + .bs_sr_8= NULL, + + /* copy */ + .bs_c_1 = NULL, + .bs
svn commit: r256950 - head/sys/arm/conf
Author: ganbold (doc committer) Date: Wed Oct 23 00:43:22 2013 New Revision: 256950 URL: http://svnweb.freebsd.org/changeset/base/256950 Log: Radxa Rock board (by radxa.com) kernel config file. More info on the Wiki page: https://wiki.freebsd.org/FreeBSD/arm/Radxa%20Rock Reviewed by: ray@ Added: head/sys/arm/conf/RADXA (contents, props changed) Added: head/sys/arm/conf/RADXA == --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/sys/arm/conf/RADXA Wed Oct 23 00:43:22 2013(r256950) @@ -0,0 +1,119 @@ +# RADXA -- Custom configuration for the RADXA ARM development +# platform, check out http://www.radxa.com +# +# For more information on this file, please read the handbook section on +# Kernel Configuration Files: +# +# http://www.FreeBSD.org/doc/en_US.ISO8859-1/books/handbook/kernelconfig-config.html +# +# The handbook is also available locally in /usr/share/doc/handbook +# if you've installed the doc distribution, otherwise always see the +# FreeBSD World Wide Web server (http://www.FreeBSD.org/) for the +# latest information. +# +# An exhaustive list of options and more detailed explanations of the +# device lines is also present in the ../../conf/NOTES and NOTES files. +# If you are in doubt as to the purpose or necessity of a line, check first +# in NOTES. +# +# $FreeBSD$ + +ident RADXA + +include"../rockchip/std.rk30xx" + +makeoptionsMODULES_OVERRIDE="" +makeoptionsWITHOUT_MODULES="ahc" + +optionsHZ=100 +optionsSCHED_4BSD #4BSD scheduler +optionsINET#InterNETworking +optionsINET6 #IPv6 communications protocols +optionsFFS #Berkeley Fast Filesystem +optionsSOFTUPDATES #Enable FFS soft updates support +optionsUFS_ACL #Support for access control lists +optionsUFS_DIRHASH #Improve performance on big directories +optionsMSDOSFS #MSDOS Filesystem +optionsCD9660 #ISO 9660 Filesystem +optionsPROCFS #Process filesystem (requires PSEUDOFS) +optionsPSEUDOFS#Pseudo-filesystem framework +optionsCOMPAT_43 #Compatible with BSD 4.3 [KEEP THIS!] +optionsSCSI_DELAY=5000 #Delay (in ms) before probing SCSI +optionsKTRACE #ktrace(1) support +optionsSYSVSHM #SYSV-style shared memory +optionsSYSVMSG #SYSV-style message queues +optionsSYSVSEM #SYSV-style semaphores +options_KPOSIX_PRIORITY_SCHEDULING #Posix P1003_1B real-time extensions +optionsKBD_INSTALL_CDEV# install a CDEV entry in /dev +optionsPREEMPTION +optionsFREEBSD_BOOT_LOADER +optionsVFP # vfp/neon + +# Debugging +makeoptionsDEBUG=-g#Build kernel with gdb(1) debug symbols +optionsBREAK_TO_DEBUGGER +#options VERBOSE_SYSINIT #Enable verbose sysinit messages +optionsKDB +optionsDDB #Enable the kernel debugger +#options INVARIANTS #Enable calls of extra sanity checking +#options INVARIANT_SUPPORT #Extra sanity checks of internal structures, required by INVARIANTS +optionsWITNESS #Enable checks to detect deadlocks and cycles +optionsWITNESS_SKIPSPIN#Don't run witness on spinlocks for speed +optionsDIAGNOSTIC + +# NFS support +#options NFSCL +#options NFSSERVER #Network Filesystem Server +#options NFSCLIENT #Network Filesystem Client + +# MMC/SD/SDIO card slot support +#devicemmc # mmc/sd bus +#devicemmcsd # mmc/sd flash cards + +# Boot device is 2nd slice on MMC/SD card +optionsROOTDEVNAME=\"ufs:/dev/da0s2\" + +# Console and misc +device uart +device uart_ns8250 +device pty +device snp +device md +device random # Entropy device + +# I2C support +#deviceiicbus +#deviceiic + +# GPIO +device gpio + +device scbus # SCSI bus (required for SCSI) +device da # Direct Access (disks) +device pass + +# USB support +device usb +optionsUSB_DEBUG +#options USB_REQ_DEBUG +#options USB_VERBOSE +device dwcotg #DWC OTG co
svn commit: r256951 - head/sys/geom/nop
Author: mjg Date: Wed Oct 23 01:34:18 2013 New Revision: 256951 URL: http://svnweb.freebsd.org/changeset/base/256951 Log: gnop: make sure that newly allocated memory for softc is zeroed This prevents mtx_init from encountering non-zeros and panicking the kernel as a result. Reported by: Keith White Modified: head/sys/geom/nop/g_nop.c Modified: head/sys/geom/nop/g_nop.c == --- head/sys/geom/nop/g_nop.c Wed Oct 23 00:43:22 2013(r256950) +++ head/sys/geom/nop/g_nop.c Wed Oct 23 01:34:18 2013(r256951) @@ -216,7 +216,7 @@ g_nop_create(struct gctl_req *req, struc } } gp = g_new_geomf(mp, "%s", name); - sc = g_malloc(sizeof(*sc), M_WAITOK); + sc = g_malloc(sizeof(*sc), M_WAITOK | M_ZERO); sc->sc_offset = offset; sc->sc_explicitsize = explicitsize; sc->sc_error = ioerror; ___ svn-src-head@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
Re: svn commit: r256934 - head/sys/mips/include
This fails to build: cc -c -x assembler-with-cpp -DLOCORE -O -pipe -march=mips32 -std=c99 -g -Wall -Wredundant-decls -Wnested-externs -Wstrict-prototypes -Wmissing-prototypes -Wpointer-arith -Winline -Wcast-qual -Wundef -Wno-pointer-sign -fformat-extensions -Wmissing-include-dirs -fdiagnostics-show-option -nostdinc -I. -I/usr/home/adrian/work/freebsd/svn/head/src/sys -I/usr/home/adrian/work/freebsd/svn/head/src/sys/contrib/altq -I/usr/home/adrian/work/freebsd/svn/head/src/sys/contrib/libfdt -D_KERNEL -DHAVE_KERNEL_OPTION_HEADERS -include opt_global.h -fno-common -finline-limit=8000 --param inline-unit-growth=1 --param large-function-growth=10 --param max-inline-insns-single=1 -fno-pic -mno-abicalls -G0 -DKERNLOADADDR=0x8005 -march=mips32 -msoft-float -ffreestanding -O -pipe -march=mips32 -std=c99 -g -Wall -Wredundant-decls -Wnested-externs -Wstrict-prototypes -Wmissing-prototypes -Wpointer-arith -Winline -Wcast-qual -Wundef -Wno-pointer-sign -fformat-extensions -Wmissing-include-dirs -fdiagnostics-show-option -nostdinc -I. -I/usr/home/adrian/work/freebsd/svn/head/src/sys -I/usr/home/adrian/work/freebsd/svn/head/src/sys/contrib/altq -I/usr/home/adrian/work/freebsd/svn/head/src/sys/contrib/libfdt -D_KERNEL -DHAVE_KERNEL_OPTION_HEADERS -include opt_global.h -fno-common -finline-limit=8000 --param inline-unit-growth=1 --param large-function-growth=10 --param max-inline-insns-single=1 -fno-pic -mno-abicalls -G0 -DKERNLOADADDR=0x8005 -march=mips32 -msoft-float -ffreestanding -D_LOCORE -DLOCORE -Werror /usr/home/adrian/work/freebsd/svn/head/src/sys/mips/mips/locore.S --- exception.o --- /usr/home/adrian/work/freebsd/svn/head/src/sys/mips/mips/exception.S: Assembler messages: /usr/home/adrian/work/freebsd/svn/head/src/sys/mips/mips/exception.S:157: Error: Instruction sll requires absolute expression /usr/home/adrian/work/freebsd/svn/head/src/sys/mips/mips/exception.S:157: Error: Instruction srl requires absolute expression /usr/home/adrian/work/freebsd/svn/head/src/sys/mips/mips/exception.S:160: Error: Instruction sll requires absolute expression /usr/home/adrian/work/freebsd/svn/head/src/sys/mips/mips/exception.S:160: Error: Instruction srl requires absolute expression --- support.o --- --- exception.o --- /usr/home/adrian/work/freebsd/svn/head/src/sys/mips/mips/exception.S:907: Error: Instruction sll requires absolute expression /usr/home/adrian/work/freebsd/svn/head/src/sys/mips/mips/exception.S:907: Error: Instruction srl requires absolute expression /usr/home/adrian/work/freebsd/svn/head/src/sys/mips/mips/exception.S:910: Error: Instruction sll requires absolute expression /usr/home/adrian/work/freebsd/svn/head/src/sys/mips/mips/exception.S:910: Error: Instruction srl requires absolute expression /usr/home/adrian/work/freebsd/svn/head/src/sys/mips/mips/exception.S:920: Error: Instruction sll requires absolute expression /usr/home/adrian/work/freebsd/svn/head/src/sys/mips/mips/exception.S:920: Error: Instruction srl requires absolute expression /usr/home/adrian/work/freebsd/svn/head/src/sys/mips/mips/exception.S:923: Error: Instruction sll requires absolute expression /usr/home/adrian/work/freebsd/svn/head/src/sys/mips/mips/exception.S:923: Error: Instruction srl requires absolute expression /usr/home/adrian/work/freebsd/svn/head/src/sys/mips/mips/exception.S:1064: Error: Instruction sll requires absolute expression /usr/home/adrian/work/freebsd/svn/head/src/sys/mips/mips/exception.S:1064: Error: Instruction srl requires absolute expression --- support.o --- cc -c -x assembler-with-cpp -DLOCORE -O -pipe -march=mips32 -std=c99 -g -Wall -Wredundant-decls -Wnested-externs -Wstrict-prototypes -Wmissing-prototypes -Wpointer-arith -Winline -Wcast-qual -Wundef -Wno-pointer-sign -fformat-extensions -Wmissing-include-dirs -fdiagnostics-show-option -nostdinc -I. -I/usr/home/adrian/work/freebsd/svn/head/src/sys -I/usr/home/adrian/work/freebsd/svn/head/src/sys/contrib/altq -I/usr/home/adrian/work/freebsd/svn/head/src/sys/contrib/libfdt -D_KERNEL -DHAVE_KERNEL_OPTION_HEADERS -include opt_global.h -fno-common -finline-limit=8000 --param inline-unit-growth=1 --param large-function-growth=10 --param max-inline-insns-single=1 -fno-pic -mno-abicalls -G0 -DKERNLOADADDR=0x8005 -march=mips32 -msoft-float -ffreestanding -O -pipe -march=mips32 -std=c99 -g -Wall -Wredundant-decls -Wnested-externs -Wstrict-prototypes -Wmissing-prototypes -Wpointer-arith -Winline -Wcast-qual -Wundef -Wno-pointer-sign -fformat-extensions -Wmissing-include-dirs -fdiagnostics-show exception.o --- /usr/home/adrian/work/freebsd/svn/head/src/sys/mips/mips/exception.S:1067: Error: Instruction sll requires absolute expression /usr/home/adrian/work/freebsd/svn/head/src/sys/mips/mips/exception.S:1067: Error: Instruction srl requires absolute expression -adrian On 22 October 2013 14:06, Brooks Davis wrote: > Author: brooks > Date: Tue Oct 22 21:06:27 2013 > New Revision: 256934
Re: svn commit: r256934 - head/sys/mips/include
.. and it didn't compile because TLBLO_SWBITS_CLEAR_SHIFT is just plain not defined in the 32-bit mips platform case. Did you attempt to do a tinderbox build on this? Or even build a 32 bit kernel? -adrian On 22 October 2013 19:20, Adrian Chadd wrote: > This fails to build: > > cc -c -x assembler-with-cpp -DLOCORE -O -pipe -march=mips32 -std=c99 -g > -Wall -Wredundant-decls -Wnested-externs -Wstrict-prototypes > -Wmissing-prototypes -Wpointer-arith -Winline -Wcast-qual -Wundef > -Wno-pointer-sign -fformat-extensions -Wmissing-include-dirs > -fdiagnostics-show-option -nostdinc -I. > -I/usr/home/adrian/work/freebsd/svn/head/src/sys > -I/usr/home/adrian/work/freebsd/svn/head/src/sys/contrib/altq > -I/usr/home/adrian/work/freebsd/svn/head/src/sys/contrib/libfdt -D_KERNEL > -DHAVE_KERNEL_OPTION_HEADERS -include opt_global.h -fno-common > -finline-limit=8000 --param inline-unit-growth=1 --param > large-function-growth=10 --param max-inline-insns-single=1 > -fno-pic -mno-abicalls -G0 -DKERNLOADADDR=0x8005 -march=mips32 > -msoft-float -ffreestanding -O -pipe -march=mips32 -std=c99 -g -Wall > -Wredundant-decls -Wnested-externs -Wstrict-prototypes > -Wmissing-prototypes -Wpointer-arith -Winline -Wcast-qual -Wundef > -Wno-pointer-sign -fformat-extensions -Wmissing-include-dirs > -fdiagnostics-show-option -nostdinc -I. > -I/usr/home/adrian/work/freebsd/svn/head/src/sys > -I/usr/home/adrian/work/freebsd/svn/head/src/sys/contrib/altq > -I/usr/home/adrian/work/freebsd/svn/head/src/sys/contrib/libfdt -D_KERNEL > -DHAVE_KERNEL_OPTION_HEADERS -include opt_global.h -fno-common > -finline-limit=8000 --param inline-unit-growth=1 --param > large-function-growth=10 --param max-inline-insns-single=1 > -fno-pic -mno-abicalls -G0 -DKERNLOADADDR=0x8005 -march=mips32 > -msoft-float -ffreestanding -D_LOCORE -DLOCORE -Werror > /usr/home/adrian/work/freebsd/svn/head/src/sys/mips/mips/locore.S > --- exception.o --- > /usr/home/adrian/work/freebsd/svn/head/src/sys/mips/mips/exception.S: > Assembler messages: > /usr/home/adrian/work/freebsd/svn/head/src/sys/mips/mips/exception.S:157: > Error: Instruction sll requires absolute expression > /usr/home/adrian/work/freebsd/svn/head/src/sys/mips/mips/exception.S:157: > Error: Instruction srl requires absolute expression > /usr/home/adrian/work/freebsd/svn/head/src/sys/mips/mips/exception.S:160: > Error: Instruction sll requires absolute expression > /usr/home/adrian/work/freebsd/svn/head/src/sys/mips/mips/exception.S:160: > Error: Instruction srl requires absolute expression > --- support.o --- > --- exception.o --- > /usr/home/adrian/work/freebsd/svn/head/src/sys/mips/mips/exception.S:907: > Error: Instruction sll requires absolute expression > /usr/home/adrian/work/freebsd/svn/head/src/sys/mips/mips/exception.S:907: > Error: Instruction srl requires absolute expression > /usr/home/adrian/work/freebsd/svn/head/src/sys/mips/mips/exception.S:910: > Error: Instruction sll requires absolute expression > /usr/home/adrian/work/freebsd/svn/head/src/sys/mips/mips/exception.S:910: > Error: Instruction srl requires absolute expression > /usr/home/adrian/work/freebsd/svn/head/src/sys/mips/mips/exception.S:920: > Error: Instruction sll requires absolute expression > /usr/home/adrian/work/freebsd/svn/head/src/sys/mips/mips/exception.S:920: > Error: Instruction srl requires absolute expression > /usr/home/adrian/work/freebsd/svn/head/src/sys/mips/mips/exception.S:923: > Error: Instruction sll requires absolute expression > /usr/home/adrian/work/freebsd/svn/head/src/sys/mips/mips/exception.S:923: > Error: Instruction srl requires absolute expression > /usr/home/adrian/work/freebsd/svn/head/src/sys/mips/mips/exception.S:1064: > Error: Instruction sll requires absolute expression > /usr/home/adrian/work/freebsd/svn/head/src/sys/mips/mips/exception.S:1064: > Error: Instruction srl requires absolute expression > --- support.o --- > cc -c -x assembler-with-cpp -DLOCORE -O -pipe -march=mips32 -std=c99 -g > -Wall -Wredundant-decls -Wnested-externs -Wstrict-prototypes > -Wmissing-prototypes -Wpointer-arith -Winline -Wcast-qual -Wundef > -Wno-pointer-sign -fformat-extensions -Wmissing-include-dirs > -fdiagnostics-show-option -nostdinc -I. > -I/usr/home/adrian/work/freebsd/svn/head/src/sys > -I/usr/home/adrian/work/freebsd/svn/head/src/sys/contrib/altq > -I/usr/home/adrian/work/freebsd/svn/head/src/sys/contrib/libfdt -D_KERNEL > -DHAVE_KERNEL_OPTION_HEADERS -include opt_global.h -fno-common > -finline-limit=8000 --param inline-unit-growth=1 --param > large-function-growth=10 --param max-inline-insns-single=1 > -fno-pic -mno-abicalls -G0 -DKERNLOADADDR=0x8005 -march=mips32 > -msoft-float -ffreestanding -O -pipe -march=mips32 -std=c99 -g -Wall > -Wredundant-decls -Wnested-externs -Wstrict-prototypes > -Wmissing-prototypes -Wpointer-arith -Winline -Wcast-qual -Wundef > -Wno-pointer-sign -fformat-extensions -Wmissing-include-dirs > -fdiagnos
svn commit: r256952 - head/share/man/man9
Author: eadler Date: Wed Oct 23 03:27:42 2013 New Revision: 256952 URL: http://svnweb.freebsd.org/changeset/base/256952 Log: Add missing symlinks for the sbuf man page Modified: head/share/man/man9/Makefile Modified: head/share/man/man9/Makefile == --- head/share/man/man9/MakefileWed Oct 23 01:34:18 2013 (r256951) +++ head/share/man/man9/MakefileWed Oct 23 03:27:42 2013 (r256952) @@ -1143,11 +1143,14 @@ MLINKS+=sbuf.9 sbuf_bcat.9 \ sbuf.9 sbuf_finish.9 \ sbuf.9 sbuf_len.9 \ sbuf.9 sbuf_new.9 \ + sbuf.9 sbuf_new_auto.9 \ sbuf.9 sbuf_new_for_sysctl.9 \ sbuf.9 sbuf_printf.9 \ sbuf.9 sbuf_putc.9 \ sbuf.9 sbuf_set_drain.9 \ sbuf.9 sbuf_setpos.9 \ + sbuf.9 sbuf_start_section.9 \ + sbuf.9 sbuf_end_section.9 \ sbuf.9 sbuf_trim.9 \ sbuf.9 sbuf_vprintf.9 MLINKS+=scheduler.9 curpriority_cmp.9 \ ___ svn-src-head@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
svn commit: r256953 - head/sys/dev/ofw
Author: andreast Date: Wed Oct 23 03:59:51 2013 New Revision: 256953 URL: http://svnweb.freebsd.org/changeset/base/256953 Log: Fix build. Modified: head/sys/dev/ofw/openfirm.c Modified: head/sys/dev/ofw/openfirm.c == --- head/sys/dev/ofw/openfirm.c Wed Oct 23 03:27:42 2013(r256952) +++ head/sys/dev/ofw/openfirm.c Wed Oct 23 03:59:51 2013(r256953) @@ -287,7 +287,7 @@ OF_getencprop(phandle_t node, const char ssize_t retval; int i; - KASSERT(len % 4 == 0, "Need a multiple of 4 bytes"); + KASSERT(len % 4 == 0, ("Need a multiple of 4 bytes")); retval = OF_getprop(node, propname, buf, len); for (i = 0; i < len/4; i++) @@ -354,7 +354,7 @@ OF_getencprop_alloc(phandle_t package, c pcell_t *cell; int i; - KASSERT(elsz % 4 == 0, "Need a multiple of 4 bytes"); + KASSERT(elsz % 4 == 0, ("Need a multiple of 4 bytes")); retval = OF_getprop_alloc(package, name, elsz, buf); if (retval == -1) ___ svn-src-head@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
Re: svn commit: r256953 - head/sys/dev/ofw
On 10/22/13 22:59, Andreas Tobler wrote: Author: andreast Date: Wed Oct 23 03:59:51 2013 New Revision: 256953 URL: http://svnweb.freebsd.org/changeset/base/256953 Log: Fix build. Modified: head/sys/dev/ofw/openfirm.c Modified: head/sys/dev/ofw/openfirm.c == --- head/sys/dev/ofw/openfirm.c Wed Oct 23 03:27:42 2013(r256952) +++ head/sys/dev/ofw/openfirm.c Wed Oct 23 03:59:51 2013(r256953) @@ -287,7 +287,7 @@ OF_getencprop(phandle_t node, const char ssize_t retval; int i; - KASSERT(len % 4 == 0, "Need a multiple of 4 bytes"); + KASSERT(len % 4 == 0, ("Need a multiple of 4 bytes")); retval = OF_getprop(node, propname, buf, len); for (i = 0; i < len/4; i++) @@ -354,7 +354,7 @@ OF_getencprop_alloc(phandle_t package, c pcell_t *cell; int i; - KASSERT(elsz % 4 == 0, "Need a multiple of 4 bytes"); + KASSERT(elsz % 4 == 0, ("Need a multiple of 4 bytes")); retval = OF_getprop_alloc(package, name, elsz, buf); if (retval == -1) Thank you! Serves me right for doing my test builds with INVARIANTS off. -Nathan ___ svn-src-head@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
Re: svn commit: r256949 - head/sys/arm/rockchip
23 okt 2013 kl. 02:39 skrev Ganbold Tsagaankhuu : > Author: ganbold (doc committer) > Date: Wed Oct 23 00:39:43 2013 > New Revision: 256949 > URL: http://svnweb.freebsd.org/changeset/base/256949 > > Log: > Import basic support for Rockchip RK3188 SoC. > > Added: head/sys/arm/rockchip/bus_space.c > == > --- /dev/null 00:00:00 1970 (empty, because file is newly added) > +++ head/sys/arm/rockchip/bus_space.c Wed Oct 23 00:39:43 2013 > (r256949) > @@ -0,0 +1,113 @@ > +/*- > + * Copyright (C) 2012 FreeBSD Foundation > + * All rights reserved. > + * > + * Redistribution and use in source and binary forms, with or without > + * modification, are permitted provided that the following conditions > + * are met: > + * 1. Redistributions of source code must retain the above copyright > + *notice, this list of conditions and the following disclaimer. > + * 2. Redistributions in binary form must reproduce the above copyright > + *notice, this list of conditions and the following disclaimer in the > + *documentation and/or other materials provided with the distribution. > + * 3. Neither the name of MARVELL nor the names of contributors > + *may be used to endorse or promote products derived from this software > + *without specific prior written permission. Hmm? If this is copyrighted the FreeBSD Foundation, why does the copyright mention MARVELL? Copy/Paste mistake? -- Joel ___ svn-src-head@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"
Re: svn commit: r256949 - head/sys/arm/rockchip
On Wed, Oct 23, 2013 at 1:21 PM, Joel Dahl wrote: > > 23 okt 2013 kl. 02:39 skrev Ganbold Tsagaankhuu : > > > Author: ganbold (doc committer) > > Date: Wed Oct 23 00:39:43 2013 > > New Revision: 256949 > > URL: http://svnweb.freebsd.org/changeset/base/256949 > > > > Log: > > Import basic support for Rockchip RK3188 SoC. > > > > Added: head/sys/arm/rockchip/bus_space.c > > > == > > --- /dev/null 00:00:00 1970 (empty, because file is newly added) > > +++ head/sys/arm/rockchip/bus_space.c Wed Oct 23 00:39:43 2013 > (r256949) > > @@ -0,0 +1,113 @@ > > +/*- > > + * Copyright (C) 2012 FreeBSD Foundation > > + * All rights reserved. > > + * > > + * Redistribution and use in source and binary forms, with or without > > + * modification, are permitted provided that the following conditions > > + * are met: > > + * 1. Redistributions of source code must retain the above copyright > > + *notice, this list of conditions and the following disclaimer. > > + * 2. Redistributions in binary form must reproduce the above copyright > > + *notice, this list of conditions and the following disclaimer in > the > > + *documentation and/or other materials provided with the > distribution. > > + * 3. Neither the name of MARVELL nor the names of contributors > > + *may be used to endorse or promote products derived from this > software > > + *without specific prior written permission. > > Hmm? If this is copyrighted the FreeBSD Foundation, why does the copyright > mention MARVELL? > > Copy/Paste mistake? > > I have seen most of the bus_space.c in sys/arm has this type of license. Ganbold > -- > Joel > > ___ svn-src-head@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"