svn commit: r227448 - head/share/man/man4
Author: brueffer Date: Fri Nov 11 12:06:09 2011 New Revision: 227448 URL: http://svn.freebsd.org/changeset/base/227448 Log: Reword a sentence in the HARDWARE section a little to make it more suitable for automatic hardware notes generation. MFC after:3 days Modified: head/share/man/man4/mps.4 Modified: head/share/man/man4/mps.4 == --- head/share/man/man4/mps.4 Fri Nov 11 07:17:00 2011(r227447) +++ head/share/man/man4/mps.4 Fri Nov 11 12:06:09 2011(r227448) @@ -60,9 +60,9 @@ driver provides support for LSI Logic Fu .Tn SAS controllers. .Sh HARDWARE -The following controllers are supported by the +The .Nm -driver +driver supports the following controllers: .Pp .Bl -bullet -compact .It ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
svn commit: r227449 - head/sys/netinet6
Author: trociny Date: Fri Nov 11 14:09:09 2011 New Revision: 227449 URL: http://svn.freebsd.org/changeset/base/227449 Log: Fix false positive EADDRINUSE that could be returned by bind, due to the typo made in r227207. Reported by: kib Tested by:kib Modified: head/sys/netinet6/in6_pcb.c Modified: head/sys/netinet6/in6_pcb.c == --- head/sys/netinet6/in6_pcb.c Fri Nov 11 12:06:09 2011(r227448) +++ head/sys/netinet6/in6_pcb.c Fri Nov 11 14:09:09 2011(r227449) @@ -270,7 +270,7 @@ in6_pcbbind(register struct inpcb *inp, } else if (t (reuseport == 0 || (t-inp_flags2 INP_REUSEPORT) == 0) (ntohl(t-inp_laddr.s_addr) != INADDR_ANY || - (t-inp_vflag INP_IPV6PROTO) == 0)) + (t-inp_vflag INP_IPV6PROTO) != 0)) return (EADDRINUSE); } #endif ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
Re: svn commit: r226572 - stable/9/sys/netinet
On Thu, Oct 20, 2011 at 12:40 PM, Bjoern A. Zeeb b...@freebsd.org wrote: On 20. Oct 2011, at 15:58 , Gleb Smirnoff wrote: Author: glebius Date: Thu Oct 20 15:58:05 2011 New Revision: 226572 URL: http://svn.freebsd.org/changeset/base/226572 Log: MFhead 226401,226402: Remove last remnants of classful addressing: - Remove ia_net, ia_netmask, ia_netbroadcast from struct in_ifaddr. - Remove net.inet.ip.subnetsarelocal, I bet no one need it in 2011. - fix bug when we were not forwarding to a host which matches classful net address. For example router having 192.168.x.y/16 network attached, would not forward traffic to 192.168.*.0, which are legal IPs in CIDR world. - For compatibility, leave autoguessing of mask based on class. Reviewed by: andre, bz, rwatson Add support for IPv4 /31 prefixes, as described in RFC3021. To run a /31 network, participating hosts MUST drop support for directed broadcasts, and treat the first and last addresses on subnet as unicast. The broadcast address for the prefix should be the link local broadcast address, INADDR_BROADCAST. ... Modified: stable/9/sys/netinet/in_var.h == --- stable/9/sys/netinet/in_var.h Thu Oct 20 15:55:01 2011 (r226571) +++ stable/9/sys/netinet/in_var.h Thu Oct 20 15:58:05 2011 (r226572) @@ -60,12 +60,9 @@ struct in_ifaddr { struct ifaddr ia_ifa; /* protocol-independent info */ #define ia_ifp ia_ifa.ifa_ifp #define ia_flags ia_ifa.ifa_flags - /* ia_{,sub}net{,mask} in host order */ - u_long ia_net; /* network number of interface */ - u_long ia_netmask; /* mask of net part */ - u_long ia_subnet; /* subnet number, including net */ - u_long ia_subnetmask; /* mask of subnet part */ - struct in_addr ia_netbroadcast; /* to recognize net broadcasts */ + /* ia_subnet{,mask} in host order */ + u_long ia_subnet; /* subnet address */ + u_long ia_subnetmask; /* mask of subnet */ LIST_ENTRY(in_ifaddr) ia_hash; /* entry in bucket of inet addresses */ TAILQ_ENTRY(in_ifaddr) ia_link; /* list of internet addresses */ struct sockaddr_in ia_addr; /* reserve space for interface name */ This should at least break parts of netstat and ifmcstat as I had told you in private email before. Just so we're clear, it changes the API (at the RC stage!), causing at least the net/openafs port to fail to compile. I presume, given the commit message, that I am just not supposed to use ia_net and ia_netmask any more, and that ia_submet and ia_subnetmask are presumed to be sufficient? -Ben Kaduk ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
svn commit: r227450 - stable/9/sys/netinet6
Author: trociny Date: Fri Nov 11 14:42:05 2011 New Revision: 227450 URL: http://svn.freebsd.org/changeset/base/227450 Log: MFC r227449: Fix false positive EADDRINUSE that could be returned by bind, due to the typo made in r227207. Reported by: kib Tested by:kib Approved by: re (kib) Modified: stable/9/sys/netinet6/in6_pcb.c Directory Properties: stable/9/sys/ (props changed) stable/9/sys/amd64/include/xen/ (props changed) stable/9/sys/boot/ (props changed) stable/9/sys/boot/i386/efi/ (props changed) stable/9/sys/boot/ia64/efi/ (props changed) stable/9/sys/boot/ia64/ski/ (props changed) stable/9/sys/boot/powerpc/boot1.chrp/ (props changed) stable/9/sys/boot/powerpc/ofw/ (props changed) stable/9/sys/cddl/contrib/opensolaris/ (props changed) stable/9/sys/conf/ (props changed) stable/9/sys/contrib/dev/acpica/ (props changed) stable/9/sys/contrib/octeon-sdk/ (props changed) stable/9/sys/contrib/pf/ (props changed) stable/9/sys/contrib/x86emu/ (props changed) Modified: stable/9/sys/netinet6/in6_pcb.c == --- stable/9/sys/netinet6/in6_pcb.c Fri Nov 11 14:09:09 2011 (r227449) +++ stable/9/sys/netinet6/in6_pcb.c Fri Nov 11 14:42:05 2011 (r227450) @@ -270,7 +270,7 @@ in6_pcbbind(register struct inpcb *inp, } else if (t (reuseport == 0 || (t-inp_flags2 INP_REUSEPORT) == 0) (ntohl(t-inp_laddr.s_addr) != INADDR_ANY || - (t-inp_vflag INP_IPV6PROTO) == 0)) + (t-inp_vflag INP_IPV6PROTO) != 0)) return (EADDRINUSE); } #endif ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
svn commit: r227451 - releng/9.0/sys/netinet6
Author: trociny Date: Fri Nov 11 15:24:17 2011 New Revision: 227451 URL: http://svn.freebsd.org/changeset/base/227451 Log: MFS r227450 (MFC r227449): Fix false positive EADDRINUSE that could be returned by bind, due to the typo made in r227207. Reported by: kib Tested by:kib Approved by: re (kib) Modified: releng/9.0/sys/netinet6/in6_pcb.c Directory Properties: releng/9.0/sys/ (props changed) releng/9.0/sys/amd64/include/xen/ (props changed) releng/9.0/sys/boot/ (props changed) releng/9.0/sys/boot/i386/efi/ (props changed) releng/9.0/sys/boot/ia64/efi/ (props changed) releng/9.0/sys/boot/ia64/ski/ (props changed) releng/9.0/sys/boot/powerpc/boot1.chrp/ (props changed) releng/9.0/sys/boot/powerpc/ofw/ (props changed) releng/9.0/sys/cddl/contrib/opensolaris/ (props changed) releng/9.0/sys/conf/ (props changed) releng/9.0/sys/contrib/dev/acpica/ (props changed) releng/9.0/sys/contrib/octeon-sdk/ (props changed) releng/9.0/sys/contrib/pf/ (props changed) releng/9.0/sys/contrib/x86emu/ (props changed) Modified: releng/9.0/sys/netinet6/in6_pcb.c == --- releng/9.0/sys/netinet6/in6_pcb.c Fri Nov 11 14:42:05 2011 (r227450) +++ releng/9.0/sys/netinet6/in6_pcb.c Fri Nov 11 15:24:17 2011 (r227451) @@ -270,7 +270,7 @@ in6_pcbbind(register struct inpcb *inp, } else if (t (reuseport == 0 || (t-inp_flags2 INP_REUSEPORT) == 0) (ntohl(t-inp_laddr.s_addr) != INADDR_ANY || - (t-inp_vflag INP_IPV6PROTO) == 0)) + (t-inp_vflag INP_IPV6PROTO) != 0)) return (EADDRINUSE); } #endif ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
svn commit: r227452 - head/sys/dev/ae
Author: yongari Date: Fri Nov 11 19:15:32 2011 New Revision: 227452 URL: http://svn.freebsd.org/changeset/base/227452 Log: To send a frame, controller requires a prepended TX header and the length of frame should be treated as multiple of 4. Actual frame length is set in the TX header. The TX header position should be aligned on 4 byte boundary and actual frame start position should be aligned on 4 byte boundary as well. This means we need 4(TX header length) + 3(frame length fixup) additional free space in TX buffer in addition to actual frame length. Make sure TX handler check these additional bytes. ae_tx_avail_size() returns actual free space in TX buffer to ease the calculation of available TX buffer space in caller. While I'm here, replace magic number to appropriate sizeof operator to enhance readability. This change should fix controller lockup issue happened under certain conditions but it still does not fix watchdog timeout. It seems the watchdog timeout is side-effect of TxS and TxD mismatches. The root cause of TxD/TxD mismatch is not known yet but it looks like silicon bug. I guess driver may have to reinitialize controller whenever it sees TxS and TxD mismatches but leave it as it was at this moment. PR: kern/145918 Modified: head/sys/dev/ae/if_ae.c Modified: head/sys/dev/ae/if_ae.c == --- head/sys/dev/ae/if_ae.c Fri Nov 11 15:24:17 2011(r227451) +++ head/sys/dev/ae/if_ae.c Fri Nov 11 19:15:32 2011(r227452) @@ -1431,7 +1431,7 @@ ae_tx_avail_size(ae_softc_t *sc) else avail = sc-txd_ack - sc-txd_cur; - return (avail - 4); /* 4-byte header. */ + return (avail); } static int @@ -1448,7 +1448,7 @@ ae_encap(ae_softc_t *sc, struct mbuf **m len = m0-m_pkthdr.len; if ((sc-flags AE_FLAG_TXAVAIL) == 0 || - ae_tx_avail_size(sc) len) { + len + sizeof(ae_txd_t) + 3 ae_tx_avail_size(sc)) { #ifdef AE_DEBUG if_printf(sc-ifp, No free Tx available.\n); #endif @@ -1457,11 +1457,10 @@ ae_encap(ae_softc_t *sc, struct mbuf **m hdr = (ae_txd_t *)(sc-txd_base + sc-txd_cur); bzero(hdr, sizeof(*hdr)); - sc-txd_cur = (sc-txd_cur + 4) % AE_TXD_BUFSIZE_DEFAULT; /* Header -size. */ - to_end = AE_TXD_BUFSIZE_DEFAULT - sc-txd_cur; /* Space available to - * the end of the ring - */ + /* Skip header size. */ + sc-txd_cur = (sc-txd_cur + sizeof(ae_txd_t)) % AE_TXD_BUFSIZE_DEFAULT; + /* Space available to the end of the ring */ + to_end = AE_TXD_BUFSIZE_DEFAULT - sc-txd_cur; if (to_end = len) { m_copydata(m0, 0, len, (caddr_t)(sc-txd_base + sc-txd_cur)); } else { @@ -1840,8 +1839,8 @@ ae_tx_intr(ae_softc_t *sc) /* * Move txd ack and align on 4-byte boundary. */ - sc-txd_ack = ((sc-txd_ack + le16toh(txd-len) + 4 + 3) ~3) % - AE_TXD_BUFSIZE_DEFAULT; + sc-txd_ack = ((sc-txd_ack + le16toh(txd-len) + + sizeof(ae_txs_t) + 3) ~3) % AE_TXD_BUFSIZE_DEFAULT; if ((flags AE_TXS_SUCCESS) != 0) ifp-if_opackets++; ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
svn commit: r227453 - head/share/misc
Author: theraven Date: Fri Nov 11 20:13:24 2011 New Revision: 227453 URL: http://svn.freebsd.org/changeset/base/227453 Log: Added myself to committers-src.dot Approved by: dim (mentor) Modified: head/share/misc/committers-src.dot Modified: head/share/misc/committers-src.dot == --- head/share/misc/committers-src.dot Fri Nov 11 19:15:32 2011 (r227452) +++ head/share/misc/committers-src.dot Fri Nov 11 20:13:24 2011 (r227453) @@ -238,6 +238,7 @@ stas [label=Stanislav Sedov\nstas@FreeB suz [label=SUZUKI Shinsuke\n...@freebsd.org\n2002/03/26] syrinx [label=Shteryana Shopova\nsyr...@freebsd.org\n2006/10/07] takawata [label=Takanori Watanabe\ntakaw...@freebsd.org\n2000/07/06] +theraven [label=David Chisnall\nthera...@freebsd.org\n2011/11/11] thompsa [label=Andrew Thompson\nthom...@freebsd.org\n2005/05/25] ticso [label=Bernd Walter\nti...@freebsd.org\n2002/01/31] tijl [label=Tijl Coosemans\nt...@freebsd.org\n2010/07/16] @@ -304,6 +305,7 @@ brian - joe brooks - bushman brooks - jamie +brooks - theraven bz - anchie bz - jamie @@ -333,6 +335,8 @@ dds - versus dfr - zml +dim - theraven + dwmalone - fanf dwmalone - peadar dwmalone - snb ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
svn commit: r227454 - head/sbin/newfs_msdos
Author: delphij Date: Fri Nov 11 20:31:48 2011 New Revision: 227454 URL: http://svn.freebsd.org/changeset/base/227454 Log: Use __packed to prevent alignment from taking place, which otherwise may change the on-disk format in an incompatible way. Without this change, msdosfs created on FreeBSD/arm would not be mountable. PR: bin/162486 Submitted by: Ian Lepore freebsd damnhippie dyndns org Reported by: Mattia Rossi mrossi at swin.edu.au MFC after:3 days Modified: head/sbin/newfs_msdos/newfs_msdos.c Modified: head/sbin/newfs_msdos/newfs_msdos.c == --- head/sbin/newfs_msdos/newfs_msdos.c Fri Nov 11 20:13:24 2011 (r227453) +++ head/sbin/newfs_msdos/newfs_msdos.c Fri Nov 11 20:31:48 2011 (r227454) @@ -99,7 +99,7 @@ static const char rcsid[] = struct bs { u_int8_t bsJump[3];/* bootstrap entry point */ u_int8_t bsOemName[8]; /* OEM name and version */ -}; +} __packed; struct bsbpb { u_int8_t bpbBytesPerSec[2];/* bytes per sector */ @@ -114,7 +114,7 @@ struct bsbpb { u_int8_t bpbHeads[2]; /* drive heads */ u_int8_t bpbHiddenSecs[4]; /* hidden sectors */ u_int8_t bpbHugeSectors[4];/* big total sectors */ -}; +} __packed; struct bsxbpb { u_int8_t bpbBigFATsecs[4]; /* big sectors per FAT */ @@ -124,7 +124,7 @@ struct bsxbpb { u_int8_t bpbFSInfo[2]; /* file system info sector */ u_int8_t bpbBackup[2]; /* backup boot sector */ u_int8_t bpbReserved[12]; /* reserved */ -}; +} __packed; struct bsx { u_int8_t exDriveNumber;/* drive number */ @@ -133,7 +133,7 @@ struct bsx { u_int8_t exVolumeID[4];/* volume ID number */ u_int8_t exVolumeLabel[11];/* volume label */ u_int8_t exFileSysType[8]; /* file system type */ -}; +} __packed; struct de { u_int8_t deName[11]; /* name and extension */ @@ -143,7 +143,7 @@ struct de { u_int8_t deMDate[2]; /* creation date */ u_int8_t deStartCluster[2];/* starting cluster */ u_int8_t deFileSize[4];/* size */ -}; +} __packed; struct bpb { u_int bpbBytesPerSec; /* bytes per sector */ ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
Re: svn commit: r227454 - head/sbin/newfs_msdos
On Fri, Nov 11, 2011 at 08:31:48PM +, Xin LI wrote: Author: delphij Date: Fri Nov 11 20:31:48 2011 New Revision: 227454 URL: http://svn.freebsd.org/changeset/base/227454 Log: Use __packed to prevent alignment from taking place, which otherwise may change the on-disk format in an incompatible way. Without this change, msdosfs created on FreeBSD/arm would not be mountable. PR: bin/162486 Submitted by: Ian Lepore freebsd damnhippie dyndns org Reported by:Mattia Rossi mrossi at swin.edu.au MFC after: 3 days I suspect there is much more places with the similar issues. FAT structure definitions were not centralized, AFAIR. pgpcp1w5iC2oR.pgp Description: PGP signature
svn commit: r227457 - head/sys/dev/puc
Author: eadler (ports committer) Date: Fri Nov 11 22:24:16 2011 New Revision: 227457 URL: http://svn.freebsd.org/changeset/base/227457 Log: - add support for CP-104EL-A and CP-104JU to puc PR: 151365 Submitted by: Joerg Niendorf f5d...@internode.on.net Approved by: jhb Modified: head/sys/dev/puc/pucdata.c Modified: head/sys/dev/puc/pucdata.c == --- head/sys/dev/puc/pucdata.c Fri Nov 11 21:57:31 2011(r227456) +++ head/sys/dev/puc/pucdata.c Fri Nov 11 22:24:16 2011(r227457) @@ -51,6 +51,7 @@ static puc_config_f puc_config_amc; static puc_config_f puc_config_diva; static puc_config_f puc_config_exar; static puc_config_f puc_config_icbook; +static puc_config_f puc_config_moxa; static puc_config_f puc_config_oxford_pcie; static puc_config_f puc_config_quatech; static puc_config_f puc_config_syba; @@ -518,12 +519,25 @@ const struct puc_cfg puc_pci_devices[] = PUC_PORT_4S, 0x18, 0, 8, }, + { 0x1393, 0x1042, 0x, 0, + Moxa Technologies, Smartio CP-104JU/PCI, + DEFAULT_RCLK * 8, + PUC_PORT_4S, 0x18, 0, 8, + }, + { 0x1393, 0x1043, 0x, 0, Moxa Technologies, Smartio CP-104EL/PCIe, DEFAULT_RCLK * 8, PUC_PORT_4S, 0x18, 0, 8, }, + { 0x1393, 0x1045, 0x, 0, + Moxa Technologies, Smartio CP-104EL-A/PCIe, + DEFAULT_RCLK * 8, + PUC_PORT_4S, 0x14, 0, -1, + .config_function = puc_config_moxa + }, + { 0x1393, 0x1120, 0x, 0, Moxa Technologies, CP-112UL, DEFAULT_RCLK * 8, @@ -1086,6 +1100,19 @@ puc_config_icbook(struct puc_softc *sc, } static int +puc_config_moxa(struct puc_softc *sc, enum puc_cfg_cmd cmd, int port, +intptr_t *res) +{ + const struct puc_cfg *cfg = sc-sc_cfg; + + if (cmd == PUC_CFG_GET_OFS cfg-device == 0x1045) { + *res = ((port == 3) ? 7 : port) * 0x200; + return 0; + } + return (ENXIO); +} + +static int puc_config_quatech(struct puc_softc *sc, enum puc_cfg_cmd cmd, int port, intptr_t *res) { ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
svn commit: r227458 - in head: secure/usr.bin/openssl/man sys/dev/isp sys/netinet/ipfw usr.bin/compress/doc usr.sbin/pkg_install/lib
Author: eadler (ports committer) Date: Fri Nov 11 22:27:09 2011 New Revision: 227458 URL: http://svn.freebsd.org/changeset/base/227458 Log: - add a missing be and in - fix other errors introduced when committing r226436 - add 'function' to a sentence where it makes sense Submitted by: delphij Submitted by: dougb Submitted by: jhb Approved by: dougb Approved by: jhb Modified: head/secure/usr.bin/openssl/man/ca.1 head/sys/dev/isp/DriverManual.txt head/sys/netinet/ipfw/dummynet.txt head/usr.bin/compress/doc/NOTES head/usr.sbin/pkg_install/lib/version.c Modified: head/secure/usr.bin/openssl/man/ca.1 == --- head/secure/usr.bin/openssl/man/ca.1Fri Nov 11 22:24:16 2011 (r227457) +++ head/secure/usr.bin/openssl/man/ca.1Fri Nov 11 22:27:09 2011 (r227458) @@ -205,7 +205,7 @@ section for information on the required .IP \fB\-infiles\fR 4 .IX Item -infiles if present this should be the last option, all subsequent arguments -are assumed to the names of files containing certificate requests. +are assumed to be the names of files containing certificate requests. .IP \fB\-out filename\fR 4 .IX Item -out filename the output file to output certificates to. The default is standard Modified: head/sys/dev/isp/DriverManual.txt == --- head/sys/dev/isp/DriverManual.txt Fri Nov 11 22:24:16 2011 (r227457) +++ head/sys/dev/isp/DriverManual.txt Fri Nov 11 22:27:09 2011 (r227458) @@ -327,7 +327,7 @@ here in clarifying some of this. A succesful execution of isp_init will lead to the driver 'registering' itself with this platform's SCSI subsystem. One assumed action for this -is the registry of a function the SCSI subsystem for this platform +is the registry of a function that the SCSI subsystem for this platform will call when it has a SCSI command to run. The platform specific module function that receives this will do whatever Modified: head/sys/netinet/ipfw/dummynet.txt == --- head/sys/netinet/ipfw/dummynet.txt Fri Nov 11 22:24:16 2011 (r227457) +++ head/sys/netinet/ipfw/dummynet.txt Fri Nov 11 22:27:09 2011 (r227458) @@ -325,7 +325,7 @@ we do the following: dummynet_task() === -The dummynet_task() is the main dummynet processing function and is +The dummynet_task() function is the main dummynet processing function and is called every tick. This function first calculate the new current time, then it checks if it is the time to wake up object from the system_heap comparing the current time and the key of the heap. Two types of object (really the Modified: head/usr.bin/compress/doc/NOTES == --- head/usr.bin/compress/doc/NOTES Fri Nov 11 22:24:16 2011 (r227457) +++ head/usr.bin/compress/doc/NOTES Fri Nov 11 22:27:09 2011 (r227458) @@ -51,7 +51,7 @@ comprehensive survey of an area which wi Until the dust clears, how you approach ideas which are patented depends on how paranoid you are of a legal onslaught. Arbitrary? Yes. But -the patent bar the CCPA (Court of Customs and Patent Appeals) +the patent bar of the CCPA (Court of Customs and Patent Appeals) thanks you for any uncertainty as they, at least, stand to gain from any trouble. Modified: head/usr.sbin/pkg_install/lib/version.c == --- head/usr.sbin/pkg_install/lib/version.c Fri Nov 11 22:24:16 2011 (r227457) +++ head/usr.sbin/pkg_install/lib/version.c Fri Nov 11 22:27:09 2011 (r227458) @@ -66,7 +66,7 @@ split_version(const char *pkgname, const if (pkgname == NULL) errx(2, %s: Passed NULL pkgname., __func__); -/* Look for the last '-' the pkgname */ +/* Look for the last '-' in the pkgname */ ch = strrchr(pkgname, '-'); /* Cheat if we are just passed a version, not a valid package name */ versionstr = ch ? ch + 1 : pkgname; ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org
svn commit: r227459 - in head/sys: dev/lmc net netgraph netinet
Author: brooks Date: Fri Nov 11 22:57:52 2011 New Revision: 227459 URL: http://svn.freebsd.org/changeset/base/227459 Log: In r191367 the need for if_free_type() was removed and a new member if_alloctype was used to store the origional interface type. Take advantage of this change by removing all existing uses of if_free_type() in favor of if_free(). MFC after:1 Month Modified: head/sys/dev/lmc/if_lmc.c head/sys/net/if_bridge.c head/sys/net/if_lagg.c head/sys/net/if_tap.c head/sys/net/if_vlan.c head/sys/netgraph/ng_fec.c head/sys/netinet/ip_carp.c Modified: head/sys/dev/lmc/if_lmc.c == --- head/sys/dev/lmc/if_lmc.c Fri Nov 11 22:27:09 2011(r227458) +++ head/sys/dev/lmc/if_lmc.c Fri Nov 11 22:57:52 2011(r227459) @@ -4945,7 +4945,9 @@ lmc_ifnet_detach(softc_t *sc) /* Detach from the ifnet kernel interface. */ if_detach(sc-ifp); -# if (__FreeBSD_version = 60) +# if (defined(__FreeBSD__) __FreeBSD_version = 800082) + if_free(sc-ifp); +# elif (defined(__FreeBSD__) __FreeBSD_version = 60) if_free_type(sc-ifp, NSPPP ? IFT_PPP : IFT_OTHER); # endif } Modified: head/sys/net/if_bridge.c == --- head/sys/net/if_bridge.cFri Nov 11 22:27:09 2011(r227458) +++ head/sys/net/if_bridge.cFri Nov 11 22:57:52 2011(r227459) @@ -676,7 +676,7 @@ bridge_clone_destroy(struct ifnet *ifp) bstp_detach(sc-sc_stp); ether_ifdetach(ifp); - if_free_type(ifp, IFT_ETHER); + if_free(ifp); /* Tear down the routing table. */ bridge_rtable_fini(sc); Modified: head/sys/net/if_lagg.c == --- head/sys/net/if_lagg.c Fri Nov 11 22:27:09 2011(r227458) +++ head/sys/net/if_lagg.c Fri Nov 11 22:57:52 2011(r227459) @@ -275,7 +275,7 @@ lagg_clone_create(struct if_clone *ifc, if (lagg_protos[i].ti_proto == LAGG_PROTO_DEFAULT) { sc-sc_proto = lagg_protos[i].ti_proto; if ((error = lagg_protos[i].ti_attach(sc)) != 0) { - if_free_type(ifp, IFT_ETHER); + if_free(ifp); free(sc, M_DEVBUF); return (error); } @@ -293,7 +293,6 @@ lagg_clone_create(struct if_clone *ifc, ifmedia_set(sc-sc_media, IFM_ETHER | IFM_AUTO); if_initname(ifp, ifc-ifc_name, unit); - ifp-if_type = IFT_ETHER; ifp-if_softc = sc; ifp-if_start = lagg_start; ifp-if_init = lagg_init; @@ -305,7 +304,7 @@ lagg_clone_create(struct if_clone *ifc, IFQ_SET_READY(ifp-if_snd); /* -* Attach as an ordinary ethernet device, childs will be attached +* Attach as an ordinary ethernet device, children will be attached * as special device IFT_IEEE8023ADLAG. */ ether_ifattach(ifp, eaddr); @@ -352,7 +351,7 @@ lagg_clone_destroy(struct ifnet *ifp) ifmedia_removeall(sc-sc_media); ether_ifdetach(ifp); - if_free_type(ifp, IFT_ETHER); + if_free(ifp); mtx_lock(lagg_list_mtx); SLIST_REMOVE(lagg_list, sc, lagg_softc, sc_entries); Modified: head/sys/net/if_tap.c == --- head/sys/net/if_tap.c Fri Nov 11 22:27:09 2011(r227458) +++ head/sys/net/if_tap.c Fri Nov 11 22:57:52 2011(r227459) @@ -218,7 +218,7 @@ tap_destroy(struct tap_softc *tp) knlist_destroy(tp-tap_rsel.si_note); destroy_dev(tp-tap_dev); ether_ifdetach(ifp); - if_free_type(ifp, IFT_ETHER); + if_free(ifp); mtx_destroy(tp-tap_mtx); free(tp, M_TAP); Modified: head/sys/net/if_vlan.c == --- head/sys/net/if_vlan.c Fri Nov 11 22:27:09 2011(r227458) +++ head/sys/net/if_vlan.c Fri Nov 11 22:57:52 2011(r227459) @@ -967,7 +967,7 @@ vlan_clone_create(struct if_clone *ifc, */ ether_ifdetach(ifp); vlan_unconfig(ifp); - if_free_type(ifp, IFT_ETHER); + if_free(ifp); ifc_free_unit(ifc, unit); free(ifv, M_VLAN); @@ -989,7 +989,7 @@ vlan_clone_destroy(struct if_clone *ifc, ether_ifdetach(ifp);/* first, remove it from system-wide lists */ vlan_unconfig(ifp); /* now it can be unconfigured and freed */ - if_free_type(ifp, IFT_ETHER); + if_free(ifp); free(ifv, M_VLAN); ifc_free_unit(ifc, unit); Modified: head/sys/netgraph/ng_fec.c
svn commit: r227460 - head/sys/netinet6
Author: qingli Date: Fri Nov 11 23:22:38 2011 New Revision: 227460 URL: http://svn.freebsd.org/changeset/base/227460 Log: A default route learned from the RAs could be deleted manually after its installation. This removal may be accidental and can prevent the default route from being installed in the future if the associated default router has the best preference. The cause is the lack of status update in the default router on the state of its route installation in the kernel FIB. This patch fixes the described problem. Reviewed by: hrs, discussed with hrs MFC after:5 days Modified: head/sys/netinet6/in6.c head/sys/netinet6/nd6.c head/sys/netinet6/nd6.h head/sys/netinet6/nd6_rtr.c Modified: head/sys/netinet6/in6.c == --- head/sys/netinet6/in6.c Fri Nov 11 22:57:52 2011(r227459) +++ head/sys/netinet6/in6.c Fri Nov 11 23:22:38 2011(r227460) @@ -152,7 +152,7 @@ in6_ifaddloop(struct ifaddr *ifa) ia = ifa2ia6(ifa); ifp = ifa-ifa_ifp; IF_AFDATA_LOCK(ifp); - ifa-ifa_rtrequest = NULL; + ifa-ifa_rtrequest = nd6_rtrequest; /* XXX QL * we need to report rt_newaddrmsg Modified: head/sys/netinet6/nd6.c == --- head/sys/netinet6/nd6.c Fri Nov 11 22:57:52 2011(r227459) +++ head/sys/netinet6/nd6.c Fri Nov 11 23:22:38 2011(r227460) @@ -1174,6 +1174,46 @@ done: } +/* + * Rejuvenate this function for routing operations related + * processing. + */ +void +nd6_rtrequest(int req, struct rtentry *rt, struct rt_addrinfo *info) +{ + struct sockaddr_in6 *gateway = (struct sockaddr_in6 *)rt-rt_gateway; + struct nd_defrouter *dr; + struct ifnet *ifp = rt-rt_ifp; + + RT_LOCK_ASSERT(rt); + + switch (req) { + case RTM_ADD: + break; + + case RTM_DELETE: + if (!ifp) + return; + /* +* Only indirect routes are interesting. +*/ + if ((rt-rt_flags RTF_GATEWAY) == 0) + return; + /* +* check for default route +*/ + if (IN6_ARE_ADDR_EQUAL(in6addr_any, + SIN6(rt_key(rt))-sin6_addr)) { + + dr = defrouter_lookup(gateway-sin6_addr, ifp); + if (dr != NULL) + dr-installed = 0; + } + break; + } +} + + int nd6_ioctl(u_long cmd, caddr_t data, struct ifnet *ifp) { Modified: head/sys/netinet6/nd6.h == --- head/sys/netinet6/nd6.h Fri Nov 11 22:57:52 2011(r227459) +++ head/sys/netinet6/nd6.h Fri Nov 11 23:22:38 2011(r227460) @@ -406,6 +406,7 @@ void nd6_purge __P((struct ifnet *)); void nd6_nud_hint __P((struct rtentry *, struct in6_addr *, int)); int nd6_resolve __P((struct ifnet *, struct rtentry *, struct mbuf *, struct sockaddr *, u_char *)); +void nd6_rtrequest __P((int, struct rtentry *, struct rt_addrinfo *)); int nd6_ioctl __P((u_long, caddr_t, struct ifnet *)); struct llentry *nd6_cache_lladdr __P((struct ifnet *, struct in6_addr *, char *, int, int, int)); Modified: head/sys/netinet6/nd6_rtr.c == --- head/sys/netinet6/nd6_rtr.c Fri Nov 11 22:57:52 2011(r227459) +++ head/sys/netinet6/nd6_rtr.c Fri Nov 11 23:22:38 2011(r227460) @@ -751,9 +751,10 @@ defrtrlist_update(struct nd_defrouter *n /* * If the preference does not change, there's no need -* to sort the entries. +* to sort the entries. Also make sure the selected +* router is still installed in the kernel. */ - if (rtpref(new) == oldpref) { + if (dr-installed rtpref(new) == oldpref) { splx(s); return (dr); } ___ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to svn-src-all-unsubscr...@freebsd.org