CVS commit: [nick-nhusb] src/sys/dev/usb
Module Name:src Committed By: skrll Date: Fri Feb 20 09:17:17 UTC 2015 Modified Files: src/sys/dev/usb [nick-nhusb]: uhci.c Log Message: Convert to USBHIST To generate a diff of this commit: cvs rdiff -u -r1.264.4.20 -r1.264.4.21 src/sys/dev/usb/uhci.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/dev/usb/uhci.c diff -u src/sys/dev/usb/uhci.c:1.264.4.20 src/sys/dev/usb/uhci.c:1.264.4.21 --- src/sys/dev/usb/uhci.c:1.264.4.20 Fri Feb 20 09:16:49 2015 +++ src/sys/dev/usb/uhci.c Fri Feb 20 09:17:17 2015 @@ -1,4 +1,4 @@ -/* $NetBSD: uhci.c,v 1.264.4.20 2015/02/20 09:16:49 skrll Exp $ */ +/* $NetBSD: uhci.c,v 1.264.4.21 2015/02/20 09:17:17 skrll Exp $ */ /* * Copyright (c) 1998, 2004, 2011, 2012 The NetBSD Foundation, Inc. @@ -42,7 +42,7 @@ */ #include sys/cdefs.h -__KERNEL_RCSID(0, $NetBSD: uhci.c,v 1.264.4.20 2015/02/20 09:16:49 skrll Exp $); +__KERNEL_RCSID(0, $NetBSD: uhci.c,v 1.264.4.21 2015/02/20 09:17:17 skrll Exp $); #include sys/param.h @@ -69,23 +69,57 @@ __KERNEL_RCSID(0, $NetBSD: uhci.c,v 1.2 #include dev/usb/uhcireg.h #include dev/usb/uhcivar.h #include dev/usb/usbroothub.h +#include dev/usb/usbhist.h /* Use bandwidth reclamation for control transfers. Some devices choke on it. */ /*#define UHCI_CTL_LOOP */ - - #ifdef UHCI_DEBUG uhci_softc_t *thesc; -#define DPRINTF(x) if (uhcidebug) printf x -#define DPRINTFN(n,x) if (uhcidebug(n)) printf x -int uhcidebug = 0; int uhcinoloop = 0; -#else -#define DPRINTF(x) -#define DPRINTFN(n,x) #endif +#ifdef USB_DEBUG +#ifndef UHCI_DEBUG +#define uhcidebug 0 +#else +static int uhcidebug = 0; + +SYSCTL_SETUP(sysctl_hw_uhci_setup, sysctl hw.uhci setup) +{ + int err; + const struct sysctlnode *rnode; + const struct sysctlnode *cnode; + + err = sysctl_createv(clog, 0, NULL, rnode, + CTLFLAG_PERMANENT, CTLTYPE_NODE, uhci, + SYSCTL_DESCR(uhci global controls), + NULL, 0, NULL, 0, CTL_HW, CTL_CREATE, CTL_EOL); + + if (err) + goto fail; + + /* control debugging printfs */ + err = sysctl_createv(clog, 0, rnode, cnode, + CTLFLAG_PERMANENT|CTLFLAG_READWRITE, CTLTYPE_INT, + debug, SYSCTL_DESCR(Enable debugging output), + NULL, 0, uhcidebug, sizeof(uhcidebug), CTL_CREATE, CTL_EOL); + if (err) + goto fail; + + return; +fail: + aprint_error(%s: sysctl_createv failed (err = %d)\n, __func__, err); +} + +#endif /* UHCI_DEBUG */ +#endif /* USB_DEBUG */ + + +#define DPRINTFN(N,FMT,A,B,C,D) USBHIST_LOGN(uhcidebug,N,FMT,A,B,C,D) +#define UHCIHIST_FUNC() USBHIST_FUNC() +#define UHCIHIST_CALLED(name) USBHIST_CALLED(uhcidebug) + /* * The UHCI controller is little endian, so on big endian machines * the data stored in memory needs to be swapped. @@ -342,7 +376,8 @@ const struct usbd_pipe_methods uhci_devi static inline uhci_soft_qh_t * uhci_find_prev_qh(uhci_soft_qh_t *pqh, uhci_soft_qh_t *sqh) { - DPRINTFN(15,(uhci_find_prev_qh: pqh=%p sqh=%p\n, pqh, sqh)); + UHCIHIST_FUNC(); UHCIHIST_CALLED(); + DPRINTFN(15, pqh=%p sqh=%p, pqh, sqh, 0, 0); for (; pqh-hlink != sqh; pqh = pqh-hlink) { #if defined(DIAGNOSTIC) || defined(UHCI_DEBUG) @@ -375,7 +410,7 @@ uhci_init(uhci_softc_t *sc) uhci_soft_qh_t *clsqh, *chsqh, *bsqh, *sqh, *lsqh; uhci_soft_td_t *std; - DPRINTFN(1,(uhci_init: start\n)); + UHCIHIST_FUNC(); UHCIHIST_CALLED(); #ifdef UHCI_DEBUG thesc = sc; @@ -519,7 +554,7 @@ uhci_init(uhci_softc_t *sc) UHCICMD(sc, UHCI_CMD_MAXP); /* Assume 64 byte packets at frame end */ - DPRINTFN(1,(uhci_init: enabling\n)); + DPRINTFN(1, Enabling..., 0, 0, 0, 0); err = uhci_run(sc, 1, 0); /* and here we go... */ UWRITE2(sc, UHCI_INTR, UHCI_INTR_TOCRCIE | UHCI_INTR_RIE | @@ -713,63 +748,68 @@ uhci_suspend(device_t dv, const pmf_qual Static void uhci_dumpregs(uhci_softc_t *sc) { - DPRINTFN(-1,(%s regs: cmd=%04x, sts=%04x, intr=%04x, frnum=%04x, - flbase=%08x, sof=%04x, portsc1=%04x, portsc2=%04x\n, - device_xname(sc-sc_dev), - UREAD2(sc, UHCI_CMD), - UREAD2(sc, UHCI_STS), - UREAD2(sc, UHCI_INTR), - UREAD2(sc, UHCI_FRNUM), - UREAD4(sc, UHCI_FLBASEADDR), - UREAD1(sc, UHCI_SOF), - UREAD2(sc, UHCI_PORTSC1), - UREAD2(sc, UHCI_PORTSC2))); + UHCIHIST_FUNC(); UHCIHIST_CALLED(); + DPRINTFN(1, cmd =%04x sts=%04x intr =%04x frnum =%04x, + UREAD2(sc, UHCI_CMD), UREAD2(sc, UHCI_STS), + UREAD2(sc, UHCI_INTR), UREAD2(sc, UHCI_FRNUM)); + DPRINTFN(1, sof =%04x portsc1=%04x portsc2=%04x flbase=%08x, + UREAD1(sc, UHCI_SOF), UREAD2(sc, UHCI_PORTSC1), + UREAD2(sc, UHCI_PORTSC2), UREAD4(sc, UHCI_FLBASEADDR)); } void uhci_dump_td(uhci_soft_td_t *p) { - char sbuf[128], sbuf2[128]; - + UHCIHIST_FUNC(); UHCIHIST_CALLED(); usb_syncmem(p-dma, p-offs, sizeof(p-td), BUS_DMASYNC_POSTWRITE | BUS_DMASYNC_POSTREAD); - DPRINTFN(-1,(TD(%p) at %08lx = link=0x%08lx status=0x%08lx - token=0x%08lx buffer=0x%08lx\n, -
CVS commit: [nick-nhusb] src/sys/dev/usb
Module Name:src Committed By: skrll Date: Fri Feb 20 09:16:49 UTC 2015 Modified Files: src/sys/dev/usb [nick-nhusb]: uhci.c Log Message: KNF To generate a diff of this commit: cvs rdiff -u -r1.264.4.19 -r1.264.4.20 src/sys/dev/usb/uhci.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/dev/usb/uhci.c diff -u src/sys/dev/usb/uhci.c:1.264.4.19 src/sys/dev/usb/uhci.c:1.264.4.20 --- src/sys/dev/usb/uhci.c:1.264.4.19 Sun Feb 1 12:08:15 2015 +++ src/sys/dev/usb/uhci.c Fri Feb 20 09:16:49 2015 @@ -1,4 +1,4 @@ -/* $NetBSD: uhci.c,v 1.264.4.19 2015/02/01 12:08:15 skrll Exp $ */ +/* $NetBSD: uhci.c,v 1.264.4.20 2015/02/20 09:16:49 skrll Exp $ */ /* * Copyright (c) 1998, 2004, 2011, 2012 The NetBSD Foundation, Inc. @@ -42,18 +42,21 @@ */ #include sys/cdefs.h -__KERNEL_RCSID(0, $NetBSD: uhci.c,v 1.264.4.19 2015/02/01 12:08:15 skrll Exp $); +__KERNEL_RCSID(0, $NetBSD: uhci.c,v 1.264.4.20 2015/02/20 09:16:49 skrll Exp $); #include sys/param.h -#include sys/systm.h + +#include sys/bus.h +#include sys/cpu.h +#include sys/device.h #include sys/kernel.h #include sys/kmem.h -#include sys/device.h -#include sys/select.h +#include sys/mutex.h #include sys/proc.h #include sys/queue.h -#include sys/bus.h -#include sys/cpu.h +#include sys/select.h +#include sys/sysctl.h +#include sys/systm.h #include machine/endian.h
CVS commit: src/sys/dev/usb
Module Name:src Committed By: nonaka Date: Fri Feb 20 14:48:55 UTC 2015 Modified Files: src/sys/dev/usb: usbdevs Log Message: PR/49681: Support BUFFALO PC-OP-RS1 To generate a diff of this commit: cvs rdiff -u -r1.689 -r1.690 src/sys/dev/usb/usbdevs Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/dev/usb/usbdevs diff -u src/sys/dev/usb/usbdevs:1.689 src/sys/dev/usb/usbdevs:1.690 --- src/sys/dev/usb/usbdevs:1.689 Wed Feb 4 14:23:04 2015 +++ src/sys/dev/usb/usbdevs Fri Feb 20 14:48:55 2015 @@ -1,4 +1,4 @@ -$NetBSD: usbdevs,v 1.689 2015/02/04 14:23:04 jmcneill Exp $ +$NetBSD: usbdevs,v 1.690 2015/02/20 14:48:55 nonaka Exp $ /* * Copyright (c) 1998-2004 The NetBSD Foundation, Inc. @@ -2084,6 +2084,7 @@ product MELCO KG54 0x0066 WLI-U2-KG54 W product MELCO KG54AI 0x0067 WLI-U2-KG54-AI WLAN product MELCO LUAU2GT 0x006e LUA-U2-GT Ethernet product MELCO NINWIFI 0x008b Nintendo Wi-Fi +product MELCO PCOPRS1 0x00b3 RemoteStation PC-OP-RS1 product MELCO SG54HP 0x00d8 WLI-U2-SG54HP product MELCO G54HP 0x00d9 WLI-U2-G54HP product MELCO KG54L 0x00da WLI-U2-KG54L
CVS commit: src/sys/dev/usb
Module Name:src Committed By: nonaka Date: Fri Feb 20 14:50:53 UTC 2015 Modified Files: src/sys/dev/usb: uftdi.c Log Message: PR/49681: Support BUFFALO PC-OP-RS1 To generate a diff of this commit: cvs rdiff -u -r1.59 -r1.60 src/sys/dev/usb/uftdi.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/dev/usb/uftdi.c diff -u src/sys/dev/usb/uftdi.c:1.59 src/sys/dev/usb/uftdi.c:1.60 --- src/sys/dev/usb/uftdi.c:1.59 Thu Dec 19 08:22:40 2013 +++ src/sys/dev/usb/uftdi.c Fri Feb 20 14:50:53 2015 @@ -1,4 +1,4 @@ -/* $NetBSD: uftdi.c,v 1.59 2013/12/19 08:22:40 msaitoh Exp $ */ +/* $NetBSD: uftdi.c,v 1.60 2015/02/20 14:50:53 nonaka Exp $ */ /* * Copyright (c) 2000 The NetBSD Foundation, Inc. @@ -30,7 +30,7 @@ */ #include sys/cdefs.h -__KERNEL_RCSID(0, $NetBSD: uftdi.c,v 1.59 2013/12/19 08:22:40 msaitoh Exp $); +__KERNEL_RCSID(0, $NetBSD: uftdi.c,v 1.60 2015/02/20 14:50:53 nonaka Exp $); #include sys/param.h #include sys/systm.h @@ -159,6 +159,7 @@ static const struct usb_devno uftdi_devs { USB_VENDOR_xxFTDI, USB_PRODUCT_xxFTDI_SHEEVAPLUG_JTAG }, { USB_VENDOR_INTREPIDCS, USB_PRODUCT_INTREPIDCS_VALUECAN }, { USB_VENDOR_INTREPIDCS, USB_PRODUCT_INTREPIDCS_NEOVI }, + { USB_VENDOR_MELCO, USB_PRODUCT_MELCO_PCOPRS1 }, { USB_VENDOR_RATOC, USB_PRODUCT_RATOC_REXUSB60F }, { USB_VENDOR_SEALEVEL, USB_PRODUCT_SEALEVEL_USBSERIAL }, { USB_VENDOR_SEALEVEL, USB_PRODUCT_SEALEVEL_SEAPORT4P1 },
CVS commit: src/sys/netinet6
Module Name:src Committed By: rjs Date: Fri Feb 20 22:13:48 UTC 2015 Modified Files: src/sys/netinet6: in6.c in6.h Log Message: Declare input argument to in6_sin_2_v4mapsin6 to be const, allows an address from the route cache to be used as the input. ok christos@. To generate a diff of this commit: cvs rdiff -u -r1.180 -r1.181 src/sys/netinet6/in6.c cvs rdiff -u -r1.82 -r1.83 src/sys/netinet6/in6.h Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/netinet6/in6.c diff -u src/sys/netinet6/in6.c:1.180 src/sys/netinet6/in6.c:1.181 --- src/sys/netinet6/in6.c:1.180 Tue Dec 2 19:36:58 2014 +++ src/sys/netinet6/in6.c Fri Feb 20 22:13:48 2015 @@ -1,4 +1,4 @@ -/* $NetBSD: in6.c,v 1.180 2014/12/02 19:36:58 christos Exp $ */ +/* $NetBSD: in6.c,v 1.181 2015/02/20 22:13:48 rjs Exp $ */ /* $KAME: in6.c,v 1.198 2001/07/18 09:12:38 itojun Exp $ */ /* @@ -62,7 +62,7 @@ */ #include sys/cdefs.h -__KERNEL_RCSID(0, $NetBSD: in6.c,v 1.180 2014/12/02 19:36:58 christos Exp $); +__KERNEL_RCSID(0, $NetBSD: in6.c,v 1.181 2015/02/20 22:13:48 rjs Exp $); #include opt_inet.h #include opt_compat_netbsd.h @@ -2341,7 +2341,7 @@ in6_sin6_2_sin(struct sockaddr_in *sin, /* Convert sockaddr_in to sockaddr_in6 in v4 mapped addr format. */ void -in6_sin_2_v4mapsin6(struct sockaddr_in *sin, struct sockaddr_in6 *sin6) +in6_sin_2_v4mapsin6(const struct sockaddr_in *sin, struct sockaddr_in6 *sin6) { memset(sin6, 0, sizeof(*sin6)); sin6-sin6_len = sizeof(struct sockaddr_in6); Index: src/sys/netinet6/in6.h diff -u src/sys/netinet6/in6.h:1.82 src/sys/netinet6/in6.h:1.83 --- src/sys/netinet6/in6.h:1.82 Tue Jan 20 21:27:36 2015 +++ src/sys/netinet6/in6.h Fri Feb 20 22:13:48 2015 @@ -1,4 +1,4 @@ -/* $NetBSD: in6.h,v 1.82 2015/01/20 21:27:36 roy Exp $ */ +/* $NetBSD: in6.h,v 1.83 2015/02/20 22:13:48 rjs Exp $ */ /* $KAME: in6.h,v 1.83 2001/03/29 02:55:07 jinmei Exp $ */ /* @@ -770,7 +770,7 @@ __BEGIN_DECLS struct cmsghdr; void in6_sin6_2_sin(struct sockaddr_in *, struct sockaddr_in6 *); -void in6_sin_2_v4mapsin6(struct sockaddr_in *, struct sockaddr_in6 *); +void in6_sin_2_v4mapsin6(const struct sockaddr_in *, struct sockaddr_in6 *); void in6_sin6_2_sin_in_sock(struct sockaddr *); void in6_sin_2_v4mapsin6_in_sock(struct sockaddr **);
CVS commit: src/sys/dev/pci
Module Name:src Committed By: nonaka Date: Fri Feb 20 15:03:53 UTC 2015 Modified Files: src/sys/dev/pci: if_iwm.c Log Message: Don't return success when hw is not ready. To generate a diff of this commit: cvs rdiff -u -r1.9 -r1.10 src/sys/dev/pci/if_iwm.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/dev/pci/if_iwm.c diff -u src/sys/dev/pci/if_iwm.c:1.9 src/sys/dev/pci/if_iwm.c:1.10 --- src/sys/dev/pci/if_iwm.c:1.9 Tue Feb 17 09:18:45 2015 +++ src/sys/dev/pci/if_iwm.c Fri Feb 20 15:03:53 2015 @@ -1,4 +1,4 @@ -/* $NetBSD: if_iwm.c,v 1.9 2015/02/17 09:18:45 nonaka Exp $ */ +/* $NetBSD: if_iwm.c,v 1.10 2015/02/20 15:03:53 nonaka Exp $ */ /* OpenBSD: if_iwm.c,v 1.18 2015/02/11 01:12:42 brad Exp */ /* @@ -105,7 +105,7 @@ */ #include sys/cdefs.h -__KERNEL_RCSID(0, $NetBSD: if_iwm.c,v 1.9 2015/02/17 09:18:45 nonaka Exp $); +__KERNEL_RCSID(0, $NetBSD: if_iwm.c,v 1.10 2015/02/20 15:03:53 nonaka Exp $); #include sys/param.h #include sys/conf.h @@ -1389,7 +1389,7 @@ iwm_prepare_card_hw(struct iwm_softc *sc int rv = 0; int t = 0; - if (!iwm_set_hw_ready(sc)) + if (iwm_set_hw_ready(sc)) goto out; /* If HW is not ready, prepare the conditions to check again */
CVS commit: src/sys/dev/pci
Module Name:src Committed By: nonaka Date: Fri Feb 20 16:16:06 UTC 2015 Modified Files: src/sys/dev/pci: if_iwm.c Log Message: Make the iwm(4) hardware receive filter pass multicast traffic from OpenBSD. Fixes inet6 autoconf, for example. To generate a diff of this commit: cvs rdiff -u -r1.10 -r1.11 src/sys/dev/pci/if_iwm.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/dev/pci/if_iwm.c diff -u src/sys/dev/pci/if_iwm.c:1.10 src/sys/dev/pci/if_iwm.c:1.11 --- src/sys/dev/pci/if_iwm.c:1.10 Fri Feb 20 15:03:53 2015 +++ src/sys/dev/pci/if_iwm.c Fri Feb 20 16:16:06 2015 @@ -1,4 +1,4 @@ -/* $NetBSD: if_iwm.c,v 1.10 2015/02/20 15:03:53 nonaka Exp $ */ +/* $NetBSD: if_iwm.c,v 1.11 2015/02/20 16:16:06 nonaka Exp $ */ /* OpenBSD: if_iwm.c,v 1.18 2015/02/11 01:12:42 brad Exp */ /* @@ -105,7 +105,7 @@ */ #include sys/cdefs.h -__KERNEL_RCSID(0, $NetBSD: if_iwm.c,v 1.10 2015/02/20 15:03:53 nonaka Exp $); +__KERNEL_RCSID(0, $NetBSD: if_iwm.c,v 1.11 2015/02/20 16:16:06 nonaka Exp $); #include sys/param.h #include sys/conf.h @@ -254,6 +254,7 @@ static int iwm_prepare_card_hw(struct iw static void iwm_apm_config(struct iwm_softc *); static int iwm_apm_init(struct iwm_softc *); static void iwm_apm_stop(struct iwm_softc *); +static int iwm_allow_mcast(struct iwm_softc *); static int iwm_start_hw(struct iwm_softc *); static void iwm_stop_device(struct iwm_softc *); static void iwm_set_pwr(struct iwm_softc *); @@ -5154,6 +5155,10 @@ iwm_auth(struct iwm_softc *sc) int error; in-in_assoc = 0; + + if ((error = iwm_allow_mcast(sc)) != 0) + return error; + if ((error = iwm_mvm_mac_ctxt_add(sc, in)) != 0) { DPRINTF((%s: failed to add MAC\n, DEVNAME(sc))); return error; @@ -5676,6 +5681,32 @@ iwm_init_hw(struct iwm_softc *sc) return error; } +/* Allow multicast from our BSSID. */ +static int +iwm_allow_mcast(struct iwm_softc *sc) +{ + struct ieee80211com *ic = sc-sc_ic; + struct ieee80211_node *ni = ic-ic_bss; + struct iwm_mcast_filter_cmd *cmd; + size_t size; + int error; + + size = roundup(sizeof(*cmd), 4); + cmd = kmem_intr_zalloc(size, KM_NOSLEEP); + if (cmd == NULL) + return ENOMEM; + cmd-filter_own = 1; + cmd-port_id = 0; + cmd-count = 0; + cmd-pass_all = 1; + IEEE80211_ADDR_COPY(cmd-bssid, ni-ni_bssid); + + error = iwm_mvm_send_cmd_pdu(sc, IWM_MCAST_FILTER_CMD, + IWM_CMD_SYNC, size, cmd); + kmem_intr_free(cmd, size); + return error; +} + /* * ifnet interfaces */ @@ -6259,6 +6290,9 @@ iwm_notif_intr(struct iwm_softc *sc) wakeup(sc-sc_auth_prot); break; } + case IWM_MCAST_FILTER_CMD: + break; + default: aprint_error_dev(sc-sc_dev, frame %d/%d %x UNHANDLED (this should
CVS commit: src/sys/ufs/ext2fs
Module Name:src Committed By: maxv Date: Fri Feb 20 17:44:54 UTC 2015 Modified Files: src/sys/ufs/ext2fs: ext2fs_vfsops.c Log Message: Several fixes: - rename ext2fs_checksb() - ext2fs_sbcheck(): more consistent - in ext2fs_sbcheck(), add a check to ensure e2fs_inode_size!=0, otherwise division by zero - add ext2fs_sbcompute(), to compute dynamic values of the superblock. It is done twice in _reload() and _mountfs(), so put it in a function. - reorder the code in charge of loading the superblock: now, read the superblock, swap it directly, and *then* pass it to ext2fs_sbcheck(). It is similar to what ffs now does. It is better since the fields don't need to be swapped on the fly in ext2fs_sbcheck(). Tested on amd64. To generate a diff of this commit: cvs rdiff -u -r1.187 -r1.188 src/sys/ufs/ext2fs/ext2fs_vfsops.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/ufs/ext2fs/ext2fs_vfsops.c diff -u src/sys/ufs/ext2fs/ext2fs_vfsops.c:1.187 src/sys/ufs/ext2fs/ext2fs_vfsops.c:1.188 --- src/sys/ufs/ext2fs/ext2fs_vfsops.c:1.187 Thu Feb 19 21:31:44 2015 +++ src/sys/ufs/ext2fs/ext2fs_vfsops.c Fri Feb 20 17:44:54 2015 @@ -1,4 +1,4 @@ -/* $NetBSD: ext2fs_vfsops.c,v 1.187 2015/02/19 21:31:44 maxv Exp $ */ +/* $NetBSD: ext2fs_vfsops.c,v 1.188 2015/02/20 17:44:54 maxv Exp $ */ /* * Copyright (c) 1989, 1991, 1993, 1994 @@ -60,7 +60,7 @@ */ #include sys/cdefs.h -__KERNEL_RCSID(0, $NetBSD: ext2fs_vfsops.c,v 1.187 2015/02/19 21:31:44 maxv Exp $); +__KERNEL_RCSID(0, $NetBSD: ext2fs_vfsops.c,v 1.188 2015/02/20 17:44:54 maxv Exp $); #if defined(_KERNEL_OPT) #include opt_compat_netbsd.h @@ -104,7 +104,8 @@ __KERNEL_RCSID(0, $NetBSD: ext2fs_vfsop MODULE(MODULE_CLASS_VFS, ext2fs, ffs); int ext2fs_sbupdate(struct ufsmount *, int); -static int ext2fs_checksb(struct ext2fs *, int); +static void ext2fs_sbcompute(struct m_ext2fs *); +static int ext2fs_sbcheck(struct ext2fs *, int); static struct sysctllog *ext2fs_sysctl_log; @@ -534,43 +535,28 @@ ext2fs_reload(struct mount *mp, kauth_cr VOP_UNLOCK(devvp); if (error) panic(ext2fs_reload: dirty1); - /* - * Step 2: re-read superblock from disk. - */ - error = bread(devvp, SBLOCK, SBSIZE, NOCRED, 0, bp); - if (error) { - return (error); - } - newfs = (struct ext2fs *)bp-b_data; - error = ext2fs_checksb(newfs, (mp-mnt_flag MNT_RDONLY) != 0); - if (error) { - brelse(bp, 0); - return (error); - } fs = ump-um_e2fs; /* - * copy in new superblock, and compute in-memory values + * Step 2: re-read superblock from disk. Copy in new superblock, and compute + * in-memory values. */ + error = bread(devvp, SBLOCK, SBSIZE, NOCRED, 0, bp); + if (error) + return error; + newfs = (struct ext2fs *)bp-b_data; e2fs_sbload(newfs, fs-e2fs); - fs-e2fs_ncg = - howmany(fs-e2fs.e2fs_bcount - fs-e2fs.e2fs_first_dblock, - fs-e2fs.e2fs_bpg); - fs-e2fs_fsbtodb = fs-e2fs.e2fs_log_bsize + LOG_MINBSIZE - DEV_BSHIFT; - fs-e2fs_bsize = MINBSIZE fs-e2fs.e2fs_log_bsize; - fs-e2fs_bshift = LOG_MINBSIZE + fs-e2fs.e2fs_log_bsize; - fs-e2fs_qbmask = fs-e2fs_bsize - 1; - fs-e2fs_bmask = ~fs-e2fs_qbmask; - fs-e2fs_ngdb = - howmany(fs-e2fs_ncg, fs-e2fs_bsize / sizeof(struct ext2_gd)); - fs-e2fs_ipb = fs-e2fs_bsize / EXT2_DINODE_SIZE(fs); - fs-e2fs_itpg = fs-e2fs.e2fs_ipg / fs-e2fs_ipb; + brelse(bp, 0); + error = ext2fs_sbcheck(fs-e2fs, (mp-mnt_flag MNT_RDONLY) != 0); + if (error) + return error; + ext2fs_sbcompute(fs); + /* * Step 3: re-read summary information from disk. */ - for (i = 0; i fs-e2fs_ngdb; i++) { error = bread(devvp , EXT2_FSBTODB(fs, fs-e2fs.e2fs_first_dblock + @@ -652,29 +638,30 @@ ext2fs_mountfs(struct vnode *devvp, stru bp = NULL; ump = NULL; -#ifdef DEBUG_EXT2 - printf(ext2 sb size: %zu\n, sizeof(struct ext2fs)); -#endif + /* Read the superblock from disk, and swap it directly. */ error = bread(devvp, SBLOCK, SBSIZE, cred, 0, bp); if (error) goto out; fs = (struct ext2fs *)bp-b_data; - error = ext2fs_checksb(fs, ronly); - if (error) + m_fs = kmem_zalloc(sizeof(struct m_ext2fs), KM_SLEEP); + e2fs_sbload(fs, m_fs-e2fs); + + brelse(bp, 0); + bp = NULL; + + /* Once swapped, validate the superblock. */ + error = ext2fs_sbcheck(m_fs-e2fs, ronly); + if (error) { + kmem_free(m_fs, sizeof(struct m_ext2fs)); goto out; + } + m_fs-e2fs_ronly = ronly; + ump = kmem_zalloc(sizeof(*ump), KM_SLEEP); ump-um_fstype = UFS1; ump-um_ops = ext2fs_ufsops; - ump-um_e2fs = kmem_zalloc(sizeof(struct m_ext2fs), KM_SLEEP); - e2fs_sbload((struct ext2fs *)bp-b_data, ump-um_e2fs-e2fs); - brelse(bp, 0); - bp = NULL; - m_fs = ump-um_e2fs; - m_fs-e2fs_ronly = ronly; + ump-um_e2fs = m_fs; -#ifdef DEBUG_EXT2 - printf(ext2 ino size %zu\n, EXT2_DINODE_SIZE(m_fs)); -#endif if (ronly == 0) { if (m_fs-e2fs.e2fs_state == E2FS_ISCLEAN) m_fs-e2fs.e2fs_state = 0; @@ -683,23 +670,12 @@
CVS commit: src/sys/fs/ntfs
Module Name:src Committed By: maxv Date: Fri Feb 20 17:08:13 UTC 2015 Modified Files: src/sys/fs/ntfs: ntfs_compr.c ntfs_conv.c ntfs_ihash.c ntfs_subr.c ntfs_vfsops.c Log Message: Cosmetic changes: - add a ffs-like ntfs_superblock_validate function - remove unused includes - fix some comments - KNF No functional change. To generate a diff of this commit: cvs rdiff -u -r1.5 -r1.6 src/sys/fs/ntfs/ntfs_compr.c cvs rdiff -u -r1.9 -r1.10 src/sys/fs/ntfs/ntfs_conv.c cvs rdiff -u -r1.10 -r1.11 src/sys/fs/ntfs/ntfs_ihash.c cvs rdiff -u -r1.59 -r1.60 src/sys/fs/ntfs/ntfs_subr.c cvs rdiff -u -r1.102 -r1.103 src/sys/fs/ntfs/ntfs_vfsops.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/fs/ntfs/ntfs_compr.c diff -u src/sys/fs/ntfs/ntfs_compr.c:1.5 src/sys/fs/ntfs/ntfs_compr.c:1.6 --- src/sys/fs/ntfs/ntfs_compr.c:1.5 Wed Mar 18 16:00:21 2009 +++ src/sys/fs/ntfs/ntfs_compr.c Fri Feb 20 17:08:13 2015 @@ -1,4 +1,4 @@ -/* $NetBSD: ntfs_compr.c,v 1.5 2009/03/18 16:00:21 cegger Exp $ */ +/* $NetBSD: ntfs_compr.c,v 1.6 2015/02/20 17:08:13 maxv Exp $ */ /*- * Copyright (c) 1998, 1999 Semen Ustimenko @@ -29,36 +29,29 @@ */ #include sys/cdefs.h -__KERNEL_RCSID(0, $NetBSD: ntfs_compr.c,v 1.5 2009/03/18 16:00:21 cegger Exp $); +__KERNEL_RCSID(0, $NetBSD: ntfs_compr.c,v 1.6 2015/02/20 17:08:13 maxv Exp $); #include sys/param.h #include sys/systm.h #include sys/namei.h -#include sys/proc.h #include sys/kernel.h #include sys/vnode.h #include sys/mount.h -#include sys/buf.h -#include sys/file.h #include sys/malloc.h -#include miscfs/specfs/specdev.h - #include fs/ntfs/ntfs.h #include fs/ntfs/ntfs_compr.h #define GET_UINT16(addr) (*((u_int16_t *)(addr))) int -ntfs_uncompblock( - u_int8_t * dbuf, - u_int8_t * cbuf) +ntfs_uncompblock(u_int8_t *dbuf, u_int8_t *cbuf) { - u_int32_t ctag; - int len, dshift, lmask; - int blen, boff; - int i, j; - int pos, cpos; + u_int32_t ctag; + int len, dshift, lmask; + int blen, boff; + int i, j; + int pos, cpos; len = GET_UINT16(cbuf) 0xFFF; dprintf((ntfs_uncompblock: block length: %d + 3, 0x%x,0x%04x\n, @@ -101,14 +94,11 @@ ntfs_uncompblock( } int -ntfs_uncompunit( - struct ntfsmount * ntmp, - u_int8_t * uup, - u_int8_t * cup) +ntfs_uncompunit(struct ntfsmount *ntmp, u_int8_t *uup, u_int8_t *cup) { - int i; - int off = 0; - int new; + int i; + int off = 0; + int new; for (i = 0; i * NTFS_COMPBLOCK_SIZE ntfs_cntob(NTFS_COMPUNIT_CL); i++) { new = ntfs_uncompblock(uup + i * NTFS_COMPBLOCK_SIZE, cup + off); Index: src/sys/fs/ntfs/ntfs_conv.c diff -u src/sys/fs/ntfs/ntfs_conv.c:1.9 src/sys/fs/ntfs/ntfs_conv.c:1.10 --- src/sys/fs/ntfs/ntfs_conv.c:1.9 Mon Apr 28 20:24:02 2008 +++ src/sys/fs/ntfs/ntfs_conv.c Fri Feb 20 17:08:13 2015 @@ -1,4 +1,4 @@ -/* $NetBSD: ntfs_conv.c,v 1.9 2008/04/28 20:24:02 martin Exp $ */ +/* $NetBSD: ntfs_conv.c,v 1.10 2015/02/20 17:08:13 maxv Exp $ */ /*- * Copyright (c) 2001 The NetBSD Foundation, Inc. @@ -31,29 +31,18 @@ */ #include sys/cdefs.h -__KERNEL_RCSID(0, $NetBSD: ntfs_conv.c,v 1.9 2008/04/28 20:24:02 martin Exp $); +__KERNEL_RCSID(0, $NetBSD: ntfs_conv.c,v 1.10 2015/02/20 17:08:13 maxv Exp $); #include sys/param.h #include sys/systm.h #include sys/namei.h -#include sys/proc.h #include sys/kernel.h -#include sys/vnode.h #include sys/mount.h -#include sys/buf.h -#include sys/file.h #include sys/malloc.h -#include sys/lock.h - -#include miscfs/specfs/specdev.h #include fs/ntfs/ntfs.h -#include fs/ntfs/ntfsmount.h #include fs/ntfs/ntfs_inode.h -#include fs/ntfs/ntfs_vfsops.h #include fs/ntfs/ntfs_subr.h -#include fs/ntfs/ntfs_compr.h -#include fs/ntfs/ntfs_ihash.h /* UTF-8 encoding stuff */ #include fs/unicode.h Index: src/sys/fs/ntfs/ntfs_ihash.c diff -u src/sys/fs/ntfs/ntfs_ihash.c:1.10 src/sys/fs/ntfs/ntfs_ihash.c:1.11 --- src/sys/fs/ntfs/ntfs_ihash.c:1.10 Fri Jan 27 19:48:40 2012 +++ src/sys/fs/ntfs/ntfs_ihash.c Fri Feb 20 17:08:13 2015 @@ -1,4 +1,4 @@ -/* $NetBSD: ntfs_ihash.c,v 1.10 2012/01/27 19:48:40 para Exp $ */ +/* $NetBSD: ntfs_ihash.c,v 1.11 2015/02/20 17:08:13 maxv Exp $ */ /* * Copyright (c) 1982, 1986, 1989, 1991, 1993, 1995 @@ -33,14 +33,13 @@ */ #include sys/cdefs.h -__KERNEL_RCSID(0, $NetBSD: ntfs_ihash.c,v 1.10 2012/01/27 19:48:40 para Exp $); +__KERNEL_RCSID(0, $NetBSD: ntfs_ihash.c,v 1.11 2015/02/20 17:08:13 maxv Exp $); #include sys/param.h #include sys/systm.h #include sys/kernel.h #include sys/lock.h #include sys/vnode.h -#include sys/proc.h #include sys/mount.h #include sys/mallocvar.h Index: src/sys/fs/ntfs/ntfs_subr.c diff -u src/sys/fs/ntfs/ntfs_subr.c:1.59 src/sys/fs/ntfs/ntfs_subr.c:1.60 --- src/sys/fs/ntfs/ntfs_subr.c:1.59 Fri Jan 16 17:02:12 2015 +++ src/sys/fs/ntfs/ntfs_subr.c Fri Feb 20 17:08:13 2015 @@ -1,4 +1,4 @@
CVS commit: src/sys/ufs/ffs
Module Name:src Committed By: maxv Date: Fri Feb 20 17:10:17 UTC 2015 Modified Files: src/sys/ufs/ffs: ffs_vfsops.c Log Message: Style, and fix a DPRINTF No functional change To generate a diff of this commit: cvs rdiff -u -r1.316 -r1.317 src/sys/ufs/ffs/ffs_vfsops.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/ufs/ffs/ffs_vfsops.c diff -u src/sys/ufs/ffs/ffs_vfsops.c:1.316 src/sys/ufs/ffs/ffs_vfsops.c:1.317 --- src/sys/ufs/ffs/ffs_vfsops.c:1.316 Sat Feb 14 13:43:28 2015 +++ src/sys/ufs/ffs/ffs_vfsops.c Fri Feb 20 17:10:17 2015 @@ -1,4 +1,4 @@ -/* $NetBSD: ffs_vfsops.c,v 1.316 2015/02/14 13:43:28 maxv Exp $ */ +/* $NetBSD: ffs_vfsops.c,v 1.317 2015/02/20 17:10:17 maxv Exp $ */ /*- * Copyright (c) 2008, 2009 The NetBSD Foundation, Inc. @@ -61,7 +61,7 @@ */ #include sys/cdefs.h -__KERNEL_RCSID(0, $NetBSD: ffs_vfsops.c,v 1.316 2015/02/14 13:43:28 maxv Exp $); +__KERNEL_RCSID(0, $NetBSD: ffs_vfsops.c,v 1.317 2015/02/20 17:10:17 maxv Exp $); #if defined(_KERNEL_OPT) #include opt_ffs.h @@ -111,11 +111,8 @@ __KERNEL_RCSID(0, $NetBSD: ffs_vfsops.c MODULE(MODULE_CLASS_VFS, ffs, NULL); -static int -ffs_vfs_fsync(vnode_t *, int); - -static int -ffs_superblock_validate(struct fs *fs); +static int ffs_vfs_fsync(vnode_t *, int); +static int ffs_superblock_validate(struct fs *); static struct sysctllog *ffs_sysctl_log; @@ -1039,7 +1036,7 @@ ffs_mountfs(struct vnode *devvp, struct bp = NULL; } if (sblock_try[i] == -1) { - DPRINTF((%s: sblock_try\n, __func__)); + DPRINTF((%s: no superblock found\n, __func__)); error = EINVAL; fs = NULL; goto out;
CVS commit: src/distrib/sets/lists/modules
Module Name:src Committed By: ozaki-r Date: Sat Feb 21 07:36:59 UTC 2015 Modified Files: src/distrib/sets/lists/modules: md.i386 Log Message: Add missing tags (zfs, solaris and lvm) to md.i386 To generate a diff of this commit: cvs rdiff -u -r1.52 -r1.53 src/distrib/sets/lists/modules/md.i386 Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/distrib/sets/lists/modules/md.i386 diff -u src/distrib/sets/lists/modules/md.i386:1.52 src/distrib/sets/lists/modules/md.i386:1.53 --- src/distrib/sets/lists/modules/md.i386:1.52 Sun Nov 16 18:33:19 2014 +++ src/distrib/sets/lists/modules/md.i386 Sat Feb 21 07:36:59 2015 @@ -1,4 +1,4 @@ -# $NetBSD: md.i386,v 1.52 2014/11/16 18:33:19 riastradh Exp $ +# $NetBSD: md.i386,v 1.53 2015/02/21 07:36:59 ozaki-r Exp $ # # NOTE that there are three sets of files here: # @MODULEDIR@, i386-xen, and i386pae-xen @@ -284,8 +284,8 @@ ./stand/i386-xen/@OSRELEASE@/modules/des/des.kmod base-kernel-modules kmod,compatmodules ./stand/i386-xen/@OSRELEASE@/modules/dk_subrbase-kernel-modules kmod,compatmodules ./stand/i386-xen/@OSRELEASE@/modules/dk_subr/dk_subr.kmod base-kernel-modules kmod,compatmodules -./stand/i386-xen/@OSRELEASE@/modules/dm base-kernel-modules kmod,compatmodules -./stand/i386-xen/@OSRELEASE@/modules/dm/dm.kmodbase-kernel-modules kmod,compatmodules +./stand/i386-xen/@OSRELEASE@/modules/dm base-kernel-modules kmod,compatmodules,lvm +./stand/i386-xen/@OSRELEASE@/modules/dm/dm.kmodbase-kernel-modules kmod,compatmodules,lvm ./stand/i386-xen/@OSRELEASE@/modules/drmbase-kernel-modules kmod,compatmodules ./stand/i386-xen/@OSRELEASE@/modules/drm/drm.kmod base-kernel-modules kmod,compatmodules ./stand/i386-xen/@OSRELEASE@/modules/drmkmsbase-kernel-modules kmod,compatmodules @@ -496,8 +496,8 @@ ./stand/i386-xen/@OSRELEASE@/modules/sljit/sljit.kmod base-kernel-modules kmod,compatmodules ./stand/i386-xen/@OSRELEASE@/modules/smbfsbase-kernel-modules kmod,compatmodules ./stand/i386-xen/@OSRELEASE@/modules/smbfs/smbfs.kmod base-kernel-modules kmod,compatmodules -./stand/i386-xen/@OSRELEASE@/modules/solarisbase-kernel-modules kmod,compatmodules -./stand/i386-xen/@OSRELEASE@/modules/solaris/solaris.kmod base-kernel-modules kmod,compatmodules +./stand/i386-xen/@OSRELEASE@/modules/solarisbase-kernel-modules kmod,compatmodules,solaris +./stand/i386-xen/@OSRELEASE@/modules/solaris/solaris.kmod base-kernel-modules kmod,compatmodules,solaris ./stand/i386-xen/@OSRELEASE@/modules/spdmembase-kernel-modules kmod,compatmodules ./stand/i386-xen/@OSRELEASE@/modules/spdmem/spdmem.kmod base-kernel-modules kmod,compatmodules ./stand/i386-xen/@OSRELEASE@/modules/suserbase-kernel-modules kmod,compatmodules @@ -562,8 +562,8 @@ ./stand/i386-xen/@OSRELEASE@/modules/xc3028/xc3028.kmod base-kernel-modules kmod,compatmodules ./stand/i386-xen/@OSRELEASE@/modules/xc5kbase-kernel-modules kmod,compatmodules ./stand/i386-xen/@OSRELEASE@/modules/xc5k/xc5k.kmod base-kernel-modules kmod,compatmodules -./stand/i386-xen/@OSRELEASE@/modules/zfsbase-kernel-modules kmod,compatmodules -./stand/i386-xen/@OSRELEASE@/modules/zfs/zfs.kmod base-kernel-modules kmod,compatmodules +./stand/i386-xen/@OSRELEASE@/modules/zfsbase-kernel-modules kmod,compatmodules,zfs +./stand/i386-xen/@OSRELEASE@/modules/zfs/zfs.kmod base-kernel-modules kmod,compatmodules,zfs ./stand/i386-xen/@OSRELEASE@/modules/zl10353base-kernel-modules kmod,compatmodules ./stand/i386-xen/@OSRELEASE@/modules/zl10353/zl10353.kmod base-kernel-modules kmod,compatmodules ./stand/i386-xen/@OSRELEASE@/modules/zlibbase-kernel-modules kmod,compatmodules @@ -673,8 +673,8 @@ ./stand/i386pae-xen/@OSRELEASE@/modules/des/des.kmod base-kernel-modules kmod,compatmodules ./stand/i386pae-xen/@OSRELEASE@/modules/dk_subrbase-kernel-modules kmod,compatmodules ./stand/i386pae-xen/@OSRELEASE@/modules/dk_subr/dk_subr.kmod base-kernel-modules kmod,compatmodules -./stand/i386pae-xen/@OSRELEASE@/modules/dmbase-kernel-modules kmod,compatmodules -./stand/i386pae-xen/@OSRELEASE@/modules/dm/dm.kmod base-kernel-modules kmod,compatmodules +./stand/i386pae-xen/@OSRELEASE@/modules/dmbase-kernel-modules kmod,compatmodules,lvm +./stand/i386pae-xen/@OSRELEASE@/modules/dm/dm.kmod base-kernel-modules kmod,compatmodules,lvm ./stand/i386pae-xen/@OSRELEASE@/modules/drmbase-kernel-modules kmod,compatmodules ./stand/i386pae-xen/@OSRELEASE@/modules/drm/drm.kmod base-kernel-modules kmod,compatmodules ./stand/i386pae-xen/@OSRELEASE@/modules/drmkmsbase-kernel-modules kmod,compatmodules @@ -885,8 +885,8 @@ ./stand/i386pae-xen/@OSRELEASE@/modules/sljit/sljit.kmod base-kernel-modules kmod,compatmodules ./stand/i386pae-xen/@OSRELEASE@/modules/smbfsbase-kernel-modules kmod,compatmodules ./stand/i386pae-xen/@OSRELEASE@/modules/smbfs/smbfs.kmod
CVS commit: src/sys/arch/sparc64/dev
Module Name:src Committed By: nakayama Date: Sat Feb 21 07:40:01 UTC 2015 Modified Files: src/sys/arch/sparc64/dev: lom.c Log Message: Fix queue handling to make the watchdog timer actually works on netbsd-7 if it is configured by wdogctl=YES in rc.conf, and also avoid a hangup duaring shutdown. - don't put an entry which is already in the queue. - read a first entry properly to handle the queue. - check the lom status if input buffer is empty before writing. To generate a diff of this commit: cvs rdiff -u -r1.13 -r1.14 src/sys/arch/sparc64/dev/lom.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/sys/arch/sparc64/dev/lom.c diff -u src/sys/arch/sparc64/dev/lom.c:1.13 src/sys/arch/sparc64/dev/lom.c:1.14 --- src/sys/arch/sparc64/dev/lom.c:1.13 Tue Feb 25 18:30:08 2014 +++ src/sys/arch/sparc64/dev/lom.c Sat Feb 21 07:40:01 2015 @@ -1,4 +1,4 @@ -/* $NetBSD: lom.c,v 1.13 2014/02/25 18:30:08 pooka Exp $ */ +/* $NetBSD: lom.c,v 1.14 2015/02/21 07:40:01 nakayama Exp $ */ /* $OpenBSD: lom.c,v 1.21 2010/02/28 20:44:39 kettenis Exp $ */ /* * Copyright (c) 2009 Mark Kettenis @@ -17,7 +17,7 @@ */ #include sys/cdefs.h -__KERNEL_RCSID(0, $NetBSD: lom.c,v 1.13 2014/02/25 18:30:08 pooka Exp $); +__KERNEL_RCSID(0, $NetBSD: lom.c,v 1.14 2015/02/21 07:40:01 nakayama Exp $); #include sys/param.h #include sys/device.h @@ -600,7 +600,15 @@ lom1_write_polled(struct lom_softc *sc, static void lom1_queue_cmd(struct lom_softc *sc, struct lom_cmd *lc) { + struct lom_cmd *lcp; + mutex_enter(sc-sc_queue_mtx); + TAILQ_FOREACH(lcp, sc-sc_queue, lc_next) { + if (lcp == lc) { + mutex_exit(sc-sc_queue_mtx); + return; + } + } TAILQ_INSERT_TAIL(sc-sc_queue, lc, lc_next); if (sc-sc_state == LOM_STATE_IDLE) { sc-sc_state = LOM_STATE_CMD; @@ -818,13 +826,21 @@ lom2_write_polled(struct lom_softc *sc, static void lom2_queue_cmd(struct lom_softc *sc, struct lom_cmd *lc) { + struct lom_cmd *lcp; uint8_t str; mutex_enter(sc-sc_queue_mtx); + TAILQ_FOREACH(lcp, sc-sc_queue, lc_next) { + if (lcp == lc) { + mutex_exit(sc-sc_queue_mtx); + return; + } + } TAILQ_INSERT_TAIL(sc-sc_queue, lc, lc_next); if (sc-sc_state == LOM_STATE_IDLE) { str = bus_space_read_1(sc-sc_iot, sc-sc_ioh, LOM2_STATUS); if ((str LOM2_STATUS_IBF) == 0) { + lc = TAILQ_FIRST(sc-sc_queue); bus_space_write_1(sc-sc_iot, sc-sc_ioh, LOM2_CMD, lc-lc_cmd); sc-sc_state = LOM_STATE_DATA; @@ -852,9 +868,11 @@ lom2_intr(void *arg) } if (lc-lc_cmd LOM_IDX_WRITE) { - bus_space_write_1(sc-sc_iot, sc-sc_ioh, - LOM2_DATA, lc-lc_data); - lc-lc_cmd = ~LOM_IDX_WRITE; + if ((str LOM2_STATUS_IBF) == 0) { + bus_space_write_1(sc-sc_iot, sc-sc_ioh, + LOM2_DATA, lc-lc_data); + lc-lc_cmd = ~LOM_IDX_WRITE; + } mutex_exit(sc-sc_queue_mtx); return (1); } @@ -871,6 +889,7 @@ lom2_intr(void *arg) if (!TAILQ_EMPTY(sc-sc_queue)) { str = bus_space_read_1(sc-sc_iot, sc-sc_ioh, LOM2_STATUS); if ((str LOM2_STATUS_IBF) == 0) { + lc = TAILQ_FIRST(sc-sc_queue); bus_space_write_1(sc-sc_iot, sc-sc_ioh, LOM2_CMD, lc-lc_cmd); sc-sc_state = LOM_STATE_DATA;
CVS commit: src/distrib/sets/lists/modules
Module Name:src Committed By: ozaki-r Date: Sat Feb 21 07:47:41 UTC 2015 Modified Files: src/distrib/sets/lists/modules: md.i386 Log Message: Add missing dtrace modules to md.i386 set list To generate a diff of this commit: cvs rdiff -u -r1.53 -r1.54 src/distrib/sets/lists/modules/md.i386 Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. Modified files: Index: src/distrib/sets/lists/modules/md.i386 diff -u src/distrib/sets/lists/modules/md.i386:1.53 src/distrib/sets/lists/modules/md.i386:1.54 --- src/distrib/sets/lists/modules/md.i386:1.53 Sat Feb 21 07:36:59 2015 +++ src/distrib/sets/lists/modules/md.i386 Sat Feb 21 07:47:41 2015 @@ -1,4 +1,4 @@ -# $NetBSD: md.i386,v 1.53 2015/02/21 07:36:59 ozaki-r Exp $ +# $NetBSD: md.i386,v 1.54 2015/02/21 07:47:41 ozaki-r Exp $ # # NOTE that there are three sets of files here: # @MODULEDIR@, i386-xen, and i386pae-xen @@ -278,6 +278,8 @@ ./stand/i386-xen/@OSRELEASE@/modules/cx24227/cx24227.kmod base-kernel-modules kmod,compatmodules ./stand/i386-xen/@OSRELEASE@/modules/cxdtvbase-kernel-modules kmod,compatmodules ./stand/i386-xen/@OSRELEASE@/modules/cxdtv/cxdtv.kmod base-kernel-modules kmod,compatmodules +./stand/i386-xen/@OSRELEASE@/modules/cyclicbase-kernel-modules kmod,dtrace,compatmodules +./stand/i386-xen/@OSRELEASE@/modules/cyclic/cyclic.kmod base-kernel-modules kmod,dtrace,compatmodules ./stand/i386-xen/@OSRELEASE@/modules/dbcoolbase-kernel-modules kmod,compatmodules ./stand/i386-xen/@OSRELEASE@/modules/dbcool/dbcool.kmod base-kernel-modules kmod,compatmodules ./stand/i386-xen/@OSRELEASE@/modules/desbase-kernel-modules kmod,compatmodules @@ -294,6 +296,14 @@ ./stand/i386-xen/@OSRELEASE@/modules/drmkms_linux/drmkms_linux.kmod base-kernel-modules kmod,compatmodules ./stand/i386-xen/@OSRELEASE@/modules/drmkms_pcibase-kernel-modules kmod,compatmodules ./stand/i386-xen/@OSRELEASE@/modules/drmkms_pci/drmkms_pci.kmod base-kernel-modules kmod,compatmodules +./stand/i386-xen/@OSRELEASE@/modules/dtracebase-kernel-modules kmod,dtrace,compatmodules +./stand/i386-xen/@OSRELEASE@/modules/dtrace/dtrace.kmod base-kernel-modules kmod,dtrace,compatmodules +./stand/i386-xen/@OSRELEASE@/modules/dtrace_fbtbase-kernel-modules kmod,dtrace,compatmodules +./stand/i386-xen/@OSRELEASE@/modules/dtrace_fbt/dtrace_fbt.kmod base-kernel-modules kmod,dtrace,compatmodules +./stand/i386-xen/@OSRELEASE@/modules/dtrace_profile base-kernel-modules kmod,dtrace,compatmodules +./stand/i386-xen/@OSRELEASE@/modules/dtrace_profile/dtrace_profile.kmod base-kernel-modules kmod,dtrace,compatmodules +./stand/i386-xen/@OSRELEASE@/modules/dtrace_sdtbase-kernel-modules kmod,dtrace,compatmodules +./stand/i386-xen/@OSRELEASE@/modules/dtrace_sdt/dtrace_sdt.kmod base-kernel-modules kmod,dtrace,compatmodules ./stand/i386-xen/@OSRELEASE@/modules/dtvbase-kernel-modules kmod,compatmodules ./stand/i386-xen/@OSRELEASE@/modules/dtv/dtv.kmod base-kernel-modules kmod,compatmodules ./stand/i386-xen/@OSRELEASE@/modules/dtv_mathbase-kernel-modules kmod,compatmodules @@ -667,6 +677,8 @@ ./stand/i386pae-xen/@OSRELEASE@/modules/cx24227/cx24227.kmod base-kernel-modules kmod,compatmodules ./stand/i386pae-xen/@OSRELEASE@/modules/cxdtvbase-kernel-modules kmod,compatmodules ./stand/i386pae-xen/@OSRELEASE@/modules/cxdtv/cxdtv.kmod base-kernel-modules kmod,compatmodules +./stand/i386pae-xen/@OSRELEASE@/modules/cyclicbase-kernel-modules kmod,dtrace,compatmodules +./stand/i386pae-xen/@OSRELEASE@/modules/cyclic/cyclic.kmod base-kernel-modules kmod,dtrace,compatmodules ./stand/i386pae-xen/@OSRELEASE@/modules/dbcoolbase-kernel-modules kmod,compatmodules ./stand/i386pae-xen/@OSRELEASE@/modules/dbcool/dbcool.kmod base-kernel-modules kmod,compatmodules ./stand/i386pae-xen/@OSRELEASE@/modules/desbase-kernel-modules kmod,compatmodules @@ -683,6 +695,14 @@ ./stand/i386pae-xen/@OSRELEASE@/modules/drmkms_linux/drmkms_linux.kmod base-kernel-modules kmod,compatmodules ./stand/i386pae-xen/@OSRELEASE@/modules/drmkms_pci base-kernel-modules kmod,compatmodules ./stand/i386pae-xen/@OSRELEASE@/modules/drmkms_pci/drmkms_pci.kmod base-kernel-modules kmod,compatmodules +./stand/i386pae-xen/@OSRELEASE@/modules/dtracebase-kernel-modules kmod,dtrace,compatmodules +./stand/i386pae-xen/@OSRELEASE@/modules/dtrace/dtrace.kmod base-kernel-modules kmod,dtrace,compatmodules +./stand/i386pae-xen/@OSRELEASE@/modules/dtrace_fbt base-kernel-modules kmod,dtrace,compatmodules +./stand/i386pae-xen/@OSRELEASE@/modules/dtrace_fbt/dtrace_fbt.kmod base-kernel-modules kmod,dtrace,compatmodules +./stand/i386pae-xen/@OSRELEASE@/modules/dtrace_profilebase-kernel-modules kmod,dtrace,compatmodules +./stand/i386pae-xen/@OSRELEASE@/modules/dtrace_profile/dtrace_profile.kmod base-kernel-modules kmod,dtrace,compatmodules +./stand/i386pae-xen/@OSRELEASE@/modules/dtrace_sdt