Module Name:    src
Committed By:   roy
Date:           Wed Sep 14 11:43:08 UTC 2016

Modified Files:
        src/sys/net: if_media.h

Log Message:
Introduce IFM_GENERIC.
This allows use of the media interface, but without media as such.
It's sole purpose is to facilitate the reporting of the link status.


To generate a diff of this commit:
cvs rdiff -u -r1.56 -r1.57 src/sys/net/if_media.h

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/net/if_media.h
diff -u src/sys/net/if_media.h:1.56 src/sys/net/if_media.h:1.57
--- src/sys/net/if_media.h:1.56	Thu Oct 25 10:59:43 2012
+++ src/sys/net/if_media.h	Wed Sep 14 11:43:08 2016
@@ -1,4 +1,4 @@
-/*	$NetBSD: if_media.h,v 1.56 2012/10/25 10:59:43 msaitoh Exp $	*/
+/*	$NetBSD: if_media.h,v 1.57 2016/09/14 11:43:08 roy Exp $	*/
 
 /*-
  * Copyright (c) 1998, 2000, 2001 The NetBSD Foundation, Inc.
@@ -157,6 +157,11 @@ void		ifmedia_removeall(struct ifmedia *
  */
 
 /*
+ * Generic, only used for link status reporting.
+ */
+#define	IFM_GENERIC	0x00000000
+
+/*
  * Ethernet
  */
 #define	IFM_ETHER	0x00000020
@@ -614,6 +619,9 @@ struct ifmedia_status_description {
 	(ifms)->ifms_string[((ifms)->ifms_bit & (bit)) ? 1 : 0]
 
 #define	IFM_STATUS_DESCRIPTIONS {					\
+	{ IFM_GENERIC,		IFM_AVALID,	IFM_ACTIVE,		\
+	  { "no network", "active" } },					\
+									\
 	{ IFM_ETHER,		IFM_AVALID,	IFM_ACTIVE,		\
 	  { "no carrier", "active" } },					\
 									\

Reply via email to