From owner-freebsd-alpha@FreeBSD.ORG Mon Jan 5 04:39:08 2004 Return-Path: Delivered-To: freebsd-alpha@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id A738516A4CE for ; Mon, 5 Jan 2004 04:39:08 -0800 (PST) Received: from blount.mail.mindspring.net (blount.mail.mindspring.net [207.69.200.226]) by mx1.FreeBSD.org (Postfix) with ESMTP id 4C28B43D2D for ; Mon, 5 Jan 2004 04:39:07 -0800 (PST) (envelope-from mail_list@mindspring.com) Received: from h-67-101-167-234.lsanca54.dynamic.covad.net ([67.101.167.234] helo=mindspring.com) by blount.mail.mindspring.net with esmtp (Exim 3.33 #1) id 1AdU0g-00084w-00 for freebsd-alpha@freebsd.org; Mon, 05 Jan 2004 07:39:06 -0500 Message-ID: <3FF95AE6.30103@mindspring.com> Date: Mon, 05 Jan 2004 04:39:02 -0800 From: FBSD_AS1200 User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.4) Gecko/20030624 Netscape/7.1 (ax) X-Accept-Language: en-us, en MIME-Version: 1.0 To: freebsd-alpha@freebsd.org Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit Subject: xfree86 support for AS1200 X-BeenThere: freebsd-alpha@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Porting FreeBSD to the Alpha List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 05 Jan 2004 12:39:08 -0000 Just wanted to get some comments or opinions on the AS1200 suggestions received from the XFree86 mailing list as quoted below. FBSD_AS1200 wrote (in a message from Saturday 3) > Thank you for the reference. I have read the note but still don't feel > any closer to finding support for my system. The Domain.note appears to > be geared toward sun linux systems. While the note did mention > multi-domain alpha systems (I assume this is a ref to multi pci-host > bridges) I am still not clear on how I should implement an XFree86 > system on an AlphaServer 1200 under FreeBSD. I think I MUST be missing a > point or two... Would it be possible to find further documentation on > this issue so I can get up to speed on X development. From the post I > have been reading on XFree86 and FreeBSD mailing list there are several > people with multi-pci bus alpha systems that would like to assist in > getting XFree up and running under a BSD variant. Thank you for your > assistance! I'm sorry, I don't know any other written documentation that could help you. What you need is to implement the xf86GetPciDomain(), xf86MapDomainMemory(), xf86MapDomainIO() and xf86ReadDomainMemory(). functions in freebsdPci.c. Once you've done this, you can edit Pci.h and remove the INCLUDE_XF86_NO_DOMAIN for FreeBSD/alpha. Then the XFree86 drivers will be able to access the video card(s) independently of the bus they are attached to. There can be 2 approaches for that : - if the FreeBSD kernel already provides an API to enumerate the PCI host bridges and the configuration space and memory mappings for each host bridge, use that (this is what freebsdPci.c currently does for a single host bridge). - it there's no such interface available, then you need to develop a driver that will poke directly into the main chipset I/O registers to probe the various host bridges and handle their memory mappings from userland. This is for instance what sparcPci.c does for SunOS. Don't hesitate to join the devel@xfree86 mailing list and ask more questions here if needed. This list is more appropriate for developpement related questions. Looking forward for your contributions. Matthieu From owner-freebsd-alpha@FreeBSD.ORG Mon Jan 5 11:03:27 2004 Return-Path: Delivered-To: freebsd-alpha@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 02B1416A4D0 for ; Mon, 5 Jan 2004 11:03:27 -0800 (PST) Received: from freefall.freebsd.org (freefall.freebsd.org [216.136.204.21]) by mx1.FreeBSD.org (Postfix) with ESMTP id 0F4A943D5C for ; Mon, 5 Jan 2004 11:01:37 -0800 (PST) (envelope-from owner-bugmaster@freebsd.org) Received: from freefall.freebsd.org (peter@localhost [127.0.0.1]) by freefall.freebsd.org (8.12.10/8.12.10) with ESMTP id i05J1aFR016036 for ; Mon, 5 Jan 2004 11:01:36 -0800 (PST) (envelope-from owner-bugmaster@freebsd.org) Received: (from peter@localhost) by freefall.freebsd.org (8.12.10/8.12.10/Submit) id i05J1aCd016030 for freebsd-alpha@freebsd.org; Mon, 5 Jan 2004 11:01:36 -0800 (PST) (envelope-from owner-bugmaster@freebsd.org) Date: Mon, 5 Jan 2004 11:01:36 -0800 (PST) Message-Id: <200401051901.i05J1aCd016030@freefall.freebsd.org> X-Authentication-Warning: freefall.freebsd.org: peter set sender to owner-bugmaster@freebsd.org using -f From: FreeBSD bugmaster To: freebsd-alpha@FreeBSD.org Subject: Current problem reports assigned to you X-BeenThere: freebsd-alpha@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Porting FreeBSD to the Alpha List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 05 Jan 2004 19:03:27 -0000 Current FreeBSD problem reports Critical problems Serious problems S Submitted Tracker Resp. Description ------------------------------------------------------------------------------- o [2001/09/10] alpha/30486 alpha AlphaServer DS10 floppy access is broken o [2001/09/10] alpha/30487 alpha Floppy access on AlphaServer DS20 solid l o [2003/02/05] alpha/47952 alpha DEFPA causes machine check with V5.0-rele 3 problems total. Non-critical problems S Submitted Tracker Resp. Description ------------------------------------------------------------------------------- o [2001/01/26] alpha/24663 alpha Console output gets scribbled into /var/l o [2001/02/22] alpha/25284 alpha PC164 won't reboot with graphics console o [2001/06/07] alpha/27933 alpha Time jitter under load on FreeBSD 4.3 alp f [2001/07/29] alpha/29299 alpha FreeBSD 4.3 Alpha + Tekram SCSI adapter p o [2001/10/01] alpha/30970 alpha Ensoniq 1371 (Creative chipset) does not o [2002/01/24] alpha/34232 alpha rpc.statd throws alignment errors o [2002/03/26] alpha/36327 alpha trap within cvt() while attempting to pri o [2002/05/13] alpha/38031 alpha osf1.ko not loaded during boot-time of li p [2002/11/12] alpha/45240 alpha pstat -f column headings misaligned on Al o [2003/02/25] alpha/48676 alpha Changing the baud rate of serial consoles o [2003/04/12] alpha/50868 alpha fd0 floppy device is not mapped into /dev o [2003/06/02] alpha/52882 alpha fpsetprec/fp_prec_t unsupported on alpha? 12 problems total. From owner-freebsd-alpha@FreeBSD.ORG Mon Jan 5 18:43:25 2004 Return-Path: Delivered-To: freebsd-alpha@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id A340B16A4CE for ; Mon, 5 Jan 2004 18:43:25 -0800 (PST) Received: from sdf.lonestar.org (ol.freeshell.org [192.94.73.20]) by mx1.FreeBSD.org (Postfix) with ESMTP id ACBDF43D45 for ; Mon, 5 Jan 2004 18:43:23 -0800 (PST) (envelope-from phyx@freeshell.org) Received: from webmail.freeshell.org (IDENT:nobody@vinland.freeshell.org [192.94.73.6]) by sdf.lonestar.org (8.12.10/8.12.10) with SMTP id i062hK6u008429 for ; Tue, 6 Jan 2004 02:43:20 GMT Received: from 66.227.165.200 (SquirrelMail authenticated user phyx) by webmail.freeshell.org with HTTP; Mon, 5 Jan 2004 21:43:20 -0500 (EST) Message-ID: <49449.66.227.165.200.1073357000.squirrel@webmail.freeshell.org> In-Reply-To: <3FF95AE6.30103@mindspring.com> References: <3FF95AE6.30103@mindspring.com> Date: Mon, 5 Jan 2004 21:43:20 -0500 (EST) From: "S.C. Gehl" To: freebsd-alpha@freebsd.org User-Agent: SquirrelMail/1.4.2 MIME-Version: 1.0 Content-Type: text/plain;charset=iso-8859-1 Content-Transfer-Encoding: 8bit X-Priority: 3 Importance: Normal Subject: Re: xfree86supportforAS1200 X-BeenThere: freebsd-alpha@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Porting FreeBSD to the Alpha List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 06 Jan 2004 02:43:25 -0000 Cheers... sorry for the excessive quote... it's a bitch to edit/format a ong letter in 'links' ...I can not find freebsdPci.c nor can I find Pci.h I have looked in both fbsd-current and xf-current. Have you made any head way on this? I have barely just begun to learn C, so this is a great way for me to jump in head first... but honestly I am not sure where to jump. The letter seems to say where, and it makes sense. I am glad that they are aware of the source of the problem.. but where are these files! -Sean. > Just wanted to get some comments or opinions on the AS1200 > suggestions received from the XFree86 mailing list as > quoted below. > > > > FBSD_AS1200 wrote (in a message from Saturday 3) > > Thank you for the reference. I have read the note but > still don't feel > > any closer to finding support for my system. The > Domain.note appears to > > be geared toward sun linux systems. While the note did > mention > > multi-domain alpha systems (I assume this is a ref to > multi pci-host > > bridges) I am still not clear on how I should implement > an XFree86 > > system on an AlphaServer 1200 under FreeBSD. I think I > MUST be missing a > > point or two... Would it be possible to find further > documentation on > > this issue so I can get up to speed on X development. > From the post I > > have been reading on XFree86 and FreeBSD mailing list > there are several > > people with multi-pci bus alpha systems that would like > to assist in > > getting XFree up and running under a BSD variant. Thank > you for your > > assistance! > > I'm sorry, I don't know any other written documentation > that could > help you. > What you need is to implement the xf86GetPciDomain(), > xf86MapDomainMemory(), > xf86MapDomainIO() and xf86ReadDomainMemory(). functions in > freebsdPci.c. Once you've done this, you can edit Pci.h > and remove > the INCLUDE_XF86_NO_DOMAIN for FreeBSD/alpha. Then the > XFree86 drivers > will be able to access the video card(s) independently of > the bus they > are attached to. > > There can be 2 approaches for that : > > - if the FreeBSD kernel already provides an API to > enumerate the PCI > host bridges and the configuration space and memory > mappings for > each host bridge, use that (this is what freebsdPci.c > currently does > for a single host bridge). > > - it there's no such interface available, then you need to > develop a > driver that will poke directly into the main chipset I/O > registers > to probe the various host bridges and handle their > memory mappings > from userland. This is for instance what sparcPci.c does > for SunOS. > > Don't hesitate to join the devel@xfree86 mailing list and > ask more > questions here if needed. This list is more appropriate > for > developpement related questions. > > Looking forward for your contributions. > > Matthieu > > > _______________________________________________ > freebsd-alpha@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/freebsd-alpha > To unsubscribe, send any mail to > "freebsd-alpha-unsubscribe@freebsd.org" > From owner-freebsd-alpha@FreeBSD.ORG Mon Jan 5 20:42:01 2004 Return-Path: Delivered-To: freebsd-alpha@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 8966316A4CE for ; Mon, 5 Jan 2004 20:42:01 -0800 (PST) Received: from smtp6.mindspring.com (smtp6.mindspring.com [207.69.200.110]) by mx1.FreeBSD.org (Postfix) with ESMTP id B1E8B43D46 for ; Mon, 5 Jan 2004 20:41:55 -0800 (PST) (envelope-from mail_list@mindspring.com) Received: from h-68-164-116-201.lsanca54.dynamic.covad.net ([68.164.116.201] helo=mindspring.com) by smtp6.mindspring.com with esmtp (Exim 3.33 #1) id 1Adj2C-0000tD-00; Mon, 05 Jan 2004 23:41:48 -0500 Message-ID: <3FFA3C7E.1050106@mindspring.com> Date: Mon, 05 Jan 2004 20:41:34 -0800 From: FBSD_AS1200 User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.4) Gecko/20030624 Netscape/7.1 (ax) X-Accept-Language: en-us, en MIME-Version: 1.0 To: "S.C. Gehl" References: <3FF95AE6.30103@mindspring.com> <49449.66.227.165.200.1073357000.squirrel@webmail.freeshell.org> In-Reply-To: <49449.66.227.165.200.1073357000.squirrel@webmail.freeshell.org> Content-Type: multipart/mixed; boundary="------------050908010206090008020205" cc: freebsd-alpha@freebsd.org Subject: Re: xfree86supportforAS1200 X-BeenThere: freebsd-alpha@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Porting FreeBSD to the Alpha List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 06 Jan 2004 04:42:01 -0000 This is a multi-part message in MIME format. --------------050908010206090008020205 Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit S.C. Gehl wrote: >Cheers... > >sorry for the excessive quote... it's a bitch to >edit/format a ong letter in 'links' > >...I can not find freebsdPci.c nor can I find Pci.h > >I have looked in both fbsd-current and xf-current. > >Have you made any head way on this? I have barely just >begun to learn C, so this is a great way for me to jump in >head first... but honestly I am not sure where to jump. >The letter seems to say where, and it makes sense. I am >glad that they are aware of the source of the problem.. >but where are these files! -Sean. > > > >>Just wanted to get some comments or opinions on the AS1200 >>suggestions received from the XFree86 mailing list as >>quoted below. >> >> >> >>FBSD_AS1200 wrote (in a message from Saturday 3) >> > Thank you for the reference. I have read the note but >>still don't feel >> > any closer to finding support for my system. The >>Domain.note appears to >> > be geared toward sun linux systems. While the note did >>mention >> > multi-domain alpha systems (I assume this is a ref to >>multi pci-host >> > bridges) I am still not clear on how I should implement >>an XFree86 >> > system on an AlphaServer 1200 under FreeBSD. I think I >>MUST be missing a >> > point or two... Would it be possible to find further >>documentation on >> > this issue so I can get up to speed on X development. >>From the post I >> > have been reading on XFree86 and FreeBSD mailing list >>there are several >> > people with multi-pci bus alpha systems that would like >>to assist in >> > getting XFree up and running under a BSD variant. Thank >>you for your >> > assistance! >> >>I'm sorry, I don't know any other written documentation >>that could >>help you. >>What you need is to implement the xf86GetPciDomain(), >>xf86MapDomainMemory(), >>xf86MapDomainIO() and xf86ReadDomainMemory(). functions in >>freebsdPci.c. Once you've done this, you can edit Pci.h >>and remove >>the INCLUDE_XF86_NO_DOMAIN for FreeBSD/alpha. Then the >>XFree86 drivers >>will be able to access the video card(s) independently of >>the bus they >>are attached to. >> >>There can be 2 approaches for that : >> >>- if the FreeBSD kernel already provides an API to >>enumerate the PCI >> host bridges and the configuration space and memory >>mappings for >> each host bridge, use that (this is what freebsdPci.c >>currently does >> for a single host bridge). >> >>- it there's no such interface available, then you need to >>develop a >> driver that will poke directly into the main chipset I/O >>registers >> to probe the various host bridges and handle their >>memory mappings >> from userland. This is for instance what sparcPci.c does >>for SunOS. >> >>Don't hesitate to join the devel@xfree86 mailing list and >>ask more >>questions here if needed. This list is more appropriate >>for >>developpement related questions. >> >>Looking forward for your contributions. >> >> Matthieu >> >> >>_______________________________________________ >>freebsd-alpha@freebsd.org mailing list >>http://lists.freebsd.org/mailman/listinfo/freebsd-alpha >>To unsubscribe, send any mail to >>"freebsd-alpha-unsubscribe@freebsd.org" >> >> >> > >_______________________________________________ >freebsd-alpha@freebsd.org mailing list >http://lists.freebsd.org/mailman/listinfo/freebsd-alpha >To unsubscribe, send any mail to "freebsd-alpha-unsubscribe@freebsd.org" > > > Here are the most recent versions I could find. Maybe I will get a chance to play with them a bit later. Let us know if you make any headway. --------------050908010206090008020205 Content-Type: text/plain; name="Pci.h" Content-Transfer-Encoding: 7bit Content-Disposition: inline; filename="Pci.h" /* $XFree86: xc/programs/Xserver/hw/xfree86/os-support/bus/Pci.h,v 1.42 2003/08/29 21:08:06 tsi Exp $ */ /* * Copyright 1998 by Concurrent Computer Corporation * * Permission to use, copy, modify, distribute, and sell this software * and its documentation for any purpose is hereby granted without fee, * provided that the above copyright notice appear in all copies and that * both that copyright notice and this permission notice appear in * supporting documentation, and that the name of Concurrent Computer * Corporation not be used in advertising or publicity pertaining to * distribution of the software without specific, written prior * permission. Concurrent Computer Corporation makes no representations * about the suitability of this software for any purpose. It is * provided "as is" without express or implied warranty. * * CONCURRENT COMPUTER CORPORATION DISCLAIMS ALL WARRANTIES WITH REGARD * TO THIS SOFTWARE, INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY * AND FITNESS, IN NO EVENT SHALL CONCURRENT COMPUTER CORPORATION BE * LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY * DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, * WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, * ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS * SOFTWARE. * * Copyright 1998 by Metro Link Incorporated * * Permission to use, copy, modify, distribute, and sell this software * and its documentation for any purpose is hereby granted without fee, * provided that the above copyright notice appear in all copies and that * both that copyright notice and this permission notice appear in * supporting documentation, and that the name of Metro Link * Incorporated not be used in advertising or publicity pertaining to * distribution of the software without specific, written prior * permission. Metro Link Incorporated makes no representations * about the suitability of this software for any purpose. It is * provided "as is" without express or implied warranty. * * METRO LINK INCORPORATED DISCLAIMS ALL WARRANTIES WITH REGARD * TO THIS SOFTWARE, INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY * AND FITNESS, IN NO EVENT SHALL METRO LINK INCORPORATED BE * LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY * DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, * WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, * ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS * SOFTWARE. * * This file is derived in part from the original xf86_PCI.h that included * following copyright message: * * Copyright 1995 by Robin Cutshaw * * Permission to use, copy, modify, distribute, and sell this software and its * documentation for any purpose is hereby granted without fee, provided that * the above copyright notice appear in all copies and that both that * copyright notice and this permission notice appear in supporting * documentation, and that the names of the above listed copyright holder(s) * not be used in advertising or publicity pertaining to distribution of * the software without specific, written prior permission. The above listed * copyright holder(s) make(s) no representations about the suitability of this * software for any purpose. It is provided "as is" without express or * implied warranty. * * THE ABOVE LISTED COPYRIGHT HOLDER(S) DISCLAIM(S) ALL WARRANTIES WITH REGARD * TO THIS SOFTWARE, INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY * AND FITNESS, IN NO EVENT SHALL THE ABOVE LISTED COPYRIGHT HOLDER(S) BE * LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY * DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER * IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING * OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * */ /* * Copyright (c) 1999-2003 by The XFree86 Project, Inc. * * Permission is hereby granted, free of charge, to any person obtaining a * copy of this software and associated documentation files (the "Software"), * to deal in the Software without restriction, including without limitation * the rights to use, copy, modify, merge, publish, distribute, sublicense, * and/or sell copies of the Software, and to permit persons to whom the * Software is furnished to do so, subject to the following conditions: * * The above copyright notice and this permission notice shall be included in * all copies or substantial portions of the Software. * * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL * THE COPYRIGHT HOLDER(S) OR AUTHOR(S) BE LIABLE FOR ANY CLAIM, DAMAGES OR * OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, * ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR * OTHER DEALINGS IN THE SOFTWARE. * * Except as contained in this notice, the name of the copyright holder(s) * and author(s) shall not be used in advertising or otherwise to promote * the sale, use or other dealings in this Software without prior written * authorization from the copyright holder(s) and author(s). */ /* * This file has the private Pci definitions. The public ones are imported * from xf86Pci.h. Drivers should not use this file. */ #ifndef _PCI_H #define _PCI_H 1 #include "Xarch.h" #include "Xfuncproto.h" #include "xf86Pci.h" #include "xf86PciInfo.h" /* * Global Definitions */ #define MAX_PCI_DEVICES 64 /* Max number of devices accomodated */ /* by xf86scanpci */ #if defined(sun) && defined(SVR4) && defined(sparc) # define MAX_PCI_BUSES 4096 /* Max number of PCI buses */ #elif defined(__alpha__) && defined (linux) # define MAX_PCI_DOMAINS 512 # define PCI_DOM_MASK 0x01fful # define MAX_PCI_BUSES (MAX_PCI_DOMAINS*256) /* 256 per domain */ #else # define MAX_PCI_BUSES 256 /* Max number of PCI buses */ #endif #define DEVID(vendor, device) \ ((CARD32)((PCI_##device << 16) | PCI_##vendor)) #ifndef PCI_DOM_MASK # define PCI_DOM_MASK 0x0ffu #endif #define PCI_DOMBUS_MASK (((PCI_DOM_MASK) << 8) | 0x0ffu) /* * "b" contains an optional domain number. */ #define PCI_MAKE_TAG(b,d,f) ((((b) & (PCI_DOMBUS_MASK)) << 16) | \ (((d) & 0x00001fu) << 11) | \ (((f) & 0x000007u) << 8)) #define PCI_MAKE_BUS(d,b) ((((d) & (PCI_DOM_MASK)) << 8) | ((b) & 0xffu)) #define PCI_DOM_FROM_TAG(tag) (((tag) >> 24) & (PCI_DOM_MASK)) #define PCI_BUS_FROM_TAG(tag) (((tag) >> 16) & (PCI_DOMBUS_MASK)) #define PCI_DEV_FROM_TAG(tag) (((tag) & 0x0000f800u) >> 11) #define PCI_FUNC_FROM_TAG(tag) (((tag) & 0x00000700u) >> 8) #define PCI_DFN_FROM_TAG(tag) (((tag) & 0x0000ff00u) >> 8) #define PCI_BDEV_FROM_TAG(tag) ((tag) & 0x00fff800u) #define PCI_DOM_FROM_BUS(bus) (((bus) >> 8) & (PCI_DOM_MASK)) #define PCI_BUS_NO_DOMAIN(bus) ((bus) & 0xffu) #define PCI_TAG_NO_DOMAIN(tag) ((tag) & 0x00ffff00u) /* * Macros for bus numbers found in P2P headers. */ #define PCI_PRIMARY_BUS_EXTRACT(x, tag) \ ((((x) & PCI_PRIMARY_BUS_MASK ) >> 0) | (PCI_DOM_FROM_TAG(tag) << 8)) #define PCI_SECONDARY_BUS_EXTRACT(x, tag) \ ((((x) & PCI_SECONDARY_BUS_MASK ) >> 8) | (PCI_DOM_FROM_TAG(tag) << 8)) #define PCI_SUBORDINATE_BUS_EXTRACT(x, tag) \ ((((x) & PCI_SUBORDINATE_BUS_MASK) >> 16) | (PCI_DOM_FROM_TAG(tag) << 8)) #define PCI_PRIMARY_BUS_INSERT(x, y) \ (((x) & ~PCI_PRIMARY_BUS_MASK ) | (((y) & 0xffu) << 0)) #define PCI_SECONDARY_BUS_INSERT(x, y) \ (((x) & ~PCI_SECONDARY_BUS_MASK ) | (((y) & 0xffu) << 8)) #define PCI_SUBORDINATE_BUS_INSERT(x, y) \ (((x) & ~PCI_SUBORDINATE_BUS_MASK) | (((y) & 0xffu) << 16)) /* Ditto for CardBus bridges */ #define PCI_CB_PRIMARY_BUS_EXTRACT(x, tag) \ PCI_PRIMARY_BUS_EXTRACT(x, tag) #define PCI_CB_CARDBUS_BUS_EXTRACT(x, tag) \ PCI_SECONDARY_BUS_EXTRACT(x, tag) #define PCI_CB_SUBORDINATE_BUS_EXTRACT(x, tag) \ PCI_SUBORDINATE_BUS_EXTRACT(x, tag) #define PCI_CB_PRIMARY_BUS_INSERT(x, tag) \ PCI_PRIMARY_BUS_INSERT(x, tag) #define PCI_CB_CARDBUS_BUS_INSERT(x, tag) \ PCI_SECONDARY_BUS_INSERT(x, tag) #define PCI_CB_SUBORDINATE_BUS_INSERT(x, tag) \ PCI_SUBORDINATE_BUS_INSERT(x, tag) #if X_BYTE_ORDER == X_BIG_ENDIAN #define PCI_CPU(val) (((val >> 24) & 0x000000ff) | \ ((val >> 8) & 0x0000ff00) | \ ((val << 8) & 0x00ff0000) | \ ((val << 24) & 0xff000000)) #else #define PCI_CPU(val) (val) #endif /* * Debug Macros/Definitions */ /* #define DEBUGPCI 2 */ /* Disable/enable trace in PCI code */ #if defined(DEBUGPCI) # define PCITRACE(lvl,printfargs) \ if (lvl > xf86Verbose) { \ ErrorF printfargs; \ } #else /* !defined(DEBUGPCI) */ # define PCITRACE(lvl,printfargs) #endif /* !defined(DEBUGPCI) */ /* * PCI Config mechanism definitions */ #define PCI_EN 0x80000000 #define PCI_CFGMECH1_ADDRESS_REG 0xCF8 #define PCI_CFGMECH1_DATA_REG 0xCFC #define PCI_CFGMECH1_MAXDEV 32 /* * Select architecture specific PCI init function */ #if defined(__alpha__) # if defined(linux) # define ARCH_PCI_INIT axpPciInit # define INCLUDE_XF86_MAP_PCI_MEM # elif defined(__FreeBSD__) || defined(__OpenBSD__) # define ARCH_PCI_INIT freebsdPciInit # define INCLUDE_XF86_MAP_PCI_MEM # define INCLUDE_XF86_NO_DOMAIN # elif defined(__NetBSD__) # define ARCH_PCI_INIT netbsdPciInit # define INCLUDE_XF86_MAP_PCI_MEM # define INCLUDE_XF86_NO_DOMAIN # endif #elif defined(__arm__) # if defined(linux) # define ARCH_PCI_INIT linuxPciInit # define INCLUDE_XF86_MAP_PCI_MEM # define INCLUDE_XF86_NO_DOMAIN # endif #elif defined(__hppa__) # if defined(linux) # define ARCH_PCI_INIT linuxPciInit # define INCLUDE_XF86_MAP_PCI_MEM # define INCLUDE_XF86_NO_DOMAIN # endif #elif defined(__ia64__) # if defined(linux) # define ARCH_PCI_INIT linuxPciInit # define INCLUDE_XF86_MAP_PCI_MEM # define INCLUDE_XF86_NO_DOMAIN # endif # define XF86SCANPCI_WRAPPER ia64ScanPCIWrapper #elif defined(__i386__) # define ARCH_PCI_INIT ix86PciInit # define INCLUDE_XF86_MAP_PCI_MEM # define INCLUDE_XF86_NO_DOMAIN # if defined(linux) # define ARCH_PCI_OS_INIT linuxPciInit # endif #elif defined(__mc68000__) # if defined(linux) # define ARCH_PCI_INIT linuxPciInit # define INCLUDE_XF86_MAP_PCI_MEM # define INCLUDE_XF86_NO_DOMAIN # endif #elif defined(__mips__) # if defined(linux) # define ARCH_PCI_INIT linuxPciInit # define INCLUDE_XF86_MAP_PCI_MEM # define INCLUDE_XF86_NO_DOMAIN # endif #elif defined(__powerpc__) # if defined(linux) # define ARCH_PCI_INIT linuxPciInit # define INCLUDE_XF86_MAP_PCI_MEM # define INCLUDE_XF86_NO_DOMAIN /* Needs kernel work to remove */ # elif defined(__OpenBSD__) # define ARCH_PCI_INIT freebsdPciInit # define INCLUDE_XF86_MAP_PCI_MEM # define INCLUDE_XF86_NO_DOMAIN # elif defined(__NetBSD__) # define ARCH_PCI_INIT netbsdPciInit # define INCLUDE_XF86_MAP_PCI_MEM # define INCLUDE_XF86_NO_DOMAIN # elif defined(PowerMAX_OS) /* This port is broken */ # define ARCH_PCI_INIT ppcPciInit # else # define ARCH_PCI_INIT ppcPciInit # define INCLUDE_XF86_MAP_PCI_MEM # define INCLUDE_XF86_NO_DOMAIN # endif #elif defined(__s390__) # if defined(linux) # define ARCH_PCI_INIT linuxPciInit # define INCLUDE_XF86_MAP_PCI_MEM # define INCLUDE_XF86_NO_DOMAIN # endif #elif defined(__sh__) # if defined(linux) # define ARCH_PCI_INIT linuxPciInit # define INCLUDE_XF86_MAP_PCI_MEM # define INCLUDE_XF86_NO_DOMAIN # endif #elif defined(__sparc__) # if defined(linux) # define ARCH_PCI_INIT linuxPciInit # define INCLUDE_XF86_MAP_PCI_MEM # elif defined(sun) # define ARCH_PCI_INIT sparcPciInit # define INCLUDE_XF86_MAP_PCI_MEM # elif defined(__OpenBSD__) && defined(__sparc64__) # define ARCH_PCI_INIT freebsdPciInit # define INCLUDE_XF86_MAP_PCI_MEM # define INCLUDE_XF86_NO_DOMAIN # endif # define ARCH_PCI_PCI_BRIDGE sparcPciPciBridge #elif defined(__AMD64__) # define ARCH_PCI_INIT ix86PciInit # define INCLUDE_XF86_MAP_PCI_MEM # define INCLUDE_XF86_NO_DOMAIN # if defined(linux) # define ARCH_PCI_OS_INIT linuxPciInit # endif #endif #ifndef ARCH_PCI_INIT #error No PCI support available for this architecture/OS combination #endif extern void ARCH_PCI_INIT(void); #if defined(ARCH_PCI_OS_INIT) extern void ARCH_PCI_OS_INIT(void); #endif #if defined(ARCH_PCI_PCI_BRIDGE) extern void ARCH_PCI_PCI_BRIDGE(pciConfigPtr pPCI); #endif #if defined(XF86SCANPCI_WRAPPER) typedef enum { SCANPCI_INIT, SCANPCI_TERM } scanpciWrapperOpt; extern void XF86SCANPCI_WRAPPER(scanpciWrapperOpt flags); #endif /* * Table of functions used to access a specific PCI bus domain * (e.g. a primary PCI bus and all of its secondaries) */ typedef struct pci_bus_funcs { CARD32 (*pciReadLong)(PCITAG, int); void (*pciWriteLong)(PCITAG, int, CARD32); void (*pciSetBitsLong)(PCITAG, int, CARD32, CARD32); ADDRESS (*pciAddrHostToBus)(PCITAG, PciAddrType, ADDRESS); ADDRESS (*pciAddrBusToHost)(PCITAG, PciAddrType, ADDRESS); /* * The next three are optional. If NULL, the corresponding function is * to be performed generically. */ CARD16 (*pciControlBridge)(int, CARD16, CARD16); void (*pciGetBridgeBuses)(int, int *, int *, int *); /* Use pointer's to avoid #include recursion */ void (*pciGetBridgeResources)(int, pointer *, pointer *, pointer *); } pciBusFuncs_t, *pciBusFuncs_p; /* * pciBusInfo_t - One structure per defined PCI bus */ typedef struct pci_bus_info { unsigned char configMech; /* PCI config type to use */ unsigned char numDevices; /* Range of valid devnums */ unsigned char secondary; /* Boolean: bus is a secondary */ int primary_bus; /* Parent bus */ #ifdef PowerMAX_OS unsigned long ppc_io_base; /* PowerPC I/O spc membase */ unsigned long ppc_io_size; /* PowerPC I/O spc size */ #endif pciBusFuncs_p funcs; /* PCI access functions */ void *pciBusPriv; /* Implementation private data */ pciConfigPtr bridge; /* bridge that opens this bus */ } pciBusInfo_t; #define HOST_NO_BUS ((pciBusInfo_t *)(-1)) /* configMech values */ #define PCI_CFG_MECH_UNKNOWN 0 /* Not yet known */ #define PCI_CFG_MECH_1 1 /* Most machines */ #define PCI_CFG_MECH_2 2 /* Older PC's */ #define PCI_CFG_MECH_OTHER 3 /* Something else */ /* Generic PCI service functions and helpers */ PCITAG pciGenFindFirst(void); PCITAG pciGenFindNext(void); CARD32 pciCfgMech1Read(PCITAG tag, int offset); void pciCfgMech1Write(PCITAG tag, int offset, CARD32 val); void pciCfgMech1SetBits(PCITAG tag, int offset, CARD32 mask, CARD32 val); CARD32 pciByteSwap(CARD32); Bool pciMfDev(int, int); ADDRESS pciAddrNOOP(PCITAG tag, PciAddrType type, ADDRESS); extern PCITAG (*pciFindFirstFP)(void); extern PCITAG (*pciFindNextFP)(void); extern CARD32 pciDevid; extern CARD32 pciDevidMask; extern int pciMaxBusNum; extern int pciBusNum; extern int pciDevNum; extern int pciFuncNum; extern PCITAG pciDeviceTag; extern pciBusInfo_t *pciBusInfo[]; #endif /* _PCI_H */ --------------050908010206090008020205 Content-Type: text/plain; name="freebsdPci.c" Content-Transfer-Encoding: 7bit Content-Disposition: inline; filename="freebsdPci.c" /* $XFree86: xc/programs/Xserver/hw/xfree86/os-support/bus/freebsdPci.c,v 1.5 2002/08/27 22:07:07 tsi Exp $ */ /* * Copyright 1998 by Concurrent Computer Corporation * * Permission to use, copy, modify, distribute, and sell this software * and its documentation for any purpose is hereby granted without fee, * provided that the above copyright notice appear in all copies and that * both that copyright notice and this permission notice appear in * supporting documentation, and that the name of Concurrent Computer * Corporation not be used in advertising or publicity pertaining to * distribution of the software without specific, written prior * permission. Concurrent Computer Corporation makes no representations * about the suitability of this software for any purpose. It is * provided "as is" without express or implied warranty. * * CONCURRENT COMPUTER CORPORATION DISCLAIMS ALL WARRANTIES WITH REGARD * TO THIS SOFTWARE, INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY * AND FITNESS, IN NO EVENT SHALL CONCURRENT COMPUTER CORPORATION BE * LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY * DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, * WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, * ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS * SOFTWARE. * * Copyright 1998 by Metro Link Incorporated * * Permission to use, copy, modify, distribute, and sell this software * and its documentation for any purpose is hereby granted without fee, * provided that the above copyright notice appear in all copies and that * both that copyright notice and this permission notice appear in * supporting documentation, and that the name of Metro Link * Incorporated not be used in advertising or publicity pertaining to * distribution of the software without specific, written prior * permission. Metro Link Incorporated makes no representations * about the suitability of this software for any purpose. It is * provided "as is" without express or implied warranty. * * METRO LINK INCORPORATED DISCLAIMS ALL WARRANTIES WITH REGARD * TO THIS SOFTWARE, INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY * AND FITNESS, IN NO EVENT SHALL METRO LINK INCORPORATED BE * LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY * DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, * WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, * ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS * SOFTWARE. */ #include #include "compiler.h" #include "xf86.h" #include "xf86Priv.h" #include "xf86_OSlib.h" #include "Pci.h" #include /* * freebsd platform specific PCI access functions -- using /dev/pci * needs kernel version 2.2.x */ static CARD32 freebsdPciCfgRead(PCITAG tag, int off); static void freebsdPciCfgWrite(PCITAG, int off, CARD32 val); static void freebsdPciCfgSetBits(PCITAG tag, int off, CARD32 mask, CARD32 bits); static pciBusFuncs_t freebsdFuncs0 = { /* pciReadLong */ freebsdPciCfgRead, /* pciWriteLong */ freebsdPciCfgWrite, /* pciSetBitsLong */ freebsdPciCfgSetBits, /* pciAddrHostToBus */ pciAddrNOOP, /* pciAddrBusToHost */ pciAddrNOOP }; static pciBusInfo_t freebsdPci0 = { /* configMech */ PCI_CFG_MECH_OTHER, /* numDevices */ 32, /* secondary */ FALSE, /* primary_bus */ 0, #ifdef PowerMAX_OS /* ppc_io_base */ 0, /* ppc_io_size */ 0, #endif /* funcs */ &freebsdFuncs0, /* pciBusPriv */ NULL, /* bridge */ NULL }; #if !defined(__OpenBSD__) #if X_BYTE_ORDER == X_BIG_ENDIAN #ifdef __sparc__ #ifndef ASI_PL #define ASI_PL 0x88 #endif #define PCI_CPU(val) ({ \ int __ret; \ __asm__ __volatile__("lduwa [%1] %2, %0" : "=r" (__ret) : "r" (&val), "i" (ASI_PL)); \ __ret; \ }) #else #define PCI_CPU(val) (((val >> 24) & 0x000000ff) | \ ((val >> 8) & 0x0000ff00) | \ ((val << 8) & 0x00ff0000) | \ ((val << 24) & 0xff000000)) #endif #else #define PCI_CPU(val) (val) #endif #else /* ! OpenBSD */ /* OpenBSD has already the bytes in the right order for all architectures */ #define PCI_CPU(val) (val) #endif #define BUS(tag) (((tag)>>16)&0xff) #define DFN(tag) (((tag)>>8)&0xff) static int pciFd = -1; void freebsdPciInit() { pciFd = open("/dev/pci", O_RDWR); if (pciFd < 0) return; pciNumBuses = 1; pciBusInfo[0] = &freebsdPci0; pciFindFirstFP = pciGenFindFirst; pciFindNextFP = pciGenFindNext; } static CARD32 freebsdPciCfgRead(PCITAG tag, int off) { struct pci_io io; int error; io.pi_sel.pc_bus = BUS(tag); io.pi_sel.pc_dev = DFN(tag) >> 3; io.pi_sel.pc_func = DFN(tag) & 7; io.pi_reg = off; io.pi_width = 4; error = ioctl(pciFd, PCIOCREAD, &io); if (error) return ~0; return PCI_CPU(io.pi_data); } static void freebsdPciCfgWrite(PCITAG tag, int off, CARD32 val) { struct pci_io io; io.pi_sel.pc_bus = BUS(tag); io.pi_sel.pc_dev = DFN(tag) >> 3; io.pi_sel.pc_func = DFN(tag) & 7; io.pi_reg = off; io.pi_width = 4; io.pi_data = PCI_CPU(val); ioctl(pciFd, PCIOCWRITE, &io); } static void freebsdPciCfgSetBits(PCITAG tag, int off, CARD32 mask, CARD32 bits) { CARD32 val = freebsdPciCfgRead(tag, off); val = (val & ~mask) | (bits & mask); freebsdPciCfgWrite(tag, off, val); } --------------050908010206090008020205-- From owner-freebsd-alpha@FreeBSD.ORG Tue Jan 6 15:36:59 2004 Return-Path: Delivered-To: freebsd-alpha@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id B498416A4CE for ; Tue, 6 Jan 2004 15:36:59 -0800 (PST) Received: from mail3.speakeasy.net (mail3.speakeasy.net [216.254.0.203]) by mx1.FreeBSD.org (Postfix) with ESMTP id CEABE43D1D for ; Tue, 6 Jan 2004 15:36:58 -0800 (PST) (envelope-from jhb@FreeBSD.org) Received: (qmail 9829 invoked from network); 6 Jan 2004 23:36:57 -0000 Received: from dsl027-160-063.atl1.dsl.speakeasy.net (HELO server.baldwin.cx) ([216.27.160.63]) (envelope-sender ) encrypted SMTP for ; 6 Jan 2004 23:36:57 -0000 Received: from atl544379.corp.weather.com (gw1.twc.weather.com [216.133.140.1]) by server.baldwin.cx (8.12.10/8.12.10) with ESMTP id i06NaqM0028121 for ; Tue, 6 Jan 2004 18:36:52 -0500 (EST) (envelope-from jhb@FreeBSD.org) From: John Baldwin To: alpha@FreeBSD.org Date: Tue, 6 Jan 2004 18:37:34 -0500 User-Agent: KMail/1.5.4 MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Content-Disposition: inline Message-Id: <200401061837.34574.jhb@FreeBSD.org> X-Spam-Checker-Version: SpamAssassin 2.55 (1.174.2.19-2003-05-19-exp) Subject: [PATCH] SMP cosmetic cleanups X-BeenThere: freebsd-alpha@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Porting FreeBSD to the Alpha List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 06 Jan 2004 23:36:59 -0000 Can someone please test http://www.FreeBSD.org/~jhb/patches/alpha_smp.patch in an SMP kernel on an SMP alpha machine to make sure it still boots and runs SMP ok? Thanks. -- John Baldwin <>< http://www.FreeBSD.org/~jhb/ "Power Users Use the Power to Serve" = http://www.FreeBSD.org From owner-freebsd-alpha@FreeBSD.ORG Wed Jan 7 14:42:37 2004 Return-Path: Delivered-To: freebsd-alpha@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 8DF3916A4CE; Wed, 7 Jan 2004 14:42:37 -0800 (PST) Received: from niobe.ijs.si (mail.ijs.si [193.2.4.66]) by mx1.FreeBSD.org (Postfix) with ESMTP id 04B9743D1D; Wed, 7 Jan 2004 14:42:36 -0800 (PST) (envelope-from dejan.lesjak@ijs.si) Received: from localhost (localhost.ijs.si [127.0.0.1]) by niobe.ijs.si (Postfix) with ESMTP id A2B991DDC78; Wed, 7 Jan 2004 23:42:34 +0100 (CET) Received: from niobe.ijs.si ([193.2.4.66]) by localhost (niobe.ijs.si [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 10209-10; Wed, 7 Jan 2004 23:42:33 +0100 (CET) Received: from rincewind.ijs.si (rincewind.ijs.si [193.2.4.137]) by niobe.ijs.si (Postfix) with ESMTP id 576C41DDC6B; Wed, 7 Jan 2004 23:42:33 +0100 (CET) From: Dejan Lesjak To: John Baldwin Date: Wed, 7 Jan 2004 23:42:32 +0100 User-Agent: KMail/1.5.94 MIME-Version: 1.0 Content-Disposition: inline Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Message-Id: <200401072342.32782.dejan.lesjak@ijs.si> X-Virus-Scanned: by amavisd-new / Sophos+Sophie at ijs.si cc: freebsd-alpha@freebsd.org Subject: Re: [PATCH] SMP cosmetic cleanups X-BeenThere: freebsd-alpha@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Porting FreeBSD to the Alpha List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 07 Jan 2004 22:42:37 -0000 John Baldwin wrote: > Can someone please test > http://www.FreeBSD.org/~jhb/patches/alpha_smp.patch in an SMP kernel on an > SMP alpha machine to make sure it still boots and runs > SMP ok? Thanks. > It boots and runs (ie it made through buildworld) on dual EV67 264DP/UP2000. Dejan From owner-freebsd-alpha@FreeBSD.ORG Wed Jan 7 15:04:50 2004 Return-Path: Delivered-To: freebsd-alpha@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 1A27B16A4CE for ; Wed, 7 Jan 2004 15:04:50 -0800 (PST) Received: from mail6.speakeasy.net (mail6.speakeasy.net [216.254.0.206]) by mx1.FreeBSD.org (Postfix) with ESMTP id 0AEFE43D5A for ; Wed, 7 Jan 2004 15:04:49 -0800 (PST) (envelope-from jhb@FreeBSD.org) Received: (qmail 17530 invoked from network); 7 Jan 2004 23:04:48 -0000 Received: from dsl027-160-063.atl1.dsl.speakeasy.net (HELO server.baldwin.cx) ([216.27.160.63]) (envelope-sender ) encrypted SMTP for ; 7 Jan 2004 23:04:48 -0000 Received: from 10.50.40.206 (gw1.twc.weather.com [216.133.140.1]) by server.baldwin.cx (8.12.10/8.12.10) with ESMTP id i07N4hM0033723; Wed, 7 Jan 2004 18:04:43 -0500 (EST) (envelope-from jhb@FreeBSD.org) From: John Baldwin To: Dejan Lesjak Date: Wed, 7 Jan 2004 18:01:30 -0500 User-Agent: KMail/1.5.4 References: <200401072342.32782.dejan.lesjak@ijs.si> In-Reply-To: <200401072342.32782.dejan.lesjak@ijs.si> MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit Content-Disposition: inline Message-Id: <200401071801.30570.jhb@FreeBSD.org> X-Spam-Checker-Version: SpamAssassin 2.55 (1.174.2.19-2003-05-19-exp) cc: freebsd-alpha@freebsd.org Subject: Re: [PATCH] SMP cosmetic cleanups X-BeenThere: freebsd-alpha@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Porting FreeBSD to the Alpha List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 07 Jan 2004 23:04:50 -0000 On Wednesday 07 January 2004 05:42 pm, Dejan Lesjak wrote: > John Baldwin wrote: > > Can someone please test > > http://www.FreeBSD.org/~jhb/patches/alpha_smp.patch in an SMP kernel on > > an SMP alpha machine to make sure it still boots and runs > > SMP ok? Thanks. > > It boots and runs (ie it made through buildworld) on dual EV67 > 264DP/UP2000. Thanks! Committed. -- John Baldwin <>< http://www.FreeBSD.org/~jhb/ "Power Users Use the Power to Serve" = http://www.FreeBSD.org From owner-freebsd-alpha@FreeBSD.ORG Thu Jan 8 12:14:22 2004 Return-Path: Delivered-To: freebsd-alpha@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 9A12616A4CE for ; Thu, 8 Jan 2004 12:14:22 -0800 (PST) Received: from smtp.des.no (flood.des.no [217.116.83.31]) by mx1.FreeBSD.org (Postfix) with ESMTP id 91C7643D46 for ; Thu, 8 Jan 2004 12:14:18 -0800 (PST) (envelope-from des@des.no) Received: by smtp.des.no (Pony Express, from userid 666) id 40B01530D; Thu, 8 Jan 2004 21:14:17 +0100 (CET) Received: from dwp.des.no (des.no [80.203.228.37]) by smtp.des.no (Pony Express) with ESMTP id 5ABCF530C for ; Thu, 8 Jan 2004 21:14:10 +0100 (CET) Received: by dwp.des.no (Postfix, from userid 2602) id 3D90433C9A; Thu, 8 Jan 2004 21:14:10 +0100 (CET) To: alpha@freebsd.org From: des@des.no (Dag-Erling =?iso-8859-1?q?Sm=F8rgrav?=) Date: Thu, 08 Jan 2004 21:14:10 +0100 Message-ID: User-Agent: Gnus/5.090024 (Oort Gnus v0.24) Emacs/21.3 (berkeley-unix) MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: quoted-printable X-Spam-Checker-Version: SpamAssassin 2.60 (1.212-2003-09-23-exp) on flood.des.no X-Spam-Level: X-Spam-Status: No, hits=0.1 required=5.0 tests=RCVD_IN_SORBS autolearn=no version=2.60 Subject: structure padding X-BeenThere: freebsd-alpha@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Porting FreeBSD to the Alpha List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 08 Jan 2004 20:14:22 -0000 In -STABLE, struct kinfo_proc is currently defined as follows: struct kinfo_proc { struct proc kp_proc; struct eproc { /* ... */ char e_login[roundup(MAXLOGNAME, sizeof(long))]; long e_spare[2]; } kp_eproc; }; I want to add an e_sid field to hold the process's session ID: struct kinfo_proc { struct proc kp_proc; struct eproc { /* ... */ char e_login[roundup(MAXLOGNAME, sizeof(long))]; pid_t e_sid; long e_spare[1]; } kp_eproc; }; However, a pid_t is an int, and sizeof int !=3D sizeof long on Alpha. I'm not sure what will happen: will alignment rules cause gcc to add four bytes of padding before e_spare, conserving the size of struct kinfo_proc, or will struct kinfo_proc shrink by four bytes? DES --=20 Dag-Erling Sm=F8rgrav - des@des.no From owner-freebsd-alpha@FreeBSD.ORG Thu Jan 8 13:24:13 2004 Return-Path: Delivered-To: freebsd-alpha@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id AFD0416A4CE for ; Thu, 8 Jan 2004 13:24:13 -0800 (PST) Received: from mail3.speakeasy.net (mail3.speakeasy.net [216.254.0.203]) by mx1.FreeBSD.org (Postfix) with ESMTP id AE95143D3F for ; Thu, 8 Jan 2004 13:24:11 -0800 (PST) (envelope-from jhb@FreeBSD.org) Received: (qmail 7533 invoked from network); 8 Jan 2004 21:24:11 -0000 Received: from dsl027-160-063.atl1.dsl.speakeasy.net (HELO server.baldwin.cx) ([216.27.160.63]) (envelope-sender ) encrypted SMTP for ; 8 Jan 2004 21:24:11 -0000 Received: from 10.50.40.206 (gw1.twc.weather.com [216.133.140.1]) by server.baldwin.cx (8.12.10/8.12.10) with ESMTP id i08LO1M4039230; Thu, 8 Jan 2004 16:24:07 -0500 (EST) (envelope-from jhb@FreeBSD.org) From: John Baldwin To: des@des.no (Dag-Erling =?iso-8859-1?q?Sm=F8rgrav?=), alpha@freebsd.org Date: Thu, 8 Jan 2004 15:42:49 -0500 User-Agent: KMail/1.5.4 References: In-Reply-To: MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Content-Disposition: inline Message-Id: <200401081542.49500.jhb@FreeBSD.org> X-Spam-Checker-Version: SpamAssassin 2.55 (1.174.2.19-2003-05-19-exp) Subject: Re: structure padding X-BeenThere: freebsd-alpha@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Porting FreeBSD to the Alpha List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 08 Jan 2004 21:24:13 -0000 On Thursday 08 January 2004 03:14 pm, Dag-Erling Sm=F8rgrav wrote: > In -STABLE, struct kinfo_proc is currently defined as follows: > > struct kinfo_proc { > struct proc kp_proc; > struct eproc { > /* ... */ > char e_login[roundup(MAXLOGNAME, sizeof(long))]; > long e_spare[2]; > } kp_eproc; > }; > > I want to add an e_sid field to hold the process's session ID: > > struct kinfo_proc { > struct proc kp_proc; > struct eproc { > /* ... */ > char e_login[roundup(MAXLOGNAME, sizeof(long))]; > pid_t e_sid; > long e_spare[1]; > } kp_eproc; > }; > > However, a pid_t is an int, and sizeof int !=3D sizeof long on Alpha. > I'm not sure what will happen: will alignment rules cause gcc to add > four bytes of padding before e_spare, conserving the size of struct > kinfo_proc, or will struct kinfo_proc shrink by four bytes? Maybe: struct eproc { union { pid_t e_sid; long e_oldspare; } long e_spare[1]; (I think gcc supports anonymous unions like that.) In 6.0 you could remove the union hack and change the ABI, assuming that yo= u=20 want to put this in 5.x as well. =2D-=20 John Baldwin <>< http://www.FreeBSD.org/~jhb/ "Power Users Use the Power to Serve" =3D http://www.FreeBSD.org From owner-freebsd-alpha@FreeBSD.ORG Thu Jan 8 13:28:22 2004 Return-Path: Delivered-To: freebsd-alpha@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 999DF16A4CE; Thu, 8 Jan 2004 13:28:22 -0800 (PST) Received: from smtp.des.no (flood.des.no [217.116.83.31]) by mx1.FreeBSD.org (Postfix) with ESMTP id 361C443D60; Thu, 8 Jan 2004 13:28:20 -0800 (PST) (envelope-from des@des.no) Received: by smtp.des.no (Pony Express, from userid 666) id 71C9B530C; Thu, 8 Jan 2004 22:28:19 +0100 (CET) Received: from dwp.des.no (des.no [80.203.228.37]) by smtp.des.no (Pony Express) with ESMTP id 9168F5308; Thu, 8 Jan 2004 22:28:12 +0100 (CET) Received: by dwp.des.no (Postfix, from userid 2602) id 20B8F33C9A; Thu, 8 Jan 2004 22:28:12 +0100 (CET) To: John Baldwin References: <200401081542.49500.jhb@FreeBSD.org> From: des@des.no (Dag-Erling =?iso-8859-1?q?Sm=F8rgrav?=) Date: Thu, 08 Jan 2004 22:28:12 +0100 In-Reply-To: <200401081542.49500.jhb@FreeBSD.org> (John Baldwin's message of "Thu, 8 Jan 2004 15:42:49 -0500") Message-ID: User-Agent: Gnus/5.090024 (Oort Gnus v0.24) Emacs/21.3 (berkeley-unix) MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: quoted-printable X-Spam-Checker-Version: SpamAssassin 2.60 (1.212-2003-09-23-exp) on flood.des.no X-Spam-Level: X-Spam-Status: No, hits=0.1 required=5.0 tests=RCVD_IN_SORBS autolearn=no version=2.60 cc: alpha@freebsd.org Subject: Re: structure padding X-BeenThere: freebsd-alpha@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Porting FreeBSD to the Alpha List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 08 Jan 2004 21:28:22 -0000 John Baldwin writes: > Maybe: > > struct eproc { > union { > pid_t e_sid; > long e_oldspare; > } > long e_spare[1]; > > (I think gcc supports anonymous unions like that.) I thought about that, but it's butt-ugly... Does anyone have an Alpha running 4.x that I could test this on? > In 6.0 you could remove the union hack and change the ABI, assuming that = you=20 > want to put this in 5.x as well. 5.x has a completely different struct kinfo_proc which already contains the session id. DES --=20 Dag-Erling Sm=F8rgrav - des@des.no From owner-freebsd-alpha@FreeBSD.ORG Thu Jan 8 13:48:34 2004 Return-Path: Delivered-To: freebsd-alpha@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id A917716A4E1 for ; Thu, 8 Jan 2004 13:48:34 -0800 (PST) Received: from mail1.speakeasy.net (mail1.speakeasy.net [216.254.0.201]) by mx1.FreeBSD.org (Postfix) with ESMTP id 5E94043D5D for ; Thu, 8 Jan 2004 13:48:32 -0800 (PST) (envelope-from jhb@FreeBSD.org) Received: (qmail 17625 invoked from network); 8 Jan 2004 21:48:31 -0000 Received: from dsl027-160-063.atl1.dsl.speakeasy.net (HELO server.baldwin.cx) ([216.27.160.63]) (envelope-sender ) encrypted SMTP for ; 8 Jan 2004 21:48:31 -0000 Received: from 10.50.40.206 (gw1.twc.weather.com [216.133.140.1]) by server.baldwin.cx (8.12.10/8.12.10) with ESMTP id i08LmOM0039402; Thu, 8 Jan 2004 16:48:25 -0500 (EST) (envelope-from jhb@FreeBSD.org) From: John Baldwin To: des@des.no (Dag-Erling =?iso-8859-1?q?Sm=F8rgrav?=) Date: Thu, 8 Jan 2004 16:45:23 -0500 User-Agent: KMail/1.5.4 References: <200401081542.49500.jhb@FreeBSD.org> In-Reply-To: MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Content-Disposition: inline Message-Id: <200401081645.24241.jhb@FreeBSD.org> X-Spam-Checker-Version: SpamAssassin 2.55 (1.174.2.19-2003-05-19-exp) cc: alpha@freebsd.org Subject: Re: structure padding X-BeenThere: freebsd-alpha@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Porting FreeBSD to the Alpha List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 08 Jan 2004 21:48:34 -0000 On Thursday 08 January 2004 04:28 pm, Dag-Erling Sm=F8rgrav wrote: > John Baldwin writes: > > Maybe: > > > > struct eproc { > > union { > > pid_t e_sid; > > long e_oldspare; > > } > > long e_spare[1]; > > > > (I think gcc supports anonymous unions like that.) > > I thought about that, but it's butt-ugly... > > Does anyone have an Alpha running 4.x that I could test this on? > > > In 6.0 you could remove the union hack and change the ABI, assuming that > > you want to put this in 5.x as well. > > 5.x has a completely different struct kinfo_proc which already > contains the session id. Actually, why not just use a long for the e_sid instead of pid_t? A long w= ill=20 certainly fit a pid_t. Doesn't hurt for it to be too big. So just: char e_comm[] long e_sid; long e_spare; =2D-=20 John Baldwin <>< http://www.FreeBSD.org/~jhb/ "Power Users Use the Power to Serve" =3D http://www.FreeBSD.org From owner-freebsd-alpha@FreeBSD.ORG Thu Jan 8 14:03:23 2004 Return-Path: Delivered-To: freebsd-alpha@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id E0FC816A4CE; Thu, 8 Jan 2004 14:03:23 -0800 (PST) Received: from smtp.des.no (flood.des.no [217.116.83.31]) by mx1.FreeBSD.org (Postfix) with ESMTP id BA09E43D58; Thu, 8 Jan 2004 14:03:22 -0800 (PST) (envelope-from des@des.no) Received: by smtp.des.no (Pony Express, from userid 666) id 846C3530C; Thu, 8 Jan 2004 23:03:21 +0100 (CET) Received: from dwp.des.no (des.no [80.203.228.37]) by smtp.des.no (Pony Express) with ESMTP id D41985308; Thu, 8 Jan 2004 23:03:14 +0100 (CET) Received: by dwp.des.no (Postfix, from userid 2602) id 95D3B33C9A; Thu, 8 Jan 2004 23:03:14 +0100 (CET) To: John Baldwin References: <200401081542.49500.jhb@FreeBSD.org> <200401081645.24241.jhb@FreeBSD.org> From: des@des.no (Dag-Erling =?iso-8859-1?q?Sm=F8rgrav?=) Date: Thu, 08 Jan 2004 23:03:14 +0100 In-Reply-To: <200401081645.24241.jhb@FreeBSD.org> (John Baldwin's message of "Thu, 8 Jan 2004 16:45:23 -0500") Message-ID: User-Agent: Gnus/5.090024 (Oort Gnus v0.24) Emacs/21.3 (berkeley-unix) MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: quoted-printable X-Spam-Checker-Version: SpamAssassin 2.60 (1.212-2003-09-23-exp) on flood.des.no X-Spam-Level: X-Spam-Status: No, hits=0.1 required=5.0 tests=RCVD_IN_SORBS autolearn=no version=2.60 cc: alpha@freebsd.org Subject: Re: structure padding X-BeenThere: freebsd-alpha@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Porting FreeBSD to the Alpha List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 08 Jan 2004 22:03:24 -0000 John Baldwin writes: > Actually, why not just use a long for the e_sid instead of pid_t? I got off my fat lazy butt and wrote the following: #include struct foo { int a; long b; }; struct bar { long a[2]; }; int main(void) { printf("%lu, %lu\n", sizeof(struct foo), sizeof(struct bar)); return (0); } On Alpha (-CURRENT, though, not -STABLE) it prints 16 for both structures, so it looks like I don't need any hack at all. DES --=20 Dag-Erling Sm=F8rgrav - des@des.no From owner-freebsd-alpha@FreeBSD.ORG Thu Jan 8 14:24:05 2004 Return-Path: Delivered-To: freebsd-alpha@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id E197516A4CE for ; Thu, 8 Jan 2004 14:24:05 -0800 (PST) Received: from ns1.xcllnt.net (209-128-86-226.BAYAREA.NET [209.128.86.226]) by mx1.FreeBSD.org (Postfix) with ESMTP id C40C443D31 for ; Thu, 8 Jan 2004 14:24:04 -0800 (PST) (envelope-from marcel@xcllnt.net) Received: from ns1.xcllnt.net (localhost [127.0.0.1]) by ns1.xcllnt.net (8.12.10/8.12.10) with ESMTP id i08MO2OE071127; Thu, 8 Jan 2004 14:24:02 -0800 (PST) (envelope-from marcel@ns1.xcllnt.net) Received: (from marcel@localhost) by ns1.xcllnt.net (8.12.10/8.12.10/Submit) id i08MO2DO071126; Thu, 8 Jan 2004 14:24:02 -0800 (PST) (envelope-from marcel) Date: Thu, 8 Jan 2004 14:24:02 -0800 From: Marcel Moolenaar To: Dag-Erling Sm?rgrav Message-ID: <20040108222402.GA71100@ns1.xcllnt.net> References: Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.5.1i cc: alpha@freebsd.org Subject: Re: structure padding X-BeenThere: freebsd-alpha@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Porting FreeBSD to the Alpha List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 08 Jan 2004 22:24:06 -0000 On Thu, Jan 08, 2004 at 09:14:10PM +0100, Dag-Erling Sm?rgrav wrote: > > However, a pid_t is an int, and sizeof int != sizeof long on Alpha. > I'm not sure what will happen: will alignment rules cause gcc to add > four bytes of padding before e_spare, conserving the size of struct > kinfo_proc, or will struct kinfo_proc shrink by four bytes? Padding will happen. -- Marcel Moolenaar USPA: A-39004 marcel@xcllnt.net From owner-freebsd-alpha@FreeBSD.ORG Fri Jan 9 04:15:17 2004 Return-Path: Delivered-To: freebsd-alpha@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 3DFC516A4CE for ; Fri, 9 Jan 2004 04:15:17 -0800 (PST) Received: from pegasus.freiberg-net.de (pegasus.freibergnet.de [80.243.43.9]) by mx1.FreeBSD.org (Postfix) with ESMTP id 61B7043D39 for ; Fri, 9 Jan 2004 04:15:15 -0800 (PST) (envelope-from holm@pegasus.freiberg-net.de) Received: from pegasus.freiberg-net.de (localhost.freiberg-net.de [127.0.0.1]) i09CFD6T057360 for ; Fri, 9 Jan 2004 13:15:13 +0100 (CET) (envelope-from holm@pegasus.freiberg-net.de) Received: (from holm@localhost) by pegasus.freiberg-net.de (8.12.10/8.12.10/Submit) id i09CFDCA057358 for freebsd-alpha@freebsd.org; Fri, 9 Jan 2004 13:15:13 +0100 (CET) (envelope-from holm) Date: Fri, 9 Jan 2004 13:15:13 +0100 From: Holm Tiffe To: freebsd-alpha@freebsd.org Message-ID: <20040109121513.GA57018@pegasus.freiberg-net.de> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.4.1i Organization: FreibergNet Internet Services Priority: normal X-Phone: +49-3731-781279 X-Fax: +49-3731-781377 X-PGP-fingerprint: 86 EC A5 63 B5 28 78 13 8B FC E9 09 04 6E 86 FC Subject: Mysql? X-BeenThere: freebsd-alpha@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list Reply-To: holm@freibergnet.de List-Id: Porting FreeBSD to the Alpha List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 09 Jan 2004 12:15:17 -0000 Hi, has anyone got mysql to work properly on alpha? I've tried mysql-4.0.16 from the ports, 4.0.17, 4.1xx and I've got alsways the same error if I try to connect to the mysqld over tcp: # /usr/local/bin/mysqladmin -u root -h install password 'lolo' /usr/local/bin/mysqladmin: connect to server at 'install' failed error: 'Lost connection to MySQL server during query' the mysqld logs in this moment: pid 65409 (mysqld): unaligned access: va=0x11fff70c pc=0x160389bd4 ra=0x160389bc0 op=stq ll is fine if I connect the daemon over the unix domain socket: # /usr/local/bin/mysqladmin -u root -p password 'lolo' Enter password: (xxxx) # I do'nt think, that this is a FreeBSD issue, it looks like a mysql bug on 64bit Machines.... BTW: PostgreSQL works as expected, but I need mysql. Holm -- L&P::Kommunikation GbR Holm Tiffe * Administration, Development FreibergNet.de Internet Systems phone +49 3731 41930 Bereich Server & Technik fax +49 3731 4196026 D-09599 Freiberg * Nonnengasse 31a http://www.freibergnet.de From owner-freebsd-alpha@FreeBSD.ORG Fri Jan 9 16:52:51 2004 Return-Path: Delivered-To: freebsd-alpha@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 5529716A4CE for ; Fri, 9 Jan 2004 16:52:51 -0800 (PST) Received: from smta06.mail.ozemail.net (smta06.mail.ozemail.net [203.103.165.100]) by mx1.FreeBSD.org (Postfix) with ESMTP id E9D3043D1D for ; Fri, 9 Jan 2004 16:52:48 -0800 (PST) (envelope-from robbyrnes@ozemail.com.au) Received: from cartman ([203.61.129.215]) by smta06.mail.ozemail.net with SMTP id <20040110005042.VOSE5468.smta06.mail.ozemail.net@cartman>; Sat, 10 Jan 2004 00:50:42 +0000 From: Rob To: , X-Mailer: PocoMail 3.03 (1740) - Licensed Version Date: Sat, 10 Jan 2004 11:52:03 +1100 Message-ID: <200411011523.232363@cartman> In-Reply-To: <20040109121513.GA57018@pegasus.freiberg-net.de> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable Subject: Re: Mysql? X-BeenThere: freebsd-alpha@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Porting FreeBSD to the Alpha List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 10 Jan 2004 00:52:51 -0000 On Fri, 9 Jan 2004 13:15:13 +0100, Holm Tiffe wrote: > Hi, > > > has anyone got mysql to work properly on alpha? > > > I've tried mysql-4.0.16 from the ports, 4.0.17, 4.1xx and I've got > alsways the same error if I try to connect to the mysqld over tcp: > > # /usr/local/bin/mysqladmin -u root -h install password 'lolo' > /usr/local/bin/mysqladmin: connect to server at 'install' failed > error: 'Lost connection to MySQL server during query' > > > the mysqld logs in this moment: > > > pid 65409 (mysqld): unaligned access: va=3D0x11fff70c pc=3D0x160389bd4 > ra=3D0x160389bc0 op=3Dstq > > > ll is fine if I connect the daemon over the unix domain socket: > > > # /usr/local/bin/mysqladmin -u root -p password 'lolo' Enter > password: (xxxx) # > > I do'nt think, that this is a FreeBSD issue, it looks like a mysql > bug on 64bit Machines.... > > BTW: PostgreSQL works as expected, but I need mysql. I don't get any unaligned accesses on my Miata, are you building mysql with= any fancy optimisations? loop@erwin ~ % /usr/local/bin/mysqladmin -u root -h localhost -p 'status' Enter password: Uptime: 927362 Threads: 1 Questions: 40716 Slow queries: 0 Opens: 107 Flush tables: 1 Open tables: 49 Queries per second avg: 0.044 loop@erwin ~ % pkg_info | grep mysql mysql-client-4.0.17 Multithreaded SQL database (client) mysql-server-4.0.17 Multithreaded SQL database (server) cheers, Rob From owner-freebsd-alpha@FreeBSD.ORG Sat Jan 10 01:22:05 2004 Return-Path: Delivered-To: freebsd-alpha@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id EFC0616A4CE for ; Sat, 10 Jan 2004 01:22:04 -0800 (PST) Received: from pegasus.freiberg-net.de (pegasus.freibergnet.de [80.243.43.9]) by mx1.FreeBSD.org (Postfix) with ESMTP id E2FB943D58 for ; Sat, 10 Jan 2004 01:21:47 -0800 (PST) (envelope-from holm@pegasus.freiberg-net.de) Received: from pegasus.freiberg-net.de (localhost.freiberg-net.de [127.0.0.1]) i0A9Lk6T000443; Sat, 10 Jan 2004 10:21:46 +0100 (CET) (envelope-from holm@pegasus.freiberg-net.de) Received: (from holm@localhost) by pegasus.freiberg-net.de (8.12.10/8.12.10/Submit) id i0A9Lj9N000441; Sat, 10 Jan 2004 10:21:45 +0100 (CET) (envelope-from holm) Date: Sat, 10 Jan 2004 10:21:45 +0100 From: Holm Tiffe To: Rob Message-ID: <20040110092145.GA118@pegasus.freiberg-net.de> References: <20040109121513.GA57018@pegasus.freiberg-net.de> <200411011523.232363@cartman> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <200411011523.232363@cartman> User-Agent: Mutt/1.4.1i Organization: FreibergNet Internet Services Priority: normal X-Phone: +49-3731-781279 X-Fax: +49-3731-781377 X-PGP-fingerprint: 86 EC A5 63 B5 28 78 13 8B FC E9 09 04 6E 86 FC cc: freebsd-alpha@freebsd.org Subject: Re: Mysql? X-BeenThere: freebsd-alpha@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list Reply-To: holm@freibergnet.de List-Id: Porting FreeBSD to the Alpha List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 10 Jan 2004 09:22:05 -0000 Rob wrote: > On Fri, 9 Jan 2004 13:15:13 +0100, Holm Tiffe wrote: > > Hi, > > > > > > has anyone got mysql to work properly on alpha? > > > > > > I've tried mysql-4.0.16 from the ports, 4.0.17, 4.1xx and I've got > > alsways the same error if I try to connect to the mysqld over tcp: > > > > # /usr/local/bin/mysqladmin -u root -h install password 'lolo' > > /usr/local/bin/mysqladmin: connect to server at 'install' failed > > error: 'Lost connection to MySQL server during query' > > > > > > the mysqld logs in this moment: > > > > > > pid 65409 (mysqld): unaligned access: va=0x11fff70c pc=0x160389bd4 > > ra=0x160389bc0 op=stq > > > > > > ll is fine if I connect the daemon over the unix domain socket: > > > > > > # /usr/local/bin/mysqladmin -u root -p password 'lolo' Enter > > password: (xxxx) # > > > > I do'nt think, that this is a FreeBSD issue, it looks like a mysql > > bug on 64bit Machines.... > > > > BTW: PostgreSQL works as expected, but I need mysql. > > I don't get any unaligned accesses on my Miata, are you building mysql with > any fancy optimisations? > > loop@erwin ~ % /usr/local/bin/mysqladmin -u root -h localhost -p 'status' > Enter password: > Uptime: 927362 Threads: 1 Questions: 40716 Slow queries: 0 Opens: 107 > Flush tables: 1 Open tables: 49 Queries per second avg: 0.044 > > loop@erwin ~ % pkg_info | grep mysql > mysql-client-4.0.17 Multithreaded SQL database (client) > mysql-server-4.0.17 Multithreaded SQL database (server) > > cheers, > Rob > I think this worky on my miata too: # /usr/local/bin/mysqladmin -u root -h localhost -p 'status' Enter password: Uptime: 87195 Threads: 1 Questions: 14 Slow queries: 0 Opens: 12 Flush tables: 1 Open tables: 6 Queries per second avg: 0.000 The Problem is occuring here, when I use the real hostname for the connections I'm unable to set the passwd for the empty root account. #/usr/local/bin/mysqladmin -u root -h install 'status' /usr/local/bin/mysqladmin: connect to server at 'install' failed error: 'Lost connection to MySQL server during query' 'install' is the hostname of the machine. (DNS entry used to install several machines, I'm changing the hostname later) In the /var/log/messages you can read this after the try: Jan 10 10:16:42 install mysqld[69662]: warning: can't get client address: Bad file descriptor and on stdout of mysqld the message about the unaligned access. There are no fancy optimisations used. Greetings, Holm -- L&P::Kommunikation GbR Holm Tiffe * Administration, Development FreibergNet.de Internet Systems phone +49 3731 41930 Bereich Server & Technik fax +49 3731 4196026 D-09599 Freiberg * Nonnengasse 31a http://www.freibergnet.de From owner-freebsd-alpha@FreeBSD.ORG Sat Jan 10 09:39:46 2004 Return-Path: Delivered-To: freebsd-alpha@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 309C716A4CE; Sat, 10 Jan 2004 09:39:46 -0800 (PST) Received: from cueball.rtp.FreeBSD.org (cueball.rtp.FreeBSD.org [192.58.184.37]) by mx1.FreeBSD.org (Postfix) with ESMTP id ADB9443D4C; Sat, 10 Jan 2004 09:39:44 -0800 (PST) (envelope-from des+tinderbox@freebsd.org) Received: from cueball.rtp.FreeBSD.org (localhost [127.0.0.1]) i0AHdhv9030813; Sat, 10 Jan 2004 12:39:43 -0500 (EST) (envelope-from des+tinderbox@freebsd.org) Received: (from des@localhost) by cueball.rtp.FreeBSD.org (8.12.9/8.12.9/Submit) id i0AHdhUC030812; Sat, 10 Jan 2004 12:39:43 -0500 (EST) (envelope-from des+tinderbox@freebsd.org) Date: Sat, 10 Jan 2004 12:39:43 -0500 (EST) Message-Id: <200401101739.i0AHdhUC030812@cueball.rtp.FreeBSD.org> X-Authentication-Warning: cueball.rtp.FreeBSD.org: des set sender to Tinderbox using -f Sender: Tinderbox From: Tinderbox To: current@freebsd.org, alpha@freebsd.org Precedence: bulk Subject: [current tinderbox] failure on alpha/alpha X-BeenThere: freebsd-alpha@freebsd.org X-Mailman-Version: 2.1.1 List-Id: Porting FreeBSD to the Alpha List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 10 Jan 2004 17:39:46 -0000 TB --- 2004-01-10 17:00:00 - tinderbox 2.2 running on cueball.rtp.FreeBSD.org TB --- 2004-01-10 17:00:00 - starting CURRENT tinderbox run for alpha/alpha TB --- 2004-01-10 17:00:00 - checking out the source tree TB --- cd /home/des/tinderbox/CURRENT/alpha/alpha TB --- /usr/bin/cvs -f -R -q -d/home/ncvs update -Pd -A src TB --- 2004-01-10 17:05:04 - building world TB --- cd /home/des/tinderbox/CURRENT/alpha/alpha/src TB --- /usr/bin/make -B buildworld >>> Rebuilding the temporary build tree >>> stage 1.1: legacy release compatibility shims >>> stage 1.2: bootstrap tools >>> stage 2.1: cleaning up the object tree >>> stage 2.2: rebuilding the object tree >>> stage 2.3: build tools >>> stage 3: cross tools >>> stage 4.1: building includes >>> stage 4.2: building libraries [...] building shared library libgeom.so.2 ===> lib/libio cc -O -pipe -mcpu=ev4 -mtune=ev5 -mieee -Wall -Wa,-mev56 -c /vol/vol1/users/des/tinderbox/CURRENT/alpha/alpha/src/lib/libio/io.c cc -O -pipe -mcpu=ev4 -mtune=ev5 -mieee -Wall -Wa,-mev56 -c /vol/vol1/users/des/tinderbox/CURRENT/alpha/alpha/src/lib/libio/swiz.c cc -O -pipe -mcpu=ev4 -mtune=ev5 -mieee -Wall -Wa,-mev56 -c /vol/vol1/users/des/tinderbox/CURRENT/alpha/alpha/src/lib/libio/bwx.c cc -O -pipe -mcpu=ev4 -mtune=ev5 -mieee -Wall -Wa,-mev56 -c /vol/vol1/users/des/tinderbox/CURRENT/alpha/alpha/src/lib/libio/alpha_sethae.c /vol/vol1/users/des/tinderbox/CURRENT/alpha/alpha/src/lib/libio/alpha_sethae.c:34: error: conflicting types for `sysarch' /home/des/tinderbox/CURRENT/alpha/alpha/obj/alpha/vol/vol1/users/des/tinderbox/CURRENT/alpha/alpha/src/i386/usr/include/machine/sysarch.h:55: error: previous declaration of `sysarch' *** Error code 1 Stop in /vol/vol1/users/des/tinderbox/CURRENT/alpha/alpha/src/lib/libio. *** Error code 1 Stop in /vol/vol1/users/des/tinderbox/CURRENT/alpha/alpha/src/lib. *** Error code 1 Stop in /vol/vol1/users/des/tinderbox/CURRENT/alpha/alpha/src. *** Error code 1 Stop in /vol/vol1/users/des/tinderbox/CURRENT/alpha/alpha/src. *** Error code 1 Stop in /vol/vol1/users/des/tinderbox/CURRENT/alpha/alpha/src. *** Error code 1 Stop in /vol/vol1/users/des/tinderbox/CURRENT/alpha/alpha/src. TB --- 2004-01-10 17:39:43 - TB --- /usr/bin/make returned exit code 1 TB --- 2004-01-10 17:39:43 - TB --- ERROR: failed to build world TB --- 2004-01-10 17:39:43 - tinderbox aborted From owner-freebsd-alpha@FreeBSD.ORG Sat Jan 10 10:38:47 2004 Return-Path: Delivered-To: freebsd-alpha@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id C943F16A4CE; Sat, 10 Jan 2004 10:38:47 -0800 (PST) Received: from gw.celabo.org (gw.celabo.org [208.42.49.153]) by mx1.FreeBSD.org (Postfix) with ESMTP id 7F81643D2D; Sat, 10 Jan 2004 10:38:46 -0800 (PST) (envelope-from nectar@celabo.org) Received: from madman.celabo.org (madman.celabo.org [10.0.1.111]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client CN "madman.celabo.org", Issuer "celabo.org CA" (verified OK)) by gw.celabo.org (Postfix) with ESMTP id 2ED09548A5; Sat, 10 Jan 2004 12:38:46 -0600 (CST) Received: by madman.celabo.org (Postfix, from userid 1001) id C82146D45F; Sat, 10 Jan 2004 12:38:45 -0600 (CST) Date: Sat, 10 Jan 2004 12:38:45 -0600 From: "Jacques A. Vidrine" To: Tinderbox Message-ID: <20040110183845.GA81382@madman.celabo.org> References: <200401101739.i0AHdhUC030812@cueball.rtp.FreeBSD.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <200401101739.i0AHdhUC030812@cueball.rtp.FreeBSD.org> X-Url: http://www.celabo.org/ User-Agent: Mutt/1.5.4i-ja.1 cc: alpha@freebsd.org cc: current@freebsd.org Subject: Re: [current tinderbox] failure on alpha/alpha X-BeenThere: freebsd-alpha@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Porting FreeBSD to the Alpha List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 10 Jan 2004 18:38:47 -0000 On Sat, Jan 10, 2004 at 12:39:43PM -0500, Tinderbox wrote: > TB --- 2004-01-10 17:00:00 - tinderbox 2.2 running on cueball.rtp.FreeBSD.org [...] > /vol/vol1/users/des/tinderbox/CURRENT/alpha/alpha/src/lib/libio/alpha_sethae.c:34: error: conflicting types for `sysarch' > /home/des/tinderbox/CURRENT/alpha/alpha/obj/alpha/vol/vol1/users/des/tinderbox/CURRENT/alpha/alpha/src/i386/usr/include/machine/sysarch.h:55: error: previous declaration of `sysarch' > *** Error code 1 [...] > TB --- 2004-01-10 17:39:43 - TB --- /usr/bin/make returned exit code 1 > TB --- 2004-01-10 17:39:43 - TB --- ERROR: failed to build world > TB --- 2004-01-10 17:39:43 - tinderbox aborted Sorry again! I didn't look for uses of sysarch(2) outside of libc. I'm still doing `make universe' from my previous change--- the tinderbox hardware must be faster than mine :-) Cheers, -- Jacques Vidrine NTT/Verio SME FreeBSD UNIX Heimdal nectar@celabo.org jvidrine@verio.net nectar@freebsd.org nectar@kth.se