Mailing List archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[linux-dvb] patch for dvb_net.c (x Marcus)
- To: linux-dvb@linuxtv.org
- Subject: [linux-dvb] patch for dvb_net.c (x Marcus)
- From: lymes23 <lymes@tiscalinet.it>
- Date: Wed, 29 Jan 2003 16:43:19 +0100
- Content-transfer-encoding: 7bit
- Content-type: text/plain; charset=ISO-8859-1; format=flowed
- Sender: linux-dvb-bounce@linuxtv.org
- User-agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.2) Gecko/20021126
Hello,
Just wonder if it is possible to integrate the following patch into the
next driver releases:
------------------ cut here ------------------------
diff -Naur DVB.safe/driver/dvb_net.c DVB/driver/dvb_net.c
--- DVB.safe/driver/dvb_net.c Wed Jan 29 15:21:01 2003
+++ DVB/driver/dvb_net.c Tue Jan 28 12:05:16 2003
@@ -483,6 +483,21 @@
dvbnetif->if_num=result;
break;
}
+ case NET_GET_IF:
+ {
+ struct net_device *netdev;
+ struct dvb_net_priv *priv_data;
+ struct dvb_net_if *dvbnetif=(struct dvb_net_if *)parg;
+
+ if (dvbnetif->if_num >= dvbnet->dev_num ||
+ !dvbnet->state[dvbnetif->if_num])
+ return -EFAULT;
+
+ netdev=(struct net_device*)&dvbnet->device[dvbnetif->if_num];
+ priv_data=(struct dvb_net_priv*)netdev->priv;
+ dvbnetif->pid=priv_data->pid;
+ break;
+ }
case NET_REMOVE_IF:
return dvb_net_remove_if(dvbnet, (int) parg);
default:
diff -Naur DVB.safe/include/linux/dvb/net.h DVB/include/linux/dvb/net.h
--- DVB.safe/include/linux/dvb/net.h Wed Jan 29 15:21:01 2003
+++ DVB/include/linux/dvb/net.h Tue Jan 28 10:09:24 2003
@@ -38,7 +38,8 @@
#define NET_ADD_IF _IOWR('o', 52, struct dvb_net_if)
-#define NET_REMOVE_IF _IO('o', 53)
+#define NET_REMOVE_IF _IO( 'o', 53)
+#define NET_GET_IF _IOWR('o', 54, struct dvb_net_if)
#endif /*_DVBNET_H_*/
------------------ cut here ------------------------
I think it could be useful to check what net ifaces (and their pids) are
already activated, couldn't it?
Lymes.
--
Info:
To unsubscribe send a mail to listar@linuxtv.org with "unsubscribe linux-dvb" as subject.
Home |
Main Index |
Thread Index