1 /*********************************************************************
5 * Description: A first attempt to make ifconfig understand IrDA
6 * Status: Experimental.
7 * Author: Dag Brattli <dagb@cs.uit.no>
8 * Created at: Wed Apr 21 09:03:09 1999
9 * Modified at: Wed Apr 21 09:17:05 1999
10 * Modified by: Dag Brattli <dagb@cs.uit.no>
12 * This program is free software; you can redistribute it and/or
13 * modify it under the terms of the GNU General Public License as
14 * published by the Free Software Foundation; either version 2 of
15 * the License, or (at your option) any later version.
17 * This program is distributed in the hope that it will be useful,
18 * but WITHOUT ANY WARRANTY; without even the implied warranty of
19 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
20 * GNU General Public License for more details.
22 * You should have received a copy of the GNU General Public License
23 * along with this program; if not, write to the Free Software
24 * Foundation, Inc., 59 Temple Place, Suite 330, Boston,
27 ********************************************************************/
31 #if HAVE_AFIRDA || HAVE_HWIRDA
32 #include <sys/types.h>
33 #include <sys/ioctl.h>
34 #include <sys/socket.h>
35 #include <net/if_arp.h>
44 #include "net-support.h"
45 #include "pathnames.h"
49 /* Probably not a good idea to include <linux/if_arp.h> */
51 #define ARPHRD_IRDA 783
55 * Function irda_print (ptr)
57 * Print hardware address of interface
60 static char *irda_print(unsigned char *ptr
)
64 sprintf(&buff
[strlen(buff
)], "%02x:%02x:%02x:%02x", ptr
[3], ptr
[2],
70 struct hwtype irda_hwtype
=
72 "irda", NULL
, ARPHRD_IRDA
, 2,
73 irda_print
, NULL
, NULL
, 0
76 #endif /* HAVE_xxIRDA */