From: Stephane List <stephane.list@fr.alcove.com>
To: linux-kernel@vger.kernel.org
Subject: Network driver: problem with insane (ported in 2.4.3)
Date: Tue, 24 Apr 2001 16:35:09 +0200 [thread overview]
Message-ID: <20010424163509.A32453@alcove-fr> (raw)
Hi all,
Has anybody ported insane or snull from Rubini to kernel 2.4.3?
I'm porting Rubini's example: "insane".
/* --------------------------------------------------------------------------
* definition of the "private" data structure used by this interface
*/
struct insane_private {
struct net_device_stats priv_stats;
struct net_device *priv_device; /* interface used to xmit data */
int priv_mode; /* how to drop packets */
int priv_arg1; /* arguments to the dropping mode */
int priv_arg2;
};
int insane_open(struct net_device *dev)
{
/* mark the device as operational */
/* dev->start = 1;
dev->tbusy = 0;*/
netif_start_queue(dev);
MOD_INC_USE_COUNT;
return 0;
}
int insane_close(struct net_device *dev)
{
/* dev->start = 0;
dev->tbusy = 1;*/
netif_stop_queue(dev);
MOD_DEC_USE_COUNT;
return 0;
}
int insane_xmit(struct sk_buff *skb, struct net_device *dev)
{
... /* state if the packet must be transmit or nor, and if it must */
skb->dev = priv->priv_device;
skb->priority = 1;
printk("enqueue len=%d\n", skb->len);
{
int ret = dev_queue_xmit (skb);
printk("enqueue ret=%d\n", ret);
}
return 0;
}
Everything looks OK, dev_queue_xmit returns 0, but nothing comes back when I
ping through insane.
Has anybody ported insane or snull from Rubini to kernel 2.4.3?
Thanks a lot
Stephane
--
Stéphane LIST -- <stephane.list@fr.alcove.com>
Alcôve, liberating software -- <http://www.alcove.com/>
reply other threads:[~2001-04-24 14:35 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20010424163509.A32453@alcove-fr \
--to=stephane.list@fr.alcove.com \
--cc=linux-kernel@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).