From owner-freebsd-bugs@FreeBSD.ORG Thu Nov 2 18:40:26 2006 Return-Path: X-Original-To: freebsd-bugs@hub.freebsd.org Delivered-To: freebsd-bugs@hub.freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id B4B8816A403 for ; Thu, 2 Nov 2006 18:40:26 +0000 (UTC) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (freefall.freebsd.org [216.136.204.21]) by mx1.FreeBSD.org (Postfix) with ESMTP id 8158B43D55 for ; Thu, 2 Nov 2006 18:40:23 +0000 (GMT) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (gnats@localhost [127.0.0.1]) by freefall.freebsd.org (8.13.4/8.13.4) with ESMTP id kA2IeMbI071492 for ; Thu, 2 Nov 2006 18:40:22 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.13.4/8.13.4/Submit) id kA2IeMcv071491; Thu, 2 Nov 2006 18:40:22 GMT (envelope-from gnats) Date: Thu, 2 Nov 2006 18:40:22 GMT Message-Id: <200611021840.kA2IeMcv071491@freefall.freebsd.org> To: freebsd-bugs@FreeBSD.org From: Ruslan Ermilov Cc: Subject: Re: kern/105054: vge driver sends VLAN IDs in wrong endian. X-BeenThere: freebsd-bugs@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: Ruslan Ermilov List-Id: Bug reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 02 Nov 2006 18:40:26 -0000 The following reply was made to PR kern/105054; it has been noted by GNATS. From: Ruslan Ermilov To: Yo Its Me Remember Cc: bug-followup@FreeBSD.org Subject: Re: kern/105054: vge driver sends VLAN IDs in wrong endian. Date: Thu, 2 Nov 2006 21:34:19 +0300 On Thu, Nov 02, 2006 at 05:00:40PM +0000, Yo Its Me Remember wrote: > No, the input VLAN tags are fine, as I mentioned in the description. > Your patch changes them so that they're now in big endian instead > of little endian, causing another bug. As far as casting to a > uint16_t instead of using htole16, I would think big endian systems > would still need to hand the card output tags in little endian. > Not really sure though since I don't have any big endian systems > to test it. > > Either way, the second half of the patch will work just fine for > little endian systems, just leave the input tag ntohs() there. > The datasheet is silent on this, and the VIA provided Linux driver only has partial support for hardware VLAN tagging (the output part). If what you say is true, that must be a "strange" chip design -- it expects the data in little-endian, but places it in big-endian. I'd have to find the hardware in question to confirm this... Cheers, -- Ruslan Ermilov ru@FreeBSD.org FreeBSD committer