From owner-freebsd-hackers@FreeBSD.ORG Sun Feb 22 05:00:29 2004 Return-Path: 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 7F67516A4CE for ; Sun, 22 Feb 2004 05:00:29 -0800 (PST) Received: from smtp03.wxs.nl (smtp03.wxs.nl [195.121.6.37]) by mx1.FreeBSD.org (Postfix) with ESMTP id 5666E43D1D for ; Sun, 22 Feb 2004 05:00:29 -0800 (PST) (envelope-from freebsd@akruijff.dds.nl) Received: from kruij557.speed.planet.nl (ipd50a97ba.speed.planet.nl [213.10.151.186]) by smtp03.wxs.nl (iPlanet Messaging Server 5.2 HotFix 1.14 (built Mar 18 2003)) with ESMTP id <0HTH00CC1LDXAE@smtp03.wxs.nl> for hackers@freebsd.org; Sun, 22 Feb 2004 13:58:45 +0100 (MET) Received: from alex.lan (localhost [127.0.0.1]) by kruij557.speed.planet.nl (8.12.10/8.12.10) with ESMTP id i1MCxrHd067637; Sun, 22 Feb 2004 13:59:53 +0100 Received: (from akruijff@localhost) by alex.lan (8.12.10/8.12.10/Submit) id i1MCxqEG067636; Sun, 22 Feb 2004 13:59:52 +0100 Content-return: prohibited Date: Sun, 22 Feb 2004 13:59:52 +0100 From: Alex de Kruijff In-reply-to: <4A1C3989-6133-11D8-91F3-000A9576014E@cam.ac.uk> To: Bin Ren Message-id: <20040222125952.GD892@alex.lan> MIME-version: 1.0 Content-type: text/plain; charset=us-ascii Content-transfer-encoding: 7BIT Content-disposition: inline User-Agent: Mutt/1.4.2.1i References: <4A1C3989-6133-11D8-91F3-000A9576014E@cam.ac.uk> X-Authentication-warning: alex.lan: akruijff set sender to freebsd@akruijff.dds.nl using -f cc: Hackers FreeBSD Subject: Re: pin a subsystem to a CPU X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 22 Feb 2004 13:00:29 -0000 On Tue, Feb 17, 2004 at 10:23:12AM +0000, Bin Ren wrote: > Hi, > > I'm thinking about whether it's possible and how to pin > a subsystem of kernel, from a particular driver (such as > software RAID) to TCP network stack, to a particular > CPU. In other words, I have dual processors and how > can I make one of the CPU JUST runs TCP stack so > as to increase network throughput? > > Shall I turn the piece of codes into a kernel thread? Then > how hard is it? Dear Bin, I have a processor with enabled HT and run FreeBSD 5 2. I notice that the system handles this quite well on its own. When i start to compile something then the first miniute XMMS has trouble playing MP3s, but afther that time the system has ajusted quite well. -- Alex Articles based on solutions that I use: http://www.kruijff.org/alex/index.php?dir=docs/FreeBSD/ From owner-freebsd-hackers@FreeBSD.ORG Sun Feb 22 07:55:26 2004 Return-Path: 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 330E016A4CE; Sun, 22 Feb 2004 07:55:26 -0800 (PST) Received: from mail019.syd.optusnet.com.au (mail019.syd.optusnet.com.au [211.29.132.73]) by mx1.FreeBSD.org (Postfix) with ESMTP id 1685643D46; Sun, 22 Feb 2004 07:55:25 -0800 (PST) (envelope-from tfrank@optushome.com.au) Received: from marvin.home.local (c211-28-241-189.eburwd5.vic.optusnet.com.au [211.28.241.189])i1MFtJB31302; Mon, 23 Feb 2004 02:55:19 +1100 Received: by marvin.home.local (Postfix, from userid 1001) id 8D918103; Mon, 23 Feb 2004 02:55:18 +1100 (EST) Date: Mon, 23 Feb 2004 02:55:18 +1100 From: Tony Frank To: sos@freebsd.org Message-ID: <20040222155518.GA35422@marvin.home.local> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="UugvWAfsgieZRqgk" Content-Disposition: inline User-Agent: Mutt/1.4.2.1i cc: freebsd-hackers@freebsd.org Subject: Patch to improve one minor ata status print during error situation X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 22 Feb 2004 15:55:26 -0000 --UugvWAfsgieZRqgk Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Hi there, Note this only applies to -STABLE as the error handling & status prints have changed quite a bit when looking at -HEAD. Currently I got this: ad2s1e: hard error reading fsbn 32383 of 16160-16415 (ad2s1 bn 32383; cn 4 tn 34 sn 1) ad2: success setting PIO4 on generic chip trying PIO mode ad2: DMA problem fallback to PIO mode ad2: DMA problem fallback to PIO mode ad2: DMA problem fallback to PIO mode ad2: DMA problem fallback to PIO mode ad2: DMA problem fallback to PIO mode ad2: DMA problem fallback to PIO mode ad2: DMA problem fallback to PIO mode ad2s1e: hard error reading fsbn 32495 of 16160-16415 (ad2s1 bn 32495; cn 4 tn 35 sn 50) status=59 error=01 With the attached patch it would show as: ad2s1e: hard error reading fsbn 32383 of 16160-16415 (ad2s1 bn 32383; cn 4 tn 34 sn 1) trying PIO mode ad2: success setting PIO4 on generic chip ad2: DMA problem fallback to PIO mode ad2: DMA problem fallback to PIO mode ad2: DMA problem fallback to PIO mode ad2: DMA problem fallback to PIO mode ad2: DMA problem fallback to PIO mode ad2: DMA problem fallback to PIO mode ad2: DMA problem fallback to PIO mode ad2s1e: hard error reading fsbn 32495 of 16160-16415 (ad2s1 bn 32495; cn 4 tn 35 sn 50) status=59 error=01 While not a big deal it may be simple enough to add? Attached patch was created from: * $FreeBSD: src/sys/dev/ata/ata-disk.c,v 1.60.2.27 2003/09/05 18:27:38 dg Exp $ Regards, Tony --UugvWAfsgieZRqgk Content-Type: text/plain; charset=us-ascii Content-Disposition: attachment; filename="ata-disk.patch" --- ata-disk.c.orig Mon Feb 23 02:36:28 2004 +++ ata-disk.c Mon Feb 23 02:40:00 2004 @@ -631,9 +631,9 @@ if (request->flags & ADR_F_DMA_USED) { untimeout((timeout_t *)ad_timeout, request,request->timeout_handle); ad_invalidatequeue(adp, request); + printf(" trying PIO mode\n"); ata_dmainit(adp->device, ata_pmode(adp->device->param), -1, -1); request->flags |= ADR_F_FORCE_PIO; - printf(" trying PIO mode\n"); TAILQ_INSERT_HEAD(&adp->device->channel->ata_queue, request, chain); return ATA_OP_FINISHED; } --UugvWAfsgieZRqgk-- From owner-freebsd-hackers@FreeBSD.ORG Sun Feb 22 08:02:04 2004 Return-Path: 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 150BB16A4CE for ; Sun, 22 Feb 2004 08:02:04 -0800 (PST) Received: from mta08-svc.ntlworld.com (mta08-svc.ntlworld.com [62.253.162.48]) by mx1.FreeBSD.org (Postfix) with ESMTP id 9552043D2D for ; Sun, 22 Feb 2004 08:02:03 -0800 (PST) (envelope-from scott@fishballoon.org) Received: from llama.fishballoon.org ([81.104.195.124]) by mta08-svc.ntlworld.comESMTP <20040222160203.HOJT21785.mta08-svc.ntlworld.com@llama.fishballoon.org>; Sun, 22 Feb 2004 16:02:03 +0000 Received: from tuatara.fishballoon.org ([192.168.1.6]) by llama.fishballoon.org with esmtp (Exim 4.30; FreeBSD) id 1Auw3O-000EZP-FW; Sun, 22 Feb 2004 16:02:02 +0000 Received: (from scott@localhost) by tuatara.fishballoon.org (8.12.10/8.12.10/Submit) id i1MG21AS083135; Sun, 22 Feb 2004 16:02:01 GMT (envelope-from scott) Date: Sun, 22 Feb 2004 16:02:00 +0000 From: Scott Mitchell To: rhett@alasir.com Message-ID: <20040222160200.GB443@tuatara.fishballoon.org> References: <20040221055830.52920.qmail@web25105.mail.ukl.yahoo.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20040221055830.52920.qmail@web25105.mail.ukl.yahoo.com> User-Agent: Mutt/1.4.1i X-Operating-System: FreeBSD 4.9-STABLE i386 cc: hackers@freebsd.org Subject: Re: Xircom CEM56 problem X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 22 Feb 2004 16:02:04 -0000 On Sat, Feb 21, 2004 at 05:58:30AM +0000, RMH wrote: > Hello hackers, > > I have a problem with Xircom CEM56 (Ethernet + Modem) PC Card. > I know it isn't really possible on 4.x to use both network & > modem parts at the same time, but how to switch between them > without rebooting? > > For example, if I've booted with pccardd configured for either, > then I edit pccard.conf (a symlink to a real network or modem > .conf file), and what next? kldunload if_xe.ko if loaded already, > kill -s HUP [pccardd_pid] or just kill -9 [pccardd_pid] and > restart don't seem to have a desired effect because kernel > (pccard) complaints that it cannot attach more than one child. > But upon rebooting it probes the hardware just fine. How may I > reset pccard on the fly? > > A working solution is to pull the card and install it into a > second slot, but I guess it's not the best idea, because after > several such "swaps" I've got a page fault an a kernel panic... Hi Rhett, I have a couple of scripts that I use when I need to swaps cards and/or drivers, when I'm working on the xe driver. This is on -CURRENT, but using the OLDCARD driver framework, so it will hopefully work on 4.x as well: To shutdown the card: ifconfig xe0 down kill `cat /var/run/dhclient.pid` pccardc power 0 0 sleep 2 kldunload if_xe To bring it back up again after recompiling the driver or swapping cards: kldload if_xe pccardc power 0 1 The 'pccardc power' commands simulate removing and re-inserting the card. In your case you'll obviously need to switch pccard.conf and bounce pccardd while the card is powered down. If this still triggers a panic, could you file a PR on it? If it's something in the xe driver I'll take a look at it. Cheers, Scott -- =========================================================================== Scott Mitchell | PGP Key ID | "Eagles may soar, but weasels Cambridge, England | 0x54B171B9 | don't get sucked into jet engines" scott at fishballoon.org | 0xAA775B8B | -- Anon From owner-freebsd-hackers@FreeBSD.ORG Sun Feb 22 21:57:36 2004 Return-Path: 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 814E816A4CE for ; Sun, 22 Feb 2004 21:57:36 -0800 (PST) Received: from web10505.mail.yahoo.com (web10505.mail.yahoo.com [216.136.130.155]) by mx1.FreeBSD.org (Postfix) with SMTP id 79D5543D1D for ; Sun, 22 Feb 2004 21:57:36 -0800 (PST) (envelope-from b_oshea@yahoo.com) Message-ID: <20040223055736.19639.qmail@web10505.mail.yahoo.com> Received: from [24.6.211.6] by web10505.mail.yahoo.com via HTTP; Sun, 22 Feb 2004 21:57:36 PST Date: Sun, 22 Feb 2004 21:57:36 -0800 (PST) From: Brian O'Shea To: Hackers FreeBSD MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="0-1815627535-1077515856=:19519" Subject: 5.2.1-RC hangs occasionally when sound files are played using the pcm driver X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 23 Feb 2004 05:57:36 -0000 --0-1815627535-1077515856=:19519 Content-Type: text/plain; charset=us-ascii Content-Id: Content-Disposition: inline Hello Hackers, My system: $ uname -a FreeBSD apsara 5.2.1-RC FreeBSD 5.2.1-RC #0: Sat Feb 7 21:38:15 PST 2004 root@apsara:/usr/src/sys/i386/compile/APSARA i386 $ dmesg | grep pcm pcm0: port 0xd400-0xd4ff irq 16 at device 14.0 on pci0 (full dmesg output attached) Occasionally my system will lock up when audio files are played. I am using the pcm driver with a CMI 8738 on-board 6-channel audio chip (SoyoPX400 Dragon Lite motherboard). No crash dump, no panic message is displayed; the system just freezes. It does not happen regularly--probably only once in 10 or 20 times that the audio device is used. When it does happen, it can happen immediately after the audio file is played, or sometimes after several seconds. A quick search of the -hackers and -questions archives didn't turn up any matches. Has anyone else seen this behavior? Would it be more useful for me to build a debug kernel with INVARIANTS enabled and try to get the system to panic? Thanks! -brian __________________________________ Do you Yahoo!? Yahoo! Mail SpamGuard - Read only the mail you want. http://antispam.yahoo.com/tools --0-1815627535-1077515856=:19519 Content-Type: text/plain; name=dmesg Content-Description: dmesg Content-Disposition: inline; filename=dmesg Copyright (c) 1992-2004 The FreeBSD Project. Copyright (c) 1979, 1980, 1983, 1986, 1988, 1989, 1991, 1992, 1993, 1994 The Regents of the University of California. All rights reserved. FreeBSD 5.2.1-RC #0: Sat Feb 7 21:38:15 PST 2004 root@apsara:/usr/src/sys/i386/compile/APSARA Preloaded elf kernel "/boot/kernel/kernel" at 0xc09d4000. Preloaded elf module "/boot/kernel/acpi.ko" at 0xc09d4244. Timecounter "i8254" frequency 1193182 Hz quality 0 CPU: Intel(R) Pentium(R) 4 CPU 1.80GHz (1796.94-MHz 686-class CPU) Origin = "GenuineIntel" Id = 0xf24 Stepping = 4 Features=0x3febfbff real memory = 536805376 (511 MB) avail memory = 511770624 (488 MB) ACPI APIC Table: ioapic0 irqs 0-23 on motherboard Pentium Pro MTRR support enabled npx0: [FAST] npx0: on motherboard npx0: INT 16 interface acpi0: on motherboard pcibios: BIOS version 2.10 Using $PIR table, 11 entries at 0xc00fde60 acpi0: Power Button (fixed) Timecounter "ACPI-fast" frequency 3579545 Hz quality 1000 acpi_timer0: <24-bit timer at 3.579545MHz> port 0x408-0x40b on acpi0 acpi_cpu0: port 0x530-0x537 on acpi0 acpi_tz0: port 0x530-0x537 on acpi0 acpi_button0: on acpi0 acpi_button1: on acpi0 pcib0: port 0x500-0x50f,0x400-0x47f,0xcf8-0xcff on acpi0 pci0: on pcib0 pcib0: possible interrupts: 21 pcib0: slot 16 INTA routed to irq 21 via \\_SB_.PCI0.ALKB pcib0: possible interrupts: 21 pcib0: slot 16 INTB routed to irq 21 via \\_SB_.PCI0.ALKB pcib0: possible interrupts: 21 pcib0: slot 16 INTC routed to irq 21 via \\_SB_.PCI0.ALKB pcib0: possible interrupts: 21 pcib0: slot 16 INTD routed to irq 21 via \\_SB_.PCI0.ALKB agp0: mem 0xe0000000-0xe3ffffff at device 0.0 on pci0 pcib1: at device 1.0 on pci0 pci1: on pcib1 pci0: at device 8.0 (no driver attached) rl0: port 0xd000-0xd0ff mem 0xe7000000-0xe70000ff irq 18 at device 13.0 on pci0 rl0: Ethernet address: 00:50:2c:06:40:d8 miibus0: on rl0 rlphy0: on miibus0 rlphy0: 10baseT, 10baseT-FDX, 100baseTX, 100baseTX-FDX, auto pcm0: port 0xd400-0xd4ff irq 16 at device 14.0 on pci0 uhci0: port 0xd800-0xd81f irq 21 at device 16.0 on pci0 usb0: on uhci0 usb0: USB revision 1.0 uhub0: VIA UHCI root hub, class 9/0, rev 1.00/1.00, addr 1 uhub0: 2 ports with 2 removable, self powered uhci1: port 0xdc00-0xdc1f irq 21 at device 16.1 on pci0 usb1: on uhci1 usb1: USB revision 1.0 uhub1: VIA UHCI root hub, class 9/0, rev 1.00/1.00, addr 1 uhub1: 2 ports with 2 removable, self powered uhci2: port 0xe000-0xe01f irq 21 at device 16.2 on pci0 usb2: on uhci2 usb2: USB revision 1.0 uhub2: VIA UHCI root hub, class 9/0, rev 1.00/1.00, addr 1 uhub2: 2 ports with 2 removable, self powered pci0: at device 16.3 (no driver attached) isab0: at device 17.0 on pci0 isa0: on isab0 atapci0: port 0xe400-0xe40f at device 17.1 on pci0 ata0: at 0x1f0 irq 14 on atapci0 ata0: [MPSAFE] ata1: at 0x170 irq 15 on atapci0 ata1: [MPSAFE] fdc0: port 0x3f7,0x3f2-0x3f5 irq 6 drq 2 on acpi0 fdc0: FIFO enabled, 8 bytes threshold fd0: <1440-KB 3.5" drive> on fdc0 drive 0 sio0 port 0x3f8-0x3ff irq 4 on acpi0 sio0: type 16550A sio1 port 0x2f8-0x2ff irq 3 on acpi0 sio1: type 16550A ppc0 port 0x778-0x77b,0x378-0x37f irq 7 on acpi0 ppc0: Generic chipset (NIBBLE-only) in COMPATIBLE mode ppbus0: on ppc0 plip0: on ppbus0 lpt0: on ppbus0 lpt0: Interrupt-driven port ppi0: on ppbus0 atkbdc0: port 0x64,0x60 irq 1 on acpi0 atkbd0: flags 0x1 irq 1 on atkbdc0 kbd0 at atkbd0 psm0: irq 12 on atkbdc0 psm0: model IntelliMouse, device ID 3 pmtimer0 on isa0 orm0: