From: Krzysztof Halasa <khc@pm.waw.pl>
To: Stephen Hemminger <shemminger@vyatta.com>
Cc: David Miller <davem@davemloft.net>, netdev@vger.kernel.org
Subject: Re: [PATCH] hdlc: fix compile problem
Date: Thu, 08 Jan 2009 02:26:31 +0100 [thread overview]
Message-ID: <m3priytwoo.fsf@maximus.localdomain> (raw)
In-Reply-To: <20090107170842.6ee4eb77@extreme> (Stephen Hemminger's message of "Wed\, 7 Jan 2009 17\:08\:42 -0800")
Stephen Hemminger <shemminger@vyatta.com> writes:
> Alternatively, how about this:
>
> --- a/drivers/net/wan/hdlc.c 2009-01-07 17:04:52.002497019 -0800
> +++ b/drivers/net/wan/hdlc.c 2009-01-07 17:07:02.874497531 -0800
> @@ -40,8 +40,6 @@
>
> static const char* version = "HDLC support module revision 1.22";
>
> -static const struct header_ops hdlc_null_ops;
> -
> #undef DEBUG_LINK
>
> static struct hdlc_proto *first_proto;
> @@ -100,7 +98,7 @@ static int hdlc_device_event(struct noti
> if (dev_net(dev) != &init_net)
> return NOTIFY_DONE;
>
> - if (dev->header_ops != &hdlc_null_ops)
> + if (dev->priv_flags & IFF_WAN_HDLC)
> return NOTIFY_DONE; /* not an HDLC device */
>
> if (event != NETDEV_CHANGE)
"dev->netdev_ops->start_hard_xmit != hdlc_xmit" is a dirty hack.
IFF_WAN_HDLC is much cleaner though it's an additional bit consumed.
Sure, I like it.
--
Krzysztof Halasa
next prev parent reply other threads:[~2009-01-08 1:26 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-01-07 22:13 [PATCH] hdlc: fix compile problem Stephen Hemminger
2009-01-07 23:21 ` Krzysztof Halasa
2009-01-07 23:28 ` Stephen Hemminger
2009-01-08 1:00 ` Krzysztof Halasa
2009-01-08 1:08 ` Stephen Hemminger
2009-01-08 1:26 ` Krzysztof Halasa [this message]
2009-01-08 2:13 ` David Miller
2009-01-08 15:40 ` Krzysztof Halasa
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=m3priytwoo.fsf@maximus.localdomain \
--to=khc@pm.waw.pl \
--cc=davem@davemloft.net \
--cc=netdev@vger.kernel.org \
--cc=shemminger@vyatta.com \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.