From owner-freebsd-hackers@FreeBSD.ORG Sat Dec 10 22:49:33 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id E003916A41F; Sat, 10 Dec 2005 22:49:32 +0000 (GMT) (envelope-from craig@tobuj.gank.org) Received: from ion.gank.org (ion.gank.org [69.55.238.164]) by mx1.FreeBSD.org (Postfix) with ESMTP id 4871B43D86; Sat, 10 Dec 2005 22:49:24 +0000 (GMT) (envelope-from craig@tobuj.gank.org) Received: by ion.gank.org (mail, from userid 1001) id CFC022D639; Sat, 10 Dec 2005 16:49:23 -0600 (CST) Date: Sat, 10 Dec 2005 16:49:18 -0600 From: Craig Boston To: freebsd-mobile@freebsd.org Message-ID: <20051210224917.GA54870@nowhere> References: <20051130020734.GA6577@nowhere> <200512020817.55769.jhb@freebsd.org> <20051203005104.GA22567@nowhere> <200512031630.59476.jhb@freebsd.org> <20051204004131.GA7596@nowhere> <20051206015129.GA34415@nowhere> <20051206035228.GA34979@nowhere> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="9amGYk9869ThD9tj" Content-Disposition: inline In-Reply-To: <20051206035228.GA34979@nowhere> User-Agent: Mutt/1.4.2.1i X-Mailman-Approved-At: Sun, 11 Dec 2005 00:38:55 +0000 Cc: Ariff Abdullah Subject: Toshiba Satellite L25 followup X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 10 Dec 2005 22:49:33 -0000 --9amGYk9869ThD9tj Content-Type: text/plain; charset=us-ascii Content-Disposition: inline (bcc to -hackers since it also mostly concludes the "Weird PCI interrupt delivery problem" thread) Here's the current status of getting this model laptop to work with FreeBSD. Summary ________________________________________________________________ It's possible to get most features working, but takes some effort. I'd not recommend buying one of these to anyone who doesn't want to get their hands dirty with kernel patches and other workarounds. The same warning may apply to other ATI IXP400 chipset based machines as well. ACPI __________________________________________________________________ Works, sort of. ASL is in pretty bad shape. Patch is attached that fixes the battery status and interrupt routing. More details on interrupt routing at the bottom of this message. Suspend is still broken -- it suspends but isn't able to wake up. APIC ___________________________________________________________________ Broken. Also, the MP Table is broken so it won't even boot without either ACPI or kernel workarounds. Always use hint.apic.0.disabled=1 for now. Sound __________________________________________________________________ Works. I had started reverse engineering the chip using the windows driver in a modified qemu. Was half done (ac97 interface and mixer worked, DMA transfers partially working), when I discovered that Ariff had beaten me to the punch and committed a driver to current a few days ago :) Ariff, I'm CC-ing you as well because there is still a small issue with the mixer. This particular ac97 codec seems to support the mute bit of AC97_MIX_BEEP, but no volume levels other than 0 (max). As a result, it gets muted and marked as disabled so there is no way to re-enable the PC speaker. Interestingly, the default value of the register seems to be 0x8000 even though the speaker is _NOT_ muted at bootup. I've got a local hack to work around it, but it's not a general solution. The codec ID is 0x43585430. SMBus __________________________________________________________________ Doesn't seem to be a driver yet. Can get temperature through ACPI so this may not be an issue. Modem __________________________________________________________________ No driver. Apparently based on the Conexant AC97 codec as well (i.e. Winmodem). I've seen references to Linux folks working on this, so it may be possible to get it working, but I haven't tried yet. Video __________________________________________________________________ 2D acceleration via the linux drivers (see my original post at http://docs.freebsd.org/cgi/getmsg.cgi?fetch=155785+0+archive/2005/freebsd-mobile/20051127.freebsd-mobile for instructions). xorg-server-snap should eventually support this, but it just segfaults for me. Here's the rundown for the whole interrupt thread: APIC ___________________________________________________________________ The APIC is busted; I'm not sure why. Something is causing it to start ignoring certain pins after a while. The ACPI and i8254 timecounters exacerbate whatever it is that's causing it to fail. Running with WITNESS, the APIC seems to work ok. My current theory is that some register is being updated faster than the hardware can handle, and WITNESS slows things down enough to not trigger it. Windows may have additional delays or timing differences in how it accesses the hardware so it was never noticed during testing. !APIC (dual 8259A PIC) _________________________________________________ Without ACPI, Cardbus doesn't generate interrupts. Thanks to jhb's very informative post to stable the other day, I'm certain that it's because the BIOS isn't setting up the link device that is connected to it. There is no $PIR table, so although we can try to map an interrupt to it, we can't program the link device to route it anywhere. With ACPI, the _PRT provided for the secondary PCI bus is completely wrong. After much trial and error I've finally figured out which PCI link is connected to which slot/pin. The attached patch to the ASL is able to get everything routed correctly for the +ACPI -APIC case. Running without the APIC isn't quite optimal, but at least everything works. I hope that all this is helpful to any others who have one of these machines. I'll be attempting to contact Toshiba about these issues and see if we can't get some of them addressed in a future BIOS update. Craig --9amGYk9869ThD9tj Content-Type: text/plain; charset=us-ascii Content-Disposition: attachment; filename="acpifix.diff" --- toshiba.asl Sat Nov 26 14:37:24 2005 +++ fixed2.asl Wed Dec 7 17:26:59 2005 @@ -192,6 +192,8 @@ Notify (\_SB.BAT1, 0x81) } } + + Return (0x0) } Scope (\_SI) @@ -1023,408 +1025,6 @@ Z00A, 32 } - Device (PB2) - { - Name (_ADR, 0x00020000) - Name (_PRW, Package (0x02) - { - 0x18, - 0x04 - }) - Method (_PRT, 0, NotSerialized) - { - If (GPIC) - { - Return (Package (0x04) - { - Package (0x04) - { - 0xFFFF, - 0x00, - 0x00, - 0x12 - }, - - Package (0x04) - { - 0xFFFF, - 0x01, - 0x00, - 0x13 - }, - - Package (0x04) - { - 0xFFFF, - 0x02, - 0x00, - 0x10 - }, - - Package (0x04) - { - 0xFFFF, - 0x03, - 0x00, - 0x11 - } - }) - } - Else - { - Return (Package (0x04) - { - Package (0x04) - { - 0xFFFF, - 0x00, - \_SB.PCI0.LPC0.LNKC, - 0x00 - }, - - Package (0x04) - { - 0xFFFF, - 0x01, - \_SB.PCI0.LPC0.LNKD, - 0x00 - }, - - Package (0x04) - { - 0xFFFF, - 0x02, - \_SB.PCI0.LPC0.LNKA, - 0x00 - }, - - Package (0x04) - { - 0xFFFF, - 0x03, - \_SB.PCI0.LPC0.LNKB, - 0x00 - } - }) - } - } - } - - Device (PB3) - { - Name (_ADR, 0x00030000) - Method (_PRT, 0, NotSerialized) - { - If (GPIC) - { - Return (Package (0x04) - { - Package (0x04) - { - 0xFFFF, - 0x00, - 0x00, - 0x13 - }, - - Package (0x04) - { - 0xFFFF, - 0x01, - 0x00, - 0x10 - }, - - Package (0x04) - { - 0xFFFF, - 0x02, - 0x00, - 0x11 - }, - - Package (0x04) - { - 0xFFFF, - 0x03, - 0x00, - 0x12 - } - }) - } - Else - { - Return (Package (0x04) - { - Package (0x04) - { - 0xFFFF, - 0x00, - \_SB.PCI0.LPC0.LNKD, - 0x00 - }, - - Package (0x04) - { - 0xFFFF, - 0x01, - \_SB.PCI0.LPC0.LNKA, - 0x00 - }, - - Package (0x04) - { - 0xFFFF, - 0x02, - \_SB.PCI0.LPC0.LNKB, - 0x00 - }, - - Package (0x04) - { - 0xFFFF, - 0x03, - \_SB.PCI0.LPC0.LNKC, - 0x00 - } - }) - } - } - } - - Device (PB4) - { - Name (_ADR, 0x00040000) - OperationRegion (XPCB, PCI_Config, 0x58, 0x24) - Field (XPCB, ByteAcc, NoLock, Preserve) - { - Offset (0x10), - LKCN, 16, - LKST, 16, - Offset (0x1A), - SLST, 16 - } - - OperationRegion (XPRI, PCI_Config, 0xE0, 0x08) - Field (XPRI, ByteAcc, NoLock, Preserve) - { - XPIR, 32, - XPID, 32 - } - - OperationRegion (XPEX, SystemMemory, 0xE0020100, 0x0100) - Field (XPEX, DWordAcc, NoLock, Preserve) - { - Offset (0x40), - ECPH, 32, - Offset (0x58), - VC02, 32, - VC0S, 32 - } - - Method (XPDL, 0, NotSerialized) - { - Store (Zero, Local0) - If (And (VC02, 0x00020000)) - { - Store (Ones, Local0) - } - - Return (Local0) - } - - Method (XPRD, 1, NotSerialized) - { - Store (Arg0, XPIR) - Store (XPID, Local0) - Store (0x00, XPIR) - Return (Local0) - } - - Method (XPWR, 2, NotSerialized) - { - Store (Arg0, XPIR) - Store (Arg1, XPID) - Store (0x00, XPIR) - } - - Method (XPRT, 0, NotSerialized) - { - Store (XPRD (0xA2), Local0) - And (Local0, Not (0x07), Local0) - ShiftRight (Local0, 0x04, Local1) - And (Local1, 0x07, Local1) - Or (Local0, Local1, Local0) - Or (Local0, 0x0100, Local0) - XPWR (0xA2, Local0) - } - - Method (XPLP, 1, NotSerialized) - { - If (LEqual (\_SB.PCI0.GPPM (), 0x02)) - { - Store (0x1010, Local1) - } - Else - { - Store (0x0404, Local1) - } - - Store (\_SB.PCI0.NBXR (0x00010065), Local2) - If (Arg0) - { - And (Local2, Not (Local1), Local2) - } - Else - { - Or (Local2, Local1, Local2) - } - - \_SB.PCI0.NBXW (0x00010065, Local2) - } - - Method (XPR2, 0, NotSerialized) - { - Store (LKCN, Local0) - And (Local0, Not (0x20), Local0) - Store (Local0, LKCN) - Or (Local0, 0x20, Local0) - Store (Local0, LKCN) - Store (0x64, Local1) - Store (0x01, Local2) - While (LAnd (Local1, Local2)) - { - Sleep (0x01) - Store (LKST, Local3) - If (And (Local3, 0x0800)) - { - Decrement (Local1) - } - Else - { - Store (0x00, Local2) - } - } - - And (Local0, Not (0x20), Local0) - Store (Local0, LKCN) - If (LNot (Local2)) - { - Return (Ones) - } - Else - { - Return (Zero) - } - } - - Device (NCRD) - { - Name (_ADR, 0x00) - OperationRegion (PCFG, PCI_Config, 0x00, 0x08) - Field (PCFG, DWordAcc, NoLock, Preserve) - { - DVID, 32, - PCMS, 32 - } - - Method (_RMV, 0, NotSerialized) - { - Return (0x01) - } - - Method (_STA, 0, NotSerialized) - { - If (\_SB.PCI0.SMB.GVT6) - { - Return (0x0F) - } - Else - { - Return (0x00) - } - } - } - - Method (_PRT, 0, NotSerialized) - { - If (GPIC) - { - Return (Package (0x04) - { - Package (0x04) - { - 0xFFFF, - 0x00, - 0x00, - 0x10 - }, - - Package (0x04) - { - 0xFFFF, - 0x01, - 0x00, - 0x11 - }, - - Package (0x04) - { - 0xFFFF, - 0x02, - 0x00, - 0x12 - }, - - Package (0x04) - { - 0xFFFF, - 0x03, - 0x00, - 0x13 - } - }) - } - Else - { - Return (Package (0x04) - { - Package (0x04) - { - 0xFFFF, - 0x00, - \_SB.PCI0.LPC0.LNKA, - 0x00 - }, - - Package (0x04) - { - 0xFFFF, - 0x01, - \_SB.PCI0.LPC0.LNKB, - 0x00 - }, - - Package (0x04) - { - 0xFFFF, - 0x02, - \_SB.PCI0.LPC0.LNKC, - 0x00 - }, - - Package (0x04) - { - 0xFFFF, - 0x03, - \_SB.PCI0.LPC0.LNKD, - 0x00 - } - }) - } - } - } - Scope (\_GPE) { } @@ -1459,291 +1059,6 @@ }) } - Device (SATA) - { - Name (_ADR, 0x00120000) - Name (B5EN, 0x00) - Name (BA_5, 0x00) - OperationRegion (SATX, PCI_Config, 0x00, 0x28) - Field (SATX, AnyAcc, NoLock, Preserve) - { - VIDI, 32, - Offset (0x24), - BA05, 32 - } - - Method (GBAA, 0, NotSerialized) - { - Store (BA_5, B5EN) - If (LEqual (BA_5, 0xFFFFFFFF)) - { - Store (0x00, B5EN) - Return (0xFFF80000) - } - Else - { - Store (0x01, B5EN) - Return (BA_5) - } - } - - OperationRegion (BAR5, SystemMemory, GBAA, 0x0200) - Field (BAR5, AnyAcc, NoLock, Preserve) - { - Offset (0x104), - CSTX, 1, - CST0, 1, - Offset (0x10A), - STA0, 1, - Offset (0x184), - CSTY, 1, - CST1, 1, - Offset (0x18A), - STA1, 1 - } - - Method (_INI, 0, NotSerialized) - { - Store (BA05, BA_5) - GBAA () - If (B5EN) - { - If (\_SB.PCI0.SATA.STA0) - { - Store (\_SB.PCI0.SATA.STA0, \_SB.PCI0.SATA.STA0) - } - - If (\_SB.PCI0.SATA.STA1) - { - Store (\_SB.PCI0.SATA.STA1, \_SB.PCI0.SATA.STA1) - } - } - } - - Device (PRID) - { - Name (_ADR, 0x00) - Device (P_D0) - { - Name (_ADR, 0x00) - Method (_STA, 0, NotSerialized) - { - Store (BA05, BA_5) - GBAA () - If (LEqual (B5EN, 0x00)) - { - Return (0x00) - } - - If (\_SB.PCI0.SATA.CST0) - { - Return (0x0F) - } - Else - { - Return (0x00) - } - } - } - } - - Device (SECD) - { - Name (_ADR, 0x01) - Device (S_D0) - { - Name (_ADR, 0x00) - Method (_STA, 0, NotSerialized) - { - Store (BA05, BA_5) - GBAA () - If (LEqual (B5EN, 0x00)) - { - Return (0x00) - } - - If (\_SB.PCI0.SATA.CST1) - { - Return (0x0F) - } - Else - { - Return (0x00) - } - } - } - } - } - - Device (SAT2) - { - Name (_ADR, 0x00110000) - Name (B5EN, 0x00) - Name (BA_5, 0x00) - OperationRegion (SATX, PCI_Config, 0x00, 0x28) - Field (SATX, AnyAcc, NoLock, Preserve) - { - VIDI, 32, - Offset (0x24), - BA05, 32 - } - - Method (GBAA, 0, NotSerialized) - { - Store (BA_5, B5EN) - If (LEqual (BA_5, 0xFFFFFFFF)) - { - Store (0x00, B5EN) - Return (0xFFF80000) - } - Else - { - Store (0x01, B5EN) - Return (BA_5) - } - } - - OperationRegion (BAR5, SystemMemory, GBAA, 0x0200) - Field (BAR5, AnyAcc, NoLock, Preserve) - { - Offset (0x104), - CSTX, 1, - CST0, 1, - Offset (0x10A), - STA0, 1, - Offset (0x184), - CSTY, 1, - CST1, 1, - Offset (0x18A), - STA1, 1 - } - - Method (_INI, 0, NotSerialized) - { - Store (BA05, BA_5) - GBAA () - If (B5EN) - { - If (\_SB.PCI0.SAT2.STA0) - { - Store (\_SB.PCI0.SAT2.STA0, \_SB.PCI0.SAT2.STA0) - } - - If (\_SB.PCI0.SAT2.STA1) - { - Store (\_SB.PCI0.SAT2.STA1, \_SB.PCI0.SAT2.STA1) - } - } - } - - Device (PRID) - { - Name (_ADR, 0x00) - Device (P_D0) - { - Name (_ADR, 0x00) - Method (_STA, 0, NotSerialized) - { - Store (BA05, BA_5) - GBAA () - If (LEqual (B5EN, 0x00)) - { - Return (0x00) - } - - If (\_SB.PCI0.SAT2.CST0) - { - Return (0x0F) - } - Else - { - Return (0x00) - } - } - } - } - - Device (SECD) - { - Name (_ADR, 0x01) - Device (S_D0) - { - Name (_ADR, 0x00) - Method (_STA, 0, NotSerialized) - { - Store (BA05, BA_5) - GBAA () - If (LEqual (B5EN, 0x00)) - { - Return (0x00) - } - - If (\_SB.PCI0.SAT2.CST1) - { - Return (0x0F) - } - Else - { - Return (0x00) - } - } - } - } - } - - Scope (\_GPE) - { - Method (_L1F, 0, NotSerialized) - { - Sleep (0x07D0) - Store (\_SB.PCI0.SATA.BA05, \_SB.PCI0.SATA.BA_5) - \_SB.PCI0.SATA.GBAA () - If (\_SB.PCI0.SATA.B5EN) - { - If (\_SB.PCI0.SATA.STA0) - { - Notify (\_SB.PCI0.SATA.PRID.P_D0, 0x00) - Sleep (0x07D0) - Notify (\_SB.PCI0.SATA.PRID, 0x01) - Sleep (0x07D0) - Store (\_SB.PCI0.SATA.STA0, \_SB.PCI0.SATA.STA0) - } - - If (\_SB.PCI0.SATA.STA1) - { - Notify (\_SB.PCI0.SATA.SECD.S_D0, 0x00) - Sleep (0x07D0) - Notify (\_SB.PCI0.SATA.SECD, 0x01) - Sleep (0x07D0) - Store (\_SB.PCI0.SATA.STA1, \_SB.PCI0.SATA.STA1) - } - } - - Store (\_SB.PCI0.SAT2.BA05, \_SB.PCI0.SAT2.BA_5) - \_SB.PCI0.SAT2.GBAA () - If (\_SB.PCI0.SAT2.B5EN) - { - If (\_SB.PCI0.SAT2.STA0) - { - Notify (\_SB.PCI0.SAT2.PRID.P_D0, 0x00) - Sleep (0x07D0) - Notify (\_SB.PCI0.SAT2.PRID, 0x01) - Sleep (0x07D0) - Store (\_SB.PCI0.SAT2.STA0, \_SB.PCI0.SAT2.STA0) - } - - If (\_SB.PCI0.SAT2.STA1) - { - Notify (\_SB.PCI0.SAT2.SECD.S_D0, 0x00) - Sleep (0x07D0) - Notify (\_SB.PCI0.SAT2.SECD, 0x01) - Sleep (0x07D0) - Store (\_SB.PCI0.SAT2.STA1, \_SB.PCI0.SAT2.STA1) - } - } - } - } - Device (SMB) { Name (_ADR, 0x00140000) @@ -1761,7 +1076,7 @@ } OperationRegion (SMB, PCI_Config, 0x69, 0x01) - Field (SMB, WordAcc, NoLock, Preserve) + Field (SMB, ByteAcc, NoLock, Preserve) { SIRQ, 8 } @@ -3493,191 +2808,39 @@ } Else { - Return (Package (0x17) + Return (Package (0x04) { Package (0x04) { - 0x0008FFFF, - 0x00, - \_SB.PCI0.LPC0.LNKA, - 0x00 - }, - - Package (0x04) - { - 0x0008FFFF, - 0x01, - \_SB.PCI0.LPC0.LNKB, - 0x00 - }, - - Package (0x04) - { - 0x0009FFFF, - 0x00, - \_SB.PCI0.LPC0.LNKC, - 0x00 - }, - - Package (0x04) - { - 0x000AFFFF, - 0x00, - \_SB.PCI0.LPC0.LNKA, - 0x00 - }, - - Package (0x04) - { - 0x000AFFFF, - 0x01, - \_SB.PCI0.LPC0.LNKB, - 0x00 - }, - - Package (0x04) - { - 0x000AFFFF, - 0x02, - \_SB.PCI0.LPC0.LNKC, - 0x00 - }, - - Package (0x04) - { - 0x000AFFFF, - 0x03, - \_SB.PCI0.LPC0.LNKD, - 0x00 - }, - - Package (0x04) - { - 0x000BFFFF, - 0x00, - \_SB.PCI0.LPC0.LNKB, - 0x00 - }, - - Package (0x04) - { - 0x000BFFFF, - 0x01, - \_SB.PCI0.LPC0.LNKC, - 0x00 - }, - - Package (0x04) - { - 0x000BFFFF, - 0x02, - \_SB.PCI0.LPC0.LNKD, - 0x00 - }, - - Package (0x04) - { - 0x000BFFFF, - 0x03, - \_SB.PCI0.LPC0.LNKA, - 0x00 - }, - - Package (0x04) - { - 0x000CFFFF, + 0x0001FFFF, 0x00, - \_SB.PCI0.LPC0.LNKC, - 0x00 - }, - - Package (0x04) - { - 0x000CFFFF, - 0x01, - \_SB.PCI0.LPC0.LNKD, - 0x00 - }, - - Package (0x04) - { - 0x000CFFFF, - 0x02, - \_SB.PCI0.LPC0.LNKA, - 0x00 - }, - - Package (0x04) - { - 0x000CFFFF, - 0x03, - \_SB.PCI0.LPC0.LNKB, + \_SB.PCI0.LPC0.LNKE, 0x00 }, Package (0x04) { - 0x000DFFFF, + 0x0002FFFF, 0x00, - \_SB.PCI0.LPC0.LNKD, - 0x00 - }, - - Package (0x04) - { - 0x000DFFFF, - 0x01, - \_SB.PCI0.LPC0.LNKA, - 0x00 - }, - - Package (0x04) - { - 0x000DFFFF, - 0x02, - \_SB.PCI0.LPC0.LNKB, - 0x00 - }, - - Package (0x04) - { - 0x000DFFFF, - 0x03, - \_SB.PCI0.LPC0.LNKC, + \_SB.PCI0.LPC0.LNKF, 0x00 }, Package (0x04) { - 0x000EFFFF, + 0x0004FFFF, 0x00, - \_SB.PCI0.LPC0.LNKA, + \_SB.PCI0.LPC0.LNKG, 0x00 }, Package (0x04) { - 0x000EFFFF, + 0x0004FFFF, 0x01, - \_SB.PCI0.LPC0.LNKB, - 0x00 - }, - - Package (0x04) - { - 0x000EFFFF, - 0x02, - \_SB.PCI0.LPC0.LNKC, + \_SB.PCI0.LPC0.LNKH, 0x00 }, - - Package (0x04) - { - 0x000EFFFF, - 0x03, - \_SB.PCI0.LPC0.LNKD, - 0x00 - } }) } } @@ -3851,8 +3014,8 @@ Name (PBST, Package (0x04) { 0x00, - Z00D, - Z00D, + 0xFFFFFFFF, + 0xFFFFFFFF, 0x2710 }) Name (ERRC, 0x00) --9amGYk9869ThD9tj-- From owner-freebsd-hackers@FreeBSD.ORG Mon Dec 12 04:03:43 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id DC0CA16A41F for ; Mon, 12 Dec 2005 04:03:43 +0000 (GMT) (envelope-from nsrashmi@gmail.com) Received: from wproxy.gmail.com (wproxy.gmail.com [64.233.184.198]) by mx1.FreeBSD.org (Postfix) with ESMTP id 004EE43D67 for ; Mon, 12 Dec 2005 04:03:38 +0000 (GMT) (envelope-from nsrashmi@gmail.com) Received: by wproxy.gmail.com with SMTP id i5so299672wra for ; Sun, 11 Dec 2005 20:03:38 -0800 (PST) DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=beta; d=gmail.com; h=received:message-id:date:from:to:subject:mime-version:content-type:content-transfer-encoding:content-disposition; b=QJY3n7/0S27RcdA2qpwdiDa9cNqUK6m6b2ZEOqxjGpIpsqjfh8EuFKcUUz8N16RPK5Pn1yVeu4RRY0kpRDX+rgZLeTLbIwrPTK49naLAp4jM/L93g4GVWkqLPCpatXBWLLgu0Sy11jpFhOrEq+TJMR+OYbmzSRG7AG2k8y2IzDc= Received: by 10.64.241.5 with SMTP id o5mr5394655qbh; Sun, 11 Dec 2005 20:03:37 -0800 (PST) Received: by 10.64.204.16 with HTTP; Sun, 11 Dec 2005 20:03:37 -0800 (PST) Message-ID: <9f9993160512112003i56f25cd6t78533717fec580d1@mail.gmail.com> Date: Mon, 12 Dec 2005 09:33:37 +0530 From: rashmi ns To: freebsd-hackers@freebsd.org, freebsd-drivers@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Content-Disposition: inline Cc: Subject: Help Reqd: "uiomove" transferring zero bytes from user-kernel space X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 12 Dec 2005 04:03:44 -0000 Hello Team, when i use "uiomove" in the character device interface the no of bytes transfrerred between kernel and userspace is zero .but the actual data transferred when trraced through "uio->resid" is correct .can any one explain why this is happening ? /*Character Device Interfaces*/ static struct cdevsw hdlc_cdevsw =3D { .d_maj =3D CDEV_MAJOR, .d_open =3D hdlc_open, .d_read =3D hdlc_read, .d_write =3D hdlc_write, .d_ioctl =3D hdlc_ioctl, .d_close =3D hdlc_close, .d_version =3D D_VERSION, }; static int hdlc_write(dev_t dev, struct uio *uio, int ioflag) { int towrite,written; /*char device inf*/ written=3Duiomove((void *)write_tx_buffer,towrite,uio); uprintf("uio->resid=3D%d",uio->uio_resid); uprintf("No of bytes written =3D%d",written); } Thanks and Regards, Rashmi.N.S From owner-freebsd-hackers@FreeBSD.ORG Mon Dec 12 04:18:14 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id ADC2616A41F for ; Mon, 12 Dec 2005 04:18:14 +0000 (GMT) (envelope-from myst@tut.by) Received: from tut.by (speedy.tutby.com [195.137.160.40]) by mx1.FreeBSD.org (Postfix) with ESMTP id 0AD0643D5C for ; Mon, 12 Dec 2005 04:18:13 +0000 (GMT) (envelope-from myst@tut.by) Received: from [203.145.132.252] (account myst@tut.by) by tut.by (CommuniGate Pro WebUser 4.3.6) with HTTP id 32082092; Mon, 12 Dec 2005 06:10:36 +0200 From: Stas Myasnikov To: Matthew Dillon X-Mailer: CommuniGate Pro WebUser Interface v.4.3.6 Date: Mon, 12 Dec 2005 06:10:36 +0200 Message-ID: In-Reply-To: <200512102245.jBAMjiu0087758@apollo.backplane.com> References: <20051210150612.648aef0e.eric@theeric.com> <200512102245.jBAMjiu0087758@apollo.backplane.com> MIME-Version: 1.0 Content-Type: text/plain; charset="windows-1251"; format="flowed" Content-Transfer-Encoding: 8bit Cc: freebsd-hackers@freebsd.org Subject: Re: DragonFly talk at the upcoming BAYLISA (15 December 2005) X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 12 Dec 2005 04:18:14 -0000 Hello Matt! I hope you'll make the materials available on the Net. > Hello everyone! I will be giving a DragonFly talk at the next > Bay Lisa. The primary focus of my talk will be a physical > characterization (latencies, overheads, etc) of MP mechanisms > and algorithms implemented by DragonFly. I'll be explaining how > the algorithms work and providing hard (TSC-derived) numbers from >a > dual-core Athlon 64 X2 based system. > > The Bay Lisa in question will be held on December 15's 2005 7:30 >p.m. > to 9:30 p.m. on Apple Campus in Cupertino (California, USA). > Site > information and directions below: > > http://www.baylisa.org/ > http://www.baylisa.org/location.shtml > > It is open to the public. > > Since the algorithms are fairly low level, the discussion and >hard > numbers I present really applies to anyone doing MP work on any > operating system. > > -Matt From owner-freebsd-hackers@FreeBSD.ORG Mon Dec 12 05:18:14 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 6BD0A16A41F; Mon, 12 Dec 2005 05:18:14 +0000 (GMT) (envelope-from jgrosch@mooseriver.com) Received: from mooseriver.com (h-66-166-146-73.snvacaid.covad.net [66.166.146.73]) by mx1.FreeBSD.org (Postfix) with ESMTP id E1C8043D5A; Mon, 12 Dec 2005 05:18:13 +0000 (GMT) (envelope-from jgrosch@mooseriver.com) Received: by mooseriver.com (Postfix, from userid 200) id 9964117027; Sun, 11 Dec 2005 21:18:13 -0800 (PST) Date: Sun, 11 Dec 2005 21:18:13 -0800 From: Josef Grosch To: freebsd-hackers@freebsd.org Message-ID: <20051212051813.GA19499@mooseriver.com> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="YiEDa0DAkWCtVeE4" Content-Disposition: inline User-Agent: Mutt/1.4.2.1i Organization: Moose River, LLC Subject: Cardbus panics X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: jgrosch@MooseRiver.com List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 12 Dec 2005 05:18:14 -0000 --YiEDa0DAkWCtVeE4 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable I have an IBM T22 thinkpad running FreeBSD 5.4-RELEASE-p8. I have the CardBus devices in the current kernel. When I insert a CardBus device, A Xircom RealPort CardBus Ethernet I get a kernel panic like so; Dec 9 18:42:32 paris kernel: cbb alloc res fail=20 Dec 9 18:42:32 paris kernel: cardbus1: Can't get memory for IO ports=20 Dec 9 18:42:32 paris kernel: dc0: port 0-0x7f = mem \ 0x88000000-0x880007ff,0x88000800-0x88000fff at device 0.0 on cardbus1=20 Dec 9 18:42:32 paris kernel: cbb alloc res fail=20 Dec 9 18:42:32 paris kernel: dc0: couldn't map ports/memory=20 Dec 9 18:42:32 paris kernel: =20 Dec 9 18:42:32 paris kernel: =20 Dec 9 18:42:32 paris kernel: Fatal trap 12: page fault while in kernel mod= e=20 Dec 9 18:42:32 paris kernel: fault virtual address =3D 0x30=20 Dec 9 18:42:32 paris kernel: fault code =3D supervisor writ= e, pag\ e not present=20 Dec 9 18:42:32 paris kernel: instruction pointer =3D 0x8:0xc07b01f2= =20 Dec 9 18:42:32 paris kernel: stack pointer =3D 0x10:0xd5428c10= =20 Dec 9 18:42:32 paris kernel: frame pointer =3D 0x10:0xd5428c14= =20 Dec 9 18:42:32 paris kernel: code segment =3D base 0x0, limit= 0xfff\ ff, type 0x1b=20 Dec 9 18:42:32 paris kernel: =3D DPL 0, pres 1, def32 1, gran 1=20 Dec 9 18:42:32 paris kernel: processor eflags =3D interrupt enabled, resu= me, IO\ PL =3D 0=20 Dec 9 18:42:32 paris kernel: current process =3D 38 (cbb1)=20 Dec 9 18:42:32 paris kernel: trap number =3D 12=20 Dec 9 18:42:32 paris kernel: panic: page fault=20 Dec 9 18:42:32 paris kernel: Uptime: 35s=20 Dec 9 18:42:32 paris kernel: Cannot dump. No dump device defined.=20 Dec 9 18:42:32 paris kernel: Automatic reboot in 15 seconds - press a key = on t\ he console to abort=20 Any ideas How I can fix this? The suggested sysctl,=20 hw.pci.allow_unsupported_io_range, does not seem to exist in the kernel. Josef --=20 Josef Grosch | Another day closer to a | FreeBSD 5.4 jgrosch@MooseRiver.com | Micro$oft free world | Berkeley, Ca. --YiEDa0DAkWCtVeE4 Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- iD8DBQFDnQgVy8prLS1GYSERArElAKCDyVQQiY9RPjrJzdeLZDoCnqE0ZACfXpDq 1u5+JLQYH3KS2dL8spcgW/A= =NYDc -----END PGP SIGNATURE----- --YiEDa0DAkWCtVeE4-- From owner-freebsd-hackers@FreeBSD.ORG Mon Dec 12 05:20:57 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id EC82516A41F for ; Mon, 12 Dec 2005 05:20:57 +0000 (GMT) (envelope-from nsrashmi@gmail.com) Received: from zproxy.gmail.com (zproxy.gmail.com [64.233.162.202]) by mx1.FreeBSD.org (Postfix) with ESMTP id 363A443D58 for ; Mon, 12 Dec 2005 05:20:57 +0000 (GMT) (envelope-from nsrashmi@gmail.com) Received: by zproxy.gmail.com with SMTP id j2so1333700nzf for ; Sun, 11 Dec 2005 21:20:56 -0800 (PST) DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=beta; d=gmail.com; h=received:message-id:date:from:to:subject:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; b=fQDTIAeIwYXZazwgwsezqKGMVglcbLcblszwjggtq5ldX3rWB8Xqkdgivc4txBaiFTx8C3wbU+ba7ZqEpEMGYD4V3E+V2NgoBpy1Lc+Td3sF7Ol4XutrAm60p14EajMqtzNkeJz/MuLuuvgqD/Smz5AdQTdxWmABwWZG9nw3KR8= Received: by 10.64.253.17 with SMTP id a17mr5400840qbi; Sun, 11 Dec 2005 21:20:56 -0800 (PST) Received: by 10.64.204.16 with HTTP; Sun, 11 Dec 2005 21:20:56 -0800 (PST) Message-ID: <9f9993160512112120g42121d74pb9339971f0b89a61@mail.gmail.com> Date: Mon, 12 Dec 2005 10:50:56 +0530 From: rashmi ns To: freebsd-hackers@freebsd.org, freebsd-drivers@freebsd.org In-Reply-To: <9f9993160512112003i56f25cd6t78533717fec580d1@mail.gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Content-Disposition: inline References: <9f9993160512112003i56f25cd6t78533717fec580d1@mail.gmail.com> Cc: Subject: Re: Help Reqd: "uiomove" transferring zero bytes from user-kernel space X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 12 Dec 2005 05:20:58 -0000 Sorry , uiomove does not written no of bytes copied from user_space to kernel space or from kernel space to userspace .My understanding was wrong . uiomove returns 0 on success . Regards, Rashmi On 12/12/05, rashmi ns wrote: > Hello Team, > when i use "uiomove" in the character device > interface the no of bytes transfrerred between kernel and userspace is > zero .but the actual data transferred when trraced through > "uio->resid" is correct .can any one explain why this is happening ? > > /*Character Device Interfaces*/ > static struct cdevsw hdlc_cdevsw =3D { > > .d_maj =3D CDEV_MAJOR, > .d_open =3D hdlc_open, > .d_read =3D hdlc_read, > .d_write =3D hdlc_write, > .d_ioctl =3D hdlc_ioctl, > .d_close =3D hdlc_close, > .d_version =3D D_VERSION, > }; > static int hdlc_write(dev_t dev, struct uio *uio, int ioflag) > { > int towrite,written; /*char device inf*/ > written=3Duiomove((void *)write_tx_buffer,towrite,uio); > uprintf("uio->resid=3D%d",uio->uio_resid); > uprintf("No of bytes written =3D%d",written); > > > > > } > > Thanks and Regards, > Rashmi.N.S > From owner-freebsd-hackers@FreeBSD.ORG Mon Dec 12 08:42:25 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 6F1C416A41F for ; Mon, 12 Dec 2005 08:42:25 +0000 (GMT) (envelope-from ced@grumly.eu.org) Received: from spike.grumly.eu.org (spike.grumly.eu.org [195.5.253.226]) by mx1.FreeBSD.org (Postfix) with ESMTP id DC05143D70 for ; Mon, 12 Dec 2005 08:42:19 +0000 (GMT) (envelope-from ced@grumly.eu.org) Received: by spike.grumly.eu.org (Postfix, from userid 1001) id A0DFA11593; Mon, 12 Dec 2005 09:39:30 +0100 (CET) Date: Mon, 12 Dec 2005 09:39:30 +0100 From: Cedric Tabary To: freebsd-hackers@freebsd.org Message-ID: <20051212083930.GC91837@efrei.fr> Mime-Version: 1.0 Content-Type: text/plain; charset=iso-8859-15 Content-Disposition: inline Content-Transfer-Encoding: 8bit Subject: mmap() sendfile() X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 12 Dec 2005 08:42:25 -0000 I was looking at the freebsd port of thttpd and i saw this patch : /usr/ports/www/thttpd/files/patch-mmc.c This is some sort of file cache, it works by mmap()ing some files and keeping the mmap address in a hashtable. I suppose this is used to keep the file in memory until munmap() is called. The patch is just removing the mmap() and keeping file descriptors open for use by sendfile(). But I don't know if replacing the mmap() by sendfile() has the same cache effect ?! Keeping the file descriptor open after using sendfile() will keep the file in memory ?? If it is true, doing a sendfile() on some very big files (even if not keeping the descriptor open after) will kill the cache ? Please help me to understand why this patch ? and the difference between sendfile() and mmap() at the memory or cache level.. Cédric From owner-freebsd-hackers@FreeBSD.ORG Mon Dec 12 09:40:11 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id BE07516A45C for ; Mon, 12 Dec 2005 09:40:11 +0000 (GMT) (envelope-from ilovefd@topaz.plala.or.jp) Received: from mvs5.plala.or.jp (c158133.vh.plala.or.jp [210.150.158.133]) by mx1.FreeBSD.org (Postfix) with ESMTP id 246A843D4C for ; Mon, 12 Dec 2005 09:40:10 +0000 (GMT) (envelope-from ilovefd@topaz.plala.or.jp) Received: from ilovefd533 ([150.29.122.91]) by mvs5.plala.or.jp with SMTP id <20051212094009.JQUT5652.mvs5.plala.or.jp@ilovefd533> for ; Mon, 12 Dec 2005 18:40:09 +0900 Message-ID: <020f01c5feff$ec8211f0$1400a8c0@ilovefd533> From: "gama" To: References: <200512071240.jB7CexvJ025961@peedub.jennejohn.org> Date: Mon, 12 Dec 2005 18:39:03 +0900 MIME-Version: 1.0 Content-Type: text/plain; charset="ISO-8859-1" Content-Transfer-Encoding: 7bit X-Priority: 3 X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook Express 6.00.2800.1506 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1506 Subject: Re: /usr/ports/sysutils/sge is broken ? for amd 64 X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 12 Dec 2005 09:40:12 -0000 Thank you for good advises. I could go ahead. But, now , my installation of sge for amd64 is stopped due to unkown reasons anyone could install sge for amd64? My message is like belows ---------------------------------------------------------------------------- ----------------------------- if [ -s /usr/ports/java/jdk15/work/control/build/bsd-amd64/tmp/java/java.lang/java/. classes.list ] ; \ then /usr/local/linux-sun-jdk1.4.2/bin/javac -J-Xbootclasspath/p:../../sun/javac/ javac/gjc.jar -Xbootclasspath/p:../../sun/javac/javac/collect.jar -target jsr14 -J-Xmx128m -classpath /usr/ports/java/jdk15/work/control/build/bsd-amd64/classes -bootclasspath "/usr/ports/java/jdk15/work/control/build/bsd-amd64/lib/jce.jar:/usr/ports/j ava/jdk15/work/control/build/bsd-amd64/lib/jsse.jar" -sourcepath "/usr/ports/java/jdk15/work/control/build/bsd-amd64/gensrc:../../../src/sola ris/classes:../../../src/share/classes" -d /usr/ports/java/jdk15/work/control/build/bsd-amd64/classes -encoding cii -source 1.5 -source 1.5 -target 1.5 -encoding ascii \ ../../../src/share/classes/java/lang/Object.java ../../../src/share/classes/java/lang/Class.java ../../../src/share/classes/java/lang/Thread.java ../../../src/share/classes/java/lang/Character.java ../../../src/share/classes/sun/misc/ASCIICaseInsensitiveComparator.java ../../../src/share/classes/sun/misc/VM.java ../../../src/share/classes/sun/misc/Signal.java ../../../src/share/classes/sun/misc/NativeSignalHandler.java ../../../src/share/classes/java/lang/ThreadGroup.java ../../../src/share/classes/java/lang/ThreadLocal.java ../../../src/share/classes/java/lang/InheritableThreadLocal.java ../../../src/share/classes/java/lang/String.java ../../../src/share/classes/java/lang/ConditionalSpecialCasing.java ../../../src/share/classes/java/lang/StringCoding.java ../../../src/share/classes/java/lang/StringBuffer.java ../../../src/share/classes/java/lang/StringBuilder.java ../../../src/share/classes/java/lang/SuppressWarnings.java ../../../src/share/classes/java/lang/AbstractStringBuilder.java ../../../src/share/classes/java/lang/ClassLoader.java ../../../src/share/classes/java/lang/AssertionStatusDirectives.java ../../../src/share/classes/java/lang/Enum.java ../../../src/share/classes/java/lang/StrictMath.java ../../../src/share/classes/java/lang/Math.java ../../../src/share/classes/sun/misc/FloatingDecimal.java ../../../src/share/classes/sun/misc/FormattedFloatingDecimal.java ../../../src/share/classes/java/lang/Number.java ../../../src/share/classes/java/lang/Byte.java ../../../src/share/classes/java/lang/Short.java ../../../src/share/classes/java/lang/Integer.java ../../../src/share/classes/java/lang/Long.java ../../../src/share/classes/java/lang/Float.java ../../../src/share/classes/java/lang/Double.java ../../../src/share/classes/java/lang/Boolean.java ../../../src/share/classes/java/lang/Void.java ../../../src/share/classes/java/lang/Runnable.java ../../../src/share/classes/java/lang/Cloneable.java ../../../src/share/classes/java/lang/CharSequence.java ../../../src/share/classes/java/lang/SecurityManager.java ../../../src/share/classes/java/lang/Runtime.java ../../../src/share/classes/java/lang/RuntimePermission.java ../../../src/share/classes/java/lang/Shutdown.java ../../../src/solaris/classes/java/lang/Terminator.java ../../../src/share/classes/java/lang/System.java ../../../src/share/classes/java/lang/Compiler.java ../../../src/share/classes/java/lang/Throwable.java ../../../src/share/classes/java/lang/Exception.java ../../../src/share/classes/java/lang/IllegalAccessException.java ../../../src/share/classes/java/lang/InstantiationException.java ../../../src/share/classes/java/lang/ClassNotFoundException.java ../../../src/share/classes/java/lang/CloneNotSupportedException.java ../../../src/share/classes/java/lang/InterruptedException.java ../../../src/share/classes/java/lang/NoSuchFieldException.java ../../../src/share/classes/java/lang/NoSuchMethodException.java ../../../src/share/classes/java/lang/RuntimeException.java ../../../src/share/classes/java/lang/ArithmeticException.java ../../../src/share/classes/java/lang/ArrayStoreException.java ../../../src/share/classes/java/lang/ClassCastException.java ../../../src/share/classes/java/lang/IndexOutOfBoundsException.java ../../../src/share/classes/java/lang/ArrayIndexOutOfBoundsException.java ../../../src/share/classes/java/lang/StringIndexOutOfBoundsException.java ../../../src/share/classes/java/lang/NegativeArraySizeException.java ../../../src/share/classes/java/lang/NullPointerException.java ../../../src/share/classes/java/lang/IllegalStateException.java ../../../src/share/classes/java/lang/IllegalArgumentException.java ../../../src/share/classes/java/lang/NumberFormatException.java ../../../src/share/classes/java/lang/IllegalThreadStateException.java ../../../src/share/classes/java/lang/IllegalMonitorStateException.java ../../../src/share/classes/java/lang/SecurityException.java ../../../src/share/classes/java/lang/TypeNotPresentException.java ../../../src/share/classes/java/lang/EnumConstantNotPresentException.java ../../../src/share/classes/java/lang/UnsupportedOperationException.java ../../../src/share/classes/java/lang/Error.java ../../../src/share/classes/java/lang/AssertionError.java ../../../src/share/classes/java/lang/ThreadDeath.java ../../../src/share/classes/java/lang/LinkageError.java ../../../src/share/classes/java/lang/ClassCircularityError.java ../../../src/share/classes/java/lang/ClassFormatError.java ../../../src/share/classes/java/lang/UnsupportedClassVersionError.java ../../../src/share/classes/java/lang/ExceptionInInitializerError.java ../../../src/share/classes/java/lang/IncompatibleClassChangeError.java ../../../src/share/classes/java/lang/AbstractMethodError.java ../../../src/share/classes/java/lang/IllegalAccessError.java ../../../src/share/classes/java/lang/InstantiationError.java ../../../src/share/classes/java/lang/NoSuchFieldError.java ../../../src/share/classes/java/lang/NoSuchMethodError.java ../../../src/share/classes/java/lang/NoClassDefFoundError.java ../../../src/share/classes/java/lang/UnsatisfiedLinkError.java ../../../src/share/classes/java/lang/VerifyError.java ../../../src/share/classes/java/lang/VirtualMachineError.java ../../../src/share/classes/java/lang/InternalError.java ../../../src/share/classes/java/lang/OutOfMemoryError.java ../../../src/share/classes/java/lang/StackOverflowError.java ../../../src/share/classes/java/lang/UnknownError.java ../../../src/share/classes/java/lang/StackTraceElement.java ../../../src/share/classes/java/lang/Package.java ../../../src/share/classes/java/lang/Process.java ../../../src/share/classes/java/lang/ProcessBuilder.java ../../../src/solaris/classes/java/lang/ProcessEnvironment.java ../../../src/solaris/classes/java/lang/ProcessImpl.java ../../../src/share/classes/java/lang/Appendable.java ../../../src/share/classes/java/lang/Comparable.java ../../../src/share/classes/java/lang/Readable.java ../../../src/share/classes/java/lang/Override.java ../../../src/share/classes/java/lang/ref/Reference.java ../../../src/share/classes/java/lang/ref/SoftReference.java ../../../src/share/classes/java/lang/ref/WeakReference.java ../../../src/share/classes/java/lang/ref/FinalReference.java ../../../src/share/classes/java/lang/ref/PhantomReference.java ../../../src/share/classes/java/lang/ref/ReferenceQueue.java ../../../src/share/classes/java/lang/ref/Finalizer.java ../../../src/share/classes/java/util/BitSet.java ../../../src/share/classes/java/util/Calendar.java ../../../src/share/classes/java/util/GregorianCalendar.java ../../../src/share/classes/sun/util/BuddhistCalendar.java ../../../src/share/classes/sun/util/calendar/CalendarDate.java ../../../src/share/classes/sun/util/calendar/CalendarSystem.java ../../../src/share/classes/sun/util/calendar/CalendarUtils.java ../../../src/share/classes/sun/util/calendar/AbstractCalendar.java ../../../src/share/classes/sun/util/calendar/BaseCalendar.java ../../../src/share/classes/sun/util/calendar/Era.java ../../../src/share/classes/sun/util/calendar/Gregorian.java ../../../src/share/classes/sun/util/calendar/JulianCalendar.java ../../../src/share/classes/java/util/Currency.java /usr/ports/java/jdk15/work/control/build/bsd-amd64/gensrc/java/util/Currency Data.java ../../../src/share/classes/java/util/Date.java ../../../src/share/classes/java/util/Dictionary.java ../../../src/share/classes/java/util/EmptyStackException.java ../../../src/share/classes/java/util/Enumeration.java ../../../src/share/classes/java/util/EventListener.java ../../../src/share/classes/java/util/EventListenerProxy.java ../../../src/share/classes/java/util/EventObject.java ../../../src/share/classes/java/util/Formatter.java ../../../src/share/classes/java/util/Formattable.java ../../../src/share/classes/java/util/FormattableFlags.java ../../../src/share/classes/java/util/IllegalFormatException.java ../../../src/share/classes/java/util/DuplicateFormatFlagsException.java ../../../src/share/classes/java/util/FormatFlagsConversionMismatchException. java ../../../src/share/classes/java/util/IllegalFormatCodePointException.java ../../../src/share/classes/java/util/IllegalFormatConversionException.java ../../../src/share/classes/java/util/IllegalFormatFlagsException.java ../../../src/share/classes/java/util/IllegalFormatPrecisionException.java ../../../src/share/classes/java/util/IllegalFormatWidthException.java ../../../src/share/classes/java/util/MissingFormatArgumentException.java ../../../src/share/classes/java/util/MissingFormatWidthException.java ../../../src/share/classes/java/util/UnknownFormatConversionException.java ../../../src/share/classes/java/util/UnknownFormatFlagsException.java ../../../src/share/classes/java/util/FormatterClosedException.java ../../../src/share/classes/java/util/ListResourceBundle.java ../../../src/share/classes/java/util/Locale.java ../../../src/share/classes/java/util/MissingResourceException.java ../../../src/share/classes/java/util/NoSuchElementException.java ../../../src/share/classes/java/util/Observable.java ../../../src/share/classes/java/util/Observer.java ../../../src/share/classes/java/util/Properties.java ../../../src/share/classes/java/util/XMLUtils.java ../../../src/share/classes/java/util/InvalidPropertiesFormatException.java ../../../src/share/classes/java/util/PropertyPermission.java ../../../src/share/classes/java/util/PropertyResourceBundle.java ../../../src/share/classes/java/util/Random.java ../../../src/share/classes/java/util/ResourceBundle.java ../../../src/share/classes/java/util/ResourceBundleEnumeration.java ../../../src/share/classes/java/util/Scanner.java ../../../src/share/classes/java/util/InputMismatchException.java ../../../src/share/classes/java/util/Stack.java ../../../src/share/classes/java/util/StringTokenizer.java ../../../src/share/classes/java/util/TimeZone.java ../../../src/share/classes/java/util/SimpleTimeZone.java ../../../src/share/classes/sun/util/calendar/ZoneInfo.java ../../../src/share/classes/sun/util/calendar/ZoneInfoFile.java ../../../src/share/classes/java/util/TooManyListenersException.java ../../../src/share/classes/java/util/Comparator.java ../../../src/share/classes/java/util/Collections.java ../../../src/share/classes/java/util/Iterator.java ../../../src/share/classes/java/util/ListIterator.java ../../../src/share/classes/java/util/Collection.java ../../../src/share/classes/java/util/Set.java ../../../src/share/classes/java/util/SortedSet.java ../../../src/share/classes/java/util/List.java ../../../src/share/classes/java/util/Queue.java ../../../src/share/classes/java/util/AbstractCollection.java ../../../src/share/classes/java/util/AbstractSet.java ../../../src/share/classes/java/util/HashSet.java ../../../src/share/classes/java/util/LinkedHashSet.java ../../../src/share/classes/java/util/TreeSet.java ../../../src/share/classes/java/util/EnumSet.java ../../../src/share/classes/java/util/RegularEnumSet.java ../../../src/share/classes/java/util/JumboEnumSet.java ../../../src/share/classes/java/util/AbstractList.java ../../../src/share/classes/java/util/ArrayList.java ../../../src/share/classes/java/util/Vector.java ../../../src/share/classes/java/util/AbstractSequentialList.java ../../../src/share/classes/java/util/LinkedList.java ../../../src/share/classes/java/util/AbstractQueue.java ../../../src/share/classes/java/util/PriorityQueue.java ../../../src/share/classes/java/util/Map.java ../../../src/share/classes/java/util/SortedMap.java ../../../src/share/classes/java/util/AbstractMap.java ../../../src/share/classes/java/util/HashMap.java ../../../src/share/classes/java/util/LinkedHashMap.java ../../../src/share/classes/java/util/TreeMap.java ../../../src/share/classes/java/util/Hashtable.java ../../../src/share/classes/java/util/WeakHashMap.java ../../../src/share/classes/java/util/IdentityHashMap.java ../../../src/share/classes/java/util/EnumMap.java ../../../src/share/classes/java/util/Arrays.java ../../../src/share/classes/java/util/ConcurrentModificationException.java ../../../src/share/classes/java/util/Timer.java ../../../src/share/classes/java/util/TimerTask.java ../../../src/share/classes/java/util/UUID.java ../../../src/share/classes/java/util/concurrent/AbstractExecutorService.java ../../../src/share/classes/java/util/concurrent/ArrayBlockingQueue.java ../../../src/share/classes/java/util/concurrent/BlockingQueue.java ../../../src/share/classes/java/util/concurrent/BrokenBarrierException.java ../../../src/share/classes/java/util/concurrent/Callable.java ../../../src/share/classes/java/util/concurrent/CancellationException.java ../../../src/share/classes/java/util/concurrent/CompletionService.java ../../../src/share/classes/java/util/concurrent/ConcurrentHashMap.java ../../../src/share/classes/java/util/concurrent/ConcurrentLinkedQueue.java ../../../src/share/classes/java/util/concurrent/ConcurrentMap.java ../../../src/share/classes/java/util/concurrent/CopyOnWriteArrayList.java ../../../src/share/classes/java/util/concurrent/CopyOnWriteArraySet.java ../../../src/share/classes/java/util/concurrent/CountDownLatch.java ../../../src/share/classes/java/util/concurrent/CyclicBarrier.java ../../../src/share/classes/java/util/concurrent/DelayQueue.java ../../../src/share/classes/java/util/concurrent/Delayed.java ../../../src/share/classes/java/util/concurrent/Exchanger.java ../../../src/share/classes/java/util/concurrent/ExecutionException.java ../../../src/share/classes/java/util/concurrent/Executor.java ../../../src/share/classes/java/util/concurrent/ExecutorService.java ../../../src/share/classes/java/util/concurrent/ExecutorCompletionService.ja va ../../../src/share/classes/java/util/concurrent/Executors.java ../../../src/share/classes/java/util/concurrent/Future.java ../../../src/share/classes/java/util/concurrent/FutureTask.java ../../../src/share/classes/java/util/concurrent/LinkedBlockingQueue.java ../../../src/share/classes/java/util/concurrent/PriorityBlockingQueue.java ../../../src/share/classes/java/util/concurrent/RejectedExecutionException.j ava ../../../src/share/classes/java/util/concurrent/RejectedExecutionHandler.jav a ../../../src/share/classes/java/util/concurrent/ScheduledExecutorService.jav a ../../../src/share/classes/java/util/concurrent/ScheduledFuture.java ../../../src/share/classes/java/util/concurrent/ScheduledThreadPoolExecutor. java ../../../src/share/classes/java/util/concurrent/Semaphore.java ../../../src/share/classes/java/util/concurrent/SynchronousQueue.java ../../../src/share/classes/java/util/concurrent/ThreadFactory.java ../../../src/share/classes/java/util/concurrent/ThreadPoolExecutor.java ../../../src/share/classes/java/util/concurrent/TimeUnit.java ../../../src/share/classes/java/util/concurrent/TimeoutException.java ../../../src/share/classes/java/util/concurrent/atomic/AtomicBoolean.java ../../../src/share/classes/java/util/concurrent/atomic/AtomicInteger.java ../../../src/share/classes/java/util/concurrent/atomic/AtomicIntegerArray.ja va ../../../src/share/classes/java/util/concurrent/atomic/AtomicIntegerFieldUpd ater.java ../../../src/share/classes/java/util/concurrent/atomic/AtomicLong.java ../../../src/share/classes/java/util/concurrent/atomic/AtomicLongArray.java ../../../src/share/classes/java/util/concurrent/atomic/AtomicLongFieldUpdate r.java ../../../src/share/classes/java/util/concurrent/atomic/AtomicMarkableReferen ce.java ../../../src/share/classes/java/util/concurrent/atomic/AtomicReference.java ../../../src/share/classes/java/util/concurrent/atomic/AtomicReferenceArray. java ../../../src/share/classes/java/util/concurrent/atomic/AtomicReferenceFieldU pdater.java ../../../src/share/classes/java/util/concurrent/atomic/AtomicStampedReferenc e.java ../../../src/share/classes/java/util/concurrent/locks/AbstractQueuedSynchron izer.java ../../../src/share/classes/java/util/concurrent/locks/Condition.java ../../../src/share/classes/java/util/concurrent/locks/Lock.java ../../../src/share/classes/java/util/concurrent/locks/LockSupport.java ../../../src/share/classes/java/util/concurrent/locks/ReadWriteLock.java ../../../src/share/classes/java/util/concurrent/locks/ReentrantLock.java ../../../src/share/classes/java/util/concurrent/locks/ReentrantReadWriteLock .java ../../../src/share/classes/java/util/regex/Pattern.java ../../../src/share/classes/java/util/regex/Matcher.java ../../../src/share/classes/java/util/regex/MatchResult.java ../../../src/share/classes/java/util/regex/ASCII.java ../../../src/share/classes/java/util/regex/PatternSyntaxException.java ../../../src/share/classes/java/util/prefs/Preferences.java ../../../src/share/classes/java/util/prefs/AbstractPreferences.java ../../../src/share/classes/java/util/prefs/PreferenceChangeEvent.java ../../../src/share/classes/java/util/prefs/PreferenceChangeListener.java ../../../src/share/classes/java/util/prefs/NodeChangeEvent.java ../../../src/share/classes/java/util/prefs/NodeChangeListener.java ../../../src/share/classes/java/util/prefs/BackingStoreException.java ../../../src/share/classes/java/util/prefs/InvalidPreferencesFormatException .java ../../../src/share/classes/java/util/prefs/PreferencesFactory.java ../../../src/share/classes/java/util/prefs/Base64.java ../../../src/share/classes/java/util/prefs/XmlSupport.java ../../../src/share/classes/java/io/Closeable.java ../../../src/share/classes/java/io/Flushable.java ../../../src/share/classes/java/io/PipedInputStream.java ../../../src/share/classes/java/io/PipedOutputStream.java ../../../src/share/classes/java/io/IOException.java ../../../src/share/classes/java/io/CharConversionException.java ../../../src/share/classes/java/io/FileNotFoundException.java ../../../src/share/classes/java/io/EOFException.java ../../../src/share/classes/java/io/SyncFailedException.java ../../../src/share/classes/java/io/UTFDataFormatException.java ../../../src/share/classes/java/io/InterruptedIOException.java ../../../src/share/classes/java/io/UnsupportedEncodingException.java ../../../src/share/classes/java/io/DataInput.java ../../../src/share/classes/java/io/DataOutput.java ../../../src/share/classes/java/io/InputStream.java ../../../src/share/classes/java/io/FileInputStream.java ../../../src/share/classes/java/io/FilterInputStream.java ../../../src/share/classes/java/io/BufferedInputStream.java ../../../src/share/classes/java/io/DataInputStream.java ../../../src/share/classes/java/io/ByteArrayInputStream.java ../../../src/share/classes/java/io/PushbackInputStream.java ../../../src/share/classes/java/io/SequenceInputStream.java ../../../src/share/classes/java/io/StringBufferInputStream.java ../../../src/share/classes/java/io/LineNumberInputStream.java ../../../src/share/classes/java/io/OutputStream.java ../../../src/share/classes/java/io/FileOutputStream.java ../../../src/share/classes/java/io/FilterOutputStream.java ../../../src/share/classes/java/io/BufferedOutputStream.java ../../../src/share/classes/java/io/DataOutputStream.java ../../../src/share/classes/java/io/ByteArrayOutputStream.java ../../../src/share/classes/java/io/PrintStream.java ../../../src/share/classes/java/io/RandomAccessFile.java ../../../src/share/classes/java/io/StreamTokenizer.java ../../../src/share/classes/java/io/File.java ../../../src/share/classes/java/io/FileSystem.java ../../../src/solaris/classes/java/io/FileDescriptor.java ../../../src/share/classes/java/io/FilenameFilter.java ../../../src/share/classes/java/io/FileFilter.java ../../../src/share/classes/java/io/FilePermission.java ../../../src/share/classes/java/io/Serializable.java ../../../src/share/classes/java/io/Externalizable.java ../../../src/share/classes/java/io/Bits.java ../../../src/share/classes/java/io/ObjectInput.java ../../../src/share/classes/java/io/ObjectInputStream.java ../../../src/share/classes/java/io/ObjectInputValidation.java ../../../src/share/classes/java/io/ObjectOutput.java ../../../src/share/classes/java/io/ObjectOutputStream.java ../../../src/share/classes/java/io/ObjectStreamClass.java ../../../src/share/classes/java/io/ObjectStreamConstants.java ../../../src/share/classes/java/io/ObjectStreamField.java ../../../src/share/classes/java/io/SerializablePermission.java ../../../src/share/classes/java/io/InvalidClassException.java ../../../src/share/classes/java/io/InvalidObjectException.java ../../../src/share/classes/java/io/NotActiveException.java ../../../src/share/classes/java/io/NotSerializableException.java ../../../src/share/classes/java/io/ObjectStreamException.java ../../../src/share/classes/java/io/OptionalDataException.java ../../../src/share/classes/java/io/StreamCorruptedException.java ../../../src/share/classes/java/io/WriteAbortedException.java ../../../src/share/classes/java/io/Reader.java ../../../src/share/classes/java/io/BufferedReader.java ../../../src/share/classes/java/io/LineNumberReader.java ../../../src/share/classes/java/io/CharArrayReader.java ../../../src/share/classes/java/io/FilterReader.java ../../../src/share/classes/java/io/PushbackReader.java ../../../src/share/classes/java/io/InputStreamReader.java ../../../src/share/classes/java/io/FileReader.java ../../../src/share/classes/java/io/PipedReader.java ../../../src/share/classes/java/io/StringReader.java ../../../src/share/classes/java/io/Writer.java ../../../src/share/classes/java/io/BufferedWriter.java ../../../src/share/classes/java/io/PrintWriter.java ../../../src/share/classes/java/io/CharArrayWriter.java ../../../src/share/classes/java/io/FilterWriter.java ../../../src/share/classes/java/io/OutputStreamWriter.java ../../../src/share/classes/java/io/FileWriter.java ../../../src/share/classes/java/io/PipedWriter.java ../../../src/share/classes/java/io/StringWriter.java ../../../src/share/classes/java/io/ExpiringCache.java ../../../src/share/classes/java/nio/charset/Charset.java /usr/ports/java/jdk15/work/control/build/bsd-amd64/gensrc/java/nio/charset/C harsetDecoder.java /usr/ports/java/jdk15/work/control/build/bsd-amd64/gensrc/java/nio/charset/C harsetEncoder.java ../../../src/share/classes/java/nio/charset/UnmappableCharacterException.jav a ../../../src/share/classes/java/nio/Bits.java /usr/ports/java/jdk15/work/control/build/bsd-amd64/gensrc/java/nio/DirectByt eBuffer.java /usr/ports/java/jdk15/work/control/build/bsd-amd64/gensrc/java/nio/HeapByteB uffer.java /usr/ports/java/jdk15/work/control/build/bsd-amd64/gensrc/java/nio/HeapCharB uffer.java ../../../src/share/classes/java/security/AccessController.java ../../../src/share/classes/java/security/ProtectionDomain.java ../../../src/share/classes/java/net/URLClassLoader.java ../../../src/share/classes/java/net/URLConnection.java ../../../src/share/classes/sun/misc/Launcher.java /usr/ports/java/jdk15/work/control/build/bsd-amd64/gensrc/sun/misc/Version.j ava ../../../src/share/classes/sun/net/www/protocol/jar/Handler.java ../../../src/share/classes/sun/net/www/protocol/jar/JarURLConnection.java ../../../src/solaris/classes/sun/net/www/protocol/file/Handler.java ../../../src/share/classes/sun/net/www/protocol/file/FileURLConnection.java ../../../src/solaris/classes/sun/misc/FileURLMapper.java ../../../src/share/classes/sun/misc/MessageUtils.java ../../../src/share/classes/sun/misc/GC.java ../../../src/share/classes/sun/misc/Service.java ../../../src/share/classes/sun/misc/JavaLangAccess.java /usr/ports/java/jdk15/work/control/build/bsd-amd64/gensrc/java/lang/UNIXProc ess.java ../../../src/solaris/classes/java/io/UnixFileSystem.java ../../../src/solaris/classes/java/util/prefs/FileSystemPreferences.java ../../../src/solaris/classes/java/util/prefs/FileSystemPreferencesFactory.ja va ../../../src/share/classes/java/lang/reflect/AccessibleObject.java ../../../src/share/classes/java/lang/reflect/Field.java ../../../src/share/classes/java/lang/reflect/Method.java ../../../src/share/classes/java/lang/reflect/Constructor.java ../../../src/share/classes/java/lang/reflect/InvocationTargetException.java ../../../src/share/classes/java/lang/reflect/Array.java ../../../src/share/classes/java/lang/reflect/Proxy.java ../../../src/share/classes/sun/io/ByteToCharConverter.java ../../../src/share/classes/sun/io/CharToByteConverter.java ../../../src/share/classes/sun/misc/AtomicLong.java ../../../src/share/classes/sun/misc/AtomicLongCSImpl.java ../../../src/share/classes/sun/misc/AtomicLongLockImpl.java ../../../src/share/classes/sun/reflect/ConstantPool.java ../../../src/share/classes/sun/reflect/NativeConstructorAccessorImpl.java ../../../src/share/classes/sun/reflect/NativeMethodAccessorImpl.java ../../../src/share/classes/sun/reflect/Reflection.java ; \ fi execv(): Bad address Error trying to exec /usr/local/linux-sun-jdk1.4.2/bin/javac. Check if file exists and permissions are set correctly. gmake[3]: *** [.compile.classlist] Error 1 gmake[3]: Leaving directory `/usr/ports/java/jdk15/work/j2se/make/java/java' gmake[2]: *** [all] Error 1 gmake[2]: Leaving directory `/usr/ports/java/jdk15/work/j2se/make/java' gmake[1]: *** [all] Error 1 gmake[1]: Leaving directory `/usr/ports/java/jdk15/work/j2se/make' gmake: *** [j2se-build] Error 2 *** Error code 2 Stop in /usr/ports/java/jdk15. *** Error code 1 Stop in /usr/ports/sysutils/sge. ** Command failed [exit code 1]: /usr/bin/script -qa /tmp/portinstall58978.0 make ** Fix the problem and try again. ** Listing the failed packages (*:skipped / !:failed) ! sysutils/sge (unknown build error) ---> Packages processed: 0 done, 0 ignored, 0 skipped and 1 failed pcomp4# . ----- Original Message ----- From: "Gary Jennejohn" To: "gama" Cc: Sent: Wednesday, December 07, 2005 9:40 PM Subject: Re: /usr/ports/sysutils/sge is broken ? for amd 64 > > "gama" writes: > > I am trying to install Sun Grid Engine with FreeBSD5.4/amd64. > > It needs glibc-common-2.3.2-4.80.8.amd64.rpm > > > > glibc-common-2.3.2-4.80.8.i386.rpm can be found in > > ftp://ftp.FreeBSD.org/pub/FreeBSD/ports/distfiles/rpm/i386/8.0/ but amd64. > > > > Where can I get glibc-common-2.3.2-4.80.8.amd64.rpm. > > > > See this URL: > http://lists.freebsd.org/pipermail/freebsd-ports/2005-November/027550.html > > You could have this out for yourself by doing a simple search using e.g. > google. > > --- > Gary Jennejohn / garyjATjennejohnDOTorg gjATfreebsdDOTorg garyjATdenxDOTde > > From owner-freebsd-hackers@FreeBSD.ORG Mon Dec 12 10:17:44 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 99CED16A420 for ; Mon, 12 Dec 2005 10:17:44 +0000 (GMT) (envelope-from tony.uestc@gmail.com) Received: from zproxy.gmail.com (zproxy.gmail.com [64.233.162.204]) by mx1.FreeBSD.org (Postfix) with ESMTP id 0975143D5C for ; Mon, 12 Dec 2005 10:17:39 +0000 (GMT) (envelope-from tony.uestc@gmail.com) Received: by zproxy.gmail.com with SMTP id 9so1336828nzo for ; Mon, 12 Dec 2005 02:17:32 -0800 (PST) DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=beta; d=gmail.com; h=received:message-id:date:from:user-agent:x-accept-language:mime-version:to:subject:content-type; b=hhND81T0+ap+yTiLeVFkPGT2DFIkWx8VlpDW/2hDKkfUTLar3kk2W4Dx7N+QlENAKVJlUiPGZ1wL+gCtEnehVzCiScO+UK6MwD8mrw51te9kvAM8VyzJCuusypJQfo0aF0jJzvrymm+37iXjdlAqzxpjtmIlnD7FOy2W94RpcGQ= Received: by 10.36.108.16 with SMTP id g16mr5769597nzc; Mon, 12 Dec 2005 02:17:32 -0800 (PST) Received: from ?211.83.98.99? ( [220.166.213.4]) by mx.gmail.com with ESMTP id 6sm9224105nzn.2005.12.12.02.17.27; Mon, 12 Dec 2005 02:17:32 -0800 (PST) Message-ID: <439D4D69.6000906@gmail.com> Date: Mon, 12 Dec 2005 18:14:01 +0800 From: Tony User-Agent: Mozilla Thunderbird 1.0.7 (Windows/20050923) X-Accept-Language: en-us, en MIME-Version: 1.0 To: freebsd-hackers@freebsd.org Content-Type: multipart/mixed; boundary="------------000301020408020607010604" Subject: boot FreeBSD from cdrom using grub X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 12 Dec 2005 10:17:44 -0000 This is a multi-part message in MIME format. --------------000301020408020607010604 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Hi, I'm trying to make an iso image that will boot FreeBSD using GRUB boot loader. Grub will boot /boot/loader and the loader will boot /boot/kernel. It goes well on my disk, but when I try to make a livecd, it fails. I spend some time figuring out that loader does not probe cd it self, it depends on boot1 to tell him when cd to boot. So I did some hack on loader. Bellow is the diff: *** sys/boot/i386/loader/main.c.bak Sun Dec 11 19:32:29 2005 --- sys/boot/i386/loader/main.c Sun Dec 11 22:04:29 2005 *************** *** 228,235 **** if ((new_currdev.d_type == biosdisk.dv_type) && ((new_currdev.d_kind.biosdisk.unit = bd_bios2unit(biosdev)) == -1)) { printf("Can't work out which disk we are booting from.\n" ! "Guessed BIOS device 0x%x not found by probes, defaulting to disk0:\n", biosdev); ! new_currdev.d_kind.biosdisk.unit = 0; } env_setenv("currdev", EV_VOLATILE, i386_fmtdev(&new_currdev), i386_setcurrdev, env_nounset); --- 228,238 ---- if ((new_currdev.d_type == biosdisk.dv_type) && ((new_currdev.d_kind.biosdisk.unit = bd_bios2unit(biosdev)) == -1)) { printf("Can't work out which disk we are booting from.\n" ! "Guessed BIOS device 0x%x not found by probes, defaulting to cd0(%d):\n", biosdev, biosdev); ! bc_add(biosdev); ! new_currdev.d_type = bioscd.dv_type; ! new_currdev.d_dev = &bioscd; ! new_currdev.d_kind.bioscd.unit = bc_bios2unit(biosdev); } env_setenv("currdev", EV_VOLATILE, i386_fmtdev(&new_currdev), i386_setcurrdev, env_nounset); Then the kernel starts, but when the kernel try to mount the root fs, it stops. I have the follow line in my /etc/fstab /dev/acd0c / cd9660 ro 0 0 I am stranded. Anyone can help? thx Tony --------------000301020408020607010604 Content-Type: text/plain; name="diff.txt" Content-Transfer-Encoding: 7bit Content-Disposition: inline; filename="diff.txt" *** sys/boot/i386/loader/main.c.bak Sun Dec 11 19:32:29 2005 --- sys/boot/i386/loader/main.c Sun Dec 11 22:04:29 2005 *************** *** 228,235 **** if ((new_currdev.d_type == biosdisk.dv_type) && ((new_currdev.d_kind.biosdisk.unit = bd_bios2unit(biosdev)) == -1)) { printf("Can't work out which disk we are booting from.\n" ! "Guessed BIOS device 0x%x not found by probes, defaulting to disk0:\n", biosdev); ! new_currdev.d_kind.biosdisk.unit = 0; } env_setenv("currdev", EV_VOLATILE, i386_fmtdev(&new_currdev), i386_setcurrdev, env_nounset); --- 228,238 ---- if ((new_currdev.d_type == biosdisk.dv_type) && ((new_currdev.d_kind.biosdisk.unit = bd_bios2unit(biosdev)) == -1)) { printf("Can't work out which disk we are booting from.\n" ! "Guessed BIOS device 0x%x not found by probes, defaulting to cd0(%d):\n", biosdev, biosdev); ! bc_add(biosdev); ! new_currdev.d_type = bioscd.dv_type; ! new_currdev.d_dev = &bioscd; ! new_currdev.d_kind.bioscd.unit = bc_bios2unit(biosdev); } env_setenv("currdev", EV_VOLATILE, i386_fmtdev(&new_currdev), i386_setcurrdev, env_nounset); --------------000301020408020607010604-- From owner-freebsd-hackers@FreeBSD.ORG Mon Dec 12 12:09:47 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 8396416A41F for ; Mon, 12 Dec 2005 12:09:47 +0000 (GMT) (envelope-from simon@comsys.ntu-kpi.kiev.ua) Received: from comsys.ntu-kpi.kiev.ua (comsys.ntu-kpi.kiev.ua [195.245.194.142]) by mx1.FreeBSD.org (Postfix) with ESMTP id 2F79343D53 for ; Mon, 12 Dec 2005 12:09:16 +0000 (GMT) (envelope-from simon@comsys.ntu-kpi.kiev.ua) Received: from pm513-1.comsys.ntu-kpi.kiev.ua (pm513-1.comsys.ntu-kpi.kiev.ua [10.18.52.101]) (authenticated bits=0) by comsys.ntu-kpi.kiev.ua (8.12.10/8.12.10) with ESMTP id jBCCJeVO050226 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=FAIL); Mon, 12 Dec 2005 14:19:40 +0200 (EET) Received: by pm513-1.comsys.ntu-kpi.kiev.ua (Postfix, from userid 1001) id F3CE25C07C; Mon, 12 Dec 2005 14:09:02 +0200 (EET) Date: Mon, 12 Dec 2005 14:09:02 +0200 From: Andrey Simonenko To: Cedric Tabary Message-ID: <20051212120902.GA1143@pm513-1.comsys.ntu-kpi.kiev.ua> References: <20051212083930.GC91837@efrei.fr> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20051212083930.GC91837@efrei.fr> User-Agent: Mutt/1.5.11 X-Virus-Scanned: ClamAV 0.82/1207/Sat Dec 10 00:01:12 2005 on comsys.ntu-kpi.kiev.ua X-Virus-Status: Clean Cc: freebsd-hackers@freebsd.org Subject: Re: mmap() sendfile() X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 12 Dec 2005 12:09:47 -0000 On Mon, Dec 12, 2005 at 09:39:30AM +0100, Cedric Tabary wrote: > > This is some sort of file cache, it works by mmap()ing some files and > keeping the mmap address in a hashtable. I suppose this is used to keep > the file in memory until munmap() is called. I guess this is used for accessing file's data directly (read automatic), without read(2) and write(2) system calls, according to source files if mmap(2) is not supported, then malloc(3) and read(2) are used for reading files (I checked source files very quickly) and write(2) for transferring data to socket. I do not understand why mmap() is called with MAP_PRIVATE and PROT_READ at the same time, because copy-objects are not supported on FreeBSD (probably on other systems too). > The patch is just removing the mmap() and keeping file descriptors open > for use by sendfile(). But I don't know if replacing the mmap() by > sendfile() has the same cache effect ?! The sendfile(2) system call is used for transferring some portion of a file to a stream socket. Since this is a system call and not library function it can implement data transfers from a file to a socket entirely in the kernel, without bringing data to the userspace as in case of read(2) or mmap(2). This technique sometimes is called "zerocopy". > Keeping the file descriptor open after using sendfile() will keep the > file in memory ?? I think no. Owners of files' pages are VM objects, even if a file (really vnode) does not have any reference and hold counter, its vnode will go to the free list, but its VM pages in corresponding VM object will be still in memory, until another pages which have higher priority (according to the logic of VM system) will cause removing of file's pages from the VM cache or until there are not enough free vnodes. Just test it: open file, write something to it, close it and { read it and close it } several times, reboot and read this file again and compare times. > If it is true, doing a sendfile() on some very big files (even if not > keeping the descriptor open after) will kill the cache ? VM system keeps pages in several queues (read classes), so reading big files will not remove frequently used pages (also wired pages cannot be removed from memory). Read corresponding paragraph in FAQ ("What do the various memory states..." and next one). > Please help me to understand why this patch ? and the difference between > sendfile() and mmap() at the memory or cache level.. sendfile(2) will transfer data from a file to a socket entirely in the kernel, without context switching, unlike read(2) which requires context switching and mmap(2) which will require context switching in case of page fault; as I understand VM cache will be used in the same way. As usually correct me if I'm wrong. From owner-freebsd-hackers@FreeBSD.ORG Mon Dec 12 05:31:58 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 95D3D16A41F; Mon, 12 Dec 2005 05:31:58 +0000 (GMT) (envelope-from jgrosch@mooseriver.com) Received: from mooseriver.com (h-66-166-146-73.snvacaid.covad.net [66.166.146.73]) by mx1.FreeBSD.org (Postfix) with ESMTP id E450243D66; Mon, 12 Dec 2005 05:31:57 +0000 (GMT) (envelope-from jgrosch@mooseriver.com) Received: by berkeley.mooseriver.com (Postfix, from userid 200) id 92BF317022; Sun, 11 Dec 2005 21:12:33 -0800 (PST) Date: Sun, 11 Dec 2005 21:12:33 -0800 From: Josef Grosch To: freebsd-questions@freebsd.org Message-ID: <20051212051233.GA19269@mooseriver.com> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="T4sUOijqQbZv57TR" Content-Disposition: inline User-Agent: Mutt/1.4.2.1i Organization: Moose River, LLC X-Mailman-Approved-At: Mon, 12 Dec 2005 12:53:07 +0000 Cc: Subject: Cardbus panics X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: jgrosch@MooseRiver.com List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 12 Dec 2005 05:31:58 -0000 --T4sUOijqQbZv57TR Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable ----- Forwarded message from Josef Grosch ----- Date: Sat, 10 Dec 2005 13:52:43 -0800 From: Josef Grosch To: freebsd-questions@freebsd.org Subject: Cardbus panics I have an IBM T22 thinkpad running FreeBSD 5.4-RELEASE-p8. I have the CardBus devices in the current kernel. When I insert a CardBus device, A Xircom RealPort CardBus Ethernet I get a kernel panic like so; Dec 9 18:42:32 paris kernel: cbb alloc res fail=20 Dec 9 18:42:32 paris kernel: cardbus1: Can't get memory for IO ports=20 Dec 9 18:42:32 paris kernel: dc0: port 0-0x7f = mem \ 0x88000000-0x880007ff,0x88000800-0x88000fff at device 0.0 on cardbus1=20 Dec 9 18:42:32 paris kernel: cbb alloc res fail=20 Dec 9 18:42:32 paris kernel: dc0: couldn't map ports/memory=20 Dec 9 18:42:32 paris kernel: =20 Dec 9 18:42:32 paris kernel: =20 Dec 9 18:42:32 paris kernel: Fatal trap 12: page fault while in kernel mod= e=20 Dec 9 18:42:32 paris kernel: fault virtual address =3D 0x30=20 Dec 9 18:42:32 paris kernel: fault code =3D supervisor writ= e, pag\ e not present=20 Dec 9 18:42:32 paris kernel: instruction pointer =3D 0x8:0xc07b01f2= =20 Dec 9 18:42:32 paris kernel: stack pointer =3D 0x10:0xd5428c10= =20 Dec 9 18:42:32 paris kernel: frame pointer =3D 0x10:0xd5428c14= =20 Dec 9 18:42:32 paris kernel: code segment =3D base 0x0, limit= 0xfff\ ff, type 0x1b=20 Dec 9 18:42:32 paris kernel: =3D DPL 0, pres 1, def32 1, gran 1=20 Dec 9 18:42:32 paris kernel: processor eflags =3D interrupt enabled, resu= me, IO\ PL =3D 0=20 Dec 9 18:42:32 paris kernel: current process =3D 38 (cbb1)=20 Dec 9 18:42:32 paris kernel: trap number =3D 12=20 Dec 9 18:42:32 paris kernel: panic: page fault=20 Dec 9 18:42:32 paris kernel: Uptime: 35s=20 Dec 9 18:42:32 paris kernel: Cannot dump. No dump device defined.=20 Dec 9 18:42:32 paris kernel: Automatic reboot in 15 seconds - press a key = on t\ he console to abort=20 Any ideas How I can fix this? The suggested sysctl,=20 hw.pci.allow_unsupported_io_range, does not seem to exist in the kernel. Josef --=20 Josef Grosch | Another day closer to a | FreeBSD 5.4 jgrosch@MooseRiver.com | Micro$oft free world | Berkeley, Ca. ----- End forwarded message ----- --=20 Josef Grosch | Another day closer to a | FreeBSD 5.4 jgrosch@MooseRiver.com | Micro$oft free world | Berkeley, Ca. --T4sUOijqQbZv57TR Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- iD8DBQFDnQbBy8prLS1GYSERAqi1AJ45yPbo8tIo6oDMmLPcpkL5q/i46wCggIcV tNJV9vI2CRpa3L5P1aoREZ4= =rky2 -----END PGP SIGNATURE----- --T4sUOijqQbZv57TR-- From owner-freebsd-hackers@FreeBSD.ORG Mon Dec 12 13:56:58 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 25CB016A420 for ; Mon, 12 Dec 2005 13:56:58 +0000 (GMT) (envelope-from keramida@ceid.upatras.gr) Received: from aiolos.otenet.gr (aiolos.otenet.gr [195.170.0.93]) by mx1.FreeBSD.org (Postfix) with ESMTP id 0470843D68 for ; Mon, 12 Dec 2005 13:56:55 +0000 (GMT) (envelope-from keramida@ceid.upatras.gr) Received: from flame.pc (aris.bedc.ondsl.gr [62.103.39.226]) by aiolos.otenet.gr (8.13.4/8.13.4/Debian-8) with SMTP id jBCDulr6004335; Mon, 12 Dec 2005 15:56:47 +0200 Received: by flame.pc (Postfix, from userid 1001) id 73A4D115BB; Mon, 12 Dec 2005 15:55:57 +0200 (EET) Date: Mon, 12 Dec 2005 15:55:57 +0200 From: Giorgos Keramidas To: Dan Nelson Message-ID: <20051212135557.GA1893@flame.pc> References: <10939303.1134158545675.JavaMail.root@vms070.mailsrvcs.net> <20051210020643.GA6206@flame.pc> <20051210034629.GI95420@dan.emsphone.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20051210034629.GI95420@dan.emsphone.com> Cc: freebsd-hackers@freebsd.org, babkin@users.sourceforge.net, Divacky Roman Subject: Re: sysctl, HW_PHYSMEM, and crippled gcc X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 12 Dec 2005 13:56:58 -0000 On 2005-12-09 21:46, Dan Nelson wrote: >In the last episode (Dec 10), Giorgos Keramidas said: >>>>On Thu, Dec 08, 2005 at 05:06:16PM -0800, Steve Kargl wrote: >>>>> Anyone have any insight into fixing gcc to make better >>>>> use of system memory on systems with more than 4 GB. >>>>> It appears that libiberty/physmem.c tries to use sysctl() >>>>> to determine the amount of physical memory in a system. >>>>> >>>>> { /* This works on *bsd and darwin. */ >>>>> unsigned int physmem; >>>>> size_t len = sizeof physmem; >>>>> static int mib[2] = { CTL_HW, HW_PHYSMEM }; >>>>> >>>>> if (sysctl (mib, ARRAY_SIZE (mib), &physmem, &len, NULL, 0) == 0 >>>>> && len == sizeof (physmem)) >>>>> return (double) physmem; >>>>> } >>>>> >>>>> This works if you have less than 4GB because of the unsigned >>>>> int physmem. I have 12 GB, which of course, when expanded >>>>> to the number of bytes doesn't fit into a unsigned int physmem. >> >> Can someone with access to a system with more than 4 GB verify that the >> following works correctly? >> >> % flame:/home/keramida/tmp/physmem$ cat -n physmem.c >> % 9 int >> % 10 main(void) >> % 11 { >> % 12 uint64_t physmem; >> % 13 size_t len = sizeof physmem; >> % 14 static int mib[] = { CTL_HW, HW_PHYSMEM }; >> % 15 static size_t miblen = sizeof(mib) / sizeof(mib[0]); >> % 16 >> % 17 if (sysctl(mib, miblen, &physmem, &len, NULL, 0) != 0) >> % 18 err(1, "sysctl hw.physmem"); >> % 19 printf("Physical memory = %ju bytes\n", (intmax_t)physmem); >> % 20 return EXIT_SUCCESS; >> % 21 } > > Won't this break on x86, where physmem is 32 bits? Just use "unsigned > long", which is what the sysctl type is according to kern_mib.c . I'm not sure it breaks, but seeing it just work on a couple of systems doesn't mean much. You're right of course, that the correct type from kern_mib.c is better. Thanks :) From owner-freebsd-hackers@FreeBSD.ORG Mon Dec 12 14:38:35 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 83AE316A41F for ; Mon, 12 Dec 2005 14:38:35 +0000 (GMT) (envelope-from silby@silby.com) Received: from relay01.pair.com (relay01.pair.com [209.68.5.15]) by mx1.FreeBSD.org (Postfix) with SMTP id A6E7843D6A for ; Mon, 12 Dec 2005 14:38:34 +0000 (GMT) (envelope-from silby@silby.com) Received: (qmail 23370 invoked from network); 12 Dec 2005 14:38:33 -0000 Received: from unknown (HELO localhost) (unknown) by unknown with SMTP; 12 Dec 2005 14:38:33 -0000 X-pair-Authenticated: 209.68.2.70 Date: Mon, 12 Dec 2005 08:38:35 -0600 (CST) From: Mike Silbersack To: Cedric Tabary In-Reply-To: <20051212083930.GC91837@efrei.fr> Message-ID: <20051212083537.T78724@odysseus.silby.com> References: <20051212083930.GC91837@efrei.fr> MIME-Version: 1.0 Content-Type: MULTIPART/MIXED; BOUNDARY="0-379007335-1134398315=:78724" Cc: freebsd-hackers@freebsd.org Subject: Re: mmap() sendfile() X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 12 Dec 2005 14:38:35 -0000 This message is in MIME format. The first part should be readable text, while the remaining parts are likely unreadable without MIME-aware tools. --0-379007335-1134398315=:78724 Content-Type: TEXT/PLAIN; charset=iso-8859-15; format=flowed Content-Transfer-Encoding: QUOTED-PRINTABLE On Mon, 12 Dec 2005, Cedric Tabary wrote: > If it is true, doing a sendfile() on some very big files (even if not > keeping the descriptor open after) will kill the cache ? > > Please help me to understand why this patch ? and the difference between > sendfile() and mmap() at the memory or cache level.. > > C=E9dric My memory escapes me on all the details, but there were two potential=20 reasons not to use sendfile with 4.x that no longer apply in 5.x and=20 above: 1. Sendfile used to send small files inefficiently, sending the http=20 headers in one packet and the data in another. I fixed this in 5.x. 2. Alan Cox improved the memory efficiency of sendfile greatly, it now=20 uses a single kernel buffer for all copies of the same block of the same=20 file, whereas the old implementation made an in-kernel copy of each block,= =20 making it no more memory efficient than using mbufs. So, if there was a reason to not use sendfile under 4.x, it's probably not= =20 true anymore. Someone sent me a patch to thttpd which made it more efficient on FreeBSD= =20 a looooooong time ago, I don't recall what changes he had made. Mike "Silby" Silbersack --0-379007335-1134398315=:78724-- From owner-freebsd-hackers@FreeBSD.ORG Mon Dec 12 16:56:06 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 872CE16A422 for ; Mon, 12 Dec 2005 16:56:06 +0000 (GMT) (envelope-from kris@obsecurity.org) Received: from elvis.mu.org (elvis.mu.org [192.203.228.196]) by mx1.FreeBSD.org (Postfix) with ESMTP id DE9A243D5E for ; Mon, 12 Dec 2005 16:56:05 +0000 (GMT) (envelope-from kris@obsecurity.org) Received: from obsecurity.dyndns.org (elvis.mu.org [192.203.228.196]) by elvis.mu.org (Postfix) with ESMTP id CB9BE1A3C1E; Mon, 12 Dec 2005 08:56:05 -0800 (PST) Received: by obsecurity.dyndns.org (Postfix, from userid 1000) id 66C975158E; Mon, 12 Dec 2005 11:56:04 -0500 (EST) Date: Mon, 12 Dec 2005 11:56:04 -0500 From: Kris Kennaway To: gama Message-ID: <20051212165604.GA31477@xor.obsecurity.org> References: <200512071240.jB7CexvJ025961@peedub.jennejohn.org> <020f01c5feff$ec8211f0$1400a8c0@ilovefd533> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="2oS5YaxWCcQjTEyO" Content-Disposition: inline In-Reply-To: <020f01c5feff$ec8211f0$1400a8c0@ilovefd533> User-Agent: Mutt/1.4.2.1i Cc: freebsd-hackers@freebsd.org Subject: Re: /usr/ports/sysutils/sge is broken ? for amd 64 X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 12 Dec 2005 16:56:06 -0000 --2oS5YaxWCcQjTEyO Content-Type: text/plain; charset=us-ascii Content-Disposition: inline On Mon, Dec 12, 2005 at 06:39:03PM +0900, gama wrote: > Thank you for good advises. > I could go ahead. > But, now , my installation of sge for amd64 is stopped due to unkown > reasons > anyone could install sge for amd64? > My message is like belows You still didn't turn off java support like it was suggested. Kris --2oS5YaxWCcQjTEyO Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.2 (FreeBSD) iD8DBQFDnaukWry0BWjoQKURAlt8AKCVJ6RmWBkEwhQv/6ub7+EJfcIClgCgmd66 o4U5+OvFDdrvsQgKad5IaDU= =QbUZ -----END PGP SIGNATURE----- --2oS5YaxWCcQjTEyO-- From owner-freebsd-hackers@FreeBSD.ORG Mon Dec 12 17:23:20 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 639FA16A41F for ; Mon, 12 Dec 2005 17:23:20 +0000 (GMT) (envelope-from ced@grumly.eu.org) Received: from spike.grumly.eu.org (spike.grumly.eu.org [195.5.253.226]) by mx1.FreeBSD.org (Postfix) with ESMTP id 07A7643D55 for ; Mon, 12 Dec 2005 17:23:19 +0000 (GMT) (envelope-from ced@grumly.eu.org) Received: by spike.grumly.eu.org (Postfix, from userid 1001) id 6CE3F1159E; Mon, 12 Dec 2005 18:20:31 +0100 (CET) Date: Mon, 12 Dec 2005 18:20:31 +0100 From: Cedric Tabary To: freebsd-hackers@freebsd.org Message-ID: <20051212172031.GC42322@efrei.fr> References: <20051212083930.GC91837@efrei.fr> <20051212083537.T78724@odysseus.silby.com> Mime-Version: 1.0 Content-Type: text/plain; charset=iso-8859-15 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <20051212083537.T78724@odysseus.silby.com> Subject: Re: mmap() sendfile() X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 12 Dec 2005 17:23:20 -0000 On 12/12/2005 08:38, Mike Silbersack wrote: > On Mon, 12 Dec 2005, Cedric Tabary wrote: > > >If it is true, doing a sendfile() on some very big files (even if not > >keeping the descriptor open after) will kill the cache ? > > > >Please help me to understand why this patch ? and the difference between > >sendfile() and mmap() at the memory or cache level.. > > > >Cédric > > My memory escapes me on all the details, but there were two potential > reasons not to use sendfile with 4.x that no longer apply in 5.x and > above: > > 1. Sendfile used to send small files inefficiently, sending the http > headers in one packet and the data in another. I fixed this in 5.x. > > 2. Alan Cox improved the memory efficiency of sendfile greatly, it now > uses a single kernel buffer for all copies of the same block of the same > file, whereas the old implementation made an in-kernel copy of each block, > making it no more memory efficient than using mbufs. What about using sendfile() or mmap() on NFS ? Cédric From owner-freebsd-hackers@FreeBSD.ORG Mon Dec 12 17:58:08 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id E34F016A41F for ; Mon, 12 Dec 2005 17:58:08 +0000 (GMT) (envelope-from oxy@field.hu) Received: from dumballah.tvnet.hu (dumballah.tvnet.hu [195.38.96.23]) by mx1.FreeBSD.org (Postfix) with ESMTP id 4FF4143D62 for ; Mon, 12 Dec 2005 17:58:07 +0000 (GMT) (envelope-from oxy@field.hu) Received: from localhost (localhost.localdomain [127.0.0.1]) by dumballah.tvnet.hu (Postfix) with ESMTP id 89AD6101AD6 for ; Mon, 12 Dec 2005 18:58:06 +0100 (CET) Received: from dumballah.tvnet.hu ([127.0.0.1]) by localhost (dumballah.tvnet.hu [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 08488-34 for ; Mon, 12 Dec 2005 18:58:06 +0100 (CET) Received: from oxy (dsl195-38-110-3.pool.tvnet.hu [195.38.110.3]) by dumballah.tvnet.hu (Postfix) with SMTP id 32F0A101A9E for ; Mon, 12 Dec 2005 18:58:06 +0100 (CET) Message-ID: <000f01c5ff45$9abde650$0201a8c0@oxy> From: "OxY" To: Date: Mon, 12 Dec 2005 18:58:06 +0100 MIME-Version: 1.0 Content-Type: text/plain; format=flowed; charset="iso-8859-2"; reply-type=original Content-Transfer-Encoding: 7bit X-Priority: 3 X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook Express 6.00.2900.2527 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.2527 X-Virus-Scanned: by amavisd-new at tvnet.hu Subject: jailctl with multiple ip per jail X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 12 Dec 2005 17:58:09 -0000 hi! i have a little problem with jailctl, (sorry if it's not the right maillist, dunno where should i ask it) my question is can i use jailctl with two or more ip/jail or not? in the jails.conf i have to add hostname:ipaddress per jail, and wonder if i could make it work with other ip addresses... thanks for your help! From owner-freebsd-hackers@FreeBSD.ORG Mon Dec 12 19:24:35 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 0D67516A422 for ; Mon, 12 Dec 2005 19:24:35 +0000 (GMT) (envelope-from dillon@apollo.backplane.com) Received: from apollo.backplane.com (apollo.backplane.com [216.240.41.2]) by mx1.FreeBSD.org (Postfix) with ESMTP id 0DE2343D6B for ; Mon, 12 Dec 2005 19:24:13 +0000 (GMT) (envelope-from dillon@apollo.backplane.com) Received: from apollo.backplane.com (localhost [127.0.0.1]) by apollo.backplane.com (8.13.4/8.13.4) with ESMTP id jBCJNZe9099449; Mon, 12 Dec 2005 11:23:35 -0800 (PST) Received: (from dillon@localhost) by apollo.backplane.com (8.13.4/8.13.4/Submit) id jBCJNYCN099446; Mon, 12 Dec 2005 11:23:34 -0800 (PST) Date: Mon, 12 Dec 2005 11:23:34 -0800 (PST) From: Matthew Dillon Message-Id: <200512121923.jBCJNYCN099446@apollo.backplane.com> To: Stas Myasnikov References: <20051210150612.648aef0e.eric@theeric.com> <200512102245.jBAMjiu0087758@apollo.backplane.com> Cc: freebsd-hackers@freebsd.org Subject: Re: DragonFly talk at the upcoming BAYLISA (15 December 2005) X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 12 Dec 2005 19:24:35 -0000 :Hello Matt! : :I hope you'll make the materials available on the Net. Yah, I'm putting some slides together and will make them available after the talk. -Matt From owner-freebsd-hackers@FreeBSD.ORG Mon Dec 12 19:28:50 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id A6ED916A424; Mon, 12 Dec 2005 19:28:50 +0000 (GMT) (envelope-from jhb@freebsd.org) Received: from speedfactory.net (mail6.speedfactory.net [66.23.216.219]) by mx1.FreeBSD.org (Postfix) with ESMTP id D7BD343D60; Mon, 12 Dec 2005 19:28:46 +0000 (GMT) (envelope-from jhb@freebsd.org) Received: from server.baldwin.cx (unverified [66.23.211.162]) by speedfactory.net (SurgeMail 3.5b3) with ESMTP id 3660099 for multiple; Mon, 12 Dec 2005 14:30:51 -0500 Received: from localhost (john@localhost [127.0.0.1]) by server.baldwin.cx (8.13.1/8.13.1) with ESMTP id jBCJSTM4012946; Mon, 12 Dec 2005 14:28:35 -0500 (EST) (envelope-from jhb@freebsd.org) From: John Baldwin To: freebsd-hackers@freebsd.org Date: Mon, 12 Dec 2005 13:24:41 -0500 User-Agent: KMail/1.8.2 References: <1133993394.1426.2.camel@localhost> In-Reply-To: <1133993394.1426.2.camel@localhost> MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-6" Content-Transfer-Encoding: 7bit Content-Disposition: inline Message-Id: <200512121324.43169.jhb@freebsd.org> X-Spam-Status: No, score=-2.8 required=4.2 tests=ALL_TRUSTED autolearn=failed version=3.0.2 X-Spam-Checker-Version: SpamAssassin 3.0.2 (2004-11-16) on server.baldwin.cx X-Server: High Performance Mail Server - http://surgemail.com r=1653887525 Cc: Danilo Asara , David Xu Subject: Re: Fatal trap 12: page fault while in kernel mode X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 12 Dec 2005 19:28:50 -0000 On Wednesday 07 December 2005 05:09 pm, Danilo Asara wrote: > danilo@resolza [~]$ uname -a > FreeBSD resolza.fastwebnet.it 6.0-STABLE FreeBSD 6.0-STABLE #0: Fri > Nov18 11:19:38 CET > root@resolza.fastwebnet.it:/usr/obj/usr/src/sys/RESOLZA i386 > danilo@resolza [~]$ > > > root@resolza [/usr/crash]# kgdb kernel.debug.0 vmcore.0 > [GDB will not be able to debug user-mode > threads: /usr/lib/libthread_db.so: Undefined symbol "ps_pglobal_lookup"] > GNU gdb 6.1.1 [FreeBSD] > Copyright 2004 Free Software Foundation, Inc. > GDB is free software, covered by the GNU General Public License, and you > are > welcome to change it and/or distribute copies of it under certain > conditions. > Type "show copying" to see the conditions. > There is absolutely no warranty for GDB. Type "show warranty" for > details. > This GDB was configured as "i386-marcel-freebsd". > > Unread portion of the kernel message buffer: > > > Fatal trap 12: page fault while in kernel mode > cpuid = 0; apic id = 00 > fault virtual address = 0x0 > fault code = supervisor read, page not present > instruction pointer = 0x20:0xc0500411 > stack pointer = 0x28:0xef58fcac > frame pointer = 0x28:0xef58fcdc > code segment = base 0x0, limit 0xfffff, type 0x1b > = DPL 0, pres 1, def32 1, gran 1 > processor eflags = interrupt enabled, resume, IOPL = 0 > current process = 722 (artsd) > trap number = 12 > panic: page fault > cpuid = 0 > KDB: stack backtrace: > kdb_backtrace(100,c2a83a80,28,ef58fc6c,c) at kdb_backtrace+0x29 > panic(c06b2fec,c06d9f5b,0,fffff,c09b) at panic+0x114 > trap_fatal(ef58fc6c,0,c2a83a80,c2890bb8,c) at trap_fatal+0x2ca > trap_pfault(ef58fc6c,0,0) at trap_pfault+0x1d7 > trap(8,28,28,c2ea9e70,c2a83a80) at trap+0x2fd > calltrap() at calltrap+0x5 > --- trap 0xc, eip = 0xc0500411, esp = 0xef58fcac, ebp = 0xef58fcdc --- > kse_release(c2a83a80,ef58fd04,1,0,200292) at kse_release+0x165 > syscall(3b,3b,3b,80f2100,81) at syscall+0x2bf > Xint0x80_syscall() at Xint0x80_syscall+0x1f > --- syscall (383, FreeBSD ELF32, kse_release), eip = 0x287d81af, esp = > 0xbf9fef30, ebp = 0xbf9fef8c --- > Uptime: 12h9m20s > Dumping 1023 MB (2 chunks) > chunk 0: 1MB (159 pages) ... ok > chunk 1: 1023MB (261872 pages) 1007 991 975 959 943 927 911 895 879 > 863 847 831 815 799 783 767 751 735 719 703 687 671 655 639 623 607 591 > 575 559 543 527 511 495 479 463 447 431 415 399 383 367 351 335 319 303 > 287 271 255 239 223 207 191 175 159 143 127 111 95 79 63 47 31 15 > > #0 doadump () at pcpu.h:165 > 165 pcpu.h: No such file or directory. > in pcpu.h > (kgdb) where > #0 doadump () at pcpu.h:165 > #1 0xc05132bf in boot (howto=260) > at /usr/src/sys/kern/kern_shutdown.c:399 > #2 0xc0513615 in panic (fmt=0xc06b2fec "%s") > at /usr/src/sys/kern/kern_shutdown.c:555 > #3 0xc068d8ca in trap_fatal (frame=0xef58fc6c, eva=0) > at /usr/src/sys/i386/i386/trap.c:831 > #4 0xc068d5d7 in trap_pfault (frame=0xef58fc6c, usermode=0, eva=0) > at /usr/src/sys/i386/i386/trap.c:742 > #5 0xc068d1ed in trap (frame= > {tf_fs = 8, tf_es = 40, tf_ds = 40, tf_edi = -1024811408, tf_esi = > -1029162368, tf_ebp = -279380772, tf_isp = -279380840, tf_ebx = > -1026066384, tf_edx = -1029162368, tf_ecx = -1026066303, tf_eax = 0, > tf_trapno = 12, tf_err = 0, tf_eip = -1068497903, tf_cs = 32, tf_eflags > = 2687622, tf_esp = -1036728832, tf_ss = 30}) > at /usr/src/sys/i386/i386/trap.c:432 > #6 0xc067aaca in calltrap () at /usr/src/sys/i386/i386/exception.s:139 > #7 0xc0500411 in kse_release (td=0xc2a83a80, uap=0xef58fd04) > at /usr/src/sys/kern/kern_kse.c:428 The problem is here. You can try posting this to threads@FreeBSD.org and see if someone there can help you debug this further. -- John Baldwin <>< http://www.FreeBSD.org/~jhb/ "Power Users Use the Power to Serve" = http://www.FreeBSD.org From owner-freebsd-hackers@FreeBSD.ORG Mon Dec 12 19:48:39 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id A122816A422 for ; Mon, 12 Dec 2005 19:48:39 +0000 (GMT) (envelope-from pietro.cerutti@gmail.com) Received: from wproxy.gmail.com (wproxy.gmail.com [64.233.184.206]) by mx1.FreeBSD.org (Postfix) with ESMTP id 4F7F743D79 for ; Mon, 12 Dec 2005 19:48:30 +0000 (GMT) (envelope-from pietro.cerutti@gmail.com) Received: by wproxy.gmail.com with SMTP id 69so1849296wri for ; Mon, 12 Dec 2005 11:48:28 -0800 (PST) DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=beta; d=gmail.com; h=received:message-id:date:from:to:subject:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; b=ic3IeR9ZD9N+/SGeJwGpKNdFHjUxGDvP/uC+TuHOPZ+LJXwxyjP11Gip8/P/Ssm7qmSIfKOetyqQ2HLIYHeSzPHKcGEX0Qn5fTM7m4JtwXYE3w9m435tcgpLnt+2V6gUiBulS85oJNfrUhfoKZm8uTKv+a+FbCAvU0hMyDAyObk= Received: by 10.64.251.2 with SMTP id y2mr2607928qbh; Mon, 12 Dec 2005 11:47:48 -0800 (PST) Received: by 10.64.150.18 with HTTP; Mon, 12 Dec 2005 11:47:48 -0800 (PST) Message-ID: Date: Mon, 12 Dec 2005 20:47:48 +0100 From: Pietro Cerutti To: OxY , freebsd-hackers@freebsd.org In-Reply-To: <000f01c5ff45$9abde650$0201a8c0@oxy> MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Content-Disposition: inline References: <000f01c5ff45$9abde650$0201a8c0@oxy> Cc: Subject: Re: jailctl with multiple ip per jail X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 12 Dec 2005 19:48:39 -0000 On 12/12/05, OxY wrote: > hi! Hi, > > my question is can i use jailctl with two or more ip/jail or not? AFAIK, you can use bind a jail just to one Ip address... Don't know if things have changed since 6.0 > thanks for your help! Hope this helps, -- Pietro Cerutti Beansidhe - SwiSS Death / Thrash Metal Windows: "Where do you want to go today?" Linux: "Where do you want to go tomorrow?" FreeBSD: "Are you guys coming or what?" From owner-freebsd-hackers@FreeBSD.ORG Mon Dec 12 21:04:41 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 5D76F16A41F for ; Mon, 12 Dec 2005 21:04:41 +0000 (GMT) (envelope-from lists@codelounge.co.za) Received: from wiqd.gotdns.org (c1-25-2.nngy.isadsl.co.za [196.209.17.25]) by mx1.FreeBSD.org (Postfix) with ESMTP id 8192E43D4C for ; Mon, 12 Dec 2005 21:04:38 +0000 (GMT) (envelope-from lists@codelounge.co.za) Received: from dev.codelounge.co.za (localhost [127.0.0.1]) by wiqd.gotdns.org (8.13.4/8.13.3) with ESMTP id jBCL452S093439; Mon, 12 Dec 2005 23:04:05 +0200 (SAST) (envelope-from lists@codelounge.co.za) Received: (from wiqd@localhost) by dev.codelounge.co.za (8.13.4/8.13.3/Submit) id jBCL43xb093438; Mon, 12 Dec 2005 23:04:03 +0200 (SAST) (envelope-from lists@codelounge.co.za) X-Authentication-Warning: dev.codelounge.co.za: wiqd set sender to lists@codelounge.co.za using -f Date: Mon, 12 Dec 2005 23:04:03 +0200 From: wiqd To: OxY Message-ID: <20051212210403.GA93277@dev.codelounge.co.za> References: <000f01c5ff45$9abde650$0201a8c0@oxy> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <000f01c5ff45$9abde650$0201a8c0@oxy> User-Agent: mutt-ng/devel-r535 (FreeBSD) Cc: freebsd-hackers@freebsd.org Subject: Re: jailctl with multiple ip per jail X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: freebsd-hackers@freebsd.org List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 12 Dec 2005 21:04:41 -0000 On Mon, Dec 12, 2005 at 06:58:06PM +0100, OxY wrote: >hi! > >i have a little problem with jailctl, (sorry if it's not the right maillist, dunno where should i ask it) > >my question is can i use jailctl with two or more ip/jail or not? > >in the jails.conf i have to add hostname:ipaddress per jail, and wonder >if i could make it work with other ip addresses... hi there, yes just add them all, seperated with a space. Example: # List the names of all your jails here JAILS="host1.domain.tld:192.168.1.20 host2.domain.tld:192.168.1.21 host3.domain.tld:192.168.1.22" > >thanks for your help! Hope it does help :) Greg From owner-freebsd-hackers@FreeBSD.ORG Mon Dec 12 21:09:32 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 7099416A41F for ; Mon, 12 Dec 2005 21:09:32 +0000 (GMT) (envelope-from oxy@field.hu) Received: from dumballah.tvnet.hu (dumballah.tvnet.hu [195.38.96.23]) by mx1.FreeBSD.org (Postfix) with ESMTP id C9D5E43D82 for ; Mon, 12 Dec 2005 21:09:18 +0000 (GMT) (envelope-from oxy@field.hu) Received: from localhost (localhost.localdomain [127.0.0.1]) by dumballah.tvnet.hu (Postfix) with ESMTP id C9B471018A5 for ; Mon, 12 Dec 2005 22:09:13 +0100 (CET) Received: from dumballah.tvnet.hu ([127.0.0.1]) by localhost (dumballah.tvnet.hu [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 25985-34 for ; Mon, 12 Dec 2005 22:09:13 +0100 (CET) Received: from oxy (dsl195-38-110-3.pool.tvnet.hu [195.38.110.3]) by dumballah.tvnet.hu (Postfix) with SMTP id 783F11017F3 for ; Mon, 12 Dec 2005 22:09:13 +0100 (CET) Message-ID: <000a01c5ff60$4e2a3760$0201a8c0@oxy> From: "OxY" To: References: <000f01c5ff45$9abde650$0201a8c0@oxy> <20051212210403.GA93277@dev.codelounge.co.za> Date: Mon, 12 Dec 2005 22:09:13 +0100 MIME-Version: 1.0 Content-Type: text/plain; format=flowed; charset="iso-8859-1"; reply-type=original Content-Transfer-Encoding: 7bit X-Priority: 3 X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook Express 6.00.2900.2527 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.2527 X-Virus-Scanned: by amavisd-new at tvnet.hu Subject: Re: jailctl with multiple ip per jail X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 12 Dec 2005 21:09:32 -0000 i think i can define other jails with this, am i wrong? ----- Original Message ----- From: "wiqd" To: "OxY" Cc: Sent: Monday, December 12, 2005 10:04 PM Subject: Re: jailctl with multiple ip per jail > On Mon, Dec 12, 2005 at 06:58:06PM +0100, OxY wrote: >>hi! >> >>i have a little problem with jailctl, (sorry if it's not the right >>maillist, dunno where should i ask it) >> >>my question is can i use jailctl with two or more ip/jail or not? >> >>in the jails.conf i have to add hostname:ipaddress per jail, and wonder >>if i could make it work with other ip addresses... > > hi there, > > yes just add them all, seperated with a space. > > Example: > > # List the names of all your jails here > JAILS="host1.domain.tld:192.168.1.20 host2.domain.tld:192.168.1.21 > host3.domain.tld:192.168.1.22" > > >> >>thanks for your help! > > Hope it does help :) > > > Greg From owner-freebsd-hackers@FreeBSD.ORG Mon Dec 12 21:17:05 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 744DB16A42A for ; Mon, 12 Dec 2005 21:17:05 +0000 (GMT) (envelope-from lists@codelounge.co.za) Received: from wiqd.gotdns.org (c1-25-2.nngy.isadsl.co.za [196.209.17.25]) by mx1.FreeBSD.org (Postfix) with ESMTP id F00F243D66 for ; Mon, 12 Dec 2005 21:17:02 +0000 (GMT) (envelope-from lists@codelounge.co.za) Received: from dev.codelounge.co.za (localhost [127.0.0.1]) by wiqd.gotdns.org (8.13.4/8.13.3) with ESMTP id jBCLGVlb093527; Mon, 12 Dec 2005 23:16:31 +0200 (SAST) (envelope-from lists@codelounge.co.za) Received: (from wiqd@localhost) by dev.codelounge.co.za (8.13.4/8.13.3/Submit) id jBCLGUtY093526; Mon, 12 Dec 2005 23:16:30 +0200 (SAST) (envelope-from lists@codelounge.co.za) X-Authentication-Warning: dev.codelounge.co.za: wiqd set sender to lists@codelounge.co.za using -f Date: Mon, 12 Dec 2005 23:16:30 +0200 From: wiqd To: OxY Message-ID: <20051212211630.GB93277@dev.codelounge.co.za> References: <000f01c5ff45$9abde650$0201a8c0@oxy> <20051212210403.GA93277@dev.codelounge.co.za> <000a01c5ff60$4e2a3760$0201a8c0@oxy> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <000a01c5ff60$4e2a3760$0201a8c0@oxy> User-Agent: mutt-ng/devel-r535 (FreeBSD) Cc: freebsd-hackers@freebsd.org Subject: Re: jailctl with multiple ip per jail X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: freebsd-hackers@freebsd.org List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 12 Dec 2005 21:17:05 -0000 On Mon, Dec 12, 2005 at 10:09:13PM +0100, OxY wrote: >i think i can define other jails with this, am i wrong? You can define as many jails as you want with this, and use jailctl to start and stop them as needed. Greg From owner-freebsd-hackers@FreeBSD.ORG Mon Dec 12 21:35:37 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id B13B316A41F for ; Mon, 12 Dec 2005 21:35:37 +0000 (GMT) (envelope-from oxy@field.hu) Received: from dumballah.tvnet.hu (dumballah.tvnet.hu [195.38.96.23]) by mx1.FreeBSD.org (Postfix) with ESMTP id 24D9043D46 for ; Mon, 12 Dec 2005 21:35:36 +0000 (GMT) (envelope-from oxy@field.hu) Received: from localhost (localhost.localdomain [127.0.0.1]) by dumballah.tvnet.hu (Postfix) with ESMTP id E3743101A27 for ; Mon, 12 Dec 2005 22:35:32 +0100 (CET) Received: from dumballah.tvnet.hu ([127.0.0.1]) by localhost (dumballah.tvnet.hu [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 28950-05 for ; Mon, 12 Dec 2005 22:35:32 +0100 (CET) Received: from oxy (dsl195-38-110-3.pool.tvnet.hu [195.38.110.3]) by dumballah.tvnet.hu (Postfix) with SMTP id 91997101A21 for ; Mon, 12 Dec 2005 22:35:32 +0100 (CET) Message-ID: <000801c5ff63$fb717890$0201a8c0@oxy> From: "OxY" To: References: <000f01c5ff45$9abde650$0201a8c0@oxy><20051212210403.GA93277@dev.codelounge.co.za><000a01c5ff60$4e2a3760$0201a8c0@oxy> <20051212211630.GB93277@dev.codelounge.co.za> Date: Mon, 12 Dec 2005 22:35:33 +0100 MIME-Version: 1.0 Content-Type: text/plain; format=flowed; charset="iso-8859-1"; reply-type=original Content-Transfer-Encoding: 7bit X-Priority: 3 X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook Express 6.00.2900.2527 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.2527 X-Virus-Scanned: by amavisd-new at tvnet.hu Subject: Re: jailctl with multiple ip per jail X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 12 Dec 2005 21:35:37 -0000 yes, i know that, but what i want is to use an existing jail with 2ip not to create additional jails.. ----- Original Message ----- From: "wiqd" To: "OxY" Cc: Sent: Monday, December 12, 2005 10:16 PM Subject: Re: jailctl with multiple ip per jail > On Mon, Dec 12, 2005 at 10:09:13PM +0100, OxY wrote: >>i think i can define other jails with this, am i wrong? > > You can define as many jails as you want with this, and use jailctl to > start and stop them as needed. > > Greg > > > _______________________________________________ > freebsd-hackers@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/freebsd-hackers > To unsubscribe, send any mail to "freebsd-hackers-unsubscribe@freebsd.org" From owner-freebsd-hackers@FreeBSD.ORG Mon Dec 12 22:46:36 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id E1A8E16A422 for ; Mon, 12 Dec 2005 22:46:36 +0000 (GMT) (envelope-from danger@rulez.sk) Received: from mail.rulez.sk (DaEmoN.RuLeZ.sK [84.16.32.226]) by mx1.FreeBSD.org (Postfix) with ESMTP id 358DC43D7D for ; Mon, 12 Dec 2005 22:46:30 +0000 (GMT) (envelope-from danger@rulez.sk) Received: from localhost (localhost [127.0.0.1]) by mail.rulez.sk (Postfix) with ESMTP id 57CAB1CD3F; Mon, 12 Dec 2005 23:46:28 +0100 (CET) Received: from localhost (danger.mcrn.sk [84.16.37.254]) by mail.rulez.sk (Postfix) with ESMTP id A50581CD02; Mon, 12 Dec 2005 23:46:22 +0100 (CET) Date: Mon, 12 Dec 2005 23:46:18 +0100 From: Daniel Gerzo X-Mailer: The Bat! (v3.62.14) Professional X-Priority: 3 (Normal) Message-ID: <1103711167.20051212234618@rulez.sk> To: "OxY" In-Reply-To: <000801c5ff63$fb717890$0201a8c0@oxy> References: <000f01c5ff45$9abde650$0201a8c0@oxy><20051212210403.GA93277@dev.codelounge.co.za><000a01c5ff60$4e2a3760$0201a8c0@oxy> <20051212211630.GB93277@dev.codelounge.co.za> <000801c5ff63$fb717890$0201a8c0@oxy> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Virus-Scanned: by amavisd-new at mail.rulez.sk X-Spam-Status: No, score=-4.029 tagged_above=-999 required=5 tests=[ALL_TRUSTED=-1.8, AWL=0.370, BAYES_00=-2.599] X-Spam-Score: -4.029 X-Spam-Level: X-Mailman-Approved-At: Mon, 12 Dec 2005 22:48:54 +0000 Cc: freebsd-hackers@freebsd.org Subject: Re[2]: jailctl with multiple ip per jail X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: Daniel Gerzo List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 12 Dec 2005 22:46:37 -0000 Hello OxY, Monday, December 12, 2005, 10:35:33 PM, you wrote: > yes, i know that, but what i want is to use an existing jail > with 2ip > not to create additional jails.. although i dont know if it really works, but here is what i was able to google (check those mijail patches) :) place your questions on pjd@ http://garage.freebsd.pl/ -- Best regards, Daniel mailto:danger@rulez.sk From owner-freebsd-hackers@FreeBSD.ORG Tue Dec 13 00:16:42 2005 Return-Path: X-Original-To: hackers@freebsd.org Delivered-To: freebsd-hackers@FreeBSD.ORG Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id C980A16A420 for ; Tue, 13 Dec 2005 00:16:42 +0000 (GMT) (envelope-from jinmtb@sbcglobal.net) Received: from smtp106.sbc.mail.mud.yahoo.com (smtp106.sbc.mail.mud.yahoo.com [68.142.198.205]) by mx1.FreeBSD.org (Postfix) with SMTP id 4CC8F43D53 for ; Tue, 13 Dec 2005 00:16:41 +0000 (GMT) (envelope-from jinmtb@sbcglobal.net) Received: (qmail 155 invoked from network); 12 Dec 2005 23:45:49 -0000 Received: from unknown (HELO ?192.168.2.8?) (jinmtb@sbcglobal.net@68.127.176.52 with plain) by smtp106.sbc.mail.mud.yahoo.com with SMTP; 12 Dec 2005 23:45:48 -0000 Message-ID: <439E0D13.8010508@sbcglobal.net> Date: Mon, 12 Dec 2005 15:51:47 -0800 From: "Jin Guojun [VFFS]" User-Agent: Mozilla/5.0 (X11; U; FreeBSD i386; en-US; rv:1.7.12) Gecko/20051013 X-Accept-Language: zh, zh-CN, en MIME-Version: 1.0 To: hackers@freebsd.org Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Mailman-Approved-At: Tue, 13 Dec 2005 01:27:11 +0000 Cc: Subject: command line switch to disable following symlink in DIFF program X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 13 Dec 2005 00:16:42 -0000 Is "diff" program supposed to have a switch at command line to disable following (ignore) symbolic links when -r switch is given, like many other programs do? In many places, a directory or source file can be symbolically linked multiple times to different archives. Since the original source will be diffed anyway, why "diff" needs to follow symlinks to compare a same source multiple times? In the other case, if partition A has a symlink to somewhere in partition B, which has a symlink back to partition A , then "diff -r" will loop forever. I think that "diff" need a switch to disable following symlink to compare final object, instead, just check if symlink exists in both checked directories, like ls -P. -Jin From owner-freebsd-hackers@FreeBSD.ORG Tue Dec 13 12:22:00 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id CCF5416A420 for ; Tue, 13 Dec 2005 12:22:00 +0000 (GMT) (envelope-from nsrashmi@gmail.com) Received: from wproxy.gmail.com (wproxy.gmail.com [64.233.184.198]) by mx1.FreeBSD.org (Postfix) with ESMTP id E5A6543D60 for ; Tue, 13 Dec 2005 12:21:58 +0000 (GMT) (envelope-from nsrashmi@gmail.com) Received: by wproxy.gmail.com with SMTP id 55so119771wri for ; Tue, 13 Dec 2005 04:21:58 -0800 (PST) DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=beta; d=gmail.com; h=received:message-id:date:from:to:subject:mime-version:content-type:content-transfer-encoding:content-disposition; b=lsxlj/AWzdI4n5wC0+LcnVnIBvyw97SxPqoEsTUq1dd2OKpxjEWUWl0SiRmeIVpCliBI7NBk072hbrk6mGcBeUJt5SNenS4Xz2Ycw5+j4wC8p5rnEOulDSGuZDJAaziCKieAp/nLaOPn/ejcI9khYVyuxu3gtl8hANMGLozCAG4= Received: by 10.65.72.10 with SMTP id z10mr546130qbk; Tue, 13 Dec 2005 04:21:58 -0800 (PST) Received: by 10.64.204.16 with HTTP; Tue, 13 Dec 2005 04:21:57 -0800 (PST) Message-ID: <9f9993160512130421m60fe7303l311c13b542544551@mail.gmail.com> Date: Tue, 13 Dec 2005 17:51:57 +0530 From: rashmi ns To: freebsd-hackers@freebsd.org, freebsd-drivers@freebsd.org, freebsd-questions@freebsd.org, bugi@lists.redbrick.dcu.ie MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Content-Disposition: inline Cc: Subject: Help reqd: Configuring sppp X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 13 Dec 2005 12:22:00 -0000 Hi, I am facing problem in using sppp. Both local system amd remote systems are using the sppp. My questions are 1.Can we use sppp as PPP server? 2.If answer to first question is yes ,how can I do that? I tried out the following commands. $ifconfig hdlc0 up After this command interface is sending LCP-CONF-REQUEST. Also getting the LCP-CONF-ACK from the remote system. Sending and receiving of REQ and ACK is going on ,but after getting ACK sppp is not sending next phase (IPCP) packet to remote system. Pls help me in fixing this.Pls let me know any pointers regarding this. Regards, Rashmi From owner-freebsd-hackers@FreeBSD.ORG Tue Dec 13 14:44:43 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 740BD16A41F for ; Tue, 13 Dec 2005 14:44:43 +0000 (GMT) (envelope-from guomingyan@gmail.com) Received: from xproxy.gmail.com (xproxy.gmail.com [66.249.82.206]) by mx1.FreeBSD.org (Postfix) with ESMTP id 2AECF43D8F for ; Tue, 13 Dec 2005 14:44:33 +0000 (GMT) (envelope-from guomingyan@gmail.com) Received: by xproxy.gmail.com with SMTP id s18so1280097wxc for ; Tue, 13 Dec 2005 06:44:31 -0800 (PST) DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=beta; d=gmail.com; h=received:message-id:date:from:to:subject:mime-version:content-type; b=sM1l/riEIPiVUOFqWzed7smnGiiNjQ/BkuWep0/NJA8EH8ZPDoRjXSM3/CnYU8XcensUP/Jk4Ip4b5NisIQje0T2gNhdws6Dp+0WgysOGV5XNYJDzN7SFN2pHjyvHCgHDfCVl/ggGWYoqs78xC5PG7oxm6q7tou/oiroPK+4XbI= Received: by 10.70.42.13 with SMTP id p13mr10271213wxp; Tue, 13 Dec 2005 06:44:31 -0800 (PST) Received: by 10.70.39.18 with HTTP; Tue, 13 Dec 2005 06:44:31 -0800 (PST) Message-ID: <1fa17f810512130644y72d5994cp62b27f4ba54c8b47@mail.gmail.com> Date: Tue, 13 Dec 2005 22:44:31 +0800 From: prime To: freebsd-hackers@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Content-Disposition: inline X-Content-Filtered-By: Mailman/MimeDel 2.1.5 Subject: anybody interested in "Usable lock..." project? X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 13 Dec 2005 14:44:43 -0000 hi hackers, Are there anybody are interested in project "Usable lock implementation wit= h SX-semantics"(http://www.freebsd.org/projects/ideas/#p-sxsemantics)? Can we discuss it here? if so,share you ideas please. or anywhere else ? please tell me,thanks. -- Three passions, simple but overwhelmingly strong, have governed my life: the longing for love, the search for knowledge, and unbearable pity for the suffering of mankind. ---------Bertrand Russell From owner-freebsd-hackers@FreeBSD.ORG Tue Dec 13 16:01:04 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 893CA16A41F for ; Tue, 13 Dec 2005 16:01:04 +0000 (GMT) (envelope-from reichert@numachi.com) Received: from meisai.numachi.com (meisai.numachi.com [198.175.254.6]) by mx1.FreeBSD.org (Postfix) with SMTP id 5BA5F43D62 for ; Tue, 13 Dec 2005 16:01:01 +0000 (GMT) (envelope-from reichert@numachi.com) Received: (qmail 27223 invoked from network); 13 Dec 2005 16:00:58 -0000 Received: from natto.numachi.com (198.175.254.216) by meisai.numachi.com with SMTP; 13 Dec 2005 16:00:58 -0000 Received: (qmail 6262 invoked by uid 1001); 13 Dec 2005 16:00:57 -0000 Date: Tue, 13 Dec 2005 11:00:57 -0500 From: Brian Reichert To: freebsd-hackers@freebsd.org Message-ID: <20051213160057.GH19179@numachi.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.5.10i Subject: Does tcpdump2xplot work? X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 13 Dec 2005 16:01:04 -0000 This may be pilot error, but for the life of me, I can't get tcpdump2xplot to work as advertised. Every lick of documentation I can find say to first create a netdump libpcap file of TCP packets as such: tcpdump -tt -S -w tcpdump.out tcp Then, near as I can tell, I should be able to use tcpdump2xplot -plot tcpdump.out or tcpdump2xplot < tcpdump.out But in either case, each packet is rejected with the message 'Malformed entry in dump file tcpdump.out'. Can someone clue me in? Yes, tcpdump2xplot is just perl code, but this tools seems like it's been around for a while... -- Brian Reichert 55 Crystal Ave. #286 Daytime number: (603) 434-6842 Derry NH 03038-1725 USA BSD admin/developer at large From owner-freebsd-hackers@FreeBSD.ORG Tue Dec 13 16:20:55 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 6118E16A41F for ; Tue, 13 Dec 2005 16:20:55 +0000 (GMT) (envelope-from reichert@numachi.com) Received: from meisai.numachi.com (meisai.numachi.com [198.175.254.6]) by mx1.FreeBSD.org (Postfix) with SMTP id B8C1143D7B for ; Tue, 13 Dec 2005 16:20:52 +0000 (GMT) (envelope-from reichert@numachi.com) Received: (qmail 27463 invoked from network); 13 Dec 2005 16:20:51 -0000 Received: from natto.numachi.com (198.175.254.216) by meisai.numachi.com with SMTP; 13 Dec 2005 16:20:51 -0000 Received: (qmail 6403 invoked by uid 1001); 13 Dec 2005 16:20:50 -0000 Date: Tue, 13 Dec 2005 11:20:49 -0500 From: Brian Reichert To: freebsd-hackers@freebsd.org Message-ID: <20051213162049.GI19179@numachi.com> References: <20051213160057.GH19179@numachi.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20051213160057.GH19179@numachi.com> User-Agent: Mutt/1.5.10i Subject: Re: Does tcpdump2xplot work? X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 13 Dec 2005 16:20:55 -0000 On Tue, Dec 13, 2005 at 11:00:57AM -0500, Brian Reichert wrote: > This may be pilot error, but for the life of me, I can't get > tcpdump2xplot to work as advertised. > > Every lick of documentation I can find say to first create a netdump > libpcap file of TCP packets as such: I misenterpreted the instructions; tcpdump2xplot does _not_ accept a capture file. Other docs say I have to do this: tcpdump -tt -S -r tcpdump.out | tcpdump2xplot But, I get the same error... -- Brian Reichert 55 Crystal Ave. #286 Daytime number: (603) 434-6842 Derry NH 03038-1725 USA BSD admin/developer at large From owner-freebsd-hackers@FreeBSD.ORG Tue Dec 13 17:27:58 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id D658416A41F for ; Tue, 13 Dec 2005 17:27:58 +0000 (GMT) (envelope-from oxy@field.hu) Received: from dumballah.tvnet.hu (dumballah.tvnet.hu [195.38.96.23]) by mx1.FreeBSD.org (Postfix) with ESMTP id 3211043D86 for ; Tue, 13 Dec 2005 17:27:47 +0000 (GMT) (envelope-from oxy@field.hu) Received: from localhost (localhost.localdomain [127.0.0.1]) by dumballah.tvnet.hu (Postfix) with ESMTP id 03833101947 for ; Tue, 13 Dec 2005 18:27:41 +0100 (CET) Received: from dumballah.tvnet.hu ([127.0.0.1]) by localhost (dumballah.tvnet.hu [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 32597-14 for ; Tue, 13 Dec 2005 18:27:41 +0100 (CET) Received: from oxy (dsl195-38-110-3.pool.tvnet.hu [195.38.110.3]) by dumballah.tvnet.hu (Postfix) with SMTP id 9CDCA10193D for ; Tue, 13 Dec 2005 18:27:41 +0100 (CET) Message-ID: <001701c6000a$86eab700$0201a8c0@oxy> From: "OxY" To: Date: Tue, 13 Dec 2005 18:27:43 +0100 MIME-Version: 1.0 Content-Type: text/plain; format=flowed; charset="iso-8859-2"; reply-type=original Content-Transfer-Encoding: 7bit X-Priority: 3 X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook Express 6.00.2900.2527 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.2527 X-Virus-Scanned: by amavisd-new at tvnet.hu Subject: ipfw forwarding X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 13 Dec 2005 17:27:59 -0000 hi! i have a probably dumb question, can't get through it.. i have some ips on my server (x.x.x.28 and x.x.x.204 is important).. tried to forward packets from one ip to the other and ipfw doesn't do anything. i'd like to catch the packets on .204 port 80 and send them to one of my vhosts (domain is on .28) so anybody on the internet may open the .204 address from browser and get back the .28 content.. i used this rule: $cmd 00316 fwd x.x.x.x.204,80 tcp from any to x.x.x.28 80 what's wrong with it? i also added options IPFIREWALL_FORWARD to my kernel thx! From owner-freebsd-hackers@FreeBSD.ORG Tue Dec 13 17:40:33 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id DB52616A41F for ; Tue, 13 Dec 2005 17:40:33 +0000 (GMT) (envelope-from reichert@numachi.com) Received: from meisai.numachi.com (meisai.numachi.com [198.175.254.6]) by mx1.FreeBSD.org (Postfix) with SMTP id 1FEC643D53 for ; Tue, 13 Dec 2005 17:40:31 +0000 (GMT) (envelope-from reichert@numachi.com) Received: (qmail 28841 invoked from network); 13 Dec 2005 17:40:31 -0000 Received: from natto.numachi.com (198.175.254.216) by meisai.numachi.com with SMTP; 13 Dec 2005 17:40:31 -0000 Received: (qmail 6998 invoked by uid 1001); 13 Dec 2005 17:40:31 -0000 Date: Tue, 13 Dec 2005 12:40:31 -0500 From: Brian Reichert To: freebsd-hackers@freebsd.org Message-ID: <20051213174031.GJ19179@numachi.com> References: <20051213160057.GH19179@numachi.com> <20051213162049.GI19179@numachi.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20051213162049.GI19179@numachi.com> User-Agent: Mutt/1.5.10i Subject: Re: Does tcpdump2xplot work? X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 13 Dec 2005 17:40:34 -0000 On Tue, Dec 13, 2005 at 11:20:49AM -0500, Brian Reichert wrote: > Other docs say I have to do this: > > tcpdump -tt -S -r tcpdump.out | tcpdump2xplot > > But, I get the same error... I've traced down the issue: tcpdump now creates lines like: IP > ... And tcpdump2xplot doesn't want to see that 'IP' field. I'll try to get a patch cobbled... -- Brian Reichert 55 Crystal Ave. #286 Daytime number: (603) 434-6842 Derry NH 03038-1725 USA BSD admin/developer at large From owner-freebsd-hackers@FreeBSD.ORG Tue Dec 13 17:43:05 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id E87F116A428 for ; Tue, 13 Dec 2005 17:43:05 +0000 (GMT) (envelope-from joel@FreeBSD.org) Received: from av10-2-sn2.hy.skanova.net (av10-2-sn2.hy.skanova.net [81.228.8.182]) by mx1.FreeBSD.org (Postfix) with ESMTP id 4DF5E43D6A for ; Tue, 13 Dec 2005 17:42:57 +0000 (GMT) (envelope-from joel@FreeBSD.org) Received: by av10-2-sn2.hy.skanova.net (Postfix, from userid 502) id 0172A37FC1; Tue, 13 Dec 2005 18:42:51 +0100 (CET) Received: from smtp4-1-sn2.hy.skanova.net (smtp4-1-sn2.hy.skanova.net [81.228.8.92]) by av10-2-sn2.hy.skanova.net (Postfix) with ESMTP id D7F6C37E82; Tue, 13 Dec 2005 18:42:51 +0100 (CET) Received: from t4o55p69.telia.com (t4o55p69.telia.com [62.20.171.189]) by smtp4-1-sn2.hy.skanova.net (Postfix) with ESMTP id 14F1A37E44; Tue, 13 Dec 2005 18:42:50 +0100 (CET) From: Joel Dahl To: prime In-Reply-To: <1fa17f810512130644y72d5994cp62b27f4ba54c8b47@mail.gmail.com> References: <1fa17f810512130644y72d5994cp62b27f4ba54c8b47@mail.gmail.com> Content-Type: text/plain Date: Tue, 13 Dec 2005 18:43:02 +0100 Message-Id: <1134495782.677.3.camel@dude.automatvapen.se> Mime-Version: 1.0 X-Mailer: Evolution 2.2.3 FreeBSD GNOME Team Port Content-Transfer-Encoding: 7bit Cc: freebsd-hackers@freebsd.org Subject: Re: anybody interested in "Usable lock..." project? X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 13 Dec 2005 17:43:06 -0000 On Tue, 2005-12-13 at 22:44 +0800, prime wrote: > hi hackers, > > Are there anybody are interested in project "Usable lock implementation with > SX-semantics"(http://www.freebsd.org/projects/ideas/#p-sxsemantics)? > Can we discuss it here? if so,share you ideas please. > or anywhere else ? please tell me,thanks. Yes, you can discuss it here, and you should also check out the wiki: http://wikitest.freebsd.org/moin.cgi/Usable_20lock_20implementation_20with_20SX_2dsemantics -- Joel - joel at FreeBSD dot org From owner-freebsd-hackers@FreeBSD.ORG Tue Dec 13 18:01:52 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id E124516A422 for ; Tue, 13 Dec 2005 18:01:52 +0000 (GMT) (envelope-from dan@dan.emsphone.com) Received: from dan.emsphone.com (dan.emsphone.com [199.67.51.101]) by mx1.FreeBSD.org (Postfix) with ESMTP id 6B4BA43D7D for ; Tue, 13 Dec 2005 18:01:17 +0000 (GMT) (envelope-from dan@dan.emsphone.com) Received: (from dan@localhost) by dan.emsphone.com (8.13.1/8.13.3) id jBDI1BCc019535; Tue, 13 Dec 2005 12:01:11 -0600 (CST) (envelope-from dan) Date: Tue, 13 Dec 2005 12:01:11 -0600 From: Dan Nelson To: Brian Reichert Message-ID: <20051213180110.GE67826@dan.emsphone.com> References: <20051213160057.GH19179@numachi.com> <20051213162049.GI19179@numachi.com> <20051213174031.GJ19179@numachi.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20051213174031.GJ19179@numachi.com> X-OS: FreeBSD 5.4-STABLE X-message-flag: Outlook Error User-Agent: Mutt/1.5.11 Cc: freebsd-hackers@freebsd.org Subject: Re: Does tcpdump2xplot work? X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 13 Dec 2005 18:01:53 -0000 In the last episode (Dec 13), Brian Reichert said: > On Tue, Dec 13, 2005 at 11:20:49AM -0500, Brian Reichert wrote: > > Other docs say I have to do this: > > > > tcpdump -tt -S -r tcpdump.out | tcpdump2xplot > > > > But, I get the same error... > > I've traced down the issue: tcpdump now creates lines like: > > IP > ... > > And tcpdump2xplot doesn't want to see that 'IP' field. I'll try to get a > patch cobbled... You'll probably get better results using the tcptrace port, which reads capture files directly. -- Dan Nelson dnelson@allantgroup.com From owner-freebsd-hackers@FreeBSD.ORG Tue Dec 13 18:21:31 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 8EDB516A41F for ; Tue, 13 Dec 2005 18:21:31 +0000 (GMT) (envelope-from PeterJeremy@optushome.com.au) Received: from mail04.syd.optusnet.com.au (mail04.syd.optusnet.com.au [211.29.132.185]) by mx1.FreeBSD.org (Postfix) with ESMTP id 9D89743D97 for ; Tue, 13 Dec 2005 18:20:56 +0000 (GMT) (envelope-from PeterJeremy@optushome.com.au) Received: from cirb503493.alcatel.com.au (c220-239-19-236.belrs4.nsw.optusnet.com.au [220.239.19.236]) by mail04.syd.optusnet.com.au (8.12.11/8.12.11) with ESMTP id jBDIKePk031457 (version=TLSv1/SSLv3 cipher=EDH-RSA-DES-CBC3-SHA bits=168 verify=NO); Wed, 14 Dec 2005 05:20:41 +1100 Received: from cirb503493.alcatel.com.au (localhost.alcatel.com.au [127.0.0.1]) by cirb503493.alcatel.com.au (8.12.10/8.12.10) with ESMTP id jBDIKeHh078757; Wed, 14 Dec 2005 05:20:40 +1100 (EST) (envelope-from pjeremy@cirb503493.alcatel.com.au) Received: (from pjeremy@localhost) by cirb503493.alcatel.com.au (8.12.10/8.12.9/Submit) id jBDIKeUX078756; Wed, 14 Dec 2005 05:20:40 +1100 (EST) (envelope-from pjeremy) Date: Wed, 14 Dec 2005 05:20:39 +1100 From: Peter Jeremy To: OxY Message-ID: <20051213182039.GF77268@cirb503493.alcatel.com.au> References: <001701c6000a$86eab700$0201a8c0@oxy> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <001701c6000a$86eab700$0201a8c0@oxy> User-Agent: Mutt/1.4.2.1i X-PGP-Key: http://members.optusnet.com.au/peterjeremy/pubkey.asc Cc: freebsd-hackers@freebsd.org Subject: Re: ipfw forwarding X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 13 Dec 2005 18:21:32 -0000 On Tue, 2005-Dec-13 18:27:43 +0100, OxY wrote: >i used this rule: > >$cmd 00316 fwd x.x.x.x.204,80 tcp from any to x.x.x.28 80 > >what's wrong with it? You don't mention what is happening or not happening (running tcpdump and following packets as they go from system to system can be useful) but there are two issues you may not have considered. 1) Have you considered what will happen to packets being returned from the server on .28 to the client? 2) ipfw(8) states: The fwd action does not change the contents of the packet at all. In particular, the destination address remains unmodified, so packets forwarded to another system will usually be rejected by that system unless there is a matching rule on that system to capture them. For packets forwarded locally, the local address -- Peter Jeremy From owner-freebsd-hackers@FreeBSD.ORG Tue Dec 13 18:32:40 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 547BC16A420 for ; Tue, 13 Dec 2005 18:32:40 +0000 (GMT) (envelope-from V.Haisman@sh.cvut.cz) Received: from service.sh.cvut.cz (service.sh.cvut.cz [147.32.127.214]) by mx1.FreeBSD.org (Postfix) with ESMTP id 3393143D5E for ; Tue, 13 Dec 2005 18:32:38 +0000 (GMT) (envelope-from V.Haisman@sh.cvut.cz) Received: from localhost (localhost [127.0.0.1]) by service.sh.cvut.cz (Postfix) with ESMTP id E0C8E1A33E6 for ; Tue, 13 Dec 2005 19:32:37 +0100 (CET) Received: from service.sh.cvut.cz ([127.0.0.1]) by localhost (service [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 05282-08 for ; Tue, 13 Dec 2005 19:32:33 +0100 (CET) Received: from logout.sh.cvut.cz (logout.sh.cvut.cz [147.32.127.203]) by service.sh.cvut.cz (Postfix) with ESMTP id C4E2B1A33D6 for ; Tue, 13 Dec 2005 19:32:33 +0100 (CET) Received: from logout.sh.cvut.cz (logout.sh.cvut.cz [147.32.127.203]) by logout.sh.cvut.cz (Postfix) with ESMTP id 650F261C1F for ; Tue, 13 Dec 2005 19:36:22 +0100 (CET) Date: Tue, 13 Dec 2005 19:36:22 +0100 (CET) From: Vaclav Haisman To: freebsd-hackers@freebsd.org Message-ID: <20051213193118.Q94136@logout.sh.cvut.cz> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed X-Virus-Scanned: by amavisd-new at sh.cvut.cz Subject: Equivalent of POLLERR for kqueue. X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 13 Dec 2005 18:32:40 -0000 Is there equivalent of POLLERR for kqueue()? Or is EV_EOF the only thing? I would like to use kqueue/kevent for sockets but error condition signaling is not clear to me from manpage. Vaclav Haisman From owner-freebsd-hackers@FreeBSD.ORG Tue Dec 13 18:35:19 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 6CDDC16A41F for ; Tue, 13 Dec 2005 18:35:19 +0000 (GMT) (envelope-from hselasky@c2i.net) Received: from swip.net (mailfe01.swip.net [212.247.154.1]) by mx1.FreeBSD.org (Postfix) with ESMTP id 082D843D64 for ; Tue, 13 Dec 2005 18:35:14 +0000 (GMT) (envelope-from hselasky@c2i.net) X-T2-Posting-ID: Y1QAsIk9O44SO+J/q9KNyQ== X-Cloudmark-Score: 0.000000 [] Received: from mp-217-37-239.daxnet.no ([193.217.37.239] verified) by mailfe01.swip.net (CommuniGate Pro SMTP 5.0.2) with ESMTP id 46128512 for freebsd-hackers@freebsd.org; Tue, 13 Dec 2005 19:34:56 +0100 From: Hans Petter Selasky To: freebsd-hackers@freebsd.org Date: Tue, 13 Dec 2005 19:36:10 +0100 User-Agent: KMail/1.7 MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Content-Disposition: inline Message-Id: <200512131936.11640.hselasky@c2i.net> Subject: Standard C-macro scripting X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: hselasky@c2i.net List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 13 Dec 2005 18:35:19 -0000 Hi, What do you think about defining the following macros like this: #ifndef NOT #define NOT(arg) _NOT(YES arg(() NO)) #define _NOT(args...) args #endif #ifndef YES #define YES(args...) args #define NO(args...) #endif #ifndef END #define END(args...) args #endif #if ((1-YES(1)) || (1-NOT(NO)(1)) NO(||1)) #error "macros are not expanded correctly" #endif After some thinking these macros prove very useful building blocks. Consider the following macro: #define IE_WORD_COMPILE_1(name, def, decode) \ decode(u_int8_t name##_WORD;) \ u_int16_t name; Depending on wether the "decode" argument is "YES" or "NO", code will be kept or removed respectivly. Also the "decode" argument can be negated: "NOT(decode)". Usually "YES" and "NO" are not used directly but indirectly. For example one has a definition of a structure presented like this: #define CAPI_FACILITY_CONF(m,n) \ m(n, WORD , wInfo,)\ m(n, WORD , wSelector,)\ m(n, STRUCT, Param,)\ END Using this definition one wants to generate several other structures and initializers, that initialize the fields depending on their type, all automatic. How can one do that by using C-macros? Here is the code to generate "struct CAPI_FACILITY_CONF_ENCODED": CAPI_MAKE_STRUCT(CAPI_FACILITY_CONF); Here is the kernel code that uses this structure and initializes it: /*---------------------------------------------------------------------------* * generate facility confirmation message *---------------------------------------------------------------------------*/ static struct mbuf * capi_make_facility_conf(struct capi_message_encoded *pmsg, u_int16_t wSelector, u_int16_t wInfo) { struct mbuf *m; struct capi_message_encoded msg; struct CAPI_FACILITY_CONF_DECODED fac_conf = { /* zero */ }; u_int16_t len; /* the "CAPI_INIT" macro is defined further down */ CAPI_INIT(CAPI_FACILITY_CONF, &fac_conf); fac_conf.wInfo = wInfo; fac_conf.wSelector = wSelector; len = capi_encode(&msg.data, sizeof(msg.data), &fac_conf); len += sizeof(msg.head); /* fill out CAPI header */ msg.head.wLen = htole16(len); msg.head.wApp = htole16(0); msg.head.wCmd = htole16(CAPI_CONF(FACILITY)); msg.head.wNum = htole16(pmsg->head.wNum); msg.head.dwCid = htole32(pmsg->head.dwCid); if((m = i4b_getmbuf(len, M_NOWAIT))) { bcopy(&msg, m->m_data, m->m_len); } return m; } Here are the macros that do all the generation, and some extra ones that generate other things: /* information element types * for internal use: */ #define IE_END 0 #define IE_BYTE 1 #define IE_WORD 2 #define IE_DWORD 3 #define IE_QWORD 4 #define IE_STRUCT 5 /* excludes length field */ #define IE_STRUCT_CAPI 6 /* includes length field */ #define IE_STRUCT_DECODED 7 #define IE_STRUCT_DECODED_EMPTY 8 #define IE_BYTE_ARRAY 9 #define IE_MAX 10 /* exclusive */ struct capi_struct { u_int16_t len; void * ptr; } __packed; #define IE_BYTE_COMPILE_M(b,w,d,q,s,a) b #define IE_BYTE_COMPILE_1(name, def, decode) \ decode(u_int8_t name##_BYTE;) \ u_int8_t name; #define IE_WORD_COMPILE_M(b,w,d,q,s,a) w #define IE_WORD_COMPILE_1(name, def, decode) \ decode(u_int8_t name##_WORD;) \ u_int16_t name; #define IE_DWORD_COMPILE_M(b,w,d,q,s,a) d #define IE_DWORD_COMPILE_1(name, def, decode) \ decode(u_int8_t name##_DWORD;) \ u_int32_t name; #define IE_QWORD_COMPILE_M(b,w,d,q,s,a) q #define IE_QWORD_COMPILE_1(name, def, decode) \ decode(u_int8_t name##_QWORD;) \ u_int64_t name; #define IE_STRUCT_COMPILE_M(b,w,d,q,s,a) s #define IE_STRUCT_COMPILE_1(name, def, decode) \ decode(u_int8_t name##_STRUCT; \ struct capi_struct name;) \ NOT(decode)(/* structure length is set to \ * zero. Use the *DECODED \ * structure if length is non- \ * zero. \ */ \ u_int8_t name##_Null;) #define IE_BYTE_ARRAY_COMPILE_M(b,w,d,q,s,a) a #define IE_BYTE_ARRAY_COMPILE_1(name, def, decode) \ decode(u_int8_t name##_BYTE_ARRAY; \ u_int16_t name##_BYTE_ARRAY_LENGTH; ) \ u_int8_t name [def]; #define CAPI_MAKE_DECODED_FIELD(n, type, field, def) \ IE_##type##_COMPILE_1(field, def, YES) #define CAPI_MAKE_ENCODED_FIELD(n, type, field, def) \ IE_##type##_COMPILE_1(field, def, NO) #define CAPI_MAKE_STRUCT(name) \ struct name##_DECODED { \ name(CAPI_MAKE_DECODED_FIELD,)() \ u_int8_t name##_end; \ } __packed; \ struct name##_ENCODED { \ name(CAPI_MAKE_ENCODED_FIELD,)() \ } __packed; #define CAPI_MAKE_DEF_1(n,ENUM,value) \ enum { CAPI_##ENUM = (value) }; \ CAPI_MAKE_STRUCT(CAPI_##ENUM##_REQ) \ CAPI_MAKE_STRUCT(CAPI_##ENUM##_CONF) \ CAPI_MAKE_STRUCT(CAPI_##ENUM##_IND) \ CAPI_MAKE_STRUCT(CAPI_##ENUM##_RESP) #define CAPI_MAKE_DEF_2(n,ENUM,value) \ CAPI_##ENUM##_INDEX, #define CAPI_MAKE_DEF_3(n, ENUM) \ CAPI_MAKE_STRUCT(CAPI_##ENUM) #define CAPI_MAKE_UNION_1(n,ENUM,value) \ struct CAPI_##ENUM##_REQ_##n ENUM##_REQ; \ struct CAPI_##ENUM##_CONF_##n ENUM##_CONF; \ struct CAPI_##ENUM##_IND_##n ENUM##_IND; \ struct CAPI_##ENUM##_RESP_##n ENUM##_RESP; #define CAPI_MAKE_UNION_2(n, ENUM) \ struct CAPI_##ENUM##_##n ENUM; #define CAPI_DEBUG_OFFSET_1(field) \ (((u_int8_t *)&(((struct capi_message_decoded *)0)->field)) - ((u_int8_t *) 0)) /* this macro is a copy of the * next macro and is used to * allow macro recursion */ #define CAPI_MAKE_DEBUG_3(n, type, field, def) \ IE_##type##_COMPILE_M \ ( \ YES({ IE_BYTE, 1, CAPI_DEBUG_OFFSET_1(n.field), #field },) \ , \ YES({ IE_WORD, 2, CAPI_DEBUG_OFFSET_1(n.field), #field },) \ , \ YES({ IE_DWORD, 4, CAPI_DEBUG_OFFSET_1(n.field), #field },) \ , \ YES({ IE_QWORD, 8, CAPI_DEBUG_OFFSET_1(n.field), #field },) \ , \ CAPI_##def(NO,) \ ( \ CAPI_##def(CAPI_MAKE_DEBUG_3, def)() \ ) \ NOT(CAPI_##def(NO,)) \ ( \ { IE_STRUCT, sizeof(void *), \ CAPI_DEBUG_OFFSET_1(n.field.ptr), #field ".ptr" }, \ ) \ , \ YES({ IE_BYTE_ARRAY, sizeof(u_int8_t [def]), \ CAPI_DEBUG_OFFSET_1(n.field), #field "[" #def "]"},) \ ) /* this macro is used to make the debug * table in "libcapi.c" */ #define CAPI_MAKE_DEBUG_2(n, type, field, def) \ IE_##type##_COMPILE_M \ ( \ YES({ IE_BYTE, 1, CAPI_DEBUG_OFFSET_1(n.field), #field },) \ , \ YES({ IE_WORD, 2, CAPI_DEBUG_OFFSET_1(n.field), #field },) \ , \ YES({ IE_DWORD, 4, CAPI_DEBUG_OFFSET_1(n.field), #field },) \ , \ YES({ IE_QWORD, 8, CAPI_DEBUG_OFFSET_1(n.field), #field },) \ , \ CAPI_##def(NO,) \ ( \ CAPI_##def(CAPI_MAKE_DEBUG_3, def)() \ ) \ NOT(CAPI_##def(NO,)) \ ( \ { IE_STRUCT, sizeof(void *), \ CAPI_DEBUG_OFFSET_1(n.field.ptr), #field ".ptr" }, \ ) \ , \ YES({ IE_BYTE_ARRAY, sizeof(u_int8_t [def]), \ CAPI_DEBUG_OFFSET_1(n.field), #field "[" #def "]"},) \ ) #define CAPI_MAKE_DEBUG_1(n, ENUM, value) \ { IE_END, CAPI_P_REQ(ENUM), CAPI_REQ(ENUM), "CAPI_" #ENUM "_REQ" }, \ CAPI_##ENUM##_REQ (CAPI_MAKE_DEBUG_2, data.ENUM##_REQ )() \ { IE_END, CAPI_P_CONF(ENUM), CAPI_CONF(ENUM), "CAPI_" #ENUM "_CONF" }, \ CAPI_##ENUM##_CONF(CAPI_MAKE_DEBUG_2, data.ENUM##_CONF)() \ { IE_END, CAPI_P_IND(ENUM), CAPI_IND(ENUM), "CAPI_" #ENUM "_IND" }, \ CAPI_##ENUM##_IND (CAPI_MAKE_DEBUG_2, data.ENUM##_IND )() \ { IE_END, CAPI_P_RESP(ENUM), CAPI_RESP(ENUM), "CAPI_" #ENUM "_RESP" }, \ CAPI_##ENUM##_RESP(CAPI_MAKE_DEBUG_2, data.ENUM##_RESP)() #define CAPI_MAKE_CASES(n, ENUM, value) \ case CAPI_P_REQ(ENUM): \ CAPI_INIT_2(CAPI_##ENUM##_REQ,&((n)->data.ENUM##_REQ)) \ break; \ case CAPI_P_CONF(ENUM): \ CAPI_INIT_2(CAPI_##ENUM##_CONF,&((n)->data.ENUM##_CONF)) \ break; \ case CAPI_P_IND(ENUM): \ CAPI_INIT_2(CAPI_##ENUM##_IND,&((n)->data.ENUM##_IND)) \ break; \ case CAPI_P_RESP(ENUM): \ CAPI_INIT_2(CAPI_##ENUM##_RESP,&((n)->data.ENUM##_RESP)) \ break; #define CAPI_(m,n) NO /* invalid structure */ #define CAPI_MAKE_INIT_1(n, type, field, def) \ (n)->field##_##type = IE_##type; \ IE_##type##_COMPILE_M \ (,,,,,(n)->field##_##type##_LENGTH = sizeof(u_int8_t [def]);) #if (IE_STRUCT_DECODED_EMPTY == 0) #error "IE_STRUCT_DECODED_EMPTY cannot be zero" #endif #define CAPI_MAKE_INIT_2(n, type, field, def) \ IE_##type##_COMPILE_M \ ( \ /* BYTE */ \ (n)->field##_##type = IE_##type; \ , \ /* WORD */ \ (n)->field##_##type = IE_##type; \ , \ /* DWORD */ \ (n)->field##_##type = IE_##type; \ , \ /* QWORD */ \ (n)->field##_##type = IE_##type; \ , \ /* STRUCT */ \ CAPI_##def(NO,) \ ( \ /* allow the application to set type */ \ if((n)->field##_##type != IE_STRUCT_DECODED_EMPTY) \ { (n)->field##_##type = IE_STRUCT_DECODED; } \ \ /* use hints set by the environment to \ * setup the *DECODED pointer and structure \ */ \ (n)->field.ptr = &def##_STRUCT; \ def##_INIT = 1; \ ) \ NOT(CAPI_##def(NO,)) \ ( \ /* standard CAPI structure pointer */ \ (n)->field##_##type = IE_##type##_CAPI; \ ) \ , \ /* BYTE ARRAY */ \ (n)->field##_##type = IE_##type; \ (n)->field##_##type##_LENGTH = sizeof(u_int8_t [def]); \ ) /* this macro is used to initialize * the *DECODED structures before * passed to "capi_encode()" or * "capi_decode()" */ #define CAPI_INIT(what, ptr) \ { what(CAPI_MAKE_INIT_1,ptr)(); \ (ptr)->what##_end = IE_END; } \ /**/ /* internal use macro */ #define CAPI_INIT_2(what, ptr) \ { what(CAPI_MAKE_INIT_2,ptr)(); \ (ptr)->what##_end = IE_END; } \ /**/ Of course I chain things. When I whant to generate all structures in my header file I do it by typing: #define CAPI_COMMANDS(m,n) \ /*m(n, enum , value )* \ *m(n,------------------------------,-------)*/ \ m(n, DATA_B3 , 0x0086) \ m(n, CONNECT , 0x0002) \ m(n, CONNECT_ACTIVE , 0x0003) \ m(n, CONNECT_B3 , 0x0082) \ m(n, CONNECT_B3_ACTIVE , 0x0083) \ m(n, CONNECT_B3_T90_ACTIVE , 0x0088) \ m(n, DISCONNECT , 0x0004) \ m(n, DISCONNECT_B3 , 0x0084) \ m(n, ALERT , 0x0001) \ m(n, INFO , 0x0008) \ m(n, SELECT_B_PROTOCOL , 0x0041) \ m(n, FACILITY , 0x0080) \ m(n, RESET_B3 , 0x0087) \ m(n, MANUFACTURER , 0x00FF) \ m(n, LISTEN , 0x0005) \ /**/ /* for each command generate eight structures */ CAPI_COMMANDS(CAPI_MAKE_DEF_1,); What do you think about using C-macros like a scripting language? Any comments? --HPS From owner-freebsd-hackers@FreeBSD.ORG Tue Dec 13 18:52:08 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id BC6AD16A433 for ; Tue, 13 Dec 2005 18:52:08 +0000 (GMT) (envelope-from oxy@field.hu) Received: from dumballah.tvnet.hu (dumballah.tvnet.hu [195.38.96.23]) by mx1.FreeBSD.org (Postfix) with ESMTP id 2E52443D77 for ; Tue, 13 Dec 2005 18:51:53 +0000 (GMT) (envelope-from oxy@field.hu) Received: from localhost (localhost.localdomain [127.0.0.1]) by dumballah.tvnet.hu (Postfix) with ESMTP id D9DB110199D for ; Tue, 13 Dec 2005 19:51:51 +0100 (CET) Received: from dumballah.tvnet.hu ([127.0.0.1]) by localhost (dumballah.tvnet.hu [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 06664-24 for ; Tue, 13 Dec 2005 19:51:51 +0100 (CET) Received: from oxy (dsl195-38-110-3.pool.tvnet.hu [195.38.110.3]) by dumballah.tvnet.hu (Postfix) with SMTP id 792061018D2 for ; Tue, 13 Dec 2005 19:51:51 +0100 (CET) Message-ID: <000e01c60016$48f84af0$0201a8c0@oxy> From: "OxY" To: References: <001701c6000a$86eab700$0201a8c0@oxy> <20051213182039.GF77268@cirb503493.alcatel.com.au> Date: Tue, 13 Dec 2005 19:51:53 +0100 MIME-Version: 1.0 Content-Type: text/plain; format=flowed; charset="iso-8859-1"; reply-type=original Content-Transfer-Encoding: 7bit X-Priority: 3 X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook Express 6.00.2900.2527 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.2527 X-Virus-Scanned: by amavisd-new at tvnet.hu Subject: Re: ipfw forwarding X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 13 Dec 2005 18:52:08 -0000 both addresses are on the same box, just 2 public ips.. .28 is the jail, .204 is one of the hosts alias ----- Original Message ----- From: "Peter Jeremy" To: "OxY" Cc: Sent: Tuesday, December 13, 2005 7:20 PM Subject: Re: ipfw forwarding > On Tue, 2005-Dec-13 18:27:43 +0100, OxY wrote: >>i used this rule: >> >>$cmd 00316 fwd x.x.x.x.204,80 tcp from any to x.x.x.28 80 >> >>what's wrong with it? > > You don't mention what is happening or not happening (running tcpdump > and following packets as they go from system to system can be useful) > but there are two issues you may not have considered. > 1) Have you considered what will happen to packets being returned from > the server on .28 to the client? > 2) ipfw(8) states: > The fwd action does not change the contents of the packet at all. > In particular, the destination address remains unmodified, so > packets forwarded to another system will usually be rejected by > that system unless there is a matching rule on that system to > capture them. For packets forwarded locally, the local address > > -- > Peter Jeremy From owner-freebsd-hackers@FreeBSD.ORG Tue Dec 13 19:13:26 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id DE76016A41F for ; Tue, 13 Dec 2005 19:13:26 +0000 (GMT) (envelope-from michael@gargantuan.com) Received: from phoenix.gargantuan.com (srv01.lak.lwxdatacom.net [24.73.171.238]) by mx1.FreeBSD.org (Postfix) with ESMTP id DEA3B43D82 for ; Tue, 13 Dec 2005 19:13:11 +0000 (GMT) (envelope-from michael@gargantuan.com) Received: by phoenix.gargantuan.com (Postfix, from userid 1001) id D255531C; Tue, 13 Dec 2005 14:13:07 -0500 (EST) Date: Tue, 13 Dec 2005 14:13:07 -0500 From: "Michael W. Oliver" To: Brian Reichert Message-ID: <20051213191307.GE72074@gargantuan.com> Mail-Followup-To: Brian Reichert , freebsd-hackers@freebsd.org References: <20051213160057.GH19179@numachi.com> <20051213162049.GI19179@numachi.com> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="0eh6TmSyL6TZE2Uz" Content-Disposition: inline In-Reply-To: <20051213162049.GI19179@numachi.com> X-WWW-URL: http://michael.gargantuan.com X-GPG-PGP-Public-Key: http://michael.gargantuan.com/gnupg/pubkey.asc X-GPG-PGP-Fingerprint: 2694 0179 AE3F BFAE 0916 0BF5 B16B FBAB C5FA A3C9 X-Home-Phone: +1-863-816-8091 X-Mobile-Phone: +1-863-738-2334 X-Mailing-Address0: 8008 Apache Lane X-Mailing-Address1: Lakeland, FL X-Mailing-Address2: 33810-2172 X-Mailing-Address3: United States of America X-Guide-Questions: http://www.catb.org/~esr/faqs/smart-questions.html X-Guide-Netiquette: http://www.ietf.org/rfc/rfc1855.txt User-Agent: mutt-ng/devel-r445 (FreeBSD) Cc: freebsd-hackers@freebsd.org Subject: Re: Does tcpdump2xplot work? X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 13 Dec 2005 19:13:27 -0000 --0eh6TmSyL6TZE2Uz Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On 2005-12-13T11:20:49-0500, Brian Reichert wrote: > On Tue, Dec 13, 2005 at 11:00:57AM -0500, Brian Reichert wrote: >> This may be pilot error, but for the life of me, I can't get >> tcpdump2xplot to work as advertised. >> Every lick of documentation I can find say to first create a netdump >> libpcap file of TCP packets as such: >=20 > I misenterpreted the instructions; tcpdump2xplot does _not_ accept > a capture file. >=20 > Other docs say I have to do this: >=20 > tcpdump -tt -S -r tcpdump.out | tcpdump2xplot >=20 > But, I get the same error... Check this out... http://mail-index.netbsd.org/current-users/2004/11/30/0010.html Does that help? --=20 Mike Oliver [see complete headers for contact information] --0eh6TmSyL6TZE2Uz Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.2 (FreeBSD) iD8DBQFDnx1DsWv7q8X6o8kRApZ2AJ0QU2Rox+eLCviy3EcuSWe+YQLvUwCePDuy 5zEW9Q1GGFJEoB9Y4SEItY4= =koD9 -----END PGP SIGNATURE----- --0eh6TmSyL6TZE2Uz-- From owner-freebsd-hackers@FreeBSD.ORG Tue Dec 13 19:50:10 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 3E0C916A420 for ; Tue, 13 Dec 2005 19:50:10 +0000 (GMT) (envelope-from jhb@freebsd.org) Received: from speedfactory.net (mail6.speedfactory.net [66.23.216.219]) by mx1.FreeBSD.org (Postfix) with ESMTP id 025F643D6D for ; Tue, 13 Dec 2005 19:49:56 +0000 (GMT) (envelope-from jhb@freebsd.org) Received: from server.baldwin.cx (unverified [66.23.211.162]) by speedfactory.net (SurgeMail 3.5b3) with ESMTP id 3734723 for multiple; Tue, 13 Dec 2005 14:52:00 -0500 Received: from localhost (john@localhost [127.0.0.1]) by server.baldwin.cx (8.13.1/8.13.1) with ESMTP id jBDJndMK050422; Tue, 13 Dec 2005 14:49:39 -0500 (EST) (envelope-from jhb@freebsd.org) From: John Baldwin To: freebsd-hackers@freebsd.org, hselasky@c2i.net Date: Tue, 13 Dec 2005 14:48:21 -0500 User-Agent: KMail/1.8.2 References: <200512131936.11640.hselasky@c2i.net> In-Reply-To: <200512131936.11640.hselasky@c2i.net> MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit Content-Disposition: inline Message-Id: <200512131448.22599.jhb@freebsd.org> X-Virus-Scanned: ClamAV version 0.87.1, clamav-milter version 0.87 on server.baldwin.cx X-Virus-Status: Clean X-Spam-Status: No, score=-2.8 required=4.2 tests=ALL_TRUSTED autolearn=failed version=3.0.2 X-Spam-Checker-Version: SpamAssassin 3.0.2 (2004-11-16) on server.baldwin.cx X-Server: High Performance Mail Server - http://surgemail.com r=1653887525 Cc: Subject: Re: Standard C-macro scripting X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 13 Dec 2005 19:50:10 -0000 On Tuesday 13 December 2005 01:36 pm, Hans Petter Selasky wrote: > Hi, > > ... > > What do you think about using C-macros like a scripting language? Honestly, I think I've now been scarred for life. :-/ I think that this stuff would be so obscure that no one else would be able to help with maintenace. -- John Baldwin <>< http://www.FreeBSD.org/~jhb/ "Power Users Use the Power to Serve" = http://www.FreeBSD.org From owner-freebsd-hackers@FreeBSD.ORG Tue Dec 13 20:02:26 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id ACEEC16A41F for ; Tue, 13 Dec 2005 20:02:26 +0000 (GMT) (envelope-from reichert@numachi.com) Received: from meisai.numachi.com (meisai.numachi.com [198.175.254.6]) by mx1.FreeBSD.org (Postfix) with SMTP id AE1DA43D98 for ; Tue, 13 Dec 2005 20:02:09 +0000 (GMT) (envelope-from reichert@numachi.com) Received: (qmail 30487 invoked from network); 13 Dec 2005 20:02:06 -0000 Received: from natto.numachi.com (198.175.254.216) by meisai.numachi.com with SMTP; 13 Dec 2005 20:02:06 -0000 Received: (qmail 8009 invoked by uid 1001); 13 Dec 2005 20:02:06 -0000 Date: Tue, 13 Dec 2005 15:02:06 -0500 From: Brian Reichert To: Dan Nelson Message-ID: <20051213200206.GN19179@numachi.com> References: <20051213160057.GH19179@numachi.com> <20051213162049.GI19179@numachi.com> <20051213174031.GJ19179@numachi.com> <20051213180110.GE67826@dan.emsphone.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20051213180110.GE67826@dan.emsphone.com> User-Agent: Mutt/1.5.10i Cc: freebsd-hackers@freebsd.org Subject: Re: Does tcpdump2xplot work? X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 13 Dec 2005 20:02:26 -0000 On Tue, Dec 13, 2005 at 12:01:11PM -0600, Dan Nelson wrote: > You'll probably get better results using the tcptrace port, which reads > capture files directly. That it does; I was exploring what tcpdump2xplot _could_ provide, as distinct from tcptrace, and ran in to the roadblock I originally ran into.. > -- > Dan Nelson > dnelson@allantgroup.com -- Brian Reichert 55 Crystal Ave. #286 Daytime number: (603) 434-6842 Derry NH 03038-1725 USA BSD admin/developer at large From owner-freebsd-hackers@FreeBSD.ORG Tue Dec 13 20:05:30 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 584BB16A41F for ; Tue, 13 Dec 2005 20:05:30 +0000 (GMT) (envelope-from reichert@numachi.com) Received: from meisai.numachi.com (meisai.numachi.com [198.175.254.6]) by mx1.FreeBSD.org (Postfix) with SMTP id A5EB043D82 for ; Tue, 13 Dec 2005 20:05:01 +0000 (GMT) (envelope-from reichert@numachi.com) Received: (qmail 30518 invoked from network); 13 Dec 2005 20:04:55 -0000 Received: from natto.numachi.com (198.175.254.216) by meisai.numachi.com with SMTP; 13 Dec 2005 20:04:55 -0000 Received: (qmail 8030 invoked by uid 1001); 13 Dec 2005 20:04:55 -0000 Date: Tue, 13 Dec 2005 15:04:55 -0500 From: Brian Reichert To: Brian Reichert , freebsd-hackers@freebsd.org Message-ID: <20051213200455.GO19179@numachi.com> References: <20051213160057.GH19179@numachi.com> <20051213162049.GI19179@numachi.com> <20051213191307.GE72074@gargantuan.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20051213191307.GE72074@gargantuan.com> User-Agent: Mutt/1.5.10i Cc: Subject: Re: Does tcpdump2xplot work? X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 13 Dec 2005 20:05:31 -0000 On Tue, Dec 13, 2005 at 02:13:07PM -0500, Michael W. Oliver wrote: > Check this out... > > http://mail-index.netbsd.org/current-users/2004/11/30/0010.html > > Does that help? That confirms my own research; thanks... > -- > Mike Oliver -- Brian Reichert 55 Crystal Ave. #286 Daytime number: (603) 434-6842 Derry NH 03038-1725 USA BSD admin/developer at large From owner-freebsd-hackers@FreeBSD.ORG Tue Dec 13 21:32:19 2005 Return-Path: X-Original-To: hackers@freebsd.org Delivered-To: freebsd-hackers@FreeBSD.ORG Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id DAD3716A41F for ; Tue, 13 Dec 2005 21:32:19 +0000 (GMT) (envelope-from xdivac02@stud.fit.vutbr.cz) Received: from eva.fit.vutbr.cz (eva.fit.vutbr.cz [147.229.10.14]) by mx1.FreeBSD.org (Postfix) with ESMTP id F1A5743D68 for ; Tue, 13 Dec 2005 21:32:15 +0000 (GMT) (envelope-from xdivac02@stud.fit.vutbr.cz) Received: from eva.fit.vutbr.cz (localhost [127.0.0.1]) by eva.fit.vutbr.cz (envelope-from xdivac02@eva.fit.vutbr.cz) (8.13.4/8.13.3) with ESMTP id jBDLWB1O062443 (version=TLSv1/SSLv3 cipher=EDH-RSA-DES-CBC3-SHA bits=168 verify=NO) for ; Tue, 13 Dec 2005 22:32:11 +0100 (CET) Received: (from xdivac02@localhost) by eva.fit.vutbr.cz (8.13.4/8.13.3/Submit) id jBDLWB6b062442 for hackers@freebsd.org; Tue, 13 Dec 2005 22:32:11 +0100 (CET) Date: Tue, 13 Dec 2005 22:32:11 +0100 From: Divacky Roman To: hackers@freebsd.org Message-ID: <20051213213211.GA61984@stud.fit.vutbr.cz> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.4.2i X-Scanned-By: MIMEDefang 2.49 on 147.229.10.14 Cc: Subject: COMPAT_43 X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 13 Dec 2005 21:32:20 -0000 hi, the only use of COMPAT_43 (beside running 43 programs) is linux emulation layer and some tty-related stuff. but GENERIC etc. still shouts KEEP THIS on this option. is this necessary? forcing COMPAT_43 pesimises performnce (additional locking in some places etc.) and most users dont need it (for linux emulation I am working on a patch and also the tty part is being worked on). could the [KEEP THIS!] text be changed to something more reflecting reality? like keep this for linuxator/tty or something like that thnx roman From owner-freebsd-hackers@FreeBSD.ORG Wed Dec 14 00:04:39 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id C68E716A420; Wed, 14 Dec 2005 00:04:39 +0000 (GMT) (envelope-from hselasky@c2i.net) Received: from swip.net (mailfe05.swip.net [212.247.154.129]) by mx1.FreeBSD.org (Postfix) with ESMTP id 7839243D60; Wed, 14 Dec 2005 00:04:29 +0000 (GMT) (envelope-from hselasky@c2i.net) X-T2-Posting-ID: Y1QAsIk9O44SO+J/q9KNyQ== X-Cloudmark-Score: 0.000000 [] Received: from mp-217-38-178.daxnet.no ([193.217.38.178] verified) by mailfe05.swip.net (CommuniGate Pro SMTP 5.0.2) with ESMTP id 48854800; Wed, 14 Dec 2005 01:04:26 +0100 From: Hans Petter Selasky To: John Baldwin Date: Wed, 14 Dec 2005 01:05:45 +0100 User-Agent: KMail/1.7 References: <200512131936.11640.hselasky@c2i.net> <200512131448.22599.jhb@freebsd.org> In-Reply-To: <200512131448.22599.jhb@freebsd.org> MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Content-Disposition: inline Message-Id: <200512140105.46945.hselasky@c2i.net> Cc: freebsd-hackers@freebsd.org Subject: Re: Standard C-macro scripting X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: hselasky@c2i.net List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 14 Dec 2005 00:04:39 -0000 On Tuesday 13 December 2005 20:48, John Baldwin wrote: > On Tuesday 13 December 2005 01:36 pm, Hans Petter Selasky wrote: > > Hi, > > > > ... > > > > What do you think about using C-macros like a scripting language? > > Honestly, I think I've now been scarred for life. :-/ I think that this > stuff would be so obscure that no one else would be able to help with > maintenace. Macros are easy. It is just concat, stringify and expand. Maybe you have to think more about it before you get it. I am probably too used to it. What is the alternative? An Awk script would require a lot more code and it cannot be called from a C-program when it is compiling. Consider the following: One has some "enums" and wants to declare these and make a debugging table at the same time. The problem is that at some time one adds another "enum" and then the debugging table is out of sync. Using an Awk/Perl/XXX script to keep things in sync would be overkill. If one makes some standard macros that do standard transforms, then people will not get confused. I have started out to standardise this, for example one macro to make enums, MAKE_ENUM, and another to make tables of different kinds, MAKE_TABLE. There might be room for improvement. #define _MAKE_ENUM(enum,value,arg...) \ enum value, \ /**/ #define MAKE_ENUM(macro,end...) \ enum { macro(_MAKE_ENUM) end } \ /**/ #define __MAKE_TABLE(a...) a /* double pass to expand all macros */ #define _MAKE_TABLE(a...) (a), /* add comma */ #define MAKE_TABLE(m,field,p,a...) m##_##field p = \ { __MAKE_TABLE(m(m##_##field _MAKE_TABLE)) a } What the macros above do, is not difficult to understand at all. It is bare simple. Here is the definition of some enum series: #define MY_ENUMS_DEFAULT_DRIVER_DESC(enum,val,desc) desc #define MY_ENUMS(m)\ m(MY_ENUM_UNKNOWN ,,"unknown")\ m(MY_ENUM_YYY ,,"yyy ...")\ m(MY_ENUM_DAIC ,,"zzz ...")\ /**/ Here is the declaration: MAKE_ENUM(MY_ENUMS, N_MY_ENUMS); Here is the debugging table: static const char * const MAKE_TABLE(MY_ENUMS,DEFAULT_DRIVER_DESC,[]); Because the "MAKE_ENUM" macro only use the two first arguments passed to "m" in "MY_ENUMS", the other arguments can be used for other purpose, and one can list more information: Here is a real example of a state machine: #define L3_STATES(m)/* \ m(----------------,,--------,-------------,-------------------------,------)*\ m( ,,timeout , timeout , , q931 )*\ m( state ,,delay , state , desc , conv.)*\ m(----------------,,--------,-------------,-------------------------,------)*/ \ m( ST_L3_U0 ,, 0/*hz*/, ST_L3_U0 , "Null" , 0x00 )\ \ m( ST_L3_OUTGOING ,, 8/*hz*/, ST_L3_U0 , "Outgoing initialized" , 0x00 )\ m( ST_L3_U1 ,, 8/*hz*/, ST_L3_U0 , "Outgoing setup (U1)" , 0x01 )\ m( ST_L3_U2 ,,16/*hz*/, ST_L3_U0 , "Outgoing setup (U2)" , 0x02 )\ m( ST_L3_U2_ACK ,,16/*hz*/, ST_L3_U0 , "Outgoing setup (U2)" , 0x02 )\ m( ST_L3_U3 ,, 8/*hz*/, ST_L3_U3_TO , "Outgoing proceeding" , 0x03 )\ m( ST_L3_U3_TO ,, 4/*hz*/, ST_L3_U0 , "Outgoing proceeding" , 0x03 )\ \ m( ST_L3_U4 ,, 8/*hz*/, ST_L3_U4_TO , "Outgoing delivered" , 0x04 )\ m( ST_L3_U4_TO ,, 4/*hz*/, ST_L3_U0 , "Outgoing delivered" , 0x04 )\ \ m( ST_L3_INCOMING ,, 8/*hz*/, ST_L3_U0 , "Incoming initialized" , 0x00 )\ m( ST_L3_IN_ACK ,,16/*hz*/, ST_L3_U0 , "Incoming initialized" , 0x19 )\ m( ST_L3_U6 ,, 8/*hz*/, ST_L3_U0 , "Incoming present" , 0x06 )\ m( ST_L3_U7 ,, 8/*hz*/, ST_L3_U7_TO , "Incoming alerted" , 0x07 )\ m( ST_L3_U7_TO ,, 4/*hz*/, ST_L3_U0 , "Incoming alerted" , 0x07 )\ m( ST_L3_U8 ,, 4/*hz*/, ST_L3_U0 , "Incoming connecting" , 0x08 )\ \ m( ST_L3_UA ,, 8/*hz*/, ST_L3_UA_TO , "Active" , 0x0A )\ m( ST_L3_UA_TO ,, 4/*hz*/, ST_L3_U0 , "Active" , 0x0A )\ \ m( ST_L3_UC ,, 8/*hz*/, ST_L3_UC_TO , "Disconnected" , 0x0C )\ m( ST_L3_UC_TO ,, 4/*hz*/, ST_L3_U0 , "Disconnected" , 0x0C )\ /**/ Isn't the state-machine above easy to edit and understand ? What is wrong about that? And how would you solve it? --HPS From owner-freebsd-hackers@FreeBSD.ORG Wed Dec 14 00:08:40 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id DD33216A41F for ; Wed, 14 Dec 2005 00:08:40 +0000 (GMT) (envelope-from V.Haisman@sh.cvut.cz) Received: from service.sh.cvut.cz (service.sh.cvut.cz [147.32.127.214]) by mx1.FreeBSD.org (Postfix) with ESMTP id 2C5B743D7B for ; Wed, 14 Dec 2005 00:08:37 +0000 (GMT) (envelope-from V.Haisman@sh.cvut.cz) Received: from localhost (localhost [127.0.0.1]) by service.sh.cvut.cz (Postfix) with ESMTP id 4B78B1A33E5 for ; Wed, 14 Dec 2005 01:08:36 +0100 (CET) Received: from service.sh.cvut.cz ([127.0.0.1]) by localhost (service [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 14271-02; Wed, 14 Dec 2005 01:08:32 +0100 (CET) Received: from logout.sh.cvut.cz (logout.sh.cvut.cz [147.32.127.203]) by service.sh.cvut.cz (Postfix) with ESMTP id 571BC1A33D6; Wed, 14 Dec 2005 01:08:32 +0100 (CET) Received: from logout.sh.cvut.cz (logout.sh.cvut.cz [147.32.127.203]) by logout.sh.cvut.cz (Postfix) with ESMTP id 92F8F61C34; Wed, 14 Dec 2005 01:12:23 +0100 (CET) Date: Wed, 14 Dec 2005 01:12:23 +0100 (CET) From: Vaclav Haisman To: Vaclav Haisman In-Reply-To: <20051213193118.Q94136@logout.sh.cvut.cz> Message-ID: <20051214010711.F78686@logout.sh.cvut.cz> References: <20051213193118.Q94136@logout.sh.cvut.cz> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed X-Virus-Scanned: by amavisd-new at sh.cvut.cz Cc: freebsd-hackers@freebsd.org Subject: kqueue/kevent and directories (Was: Equivalent of POLLERR for kqueue.) X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 14 Dec 2005 00:08:41 -0000 On Tue, 13 Dec 2005, Vaclav Haisman wrote: > Is there equivalent of POLLERR for kqueue()? Or is EV_EOF the only thing? I > would like to use kqueue/kevent for sockets but error condition signaling is > not clear to me from manpage. > > Vaclav Haisman Another unclear area for me is how do changes in watched directory map on NOTE_*s of EVFILT_VNODE filter. What NOTE_* do I get when a file is created/deleted/modified etc.? Is there some other documentation I can read besides the man page? Vaclav Haisman From owner-freebsd-hackers@FreeBSD.ORG Wed Dec 14 01:59:44 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 06F4816A41F for ; Wed, 14 Dec 2005 01:59:44 +0000 (GMT) (envelope-from jmg@hydrogen.funkthat.com) Received: from hydrogen.funkthat.com (gate.funkthat.com [69.17.45.168]) by mx1.FreeBSD.org (Postfix) with ESMTP id 224FA43D5D for ; Wed, 14 Dec 2005 01:59:43 +0000 (GMT) (envelope-from jmg@hydrogen.funkthat.com) Received: from hydrogen.funkthat.com (localhost.funkthat.com [127.0.0.1]) by hydrogen.funkthat.com (8.13.3/8.13.3) with ESMTP id jBE1xfN6075607; Tue, 13 Dec 2005 17:59:41 -0800 (PST) (envelope-from jmg@hydrogen.funkthat.com) Received: (from jmg@localhost) by hydrogen.funkthat.com (8.13.3/8.13.3/Submit) id jBE1xe0i075606; Tue, 13 Dec 2005 17:59:40 -0800 (PST) (envelope-from jmg) Date: Tue, 13 Dec 2005 17:59:39 -0800 From: John-Mark Gurney To: Vaclav Haisman Message-ID: <20051214015939.GD55657@funkthat.com> Mail-Followup-To: Vaclav Haisman , freebsd-hackers@freebsd.org References: <20051213193118.Q94136@logout.sh.cvut.cz> <20051214010711.F78686@logout.sh.cvut.cz> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20051214010711.F78686@logout.sh.cvut.cz> User-Agent: Mutt/1.4.2.1i X-Operating-System: FreeBSD 5.4-RELEASE-p6 i386 X-PGP-Fingerprint: B7 EC EF F8 AE ED A7 31 96 7A 22 B3 D8 56 36 F4 X-Files: The truth is out there X-URL: http://resnet.uoregon.edu/~gurney_j/ X-Resume: http://resnet.uoregon.edu/~gurney_j/resume.html Cc: freebsd-hackers@freebsd.org Subject: Re: kqueue/kevent and directories (Was: Equivalent of POLLERR for kqueue.) X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: John-Mark Gurney List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 14 Dec 2005 01:59:44 -0000 Vaclav Haisman wrote this message on Wed, Dec 14, 2005 at 01:12 +0100: > On Tue, 13 Dec 2005, Vaclav Haisman wrote: > > >Is there equivalent of POLLERR for kqueue()? Or is EV_EOF the only thing? > >I would like to use kqueue/kevent for sockets but error condition > >signaling is not clear to me from manpage. It's up to the driver, but I don't believe that kqueue normally delivers errors back to the process... it returns as ready, but needs to be checked manually via a call to the proper syscall... (at least for sockets).. > >Vaclav Haisman > Another unclear area for me is how do changes in watched directory map on > NOTE_*s of EVFILT_VNODE filter. What NOTE_* do I get when a file is > created/deleted/modified etc.? You basicly have to treat a directory as a normal file.. if a NOTE_WRITE or NOTE_EXTEND gets returned on a directory, you have to rescan the entire directory to see what changed... kqueue does not return the directory entry in a watched directory that change/added/removed.. > Is there some other documentation I can read besides the man page? src/sys/kern/kern_event.c (and associated files)... There is also jlemon's paper on kqueue: http://people.freebsd.org/~jlemon/papers/kqueue.pdf -- John-Mark Gurney Voice: +1 415 225 5579 "All that I will do, has been done, All that I have, has not." From owner-freebsd-hackers@FreeBSD.ORG Wed Dec 14 06:01:26 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 15B4C16A41F for ; Wed, 14 Dec 2005 06:01:26 +0000 (GMT) (envelope-from vd@datamax.bg) Received: from jengal.datamax.bg (jengal.datamax.bg [82.103.104.21]) by mx1.FreeBSD.org (Postfix) with ESMTP id 9201D43D49 for ; Wed, 14 Dec 2005 06:01:25 +0000 (GMT) (envelope-from vd@datamax.bg) Received: from qlovarnika.bg.datamax (qlovarnika.bg.datamax [192.168.10.2]) by jengal.datamax.bg (Postfix) with SMTP id BD419B833; Wed, 14 Dec 2005 08:01:23 +0200 (EET) Received: (nullmailer pid 8103 invoked by uid 1002); Wed, 14 Dec 2005 06:01:20 -0000 Date: Wed, 14 Dec 2005 08:01:20 +0200 From: Vasil Dimov To: OxY Message-ID: <20051214060120.GA6833@qlovarnika.bg.datamax> References: <001701c6000a$86eab700$0201a8c0@oxy> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="5mCyUwZo2JvN/JJP" Content-Disposition: inline In-Reply-To: <001701c6000a$86eab700$0201a8c0@oxy> X-OS: FreeBSD 6.0-STABLE User-Agent: Mutt/1.5.11 Cc: freebsd-hackers@freebsd.org Subject: Re: ipfw forwarding X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: vd@datamax.bg List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 14 Dec 2005 06:01:26 -0000 --5mCyUwZo2JvN/JJP Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Tue, Dec 13, 2005 at 06:27:43PM +0100, OxY wrote: > hi! >=20 > i have a probably dumb question, can't get through it.. >=20 > i have some ips on my server (x.x.x.28 and x.x.x.204 is important).. >=20 > tried to forward packets from one ip to the other and ipfw doesn't do=20 > anything. > i'd like to catch the packets on .204 port 80 and send them to one of my= =20 > vhosts > (domain is on .28) >=20 > so anybody on the internet may open the .204 address from browser and get= =20 > back > the .28 content.. >=20 > i used this rule: >=20 > $cmd 00316 fwd x.x.x.x.204,80 tcp from any to x.x.x.28 80 >=20 > what's wrong with it? >=20 I suggest that you read *carefully* ipfw(8) and rewrite your rule to: 00316 fwd x.x.x.x.28,80 tcp from any to x.x.x.204 80 Good luck! --=20 Vasil Dimov --5mCyUwZo2JvN/JJP Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- iD8DBQFDn7UvFw6SP/bBpCARAtjoAJ9Kqcv5GaqStoCSemuGC77Em8/OfgCgzR9O 4DsR8gYW9N6wss4rrL0/FcQ= =nfhD -----END PGP SIGNATURE----- --5mCyUwZo2JvN/JJP-- From owner-freebsd-hackers@FreeBSD.ORG Wed Dec 14 06:27:00 2005 Return-Path: X-Original-To: freebsd-hackers@FreeBSD.org Delivered-To: freebsd-hackers@FreeBSD.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id B317B16A41F for ; Wed, 14 Dec 2005 06:27:00 +0000 (GMT) (envelope-from imp@bsdimp.com) Received: from harmony.bsdimp.com (vc4-2-0-87.dsl.netrack.net [199.45.160.85]) by mx1.FreeBSD.org (Postfix) with ESMTP id 266B643D55 for ; Wed, 14 Dec 2005 06:27:00 +0000 (GMT) (envelope-from imp@bsdimp.com) Received: from localhost (localhost.village.org [127.0.0.1] (may be forged)) by harmony.bsdimp.com (8.13.3/8.13.3) with ESMTP id jBE6OgPM026693; Tue, 13 Dec 2005 23:24:48 -0700 (MST) (envelope-from imp@bsdimp.com) Date: Tue, 13 Dec 2005 23:25:04 -0700 (MST) Message-Id: <20051213.232504.07010673.imp@bsdimp.com> To: jgrosch@MooseRiver.com From: "M. Warner Losh" In-Reply-To: <20051212051813.GA19499@mooseriver.com> References: <20051212051813.GA19499@mooseriver.com> X-Mailer: Mew version 3.3 on Emacs 21.3 / Mule 5.0 (SAKAKI) Mime-Version: 1.0 Content-Type: Text/Plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-2.0 (harmony.bsdimp.com [127.0.0.1]); Tue, 13 Dec 2005 23:24:48 -0700 (MST) Cc: freebsd-hackers@FreeBSD.org Subject: Re: Cardbus panics X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 14 Dec 2005 06:27:00 -0000 In message: <20051212051813.GA19499@mooseriver.com> Josef Grosch writes: : : I have an IBM T22 thinkpad running FreeBSD 5.4-RELEASE-p8. I have the : CardBus devices in the current kernel. When I insert a CardBus device, A : Xircom RealPort CardBus Ethernet I get a kernel panic like so; : : Dec 9 18:42:32 paris kernel: cbb alloc res fail : Dec 9 18:42:32 paris kernel: cardbus1: Can't get memory for IO ports : Dec 9 18:42:32 paris kernel: dc0: port 0-0x7f mem \ : 0x88000000-0x880007ff,0x88000800-0x88000fff at device 0.0 on cardbus1 : Dec 9 18:42:32 paris kernel: cbb alloc res fail : Dec 9 18:42:32 paris kernel: dc0: couldn't map ports/memory : Dec 9 18:42:32 paris kernel: : Dec 9 18:42:32 paris kernel: : Dec 9 18:42:32 paris kernel: Fatal trap 12: page fault while in kernel mode : Dec 9 18:42:32 paris kernel: fault virtual address = 0x30 : Dec 9 18:42:32 paris kernel: fault code = supervisor write, pag\ : e not present : Dec 9 18:42:32 paris kernel: instruction pointer = 0x8:0xc07b01f2 : Dec 9 18:42:32 paris kernel: stack pointer = 0x10:0xd5428c10 : Dec 9 18:42:32 paris kernel: frame pointer = 0x10:0xd5428c14 : Dec 9 18:42:32 paris kernel: code segment = base 0x0, limit 0xfff\ : ff, type 0x1b : Dec 9 18:42:32 paris kernel: = DPL 0, pres 1, def32 1, gran 1 : Dec 9 18:42:32 paris kernel: processor eflags = interrupt enabled, resume, IO\ : PL = 0 : Dec 9 18:42:32 paris kernel: current process = 38 (cbb1) : Dec 9 18:42:32 paris kernel: trap number = 12 : Dec 9 18:42:32 paris kernel: panic: page fault : Dec 9 18:42:32 paris kernel: Uptime: 35s : Dec 9 18:42:32 paris kernel: Cannot dump. No dump device defined. : Dec 9 18:42:32 paris kernel: Automatic reboot in 15 seconds - press a key on t\ : he console to abort : : : Any ideas How I can fix this? The suggested sysctl, : hw.pci.allow_unsupported_io_range, does not seem to exist in the kernel. Try 6.0 or a recent 7.0 snapshot. A bug similar to this has been fixed. Warner From owner-freebsd-hackers@FreeBSD.ORG Wed Dec 14 10:18:51 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 4408E16A41F for ; Wed, 14 Dec 2005 10:18:51 +0000 (GMT) (envelope-from stefan@fafoe.narf.at) Received: from viefep14-int.chello.at (viefep14-int.chello.at [213.46.255.13]) by mx1.FreeBSD.org (Postfix) with ESMTP id 290E143D5E for ; Wed, 14 Dec 2005 10:18:49 +0000 (GMT) (envelope-from stefan@fafoe.narf.at) Received: from wombat.fafoe.narf.at ([213.47.85.26]) by viefep14-int.chello.at (InterMail vM.6.01.04.04 201-2131-118-104-20050224) with ESMTP id <20051214101847.USNQ23858.viefep14-int.chello.at@wombat.fafoe.narf.at>; Wed, 14 Dec 2005 11:18:47 +0100 Received: by wombat.fafoe.narf.at (Postfix, from userid 1001) id 9C59CBF07; Wed, 14 Dec 2005 11:18:46 +0100 (CET) Date: Wed, 14 Dec 2005 11:18:46 +0100 From: Stefan Farfeleder To: Hans Petter Selasky Message-ID: <20051214101844.GE608@wombat.fafoe.narf.at> Mail-Followup-To: Hans Petter Selasky , freebsd-hackers@freebsd.org References: <200512131936.11640.hselasky@c2i.net> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <200512131936.11640.hselasky@c2i.net> User-Agent: Mutt/1.5.11 Cc: freebsd-hackers@freebsd.org Subject: Re: Standard C-macro scripting X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 14 Dec 2005 10:18:51 -0000 On Tue, Dec 13, 2005 at 07:36:10PM +0100, Hans Petter Selasky wrote: > Hi, > > What do you think about defining the following macros like this: > > #ifndef NOT > #define NOT(arg) _NOT(YES arg(() NO)) > #define _NOT(args...) args > #endif If you're interested in standards conforming code (as you seem to imply in the subject), use this instead: #define _NOT(...) __VA_ARGS__ Stefan From owner-freebsd-hackers@FreeBSD.ORG Wed Dec 14 14:25:49 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id A2CD216A41F for ; Wed, 14 Dec 2005 14:25:49 +0000 (GMT) (envelope-from oxy@field.hu) Received: from dumballah.tvnet.hu (dumballah.tvnet.hu [195.38.96.23]) by mx1.FreeBSD.org (Postfix) with ESMTP id 86BED43D45 for ; Wed, 14 Dec 2005 14:25:48 +0000 (GMT) (envelope-from oxy@field.hu) Received: from localhost (localhost.localdomain [127.0.0.1]) by dumballah.tvnet.hu (Postfix) with ESMTP id C95AD1019C0; Wed, 14 Dec 2005 15:25:46 +0100 (CET) Received: from dumballah.tvnet.hu ([127.0.0.1]) by localhost (dumballah.tvnet.hu [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 22103-37; Wed, 14 Dec 2005 15:25:46 +0100 (CET) Received: from oxy (dsl195-38-110-3.pool.tvnet.hu [195.38.110.3]) by dumballah.tvnet.hu (Postfix) with SMTP id 31CA1101976; Wed, 14 Dec 2005 15:25:46 +0100 (CET) Message-ID: <002501c600ba$489502c0$0201a8c0@oxy> From: "OxY" To: References: <001701c6000a$86eab700$0201a8c0@oxy> <20051214060120.GA6833@qlovarnika.bg.datamax> Date: Wed, 14 Dec 2005 15:25:50 +0100 MIME-Version: 1.0 Content-Type: text/plain; format=flowed; charset="iso-8859-1"; reply-type=original Content-Transfer-Encoding: 7bit X-Priority: 3 X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook Express 6.00.2900.2527 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.2527 X-Virus-Scanned: by amavisd-new at tvnet.hu Cc: freebsd-hackers@freebsd.org Subject: Re: ipfw forwarding X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 14 Dec 2005 14:25:49 -0000 thanks, it works! On Tue, Dec 13, 2005 at 06:27:43PM +0100, OxY wrote: > hi! > > i have a probably dumb question, can't get through it.. > > i have some ips on my server (x.x.x.28 and x.x.x.204 is important).. > > tried to forward packets from one ip to the other and ipfw doesn't do > anything. > i'd like to catch the packets on .204 port 80 and send them to one of my > vhosts > (domain is on .28) > > so anybody on the internet may open the .204 address from browser and get > back > the .28 content.. > > i used this rule: > > $cmd 00316 fwd x.x.x.x.204,80 tcp from any to x.x.x.28 80 > > what's wrong with it? > I suggest that you read *carefully* ipfw(8) and rewrite your rule to: 00316 fwd x.x.x.x.28,80 tcp from any to x.x.x.204 80 Good luck! -- Vasil Dimov ----- Original Message ----- From: "Vasil Dimov" To: "OxY" Cc: Sent: Wednesday, December 14, 2005 7:01 AM Subject: Re: ipfw forwarding From owner-freebsd-hackers@FreeBSD.ORG Wed Dec 14 14:38:12 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 23DE216A41F for ; Wed, 14 Dec 2005 14:38:12 +0000 (GMT) (envelope-from guomingyan@gmail.com) Received: from xproxy.gmail.com (xproxy.gmail.com [66.249.82.193]) by mx1.FreeBSD.org (Postfix) with ESMTP id 30E0F43D49 for ; Wed, 14 Dec 2005 14:38:11 +0000 (GMT) (envelope-from guomingyan@gmail.com) Received: by xproxy.gmail.com with SMTP id t12so94978wxc for ; Wed, 14 Dec 2005 06:38:09 -0800 (PST) DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=beta; d=gmail.com; h=received:message-id:date:from:to:subject:in-reply-to:mime-version:content-type:references; b=N15ozunl8gCuOTtEX06WtMLrJwvEhltauHMgwrI9rAho+Of1bxF/vpOJ5f+8zxkz3g/OWFLhQx6wxdsAK4f5BY0U5AaXH4i+gC/Jbw6TTL56yztc9pHkVUXq7Q+K5DR4rzid/NZsY62ap3zQc7XMiSFhnEgb1VcPYSxsfjKh0Go= Received: by 10.70.15.6 with SMTP id 6mr908956wxo; Wed, 14 Dec 2005 06:38:09 -0800 (PST) Received: by 10.70.39.18 with HTTP; Wed, 14 Dec 2005 06:38:09 -0800 (PST) Message-ID: <1fa17f810512140638t18eaef6cg9b0f4db782d47861@mail.gmail.com> Date: Wed, 14 Dec 2005 22:38:09 +0800 From: prime To: freebsd-hackers@freebsd.org In-Reply-To: <1134495496.677.1.camel@dude.automatvapen.se> MIME-Version: 1.0 References: <1fa17f810512130644y72d5994cp62b27f4ba54c8b47@mail.gmail.com> <1134495496.677.1.camel@dude.automatvapen.se> Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Content-Disposition: inline X-Content-Filtered-By: Mailman/MimeDel 2.1.5 Subject: Re: anybody interested in "Usable lock..." project? X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 14 Dec 2005 14:38:12 -0000 On 12/14/05, Joel Dahl wrote: > > On Tue, 2005-12-13 at 22:44 +0800, prime wrote: > > hi hackers, > > > > Are there anybody are interested in project "Usable lock implementation > with > > SX-semantics"(http://www.freebsd.org/projects/ideas/#p-sxsemantics)? > > Can we discuss it here? if so,share you ideas please. > > or anywhere else ? please tell me,thanks. > > Yes, you can discuss it here, and you should also check out the wiki: > > http://wikitest.freebsd.org/moin.cgi/Usable_20lock_20implementation_20wit= h_20SX_2dsemantics > > -- > Joel - joel at FreeBSD dot org > > thank you for your reply,and would you please tell me how to take part in the project? thanks. -- Three passions, simple but overwhelmingly strong, have governed my life: the longing for love, the search for knowledge, and unbearable pity for the suffering of mankind. ---------Bertrand Russell From owner-freebsd-hackers@FreeBSD.ORG Wed Dec 14 17:40:42 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id E14AD16A41F for ; Wed, 14 Dec 2005 17:40:42 +0000 (GMT) (envelope-from tbyte@otel.net) Received: from mail.otel.net (ll.otel.net [212.36.8.152]) by mx1.FreeBSD.org (Postfix) with ESMTP id 59A6043D64 for ; Wed, 14 Dec 2005 17:40:41 +0000 (GMT) (envelope-from tbyte@otel.net) Received: from dragon.otel.net ([212.36.8.135]) by mail.otel.net with esmtp (Exim 4.30; FreeBSD) id 1EmacJ-000JT2-PE; Wed, 14 Dec 2005 19:40:39 +0200 From: Iasen Kostov To: Cedric Tabary In-Reply-To: <20051212172031.GC42322@efrei.fr> References: <20051212083930.GC91837@efrei.fr> <20051212083537.T78724@odysseus.silby.com> <20051212172031.GC42322@efrei.fr> Content-Type: text/plain; charset=UTF-8 Date: Wed, 14 Dec 2005 19:40:39 +0200 Message-Id: <1134582039.40475.0.camel@DraGoN.OTEL.net> Mime-Version: 1.0 X-Mailer: Evolution 2.4.2.1 FreeBSD GNOME Team Port Content-Transfer-Encoding: quoted-printable Cc: freebsd-hackers@freebsd.org Subject: Re: mmap() sendfile() X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 14 Dec 2005 17:40:43 -0000 On Mon, 2005-12-12 at 18:20 +0100, Cedric Tabary wrote: > On 12/12/2005 08:38, Mike Silbersack wrote: > > On Mon, 12 Dec 2005, Cedric Tabary wrote: > >=20 > > >If it is true, doing a sendfile() on some very big files (even if not > > >keeping the descriptor open after) will kill the cache ? > > > > > >Please help me to understand why this patch ? and the difference betwe= en > > >sendfile() and mmap() at the memory or cache level.. > > > > > >C=C3=A9dric > >=20 > > My memory escapes me on all the details, but there were two potential=20 > > reasons not to use sendfile with 4.x that no longer apply in 5.x and=20 > > above: > >=20 > > 1. Sendfile used to send small files inefficiently, sending the http=20 > > headers in one packet and the data in another. I fixed this in 5.x. > >=20 > > 2. Alan Cox improved the memory efficiency of sendfile greatly, it now= =20 > > uses a single kernel buffer for all copies of the same block of the sam= e=20 > > file, whereas the old implementation made an in-kernel copy of each blo= ck,=20 > > making it no more memory efficient than using mbufs. >=20 > What about using sendfile() or mmap() on NFS ? >=20 > C=C3=A9dric > _______________________________________________ > freebsd-hackers@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/freebsd-hackers > To unsubscribe, send any mail to "freebsd-hackers-unsubscribe@freebsd.org= " From owner-freebsd-hackers@FreeBSD.ORG Wed Dec 14 17:44:23 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id AEE5316A41F for ; Wed, 14 Dec 2005 17:44:23 +0000 (GMT) (envelope-from tbyte@otel.net) Received: from mail.otel.net (ll.otel.net [212.36.8.152]) by mx1.FreeBSD.org (Postfix) with ESMTP id 418EB43D5A for ; Wed, 14 Dec 2005 17:44:23 +0000 (GMT) (envelope-from tbyte@otel.net) Received: from dragon.otel.net ([212.36.8.135]) by mail.otel.net with esmtp (Exim 4.30; FreeBSD) id 1Emaft-000JW7-TJ; Wed, 14 Dec 2005 19:44:21 +0200 From: Iasen Kostov To: Cedric Tabary In-Reply-To: <20051212172031.GC42322@efrei.fr> References: <20051212083930.GC91837@efrei.fr> <20051212083537.T78724@odysseus.silby.com> <20051212172031.GC42322@efrei.fr> Content-Type: text/plain; charset=UTF-8 Date: Wed, 14 Dec 2005 19:44:21 +0200 Message-Id: <1134582261.40475.4.camel@DraGoN.OTEL.net> Mime-Version: 1.0 X-Mailer: Evolution 2.4.2.1 FreeBSD GNOME Team Port Content-Transfer-Encoding: quoted-printable Cc: freebsd-hackers@freebsd.org Subject: Re: mmap() sendfile() X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 14 Dec 2005 17:44:23 -0000 On Mon, 2005-12-12 at 18:20 +0100, Cedric Tabary wrote: > On 12/12/2005 08:38, Mike Silbersack wrote: > > On Mon, 12 Dec 2005, Cedric Tabary wrote: > >=20 > > >If it is true, doing a sendfile() on some very big files (even if not > > >keeping the descriptor open after) will kill the cache ? > > > > > >Please help me to understand why this patch ? and the difference betwe= en > > >sendfile() and mmap() at the memory or cache level.. > > > > > >C=C3=A9dric > >=20 > > My memory escapes me on all the details, but there were two potential=20 > > reasons not to use sendfile with 4.x that no longer apply in 5.x and=20 > > above: > >=20 > > 1. Sendfile used to send small files inefficiently, sending the http=20 > > headers in one packet and the data in another. I fixed this in 5.x. > >=20 > > 2. Alan Cox improved the memory efficiency of sendfile greatly, it now= =20 > > uses a single kernel buffer for all copies of the same block of the sam= e=20 > > file, whereas the old implementation made an in-kernel copy of each blo= ck,=20 > > making it no more memory efficient than using mbufs. >=20 > What about using sendfile() or mmap() on NFS ? My expirience to the moment is that sendfile() is way slower when used to read large files from NFS and send them to many users via some HTTPd. Particulary thttpd and lighttp are 2 or more times (!) slower than xshttpd in that setup (xshttpd is using mmap). >=20 > C=C3=A9dric > _______________________________________________ > freebsd-hackers@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/freebsd-hackers > To unsubscribe, send any mail to "freebsd-hackers-unsubscribe@freebsd.org= " From owner-freebsd-hackers@FreeBSD.ORG Thu Dec 15 09:31:11 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 72B3F16A41F; Thu, 15 Dec 2005 09:31:11 +0000 (GMT) (envelope-from PeterJeremy@optushome.com.au) Received: from mail05.syd.optusnet.com.au (mail05.syd.optusnet.com.au [211.29.132.186]) by mx1.FreeBSD.org (Postfix) with ESMTP id 61C9E43D5C; Thu, 15 Dec 2005 09:31:08 +0000 (GMT) (envelope-from PeterJeremy@optushome.com.au) Received: from cirb503493.alcatel.com.au (c220-239-19-236.belrs4.nsw.optusnet.com.au [220.239.19.236]) by mail05.syd.optusnet.com.au (8.12.11/8.12.11) with ESMTP id jBF9V0dv000987 (version=TLSv1/SSLv3 cipher=EDH-RSA-DES-CBC3-SHA bits=168 verify=NO); Thu, 15 Dec 2005 20:31:01 +1100 Received: from cirb503493.alcatel.com.au (localhost.alcatel.com.au [127.0.0.1]) by cirb503493.alcatel.com.au (8.12.10/8.12.10) with ESMTP id jBF9V0Hh081120; Thu, 15 Dec 2005 20:31:00 +1100 (EST) (envelope-from pjeremy@cirb503493.alcatel.com.au) Received: (from pjeremy@localhost) by cirb503493.alcatel.com.au (8.12.10/8.12.9/Submit) id jBF9UxJk081119; Thu, 15 Dec 2005 20:30:59 +1100 (EST) (envelope-from pjeremy) Date: Thu, 15 Dec 2005 20:30:59 +1100 From: Peter Jeremy To: Hans Petter Selasky Message-ID: <20051215093059.GL77268@cirb503493.alcatel.com.au> References: <200512131936.11640.hselasky@c2i.net> <200512131448.22599.jhb@freebsd.org> <200512140105.46945.hselasky@c2i.net> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <200512140105.46945.hselasky@c2i.net> User-Agent: Mutt/1.4.2.1i X-PGP-Key: http://members.optusnet.com.au/peterjeremy/pubkey.asc Cc: freebsd-hackers@freebsd.org Subject: Re: Standard C-macro scripting X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 15 Dec 2005 09:31:11 -0000 On Wed, 2005-Dec-14 01:05:45 +0100, Hans Petter Selasky wrote: >On Tuesday 13 December 2005 20:48, John Baldwin wrote: >> Honestly, I think I've now been scarred for life. :-/ I think that this >> stuff would be so obscure that no one else would be able to help with >> maintenace. I tend to agree. >Macros are easy. It is just concat, stringify and expand. Maybe you have to >think more about it before you get it. I am probably too used to it. When you have nested macros and have to work out what is stringified at each level of expansion, it can get very difficult to follow. >What is the alternative? An Awk script would require a lot more code and it >cannot be called from a C-program when it is compiling. The approach I use (borrowed from gcc) is multiple includes. To take your enum example: ========== foo.def =================== m(MY_ENUM_UNKNOWN ,,"unknown") m(MY_ENUM_YYY ,,"yyy ...") m(MY_ENUM_DAIC ,,"zzz ...") ========== foo.c ===================== enum MY_ENUM { #define m(a,b,c) a b, #include "foo.def" #undef m }; static const char * const MY_ENUMS_DEFAULT_DRIVER_DESC[] = { #define m(a,b,c) c, #include "foo.def" #undef m }; ========== EOF ====================== Personally, I think this is far easier to understand - a single macro which is redefined to have a number of simple macro expansions rather than seven macros with carefully organised nesting to ensure correct stringification. I agree that this requires re-reading the definition file but it will be cached after the first pass so this isn't particularly expensive. You also have the advantage that the data (foo.def) doesn't have to be a single statement so you can (more easily) embed comments or other preprocessor directives. gcc uses this for various *.def files, redefining macros to suit requirements. As a real (cut-down) example from an interpreter I'm maintaining (in reality optab.h has 146 entries with 5 different opX_XX() macros): =============== optab.h ================== opd_dd(ex_add, ADD, "add",) /* 2 A+B */ opd_d( ex_plus, PLUS, "plus",) /* 3 +B */ opd_dd(ex_sub, SUB, "sub",) /* 4 A-B */ opd_d( ex_minus, MINUS, "minus",) /* 5 -B */ opd_dd(ex_pwr, PWR, "pwr",) /* 16 A*B */ opd_d( ex_exp, EXP, "exp",) /* 17 *B */ opd_dd(ex_comb, COMB, "comb",) /* 22 A!B */ opd_d( ex_fac, FAC, "fac",) /* 23 !B */ #undef opd_d #undef opd_dd =========== opt_codes.h ============ enum OpCode { #define opd_d(a,b,c,d) b, #define opd_dd(a,b,c,d) b, #include "optab.h" OPT_MAX /* largest opt-code */ }; =============== optable.c ============== const pfd_d exop2[] = { #define opd_d(a,b,c,d) a, #define opd_dd(a,b,c,d) ex_botch2, #include "optab.h" }; const pfd_dd exop3[] = { #define opd_d(a,b,c,d) ex_botch3, #define opd_dd(a,b,c,d) a, #include "optab.h" }; const char *opname[] = { #define opd_d(a,b,c,d) c, #define opd_dd(a,b,c,d) c, #include "optab.h" }; =============== main.h ============== #define opd_d(a,b,c,d) data a(data) d; #define opd_dd(a,b,c,d) data a(data, data) d; #include "optab.h" ========== EOF ====================== >Here is a real example of a state machine: > >#define L3_STATES(m)/* \ ... >m( ST_L3_UC_TO ,, 4/*hz*/, ST_L3_U0 , "Disconnected" , 0x0C )\ >/**/ > >Isn't the state-machine above easy to edit and understand ? It looks the same as my definitions file (modulo a backslash on each line and not having it in a separate file). >What is wrong about that? The complexity of the macros you need to expand it. There's also no scope for conditional inclusion (what if you wanted a single state machine description to conditionally compile for several protocol variants). >And how would you solve it? See above. -- Peter Jeremy From owner-freebsd-hackers@FreeBSD.ORG Thu Dec 15 11:33:29 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 25E6A16A41F; Thu, 15 Dec 2005 11:33:29 +0000 (GMT) (envelope-from hselasky@c2i.net) Received: from swip.net (mailfe01.swip.net [212.247.154.1]) by mx1.FreeBSD.org (Postfix) with ESMTP id 6BA3343D7F; Thu, 15 Dec 2005 11:33:17 +0000 (GMT) (envelope-from hselasky@c2i.net) X-T2-Posting-ID: Y1QAsIk9O44SO+J/q9KNyQ== X-Cloudmark-Score: 0.000000 [] Received: from mp-217-36-119.daxnet.no ([193.217.36.119] verified) by mailfe01.swip.net (CommuniGate Pro SMTP 5.0.2) with ESMTP id 47945492; Thu, 15 Dec 2005 12:33:09 +0100 From: Hans Petter Selasky To: Peter Jeremy Date: Thu, 15 Dec 2005 12:34:28 +0100 User-Agent: KMail/1.7 References: <200512131936.11640.hselasky@c2i.net> <200512140105.46945.hselasky@c2i.net> <20051215093059.GL77268@cirb503493.alcatel.com.au> In-Reply-To: <20051215093059.GL77268@cirb503493.alcatel.com.au> MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit Content-Disposition: inline Message-Id: <200512151234.29933.hselasky@c2i.net> Cc: freebsd-hackers@freebsd.org Subject: Re: Standard C-macro scripting X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: hselasky@c2i.net List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 15 Dec 2005 11:33:29 -0000 On Thursday 15 December 2005 10:30, Peter Jeremy wrote: > On Wed, 2005-Dec-14 01:05:45 +0100, Hans Petter Selasky wrote: > >On Tuesday 13 December 2005 20:48, John Baldwin wrote: > >> Honestly, I think I've now been scarred for life. :-/ I think that this > >> stuff would be so obscure that no one else would be able to help with > >> maintenace. > > I tend to agree. > > >Macros are easy. It is just concat, stringify and expand. Maybe you have > > to think more about it before you get it. I am probably too used to it. > > When you have nested macros and have to work out what is stringified at > each level of expansion, it can get very difficult to follow. > > >What is the alternative? An Awk script would require a lot more code and > > it cannot be called from a C-program when it is compiling. > > The approach I use (borrowed from gcc) is multiple includes. To take > your enum example: > > ========== foo.def =================== > m(MY_ENUM_UNKNOWN ,,"unknown") > m(MY_ENUM_YYY ,,"yyy ...") > m(MY_ENUM_DAIC ,,"zzz ...") > ========== foo.c ===================== > enum MY_ENUM { > #define m(a,b,c) a b, > #include "foo.def" > #undef m > }; > > static const char * const MY_ENUMS_DEFAULT_DRIVER_DESC[] = { > #define m(a,b,c) c, > #include "foo.def" > #undef m > }; > ========== EOF ====================== > > Personally, I think this is far easier to understand - a single macro > which is redefined to have a number of simple macro expansions rather > than seven macros with carefully organised nesting to ensure correct > stringification. I agree that this requires re-reading the definition > file but it will be cached after the first pass so this isn't particularly > expensive. You also have the advantage that the data (foo.def) doesn't > have to be a single statement so you can (more easily) embed comments or > other preprocessor directives. > > gcc uses this for various *.def files, redefining macros to suit > requirements. > > As a real (cut-down) example from an interpreter I'm maintaining (in > reality optab.h has 146 entries with 5 different opX_XX() macros): > > =============== optab.h ================== > opd_dd(ex_add, ADD, "add",) /* 2 A+B */ > opd_d( ex_plus, PLUS, "plus",) /* 3 +B */ > opd_dd(ex_sub, SUB, "sub",) /* 4 A-B */ > opd_d( ex_minus, MINUS, "minus",) /* 5 -B */ > opd_dd(ex_pwr, PWR, "pwr",) /* 16 A*B */ > opd_d( ex_exp, EXP, "exp",) /* 17 *B */ > opd_dd(ex_comb, COMB, "comb",) /* 22 A!B */ > opd_d( ex_fac, FAC, "fac",) /* 23 !B */ > > #undef opd_d > #undef opd_dd > =========== opt_codes.h ============ > enum OpCode { > #define opd_d(a,b,c,d) b, > #define opd_dd(a,b,c,d) b, > #include "optab.h" > OPT_MAX /* largest opt-code */ > }; > =============== optable.c ============== > const pfd_d exop2[] = { > #define opd_d(a,b,c,d) a, > #define opd_dd(a,b,c,d) ex_botch2, > #include "optab.h" > }; > > const pfd_dd exop3[] = { > #define opd_d(a,b,c,d) ex_botch3, > #define opd_dd(a,b,c,d) a, > #include "optab.h" > }; > > const char *opname[] = { > #define opd_d(a,b,c,d) c, > #define opd_dd(a,b,c,d) c, > #include "optab.h" > }; > > =============== main.h ============== > #define opd_d(a,b,c,d) data a(data) d; > #define opd_dd(a,b,c,d) data a(data, data) d; > #include "optab.h" I would prefer: OPTAB_DEF_H(opd_d, opd_dd); Because then one can put more definitions in the same file. And also it allows one to reuse macros without having to redefine them. Maybe you're right, that expanding as much as possible first is better. But in case a macro is nesting in one or two levels, I see no problem. > > ========== EOF ====================== > > >Here is a real example of a state machine: > > > >#define L3_STATES(m)/* \ > > ... > > >m( ST_L3_UC_TO ,, 4/*hz*/, ST_L3_U0 , "Disconnected" , 0x0C > > )\ /**/ > > > >Isn't the state-machine above easy to edit and understand ? > > It looks the same as my definitions file (modulo a backslash on each line > and not having it in a separate file). > > >What is wrong about that? > > The complexity of the macros you need to expand it. There's also no > scope for conditional inclusion (what if you wanted a single state > machine description to conditionally compile for several protocol > variants). Yes, you can do conditionally expressions with macros, just by adding another field to the definition where one specifies the protcol, and it will look good also, because now each line will contain the version for which the line is valid: #define MY_ENUMS(m)\ m(PROT_V1, MY_ENUM_UNKNOWN ,,"unknown")\ m(PROT_V2, MY_ENUM_YYY ,,"yyy ...")\ m(PROT_V3, MY_ENUM_DAIC ,,"zzz ...")\ #if xxx #define PROT_V1 YES #define PROT_V2 NO #deifne PROT_V3 NO #else ... #endif #define MY_GENERATOR(enabled, enum, value, desc) \ enabled (#enum ":" desc "\n") static const char * const desc = MY_ENUMS(MY_GENERATOR); I'm sure that one can also make logical macros that performs logical evaluation! Look at this: testM.h: #define YES(...) __VA_ARGS__ #define NO(...) #define __AND(a,b) COND_TEST_##a##b #define _AND(a,b) __AND(a,b) /* pass the arguments like this so that * they are expanded */ #define AND(a,b) _AND(a(1),b(1)) #define COND_TEST(...) /* equivalent to NO */ #define COND_TEST_1(...) /* equivalent to NO */ #define COND_TEST_11(...) __VA_ARGS__ /* equivalent to YES */ /* this should be a self-explaining statement: */ /* if */AND(AND(YES,YES),YES)( keep this ) %cpp testM.h # 1 "testM.h" # 1 "" # 1 "" # 1 "testM.h" # 12 "testM.h" keep this > >And how would you solve it? > > See above. It is just that one has to build up the macro C-scripting language with some helper macros like NOT/AND/OR/XOR/YES/NO/SWITCH ... to make it easy to use. For some purposes I still think that using macros directly instead of using an external script is more easy, though it might be an idea to expand more of these macros before-hand to make understanding the code easier. --HPS From owner-freebsd-hackers@FreeBSD.ORG Thu Dec 15 11:43:24 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 213AF16A41F for ; Thu, 15 Dec 2005 11:43:24 +0000 (GMT) (envelope-from joel@FreeBSD.org) Received: from av8-2-sn3.vrr.skanova.net (av8-2-sn3.vrr.skanova.net [81.228.9.184]) by mx1.FreeBSD.org (Postfix) with ESMTP id 2F2DE43D83 for ; Thu, 15 Dec 2005 11:43:18 +0000 (GMT) (envelope-from joel@FreeBSD.org) Received: by av8-2-sn3.vrr.skanova.net (Postfix, from userid 502) id A3DD137FE9; Thu, 15 Dec 2005 12:43:15 +0100 (CET) Received: from smtp3-2-sn3.vrr.skanova.net (smtp3-2-sn3.vrr.skanova.net [81.228.9.102]) by av8-2-sn3.vrr.skanova.net (Postfix) with ESMTP id 8F81537EDC; Thu, 15 Dec 2005 12:43:15 +0100 (CET) Received: from t6o955p19.telia.com (t6o955p19.telia.com [212.181.189.139]) by smtp3-2-sn3.vrr.skanova.net (Postfix) with ESMTP id B8AAB37E6E; Thu, 15 Dec 2005 12:43:14 +0100 (CET) From: Joel Dahl To: prime In-Reply-To: <1fa17f810512140638t18eaef6cg9b0f4db782d47861@mail.gmail.com> References: <1fa17f810512130644y72d5994cp62b27f4ba54c8b47@mail.gmail.com> <1134495496.677.1.camel@dude.automatvapen.se> <1fa17f810512140638t18eaef6cg9b0f4db782d47861@mail.gmail.com> Content-Type: text/plain Date: Thu, 15 Dec 2005 12:19:23 +0100 Message-Id: <1134645563.708.2.camel@dude.automatvapen.se> Mime-Version: 1.0 X-Mailer: Evolution 2.2.3 FreeBSD GNOME Team Port Content-Transfer-Encoding: 7bit Cc: freebsd-hackers@freebsd.org Subject: Re: anybody interested in "Usable lock..." project? X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 15 Dec 2005 11:43:24 -0000 On Wed, 2005-12-14 at 22:38 +0800, prime wrote: > On 12/14/05, Joel Dahl wrote: > > > > On Tue, 2005-12-13 at 22:44 +0800, prime wrote: > > > hi hackers, > > > > > > Are there anybody are interested in project "Usable lock implementation > > with > > > SX-semantics"(http://www.freebsd.org/projects/ideas/#p-sxsemantics)? > > > Can we discuss it here? if so,share you ideas please. > > > or anywhere else ? please tell me,thanks. > > > > Yes, you can discuss it here, and you should also check out the wiki: > > > > http://wikitest.freebsd.org/moin.cgi/Usable_20lock_20implementation_20with_20SX_2dsemantics > > > > -- > > Joel - joel at FreeBSD dot org > > > > > thank you for your reply,and would you please > tell me how to take part in the project? > thanks. If you can contribute code, you should talk to the "Technical contact". -- Joel - joel at FreeBSD dot org From owner-freebsd-hackers@FreeBSD.ORG Thu Dec 15 13:03:09 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id D179F16A41F for ; Thu, 15 Dec 2005 13:03:09 +0000 (GMT) (envelope-from kprokazov@s-v-r.net) Received: from globalmail.svr.net.ua (globalmail.svr.net.ua [212.113.40.42]) by mx1.FreeBSD.org (Postfix) with ESMTP id 49C4343D45 for ; Thu, 15 Dec 2005 13:03:08 +0000 (GMT) (envelope-from kprokazov@s-v-r.net) Received: from [10.1.2.12] (helo=svr012) by globalmail.svr.net.ua with smtp (Exim 4.52) id 1EmslH-0006im-C1; Thu, 15 Dec 2005 15:03:07 +0200 Message-ID: <1a3601c60179$cbbd76e0$0c02010a@svr012> From: "Konstantin Prokazoff" To: "Asterisk on BSD discussion" References: Date: Thu, 15 Dec 2005 15:16:44 +0200 MIME-Version: 1.0 Content-Type: text/plain; charset="ISO-8859-1" Content-Transfer-Encoding: 7bit X-Priority: 3 X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook Express 6.00.3790.0 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.3790.0 X-Mailman-Approved-At: Thu, 15 Dec 2005 13:25:13 +0000 Cc: freebsd-hackers@freebsd.org Subject: Re: [Asterisk-bsd] NMI ISA 30, EISA ff X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 15 Dec 2005 13:03:09 -0000 I haven't any ideas yet. Have same on i7325 chipset on 5.4 stable. Best regards, Konstantin Prokazoff Center Of Excellence, S_V_R Ltd., Kyiv HQs, Ukraine Official business-partner & DevConnect member of Avaya Inc. Regional development & support center of Digium Inc. Tel. +38 044 594 1781, ext. 1038 Fax. +38 044 234 0455 ----- Original Message ----- From: "Mark Ackroyd" To: "'Asterisk on BSD discussion'" Sent: Thursday, December 15, 2005 2:52 PM Subject: [Asterisk-bsd] NMI ISA 30, EISA ff > Hiya all, > > just installed the latest version of the BSD zaptel drivers (from svn) on a > bran new FreeBSD 6 machine. As soon as Zaptel loads my /var/log/messages > file gets filed with > > Dec 15 07:53:04 hathor kernel: NMI ISA 20, EISA ff > Dec 15 07:53:04 hathor kernel: NMI ISA 30, EISA ff > Dec 15 07:53:04 hathor kernel: NMI ISA 30, EISA ff > Dec 15 07:53:04 hathor kernel: NMI ISA 20, EISA ff > Dec 15 07:53:04 hathor last message repeated 4 times > Dec 15 07:53:04 hathor kernel: NMI ISA 30, EISA ff > Dec 15 07:53:04 hathor kernel: NMI ISA 30, EISA ff > Dec 15 07:53:04 hathor kernel: NMI ISA 20, EISA ff > Dec 15 07:53:04 hathor last message repeated 2 times > Dec 15 07:53:04 hathor kernel: NMI ISA 30, EISA ff > > Someone left some debug code in the zaptel driver? what does this mean? .. > at the moment it's just filling up disk space :-) > > Anyone got any ideas? > > Thanks, > Mark > > > > > > > > _______________________________________________ > Asterisk-BSD mailing list > Asterisk-BSD@lists.digium.com > http://lists.digium.com/mailman/listinfo/asterisk-bsd > > > -- > No virus found in this incoming message. > Checked by AVG Free Edition. > Version: 7.1.371 / Virus Database: 267.13.13/200 - Release Date: 14.12.2005 > > From owner-freebsd-hackers@FreeBSD.ORG Thu Dec 15 14:52:37 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 994A916A422 for ; Thu, 15 Dec 2005 14:52:37 +0000 (GMT) (envelope-from guomingyan@gmail.com) Received: from xproxy.gmail.com (xproxy.gmail.com [66.249.82.192]) by mx1.FreeBSD.org (Postfix) with ESMTP id 1B89A43D67 for ; Thu, 15 Dec 2005 14:52:34 +0000 (GMT) (envelope-from guomingyan@gmail.com) Received: by xproxy.gmail.com with SMTP id t12so309407wxc for ; Thu, 15 Dec 2005 06:52:34 -0800 (PST) DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=beta; d=gmail.com; h=received:message-id:date:from:to:subject:mime-version:content-type; b=e/19nb5fsJlyN9rHXNUgfP/dL7AEzV/7Af1oMKI8fiItCQTGB0FAEagD+Bt/0b9GBdf9SlXsfZu7yK/MqPjJFjkCF8gReYna0A4tQOjlGAICPD5+ubY8d/MRGvxKK+80BV1sEOfFOwYZ/zd35QYLPWLH5BcXJf9GAlKNFcOaewo= Received: by 10.70.20.10 with SMTP id 10mr2318391wxt; Thu, 15 Dec 2005 06:52:31 -0800 (PST) Received: by 10.70.39.18 with HTTP; Thu, 15 Dec 2005 06:52:31 -0800 (PST) Message-ID: <1fa17f810512150652h5da6a6a5g3347f841a614689e@mail.gmail.com> Date: Thu, 15 Dec 2005 22:52:31 +0800 From: prime To: freebsd-hackers@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Content-Disposition: inline X-Content-Filtered-By: Mailman/MimeDel 2.1.5 Subject: Use turnstile to implement sx_lock X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 15 Dec 2005 14:52:37 -0000 hi hackers, I want to use turnstile to implement sx_lock( or read/write lock),but find that there is a big obstacle, ONE sx_lock needs TWO queues to put waiters on,one for readers and the other one for writers,but ONE turnstile can only supply ONE queue,and ONE sx_lock can only get ONE turnstile. I read opensolaris' rw_lock implementation and find that its turnstile has TWO queues which is different from FreeBSD's turnstile. Are there any good ideas to bypass the obstacle? Thanks very much. -- Three passions, simple but overwhelmingly strong, have governed my life: the longing for love, the search for knowledge, and unbearable pity for the suffering of mankind. ---------Bertrand Russell From owner-freebsd-hackers@FreeBSD.ORG Thu Dec 15 15:16:50 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 86F9B16A41F for ; Thu, 15 Dec 2005 15:16:50 +0000 (GMT) (envelope-from jhb@freebsd.org) Received: from speedfactory.net (mail6.speedfactory.net [66.23.216.219]) by mx1.FreeBSD.org (Postfix) with ESMTP id 6936D43D62 for ; Thu, 15 Dec 2005 15:16:49 +0000 (GMT) (envelope-from jhb@freebsd.org) Received: from server.baldwin.cx (unverified [66.23.211.162]) by speedfactory.net (SurgeMail 3.5b3) with ESMTP id 3865607 for multiple; Thu, 15 Dec 2005 10:14:47 -0500 Received: from localhost (john@localhost [127.0.0.1]) by server.baldwin.cx (8.13.1/8.13.1) with ESMTP id jBFFGfhQ069623; Thu, 15 Dec 2005 10:16:41 -0500 (EST) (envelope-from jhb@freebsd.org) From: John Baldwin To: freebsd-hackers@freebsd.org Date: Thu, 15 Dec 2005 10:17:11 -0500 User-Agent: KMail/1.8.2 References: <1fa17f810512150652h5da6a6a5g3347f841a614689e@mail.gmail.com> In-Reply-To: <1fa17f810512150652h5da6a6a5g3347f841a614689e@mail.gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit Content-Disposition: inline Message-Id: <200512151017.12168.jhb@freebsd.org> X-Virus-Scanned: ClamAV version 0.87.1, clamav-milter version 0.87 on server.baldwin.cx X-Virus-Status: Clean X-Spam-Status: No, score=-2.8 required=4.2 tests=ALL_TRUSTED autolearn=failed version=3.0.2 X-Spam-Checker-Version: SpamAssassin 3.0.2 (2004-11-16) on server.baldwin.cx X-Server: High Performance Mail Server - http://surgemail.com r=1653887525 Cc: prime Subject: Re: Use turnstile to implement sx_lock X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 15 Dec 2005 15:16:50 -0000 On Thursday 15 December 2005 09:52 am, prime wrote: > hi hackers, > I want to use turnstile to implement sx_lock( or read/write lock),but > find that there is a big obstacle, > ONE sx_lock needs TWO queues to put waiters on,one for readers and the > other one for writers,but ONE turnstile can only supply ONE queue,and ONE > sx_lock can only get ONE turnstile. > > I read opensolaris' rw_lock implementation and find that its turnstile > has TWO queues which is different from FreeBSD's turnstile. > > Are there any good ideas to bypass the obstacle? Thanks very much. You have to add a second queue to the turnstile and make priority propagation still work, etc. Mutexes would just use the exclusive queue all the time whereas rwlocks would use both queues. This is the hard part of the rwlock project. I've sort-of started on this but haven't gotten very far at all in my jhb_lock p4 branch. -- John Baldwin <>< http://www.FreeBSD.org/~jhb/ "Power Users Use the Power to Serve" = http://www.FreeBSD.org From owner-freebsd-hackers@FreeBSD.ORG Thu Dec 15 19:55:31 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id C498D16A41F for ; Thu, 15 Dec 2005 19:55:31 +0000 (GMT) (envelope-from mario.lobo@ipad.com.br) Received: from recife.ipadnet.com.br (recife.ipadnet.com.br [200.249.204.129]) by mx1.FreeBSD.org (Postfix) with ESMTP id 955BA43D5A for ; Thu, 15 Dec 2005 19:55:28 +0000 (GMT) (envelope-from mario.lobo@ipad.com.br) Received: from marioLobo (spyketembratel.ipadnet.com.br [200.249.204.142]) (authenticated bits=0) by recife.ipadnet.com.br (8.12.8/8.12.8) with ESMTP id jBFKF2NU016242 for ; Thu, 15 Dec 2005 17:15:02 -0300 From: "Mario Lobo" Organization: IPAD To: freebsd-hackers@freebsd.org Date: Thu, 15 Dec 2005 16:57:13 -0300 MIME-Version: 1.0 Content-type: Multipart/Mixed; boundary=Message-Boundary-11470 Message-ID: <43A1A069.12349.2A94B474@localhost> Priority: normal X-mailer: Pegasus Mail for Windows (4.21c) X-Antivirus: avast! (VPS 0550-3, 15/12/2005), Outbound message X-Antivirus-Status: Clean Subject: [OFF TOPIC] Please, see attached TXT file X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: mario.lobo@ipad.com.br List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 15 Dec 2005 19:55:32 -0000 --Message-Boundary-11470 Content-type: text/plain; charset=ISO-8859-1 Content-transfer-encoding: Quoted-printable Content-description: Mail message body Please, forgive me for posting this here but I am trying to shoot on every= direction to see if someone can give me any clues or directions on what=B4s going on here I am a true FreeBSDer but this is a system that was dumped right on my lap= , with this problem to be solved. Again, sorry for this inconvinience and thanks for reading. -- //| //|| // | // || -//--//---|| ARIO LOBO // // || --------------------------------- mario.lobo@ipad.com.br http://www.ipad.com.br --Message-Boundary-11470 Content-type: text/plain; charset=US-ASCII Content-disposition: inline Content-description: Attachment information. The following section of this message contains a file attachment prepared for transmission using the Internet MIME message format. If you are using Pegasus Mail, or any other MIME-compliant system, you should be able to save it or view it from within your mailer. If you cannot, please ask your system administrator for assistance. ---- File information ----------- File: Problem.txt Date: 15 Dec 2005, 16:56 Size: 5077 bytes. Type: Text --Message-Boundary-11470 Content-type: Application/Octet-stream; name="Problem.txt"; type=Text Content-disposition: attachment; filename="Problem.txt" Content-transfer-encoding: BASE64 VGhlIHNldHVwIGlzIGFzIGZvbGxvd3M6Cgp8ICBXaW4gWFAgICB8ICAgIHwgbGludXggcm91 dGVyICAgIE9wZW5zd2FuVlBOICB8ICAgICAgICAgICAgICAgICAgICAgICAgfCBPcGVuc3dh blZQTiBsaW51eCByb3V0ZXIgIHwgICAgIHwgV2luIDIwMDAgREIgc2VydmVyIHwKfCAxNS4z LjgzLjIgfC0tLS18IGV0aDE6MTUuMy44My4yMDEgcHBwMC9pcHNlYzAgfC0tLS0tLXsgSU5U RVJORVQgfS0tLS0tLXwgZXRoMC9pcHNlYzAgZXRoMToxMC4wLjAuOCB8LS0tLS18IDEwLjAu MC4yNSAgICAgICAgICB8CgoKCioqKiogQUxMIERVTVBTIGFyZSBmcm9tIHRoZSAxNS4zLjgz LjIwMSBtYWNoaW5lCioqKiogVGhlc2UgZHVtcHMgYXJlIGZyb20gdGhlIGxvZ2luIGF0dGVt cHQgc2VxdWVuY2UgZnJvbSB0aGUgWFAgY2xpZW50IGFwcCwgdG8gdGhlIERCIHNlcnZlciBv biAyMDAwLgoKKioqKiBGcm9tIHRoZSBsaW51eCByb3V0ZXIgMTUuMy44My4yMDEgSSBjYW4g dGVsbmV0IGZpbmUgdG8gV2luIDIwMDAgcG9ydCAxNTAyCioqKiogYnV0IGZyb20gV2luIFhQ IEkgY2FutHQuIEZyb20gV2luIFhQIEkgY2FuIHBpbmcgYW55IG1hY2hpbmUgb24gMTAuMC4w LjAvMjQgd2l0aCBhIHBhY2tldCBzaXplIG9mIHVwIHRvIDE1MDAgYnl0ZXMKCgotLS0tLSBE VU1QUyAtLS0tLQoKKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioq KioqKioqKgo+dGNwZHVtcCAtdiAtaSBldGgxIGhvc3QgMTUuMy44My4yCj50Y3BkdW1wOiBs aXN0ZW5pbmcgb24gZXRoMSwgbGluay10eXBlIEVOMTBNQiAoRXRoZXJuZXQpLCBjYXB0dXJl IHNpemUgOTYgYnl0ZXMKKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioqKioq KioqKioqKioqKgoKMDM6NTA6MDEuNTcwNTgxIElQICh0b3MgMHgwLCB0dGwgMTI4LCBpZCAy NDA2Nywgb2Zmc2V0IDAsIGZsYWdzIFtERl0sIHByb3RvIDYsIGxlbmd0aDogNDgpIDE1LjMu ODMuMi4xMDcwID4gMTAuMC4wLjI1LjE1MDI6IFMgW3RjcCBzdW0gb2tdIDI4ODM5MTU0OjI4 ODM5MTU0KDApIHdpbiA4MTkyIDxtc3MgMTQ2MCxub3Asbm9wLHNhY2tPSz4KCgo9PSBUaGlz IGlzIHRoZSBsaW5lIHRoYXS0cyBicmVha2luZyBldmVyeXRoaW5nLiBXaHkgdGhlIG5lZWQg dG8gZnJhZyBhIDQ4IGJ5dGVzIHBhY2tldCAoc2VlIGxpbmUgKCoqKSBiZWxsb3cpID8/Cgow Mzo1MDowMS41NzA2ODQgSVAgKHRvcyAweGMwLCB0dGwgIDY0LCBpZCAzMTAyNywgb2Zmc2V0 IDAsIGZsYWdzIFtub25lXSwgcHJvdG8gMSwgbGVuZ3RoOiA3NikgMTUuMy44My4yMDEgPiAx NS4zLjgzLjI6IGljbXAgNTY6IDEwLjAuMC4yNSB1bnJlYWNoYWJsZSAtIG5lZWQgdG8gZnJh ZwoKPT0gCgoKMDM6NTA6MDEuNjIzODYzIElQICh0b3MgMHgwLCB0dGwgIDYxLCBpZCAxMjE0 NCwgb2Zmc2V0IDAsIGZsYWdzIFtub25lXSwgcHJvdG8gNiwgbGVuZ3RoOiA0OCkgMTAuMC4w LjI1LjE1MDIgPiAxNS4zLjgzLjIuMTA3MDogUyBbdGNwIHN1bSBva10gMzQ1Njc3NTMwNDoz NDU2Nzc1MzA0KDApIGFjayAyODgzOTE1NSB3aW4gNTg0MCA8bXNzIDE0NjAsbm9wLG5vcCxz YWNrT0s+CjAzOjUwOjAxLjYyMzk1OCBJUCAodG9zIDB4MCwgdHRsIDEyOCwgaWQgMjQzMjMs IG9mZnNldCAwLCBmbGFncyBbbm9uZV0sIHByb3RvIDYsIGxlbmd0aDogNDApIDE1LjMuODMu Mi4xMDcwID4gMTAuMC4wLjI1LjE1MDI6IFIgW3RjcCBzdW0gb2tdIDI4ODM5MTU1OjI4ODM5 MTU1KDApIHdpbiAwCgoKPT0gQW5vdGhlciBhdHRlbXB0CgowMzo1MDowNy41Njk4NzIgSVAg KHRvcyAweDAsIHR0bCAxMjgsIGlkIDI0NTc5LCBvZmZzZXQgMCwgZmxhZ3MgW0RGXSwgcHJv dG8gNiwgbGVuZ3RoOiA0OCkgMTUuMy44My4yLjEwNzAgPiAxMC4wLjAuMjUuMTUwMjogUyBb dGNwIHN1bSBva10gMjg4MzkxNTQ6Mjg4MzkxNTQoMCkgd2luIDgxOTIgPG1zcyAxNDYwLG5v cCxub3Asc2Fja09LPgowMzo1MDowNy41Njk5NzEgSVAgKHRvcyAweGMwLCB0dGwgIDY0LCBp ZCAzMTAyOCwgb2Zmc2V0IDAsIGZsYWdzIFtub25lXSwgcHJvdG8gMSwgbGVuZ3RoOiA3Nikg MTUuMy44My4yMDEgPiAxNS4zLjgzLjI6IGljbXAgNTY6IDEwLjAuMC4yNSB1bnJlYWNoYWJs ZSAtIG5lZWQgdG8gZnJhZwoKPT0KCjAzOjUwOjA3LjYyMzEyOCBJUCAodG9zIDB4MCwgdHRs ICA2MiwgaWQgMTIxNDUsIG9mZnNldCAwLCBmbGFncyBbbm9uZV0sIHByb3RvIDYsIGxlbmd0 aDogNDgpIDEwLjAuMC4yNS4xNTAyID4gMTUuMy44My4yLjEwNzA6IFMgW3RjcCBzdW0gb2td IDM0NjI3NzI1MzM6MzQ2Mjc3MjUzMygwKSBhY2sgMjg4MzkxNTUgd2luIDU4NDAgPG1zcyAx NDYwLG5vcCxub3Asc2Fja09LPgowMzo1MDowNy42MjMyMjkgSVAgKHRvcyAweDAsIHR0bCAx MjgsIGlkIDI0ODM1LCBvZmZzZXQgMCwgZmxhZ3MgW25vbmVdLCBwcm90byA2LCBsZW5ndGg6 IDQwKSAxNS4zLjgzLjIuMTA3MCA+IDEwLjAuMC4yNS4xNTAyOiBSIFt0Y3Agc3VtIG9rXSAy ODgzOTE1NToyODgzOTE1NSgwKSB3aW4gMAoKCioqKioqKioqKioqKioqKioqKioqKioqKioq KioqKioqKioqKioqKioqKioqKioqKioKPnRjcGR1bXAgLXYgLWkgZXRoMSBob3N0IDEwLjAu MC4yNQo+dGNwZHVtcDogbGlzdGVuaW5nIG9uIGV0aDEsIGxpbmstdHlwZSBFTjEwTUIgKEV0 aGVybmV0KSwgY2FwdHVyZSBzaXplIDk2IGJ5dGVzCioqKioqKioqKioqKioqKioqKioqKioq KioqKioqKioqKioqKioqKioqKioqKioqKioKCjAzOjUwOjUxLjUyNDM3MCBJUCAodG9zIDB4 MCwgdHRsIDEyOCwgaWQgMjU2MDMsIG9mZnNldCAwLCBmbGFncyBbREZdLCBwcm90byA2LCBs ZW5ndGg6IDQ4KSAxNS4zLjgzLjIuMTA3MSA+IDEwLjAuMC4yNS4xNTAyOiBTIFt0Y3Agc3Vt IG9rXSAyODg5MjA5NzoyODg5MjA5NygwKSB3aW4gODE5MiA8bXNzIDE0NjAsbm9wLG5vcCxz YWNrT0s+Cgo9PSAoKiopCgowMzo1MDo1MS41ODgzNjUgSVAgKHRvcyAweDAsIHR0bCAgNjIs IGlkIDEyMTQ3LCBvZmZzZXQgMCwgZmxhZ3MgW25vbmVdLCBwcm90byA2LCBsZW5ndGg6IDQ4 KSAxMC4wLjAuMjUuMTUwMiA+IDE1LjMuODMuMi4xMDcxOiBTIFt0Y3Agc3VtIG9rXSAzNDk3 NTE1NjIyOjM0OTc1MTU2MjIoMCkgYWNrIDI4ODkyMDk4IHdpbiA1ODQwIDxtc3MgMTQ2MCxu b3Asbm9wLHNhY2tPSz4KCj09CgowMzo1MDo1MS41ODg1MjkgSVAgKHRvcyAweDAsIHR0bCAx MjgsIGlkIDI1ODU5LCBvZmZzZXQgMCwgZmxhZ3MgW25vbmVdLCBwcm90byA2LCBsZW5ndGg6 IDQwKSAxNS4zLjgzLjIuMTA3MSA+IDEwLjAuMC4yNS4xNTAyOiBSIFt0Y3Agc3VtIG9rXSAy ODg5MjA5ODoyODg5MjA5OCgwKSB3aW4gMAoKPT0gQW5vdGhlciBhdHRlbXB0CgowMzo1MDo1 NC40NjQyOTEgSVAgKHRvcyAweDAsIHR0bCAxMjgsIGlkIDI2MTE1LCBvZmZzZXQgMCwgZmxh Z3MgW0RGXSwgcHJvdG8gNiwgbGVuZ3RoOiA0OCkgMTUuMy44My4yLjEwNzEgPiAxMC4wLjAu MjUuMTUwMjogUyBbdGNwIHN1bSBva10gMjg4OTIwOTc6Mjg4OTIwOTcoMCkgd2luIDgxOTIg PG1zcyAxNDYwLG5vcCxub3Asc2Fja09LPgowMzo1MDo1NC41MTUwMzggSVAgKHRvcyAweDAs IHR0bCAgNjIsIGlkIDEyMTQ4LCBvZmZzZXQgMCwgZmxhZ3MgW25vbmVdLCBwcm90byA2LCBs ZW5ndGg6IDQ4KSAxMC4wLjAuMjUuMTUwMiA+IDE1LjMuODMuMi4xMDcxOiBTIFt0Y3Agc3Vt IG9rXSAzNTAwNDUxNTM0OjM1MDA0NTE1MzQoMCkgYWNrIDI4ODkyMDk4IHdpbiA1ODQwIDxt c3MgMTQ2MCxub3Asbm9wLHNhY2tPSz4KCj09CgowMzo1MDo1NC41MTUxNTcgSVAgKHRvcyAw eDAsIHR0bCAxMjgsIGlkIDI2MzcxLCBvZmZzZXQgMCwgZmxhZ3MgW25vbmVdLCBwcm90byA2 LCBsZW5ndGg6IDQwKSAxNS4zLjgzLjIuMTA3MSA+IDEwLjAuMC4yNS4xNTAyOiBSIFt0Y3Ag c3VtIG9rXSAyODg5MjA5ODoyODg5MjA5OCgwKSB3aW4gMAowMzo1MTowMC40NjM1NjQgSVAg KHRvcyAweDAsIHR0bCAxMjgsIGlkIDI2NjI3LCBvZmZzZXQgMCwgZmxhZ3MgW0RGXSwgcHJv dG8gNiwgbGVuZ3RoOiA0OCkgMTUuMy44My4yLjEwNzEgPiAxMC4wLjAuMjUuMTUwMjogUyBb dGNwIHN1bSBva10gMjg4OTIwOTc6Mjg4OTIwOTcoMCkgd2luIDgxOTIgPG1zcyAxNDYwLG5v cCxub3Asc2Fja09LPgowMzo1MTowMC41MTYzMDAgSVAgKHRvcyAweDAsIHR0bCAgNjIsIGlk IDEyMTQ5LCBvZmZzZXQgMCwgZmxhZ3MgW25vbmVdLCBwcm90byA2LCBsZW5ndGg6IDQ4KSAx MC4wLjAuMjUuMTUwMiA+IDE1LjMuODMuMi4xMDcxOiBTIFt0Y3Agc3VtIG9rXSAzNTA2NDUx Mzg1OjM1MDY0NTEzODUoMCkgYWNrIDI4ODkyMDk4IHdpbiA1ODQwIDxtc3MgMTQ2MCxub3As bm9wLHNhY2tPSz4KMDM6NTE6MDAuNTE2NDIwIElQICh0b3MgMHgwLCB0dGwgMTI4LCBpZCAy Njg4Mywgb2Zmc2V0IDAsIGZsYWdzIFtub25lXSwgcHJvdG8gNiwgbGVuZ3RoOiA0MCkgMTUu My44My4yLjEwNzEgPiAxMC4wLjAuMjUuMTUwMjogUiBbdGNwIHN1bSBva10gMjg4OTIwOTg6 Mjg4OTIwOTgoMCkgd2luIDAKMDM6NTE6MTIuNDYyMTU0IElQICh0b3MgMHgwLCB0dGwgMTI4 LCBpZCAyNzEzOSwgb2Zmc2V0IDAsIGZsYWdzIFtERl0sIHByb3RvIDYsIGxlbmd0aDogNDgp IDE1LjMuODMuMi4xMDcxID4gMTAuMC4wLjI1LjE1MDI6IFMgW3RjcCBzdW0gb2tdIDI4ODky MDk3OjI4ODkyMDk3KDApIHdpbiA4MTkyIDxtc3MgMTQ2MCxub3Asbm9wLHNhY2tPSz4KMDM6 NTE6MTIuNTE3NjI5IElQICh0b3MgMHgwLCB0dGwgIDYyLCBpZCAxMjE1MCwgb2Zmc2V0IDAs IGZsYWdzIFtub25lXSwgcHJvdG8gNiwgbGVuZ3RoOiA0OCkgMTAuMC4wLjI1LjE1MDIgPiAx NS4zLjgzLjIuMTA3MTogUyBbdGNwIHN1bSBva10gMzUxODQ0ODQxNjozNTE4NDQ4NDE2KDAp IGFjayAyODg5MjA5OCB3aW4gNTg0MCA8bXNzIDE0NjAsbm9wLG5vcCxzYWNrT0s+CjAzOjUx OjEyLjUxNzc1NiBJUCAodG9zIDB4MCwgdHRsIDEyOCwgaWQgMjczOTUsIG9mZnNldCAwLCBm bGFncyBbbm9uZV0sIHByb3RvIDYsIGxlbmd0aDogNDApIDE1LjMuODMuMi4xMDcxID4gMTAu MC4wLjI1LjE1MDI6IFIgW3RjcCBzdW0gb2tdIDI4ODkyMDk4OjI4ODkyMDk4KDApIHdpbiAw Cg== --Message-Boundary-11470-- From owner-freebsd-hackers@FreeBSD.ORG Thu Dec 15 22:35:22 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id DE7AD16A41F; Thu, 15 Dec 2005 22:35:22 +0000 (GMT) (envelope-from dunstan@freebsd.czest.pl) Received: from freebsd.czest.pl (freebsd.czest.pl [80.48.250.4]) by mx1.FreeBSD.org (Postfix) with ESMTP id 3F51B43D62; Thu, 15 Dec 2005 22:35:22 +0000 (GMT) (envelope-from dunstan@freebsd.czest.pl) Received: from freebsd.czest.pl (freebsd.czest.pl [80.48.250.4]) by freebsd.czest.pl (8.12.10/8.12.9) with ESMTP id jBFMbjPx037825; Thu, 15 Dec 2005 22:37:45 GMT (envelope-from dunstan@freebsd.czest.pl) Received: (from dunstan@localhost) by freebsd.czest.pl (8.13.4/8.12.9/Submit) id jBFMbj7v037824; Thu, 15 Dec 2005 22:37:45 GMT (envelope-from dunstan) Date: Thu, 15 Dec 2005 22:37:45 +0000 From: "Wojciech A. Koszek" To: freebsd-hackers@freebsd.org Message-ID: <20051215223745.GA37768@FreeBSD.czest.pl> Mime-Version: 1.0 Content-Type: text/plain; charset=iso-8859-2 Content-Disposition: inline User-Agent: Mutt/1.4.2.1i Cc: phk@freebsd.org Subject: [CALL FOR TESTERS] New system call: abort2() X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 15 Dec 2005 22:35:23 -0000 (discussed task was picked from Poul-Henning Kamp's TODO list) Hackers, I've implemented abort2() system call. Works just like abort(3), but delivers signal reliably. Here is a prototype: abort2(const char *why, int nargs, void **args); "why" is reason of program abort, "nargs" is number of arguments passed in "args". Both "why" and "args" (with "%p" format) will be printed via log(9). Sample output: [..] pid <3004> abort2: ABORT2 pid <3019> abort2: invalid argument [..] I put two versions: one implemented as KLD so that more people can test it without a problem: http://freebsd.czest.pl/dunstan/FreeBSD/abort2/abort2-0.3.tgz ..and also as a patch: http://freebsd.czest.pl/dunstan/FreeBSD/abort2/diff.1.abort2-sycall If I miss some tests, please let me know, especially in user<->kernelspace interaction area. (currently I run patched kernel and couldn't get a panic in testing process). Short description - function: abort2(const char *why, int nargs, void **args); ..never returns. If improper arguments are used, instead of SIGABRT, SIGKILL is delivered. By improper arguments I understand: invalid pointers -- "why" or "args" or 0 > "nargs" > 16. Comments are welcome! -- * Wojciech A. Koszek && dunstan@FreeBSD.czest.pl From owner-freebsd-hackers@FreeBSD.ORG Thu Dec 15 23:17:35 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id DBE4816A41F; Thu, 15 Dec 2005 23:17:34 +0000 (GMT) (envelope-from V.Haisman@sh.cvut.cz) Received: from service.sh.cvut.cz (service.sh.cvut.cz [147.32.127.214]) by mx1.FreeBSD.org (Postfix) with ESMTP id B532243D5A; Thu, 15 Dec 2005 23:17:32 +0000 (GMT) (envelope-from V.Haisman@sh.cvut.cz) Received: from localhost (localhost [127.0.0.1]) by service.sh.cvut.cz (Postfix) with ESMTP id 399011A3718; Fri, 16 Dec 2005 00:17:31 +0100 (CET) Received: from service.sh.cvut.cz ([127.0.0.1]) by localhost (service [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 21439-01; Fri, 16 Dec 2005 00:17:27 +0100 (CET) Received: from logout.sh.cvut.cz (logout.sh.cvut.cz [147.32.127.203]) by service.sh.cvut.cz (Postfix) with ESMTP id 58B561A3715; Fri, 16 Dec 2005 00:17:27 +0100 (CET) Received: from [192.168.1.2] (localhost [127.0.0.1]) by logout.sh.cvut.cz (Postfix) with ESMTP id 1E45F61C1F; Fri, 16 Dec 2005 00:21:36 +0100 (CET) Message-ID: <43A1F97A.3060102@sh.cvut.cz> Date: Fri, 16 Dec 2005 00:17:14 +0100 From: =?UTF-8?B?VsOhY2xhdiBIYWlzbWFu?= User-Agent: Mozilla Thunderbird 1.0.7 (Windows/20050923) X-Accept-Language: en-us, en MIME-Version: 1.0 To: "Wojciech A. Koszek" References: <20051215223745.GA37768@FreeBSD.czest.pl> In-Reply-To: <20051215223745.GA37768@FreeBSD.czest.pl> X-Enigmail-Version: 0.93.0.0 OpenPGP: id=733031B4 Face: iVBORw0KGgoAAAANSUhEUgAAADAAAAAwBAMAAAClLOS0AAAAMFBMVEUnMzWJm5S+0864pn5r blp/hnW2up7X7uqftbNRVUrW1LGBdGfHwJqPi3ScoYtBQzhDxGEwAAAAB3RJTUUH1QoQDDgyQtx8 HQAAAkNJREFUeJzFU0toU0EUPYu66CpGdCUUmoUJkpUDQUoNBVEUrBJsq1Ki2EIKIUZ8mydBhYi0 wVUXJVCLCrFN4DIEQdxIqdBIFsMkWD9YJClCRGKjJaviynjfe8RPogtXPcObuXPOPXd+PHj+Aeyo QNmobGLXVeANGM+GsP0B2yqHHNVoCD2LwLglVGZx7yXSlADR0uZu9C4Bpy3hUxPvH/cuUw6UoPCL h64I8KAJuMpwRU8uUMJy0OIpHVeXmulZoCc/t0LlTbJLEY1EudPRcnVjgAP5Osdl4K5HVP4+2bAI okaUA0Iq6Q59+Zy2eMWN6EpFTsa3+uD1+JKj4TPHuYTSMaLScLAaqk94YJqG4ds30hojOVgYoNJc NTztNU2TBYbhu9Aafnq08ORja37da1NwBrN/b7NVEc+b8yecuYkp08vNvLYneVZRaSH1vS0UnfHm OUPzWaZufHPmCWSdWrfeGVQQKmcsO4If8pAdXJ/xF4QQAeOVY1AQQcfirwkLUWeWVTgi6vaGt2xe BGzBEIMQorru8RxgPqY1V6uxYnwVBRZEI1ytCm3dE8mC2DgcbzCJGHdBEVDKuWDSwsrSGoqzJmNt 2jJpNueIH0qS8/0JrDKnVBdvOzIsdVr4zaX9dn9xcLLKdCtQGfutVacLE9Ja+yfbDvO4aMWrklfK /JYv15C8Kw9S10kup5Bys0N1bLdcn4HvTl/Xlh6Fpllwj5/XpH9BUXn/ym0Dvv7Rt2MywojpYiSi i7Hsscaa19zZ//y/hR+BT/ns80nmJAAAAABJRU5ErkJggg== Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="------------enigE53270F597569BF16AC1E89D" X-Virus-Scanned: by amavisd-new at sh.cvut.cz Cc: freebsd-hackers@freebsd.org, phk@freebsd.org Subject: Re: [CALL FOR TESTERS] New system call: abort2() X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 15 Dec 2005 23:17:35 -0000 This is an OpenPGP/MIME signed message (RFC 2440 and 3156) --------------enigE53270F597569BF16AC1E89D Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit Wojciech A. Koszek wrote: [...] > Comments are welcome! As for the patch, the use of do {} while(0) instead of goto looks odd to me. I would like to comment on FreeBSD style(9) a bit. Why does not mention or even encourage C99 style // comments? They are nice when one wants to comment out bigger chunks of code with /**/ comment. On the similar note, the ability to move declarations closer to the point of use in code is IMO nice feature, too. The style(9) doesn't mention this either. Vaclav Haisman --------------enigE53270F597569BF16AC1E89D Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.1 (MingW32) Comment: Using GnuPG with Thunderbird - http://enigmail.mozdev.org iQEVAwUBQ6H5gm56zbtzMDG0AQLglQf/cbfD2GjmmNzg56Q54jZFdabVXMnAdiYG Dfu7+bBy9IFdKow1hF08W3sd2TYK5Byfb8PHeTdppUdl9tmKPpg61yduuUEkEJYy IOnpig5QWkZG3Mq+80BSAlBzfcBqKXmF0wsYKnTyApMTK1ISyHiFDkmNNhKUEPTV 6/xhjeUC0Zfjo8cMLAstmaA5e37OzGYX5wdrayRKTjKmN2OSIl1DuQB2I2WKfNd+ j6nTpP+Gf78petjtMIbdVOwAHz0Z2hrM+V7sxgPoPLgxN1wLTsPZJnTR34PxUS81 IEt0XfHf2FtCmusZH4AqaFqNWWoM1B1L3MrzE65Ezra5iH2nOsJpiw== =MNXn -----END PGP SIGNATURE----- --------------enigE53270F597569BF16AC1E89D-- From owner-freebsd-hackers@FreeBSD.ORG Thu Dec 15 23:22:10 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id C7B6B16A41F for ; Thu, 15 Dec 2005 23:22:10 +0000 (GMT) (envelope-from joerg@britannica.bec.de) Received: from hydra.bec.de (www.ostsee-abc.de [62.206.222.50]) by mx1.FreeBSD.org (Postfix) with ESMTP id 536CF43D55 for ; Thu, 15 Dec 2005 23:22:10 +0000 (GMT) (envelope-from joerg@britannica.bec.de) Received: from britannica.bec.de (storm.stura.uni-rostock.de [139.30.252.72]) by hydra.bec.de (Postfix) with ESMTP id 6C2B235707 for ; Fri, 16 Dec 2005 00:22:08 +0100 (CET) Received: by britannica.bec.de (Postfix, from userid 1000) id A17DE6D047; Fri, 16 Dec 2005 00:21:43 +0100 (CET) Date: Fri, 16 Dec 2005 00:21:43 +0100 From: joerg@britannica.bec.de To: freebsd-hackers@freebsd.org Message-ID: <20051215232143.GC203@britannica.bec.de> Mail-Followup-To: freebsd-hackers@freebsd.org References: <20051215223745.GA37768@FreeBSD.czest.pl> <43A1F97A.3060102@sh.cvut.cz> Mime-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <43A1F97A.3060102@sh.cvut.cz> User-Agent: Mutt/1.5.11 Subject: Re: [CALL FOR TESTERS] New system call: abort2() X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 15 Dec 2005 23:22:10 -0000 On Fri, Dec 16, 2005 at 12:17:14AM +0100, Václav Haisman wrote: > > I would like to comment on FreeBSD style(9) a bit. Why does not mention > or even encourage C99 style // comments? They are nice when one wants to > comment out bigger chunks of code with /**/ comment. Use #if 0 ... #endif for that. Joerg > On the similar note, the ability to move declarations closer to the > point of use in code is IMO nice feature, too. The style(9) doesn't > mention this either. Because it is not necessarily a good thing. Joerg From owner-freebsd-hackers@FreeBSD.ORG Thu Dec 15 23:24:27 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 79D4716A41F; Thu, 15 Dec 2005 23:24:27 +0000 (GMT) (envelope-from imp@bsdimp.com) Received: from harmony.bsdimp.com (vc4-2-0-87.dsl.netrack.net [199.45.160.85]) by mx1.FreeBSD.org (Postfix) with ESMTP id C2ABA43D60; Thu, 15 Dec 2005 23:24:26 +0000 (GMT) (envelope-from imp@bsdimp.com) Received: from localhost (localhost.village.org [127.0.0.1] (may be forged)) by harmony.bsdimp.com (8.13.3/8.13.3) with ESMTP id jBFNNqY4054444; Thu, 15 Dec 2005 16:23:52 -0700 (MST) (envelope-from imp@bsdimp.com) Date: Thu, 15 Dec 2005 16:23:52 -0700 (MST) Message-Id: <20051215.162352.28837879.imp@bsdimp.com> To: V.Haisman@sh.cvut.cz From: Warner Losh In-Reply-To: <43A1F97A.3060102@sh.cvut.cz> References: <20051215223745.GA37768@FreeBSD.czest.pl> <43A1F97A.3060102@sh.cvut.cz> X-Mailer: Mew version 3.3 on Emacs 21.3 / Mule 5.0 (SAKAKI) Mime-Version: 1.0 Content-Type: Text/Plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-2.0 (harmony.bsdimp.com [127.0.0.1]); Thu, 15 Dec 2005 16:23:52 -0700 (MST) Cc: freebsd-hackers@freebsd.org, dunstan@freebsd.czest.pl, phk@freebsd.org Subject: Re: [CALL FOR TESTERS] New system call: abort2() X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 15 Dec 2005 23:24:27 -0000 > I would like to comment on FreeBSD style(9) a bit. Why does not mention > or even encourage C99 style // comments? They are nice when one wants to > comment out bigger chunks of code with /**/ comment. Too new. /**/ comment out is bogus anyway. #if 0 ... #endif is better. > On the similar note, the ability to move declarations closer to the > point of use in code is IMO nice feature, too. The style(9) doesn't > mention this either. C doesn't allow it, or didn't until recently. That style tends to lead to really gross things too. Functions should be short enough that it doesn't matter. But changing style(9) is hard. We have better things to do with our lives. :-) Warner From owner-freebsd-hackers@FreeBSD.ORG Thu Dec 15 23:32:14 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 0D79016A41F for ; Thu, 15 Dec 2005 23:32:14 +0000 (GMT) (envelope-from phk@critter.freebsd.dk) Received: from phk.freebsd.dk (phk.freebsd.dk [130.225.244.222]) by mx1.FreeBSD.org (Postfix) with ESMTP id 0221D43D8A for ; Thu, 15 Dec 2005 23:32:10 +0000 (GMT) (envelope-from phk@critter.freebsd.dk) Received: from critter.freebsd.dk (unknown [192.168.48.2]) by phk.freebsd.dk (Postfix) with ESMTP id 1D181BC66; Thu, 15 Dec 2005 23:32:09 +0000 (UTC) To: Warner Losh From: "Poul-Henning Kamp" In-Reply-To: Your message of "Thu, 15 Dec 2005 16:23:52 MST." <20051215.162352.28837879.imp@bsdimp.com> Date: Fri, 16 Dec 2005 00:32:09 +0100 Message-ID: <2936.1134689529@critter.freebsd.dk> Sender: phk@critter.freebsd.dk Cc: freebsd-hackers@freebsd.org, dunstan@freebsd.czest.pl Subject: Re: [CALL FOR TESTERS] New system call: abort2() X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 15 Dec 2005 23:32:14 -0000 In message <20051215.162352.28837879.imp@bsdimp.com>, Warner Losh writes: >> On the similar note, the ability to move declarations closer to the >> point of use in code is IMO nice feature, too. The style(9) doesn't >> mention this either. > >C doesn't allow it, or didn't until recently. That style tends to >lead to really gross things too. Functions should be short enough >that it doesn't matter. Also, it tends to make it harder to judge the amount of stackspace a function uses, something which is not entirely uninteresting in kernel programming. And yes, changing style(9) is just not worth the time it takes. -- Poul-Henning Kamp | UNIX since Zilog Zeus 3.20 phk@FreeBSD.ORG | TCP/IP since RFC 956 FreeBSD committer | BSD since 4.3-tahoe Never attribute to malice what can adequately be explained by incompetence. From owner-freebsd-hackers@FreeBSD.ORG Thu Dec 15 23:35:26 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 8159616A41F for ; Thu, 15 Dec 2005 23:35:26 +0000 (GMT) (envelope-from V.Haisman@sh.cvut.cz) Received: from service.sh.cvut.cz (service.sh.cvut.cz [147.32.127.214]) by mx1.FreeBSD.org (Postfix) with ESMTP id 7BF7443D5A for ; Thu, 15 Dec 2005 23:35:25 +0000 (GMT) (envelope-from V.Haisman@sh.cvut.cz) Received: from localhost (localhost [127.0.0.1]) by service.sh.cvut.cz (Postfix) with ESMTP id BEC431A3706; Fri, 16 Dec 2005 00:35:24 +0100 (CET) Received: from service.sh.cvut.cz ([127.0.0.1]) by localhost (service [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 21771-02; Fri, 16 Dec 2005 00:35:20 +0100 (CET) Received: from logout.sh.cvut.cz (logout.sh.cvut.cz [147.32.127.203]) by service.sh.cvut.cz (Postfix) with ESMTP id 503881A32FC; Fri, 16 Dec 2005 00:35:20 +0100 (CET) Received: from [192.168.1.2] (localhost [127.0.0.1]) by logout.sh.cvut.cz (Postfix) with ESMTP id 87B7361C37; Fri, 16 Dec 2005 00:39:32 +0100 (CET) Message-ID: <43A1FDB0.8090907@sh.cvut.cz> Date: Fri, 16 Dec 2005 00:35:12 +0100 From: =?UTF-8?B?VsOhY2xhdiBIYWlzbWFu?= User-Agent: Mozilla Thunderbird 1.0.7 (Windows/20050923) X-Accept-Language: en-us, en MIME-Version: 1.0 To: joerg@britannica.bec.de References: <20051215223745.GA37768@FreeBSD.czest.pl> <43A1F97A.3060102@sh.cvut.cz> <20051215232143.GC203@britannica.bec.de> In-Reply-To: <20051215232143.GC203@britannica.bec.de> X-Enigmail-Version: 0.93.0.0 OpenPGP: id=733031B4 Face: iVBORw0KGgoAAAANSUhEUgAAADAAAAAwBAMAAAClLOS0AAAAMFBMVEUnMzWJm5S+0864pn5r blp/hnW2up7X7uqftbNRVUrW1LGBdGfHwJqPi3ScoYtBQzhDxGEwAAAAB3RJTUUH1QoQDDgyQtx8 HQAAAkNJREFUeJzFU0toU0EUPYu66CpGdCUUmoUJkpUDQUoNBVEUrBJsq1Ki2EIKIUZ8mydBhYi0 wVUXJVCLCrFN4DIEQdxIqdBIFsMkWD9YJClCRGKjJaviynjfe8RPogtXPcObuXPOPXd+PHj+Aeyo QNmobGLXVeANGM+GsP0B2yqHHNVoCD2LwLglVGZx7yXSlADR0uZu9C4Bpy3hUxPvH/cuUw6UoPCL h64I8KAJuMpwRU8uUMJy0OIpHVeXmulZoCc/t0LlTbJLEY1EudPRcnVjgAP5Osdl4K5HVP4+2bAI okaUA0Iq6Q59+Zy2eMWN6EpFTsa3+uD1+JKj4TPHuYTSMaLScLAaqk94YJqG4ds30hojOVgYoNJc NTztNU2TBYbhu9Aafnq08ORja37da1NwBrN/b7NVEc+b8yecuYkp08vNvLYneVZRaSH1vS0UnfHm OUPzWaZufHPmCWSdWrfeGVQQKmcsO4If8pAdXJ/xF4QQAeOVY1AQQcfirwkLUWeWVTgi6vaGt2xe BGzBEIMQorru8RxgPqY1V6uxYnwVBRZEI1ytCm3dE8mC2DgcbzCJGHdBEVDKuWDSwsrSGoqzJmNt 2jJpNueIH0qS8/0JrDKnVBdvOzIsdVr4zaX9dn9xcLLKdCtQGfutVacLE9Ja+yfbDvO4aMWrklfK /JYv15C8Kw9S10kup5Bys0N1bLdcn4HvTl/Xlh6Fpllwj5/XpH9BUXn/ym0Dvv7Rt2MywojpYiSi i7Hsscaa19zZ//y/hR+BT/ns80nmJAAAAABJRU5ErkJggg== Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="------------enigB4F4992ED4E327B5EDCFF4D3" X-Virus-Scanned: by amavisd-new at sh.cvut.cz Cc: freebsd-hackers@freebsd.org Subject: Re: [CALL FOR TESTERS] New system call: abort2() X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 15 Dec 2005 23:35:26 -0000 This is an OpenPGP/MIME signed message (RFC 2440 and 3156) --------------enigB4F4992ED4E327B5EDCFF4D3 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable joerg@britannica.bec.de wrote: > On Fri, Dec 16, 2005 at 12:17:14AM +0100, V=C3=A1clav Haisman wrote: >=20 >>I would like to comment on FreeBSD style(9) a bit. Why does not mention= >>or even encourage C99 style // comments? They are nice when one wants t= o >>comment out bigger chunks of code with /**/ comment. >=20 >=20 > Use #if 0 ... #endif for that. Well, that was the only option in time of C90, now we have IMO better facility for this. Also most editors do not mark such code as commented out which might a bit inconvenient. >=20 > Joerg >=20 >=20 >>On the similar note, the ability to move declarations closer to the >>point of use in code is IMO nice feature, too. The style(9) doesn't >>mention this either. >=20 >=20 > Because it is not necessarily a good thing. I am of different opinion but I will leave it at that. >=20 > Joerg Vaclav Haisman --------------enigB4F4992ED4E327B5EDCFF4D3 Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.1 (MingW32) Comment: Using GnuPG with Thunderbird - http://enigmail.mozdev.org iQEVAwUBQ6H9t256zbtzMDG0AQKktgf+NJyTKJv0iIdUywqhOFjppnyvOHBxt9b2 fzKNYkDG0VvGTogfepFrlKHtJLRE4ZPdxRB59mfE7h6WYFaMXPqOnQ41F4wohchR ez1wqKRCzPoQkn/nTF8eq41sh0dJjR83EOH+unDxhmmq3qTbQhg86kd5JfM4KSbp xPCU+ohbRBrtDbKP71xj7kUbji6oNYMBZgs+Psl8oHKpEIUT/Ve1rsMDVDiy1jqQ V6UBjau+1rO/zFyFQZ/50EFhi3JOnYmiHCjL9kir5beVyGEfxX3ceWZlkaZIRHP3 fe5mNIgIi/Nm3jsUIVzS8PerpmUYoUY207s6QuaTTO53BJm+pN04CA== =hsox -----END PGP SIGNATURE----- --------------enigB4F4992ED4E327B5EDCFF4D3-- From owner-freebsd-hackers@FreeBSD.ORG Thu Dec 15 23:58:21 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 3777316A41F for ; Thu, 15 Dec 2005 23:58:21 +0000 (GMT) (envelope-from V.Haisman@sh.cvut.cz) Received: from service.sh.cvut.cz (service.sh.cvut.cz [147.32.127.214]) by mx1.FreeBSD.org (Postfix) with ESMTP id 430FE43D60 for ; Thu, 15 Dec 2005 23:58:20 +0000 (GMT) (envelope-from V.Haisman@sh.cvut.cz) Received: from localhost (localhost [127.0.0.1]) by service.sh.cvut.cz (Postfix) with ESMTP id E23C51A371F; Fri, 16 Dec 2005 00:58:18 +0100 (CET) Received: from service.sh.cvut.cz ([127.0.0.1]) by localhost (service [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 22256-06; Fri, 16 Dec 2005 00:58:15 +0100 (CET) Received: from logout.sh.cvut.cz (logout.sh.cvut.cz [147.32.127.203]) by service.sh.cvut.cz (Postfix) with ESMTP id 041B21A3719; Fri, 16 Dec 2005 00:58:15 +0100 (CET) Received: from [192.168.1.2] (localhost [127.0.0.1]) by logout.sh.cvut.cz (Postfix) with ESMTP id 814DD61C1F; Fri, 16 Dec 2005 01:02:27 +0100 (CET) Message-ID: <43A20303.6020005@sh.cvut.cz> Date: Fri, 16 Dec 2005 00:57:55 +0100 From: =?UTF-8?B?VsOhY2xhdiBIYWlzbWFu?= User-Agent: Mozilla Thunderbird 1.0.7 (Windows/20050923) X-Accept-Language: en-us, en MIME-Version: 1.0 To: Poul-Henning Kamp References: <2936.1134689529@critter.freebsd.dk> In-Reply-To: <2936.1134689529@critter.freebsd.dk> X-Enigmail-Version: 0.93.0.0 OpenPGP: id=733031B4 Face: iVBORw0KGgoAAAANSUhEUgAAADAAAAAwBAMAAAClLOS0AAAAMFBMVEUnMzWJm5S+0864pn5r blp/hnW2up7X7uqftbNRVUrW1LGBdGfHwJqPi3ScoYtBQzhDxGEwAAAAB3RJTUUH1QoQDDgyQtx8 HQAAAkNJREFUeJzFU0toU0EUPYu66CpGdCUUmoUJkpUDQUoNBVEUrBJsq1Ki2EIKIUZ8mydBhYi0 wVUXJVCLCrFN4DIEQdxIqdBIFsMkWD9YJClCRGKjJaviynjfe8RPogtXPcObuXPOPXd+PHj+Aeyo QNmobGLXVeANGM+GsP0B2yqHHNVoCD2LwLglVGZx7yXSlADR0uZu9C4Bpy3hUxPvH/cuUw6UoPCL h64I8KAJuMpwRU8uUMJy0OIpHVeXmulZoCc/t0LlTbJLEY1EudPRcnVjgAP5Osdl4K5HVP4+2bAI okaUA0Iq6Q59+Zy2eMWN6EpFTsa3+uD1+JKj4TPHuYTSMaLScLAaqk94YJqG4ds30hojOVgYoNJc NTztNU2TBYbhu9Aafnq08ORja37da1NwBrN/b7NVEc+b8yecuYkp08vNvLYneVZRaSH1vS0UnfHm OUPzWaZufHPmCWSdWrfeGVQQKmcsO4If8pAdXJ/xF4QQAeOVY1AQQcfirwkLUWeWVTgi6vaGt2xe BGzBEIMQorru8RxgPqY1V6uxYnwVBRZEI1ytCm3dE8mC2DgcbzCJGHdBEVDKuWDSwsrSGoqzJmNt 2jJpNueIH0qS8/0JrDKnVBdvOzIsdVr4zaX9dn9xcLLKdCtQGfutVacLE9Ja+yfbDvO4aMWrklfK /JYv15C8Kw9S10kup5Bys0N1bLdcn4HvTl/Xlh6Fpllwj5/XpH9BUXn/ym0Dvv7Rt2MywojpYiSi i7Hsscaa19zZ//y/hR+BT/ns80nmJAAAAABJRU5ErkJggg== Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="------------enig990A9AB4B4BAC8A7A0E8AFEC" X-Virus-Scanned: by amavisd-new at sh.cvut.cz Cc: freebsd-hackers@freebsd.org, dunstan@freebsd.czest.pl Subject: Re: [CALL FOR TESTERS] New system call: abort2() X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 15 Dec 2005 23:58:21 -0000 This is an OpenPGP/MIME signed message (RFC 2440 and 3156) --------------enig990A9AB4B4BAC8A7A0E8AFEC Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit Poul-Henning Kamp wrote: > In message <20051215.162352.28837879.imp@bsdimp.com>, Warner Losh writes: > > >>>On the similar note, the ability to move declarations closer to the >>>point of use in code is IMO nice feature, too. The style(9) doesn't >>>mention this either. >> >>C doesn't allow it, or didn't until recently. That style tends to >>lead to really gross things too. Functions should be short enough >>that it doesn't matter. (I haven't gotten this email yet.) Anything can lead to really gross things if misused. > > > Also, it tends to make it harder to judge the amount of stackspace > a function uses, something which is not entirely uninteresting in > kernel programming. While it might be harder to get estimate of stack space allocation I suspect it could actually lower the allocation. > > And yes, changing style(9) is just not worth the time it takes. > Vaclav Haisman --------------enig990A9AB4B4BAC8A7A0E8AFEC Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.1 (MingW32) Comment: Using GnuPG with Thunderbird - http://enigmail.mozdev.org iQEVAwUBQ6IDF256zbtzMDG0AQJRtAf/StPgSCbm2aW+59UBM+9ET+Rn9UjnZSpm n7TMgQibWfbeXsiVQguUMxC+Uc49x1BOTpSsEdymGfyX1GOIu3Qb+t2U8V/EU3gp e4xifWmL5OsDYtUOVC11t6GD7IsVsRQ8arabsaoU67i0pFIdipM8acd54x/NuP6W 5YI93pi+NjHsziOd/lLXDLf/J23UHrsZfD/wywCvtGPmh9tm2P4+kVzN48lD7eUe p1V7fwMv1uLV7Fqzoik4+2Wr9vHiKR2cTD4fQ+u5db8T/rNwIAXXaieD7fVaimwb pbs1Tb4l4NBMjW2RGrYQ0lRGCZLRvekC7OO86z2STaDp5fxzbxE3Ig== =+jU4 -----END PGP SIGNATURE----- --------------enig990A9AB4B4BAC8A7A0E8AFEC-- From owner-freebsd-hackers@FreeBSD.ORG Fri Dec 16 01:27:41 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 4DC2C16A420 for ; Fri, 16 Dec 2005 01:27:41 +0000 (GMT) (envelope-from imp@bsdimp.com) Received: from harmony.bsdimp.com (vc4-2-0-87.dsl.netrack.net [199.45.160.85]) by mx1.FreeBSD.org (Postfix) with ESMTP id A791943D5C for ; Fri, 16 Dec 2005 01:27:40 +0000 (GMT) (envelope-from imp@bsdimp.com) Received: from localhost (localhost.village.org [127.0.0.1] (may be forged)) by harmony.bsdimp.com (8.13.3/8.13.3) with ESMTP id jBG1QPeU055240; Thu, 15 Dec 2005 18:26:25 -0700 (MST) (envelope-from imp@bsdimp.com) Date: Thu, 15 Dec 2005 18:26:25 -0700 (MST) Message-Id: <20051215.182625.102526893.imp@bsdimp.com> To: V.Haisman@sh.cvut.cz From: Warner Losh In-Reply-To: <43A20303.6020005@sh.cvut.cz> References: <2936.1134689529@critter.freebsd.dk> <43A20303.6020005@sh.cvut.cz> X-Mailer: Mew version 3.3 on Emacs 21.3 / Mule 5.0 (SAKAKI) Mime-Version: 1.0 Content-Type: Text/Plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-2.0 (harmony.bsdimp.com [127.0.0.1]); Thu, 15 Dec 2005 18:26:27 -0700 (MST) Cc: freebsd-hackers@freebsd.org, phk@phk.freebsd.dk, dunstan@freebsd.czest.pl Subject: Re: [CALL FOR TESTERS] New system call: abort2() X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Dec 2005 01:27:41 -0000 > > Also, it tends to make it harder to judge the amount of stackspace > > a function uses, something which is not entirely uninteresting in > > kernel programming. > While it might be harder to get estimate of stack space allocation I > suspect it could actually lower the allocation. Maybe, maybe not. Experience has shown that putting things in inner scopes only sometimes reduces stack usage, and then it depends on the compiler, options used, etc. Warner From owner-freebsd-hackers@FreeBSD.ORG Fri Dec 16 02:32:44 2005 Return-Path: X-Original-To: hackers@freebsd.org Delivered-To: freebsd-hackers@FreeBSD.ORG Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id B4F4616A41F for ; Fri, 16 Dec 2005 02:32:44 +0000 (GMT) (envelope-from anthony.maher@uts.edu.au) Received: from zim.itd.uts.edu.au (zim.itd.uts.edu.au [138.25.22.46]) by mx1.FreeBSD.org (Postfix) with ESMTP id 4FAD843D5E for ; Fri, 16 Dec 2005 02:32:31 +0000 (GMT) (envelope-from anthony.maher@uts.edu.au) Received: by zim.itd.uts.edu.au (Postfix, from userid 900) id A701BC3474; Fri, 16 Dec 2005 13:32:29 +1100 (EST) Received: from vimes (vimes.itd.uts.edu.au [138.25.243.34])by zim.itd.uts.edu.au (Postfix/Ingress) with ESMTP id B3FB0C3484for ; Fri, 16 Dec 2005 13:28:43 +1100 (EST) Received: from [138.25.81.152] by postoffice.uts.edu.au(Sun Java System Messaging Server 6.1 HotFix 0.09 (built Dec 14 2004))with ESMTPS id <0IRK00JXAK7VMP40@postoffice.uts.edu.au> forhackers@freebsd.org; Fri, 16 Dec 2005 13:28:43 +1100 (EST) Date: Fri, 16 Dec 2005 13:28:43 +1100 From: Tony Maher To: hackers@freebsd.org Message-id: <43A2265B.5070706@uts.edu.au> MIME-version: 1.0 Content-type: text/plain; charset=us-ascii Content-transfer-encoding: 7BIT X-Accept-Language: en-us, en X-Enigmail-Version: 0.93.0.0 User-Agent: Mozilla/5.0 (X11; U; FreeBSD i386; en-US; rv:1.7.12) Gecko/20051109 X-Virus-Scanned: amavisd-new at uts.edu.au Cc: Subject: mathematica/mathlink/python/linux X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Dec 2005 02:32:44 -0000 Hello, I have installed Mathematica (v5.2) on FreeBSD 5-stable. All works fine. I am now trying to get the Python bindings to MathLink to work. I can build ok but it links against the Mathematica library (ML) which is linux. When I import mathlink I get undefined symbol "stdout" message (stdout used in libML). In FreeBSD this symbol appears to be __stdoutp. ldd /usr/local/lib/python2.4/site-packages/mathlink.so /usr/local/lib/python2.4/site-packages/mathlink.so: libm.so.3 => /lib/libm.so.3 (0x481b6000) If I modify setup.py to specify libm as libm-2.3.2 (the linux one) ldd /usr/local/lib/python2.4/site-packages/mathlink.so /usr/local/lib/python2.4/site-packages/mathlink.so: libm.so.6 => /compat/linux/lib/libm.so.6 (0x481b6000) libc.so.6 => /compat/linux/lib/libc.so.6 (0x481d7000) ld-linux.so.2 (0x48302000) Then import fails with segmentation violation. Is there any way around this or is it a hopeless cause? (I could build a linux version of python on my system and then it shoudl work but that is not ideal) thanks -- tonym -- UTS CRICOS Provider Code: 00099F DISCLAIMER: This email message and any accompanying attachments may contain confidential information. If you are not the intended recipient, do not read, use, disseminate, distribute or copy this message or attachments. If you have received this message in error, please notify the sender immediately and delete this message. Any views expressed in this message are those of the individual sender, except where the sender expressly, and with authority, states them to be the views of the University of Technology Sydney. Before opening any attachments, please check them for viruses and defects. From owner-freebsd-hackers@FreeBSD.ORG Fri Dec 16 02:59:13 2005 Return-Path: X-Original-To: hackers@freebsd.org Delivered-To: freebsd-hackers@FreeBSD.ORG Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id DC87C16A41F for ; Fri, 16 Dec 2005 02:59:13 +0000 (GMT) (envelope-from mwm-keyword-freebsdhackers.102a7e@mired.org) Received: from delight.idiom.com (outbound.idiom.com [216.240.47.197]) by mx1.FreeBSD.org (Postfix) with ESMTP id 3E5E243D5D for ; Fri, 16 Dec 2005 02:59:09 +0000 (GMT) (envelope-from mwm-keyword-freebsdhackers.102a7e@mired.org) Received: from idiom.com (idiom.com [216.240.32.1]) by delight.idiom.com (Postfix) with ESMTP id E6F7422870D for ; Thu, 15 Dec 2005 18:59:08 -0800 (PST) Received: from mired.org (mwm@idiom [216.240.32.1]) by idiom.com (8.12.11/8.12.11) with SMTP id jBG2x6A5031553 for ; Thu, 15 Dec 2005 18:59:07 -0800 (PST) (envelope-from mwm-keyword-freebsdhackers.102a7e@mired.org) Received: (qmail 1900 invoked by uid 1001); 16 Dec 2005 03:02:05 -0000 Received: by localhost.mired.org (tmda-sendmail, from uid 1001); Thu, 15 Dec 2005 22:02:05 -0500 (EST) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Message-ID: <17314.11820.983364.232729@bhuda.mired.org> Date: Thu, 15 Dec 2005 22:02:04 -0500 To: Tony Maher In-Reply-To: <43A2265B.5070706@uts.edu.au> References: <43A2265B.5070706@uts.edu.au> X-Mailer: VM 7.17 under 21.4 (patch 17) "Jumbo Shrimp" XEmacs Lucid X-Primary-Address: mwm@mired.org X-face: "5Mnwy%?j>IIV\)A=):rjWL~NB2aH[}Yq8Z=u~vJ`"(,&SiLvbbz2W`; h9L,Yg`+vb1>RG% *h+%X^n0EZd>TM8_IB;a8F?(Fb"lw'IgCoyM.[Lg#r\ X-Delivery-Agent: TMDA/1.0.3 (Seattle Slew) From: Mike Meyer Cc: hackers@freebsd.org Subject: Re: mathematica/mathlink/python/linux X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Dec 2005 02:59:14 -0000 In <43A2265B.5070706@uts.edu.au>, Tony Maher typed: > I have installed Mathematica (v5.2) on FreeBSD 5-stable. All works > fine. Is this a Linux binary, or a FreeBSD one? > I am now trying to get the Python bindings to MathLink to > work. I can build ok but it links against the Mathematica library (ML) > which is linux. When I import mathlink I get undefined symbol "stdout" > message (stdout used in libML). In FreeBSD this symbol appears to be > __stdoutp. > ldd /usr/local/lib/python2.4/site-packages/mathlink.so > /usr/local/lib/python2.4/site-packages/mathlink.so: > libm.so.3 => /lib/libm.so.3 (0x481b6000) > > If I modify setup.py to specify libm as libm-2.3.2 (the linux one) > ldd /usr/local/lib/python2.4/site-packages/mathlink.so > /usr/local/lib/python2.4/site-packages/mathlink.so: > libm.so.6 => /compat/linux/lib/libm.so.6 (0x481b6000) > libc.so.6 => /compat/linux/lib/libc.so.6 (0x481d7000) > ld-linux.so.2 (0x48302000) > > Then import fails with segmentation violation. Expected. There's evidence that this can be made to work - see the www/linuxpluginwrapper port. However, there's no guarantee that it will, and the amount of work is unknown. > Is there any way around this or is it a hopeless cause? > (I could build a linux version of python on my system > and then it shoudl work but that is not ideal) If Mathematica is a linux binary, then you've presumably got one of the linux emulation ports instlaled. I'd just install the python package (.rpm, .deb, or watever) for that system rather than build one. But that's still not ideal. http://www.mired.org/consulting.html Independent Network/Unix/Perforce consultant, email for more information. From owner-freebsd-hackers@FreeBSD.ORG Fri Dec 16 03:21:56 2005 Return-Path: X-Original-To: hackers@freebsd.org Delivered-To: freebsd-hackers@FreeBSD.ORG Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id E1F6716A41F for ; Fri, 16 Dec 2005 03:21:55 +0000 (GMT) (envelope-from anthony.maher@uts.edu.au) Received: from zim.itd.uts.edu.au (zim.itd.uts.edu.au [138.25.22.46]) by mx1.FreeBSD.org (Postfix) with ESMTP id 3B77943D46 for ; Fri, 16 Dec 2005 03:21:55 +0000 (GMT) (envelope-from anthony.maher@uts.edu.au) Received: by zim.itd.uts.edu.au (Postfix, from userid 900) id 41225C3361; Fri, 16 Dec 2005 14:21:54 +1100 (EST) Received: from vimes (vimes.itd.uts.edu.au [138.25.243.34])by zim.itd.uts.edu.au (Postfix/Ingress) with ESMTP id D53C5C3378; Fri, 16 Dec 2005 14:18:00 +1100 (EST) Received: from [138.25.81.152] by postoffice.uts.edu.au(Sun Java System Messaging Server 6.1 HotFix 0.09 (built Dec 14 2004))with ESMTPS id <0IRK00JPVMHXMU60@postoffice.uts.edu.au>; Fri,16 Dec 2005 14:17:58 +1100 (EST) Date: Fri, 16 Dec 2005 14:17:57 +1100 From: Tony Maher In-reply-to: <17314.11820.983364.232729@bhuda.mired.org> To: Mike Meyer Message-id: <43A231E5.8000606@uts.edu.au> MIME-version: 1.0 Content-type: text/plain; charset=us-ascii Content-transfer-encoding: 7BIT X-Accept-Language: en-us, en X-Enigmail-Version: 0.93.0.0 References: <43A2265B.5070706@uts.edu.au><17314.11820.983364.232729@bhuda.mired.org> User-Agent: Mozilla/5.0 (X11; U; FreeBSD i386; en-US; rv:1.7.12) Gecko/20051109 X-Virus-Scanned: amavisd-new at uts.edu.au Cc: hackers@freebsd.org Subject: Re: mathematica/mathlink/python/linux X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Dec 2005 03:21:56 -0000 Hello Mike Mike Meyer wrote: > In <43A2265B.5070706@uts.edu.au>, Tony Maher typed: > >>I have installed Mathematica (v5.2) on FreeBSD 5-stable. All works >>fine. > > Is this a Linux binary, or a FreeBSD one? Linux. I do not believe there is a FreeBSD one. >>Then import fails with segmentation violation. > > > Expected. There's evidence that this can be made to work - see the > www/linuxpluginwrapper port. However, there's no guarantee that it > will, and the amount of work is unknown. > ... Thanks for that I will look into that port. I have had some success since I first sent the email. I have compiled linking to the static linux libm and libc libraries. (Could not work out how to do that in setup.py so just ran on command line). Importing mathlink now gets further and truss shows stat("/tmp/MathLink",0xbfbfd670) = 0 (0x0) open("/tmp/MathLink",0x4,011016110000) = 4 (0x4) fstat(4,0xbfbfd670) = 0 (0x0) fcntl(4,F_SETFD,0x1) = 0 (0x0) fstatfs(0x4,0xbfbfd490) = 0 (0x0) break(0x821a000) = 0 (0x0) close(4) = 0 (0x0) gettimeofday({1134702603 203316},0x0) = 0 (0x0) gettimeofday({1134702603 205100},0x0) = 0 (0x0) open("/tmp/MathLink/pgcfgei",0x42,00) ERR#2 'No such file or directory' Fatal Python error: Error initializing mathlink extension module write(2,0xbfbfd270,65) = 65 (0x41) sigprocmask(0x3,0xbfbfd978,0x0) = 0 (0x0) sigprocmask(0x3,0x0,0x811e11c) = 0 (0x0) getpid() = 1501 (0x5dd) kill(0x5dd,0x6) = 0 (0x0) SIGNAL 6 (SIGABRT) SIGNAL 6 (SIGABRT) Process stopped because of: 16 process exit, rval = 6 Abort This could be related to fact that Mathematica does not support Python 2.4 and MathLink so I'll try installing python 2.3. thanks -- tonym -- UTS CRICOS Provider Code: 00099F DISCLAIMER: This email message and any accompanying attachments may contain confidential information. If you are not the intended recipient, do not read, use, disseminate, distribute or copy this message or attachments. If you have received this message in error, please notify the sender immediately and delete this message. Any views expressed in this message are those of the individual sender, except where the sender expressly, and with authority, states them to be the views of the University of Technology Sydney. Before opening any attachments, please check them for viruses and defects. From owner-freebsd-hackers@FreeBSD.ORG Fri Dec 16 06:19:08 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 3684816A41F; Fri, 16 Dec 2005 06:19:08 +0000 (GMT) (envelope-from dunstan@freebsd.czest.pl) Received: from freebsd.czest.pl (freebsd.czest.pl [80.48.250.4]) by mx1.FreeBSD.org (Postfix) with ESMTP id 5A84043D45; Fri, 16 Dec 2005 06:19:07 +0000 (GMT) (envelope-from dunstan@freebsd.czest.pl) Received: from freebsd.czest.pl (freebsd.czest.pl [80.48.250.4]) by freebsd.czest.pl (8.12.10/8.12.9) with ESMTP id jBG6LVPx043684; Fri, 16 Dec 2005 06:21:32 GMT (envelope-from dunstan@freebsd.czest.pl) Received: (from dunstan@localhost) by freebsd.czest.pl (8.13.4/8.12.9/Submit) id jBG6LUWA043683; Fri, 16 Dec 2005 06:21:30 GMT (envelope-from dunstan) Date: Fri, 16 Dec 2005 06:21:29 +0000 From: "Wojciech A. Koszek" To: =?iso-8859-2?Q?V=E1clav?= Haisman Message-ID: <20051216062129.GA43633@FreeBSD.czest.pl> References: <20051215223745.GA37768@FreeBSD.czest.pl> <43A1F97A.3060102@sh.cvut.cz> Mime-Version: 1.0 Content-Type: text/plain; charset=iso-8859-2 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <43A1F97A.3060102@sh.cvut.cz> User-Agent: Mutt/1.4.2.1i Cc: freebsd-hackers@freebsd.org, phk@freebsd.org Subject: Re: [CALL FOR TESTERS] New system call: abort2() X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Dec 2005 06:19:08 -0000 On Fri, Dec 16, 2005 at 12:17:14AM +0100, Václav Haisman wrote: > Wojciech A. Koszek wrote: > [...] > > Comments are welcome! > > As for the patch, the use of do {} while(0) instead of goto looks odd to me. This can be changed easily in final version of the patch if needed. > I would like to comment on FreeBSD style(9) a bit. Why does not mention > or even encourage C99 style // comments? They are nice when one wants to > comment out bigger chunks of code with /**/ comment. > > On the similar note, the ability to move declarations closer to the > point of use in code is IMO nice feature, too. The style(9) doesn't > mention this either. This creates unnecessary problems: large blocks can duplicate name of the variable so that they overlap, which has happened in the past. Additionally, some files use this kind of declaration, and it makes source hard to read. Also please note that current comments probably needs changing. I'm looking forward to hearing new comments in that field. Thanks, -- * Wojciech A. Koszek && dunstan@FreeBSD.czest.pl From owner-freebsd-hackers@FreeBSD.ORG Fri Dec 16 07:42:53 2005 Return-Path: X-Original-To: hackers@freebsd.org Delivered-To: freebsd-hackers@FreeBSD.ORG Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 3DC9216A41F; Fri, 16 Dec 2005 07:42:53 +0000 (GMT) (envelope-from scottl@samsco.org) Received: from pooker.samsco.org (pooker.samsco.org [168.103.85.57]) by mx1.FreeBSD.org (Postfix) with ESMTP id B898343D5C; Fri, 16 Dec 2005 07:42:52 +0000 (GMT) (envelope-from scottl@samsco.org) Received: from [192.168.254.11] (junior.samsco.home [192.168.254.11]) (authenticated bits=0) by pooker.samsco.org (8.13.4/8.13.4) with ESMTP id jBG7gpWL016266; Fri, 16 Dec 2005 00:42:51 -0700 (MST) (envelope-from scottl@samsco.org) Message-ID: <43A26FFB.9080405@samsco.org> Date: Fri, 16 Dec 2005 00:42:51 -0700 From: Scott Long User-Agent: Mozilla/5.0 (X11; U; FreeBSD i386; en-US; rv:1.7.8) Gecko/20050615 X-Accept-Language: en-us, en MIME-Version: 1.0 To: hackers@freebsd.org Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-1.4 required=3.8 tests=ALL_TRUSTED autolearn=failed version=3.1.0 X-Spam-Checker-Version: SpamAssassin 3.1.0 (2005-09-13) on pooker.samsco.org Cc: Subject: My wish list for 6.1 X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Dec 2005 07:42:53 -0000 Guys, With code freeze for 6.1 about 6 weeks away, I'd like to put out my 'wish list' for it: 1. working kbdmux. We need this for the growing number of systems that assume that USB is the primary keyboard. Current status appears to be that the kbdmux driver breaks very easily. We need this working well enough where it can be enabled by default, and all attached keyboards Just Work. 2. SMP kernels for install. Right now we only install a UP kernel, for performance reasons. We should be able to package both a UP and SMP kernel into the release bits, and have sysinstall install both. It should also select the correct one for the target system and make that the default on boot. The easiest way to do this would be to have sysinstall boot an SMP kernel and then look at the hw.ncpu sysctl. The only problem is being able to have sysinstall fall back to booting a UP kernel for itself if the SMP one fails. This can probably be 'faked' by setting one of the SMP-disabling variables in the loader. But in any case, the point is to make the process Just Work for the user, without the user needing to know arcane loader/sysctl knobs. SMP laptops are right around the corner, and we should be ready to support SMP out-of-the-box. 3. Full review and update of the install docs, handbook, FAQ, etc. There are sections that are embarrassingly out of date (one section of the handbook apparently states that we only support a single brand of wifi cards). A co-worker of mine tried to install 6.0 using just the handbook install guide, and discovered that it really doesn't match reality anymore, in both big and small ways. Contact me directly if you would like his list of comments. Thanks! Scott From owner-freebsd-hackers@FreeBSD.ORG Fri Dec 16 07:51:55 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id CA07E16A41F for ; Fri, 16 Dec 2005 07:51:55 +0000 (GMT) (envelope-from roma.a.g@gmail.com) Received: from uproxy.gmail.com (uproxy.gmail.com [66.249.92.205]) by mx1.FreeBSD.org (Postfix) with ESMTP id E802243D62 for ; Fri, 16 Dec 2005 07:51:54 +0000 (GMT) (envelope-from roma.a.g@gmail.com) Received: by uproxy.gmail.com with SMTP id j3so96655ugf for ; Thu, 15 Dec 2005 23:51:53 -0800 (PST) DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=beta; d=gmail.com; h=received:date:from:x-mailer:reply-to:organization:x-priority:message-id:to:subject:mime-version:content-type:content-transfer-encoding; b=Lilw8nwEcIdmu/Al2u7GFEEg1tXnHijngY2cL7+jVpVcMVBgvClxLetaV7OL20VyK+L2PzSKWkfr2y/3CYCBeS8D3yfk27eXBbG8ed7I2rBrJEYUcrCu8DwsiXmggnrWipIEIybCoS9VPPdnbIknGBXRCiNEtivOYg+T8MreRjw= Received: by 10.67.27.4 with SMTP id e4mr615587ugj; Thu, 15 Dec 2005 23:51:53 -0800 (PST) Received: from pridep3.ad.office.acropolis.ru ( [81.211.90.3]) by mx.gmail.com with ESMTP id a1sm1075335ugf.2005.12.15.23.51.52; Thu, 15 Dec 2005 23:51:53 -0800 (PST) Date: Fri, 16 Dec 2005 10:52:25 +0300 From: "roma.a.g" X-Mailer: The Bat! (v3.62.14) UNREG / CD5BF9353B3B7091 Organization: Acropolis X-Priority: 3 (Normal) Message-ID: <14510301213.20051216105225@gmail.com> To: freebsd-hackers@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Subject: easy question about kill command X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: "roma.a.g" List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Dec 2005 07:51:55 -0000 Is there anyone who can explain me, why when i say 'kill -HUP id', and its failed to restart, kill say nothing? It is such an easy to implement... Roman Gorohov. mailto:roma.a.g@gmail.com From owner-freebsd-hackers@FreeBSD.ORG Fri Dec 16 08:10:48 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id E9EA316A41F for ; Fri, 16 Dec 2005 08:10:48 +0000 (GMT) (envelope-from PeterJeremy@optushome.com.au) Received: from mail14.syd.optusnet.com.au (mail14.syd.optusnet.com.au [211.29.132.195]) by mx1.FreeBSD.org (Postfix) with ESMTP id 64DEF43D6D for ; Fri, 16 Dec 2005 08:10:45 +0000 (GMT) (envelope-from PeterJeremy@optushome.com.au) Received: from cirb503493.alcatel.com.au (c220-239-19-236.belrs4.nsw.optusnet.com.au [220.239.19.236]) by mail14.syd.optusnet.com.au (8.12.11/8.12.11) with ESMTP id jBG8AhmB013113 (version=TLSv1/SSLv3 cipher=EDH-RSA-DES-CBC3-SHA bits=168 verify=NO); Fri, 16 Dec 2005 19:10:43 +1100 Received: from cirb503493.alcatel.com.au (localhost.alcatel.com.au [127.0.0.1]) by cirb503493.alcatel.com.au (8.12.10/8.12.10) with ESMTP id jBG8AgHh082649; Fri, 16 Dec 2005 19:10:42 +1100 (EST) (envelope-from pjeremy@cirb503493.alcatel.com.au) Received: (from pjeremy@localhost) by cirb503493.alcatel.com.au (8.12.10/8.12.9/Submit) id jBG8AgNL082648; Fri, 16 Dec 2005 19:10:42 +1100 (EST) (envelope-from pjeremy) Date: Fri, 16 Dec 2005 19:10:41 +1100 From: Peter Jeremy To: =?iso-8859-1?Q?V=E1clav?= Haisman Message-ID: <20051216081041.GP77268@cirb503493.alcatel.com.au> References: <20051215223745.GA37768@FreeBSD.czest.pl> <43A1F97A.3060102@sh.cvut.cz> Mime-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <43A1F97A.3060102@sh.cvut.cz> User-Agent: Mutt/1.4.2.1i X-PGP-Key: http://members.optusnet.com.au/peterjeremy/pubkey.asc Cc: freebsd-hackers@freebsd.org Subject: Re: [CALL FOR TESTERS] New system call: abort2() X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Dec 2005 08:10:49 -0000 On Fri, 2005-Dec-16 00:17:14 +0100, Václav Haisman wrote: >I would like to comment on FreeBSD style(9) a bit. That is a different bikeshed. If, taking into account the other comments in this thread, you believe that you can justify changes to style(9), please start a new thread - probably in -arch. -- Peter Jeremy From owner-freebsd-hackers@FreeBSD.ORG Fri Dec 16 08:41:27 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 4B2BB16A41F for ; Fri, 16 Dec 2005 08:41:27 +0000 (GMT) (envelope-from joseph.koshy@gmail.com) Received: from xproxy.gmail.com (xproxy.gmail.com [66.249.82.194]) by mx1.FreeBSD.org (Postfix) with ESMTP id 9DD2F43D46 for ; Fri, 16 Dec 2005 08:41:26 +0000 (GMT) (envelope-from joseph.koshy@gmail.com) Received: by xproxy.gmail.com with SMTP id s9so460343wxc for ; Fri, 16 Dec 2005 00:41:26 -0800 (PST) DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=beta; d=gmail.com; h=received:message-id:date:from:to:subject:cc:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; b=gFm+lX6sQeGSO2rcWkI3Cf0O9H0kpvkx0Qi1a1U6KF+95sfq84Cwkv3T/VDiobP3RjPVlFCrcmnPK3+SEWG0hfyr+8KCIXsABuQhF1B/dWwP+AAIsWD1f2q78Turcr7Idrs7U3ZSSa/Z78hg7VotzA74/OAF4KlZgnthrPnGBGw= Received: by 10.70.100.5 with SMTP id x5mr567399wxb; Fri, 16 Dec 2005 00:41:25 -0800 (PST) Received: by 10.70.105.13 with HTTP; Fri, 16 Dec 2005 00:41:25 -0800 (PST) Message-ID: <84dead720512160041o77ea3aadne7dbbb4128690078@mail.gmail.com> Date: Fri, 16 Dec 2005 14:11:25 +0530 From: Joseph Koshy To: "roma.a.g" In-Reply-To: <14510301213.20051216105225@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Content-Disposition: inline References: <14510301213.20051216105225@gmail.com> Cc: freebsd-hackers@freebsd.org Subject: Re: easy question about kill command X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Dec 2005 08:41:27 -0000 > Is there anyone who can explain me, why when i say 'kill -HUP > > id', and its failed to restart, kill say nothing? > It is such an easy to implement... Your application could be choosing to ignore SIGHUP (restarting on SIGHUP is a convention, not a OS defined requirement)? -- FreeBSD Volunteer, http://people.freebsd.org/~jkoshy From owner-freebsd-hackers@FreeBSD.ORG Fri Dec 16 08:48:11 2005 Return-Path: X-Original-To: freebsd-hackers@FreeBSD.ORG Delivered-To: freebsd-hackers@FreeBSD.ORG Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 4A9AF16A422 for ; Fri, 16 Dec 2005 08:48:11 +0000 (GMT) (envelope-from olli@lurza.secnetix.de) Received: from lurza.secnetix.de (lurza.secnetix.de [83.120.8.8]) by mx1.FreeBSD.org (Postfix) with ESMTP id 5DB8E43DD6 for ; Fri, 16 Dec 2005 08:46:53 +0000 (GMT) (envelope-from olli@lurza.secnetix.de) Received: from lurza.secnetix.de (kdqted@localhost [127.0.0.1]) by lurza.secnetix.de (8.13.4/8.13.4) with ESMTP id jBG8kabq099406; Fri, 16 Dec 2005 09:46:37 +0100 (CET) (envelope-from oliver.fromme@secnetix.de) Received: (from olli@localhost) by lurza.secnetix.de (8.13.4/8.13.1/Submit) id jBG8kaEB099405; Fri, 16 Dec 2005 09:46:36 +0100 (CET) (envelope-from olli) Date: Fri, 16 Dec 2005 09:46:36 +0100 (CET) Message-Id: <200512160846.jBG8kaEB099405@lurza.secnetix.de> From: Oliver Fromme To: freebsd-hackers@FreeBSD.ORG, "roma.a.g" In-Reply-To: <14510301213.20051216105225@gmail.com> X-Newsgroups: list.freebsd-hackers User-Agent: tin/1.5.4-20000523 ("1959") (UNIX) (FreeBSD/4.11-STABLE (i386)) Cc: Subject: Re: easy question about kill command X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: freebsd-hackers@FreeBSD.ORG, "roma.a.g" List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Dec 2005 08:48:11 -0000 roma.a.g wrote: > Is there anyone who can explain me, why when i say 'kill -HUP id', > and its failed to restart, kill say nothing? Because the kill command has no way to know about it. The kill command only instructs the kernel to deliver a signal to a process (or to a process group). The only feedback it gets from the kernel is whether the target process exists or not. (The latter is often used to check for the existence of a particular process ID, by trying to send it a "zero" signal which does nothing.) There is no way for the kill command to know what the target process is going to do with the signal. This is entirely and only the business of the target process, which might chose to take the default action (in the case of SIGHUP it's to terminate the process), to ignore the signal alltogether, or to take some special action. Some programs use SIGHUP traditionally to rotate their logfiles, re-read configuration files, re-open network sockets, restart themselves, or other things. But that's entirely up to the program in question, and there is no way the kill command could know about it, let alone whether it was successful or not. > It is such an easy to implement... I don't think so, as explained above. But if you think it is easy, you're certainly free to write a patch and submit it for discussion. Best regards Oliver -- Oliver Fromme, secnetix GmbH & Co. KG, Marktplatz 29, 85567 Grafing Dienstleistungen mit Schwerpunkt FreeBSD: http://www.secnetix.de/bsd Any opinions expressed in this message may be personal to the author and may not necessarily reflect the opinions of secnetix in any way. "What is this talk of 'release'? We do not make software 'releases'. Our software 'escapes', leaving a bloody trail of designers and quality assurance people in its wake." From owner-freebsd-hackers@FreeBSD.ORG Fri Dec 16 09:05:34 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id C3FDE16A41F for ; Fri, 16 Dec 2005 09:05:34 +0000 (GMT) (envelope-from roma.a.g@gmail.com) Received: from uproxy.gmail.com (uproxy.gmail.com [66.249.92.205]) by mx1.FreeBSD.org (Postfix) with ESMTP id 04FC543D58 for ; Fri, 16 Dec 2005 09:05:33 +0000 (GMT) (envelope-from roma.a.g@gmail.com) Received: by uproxy.gmail.com with SMTP id o2so118199uge for ; Fri, 16 Dec 2005 01:05:32 -0800 (PST) DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=beta; d=gmail.com; h=received:date:from:x-mailer:reply-to:organization:x-priority:message-id:to:cc:subject:in-reply-to:references:mime-version:content-type:content-transfer-encoding; b=Hb23t8G3Gqi7S4N/zxM004iF4/fqT+nLNGQn5OR+8LtJ92TxgKE4gJvAh7C30aN3qJl1/spiGwTJR7lop6g/0nxbsmVJbJ9Ld10h5qstYvFamYK01nJvoj3H8xSstvCzYtcT3wx+9uIXtamIG0T1Bdy1fRk93heV2fuzc9MO1aE= Received: by 10.66.224.9 with SMTP id w9mr634819ugg; Fri, 16 Dec 2005 01:05:32 -0800 (PST) Received: from pridep3.ad.office.acropolis.ru ( [81.211.90.3]) by mx.gmail.com with ESMTP id q40sm1085382ugc.2005.12.16.01.05.31; Fri, 16 Dec 2005 01:05:32 -0800 (PST) Date: Fri, 16 Dec 2005 12:06:29 +0300 From: "Roman Gorohov. " X-Mailer: The Bat! (v3.62.14) UNREG / CD5BF9353B3B7091 Organization: Acropolis X-Priority: 3 (Normal) Message-ID: <691676723.20051216120629@gmail.com> To: Joseph Koshy In-Reply-To: <84dead720512160041o77ea3aadne7dbbb4128690078@mail.gmail.com> References: <14510301213.20051216105225@gmail.com> <84dead720512160041o77ea3aadne7dbbb4128690078@mail.gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: quoted-printable Cc: freebsd-hackers@freebsd.org Subject: Re[2]: easy question about kill command X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: "roma.a.g" List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Dec 2005 09:05:34 -0000 =C7=E4=F0=E0=E2=F1=F2=E2=F3=E9=F2=E5, Joseph. =C2=FB =EF=E8=F1=E0=EB=E8 16 ??????? 2005 ?., 11:41:25: >> Is there anyone who can explain me, why when i say 'kill -HUP > >> id', and its failed to restart, kill say nothing? >> It is such an easy to implement... > Your application could be choosing to ignore SIGHUP > (restarting on SIGHUP is a convention, not a OS defined > requirement)? > -- > FreeBSD Volunteer, http://people.freebsd.org/~jkoshy No, I meant, if it fail to restart due to configuration error. When I reconfigure some daemon, and then want to restart it that way, I have to check, if it running after killing. So question was, why kill command don't check it itself? -- =D1 =F3=E2=E0=E6=E5=ED=E8=E5=EC, Roman mailto:roma.a.g@gmail.com From owner-freebsd-hackers@FreeBSD.ORG Fri Dec 16 09:07:20 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id EB96A16A41F for ; Fri, 16 Dec 2005 09:07:20 +0000 (GMT) (envelope-from roma.a.g@gmail.com) Received: from uproxy.gmail.com (uproxy.gmail.com [66.249.92.200]) by mx1.FreeBSD.org (Postfix) with ESMTP id 22C4E43D46 for ; Fri, 16 Dec 2005 09:07:19 +0000 (GMT) (envelope-from roma.a.g@gmail.com) Received: by uproxy.gmail.com with SMTP id o2so118277uge for ; Fri, 16 Dec 2005 01:07:19 -0800 (PST) DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=beta; d=gmail.com; h=received:date:from:x-mailer:reply-to:organization:x-priority:message-id:to:cc:subject:in-reply-to:references:mime-version:content-type:content-transfer-encoding; b=odT0FTGz6r2OFt9cI4oSvheg921/MfWqQPhgRwAyR25mgO7BN3XbO9ieSgp211LE9KVk4fCK8ZlM/kEbpzvR8UWWrQ3eE3kZmyHr92VRZzqFlaK7XbmlmizSi78+OuuIFvTcwlA3odUJYTiHSOiVM5yu9eCMEbsLv2v9r17RrLw= Received: by 10.67.27.13 with SMTP id e13mr658729ugj; Fri, 16 Dec 2005 01:07:18 -0800 (PST) Received: from pridep3.ad.office.acropolis.ru ( [81.211.90.3]) by mx.gmail.com with ESMTP id q40sm1086162ugc.2005.12.16.01.07.18; Fri, 16 Dec 2005 01:07:18 -0800 (PST) Date: Fri, 16 Dec 2005 12:08:16 +0300 From: "Roman Gorohov. " X-Mailer: The Bat! (v3.62.14) UNREG / CD5BF9353B3B7091 Organization: Acropolis X-Priority: 3 (Normal) Message-ID: <979057908.20051216120816@gmail.com> To: Oliver Fromme In-Reply-To: <200512160846.jBG8kaEB099405@lurza.secnetix.de> References: <14510301213.20051216105225@gmail.com> <200512160846.jBG8kaEB099405@lurza.secnetix.de> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Cc: freebsd-hackers@freebsd.org Subject: Re[2]: easy question about kill command X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: "roma.a.g" List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Dec 2005 09:07:21 -0000 Hi, Oliver. > roma.a.g wrote: >> Is there anyone who can explain me, why when i say 'kill -HUP id', >> and its failed to restart, kill say nothing? > Because the kill command has no way to know about it. > The kill command only instructs the kernel to deliver > a signal to a process (or to a process group). The only > feedback it gets from the kernel is whether the target > process exists or not. (The latter is often used to > check for the existence of a particular process ID, by > trying to send it a "zero" signal which does nothing.) > There is no way for the kill command to know what the > target process is going to do with the signal. This is > entirely and only the business of the target process, > which might chose to take the default action (in the case > of SIGHUP it's to terminate the process), to ignore the > signal alltogether, or to take some special action. > Some programs use SIGHUP traditionally to rotate their > logfiles, re-read configuration files, re-open network > sockets, restart themselves, or other things. But that's > entirely up to the program in question, and there is no > way the kill command could know about it, let alone > whether it was successful or not. Thanks for your reply. My question was about standard bsd daemons, not about some apps with unpredictable behaviour. >> It is such an easy to implement... > I don't think so, as explained above. Yeah right, I see now. > Best regards > Oliver -- Best regards, Roman Gorohov mailto:roma.a.g@gmail.com From owner-freebsd-hackers@FreeBSD.ORG Fri Dec 16 09:11:10 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 8F82716A420; Fri, 16 Dec 2005 09:11:10 +0000 (GMT) (envelope-from PeterJeremy@optushome.com.au) Received: from mail18.syd.optusnet.com.au (mail18.syd.optusnet.com.au [211.29.132.199]) by mx1.FreeBSD.org (Postfix) with ESMTP id D151043D4C; Fri, 16 Dec 2005 09:11:08 +0000 (GMT) (envelope-from PeterJeremy@optushome.com.au) Received: from cirb503493.alcatel.com.au (c220-239-19-236.belrs4.nsw.optusnet.com.au [220.239.19.236]) by mail18.syd.optusnet.com.au (8.12.11/8.12.11) with ESMTP id jBG9AvZl023085 (version=TLSv1/SSLv3 cipher=EDH-RSA-DES-CBC3-SHA bits=168 verify=NO); Fri, 16 Dec 2005 20:10:59 +1100 Received: from cirb503493.alcatel.com.au (localhost.alcatel.com.au [127.0.0.1]) by cirb503493.alcatel.com.au (8.12.10/8.12.10) with ESMTP id jBG9AvHh082748; Fri, 16 Dec 2005 20:10:57 +1100 (EST) (envelope-from pjeremy@cirb503493.alcatel.com.au) Received: (from pjeremy@localhost) by cirb503493.alcatel.com.au (8.12.10/8.12.9/Submit) id jBG9AvtU082747; Fri, 16 Dec 2005 20:10:57 +1100 (EST) (envelope-from pjeremy) Date: Fri, 16 Dec 2005 20:10:57 +1100 From: Peter Jeremy To: "Wojciech A. Koszek" Message-ID: <20051216091057.GQ77268@cirb503493.alcatel.com.au> References: <20051215223745.GA37768@FreeBSD.czest.pl> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20051215223745.GA37768@FreeBSD.czest.pl> User-Agent: Mutt/1.4.2.1i X-PGP-Key: http://members.optusnet.com.au/peterjeremy/pubkey.asc Cc: freebsd-hackers@freebsd.org, phk@freebsd.org Subject: Re: [CALL FOR TESTERS] New system call: abort2() X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Dec 2005 09:11:10 -0000 On Thu, 2005-Dec-15 22:37:45 +0000, Wojciech A. Koszek wrote: > abort2(const char *why, int nargs, void **args); > >"why" is reason of program abort, "nargs" is number of arguments >passed in "args". Both "why" and "args" (with "%p" format) will be >printed via log(9). Sample output: >[..] >pid <3004> abort2: ABORT2 >pid <3019> abort2: invalid argument >[..] I don't believe the following code is correct. uap->args is a userspace pointer so uap->args[i] is dereferencing a userspace argument in kernelspace. + arg = uargs[i] = (void *) fuword(uap->args[i]); I think it should be fuword(uap->args + i); I don't see the point of the following test. "arg" is printed using %p and never de-referenced so there's no reason it can't be NULL. I would see that a legitimate use of abort2() is when the application detects that a pointer is unexpectedly NULL. Aborting on -1 is less clear - if fuword() fails, it will return -1 but, equally, a faulty user application may have left -1 in a pointer. (Note that mmap(2) returns -1 on error so it's not inconceivable that a pointer could contain -1). + /* Prevent from faults in user-space */ + if (arg == NULL || arg == (void *)-1) { + error = EINVAL; + break; + } Taking the above into account, I believe the code should be: + if (uap->args == NULL) + break; + error = copyin(uap->args, uargs, uap->nargs * sizeof (void *)); + if (error != 0) + break; -- Peter Jeremy From owner-freebsd-hackers@FreeBSD.ORG Fri Dec 16 09:13:57 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 0D18916A41F for ; Fri, 16 Dec 2005 09:13:57 +0000 (GMT) (envelope-from olli@lurza.secnetix.de) Received: from lurza.secnetix.de (lurza.secnetix.de [83.120.8.8]) by mx1.FreeBSD.org (Postfix) with ESMTP id 48B7143D6A for ; Fri, 16 Dec 2005 09:13:56 +0000 (GMT) (envelope-from olli@lurza.secnetix.de) Received: from lurza.secnetix.de (qnunef@localhost [127.0.0.1]) by lurza.secnetix.de (8.13.4/8.13.4) with ESMTP id jBG9DsEm000451; Fri, 16 Dec 2005 10:13:55 +0100 (CET) (envelope-from oliver.fromme@secnetix.de) Received: (from olli@localhost) by lurza.secnetix.de (8.13.4/8.13.1/Submit) id jBG9Dshc000450; Fri, 16 Dec 2005 10:13:54 +0100 (CET) (envelope-from olli) Date: Fri, 16 Dec 2005 10:13:54 +0100 (CET) Message-Id: <200512160913.jBG9Dshc000450@lurza.secnetix.de> From: Oliver Fromme To: freebsd-hackers@freebsd.org, "roma.a.g" In-Reply-To: <200512160846.jBG8kaEB099405@lurza.secnetix.de> X-Newsgroups: list.freebsd-hackers User-Agent: tin/1.5.4-20000523 ("1959") (UNIX) (FreeBSD/4.11-STABLE (i386)) Cc: Subject: Re: easy question about kill command X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: freebsd-hackers@freebsd.org, "roma.a.g" List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Dec 2005 09:13:57 -0000 Oliver Fromme wrote: > roma.a.g wrote: > > Is there anyone who can explain me, why when i say 'kill -HUP id', > > and its failed to restart, kill say nothing? > > Because the kill command has no way to know about it. > > The kill command only instructs the kernel to deliver > a signal to a process (or to a process group). The only > feedback it gets from the kernel is whether the target > process exists or not. (The latter is often used to > check for the existence of a particular process ID, by > trying to send it a "zero" signal which does nothing.) Oh, I forgot to add one further fact: The target process can only respond to the signal the next time it gets a time slice from the scheduler. That doesn't necessarily need to be immediately. For example, when the process is currently blocked (waiting for I/O or another resource), it can be a long time until it gets a chance to respond to the signal. At that time, the kill process has probably already exited. Best regards Oliver -- Oliver Fromme, secnetix GmbH & Co. KG, Marktplatz 29, 85567 Grafing Dienstleistungen mit Schwerpunkt FreeBSD: http://www.secnetix.de/bsd Any opinions expressed in this message may be personal to the author and may not necessarily reflect the opinions of secnetix in any way. "It combines all the worst aspects of C and Lisp: a billion different sublanguages in one monolithic executable. It combines the power of C with the readability of PostScript." -- Jamie Zawinski, when asked: "What's wrong with perl?" From owner-freebsd-hackers@FreeBSD.ORG Fri Dec 16 09:37:11 2005 Return-Path: X-Original-To: freebsd-hackers@FreeBSD.ORG Delivered-To: freebsd-hackers@FreeBSD.ORG Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 39EE416A420 for ; Fri, 16 Dec 2005 09:37:11 +0000 (GMT) (envelope-from olli@lurza.secnetix.de) Received: from lurza.secnetix.de (lurza.secnetix.de [83.120.8.8]) by mx1.FreeBSD.org (Postfix) with ESMTP id 4FDC843D58 for ; Fri, 16 Dec 2005 09:37:09 +0000 (GMT) (envelope-from olli@lurza.secnetix.de) Received: from lurza.secnetix.de (cdsdyb@localhost [127.0.0.1]) by lurza.secnetix.de (8.13.4/8.13.4) with ESMTP id jBG9b8ZQ001090; Fri, 16 Dec 2005 10:37:08 +0100 (CET) (envelope-from oliver.fromme@secnetix.de) Received: (from olli@localhost) by lurza.secnetix.de (8.13.4/8.13.1/Submit) id jBG9b8FJ001089; Fri, 16 Dec 2005 10:37:08 +0100 (CET) (envelope-from olli) Date: Fri, 16 Dec 2005 10:37:08 +0100 (CET) Message-Id: <200512160937.jBG9b8FJ001089@lurza.secnetix.de> From: Oliver Fromme To: freebsd-hackers@FreeBSD.ORG, "roma.a.g" In-Reply-To: <979057908.20051216120816@gmail.com> X-Newsgroups: list.freebsd-hackers User-Agent: tin/1.5.4-20000523 ("1959") (UNIX) (FreeBSD/4.11-STABLE (i386)) Cc: Subject: Re: easy question about kill command X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: freebsd-hackers@FreeBSD.ORG, "roma.a.g" List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Dec 2005 09:37:11 -0000 Roman Gorohov. wrote: > Thanks for your reply. My question was about standard bsd daemons, not > about some apps with unpredictable behaviour. But the kill command doesn't know what kind of daemon it is sending a signal to. It just sends a signal to a PID. That PID could belong to a daemon from the bases system (such as mountd), or it could belong to a third-party program (such as apache). There is no way for the kill command to know. If a program is unable to perform an action (be it a restart after receiving a SIGHUP or whatever), it is the responsibility of the program to print or log a message. I think most daemons in the FreeBSD base system do that. For example, when you send a SIGHUP to a mountd process and there's a fatal error in your /etc/exports file, the fact is logged via syslog (by default it is written to /var/log/messages). For convenience you can write a small shell script (or alias, or shell function) which does this: kill -HUP $1; sleep 3; tail /var/log/messages Best regards Oliver PS: I wrote the following shell script for that purpose: #!/bin/sh - LOGFILE=/var/log/messages LOGSIZE_BEFORE=$(stat -f%z $LOGFILE) logger "Executing killall -HUP $*" killall -HUP "$@" sleep 3 LOGSIZE_AFTER=$(stat -f%z $LOGFILE) tail -c $(( $LOGSIZE_AFTER - $LOGSIZE_BEFORE )) $LOGFILE I named it "killhup". I can then type "killhup mountd", so it restarts the mountd process, then waits 3 seconds, and then it prints any new messages from the log file (or nothing if everything is OK). -- Oliver Fromme, secnetix GmbH & Co. KG, Marktplatz 29, 85567 Grafing Dienstleistungen mit Schwerpunkt FreeBSD: http://www.secnetix.de/bsd Any opinions expressed in this message may be personal to the author and may not necessarily reflect the opinions of secnetix in any way. Python is executable pseudocode. Perl is executable line noise. From owner-freebsd-hackers@FreeBSD.ORG Fri Dec 16 10:26:58 2005 Return-Path: X-Original-To: freebsd-hackers@FreeBSD.ORG Delivered-To: freebsd-hackers@FreeBSD.ORG Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 9351016A41F for ; Fri, 16 Dec 2005 10:26:58 +0000 (GMT) (envelope-from V.Ovsyannikov@kr.ru) Received: from ns.kr.ru (ns.kr.ru [84.22.128.10]) by mx1.FreeBSD.org (Postfix) with ESMTP id 028F143D5A for ; Fri, 16 Dec 2005 10:26:57 +0000 (GMT) (envelope-from V.Ovsyannikov@kr.ru) Received: from gravis.skala-net.ru (gravis.skala-net.ru [84.22.128.254]) by ns.kr.ru (Postfix) with ESMTP id CCEA022E2E for ; Fri, 16 Dec 2005 17:26:54 +0700 (KRAT) Date: Fri, 16 Dec 2005 17:27:11 +0700 From: Vitaliy Ovsyannikov X-Priority: 3 (Normal) Message-ID: <917449047.20051216172711@kr.ru> To: freebsd-hackers@FreeBSD.ORG MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Cc: Subject: unable to build geom_gate X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: Vitaliy Ovsyannikov List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Dec 2005 10:26:58 -0000 Hello, freebsd-hackers. Please, look at the output and help if you can: # tar -yxf geom_gate.tbz # cd geom_gate # make ===> kmod (all) Warning: Object directory not changed from original /tmp/geom_gate/kmod cc -O2 -fno-strict-aliasing -pipe -I../include -Werror -D_KERNEL -DKLD_MODULE -nostdinc -I- -I../include -I. -I@ -I@/contrib/altq -I/usr/include -finline-limit=8000 -fno-common -mno-align-long-strings -mpreferred-stack-boundary=2 -mno-mmx -mno-3dnow -mno-sse -mno-sse2 -ffreestanding -Wall -Wredundant-decls -Wnested-externs -Wstrict-prototypes -Wmissing-prototypes -Wpointer-arith -Winline -Wcast-qual -fformat-extensions -std=c99 -Wsystem-headers -Werror -Wall -Wno-format-y2k -Wno-uninitialized -c geom_gate.c geom_gate.c:1146: error: conflicting types for 'ggf_ctlioctl' geom_gate.c:45: error: previous declaration of 'ggf_ctlioctl' was here geom_gate.c:1146: error: conflicting types for 'ggf_ctlioctl' geom_gate.c:45: error: previous declaration of 'ggf_ctlioctl' was here geom_gate.c: In function `ggf_ctlioctl': geom_gate.c:1155: warning: passing arg 1 of `devtoname' makes pointer from integer without a cast geom_gate.c: In function `ggf_drvinit': geom_gate.c:1324: warning: assignment makes integer from pointer without a cast geom_gate.c: In function `ggf_modevent': geom_gate.c:1355: warning: passing arg 1 of `destroy_dev' makes pointer from integer without a cast geom_gate.c: At top level: geom_gate.c:45: warning: 'ggf_ctlioctl' used but never defined geom_gate.c:1146: warning: 'ggf_ctlioctl' defined but not used *** Error code 1 Stop in /tmp/geom_gate/kmod. *** Error code 1 Stop in /tmp/geom_gate. # # uname -srm FreeBSD 6.0-RELEASE i386 Thanks. -- Sincerely, Vitaliy Ovsyannikov JSC Skala, Krasnoyarsk, Russia From owner-freebsd-hackers@FreeBSD.ORG Fri Dec 16 10:46:52 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 1323116A41F for ; Fri, 16 Dec 2005 10:46:51 +0000 (GMT) (envelope-from roma.a.g@gmail.com) Received: from uproxy.gmail.com (uproxy.gmail.com [66.249.92.195]) by mx1.FreeBSD.org (Postfix) with ESMTP id A442A43D55 for ; Fri, 16 Dec 2005 10:46:50 +0000 (GMT) (envelope-from roma.a.g@gmail.com) Received: by uproxy.gmail.com with SMTP id o2so122783uge for ; Fri, 16 Dec 2005 02:46:49 -0800 (PST) DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=beta; d=gmail.com; h=received:date:from:x-mailer:reply-to:organization:x-priority:message-id:to:cc:subject:in-reply-to:references:mime-version:content-type:content-transfer-encoding; b=odT0FTGz6r2OFt9cI4oSvheg921/MfWqQPhgRwAyR25mgO7BN3XbO9ieSgp211LE9KVk4fCK8ZlM/kEbpzvR8UWWrQ3eE3kZmyHr92VRZzqFlaK7XbmlmizSi78+OuuIFvTcwlA3odUJYTiHSOiVM5yu9eCMEbsLv2v9r17RrLw= Received: by 10.67.27.13 with SMTP id e13mr658729ugj; Fri, 16 Dec 2005 01:07:18 -0800 (PST) Received: from pridep3.ad.office.acropolis.ru ( [81.211.90.3]) by mx.gmail.com with ESMTP id q40sm1086162ugc.2005.12.16.01.07.18; Fri, 16 Dec 2005 01:07:18 -0800 (PST) Date: Fri, 16 Dec 2005 12:08:16 +0300 From: "Roman Gorohov. " X-Mailer: The Bat! (v3.62.14) UNREG / CD5BF9353B3B7091 Organization: Acropolis X-Priority: 3 (Normal) Message-ID: <979057908.20051216120816@gmail.com> To: Oliver Fromme In-Reply-To: <200512160846.jBG8kaEB099405@lurza.secnetix.de> References: <14510301213.20051216105225@gmail.com> <200512160846.jBG8kaEB099405@lurza.secnetix.de> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Cc: freebsd-hackers@freebsd.org Subject: Re[2]: easy question about kill command X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: "roma.a.g" List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Dec 2005 10:46:52 -0000 Hi, Oliver. > roma.a.g wrote: >> Is there anyone who can explain me, why when i say 'kill -HUP id', >> and its failed to restart, kill say nothing? > Because the kill command has no way to know about it. > The kill command only instructs the kernel to deliver > a signal to a process (or to a process group). The only > feedback it gets from the kernel is whether the target > process exists or not. (The latter is often used to > check for the existence of a particular process ID, by > trying to send it a "zero" signal which does nothing.) > There is no way for the kill command to know what the > target process is going to do with the signal. This is > entirely and only the business of the target process, > which might chose to take the default action (in the case > of SIGHUP it's to terminate the process), to ignore the > signal alltogether, or to take some special action. > Some programs use SIGHUP traditionally to rotate their > logfiles, re-read configuration files, re-open network > sockets, restart themselves, or other things. But that's > entirely up to the program in question, and there is no > way the kill command could know about it, let alone > whether it was successful or not. Thanks for your reply. My question was about standard bsd daemons, not about some apps with unpredictable behaviour. >> It is such an easy to implement... > I don't think so, as explained above. Yeah right, I see now. > Best regards > Oliver -- Best regards, Roman Gorohov mailto:roma.a.g@gmail.com From owner-freebsd-hackers@FreeBSD.ORG Fri Dec 16 10:05:31 2005 Return-Path: X-Original-To: hackers@FreeBSD.org Delivered-To: freebsd-hackers@FreeBSD.ORG Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 29B7416A41F for ; Fri, 16 Dec 2005 10:05:31 +0000 (GMT) (envelope-from Alexander@Leidinger.net) Received: from www.ebusiness-leidinger.de (jojo.ms-net.de [84.16.236.246]) by mx1.FreeBSD.org (Postfix) with ESMTP id 4335D43D55 for ; Fri, 16 Dec 2005 10:05:29 +0000 (GMT) (envelope-from Alexander@Leidinger.net) Received: from Andro-Beta.Leidinger.net (p54A5E858.dip.t-dialin.net [84.165.232.88]) (authenticated bits=0) by www.ebusiness-leidinger.de (8.13.1/8.13.1) with ESMTP id jBGA5Hn2077301; Fri, 16 Dec 2005 11:05:18 +0100 (CET) (envelope-from Alexander@Leidinger.net) Received: from localhost (localhost [127.0.0.1]) by Andro-Beta.Leidinger.net (8.13.3/8.13.3) with ESMTP id jBGA5PMT040964; Fri, 16 Dec 2005 11:05:25 +0100 (CET) (envelope-from Alexander@Leidinger.net) Received: from pslux.cec.eu.int (pslux.cec.eu.int [158.169.9.14]) by webmail.leidinger.net (Horde MIME library) with HTTP; Fri, 16 Dec 2005 11:05:24 +0100 Message-ID: <20051216110524.vvmm14ahq8wg88og@netchild.homeip.net> X-Priority: 3 (Normal) Date: Fri, 16 Dec 2005 11:05:24 +0100 From: Alexander Leidinger To: Scott Long References: <43A26FFB.9080405@samsco.org> In-Reply-To: <43A26FFB.9080405@samsco.org> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8; format="flowed" Content-Disposition: inline Content-Transfer-Encoding: 7bit User-Agent: Internet Messaging Program (IMP) H3 (4.0.3) / FreeBSD-4.11 X-Virus-Scanned: by amavisd-new X-Mailman-Approved-At: Fri, 16 Dec 2005 12:57:28 +0000 Cc: hackers@FreeBSD.org Subject: Re: My wish list for 6.1 X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Dec 2005 10:05:31 -0000 Scott Long wrote: > Guys, > > With code freeze for 6.1 about 6 weeks away, I'd like to put out my > 'wish list' for it: What about putting 1. and 3. on the new ideas page (marked as important and including a deadline)? At least for 3. more eyes would be beneficial. > 1. working kbdmux. We need this for the growing number of systems that > assume that USB is the primary keyboard. Current status appears to be > that the kbdmux driver breaks very easily. We need this working well > enough where it can be enabled by default, and all attached keyboards > Just Work. > 3. Full review and update of the install docs, handbook, FAQ, etc. > There are sections that are embarrassingly out of date (one section of > the handbook apparently states that we only support a single brand of > wifi cards). A co-worker of mine tried to install 6.0 using just the > handbook install guide, and discovered that it really doesn't match > reality anymore, in both big and small ways. Contact me directly if > you would like his list of comments. Bye, Alexander. -- http://www.Leidinger.net Alexander @ Leidinger.net: PGP ID = B0063FE7 http://www.FreeBSD.org netchild @ FreeBSD.org : PGP ID = 72077137 BOFH excuse #130: new management From owner-freebsd-hackers@FreeBSD.ORG Fri Dec 16 15:40:24 2005 Return-Path: X-Original-To: hackers@FreeBSD.ORG Delivered-To: freebsd-hackers@FreeBSD.ORG Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 68C2E16A41F for ; Fri, 16 Dec 2005 15:40:24 +0000 (GMT) (envelope-from cracauer@schlepper.zs64.net) Received: from schlepper.zs64.net (schlepper.zs64.net [212.12.50.230]) by mx1.FreeBSD.org (Postfix) with ESMTP id C88FF43D55 for ; Fri, 16 Dec 2005 15:40:23 +0000 (GMT) (envelope-from cracauer@schlepper.zs64.net) Received: from schlepper.zs64.net (schlepper [212.12.50.230]) by schlepper.zs64.net (8.13.3/8.12.9) with ESMTP id jBGFeMC4021135; Fri, 16 Dec 2005 16:40:22 +0100 (CET) (envelope-from cracauer@schlepper.zs64.net) Received: (from cracauer@localhost) by schlepper.zs64.net (8.13.3/8.12.9/Submit) id jBGFeMdb021134; Fri, 16 Dec 2005 10:40:22 -0500 (EST) (envelope-from cracauer) Date: Fri, 16 Dec 2005 10:40:22 -0500 From: Martin Cracauer To: Scott Long Message-ID: <20051216104022.A20877@cons.org> References: <43A26FFB.9080405@samsco.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2.5i In-Reply-To: <43A26FFB.9080405@samsco.org>; from scottl@samsco.org on Fri, Dec 16, 2005 at 12:42:51AM -0700 Cc: hackers@FreeBSD.ORG Subject: Re: My wish list for 6.1 X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Dec 2005 15:40:24 -0000 Scott Long wrote on Fri, Dec 16, 2005 at 12:42:51AM -0700: > > 2. SMP kernels for install. Right now we only install a UP kernel, for > performance reasons. We should be able to package both a UP and SMP > kernel into the release bits, and have sysinstall install both. It > should also select the correct one for the target system and make that > the default on boot. If people are concerned about performance, I benchmarked a 6-beta kernel SMP versus UP on a socket 939 Opteron. The performance characteristic for the parallel tests with CPU-eaters and plain http streams in the background is different. But there certainly is no slowdown that would make us look bad when people use a SMP kernel on a one-processor machine. CPU time results: http://www.cons.org/cracauer/crabench/smpkernel.user.html Wall clock time results: http://www.cons.org/cracauer/crabench/smpkernel.wall.html General benchmark homepage (lots of AMD64 and memory benchmarking there): http://cracauer-forum.cons.org/forum/crabench.html Martin -- %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% Martin Cracauer http://www.cons.org/cracauer/ FreeBSD - where you want to go, today. http://www.freebsd.org/ From owner-freebsd-hackers@FreeBSD.ORG Fri Dec 16 16:13:51 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 48B5F16A41F; Fri, 16 Dec 2005 16:13:51 +0000 (GMT) (envelope-from jhb@freebsd.org) Received: from speedfactory.net (mail6.speedfactory.net [66.23.216.219]) by mx1.FreeBSD.org (Postfix) with ESMTP id 50B5043D45; Fri, 16 Dec 2005 16:13:50 +0000 (GMT) (envelope-from jhb@freebsd.org) Received: from server.baldwin.cx (unverified [66.23.211.162]) by speedfactory.net (SurgeMail 3.5b3) with ESMTP id 3945960 for multiple; Fri, 16 Dec 2005 11:11:51 -0500 Received: from localhost (john@localhost [127.0.0.1]) by server.baldwin.cx (8.13.1/8.13.1) with ESMTP id jBGGDibV080636; Fri, 16 Dec 2005 11:13:44 -0500 (EST) (envelope-from jhb@freebsd.org) From: John Baldwin To: freebsd-hackers@freebsd.org Date: Fri, 16 Dec 2005 11:14:12 -0500 User-Agent: KMail/1.8.2 References: <20051215223745.GA37768@FreeBSD.czest.pl> <20051216091057.GQ77268@cirb503493.alcatel.com.au> In-Reply-To: <20051216091057.GQ77268@cirb503493.alcatel.com.au> MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit Content-Disposition: inline Message-Id: <200512161114.14398.jhb@freebsd.org> X-Virus-Scanned: ClamAV 0.87.1/1210/Thu Dec 15 10:23:22 2005 on server.baldwin.cx X-Virus-Status: Clean X-Spam-Status: No, score=-2.8 required=4.2 tests=ALL_TRUSTED autolearn=failed version=3.0.2 X-Spam-Checker-Version: SpamAssassin 3.0.2 (2004-11-16) on server.baldwin.cx X-Server: High Performance Mail Server - http://surgemail.com r=1653887525 Cc: Peter Jeremy , "Wojciech A. Koszek" , phk@freebsd.org Subject: Re: [CALL FOR TESTERS] New system call: abort2() X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Dec 2005 16:13:51 -0000 On Friday 16 December 2005 04:10 am, Peter Jeremy wrote: > On Thu, 2005-Dec-15 22:37:45 +0000, Wojciech A. Koszek wrote: > > abort2(const char *why, int nargs, void **args); > > > >"why" is reason of program abort, "nargs" is number of arguments > >passed in "args". Both "why" and "args" (with "%p" format) will be > >printed via log(9). Sample output: > >[..] > >pid <3004> abort2: ABORT2 > >pid <3019> abort2: invalid argument > >[..] > > I don't believe the following code is correct. uap->args is a > userspace pointer so uap->args[i] is dereferencing a userspace > argument in kernelspace. > + arg = uargs[i] = (void *) fuword(uap->args[i]); > I think it should be fuword(uap->args + i); > > I don't see the point of the following test. "arg" is printed using > %p and never de-referenced so there's no reason it can't be NULL. I > would see that a legitimate use of abort2() is when the application > detects that a pointer is unexpectedly NULL. Aborting on -1 is less > clear - if fuword() fails, it will return -1 but, equally, a faulty > user application may have left -1 in a pointer. (Note that mmap(2) > returns -1 on error so it's not inconceivable that a pointer could > contain -1). > > + /* Prevent from faults in user-space */ > + if (arg == NULL || arg == (void *)-1) { > + error = EINVAL; > + break; > + } > > Taking the above into account, I believe the code should be: > + if (uap->args == NULL) > + break; > + error = copyin(uap->args, uargs, uap->nargs * sizeof (void > *)); + if (error != 0) > + break; Agreed. Also, copyinstr() can provide a better interface for copying the why string in. Also, the PROC LOCK isn't needed for reading the static p_pid and p_comm fields of struct proc. Also, I second the other comments of do { } while(0) vs goto. Many existing syscalls use 'goto out;' for error handling, and I think that is one of the very few cases when goto is useful and not harmful. -- John Baldwin <>< http://www.FreeBSD.org/~jhb/ "Power Users Use the Power to Serve" = http://www.FreeBSD.org From owner-freebsd-hackers@FreeBSD.ORG Fri Dec 16 16:36:38 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id B1CFD16A41F for ; Fri, 16 Dec 2005 16:36:38 +0000 (GMT) (envelope-from dan@dan.emsphone.com) Received: from dan.emsphone.com (dan.emsphone.com [199.67.51.101]) by mx1.FreeBSD.org (Postfix) with ESMTP id CC4E243D5A for ; Fri, 16 Dec 2005 16:36:37 +0000 (GMT) (envelope-from dan@dan.emsphone.com) Received: (from dan@localhost) by dan.emsphone.com (8.13.1/8.13.3) id jBGGaYMu011180; Fri, 16 Dec 2005 10:36:34 -0600 (CST) (envelope-from dan) Date: Fri, 16 Dec 2005 10:36:34 -0600 From: Dan Nelson To: "Roman Gorohov. " Message-ID: <20051216163634.GD89708@dan.emsphone.com> References: <14510301213.20051216105225@gmail.com> <200512160846.jBG8kaEB099405@lurza.secnetix.de> <979057908.20051216120816@gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <979057908.20051216120816@gmail.com> X-OS: FreeBSD 5.4-STABLE X-message-flag: Outlook Error User-Agent: Mutt/1.5.11 Cc: freebsd-hackers@freebsd.org Subject: Re: easy question about kill command X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Dec 2005 16:36:38 -0000 In the last episode (Dec 16), Roman Gorohov. said: > Oliver Fromme wrote: > > > roma.a.g wrote: > >> Is there anyone who can explain me, why when i say 'kill -HUP id', > >> and its failed to restart, kill say nothing? > > > There is no way for the kill command to know what the target > > process is going to do with the signal. This is entirely and only > > the business of the target process, which might chose to take the > > default action (in the case of SIGHUP it's to terminate the > > process), to ignore the signal alltogether, or to take some special > > action. Some programs use SIGHUP traditionally to rotate their > > logfiles, re-read configuration files, re-open network sockets, > > restart themselves, or other things. But that's entirely up to the > > program in question, and there is no way the kill command could > > know about it, let alone whether it was successful or not. > > Thanks for your reply. My question was about standard bsd daemons, > not about some apps with unpredictable behaviour. It still depends on what daemon you're talking about. syslogd, for example, re-reads /etc/syslog.conf and reloads its logfiles on SIGHUP. Luckily, most base daemons are started from their own /etc/rc.d/* scripts which know how that particular program works, so you can use them to start/stop/restart daemons and not have to look up pids manually. -- Dan Nelson dnelson@allantgroup.com From owner-freebsd-hackers@FreeBSD.ORG Fri Dec 16 18:22:40 2005 Return-Path: X-Original-To: hackers@freebsd.org Delivered-To: freebsd-hackers@FreeBSD.ORG Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 1EA4416A41F for ; Fri, 16 Dec 2005 18:22:39 +0000 (GMT) (envelope-from delphij@gmail.com) Received: from wproxy.gmail.com (wproxy.gmail.com [64.233.184.196]) by mx1.FreeBSD.org (Postfix) with ESMTP id E9F1243D53 for ; Fri, 16 Dec 2005 18:22:37 +0000 (GMT) (envelope-from delphij@gmail.com) Received: by wproxy.gmail.com with SMTP id i31so683550wra for ; Fri, 16 Dec 2005 10:22:37 -0800 (PST) DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=beta; d=gmail.com; h=received:message-id:date:from:reply-to:to:subject:cc:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; b=V0Qmx07UBWo88XXgnJ0Ao8pjpEF54PIpUugSSuBpa0BDx+ybxMQ51FvXPgdxJ7F7bA6HUwuNx/ZeAMieBqzuLYADZBSA5/1smn9xGgCBlfoqDm6GLOCNPeRlk8xEAYLJ2Ue62OiQ8wwqepvnsCbXXsQS6WXw4T2u7U7kmB6RZq0= Received: by 10.64.233.2 with SMTP id f2mr80587qbh; Fri, 16 Dec 2005 10:22:36 -0800 (PST) Received: by 10.65.72.5 with HTTP; Fri, 16 Dec 2005 10:22:36 -0800 (PST) Message-ID: Date: Sat, 17 Dec 2005 02:22:36 +0800 From: Xin LI To: Scott Long In-Reply-To: <43A26FFB.9080405@samsco.org> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: base64 Content-Disposition: inline References: <43A26FFB.9080405@samsco.org> Cc: hackers@freebsd.org Subject: Re: My wish list for 6.1 X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: delphij@delphij.net List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Dec 2005 18:22:40 -0000 SGksIFNjb3R0LAoKT24gMTIvMTYvMDUsIFNjb3R0IExvbmcgPHNjb3R0bEBzYW1zY28ub3JnPiB3 cm90ZToKPiBHdXlzLAo+Cj4gV2l0aCBjb2RlIGZyZWV6ZSBmb3IgNi4xIGFib3V0IDYgd2Vla3Mg YXdheSwgSSdkIGxpa2UgdG8gcHV0IG91dCBteQo+ICd3aXNoIGxpc3QnIGZvciBpdDoKCk1vcmUt b3ItbGVzcyBPVCBxdWVzdGlvbjogU2hhbGwgd2Ugc3dpdGNoIFVMRSBhcyB0aGUgZGVmYXVsdCBz Y2hlZHVsZXIKb24gLUhFQUQgdG8gZW5jb3VyYWdlIG1vcmUgdGVzdGluZyBhZ2FpbnN0IGl0PwoK Q2hlZXJzLAotLQpYaW4gTEkgPGRlbHBoaWpAZGVscGhpai5uZXQ+IGh0dHA6Ly93d3cuZGVscGhp ai5uZXQK From owner-freebsd-hackers@FreeBSD.ORG Fri Dec 16 18:25:43 2005 Return-Path: X-Original-To: hackers@freebsd.org Delivered-To: freebsd-hackers@FreeBSD.ORG Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 1FE9316A427 for ; Fri, 16 Dec 2005 18:25:42 +0000 (GMT) (envelope-from scottl@samsco.org) Received: from pooker.samsco.org (pooker.samsco.org [168.103.85.57]) by mx1.FreeBSD.org (Postfix) with ESMTP id 4593D43D73 for ; Fri, 16 Dec 2005 18:25:07 +0000 (GMT) (envelope-from scottl@samsco.org) Received: from [192.168.254.14] (imini.samsco.home [192.168.254.14]) (authenticated bits=0) by pooker.samsco.org (8.13.4/8.13.4) with ESMTP id jBGIOwWt019576; Fri, 16 Dec 2005 11:24:59 -0700 (MST) (envelope-from scottl@samsco.org) Message-ID: <43A3067A.6080307@samsco.org> Date: Fri, 16 Dec 2005 11:24:58 -0700 From: Scott Long User-Agent: Mozilla/5.0 (Macintosh; U; PPC Mac OS X Mach-O; en-US; rv:1.7.7) Gecko/20050416 X-Accept-Language: en-us, en MIME-Version: 1.0 To: delphij@delphij.net References: <43A26FFB.9080405@samsco.org> In-Reply-To: Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-1.4 required=3.8 tests=ALL_TRUSTED autolearn=failed version=3.1.0 X-Spam-Checker-Version: SpamAssassin 3.1.0 (2005-09-13) on pooker.samsco.org Cc: hackers@freebsd.org Subject: Re: My wish list for 6.1 X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Dec 2005 18:25:44 -0000 Xin LI wrote: > Hi, Scott, > > On 12/16/05, Scott Long wrote: > >>Guys, >> >>With code freeze for 6.1 about 6 weeks away, I'd like to put out my >>'wish list' for it: > > > More-or-less OT question: Shall we switch ULE as the default scheduler > on -HEAD to encourage more testing against it? > > Cheers, Only if there is someone committed to tracking and fixing bugs. Last time we tried this, we wasted a lot of time and energy. Scott From owner-freebsd-hackers@FreeBSD.ORG Fri Dec 16 19:55:25 2005 Return-Path: X-Original-To: hackers@freebsd.org Delivered-To: freebsd-hackers@FreeBSD.ORG Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id BD35316A41F for ; Fri, 16 Dec 2005 19:55:25 +0000 (GMT) (envelope-from anderson@centtech.com) Received: from mh1.centtech.com (moat3.centtech.com [207.200.51.50]) by mx1.FreeBSD.org (Postfix) with ESMTP id 4402C43D45 for ; Fri, 16 Dec 2005 19:55:24 +0000 (GMT) (envelope-from anderson@centtech.com) Received: from [192.168.42.22] (andersonbox2.centtech.com [192.168.42.22]) by mh1.centtech.com (8.13.1/8.13.1) with ESMTP id jBGJtNG1083640; Fri, 16 Dec 2005 13:55:23 -0600 (CST) (envelope-from anderson@centtech.com) Message-ID: <43A31BAA.9000604@centtech.com> Date: Fri, 16 Dec 2005 13:55:22 -0600 From: Eric Anderson User-Agent: Mozilla Thunderbird 1.0.7 (X11/20051204) X-Accept-Language: en-us, en MIME-Version: 1.0 To: Scott Long References: <43A26FFB.9080405@samsco.org> In-Reply-To: <43A26FFB.9080405@samsco.org> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Virus-Scanned: ClamAV 0.87.1/1210/Thu Dec 15 09:23:22 2005 on mh1.centtech.com X-Virus-Status: Clean Cc: hackers@freebsd.org Subject: Re: My wish list for 6.1 X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Dec 2005 19:55:25 -0000 Scott Long wrote: > Guys, > > With code freeze for 6.1 about 6 weeks away, I'd like to put out my > 'wish list' for it: > > 1. working kbdmux. We need this for the growing number of systems that > assume that USB is the primary keyboard. Current status appears to be > that the kbdmux driver breaks very easily. We need this working well > enough where it can be enabled by default, and all attached keyboards > Just Work. FWIW, I've been using this for months, on a box that I've rolled from 5, to 6 (when I started using it), and now 7 (although outdated now). It's been running perfectly, and until now I forgot I was using it. I'm using it so my machine has a ps/2 keyboard on boot for BIOS and loader screens, but then has my usb keyboard normally. I just leave the ps/2 kb on top of the system, since it doesn't reboot much. Maksim, thanks for the hard work on it so far! Eric -- ------------------------------------------------------------------------ Eric Anderson Sr. Systems Administrator Centaur Technology Anything that works is better than anything that doesn't. ------------------------------------------------------------------------ From owner-freebsd-hackers@FreeBSD.ORG Fri Dec 16 20:02:40 2005 Return-Path: X-Original-To: hackers@freebsd.org Delivered-To: freebsd-hackers@FreeBSD.ORG Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 5E85616A41F for ; Fri, 16 Dec 2005 20:02:40 +0000 (GMT) (envelope-from kris@obsecurity.org) Received: from elvis.mu.org (elvis.mu.org [192.203.228.196]) by mx1.FreeBSD.org (Postfix) with ESMTP id 9C52043D69 for ; Fri, 16 Dec 2005 20:02:39 +0000 (GMT) (envelope-from kris@obsecurity.org) Received: from obsecurity.dyndns.org (elvis.mu.org [192.203.228.196]) by elvis.mu.org (Postfix) with ESMTP id 727661A3C27; Fri, 16 Dec 2005 12:02:39 -0800 (PST) Received: by obsecurity.dyndns.org (Postfix, from userid 1000) id CB2BB51257; Fri, 16 Dec 2005 15:02:38 -0500 (EST) Date: Fri, 16 Dec 2005 15:02:38 -0500 From: Kris Kennaway To: delphij@delphij.net Message-ID: <20051216200238.GA92404@xor.obsecurity.org> References: <43A26FFB.9080405@samsco.org> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="SLDf9lqlvOQaIe6s" Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.4.2.1i Cc: Scott Long , hackers@freebsd.org Subject: Re: My wish list for 6.1 X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Dec 2005 20:02:40 -0000 --SLDf9lqlvOQaIe6s Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Sat, Dec 17, 2005 at 02:22:36AM +0800, Xin LI wrote: > Hi, Scott, >=20 > On 12/16/05, Scott Long wrote: > > Guys, > > > > With code freeze for 6.1 about 6 weeks away, I'd like to put out my > > 'wish list' for it: >=20 > More-or-less OT question: Shall we switch ULE as the default scheduler > on -HEAD to encourage more testing against it? No, it's already known to have stability problems (on large SMP machines) and performance problems under load (about 10-20% slower than 4BSD), so until someone fixes those there's no point. Kris --SLDf9lqlvOQaIe6s Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.2 (FreeBSD) iD8DBQFDox1eWry0BWjoQKURAqCpAJ9pSdDJT/YjzdO/3jYHjiD13fmXGACdEFcM Ry4YKG63qoxpPo9L17eo0mQ= =tXyq -----END PGP SIGNATURE----- --SLDf9lqlvOQaIe6s-- From owner-freebsd-hackers@FreeBSD.ORG Fri Dec 16 20:38:57 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id DBE4C16A41F for ; Fri, 16 Dec 2005 20:38:57 +0000 (GMT) (envelope-from amesbury@umn.edu) Received: from mtaout-c.tc.umn.edu (mtaout-c.tc.umn.edu [160.94.128.21]) by mx1.FreeBSD.org (Postfix) with ESMTP id 62F6243D49 for ; Fri, 16 Dec 2005 20:38:57 +0000 (GMT) (envelope-from amesbury@umn.edu) Received: from [160.94.247.212] (paulaner.oitsec.umn.edu [160.94.247.212]) by mtaout-c.tc.umn.edu with ESMTP for freebsd-hackers@freebsd.org; Fri, 16 Dec 2005 14:38:56 -0600 (CST) X-Umn-Remote-Mta: [N] paulaner.oitsec.umn.edu [160.94.247.212] #+LO+TS+AU+HN Message-ID: <43A325DC.306@umn.edu> Date: Fri, 16 Dec 2005 14:38:52 -0600 From: Alan Amesbury User-Agent: Mozilla Thunderbird 1.0.6 (X11/20050909) X-Accept-Language: en-us, en MIME-Version: 1.0 To: freebsd-hackers@freebsd.org X-Enigmail-Version: 0.92.0.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Subject: 6-STABLE: HZ>1000, RFC1323 non-compliance, and PF X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Dec 2005 20:38:58 -0000 On a relatively recently CVSup'ed 6-STABLE box, /sys/i386/conf/NOTES says: # DEVICE_POLLING adds support for mixed interrupt-polling handling # of network device drivers, which has significant benefits in terms # of robustness to overloads and responsivity, as well as permitting # accurate scheduling of the CPU time between kernel network processing # and other activities. The drawback is a moderate (up to 1/HZ seconds) # potential increase in response times. # It is strongly recommended to use HZ=1000 or 2000 with DEVICE_POLLING # to achieve smoother behaviour. # Additionally, you can enable/disable polling at runtime with help of # the ifconfig(8) utility, and select the CPU fraction reserved to # userland with the sysctl variable kern.polling.user_frac # (default 50, range 0..100). Because we have several systems equipped with em(4)-compatible cards that are intended to accept traffic at gigabit speeds, I've configured them with HZ=2000, per the notes above. However, 6-STABLE has also included some newer pf(4) code, which is fundamentally incompatible with a HZ setting this high. I did some digging and eventually came up with this PR: http://www.freebsd.org/cgi/query-pr.cgi?pr=kern/61404 The problems we've seen appear to be because FreeBSD boxes with HZ=2000 are picking non-RFC1323-compliant timestamps, which are being discarded by the recently added PAWS code in FreeBSD's implementation of pf(4), which seems to be consistent with the observations made in the discussion linked to by the PR. Since this problem has been known for close to two years, I was wondering if anyone had heard of any progress being made on it The PR includes a patch, but the notes make it look like it's applicable to the 4.x branch, not the newer stuff. It's an issue that definitely affects us, and I suspect we can't be the only ones. So..... Any good news on this? Also, what can I do to assist in terms of testing or otherwise getting this bug fixed? -- Alan Amesbury University of Minnesota From owner-freebsd-hackers@FreeBSD.ORG Fri Dec 16 21:47:40 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id A94AE16A41F; Fri, 16 Dec 2005 21:47:40 +0000 (GMT) (envelope-from dunstan@freebsd.czest.pl) Received: from freebsd.czest.pl (freebsd.czest.pl [80.48.250.4]) by mx1.FreeBSD.org (Postfix) with ESMTP id AB27043D82; Fri, 16 Dec 2005 21:47:37 +0000 (GMT) (envelope-from dunstan@freebsd.czest.pl) Received: from freebsd.czest.pl (freebsd.czest.pl [80.48.250.4]) by freebsd.czest.pl (8.12.10/8.12.9) with ESMTP id jBGLo3Px058834; Fri, 16 Dec 2005 21:50:04 GMT (envelope-from dunstan@freebsd.czest.pl) Received: (from dunstan@localhost) by freebsd.czest.pl (8.13.4/8.12.9/Submit) id jBGLo3iI058833; Fri, 16 Dec 2005 21:50:03 GMT (envelope-from dunstan) Date: Fri, 16 Dec 2005 21:50:02 +0000 From: "Wojciech A. Koszek" To: Peter Jeremy Message-ID: <20051216215002.GA58739@FreeBSD.czest.pl> References: <20051215223745.GA37768@FreeBSD.czest.pl> <20051216091057.GQ77268@cirb503493.alcatel.com.au> Mime-Version: 1.0 Content-Type: text/plain; charset=iso-8859-2 Content-Disposition: inline In-Reply-To: <20051216091057.GQ77268@cirb503493.alcatel.com.au> User-Agent: Mutt/1.4.2.1i Cc: freebsd-hackers@freebsd.org, phk@freebsd.org Subject: Re: [CALL FOR TESTERS] New system call: abort2() X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Dec 2005 21:47:40 -0000 On Fri, Dec 16, 2005 at 08:10:57PM +1100, Peter Jeremy wrote: > On Thu, 2005-Dec-15 22:37:45 +0000, Wojciech A. Koszek wrote: > > abort2(const char *why, int nargs, void **args); > > > >"why" is reason of program abort, "nargs" is number of arguments > >passed in "args". Both "why" and "args" (with "%p" format) will be > >printed via log(9). Sample output: > >[..] > >pid <3004> abort2: ABORT2 > >pid <3019> abort2: invalid argument > >[..] > > I don't believe the following code is correct. uap->args is a > userspace pointer so uap->args[i] is dereferencing a userspace > argument in kernelspace. > + arg = uargs[i] = (void *) fuword(uap->args[i]); > I think it should be fuword(uap->args + i); > > I don't see the point of the following test. "arg" is printed using > %p and never de-referenced so there's no reason it can't be NULL. I > would see that a legitimate use of abort2() is when the application > detects that a pointer is unexpectedly NULL. Aborting on -1 is less > clear - if fuword() fails, it will return -1 but, equally, a faulty > user application may have left -1 in a pointer. (Note that mmap(2) > returns -1 on error so it's not inconceivable that a pointer could > contain -1). > > + /* Prevent from faults in user-space */ > + if (arg == NULL || arg == (void *)-1) { > + error = EINVAL; > + break; > + } > > Taking the above into account, I believe the code should be: > + if (uap->args == NULL) > + break; > + error = copyin(uap->args, uargs, uap->nargs * sizeof (void *)); > + if (error != 0) > + break; Of course! Thanks for this comment! Updated version should be available soon. -- * Wojciech A. Koszek && dunstan@FreeBSD.czest.pl From owner-freebsd-hackers@FreeBSD.ORG Fri Dec 16 21:56:03 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 688F916A420 for ; Fri, 16 Dec 2005 21:56:03 +0000 (GMT) (envelope-from reichert@numachi.com) Received: from meisai.numachi.com (meisai.numachi.com [198.175.254.6]) by mx1.FreeBSD.org (Postfix) with SMTP id 58A6343D77 for ; Fri, 16 Dec 2005 21:55:57 +0000 (GMT) (envelope-from reichert@numachi.com) Received: (qmail 79000 invoked from network); 16 Dec 2005 21:55:55 -0000 Received: from natto.numachi.com (198.175.254.216) by meisai.numachi.com with SMTP; 16 Dec 2005 21:55:55 -0000 Received: (qmail 30916 invoked by uid 1001); 16 Dec 2005 21:55:54 -0000 Date: Fri, 16 Dec 2005 16:55:54 -0500 From: Brian Reichert To: "roma.a.g" Message-ID: <20051216215554.GT19179@numachi.com> References: <14510301213.20051216105225@gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <14510301213.20051216105225@gmail.com> User-Agent: Mutt/1.5.10i Cc: freebsd-hackers@freebsd.org Subject: Re: easy question about kill command X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Dec 2005 21:56:03 -0000 On Fri, Dec 16, 2005 at 10:52:25AM +0300, roma.a.g wrote: > Is there anyone who can explain me, why when i say 'kill -HUP id', and its failed to restart, kill say nothing? That's because all kill is responsible for is sending the signal; see kill(2). As to whether or not the process in question has a SIGHUP handler, and what the behavior of that handler is, or what the latency in said handler has in completing it's desired actions, is completely outside the scope of the kill() syscall. > It is such an easy to implement... No, it's not: kill would need lots of knowledge about how every possible program is supposed to work when sent a SIGHUP. The apache_ctl script suppied by the Apache project is an example of a control script that doesn't always work; said script thinks that if it found a PID, and could send a HUP signal to it, it would gleefully inform the user that apache has been stopped. I've had to roll my own management script that more agressively checks, and will not return until Apache indeed stops. I needed this in a situation where Apache, via mod_perl, had a bunch of pending SQL transactions; asking apache to stop via a HUP could take _minutes_ until all of those SQL connections tore down. kill(2), and anything built on top of that, would have no idea if the HUP signal was being processed at all... > Roman Gorohov. mailto:roma.a.g@gmail.com -- Brian Reichert 55 Crystal Ave. #286 Daytime number: (603) 434-6842 Derry NH 03038-1725 USA BSD admin/developer at large From owner-freebsd-hackers@FreeBSD.ORG Fri Dec 16 22:09:20 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 2269C16A41F for ; Fri, 16 Dec 2005 22:09:20 +0000 (GMT) (envelope-from sean-freebsd@farley.org) Received: from mail.farley.org (farley.org [67.64.95.201]) by mx1.FreeBSD.org (Postfix) with ESMTP id 73BDD43D58 for ; Fri, 16 Dec 2005 22:09:18 +0000 (GMT) (envelope-from sean-freebsd@farley.org) Received: from thor.farley.org (thor.farley.org [IPv6:2001:470:1f01:290:1::5]) by mail.farley.org (8.13.1/8.13.1) with ESMTP id jBGM9G8w017114 for ; Fri, 16 Dec 2005 16:09:16 -0600 (CST) (envelope-from sean-freebsd@farley.org) Date: Fri, 16 Dec 2005 16:09:16 -0600 (CST) From: =?ISO-8859-1?Q?Se=E1n_C=2E_Farley?= To: freebsd-hackers@freebsd.org Message-ID: <20051216155717.W4815@thor.farley.org> MIME-Version: 1.0 Content-Type: MULTIPART/MIXED; BOUNDARY="0-1965985357-1134770956=:4815" Subject: Number of kevents registered in kqueue X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Dec 2005 22:09:20 -0000 This message is in MIME format. The first part should be readable text, while the remaining parts are likely unreadable without MIME-aware tools. --0-1965985357-1134770956=:4815 Content-Type: TEXT/PLAIN; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: QUOTED-PRINTABLE I may have missed it in the man page, but I am unable to find a way to determine how many kevents are currently registered within a kqueue. If there is no method for a count, how about a way to find if a kqueue is empty or not. Besides tracking what events are still within a kqueue, this would make for an easier way to write an event loop. Currently, calling kevent() on an empty kqueue will still block. Also, I recommend that the man page mention that a kqueue may be close(2)'d. The only reference that it can be is that the manual page says the kqueue() call returns a descriptor. Se=E1n --=20 sean-freebsd@farley.org --0-1965985357-1134770956=:4815-- From owner-freebsd-hackers@FreeBSD.ORG Fri Dec 16 22:17:37 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id DE67916A41F; Fri, 16 Dec 2005 22:17:36 +0000 (GMT) (envelope-from dunstan@freebsd.czest.pl) Received: from freebsd.czest.pl (freebsd.czest.pl [80.48.250.4]) by mx1.FreeBSD.org (Postfix) with ESMTP id 0B7E043D7B; Fri, 16 Dec 2005 22:17:18 +0000 (GMT) (envelope-from dunstan@freebsd.czest.pl) Received: from freebsd.czest.pl (freebsd.czest.pl [80.48.250.4]) by freebsd.czest.pl (8.12.10/8.12.9) with ESMTP id jBGMJiPx058925; Fri, 16 Dec 2005 22:19:44 GMT (envelope-from dunstan@freebsd.czest.pl) Received: (from dunstan@localhost) by freebsd.czest.pl (8.13.4/8.12.9/Submit) id jBGMJhlR058924; Fri, 16 Dec 2005 22:19:44 GMT (envelope-from dunstan) Date: Fri, 16 Dec 2005 22:19:43 +0000 From: "Wojciech A. Koszek" To: John Baldwin Message-ID: <20051216221943.GB58739@FreeBSD.czest.pl> References: <20051215223745.GA37768@FreeBSD.czest.pl> <20051216091057.GQ77268@cirb503493.alcatel.com.au> <200512161114.14398.jhb@freebsd.org> Mime-Version: 1.0 Content-Type: text/plain; charset=iso-8859-2 Content-Disposition: inline In-Reply-To: <200512161114.14398.jhb@freebsd.org> User-Agent: Mutt/1.4.2.1i Cc: freebsd-hackers@freebsd.org, phk@freebsd.org, Peter Jeremy Subject: Re: [CALL FOR TESTERS] New system call: abort2() X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Dec 2005 22:17:37 -0000 On Fri, Dec 16, 2005 at 11:14:12AM -0500, John Baldwin wrote: > On Friday 16 December 2005 04:10 am, Peter Jeremy wrote: > > On Thu, 2005-Dec-15 22:37:45 +0000, Wojciech A. Koszek wrote: > > > abort2(const char *why, int nargs, void **args); > > > > > >"why" is reason of program abort, "nargs" is number of arguments > > >passed in "args". Both "why" and "args" (with "%p" format) will be > > >printed via log(9). Sample output: > > >[..] > > >pid <3004> abort2: ABORT2 > > >pid <3019> abort2: invalid argument > > >[..] > > > > I don't believe the following code is correct. uap->args is a > > userspace pointer so uap->args[i] is dereferencing a userspace > > argument in kernelspace. > > + arg = uargs[i] = (void *) fuword(uap->args[i]); > > I think it should be fuword(uap->args + i); > > > > I don't see the point of the following test. "arg" is printed using > > %p and never de-referenced so there's no reason it can't be NULL. I > > would see that a legitimate use of abort2() is when the application > > detects that a pointer is unexpectedly NULL. Aborting on -1 is less > > clear - if fuword() fails, it will return -1 but, equally, a faulty > > user application may have left -1 in a pointer. (Note that mmap(2) > > returns -1 on error so it's not inconceivable that a pointer could > > contain -1). > > > > + /* Prevent from faults in user-space */ > > + if (arg == NULL || arg == (void *)-1) { > > + error = EINVAL; > > + break; > > + } > > > > Taking the above into account, I believe the code should be: > > + if (uap->args == NULL) > > + break; > > + error = copyin(uap->args, uargs, uap->nargs * sizeof (void > > *)); + if (error != 0) > > + break; > > Agreed. Also, copyinstr() can provide a better interface for copying the why > string in. Also, the PROC LOCK isn't needed for reading the static p_pid and > p_comm fields of struct proc. Also, I second the other comments of do { } > while(0) vs goto. Many existing syscalls use 'goto out;' for error handling, > and I think that is one of the very few cases when goto is useful and not > harmful. Thanks for the suggestions and comments! My question is related with copying string from user-space: the only difference I can see between those functions (other than operating of strings/sbufs) is that sbuf_copyin() looses 'done' [1]. Since current abort2() makes use of sbuf(9), I'll have to have additional buffer just for string copying and than copy it to sbuf. Would you prefer this solution or complete migration from sbufs to strl..()? [1] Couldn't sbuf_copyin() simply return 'done' from copyinstr() embedded in it, since it already returns -1 on failure? This function is used in two places, which make no use of return value. -- * Wojciech A. Koszek && dunstan@FreeBSD.czest.pl From owner-freebsd-hackers@FreeBSD.ORG Fri Dec 16 22:21:07 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 5208B16A41F for ; Fri, 16 Dec 2005 22:21:07 +0000 (GMT) (envelope-from dan@dan.emsphone.com) Received: from dan.emsphone.com (dan.emsphone.com [199.67.51.101]) by mx1.FreeBSD.org (Postfix) with ESMTP id CAB0C43D62 for ; Fri, 16 Dec 2005 22:20:56 +0000 (GMT) (envelope-from dan@dan.emsphone.com) Received: (from dan@localhost) by dan.emsphone.com (8.13.1/8.13.3) id jBGMKj5N096999; Fri, 16 Dec 2005 16:20:45 -0600 (CST) (envelope-from dan) Date: Fri, 16 Dec 2005 16:20:45 -0600 From: Dan Nelson To: =?utf-8?B?U2XDoW4gQy4=?= Farley Message-ID: <20051216222045.GF89708@dan.emsphone.com> References: <20051216155717.W4815@thor.farley.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20051216155717.W4815@thor.farley.org> X-OS: FreeBSD 5.4-STABLE X-message-flag: Outlook Error User-Agent: Mutt/1.5.11 Cc: freebsd-hackers@freebsd.org Subject: Re: Number of kevents registered in kqueue X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Dec 2005 22:21:07 -0000 In the last episode (Dec 16), Sen C. Farley said: > I may have missed it in the man page, but I am unable to find a way > to determine how many kevents are currently registered within a > kqueue. If there is no method for a count, how about a way to find > if a kqueue is empty or not. Besides tracking what events are still > within a kqueue, this would make for an easier way to write an event > loop. Currently, calling kevent() on an empty kqueue will still > block. I don't think there's a way currently. What I did in my local tree is modify kern_kevent so that if the magic number -1 is passed in as nchanges, it will return the entire queued event list back to the caller in *eventlist, and return the number of events as the returncode. Very useful for debugging kqueue-using programs where you want to compare what you think you're waiting for, and what the kernel thinks you're waiting for :) -- Dan Nelson dnelson@allantgroup.com From owner-freebsd-hackers@FreeBSD.ORG Fri Dec 16 22:25:22 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id A5FCE16A430 for ; Fri, 16 Dec 2005 22:25:21 +0000 (GMT) (envelope-from jmg@hydrogen.funkthat.com) Received: from hydrogen.funkthat.com (gate.funkthat.com [69.17.45.168]) by mx1.FreeBSD.org (Postfix) with ESMTP id 9AB2743D5A for ; Fri, 16 Dec 2005 22:24:51 +0000 (GMT) (envelope-from jmg@hydrogen.funkthat.com) Received: from hydrogen.funkthat.com (localhost.funkthat.com [127.0.0.1]) by hydrogen.funkthat.com (8.13.3/8.13.3) with ESMTP id jBGMOLR8075674; Fri, 16 Dec 2005 14:24:21 -0800 (PST) (envelope-from jmg@hydrogen.funkthat.com) Received: (from jmg@localhost) by hydrogen.funkthat.com (8.13.3/8.13.3/Submit) id jBGMOLGF075673; Fri, 16 Dec 2005 14:24:21 -0800 (PST) (envelope-from jmg) Date: Fri, 16 Dec 2005 14:24:20 -0800 From: John-Mark Gurney To: =?iso-8859-1?Q?Se=E1n_C=2E?= Farley Message-ID: <20051216222420.GI55657@funkthat.com> Mail-Followup-To: =?iso-8859-1?Q?Se=E1n_C=2E?= Farley , freebsd-hackers@freebsd.org References: <20051216155717.W4815@thor.farley.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20051216155717.W4815@thor.farley.org> User-Agent: Mutt/1.4.2.1i X-Operating-System: FreeBSD 5.4-RELEASE-p6 i386 X-PGP-Fingerprint: B7 EC EF F8 AE ED A7 31 96 7A 22 B3 D8 56 36 F4 X-Files: The truth is out there X-URL: http://resnet.uoregon.edu/~gurney_j/ X-Resume: http://resnet.uoregon.edu/~gurney_j/resume.html Cc: freebsd-hackers@freebsd.org Subject: Re: Number of kevents registered in kqueue X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: John-Mark Gurney List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Dec 2005 22:25:22 -0000 Sen C. Farley wrote this message on Fri, Dec 16, 2005 at 16:09 -0600: > I may have missed it in the man page, but I am unable to find a way to > determine how many kevents are currently registered within a kqueue. If > there is no method for a count, how about a way to find if a kqueue is > empty or not. Besides tracking what events are still within a kqueue, > this would make for an easier way to write an event loop. Currently, > calling kevent() on an empty kqueue will still block. Why do you need this? What is the point of calling kevent if you don't have an event to wake it up? Can you give us an example of where you need to know that there isn't any events in the queue? (I can't think of one, since using kqueue w/o events is pointless.) I can't see how tracking the count will let you know which events are still in the kqueue... (second to last sentence) > Also, I recommend that the man page mention that a kqueue may be > close(2)'d. The only reference that it can be is that the manual page > says the kqueue() call returns a descriptor. I would think that it would need to be documented when you can't close a descriptor.. Neither pipe nor socketpair documents that close can be called on them... -- John-Mark Gurney Voice: +1 415 225 5579 "All that I will do, has been done, All that I have, has not." From owner-freebsd-hackers@FreeBSD.ORG Fri Dec 16 22:25:30 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id E669E16A426 for ; Fri, 16 Dec 2005 22:25:29 +0000 (GMT) (envelope-from vladgalu@gmail.com) Received: from zproxy.gmail.com (zproxy.gmail.com [64.233.162.202]) by mx1.FreeBSD.org (Postfix) with ESMTP id AF40B43D55 for ; Fri, 16 Dec 2005 22:25:21 +0000 (GMT) (envelope-from vladgalu@gmail.com) Received: by zproxy.gmail.com with SMTP id z6so791116nzd for ; Fri, 16 Dec 2005 14:25:14 -0800 (PST) DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=beta; d=gmail.com; h=received:message-id:date:from:to:subject:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; b=q582dt2kcLOrbyPoa3k6KBhD0ilwrXhvjvu3pJRTnjktp8yxv5LflXJZvWYqJktvb6dwF0gZrfXbkFbTaelGOQHmCWDMn1bTr9YIOQKbLIETXYDQi3ZEE4ROr+UBetuSiYJctgLPa8OCQivXYFaKHvLL4CMPm5cw1CtVaLLaHdc= Received: by 10.36.221.45 with SMTP id t45mr3536443nzg; Fri, 16 Dec 2005 14:25:14 -0800 (PST) Received: by 10.36.145.12 with HTTP; Fri, 16 Dec 2005 14:25:14 -0800 (PST) Message-ID: <79722fad0512161425x31a8931dpda33cf71c29b7c54@mail.gmail.com> Date: Sat, 17 Dec 2005 00:25:14 +0200 From: Vlad GALU To: freebsd-hackers@freebsd.org In-Reply-To: <20051216155717.W4815@thor.farley.org> MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Content-Disposition: inline References: <20051216155717.W4815@thor.farley.org> Subject: Re: Number of kevents registered in kqueue X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Dec 2005 22:25:30 -0000 On 12/17/05, Se=E1n C. Farley wrote: > I may have missed it in the man page, but I am unable to find a way to > determine how many kevents are currently registered within a kqueue. If > there is no method for a count, how about a way to find if a kqueue is > empty or not. Besides tracking what events are still within a kqueue, > this would make for an easier way to write an event loop. Currently, > calling kevent() on an empty kqueue will still block. kevent() returns the number of events from the changelist, which is at most nevents long. So you know already how many events you've registered and how many of them were yielded. As for blocking on an empty queue, you can get rid of it by passing a pointer to a zeroed struct timespec as the last argument to kevent(). This usually works: -- cut here -- int ev =3D kevent(kq, NULL, 0, events, maxevents, &timeout); for (int i =3D 0; i < ev; i++) ... -- and here -- where kq is the kqueue descriptor, events is a pointer to a struct kevent array, maxevents is the maximum number of watched events and timeout is a struct timespec with all members set to 0. For examples you can check thttpd/lighttpd and/org libevent, they all provide wrappers around kqueue. > Also, I recommend that the man page mention that a kqueue may be > close(2)'d. The only reference that it can be is that the manual page > says the kqueue() call returns a descriptor. > > Se=E1n > -- > sean-freebsd@farley.org > > _______________________________________________ > freebsd-hackers@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/freebsd-hackers > To unsubscribe, send any mail to "freebsd-hackers-unsubscribe@freebsd.org= " > > -- If it's there, and you can see it, it's real. If it's not there, and you can see it, it's virtual. If it's there, and you can't see it, it's transparent. If it's not there, and you can't see it, you erased it. From owner-freebsd-hackers@FreeBSD.ORG Fri Dec 16 22:26:18 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id B9FC616A420 for ; Fri, 16 Dec 2005 22:26:18 +0000 (GMT) (envelope-from silby@silby.com) Received: from relay00.pair.com (relay00.pair.com [209.68.5.9]) by mx1.FreeBSD.org (Postfix) with SMTP id A866443D78 for ; Fri, 16 Dec 2005 22:26:00 +0000 (GMT) (envelope-from silby@silby.com) Received: (qmail 6655 invoked from network); 16 Dec 2005 22:25:54 -0000 Received: from unknown (HELO localhost) (unknown) by unknown with SMTP; 16 Dec 2005 22:25:54 -0000 X-pair-Authenticated: 209.68.2.70 Date: Fri, 16 Dec 2005 16:25:53 -0600 (CST) From: Mike Silbersack To: Alan Amesbury In-Reply-To: <43A325DC.306@umn.edu> Message-ID: <20051216162507.O937@odysseus.silby.com> References: <43A325DC.306@umn.edu> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed Cc: freebsd-hackers@freebsd.org Subject: Re: 6-STABLE: HZ>1000, RFC1323 non-compliance, and PF X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Dec 2005 22:26:19 -0000 On Fri, 16 Dec 2005, Alan Amesbury wrote: > Because we have several systems equipped with em(4)-compatible cards > that are intended to accept traffic at gigabit speeds, I've configured > them with HZ=2000, per the notes above. However, 6-STABLE has also > included some newer pf(4) code, which is fundamentally incompatible with > a HZ setting this high. I did some digging and eventually came up with > this PR: > > http://www.freebsd.org/cgi/query-pr.cgi?pr=kern/61404 I'll throw it on my to-do list, hopefully I'll get to it over the next few weeks. I'm going to fix it a bit differently than that patch does, though. Mike "Silby" Silbersack From owner-freebsd-hackers@FreeBSD.ORG Fri Dec 16 22:37:12 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 70BF616A41F for ; Fri, 16 Dec 2005 22:37:12 +0000 (GMT) (envelope-from V.Haisman@sh.cvut.cz) Received: from service.sh.cvut.cz (service.sh.cvut.cz [147.32.127.214]) by mx1.FreeBSD.org (Postfix) with ESMTP id A129243D66 for ; Fri, 16 Dec 2005 22:37:07 +0000 (GMT) (envelope-from V.Haisman@sh.cvut.cz) Received: from localhost (localhost [127.0.0.1]) by service.sh.cvut.cz (Postfix) with ESMTP id CFC351A3380; Fri, 16 Dec 2005 23:37:05 +0100 (CET) Received: from service.sh.cvut.cz ([127.0.0.1]) by localhost (service [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 24300-04; Fri, 16 Dec 2005 23:37:01 +0100 (CET) Received: from logout.sh.cvut.cz (logout.sh.cvut.cz [147.32.127.203]) by service.sh.cvut.cz (Postfix) with ESMTP id 0D1D01A337C; Fri, 16 Dec 2005 23:36:59 +0100 (CET) Received: from [192.168.1.2] (localhost [127.0.0.1]) by logout.sh.cvut.cz (Postfix) with ESMTP id 6751A61C1F; Fri, 16 Dec 2005 23:41:21 +0100 (CET) Message-ID: <43A3416A.2000407@sh.cvut.cz> Date: Fri, 16 Dec 2005 23:36:26 +0100 From: =?UTF-8?B?VsOhY2xhdiBIYWlzbWFu?= User-Agent: Mozilla Thunderbird 1.0.7 (Windows/20050923) X-Accept-Language: en-us, en MIME-Version: 1.0 To: =?UTF-8?B?IlNlw6FuIEMuIEZhcmxleSI=?= References: <20051216155717.W4815@thor.farley.org> In-Reply-To: <20051216155717.W4815@thor.farley.org> X-Enigmail-Version: 0.93.0.0 OpenPGP: id=733031B4 Face: iVBORw0KGgoAAAANSUhEUgAAADAAAAAwBAMAAAClLOS0AAAAMFBMVEUnMzWJm5S+0864pn5r blp/hnW2up7X7uqftbNRVUrW1LGBdGfHwJqPi3ScoYtBQzhDxGEwAAAAB3RJTUUH1QoQDDgyQtx8 HQAAAkNJREFUeJzFU0toU0EUPYu66CpGdCUUmoUJkpUDQUoNBVEUrBJsq1Ki2EIKIUZ8mydBhYi0 wVUXJVCLCrFN4DIEQdxIqdBIFsMkWD9YJClCRGKjJaviynjfe8RPogtXPcObuXPOPXd+PHj+Aeyo QNmobGLXVeANGM+GsP0B2yqHHNVoCD2LwLglVGZx7yXSlADR0uZu9C4Bpy3hUxPvH/cuUw6UoPCL h64I8KAJuMpwRU8uUMJy0OIpHVeXmulZoCc/t0LlTbJLEY1EudPRcnVjgAP5Osdl4K5HVP4+2bAI okaUA0Iq6Q59+Zy2eMWN6EpFTsa3+uD1+JKj4TPHuYTSMaLScLAaqk94YJqG4ds30hojOVgYoNJc NTztNU2TBYbhu9Aafnq08ORja37da1NwBrN/b7NVEc+b8yecuYkp08vNvLYneVZRaSH1vS0UnfHm OUPzWaZufHPmCWSdWrfeGVQQKmcsO4If8pAdXJ/xF4QQAeOVY1AQQcfirwkLUWeWVTgi6vaGt2xe BGzBEIMQorru8RxgPqY1V6uxYnwVBRZEI1ytCm3dE8mC2DgcbzCJGHdBEVDKuWDSwsrSGoqzJmNt 2jJpNueIH0qS8/0JrDKnVBdvOzIsdVr4zaX9dn9xcLLKdCtQGfutVacLE9Ja+yfbDvO4aMWrklfK /JYv15C8Kw9S10kup5Bys0N1bLdcn4HvTl/Xlh6Fpllwj5/XpH9BUXn/ym0Dvv7Rt2MywojpYiSi i7Hsscaa19zZ//y/hR+BT/ns80nmJAAAAABJRU5ErkJggg== Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="------------enigFD91E7217177B7708B5ABC99" X-Virus-Scanned: by amavisd-new at sh.cvut.cz Cc: freebsd-hackers@freebsd.org Subject: Re: Number of kevents registered in kqueue X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Dec 2005 22:37:12 -0000 This is an OpenPGP/MIME signed message (RFC 2440 and 3156) --------------enigFD91E7217177B7708B5ABC99 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Se=C3=A1n C. Farley wrote: > I may have missed it in the man page, but I am unable to find a way to > determine how many kevents are currently registered within a kqueue. I= f > there is no method for a count, how about a way to find if a kqueue is > empty or not. Besides tracking what events are still within a kqueue, > this would make for an easier way to write an event loop. Currently, > calling kevent() on an empty kqueue will still block. >=20 > Also, I recommend that the man page mention that a kqueue may be > close(2)'d. The only reference that it can be is that the manual page > says the kqueue() call returns a descriptor. >=20 > Se=C3=A1n I was working with it recently and my understanding is that if you want to retrieve any events and not block if there are none then you should give it zeroed struct timespec. Quote from the man page: "If timeout is a NULL pointer, kevent() waits indefinitely. To effect a poll, the timeout argument should be non-NULL, pointing to a zero-valued timespec structure." Vaclav Haisman --------------enigFD91E7217177B7708B5ABC99 Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.1 (MingW32) Comment: Using GnuPG with Thunderbird - http://enigmail.mozdev.org iQEVAwUBQ6NBcG56zbtzMDG0AQJOSggAjrORSDYwonOivLSyo5rS0VjAZU2roguZ wAmKMV+uWpn5+bPW4QQoXBMOkhSt/N3n1uT2qu+KfAIq6BuvBZLhterpWwoqQAaU YNuPikYTRKy0HgC8nrEduBpsCrmKIsVjTdKtLQzZB6+xVjx3o60yV0RDhG2srXK/ fH4j8ZhzMhq2esvjUz0FAuU9r+y7jvY7C+AtLealqFYSkKuHEG597tCjgGpehUxk iUa3OFXnpAamMokDAYgMyIuTb17n8XXNihTwJ585/W1QzYClpxOwPetS1UZaa5KY b0nQ+d43TfshJJGZ1u9gVSd2xwynjMgcXH2OQ1vsjK3rpsR+jCbEjw== =UKPh -----END PGP SIGNATURE----- --------------enigFD91E7217177B7708B5ABC99-- From owner-freebsd-hackers@FreeBSD.ORG Fri Dec 16 22:43:45 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 096A516A41F for ; Fri, 16 Dec 2005 22:43:45 +0000 (GMT) (envelope-from sean-freebsd@farley.org) Received: from mail.farley.org (farley.org [67.64.95.201]) by mx1.FreeBSD.org (Postfix) with ESMTP id 6C7DE43D58 for ; Fri, 16 Dec 2005 22:43:40 +0000 (GMT) (envelope-from sean-freebsd@farley.org) Received: from thor.farley.org (thor.farley.org [IPv6:2001:470:1f01:290:1::5]) by mail.farley.org (8.13.1/8.13.1) with ESMTP id jBGMhcb4017482; Fri, 16 Dec 2005 16:43:38 -0600 (CST) (envelope-from sean-freebsd@farley.org) Date: Fri, 16 Dec 2005 16:43:38 -0600 (CST) From: =?ISO-8859-1?Q?Se=E1n_C=2E_Farley?= To: John-Mark Gurney In-Reply-To: <20051216222420.GI55657@funkthat.com> Message-ID: <20051216163622.S4815@thor.farley.org> References: <20051216155717.W4815@thor.farley.org> <20051216222420.GI55657@funkthat.com> MIME-Version: 1.0 Content-Type: MULTIPART/MIXED; BOUNDARY="0-806813850-1134773018=:4815" Cc: freebsd-hackers@freebsd.org Subject: Re: Number of kevents registered in kqueue X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Dec 2005 22:43:45 -0000 This message is in MIME format. The first part should be readable text, while the remaining parts are likely unreadable without MIME-aware tools. --0-806813850-1134773018=:4815 Content-Type: TEXT/PLAIN; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: QUOTED-PRINTABLE On Fri, 16 Dec 2005, John-Mark Gurney wrote: > Se=E1n C. Farley wrote this message on Fri, Dec 16, 2005 at 16:09 -0600: >> I may have missed it in the man page, but I am unable to find a way >> to determine how many kevents are currently registered within a >> kqueue. If there is no method for a count, how about a way to find >> if a kqueue is empty or not. Besides tracking what events are still >> within a kqueue, this would make for an easier way to write an event >> loop. Currently, calling kevent() on an empty kqueue will still >> block. > > Why do you need this? What is the point of calling kevent if you > don't have an event to wake it up? Can you give us an example of > where you need to know that there isn't any events in the queue? (I > can't think of one, since using kqueue w/o events is pointless.) I > can't see how tracking the count will let you know which events are > still in the kqueue... (second to last sentence) If you register a number of events to be handled by a single kevent-loop and they are deleted (by kevent() or EV_ONESHOT), it would be nice for a way to see if there are any more kevents registered in the kqueue when deciding to exit the loop (or program) or performing some special operation when all events are gone. >> Also, I recommend that the man page mention that a kqueue may be >> close(2)'d. The only reference that it can be is that the manual >> page says the kqueue() call returns a descriptor. > > I would think that it would need to be documented when you can't close > a descriptor.. Neither pipe nor socketpair documents that close can > be called on them... Good point. It was just a thought for us beginners to kevents. The other calls have a multitude of sources for documentation. Se=E1n --=20 sean-freebsd@farley.org --0-806813850-1134773018=:4815-- From owner-freebsd-hackers@FreeBSD.ORG Fri Dec 16 22:46:25 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 2A74A16A41F for ; Fri, 16 Dec 2005 22:46:25 +0000 (GMT) (envelope-from sean-freebsd@farley.org) Received: from mail.farley.org (farley.org [67.64.95.201]) by mx1.FreeBSD.org (Postfix) with ESMTP id A74CC43D6D for ; Fri, 16 Dec 2005 22:46:24 +0000 (GMT) (envelope-from sean-freebsd@farley.org) Received: from thor.farley.org (thor.farley.org [IPv6:2001:470:1f01:290:1::5]) by mail.farley.org (8.13.1/8.13.1) with ESMTP id jBGMkMfC017522; Fri, 16 Dec 2005 16:46:22 -0600 (CST) (envelope-from sean-freebsd@farley.org) Date: Fri, 16 Dec 2005 16:46:22 -0600 (CST) From: =?ISO-8859-1?Q?Se=E1n_C=2E_Farley?= To: =?UTF-8?B?VsOhY2xhdiBIYWlzbWFu?= In-Reply-To: <43A3416A.2000407@sh.cvut.cz> Message-ID: <20051216164406.G4815@thor.farley.org> References: <20051216155717.W4815@thor.farley.org> <43A3416A.2000407@sh.cvut.cz> MIME-Version: 1.0 Content-Type: MULTIPART/MIXED; BOUNDARY="0-914946570-1134773182=:4815" Cc: freebsd-hackers@freebsd.org Subject: Re: Number of kevents registered in kqueue X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Dec 2005 22:46:25 -0000 This message is in MIME format. The first part should be readable text, while the remaining parts are likely unreadable without MIME-aware tools. --0-914946570-1134773182=:4815 Content-Type: TEXT/PLAIN; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: QUOTED-PRINTABLE On Fri, 16 Dec 2005, V=E1clav Haisman wrote: > Se=E1n C. Farley wrote: >> I may have missed it in the man page, but I am unable to find a way >> to determine how many kevents are currently registered within a >> kqueue. If there is no method for a count, how about a way to find >> if a kqueue is empty or not. Besides tracking what events are still >> within a kqueue, this would make for an easier way to write an event >> loop. Currently, calling kevent() on an empty kqueue will still >> block. > I was working with it recently and my understanding is that if you > want to retrieve any events and not block if there are none then you > should give it zeroed struct timespec. Quote from the man page: > > "If timeout is a NULL pointer, kevent() waits indefinitely. To effect > a poll, the timeout argument should be non-NULL, pointing to a > zero-valued timespec structure." I understand about the timeout. I am looking for different methods to break out of a loop where I want to remain until all events are handled and deleted from the kqueue. Se=E1n --=20 sean-freebsd@farley.org --0-914946570-1134773182=:4815-- From owner-freebsd-hackers@FreeBSD.ORG Fri Dec 16 22:55:50 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id E4A7D16A41F for ; Fri, 16 Dec 2005 22:55:50 +0000 (GMT) (envelope-from sean-freebsd@farley.org) Received: from mail.farley.org (farley.org [67.64.95.201]) by mx1.FreeBSD.org (Postfix) with ESMTP id B294F43D93 for ; Fri, 16 Dec 2005 22:55:38 +0000 (GMT) (envelope-from sean-freebsd@farley.org) Received: from thor.farley.org (thor.farley.org [IPv6:2001:470:1f01:290:1::5]) by mail.farley.org (8.13.1/8.13.1) with ESMTP id jBGMtWq4017633; Fri, 16 Dec 2005 16:55:32 -0600 (CST) (envelope-from sean-freebsd@farley.org) Date: Fri, 16 Dec 2005 16:55:32 -0600 (CST) From: =?ISO-8859-1?Q?Se=E1n_C=2E_Farley?= To: Dan Nelson In-Reply-To: <20051216222045.GF89708@dan.emsphone.com> Message-ID: <20051216165151.E4815@thor.farley.org> References: <20051216155717.W4815@thor.farley.org> <20051216222045.GF89708@dan.emsphone.com> MIME-Version: 1.0 Content-Type: MULTIPART/MIXED; BOUNDARY="0-240785591-1134773732=:4815" Cc: freebsd-hackers@freebsd.org Subject: Re: Number of kevents registered in kqueue X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Dec 2005 22:55:51 -0000 This message is in MIME format. The first part should be readable text, while the remaining parts are likely unreadable without MIME-aware tools. --0-240785591-1134773732=:4815 Content-Type: TEXT/PLAIN; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: QUOTED-PRINTABLE On Fri, 16 Dec 2005, Dan Nelson wrote: > In the last episode (Dec 16), Sen C. Farley said: >> I may have missed it in the man page, but I am unable to find a way >> to determine how many kevents are currently registered within a >> kqueue. If there is no method for a count, how about a way to find >> if a kqueue is empty or not. Besides tracking what events are still >> within a kqueue, this would make for an easier way to write an event >> loop. Currently, calling kevent() on an empty kqueue will still >> block. > > I don't think there's a way currently. What I did in my local tree is > modify kern_kevent so that if the magic number -1 is passed in as > nchanges, it will return the entire queued event list back to the > caller in *eventlist, and return the number of events as the > returncode. Very useful for debugging kqueue-using programs where you > want to compare what you think you're waiting for, and what the kernel > thinks you're waiting for :) Why does this pop in my mind when reading your reply? :) Lt. Saavik: You lied. Spock: I exaggerated. In other words, there does not currently exist a method to does this on a vanilla system. I can deal with that. It still would be a nice feature to have. Se=E1n --=20 sean-freebsd@farley.org --0-240785591-1134773732=:4815-- From owner-freebsd-hackers@FreeBSD.ORG Sat Dec 17 01:24:12 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id E853516A41F for ; Sat, 17 Dec 2005 01:24:11 +0000 (GMT) (envelope-from hselasky@c2i.net) Received: from swip.net (mailfe03.swip.net [212.247.154.65]) by mx1.FreeBSD.org (Postfix) with ESMTP id F189743D45 for ; Sat, 17 Dec 2005 01:24:10 +0000 (GMT) (envelope-from hselasky@c2i.net) X-T2-Posting-ID: Y1QAsIk9O44SO+J/q9KNyQ== X-Cloudmark-Score: 0.000000 [] Received: from mp-217-136-76.daxnet.no ([193.217.136.76] verified) by mailfe03.swip.net (CommuniGate Pro SMTP 5.0.2) with ESMTP id 56031647 for freebsd-hackers@freebsd.org; Sat, 17 Dec 2005 02:24:07 +0100 From: Hans Petter Selasky To: freebsd-hackers@freebsd.org Date: Sat, 17 Dec 2005 02:25:25 +0100 User-Agent: KMail/1.7 References: <200512131936.11640.hselasky@c2i.net> <20051215093059.GL77268@cirb503493.alcatel.com.au> <200512151234.29933.hselasky@c2i.net> In-Reply-To: <200512151234.29933.hselasky@c2i.net> MIME-Version: 1.0 Content-Disposition: inline Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit Message-Id: <200512170225.26237.hselasky@c2i.net> Subject: Re: Standard C-macro scripting X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: hselasky@c2i.net List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 17 Dec 2005 01:24:12 -0000 On Thursday 15 December 2005 12:34, Hans Petter Selasky wrote: > On Thursday 15 December 2005 10:30, Peter Jeremy wrote: > > On Wed, 2005-Dec-14 01:05:45 +0100, Hans Petter Selasky wrote: > > >On Tuesday 13 December 2005 20:48, John Baldwin wrote: > > >> Honestly, I think I've now been scarred for life. :-/ I think that > > >> this stuff would be so obscure that no one else would be able to help > > >> with maintenace. > > Will introducing the word "IF" in the conditional expressions make things more clear? > > > >And how would you solve it? > > > > See above. > > It is just that one has to build up the macro C-scripting language with > some helper macros like NOT/AND/OR/XOR/YES/NO/SWITCH ... to make it easy to > use. It is very amazing, but one can actually compare 32-bit hexadecimal numbers by only defining a handful of macros. One might think that to compare two hexadecimal numbers, ranging from '0' to 'F' inclusivly, one would need to define 256 macros. But no. The secret here is to think binary. Look at the "EQ_2" macro below. It compares two 16-bit hexadecimal numbers. /* * Standard C-macro scripting * ========================== * * Principle: * * A macro true will keep something. * A macro false will discard something. * */ #define YES(...) __VA_ARGS__ /* logical true */ #define NO(...) /* logical false */ /* definition of logical operations */ #define ___AND_(...) #define ___AND_1(...) #define ___AND_11(...) __VA_ARGS__ #define __AND(a,b) ___AND_##a##b #define _AND(a,b) __AND(a,b) #define AND(a,b) _AND(a(1),b(1)) #define ___OR_(...) #define ___OR_1(...) __VA_ARGS__ #define ___OR_11(...) __VA_ARGS__ #define __OR(a,b) ___OR_##a##b #define _OR(a,b) __OR(a,b) #define OR(a,b) _OR(a(1),b(1)) #define ___XOR_(...) #define ___XOR_1(...) __VA_ARGS__ #define ___XOR_11(...) #define __XOR(a,b) ___XOR_##a##b #define _XOR(a,b) __XOR(a,b) #define XOR(a,b) _XOR(a(1),b(1)) #define ___NOT_(...) __VA_ARGS__ #define ___NOT_1(...) #define __NOT(a) ___NOT_##a #define _NOT(a) __NOT(a) #define NOT(a) _NOT(a(1)) /* hexadecimal to binary conversion */ #define HEX_TO_BIN_0 NO, NO, NO, NO #define HEX_TO_BIN_1 NO, NO, NO,YES #define HEX_TO_BIN_2 NO, NO,YES, NO #define HEX_TO_BIN_3 NO, NO,YES,YES #define HEX_TO_BIN_4 NO,YES, NO, NO #define HEX_TO_BIN_5 NO,YES, NO,YES #define HEX_TO_BIN_6 NO,YES,YES, NO #define HEX_TO_BIN_7 NO,YES,YES,YES #define HEX_TO_BIN_8 YES, NO, NO, NO #define HEX_TO_BIN_9 YES, NO, NO,YES #define HEX_TO_BIN_A YES, NO,YES, NO #define HEX_TO_BIN_B YES, NO,YES,YES #define HEX_TO_BIN_C YES,YES, NO, NO #define HEX_TO_BIN_D YES,YES, NO,YES #define HEX_TO_BIN_E YES,YES,YES, NO #define HEX_TO_BIN_F YES,YES,YES,YES /* logical comparison of hexadecimal values */ #define ___EQ_0(a,b,c,d,e,f,g,h) \ NOT(OR(OR(XOR(a,e),XOR(b,f)),OR(XOR(c,g),XOR(d,h)))) #define __EQ_0(...) ___EQ_0(__VA_ARGS__) #define _EQ_0(a,b) __EQ_0(HEX_TO_BIN_##a, HEX_TO_BIN_##b) #define EQ_0(...) _EQ_0(__VA_ARGS__) #define EQ_1(a,b,c,d) AND(EQ_0(a,c),EQ_0(b,d)) #define EQ_2(a,b,c,d,e,f,g,h) AND(EQ_1(a,b,e,f),EQ_1(c,d,g,h)) /* symbolic wrappers for conditional expression */ #define IF(a) a #define IFE(a,b,c) a b NOT(a) c /* examples */ #define VAR_A YES #define VAR_B NO #define VAR_C NO IF(OR(AND(VAR_A,VAR_B),VAR_C)) ( keep it 1 ) IF(OR(OR(VAR_A,VAR_B),VAR_C)) ( keep it 2 ) IFE(YES, ( statement is true ), ( statement is false )) IF(EQ_0(A,B))( 0xA == 0xB ) IF(EQ_1(A,B, A,A))( 0xAB == 0xAA ) IF(EQ_2(A,B,C,0, A,B,C,0))( 0xABC0 == 0xABC0 ) Here is the output from "cpp": # cpp test.h keep it 2 statement is true 0xABC0 == 0xABC0 What more functions would a C-macro scripting language require ? --HPS From owner-freebsd-hackers@FreeBSD.ORG Sat Dec 17 06:34:10 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 3BE3016A433 for ; Sat, 17 Dec 2005 06:34:10 +0000 (GMT) (envelope-from lists-freebsd@silverwraith.com) Received: from gooseberry.silverwraith.com (pear.silverwraith.com [69.12.167.160]) by mx1.FreeBSD.org (Postfix) with ESMTP id EE61C43D5C for ; Sat, 17 Dec 2005 06:34:09 +0000 (GMT) (envelope-from lists-freebsd@silverwraith.com) Received: from avleen by gooseberry.silverwraith.com with local (Exim 4.52 (FreeBSD)) id 1EnVdx-000BFi-HD for freebsd-hackers@freebsd.org; Fri, 16 Dec 2005 22:34:09 -0800 Date: Fri, 16 Dec 2005 22:34:09 -0800 From: Avleen Vig To: freebsd-hackers@freebsd.org Message-ID: <20051217063409.GB19094@silverwraith.com> References: <43A26FFB.9080405@samsco.org> <20051216104022.A20877@cons.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20051216104022.A20877@cons.org> User-Agent: Mutt/1.5.11 Subject: Re: My wish list for 6.1 X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 17 Dec 2005 06:34:10 -0000 On Fri, Dec 16, 2005 at 10:40:22AM -0500, Martin Cracauer wrote: > > 2. SMP kernels for install. Right now we only install a UP kernel, for > > performance reasons. We should be able to package both a UP and SMP > > kernel into the release bits, and have sysinstall install both. It > > should also select the correct one for the target system and make that > > the default on boot. > > If people are concerned about performance, I benchmarked a 6-beta > kernel SMP versus UP on a socket 939 Opteron. If those results are accurate, there's no real reason not to just use an SMP kernel on default install? From owner-freebsd-hackers@FreeBSD.ORG Sat Dec 17 08:01:11 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 7BBB716A41F for ; Sat, 17 Dec 2005 08:01:11 +0000 (GMT) (envelope-from kris@obsecurity.org) Received: from elvis.mu.org (elvis.mu.org [192.203.228.196]) by mx1.FreeBSD.org (Postfix) with ESMTP id D9B0843D4C for ; Sat, 17 Dec 2005 08:01:10 +0000 (GMT) (envelope-from kris@obsecurity.org) Received: from obsecurity.dyndns.org (elvis.mu.org [192.203.228.196]) by elvis.mu.org (Postfix) with ESMTP id B548E1A3C23; Sat, 17 Dec 2005 00:01:10 -0800 (PST) Received: by obsecurity.dyndns.org (Postfix, from userid 1000) id CEF1952B7D; Sat, 17 Dec 2005 03:01:09 -0500 (EST) Date: Sat, 17 Dec 2005 03:01:09 -0500 From: Kris Kennaway To: Avleen Vig Message-ID: <20051217080109.GA31849@xor.obsecurity.org> References: <43A26FFB.9080405@samsco.org> <20051216104022.A20877@cons.org> <20051217063409.GB19094@silverwraith.com> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="liOOAslEiF7prFVr" Content-Disposition: inline In-Reply-To: <20051217063409.GB19094@silverwraith.com> User-Agent: Mutt/1.4.2.1i Cc: freebsd-hackers@freebsd.org Subject: Re: My wish list for 6.1 X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 17 Dec 2005 08:01:11 -0000 --liOOAslEiF7prFVr Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Fri, Dec 16, 2005 at 10:34:09PM -0800, Avleen Vig wrote: > On Fri, Dec 16, 2005 at 10:40:22AM -0500, Martin Cracauer wrote: > > > 2. SMP kernels for install. Right now we only install a UP kernel, = for > > > performance reasons. We should be able to package both a UP and SMP > > > kernel into the release bits, and have sysinstall install both. It= =20 > > > should also select the correct one for the target system and make that > > > the default on boot. > >=20 > > If people are concerned about performance, I benchmarked a 6-beta > > kernel SMP versus UP on a socket 939 Opteron. >=20 > If those results are accurate, there's no real reason not to just use an > SMP kernel on default install? Just because it didn't manifest on this workload, doesn't mean it doesn't on others. I think this is the point :) Kris --liOOAslEiF7prFVr Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.2 (FreeBSD) iD8DBQFDo8XFWry0BWjoQKURAvmjAKCxdm87YsTaP/f+8eYBOEbkI1ubIgCfdtQv zjw+YGfzt/ca6AOQ5goSWx0= =QjG8 -----END PGP SIGNATURE----- --liOOAslEiF7prFVr-- From owner-freebsd-hackers@FreeBSD.ORG Sat Dec 17 08:27:29 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 8EDC916A41F for ; Sat, 17 Dec 2005 08:27:29 +0000 (GMT) (envelope-from guomingyan@gmail.com) Received: from xproxy.gmail.com (xproxy.gmail.com [66.249.82.199]) by mx1.FreeBSD.org (Postfix) with ESMTP id DFBA243D49 for ; Sat, 17 Dec 2005 08:27:28 +0000 (GMT) (envelope-from guomingyan@gmail.com) Received: by xproxy.gmail.com with SMTP id t12so631349wxc for ; Sat, 17 Dec 2005 00:27:28 -0800 (PST) DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=beta; d=gmail.com; h=received:message-id:date:from:to:subject:mime-version:content-type; b=qSis4eXfybJlUNvZAm5IwxYeQn+4aviKla8VAHBNpc13xE1q6tQzRsnd6ctbodW94zlhfH0ebaskrbheRnM5akyZoSQMn74ZBeSbbNQ+NT3c3pCwZ+LJWkXo159q0c+Y0nb/3Bd5WlMj+06U8MKiff9qUCX8ocwz20+hSC1pgn8= Received: by 10.70.16.15 with SMTP id 15mr2091140wxp; Sat, 17 Dec 2005 00:27:28 -0800 (PST) Received: by 10.70.39.18 with HTTP; Sat, 17 Dec 2005 00:27:28 -0800 (PST) Message-ID: <1fa17f810512170027h58ccadbcq9f8d3187f35a2ddd@mail.gmail.com> Date: Sat, 17 Dec 2005 16:27:28 +0800 From: prime To: freebsd-hackers@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Content-Disposition: inline X-Content-Filtered-By: Mailman/MimeDel 2.1.5 Subject: Puzzled about turnstile's lock X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 17 Dec 2005 08:27:29 -0000 Hi hackers, I want to understand the current implementation of turnstile,and meet some questions about its locks' logicality. turnstile's ``ts_blocked" field is protected by both ``td_contested" lock and its turnstile_chain lock, but I think its turnstile_chain lock is enough,because we allways get the turnstile_chain lock before our manipulation on ``ts_blocked". If td_contested lock were needed ,reading ts_blocked is not protected by td_contested lock,in the kernel source, why? Thanks. -- Three passions, simple but overwhelmingly strong, have governed my life: the longing for love, the search for knowledge, and unbearable pity for the suffering of mankind. ---------Bertrand Russell From owner-freebsd-hackers@FreeBSD.ORG Sat Dec 17 08:50:36 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 586DC16A41F for ; Sat, 17 Dec 2005 08:50:36 +0000 (GMT) (envelope-from slackwarewolf@comcast.net) Received: from rwcrmhc12.comcast.net (rwcrmhc12.comcast.net [216.148.227.85]) by mx1.FreeBSD.org (Postfix) with ESMTP id 0E16443D46 for ; Sat, 17 Dec 2005 08:50:35 +0000 (GMT) (envelope-from slackwarewolf@comcast.net) Received: from hp (pcp0011279654pcs.pthurn01.mi.comcast.net[69.246.87.201]) by comcast.net (rwcrmhc12) with ESMTP id <20051217085035014008g88te>; Sat, 17 Dec 2005 08:50:35 +0000 Date: Sat, 17 Dec 2005 08:55:00 +0000 From: Allen To: freebsd-hackers@freebsd.org References: <43A26FFB.9080405@samsco.org> <20051216104022.A20877@cons.org> <20051217063409.GB19094@silverwraith.com> In-Reply-To: <20051217063409.GB19094@silverwraith.com> (from lists-freebsd@silverwraith.com on Sat Dec 17 01:34:09 2005) X-Mailer: Balsa 2.2.6 Message-Id: <1134809700l.24187l.0l@HP> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii; DelSp=Yes; Format=Flowed Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Subject: Re: My wish list for 6.1 X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 17 Dec 2005 08:50:36 -0000 On 12/17/2005 01:34:09 AM, Avleen Vig wrote: > On Fri, Dec 16, 2005 at 10:40:22AM -0500, Martin Cracauer wrote: > > > 2. SMP kernels for install. Right now we only install a UP > kernel, for > > > performance reasons. We should be able to package both a UP and > SMP > > > kernel into the release bits, and have sysinstall install both. > It > > > should also select the correct one for the target system and make > that > > > the default on boot. > > > > If people are concerned about performance, I benchmarked a 6-beta > > kernel SMP versus UP on a socket 939 Opteron. Must be great having boxes like that ;) You know what I'd like to see =20 in the next Free BSD? A way to update security fixes without having to =20 play with any source, or having to touch make world. I know the speed =20 and so on makes some people like this, but I personally try getting =20 people who use Windows to switch to another OS or at least show them =20 something else exists, and it's hard to make someone want to use Free =20 BSD when installing patches can be such a timely manner. I know about the port tool, but what I'd love to have is a tool you =20 could run from the CLI or the GUI that would check for updates, and =20 then ask which ones to install, similar to Swaret on Slackware. This =20 way people can do the usual updates if they want, and people like me =20 can show people BSD and how great it is. > If those results are accurate, there's no real reason not to just use > an > SMP kernel on default install? > _______________________________________________ > freebsd-hackers@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/freebsd-hackers > To unsubscribe, send any mail to "freebsd-hackers-=20 > unsubscribe@freebsd.org" From owner-freebsd-hackers@FreeBSD.ORG Sat Dec 17 08:55:51 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 8B5CF16A41F for ; Sat, 17 Dec 2005 08:55:51 +0000 (GMT) (envelope-from chris@haakonia.hitnet.rwth-aachen.de) Received: from ms-dienst.rz.rwth-aachen.de (ms-2.rz.RWTH-Aachen.DE [134.130.3.131]) by mx1.FreeBSD.org (Postfix) with ESMTP id 6684343D5A for ; Sat, 17 Dec 2005 08:55:50 +0000 (GMT) (envelope-from chris@haakonia.hitnet.rwth-aachen.de) Received: from r220-1 (r220-1.rz.RWTH-Aachen.DE [134.130.3.31]) by ms-dienst.rz.rwth-aachen.de (iPlanet Messaging Server 5.2 Patch 2 (built Jul 14 2004)) with ESMTP id <0IRM004LHWT0G1@ms-dienst.rz.rwth-aachen.de> for freebsd-hackers@freebsd.org; Sat, 17 Dec 2005 09:55:49 +0100 (MET) Received: from relay.rwth-aachen.de ([134.130.3.1]) by r220-1 (MailMonitor for SMTP v1.2.2 ) ; Sat, 17 Dec 2005 09:55:48 +0100 (MET) Received: from bigboss.hitnet.rwth-aachen.de (bigspace.hitnet.RWTH-Aachen.DE [137.226.181.2]) by relay.rwth-aachen.de (8.13.3/8.13.3/1) with ESMTP id jBH8tlpf006521; Sat, 17 Dec 2005 09:55:47 +0100 (MET) Received: from lorien.hitnet.rwth-aachen.de ([137.226.181.92] helo=haakonia.hitnet.rwth-aachen.de) by bigboss.hitnet.rwth-aachen.de with esmtps (TLS-1.0:DHE_RSA_AES_256_CBC_SHA:32) (Exim 4.50) id 1EnXr1-0007Yk-TD; Sat, 17 Dec 2005 09:55:47 +0100 Received: by haakonia.hitnet.rwth-aachen.de (Postfix, from userid 1001) id 98FCB3F412; Sat, 17 Dec 2005 09:55:17 +0100 (CET) Date: Sat, 17 Dec 2005 09:55:17 +0100 From: Christian Brueffer In-reply-to: <1134809700l.24187l.0l@HP> To: Allen Message-id: <20051217085517.GA1132@unixpages.org> MIME-version: 1.0 Content-type: multipart/signed; boundary=Nq2Wo0NMKNjxTN9z; protocol="application/pgp-signature"; micalg=pgp-sha1 Content-disposition: inline User-Agent: Mutt/1.5.11 X-Operating-System: FreeBSD 6.0-STABLE X-PGP-Key: http://people.FreeBSD.org/~brueffer/brueffer.key.asc X-PGP-Fingerprint: A5C8 2099 19FF AACA F41B B29B 6C76 178C A0ED 982D References: <43A26FFB.9080405@samsco.org> <20051216104022.A20877@cons.org> <20051217063409.GB19094@silverwraith.com> <1134809700l.24187l.0l@HP> Cc: freebsd-hackers@freebsd.org Subject: Re: My wish list for 6.1 X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 17 Dec 2005 08:55:51 -0000 --Nq2Wo0NMKNjxTN9z Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Sat, Dec 17, 2005 at 08:55:00AM +0000, Allen wrote: > On 12/17/2005 01:34:09 AM, Avleen Vig wrote: > >On Fri, Dec 16, 2005 at 10:40:22AM -0500, Martin Cracauer wrote: > >> > 2. SMP kernels for install. Right now we only install a UP > >kernel, for > >> > performance reasons. We should be able to package both a UP and > >SMP > >> > kernel into the release bits, and have sysinstall install both. > >It > >> > should also select the correct one for the target system and make > >that > >> > the default on boot. > >> > >> If people are concerned about performance, I benchmarked a 6-beta > >> kernel SMP versus UP on a socket 939 Opteron. >=20 > Must be great having boxes like that ;) You know what I'd like to see =20 > in the next Free BSD? A way to update security fixes without having to = =20 > play with any source, or having to touch make world. I know the speed =20 > and so on makes some people like this, but I personally try getting =20 > people who use Windows to switch to another OS or at least show them =20 > something else exists, and it's hard to make someone want to use Free =20 > BSD when installing patches can be such a timely manner. >=20 > I know about the port tool, but what I'd love to have is a tool you =20 > could run from the CLI or the GUI that would check for updates, and =20 > then ask which ones to install, similar to Swaret on Slackware. This =20 > way people can do the usual updates if they want, and people like me =20 > can show people BSD and how great it is. >=20 You probably haven't seen ports/security/freebsd-update yet. See http://www.daemonology.net/freebsd-update/ for more information. - Christian --=20 Christian Brueffer chris@unixpages.org brueffer@FreeBSD.org GPG Key: http://people.freebsd.org/~brueffer/brueffer.key.asc GPG Fingerprint: A5C8 2099 19FF AACA F41B B29B 6C76 178C A0ED 982D --Nq2Wo0NMKNjxTN9z Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.2 (FreeBSD) iD8DBQFDo9J1bHYXjKDtmC0RAlCCAJ0WFDDfncTVz39MBxhPKyRBBdU0HwCfV/D9 Q/MCw7BL6Zu0D1PkZaJ9Zh8= =gO8v -----END PGP SIGNATURE----- --Nq2Wo0NMKNjxTN9z-- From owner-freebsd-hackers@FreeBSD.ORG Sat Dec 17 10:32:56 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 0B31316A41F for ; Sat, 17 Dec 2005 10:32:56 +0000 (GMT) (envelope-from slackwarewolf@comcast.net) Received: from rwcrmhc11.comcast.net (rwcrmhc11.comcast.net [216.148.227.151]) by mx1.FreeBSD.org (Postfix) with ESMTP id A677443D49 for ; Sat, 17 Dec 2005 10:32:55 +0000 (GMT) (envelope-from slackwarewolf@comcast.net) Received: from [192.168.0.100] (pcp0011279654pcs.pthurn01.mi.comcast.net[69.246.87.201]) by comcast.net (rwcrmhc11) with ESMTP id <2005121710325501300c6fbje>; Sat, 17 Dec 2005 10:32:55 +0000 From: Allen To: freebsd-hackers@freebsd.org Date: Sat, 17 Dec 2005 05:37:20 -0500 User-Agent: KMail/1.8 References: <43A26FFB.9080405@samsco.org> <1134809700l.24187l.0l@HP> <20051217085517.GA1132@unixpages.org> In-Reply-To: <20051217085517.GA1132@unixpages.org> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit Content-Disposition: inline Message-Id: <200512170537.20791.slackwarewolf@comcast.net> Subject: Re: My wish list for 6.1 X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 17 Dec 2005 10:32:56 -0000 On Saturday 17 December 2005 03:55, Christian Brueffer wrote: > On Sat, Dec 17, 2005 at 08:55:00AM +0000, Allen wrote: > > On 12/17/2005 01:34:09 AM, Avleen Vig wrote: > > >On Fri, Dec 16, 2005 at 10:40:22AM -0500, Martin Cracauer wrote: > > >> > 2. SMP kernels for install. Right now we only install a UP > > > > > >kernel, for > > > > > >> > performance reasons. We should be able to package both a UP and > > > > > >SMP > > > > > >> > kernel into the release bits, and have sysinstall install both. > > > > > >It > > > > > >> > should also select the correct one for the target system and make > > > > > >that > > > > > >> > the default on boot. > > >> > > >> If people are concerned about performance, I benchmarked a 6-beta > > >> kernel SMP versus UP on a socket 939 Opteron. > > > > Must be great having boxes like that ;) You know what I'd like to see > > in the next Free BSD? A way to update security fixes without having to > > play with any source, or having to touch make world. I know the speed > > and so on makes some people like this, but I personally try getting > > people who use Windows to switch to another OS or at least show them > > something else exists, and it's hard to make someone want to use Free > > BSD when installing patches can be such a timely manner. > > > > I know about the port tool, but what I'd love to have is a tool you > > could run from the CLI or the GUI that would check for updates, and > > then ask which ones to install, similar to Swaret on Slackware. This > > way people can do the usual updates if they want, and people like me > > can show people BSD and how great it is. > > You probably haven't seen ports/security/freebsd-update yet. Actually, I've seen that and it does come close... But it didn't seem to like updating the Kernel or anything similar to the base system in the time I spent with it. Free BSD has probably one of the best methods of installing new packages with pkg_add, and pkg_add -r for grabbing them off the internet but for updates it could use some work. It won't stop me from buying Free BSD things, but it does make showing new computer users the OS a but harder. OT: If anyone wants a person to couge, the Free BSD boxers are VERY high quality and, it must be said, a pair of boxers any BOFH would wear. They look great with my Free BSD TeeShirt and Laptop covered in BSD stickers. :) > - Christian -Allen From owner-freebsd-hackers@FreeBSD.ORG Sat Dec 17 12:20:10 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 9498716A41F for ; Sat, 17 Dec 2005 12:20:10 +0000 (GMT) (envelope-from hampi@rootshell.be) Received: from mail20.bluewin.ch (mail20.bluewin.ch [195.186.19.65]) by mx1.FreeBSD.org (Postfix) with ESMTP id 20B7643D53 for ; Sat, 17 Dec 2005 12:20:09 +0000 (GMT) (envelope-from hampi@rootshell.be) Received: from twelvegates.homeip.net (83.79.176.207) by mail20.bluewin.ch (Bluewin 7.2.069.1) id 43926165002E47A1 for freebsd-hackers@freebsd.org; Sat, 17 Dec 2005 12:20:08 +0000 Received: from goofy.here (localhost.here [127.0.0.1]) by twelvegates.homeip.net (8.13.4/8.13.3) with ESMTP id jBHCK7mw002776 for ; Sat, 17 Dec 2005 13:20:07 +0100 (CET) (envelope-from hampi@rootshell.be) Received: (from idefix@localhost) by goofy.here (8.13.4/8.13.1/Submit) id jBHCK69D002775 for freebsd-hackers@freebsd.org; Sat, 17 Dec 2005 13:20:06 +0100 (CET) (envelope-from hampi@rootshell.be) X-Authentication-Warning: goofy.here: idefix set sender to hampi@rootshell.be using -f Date: Sat, 17 Dec 2005 13:20:06 +0100 From: Hanspeter Roth To: freebsd-hackers@freebsd.org Message-ID: <20051217122006.GA2758@twelvegates.homeip.net> Mail-Followup-To: freebsd-hackers@freebsd.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.4.2.1i Subject: accessing NetBSD filesystem X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: freebsd-hackers@freebsd.org List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 17 Dec 2005 12:20:10 -0000 Hello, is it possible to access Fast Filesystems from a NetBSD installation on the same disk? -Hanspeter From owner-freebsd-hackers@FreeBSD.ORG Sat Dec 17 13:43:27 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id ADEBB16A41F for ; Sat, 17 Dec 2005 13:43:27 +0000 (GMT) (envelope-from joerg@britannica.bec.de) Received: from hydra.bec.de (www.ostsee-abc.de [62.206.222.50]) by mx1.FreeBSD.org (Postfix) with ESMTP id 239F743D62 for ; Sat, 17 Dec 2005 13:43:27 +0000 (GMT) (envelope-from joerg@britannica.bec.de) Received: from britannica.bec.de (unknown [139.30.252.72]) by hydra.bec.de (Postfix) with ESMTP id A2E3B35707 for ; Sat, 17 Dec 2005 14:43:23 +0100 (CET) Received: by britannica.bec.de (Postfix, from userid 1000) id 915D36CFB3; Sat, 17 Dec 2005 14:42:58 +0100 (CET) Date: Sat, 17 Dec 2005 14:42:58 +0100 From: joerg@britannica.bec.de To: freebsd-hackers@freebsd.org Message-ID: <20051217134258.GC1706@britannica.bec.de> Mail-Followup-To: freebsd-hackers@freebsd.org References: <20051217122006.GA2758@twelvegates.homeip.net> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20051217122006.GA2758@twelvegates.homeip.net> User-Agent: Mutt/1.5.11 Subject: Re: accessing NetBSD filesystem X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 17 Dec 2005 13:43:27 -0000 On Sat, Dec 17, 2005 at 01:20:06PM +0100, Hanspeter Roth wrote: > > is it possible to access Fast Filesystems from a NetBSD installation > on the same disk? As long as they have the same Endianess, yes. You might get some warnings about the disklabel, otherwise it should be fine. Joerg From owner-freebsd-hackers@FreeBSD.ORG Sat Dec 17 14:31:09 2005 Return-Path: X-Original-To: freebsd-hackers@FreeBSD.ORG Delivered-To: freebsd-hackers@FreeBSD.ORG Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 6297D16A41F for ; Sat, 17 Dec 2005 14:31:09 +0000 (GMT) (envelope-from pjd@garage.freebsd.pl) Received: from mail.garage.freebsd.pl (arm132.internetdsl.tpnet.pl [83.17.198.132]) by mx1.FreeBSD.org (Postfix) with ESMTP id 4865643D45 for ; Sat, 17 Dec 2005 14:31:07 +0000 (GMT) (envelope-from pjd@garage.freebsd.pl) Received: by mail.garage.freebsd.pl (Postfix, from userid 65534) id C443052C38; Sat, 17 Dec 2005 15:31:05 +0100 (CET) Received: from localhost (dla47.neoplus.adsl.tpnet.pl [83.24.30.47]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by mail.garage.freebsd.pl (Postfix) with ESMTP id 8BE1551B27; Sat, 17 Dec 2005 15:30:57 +0100 (CET) Date: Sat, 17 Dec 2005 15:30:00 +0100 From: Pawel Jakub Dawidek To: Vitaliy Ovsyannikov Message-ID: <20051217143000.GA80713@garage.freebsd.pl> References: <917449047.20051216172711@kr.ru> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="gKMricLos+KVdGMg" Content-Disposition: inline In-Reply-To: <917449047.20051216172711@kr.ru> X-PGP-Key-URL: http://people.freebsd.org/~pjd/pjd.asc X-OS: FreeBSD 7.0-CURRENT i386 User-Agent: mutt-ng/devel-r535 (FreeBSD) X-Spam-Checker-Version: SpamAssassin 3.0.4 (2005-06-05) on mail.garage.freebsd.pl X-Spam-Level: X-Spam-Status: No, score=-0.5 required=3.0 tests=BAYES_00,RCVD_IN_NJABL_DUL, RCVD_IN_SORBS_DUL autolearn=no version=3.0.4 Cc: freebsd-hackers@FreeBSD.ORG Subject: Re: unable to build geom_gate X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 17 Dec 2005 14:31:09 -0000 --gKMricLos+KVdGMg Content-Type: text/plain; charset=iso-8859-2 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Fri, Dec 16, 2005 at 05:27:11PM +0700, Vitaliy Ovsyannikov wrote: +> Hello, freebsd-hackers. +>=20 +> Please, look at the output and help if you can: +>=20 +> # tar -yxf geom_gate.tbz +> # cd geom_gate +> # make [...] Why don't you just use ggate from the base system? --=20 Pawel Jakub Dawidek http://www.wheel.pl pjd@FreeBSD.org http://www.FreeBSD.org FreeBSD committer Am I Evil? Yes, I Am! --gKMricLos+KVdGMg Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.2 (FreeBSD) iD8DBQFDpCDoForvXbEpPzQRAjgFAJ9sxOgdMEK5zWnNZGRGEnvMTkRnuQCg9lIu BRNffkPnTsfhr55ybb3Ej0E= =AguR -----END PGP SIGNATURE----- --gKMricLos+KVdGMg-- From owner-freebsd-hackers@FreeBSD.ORG Sat Dec 17 17:10:32 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 63FFF16A41F for ; Sat, 17 Dec 2005 17:10:32 +0000 (GMT) (envelope-from hampi@rootshell.be) Received: from mail22.bluewin.ch (mail22.bluewin.ch [195.186.19.66]) by mx1.FreeBSD.org (Postfix) with ESMTP id B63DD43D46 for ; Sat, 17 Dec 2005 17:10:31 +0000 (GMT) (envelope-from hampi@rootshell.be) Received: from twelvegates.homeip.net (81.63.49.119) by mail22.bluewin.ch (Bluewin 7.2.069.1) id 43926166002F47F9 for freebsd-hackers@freebsd.org; Sat, 17 Dec 2005 17:10:30 +0000 Received: from gicco.here (localhost [127.0.0.1]) by twelvegates.homeip.net (8.13.4/8.13.1) with ESMTP id jBHHATRg080309 for ; Sat, 17 Dec 2005 18:10:29 +0100 (CET) (envelope-from hampi@rootshell.be) Received: (from idefix@localhost) by gicco.here (8.13.4/8.12.11/Submit) id jBHHAT3H080308 for freebsd-hackers@freebsd.org; Sat, 17 Dec 2005 18:10:29 +0100 (CET) (envelope-from hampi@rootshell.be) X-Authentication-Warning: gicco.here: idefix set sender to hampi@rootshell.be using -f Date: Sat, 17 Dec 2005 18:10:29 +0100 From: Hanspeter Roth To: freebsd-hackers@freebsd.org Message-ID: <20051217171029.GB14214@twelvegates.homeip.net> Mail-Followup-To: freebsd-hackers@freebsd.org References: <20051217122006.GA2758@twelvegates.homeip.net> <20051217134258.GC1706@britannica.bec.de> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20051217134258.GC1706@britannica.bec.de> User-Agent: Mutt/1.4.2.1i Subject: Re: accessing NetBSD filesystem X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: freebsd-hackers@freebsd.org List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 17 Dec 2005 17:10:32 -0000 On Dec 17 at 14:42, joerg@britannica.bec.de spoke: > On Sat, Dec 17, 2005 at 01:20:06PM +0100, Hanspeter Roth wrote: > > > > is it possible to access Fast Filesystems from a NetBSD installation > > on the same disk? > > As long as they have the same Endianess, yes. You might get some > warnings about the disklabel, otherwise it should be fine. How can one activate the Fast Filesystem support? Is there a kernel module to load? Shouldn't the respective entries /dev/ad0s4* appear provided the NetBSD installation is in /dev/ad0s4? -Hanspeter From owner-freebsd-hackers@FreeBSD.ORG Sat Dec 17 18:57:04 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 088C116A41F for ; Sat, 17 Dec 2005 18:57:04 +0000 (GMT) (envelope-from tataz@tataz.chchile.org) Received: from smtp2-g19.free.fr (smtp2-g19.free.fr [212.27.42.28]) by mx1.FreeBSD.org (Postfix) with ESMTP id CBE5043D49 for ; Sat, 17 Dec 2005 18:57:00 +0000 (GMT) (envelope-from tataz@tataz.chchile.org) Received: from tatooine.tataz.chchile.org (vol75-8-82-233-239-98.fbx.proxad.net [82.233.239.98]) by smtp2-g19.free.fr (Postfix) with ESMTP id D7A1A65BC9; Sat, 17 Dec 2005 19:56:58 +0100 (CET) Received: from obiwan.tataz.chchile.org (unknown [192.168.1.25]) by tatooine.tataz.chchile.org (Postfix) with ESMTP id 49DC09B6E7; Sat, 17 Dec 2005 18:56:34 +0000 (UTC) Received: by obiwan.tataz.chchile.org (Postfix, from userid 1000) id 20556405A; Sat, 17 Dec 2005 19:56:34 +0100 (CET) Date: Sat, 17 Dec 2005 19:56:33 +0100 From: Jeremie Le Hen To: Daniel Gerzo Message-ID: <20051217185633.GZ3512@obiwan.tataz.chchile.org> References: <20051212211630.GB93277@dev.codelounge.co.za> <000801c5ff63$fb717890$0201a8c0@oxy> <1103711167.20051212234618@rulez.sk> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1103711167.20051212234618@rulez.sk> User-Agent: Mutt/1.5.11 Cc: freebsd-hackers@freebsd.org, OxY Subject: Re: [fbsd] Re[2]: jailctl with multiple ip per jail X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 17 Dec 2005 18:57:04 -0000 Hi, Oxy, Daniel, > > yes, i know that, but what i want is to use an existing jail > > with 2ip > > not to create additional jails.. > > although i dont know if it really works, but here is what i was able > to google (check those mijail patches) :) place your questions on pjd@ > > http://garage.freebsd.pl/ pjd's mijail patce are a little bit old as they are against 5.0-CURRENT. ISTR it is usable but there were still minor problems with it which prevented the patch from being commited, but I can't pull out the details from my memory. However checking the archives would answer you for sure. Depending on what you really want to do, you may however workaround this limitation using some NAT rules. Best regards, -- Jeremie Le Hen < jeremie at le-hen dot org >< ttz at chchile dot org > From owner-freebsd-hackers@FreeBSD.ORG Sat Dec 17 19:08:06 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 4FCC616A41F for ; Sat, 17 Dec 2005 19:08:06 +0000 (GMT) (envelope-from mat@mat.cc) Received: from plouf.absolight.net (plouf.absolight.net [193.30.224.136]) by mx1.FreeBSD.org (Postfix) with ESMTP id 8FDBE43D6D for ; Sat, 17 Dec 2005 19:08:02 +0000 (GMT) (envelope-from mat@mat.cc) Received: from [192.168.1.5] (rke75-1-87-88-108-35.dsl.club-internet.fr [87.88.108.35]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client did not present a certificate) by plouf.absolight.net (Postfix) with ESMTP id 9D8874A9BB9 for ; Sat, 17 Dec 2005 20:08:00 +0100 (CET) Date: Sat, 17 Dec 2005 20:07:59 +0100 From: Mathieu Arnold To: freebsd-hackers@freebsd.org Message-ID: In-Reply-To: <20051217171029.GB14214@twelvegates.homeip.net> References: <20051217122006.GA2758@twelvegates.homeip.net> <20051217134258.GC1706@britannica.bec.de> <20051217171029.GB14214@twelvegates.homeip.net> X-Mailer: Mulberry/4.0.4 (Win32) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Content-Disposition: inline X-Mailman-Approved-At: Sat, 17 Dec 2005 19:37:15 +0000 Subject: Re: accessing NetBSD filesystem X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 17 Dec 2005 19:08:06 -0000 +-Le 17/12/2005 18:10 +0100, Hanspeter Roth a dit : | On Dec 17 at 14:42, joerg@britannica.bec.de spoke: | |> On Sat, Dec 17, 2005 at 01:20:06PM +0100, Hanspeter Roth wrote: |> > |> > is it possible to access Fast Filesystems from a NetBSD installation |> > on the same disk? |> |> As long as they have the same Endianess, yes. You might get some |> warnings about the disklabel, otherwise it should be fine. | | How can one activate the Fast Filesystem support? Is there a kernel | module to load? Shouldn't the respective entries /dev/ad0s4* appear | provided the NetBSD installation is in /dev/ad0s4? FFS == UFS. -- Mathieu Arnold From owner-freebsd-hackers@FreeBSD.ORG Sat Dec 17 20:07:35 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 5EA4316A425 for ; Sat, 17 Dec 2005 20:07:35 +0000 (GMT) (envelope-from asmrookie@gmail.com) Received: from zproxy.gmail.com (zproxy.gmail.com [64.233.162.202]) by mx1.FreeBSD.org (Postfix) with ESMTP id AD94243D95 for ; Sat, 17 Dec 2005 20:07:03 +0000 (GMT) (envelope-from asmrookie@gmail.com) Received: by zproxy.gmail.com with SMTP id z6so943710nzd for ; Sat, 17 Dec 2005 12:07:03 -0800 (PST) DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=beta; d=gmail.com; h=received:message-id:date:from:reply-to:to:subject:cc:in-reply-to:mime-version:content-type:references; b=sqtH9ZAaWnjFFRyaJ24K/a4of8J8ItQynXcwaolPvz8eASUlW6ZHxHhisi2CK+Uy/TQyuRe80dCLgyB6YWI3kUkRjriWF/yrFH4BqKVBSkOzQx7KIQRIUbvryxpMZa/UzGdQINyclUJVFp7/7qm4S9u48DxUtnnqIlggFqzsCRM= Received: by 10.37.18.66 with SMTP id v66mr4340550nzi; Sat, 17 Dec 2005 12:07:03 -0800 (PST) Received: by 10.36.43.18 with HTTP; Sat, 17 Dec 2005 12:07:02 -0800 (PST) Message-ID: <3bbf2fe10512171207n41c9308dm@mail.gmail.com> Date: Sat, 17 Dec 2005 21:07:02 +0100 From: rookie To: prime In-Reply-To: <1fa17f810512170027h58ccadbcq9f8d3187f35a2ddd@mail.gmail.com> MIME-Version: 1.0 References: <1fa17f810512170027h58ccadbcq9f8d3187f35a2ddd@mail.gmail.com> Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Content-Disposition: inline X-Content-Filtered-By: Mailman/MimeDel 2.1.5 Cc: freebsd-hackers@freebsd.org Subject: Re: Puzzled about turnstile's lock X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: rookie@gufi.org List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 17 Dec 2005 20:07:35 -0000 > Hi hackers, > I want to understand the current implementation of > turnstile,and meet some questions about its locks' logicality. [snip] It's used to lock td_contested member of struct thread structure and all issues linked to it (as you can see in the source tree). It seems used in a clean way. Attilio turnstile's ``ts_blocked" field is protected by both > ``td_contested" lock and its turnstile_chain lock, but > I think its turnstile_chain lock is enough,because we > allways get the turnstile_chain lock before our manipulation > on ``ts_blocked". > If td_contested lock were needed ,reading ts_blocked is > not protected by td_contested lock,in the kernel source, why? > > Thanks. > -- > Three passions, simple but overwhelmingly strong, have governed my life: > the longing for love, the search for knowledge, and unbearable pity for > the suffering of mankind. > ---------Bertrand Russell > _______________________________________________ > freebsd-hackers@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/freebsd-hackers > To unsubscribe, send any mail to "freebsd-hackers-unsubscribe@freebsd.org= " > -- Peace can only be achieved by understanding - A. Einstein From owner-freebsd-hackers@FreeBSD.ORG Sat Dec 17 20:44:19 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 2FAF416A41F for ; Sat, 17 Dec 2005 20:44:19 +0000 (GMT) (envelope-from hampi@rootshell.be) Received: from mail22.bluewin.ch (mail22.bluewin.ch [195.186.19.66]) by mx1.FreeBSD.org (Postfix) with ESMTP id A528443D45 for ; Sat, 17 Dec 2005 20:44:18 +0000 (GMT) (envelope-from hampi@rootshell.be) Received: from twelvegates.homeip.net (81.63.49.119) by mail22.bluewin.ch (Bluewin 7.2.069.1) id 43926166002FBCE2 for freebsd-hackers@freebsd.org; Sat, 17 Dec 2005 20:44:17 +0000 Received: from gicco.here (localhost [127.0.0.1]) by twelvegates.homeip.net (8.13.4/8.13.1) with ESMTP id jBHKiH6n053932 for ; Sat, 17 Dec 2005 21:44:17 +0100 (CET) (envelope-from hampi@rootshell.be) Received: (from idefix@localhost) by gicco.here (8.13.4/8.12.11/Submit) id jBHKiH8R053931 for freebsd-hackers@freebsd.org; Sat, 17 Dec 2005 21:44:17 +0100 (CET) (envelope-from hampi@rootshell.be) X-Authentication-Warning: gicco.here: idefix set sender to hampi@rootshell.be using -f Date: Sat, 17 Dec 2005 21:44:17 +0100 From: Hanspeter Roth To: freebsd-hackers@freebsd.org Message-ID: <20051217204417.GA27466@twelvegates.homeip.net> Mail-Followup-To: freebsd-hackers@freebsd.org References: <20051217122006.GA2758@twelvegates.homeip.net> <20051217134258.GC1706@britannica.bec.de> <20051217171029.GB14214@twelvegates.homeip.net> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.4.2.1i Subject: Re: accessing NetBSD filesystem X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: freebsd-hackers@freebsd.org List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 17 Dec 2005 20:44:19 -0000 On Dec 17 at 20:07, Mathieu Arnold spoke: > +-Le 17/12/2005 18:10 +0100, Hanspeter Roth a dit : > | On Dec 17 at 14:42, joerg@britannica.bec.de spoke: > | > |> On Sat, Dec 17, 2005 at 01:20:06PM +0100, Hanspeter Roth wrote: > |> > > |> > is it possible to access Fast Filesystems from a NetBSD installation > |> > on the same disk? > |> > |> As long as they have the same Endianess, yes. You might get some > |> warnings about the disklabel, otherwise it should be fine. > | > | How can one activate the Fast Filesystem support? Is there a kernel > | module to load? Shouldn't the respective entries /dev/ad0s4* appear > | provided the NetBSD installation is in /dev/ad0s4? > > FFS == UFS. Fdisk shows sysid 165 (0xa5) for partition 3. This is where FreeBSD is installed. And Fdisk shows sysid 169 (0xa9) for partition 4. This is where NetBSD is installed. In /dev there are ad0s3 and ad0s3[a-g] but there is only a ad0s4. So how can filesystems of my NetBSD in ad0s4 be accessed? -Hanspeter