From owner-cvs-src Thu Mar 13 4:44: 8 2003 Delivered-To: cvs-src@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id D384E37B401; Thu, 13 Mar 2003 04:44:06 -0800 (PST) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 6F36C43F93; Thu, 13 Mar 2003 04:44:06 -0800 (PST) (envelope-from harti@FreeBSD.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.12.6/8.12.6) with ESMTP id h2DCi60U035684; Thu, 13 Mar 2003 04:44:06 -0800 (PST) (envelope-from harti@repoman.freebsd.org) Received: (from harti@localhost) by repoman.freebsd.org (8.12.6/8.12.6/Submit) id h2DCi6hB035683; Thu, 13 Mar 2003 04:44:06 -0800 (PST) Message-Id: <200303131244.h2DCi6hB035683@repoman.freebsd.org> From: Hartmut Brandt Date: Thu, 13 Mar 2003 04:44:06 -0800 (PST) To: src-committers@FreeBSD.org, cvs-src@FreeBSD.org, cvs-all@FreeBSD.org Subject: cvs commit: src/sys/net if_atm.h if_atmsubr.c X-FreeBSD-CVS-Branch: HEAD Sender: owner-cvs-src@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG harti 2003/03/13 04:44:06 PST FreeBSD src repository Modified files: sys/net if_atm.h if_atmsubr.c Log: This corrects a longstanding endian bug in processing LLC/SNAP encoded frames. A comment in if_atm.h suggests that both macros, that for extracting the ethertype and that for inserting it, handle their argument in host byte order. In fact, the inserting macro treated its argument as an opposite host order short and the calling code feeds it the result of htons(). This happens to work on i386, but fails on sparc. Make the macro use real host endianess. Reviewed by: kjc, atm@ Revision Changes Path 1.6 +2 -2 src/sys/net/if_atm.h 1.24 +3 -3 src/sys/net/if_atmsubr.c To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe cvs-src" in the body of the message