summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--sys/net/if_atm.h4
-rw-r--r--sys/net/if_atmsubr.c6
2 files changed, 5 insertions, 5 deletions
diff --git a/sys/net/if_atm.h b/sys/net/if_atm.h
index cafe5a7..f09f7a6 100644
--- a/sys/net/if_atm.h
+++ b/sys/net/if_atm.h
@@ -93,8 +93,8 @@ struct atmllc {
/* ATM_LLC macros: note type code in host byte order */
#define ATM_LLC_TYPE(X) (((X)->type[0] << 8) | ((X)->type[1]))
#define ATM_LLC_SETTYPE(X,V) { \
- (X)->type[1] = ((V) >> 8) & 0xff; \
- (X)->type[0] = ((V) & 0xff); \
+ (X)->type[0] = ((V) >> 8) & 0xff; \
+ (X)->type[1] = ((V) & 0xff); \
}
#ifdef _KERNEL
diff --git a/sys/net/if_atmsubr.c b/sys/net/if_atmsubr.c
index 782ed88..7fbf1e8 100644
--- a/sys/net/if_atmsubr.c
+++ b/sys/net/if_atmsubr.c
@@ -130,9 +130,9 @@ atm_output(ifp, m0, dst, rt0)
case AF_INET:
case AF_INET6:
if (dst->sa_family == AF_INET6)
- etype = htons(ETHERTYPE_IPV6);
+ etype = ETHERTYPE_IPV6;
else
- etype = htons(ETHERTYPE_IP);
+ etype = ETHERTYPE_IP;
if (!atmresolve(rt, m, dst, &atmdst)) {
m = NULL;
/* XXX: atmresolve already free'd it */
@@ -180,7 +180,7 @@ atm_output(ifp, m0, dst, rt0)
bcopy(ATMLLC_HDR, atmllc->llchdr,
sizeof(atmllc->llchdr));
ATM_LLC_SETTYPE(atmllc, etype);
- /* note: already in network order */
+ /* note: in host order */
}
else
bcopy(llc_hdr, atmllc, sizeof(struct atmllc));
OpenPOWER on IntegriCloud