linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Francois Romieu <romieu@fr.zoreil.com>
To: linux-kernel@vger.kernel.org
Cc: henrique@cyclades.com, torvalds@osdl.org, khc@pm.waw.pl
Subject: [PATCH] 2.6.0-test2 - HDLC hook update for drivers/net/wan/pc300_drv.c
Date: Mon, 28 Jul 2003 21:22:32 +0200	[thread overview]
Message-ID: <20030728212232.C8054@electric-eye.fr.zoreil.com> (raw)
In-Reply-To: <20030728210427.B8054@electric-eye.fr.zoreil.com>; from romieu@fr.zoreil.com on Mon, Jul 28, 2003 at 09:04:27PM +0200

Layout of struct hdlc_device has changed.


 drivers/net/wan/pc300_drv.c |   22 ++++++++++------------
 1 files changed, 10 insertions(+), 12 deletions(-)

diff -puN drivers/net/wan/pc300_drv.c~drivers-hooks-changed-pc300 drivers/net/wan/pc300_drv.c
--- linux-2.6.0-test2/drivers/net/wan/pc300_drv.c~drivers-hooks-changed-pc300	Mon Jul 28 21:05:52 2003
+++ linux-2.6.0-test2-fr/drivers/net/wan/pc300_drv.c	Mon Jul 28 21:10:11 2003
@@ -2553,11 +2553,10 @@ int cpc_ioctl(struct net_device *dev, st
 	switch (cmd) {
 		case SIOCGPC300CONF:
 #ifdef CONFIG_PC300_MLPPP
-			if (conf->proto != PC300_PROTO_MLPPP) {
-				conf->proto = hdlc->proto;
-			}
+			if (conf->proto != PC300_PROTO_MLPPP)
+				conf->proto = hdlc->proto.id;
 #else
-			conf->proto = hdlc->proto;
+			conf->proto = hdlc->proto.id;
 #endif
 			memcpy(&conf_aux.conf, conf, sizeof(pc300chconf_t));
 			memcpy(&conf_aux.hw, &card->hw, sizeof(pc300hw_t));
@@ -2590,12 +2589,12 @@ int cpc_ioctl(struct net_device *dev, st
 					}
 				} else {
 					memcpy(conf, &conf_aux.conf, sizeof(pc300chconf_t));
-					hdlc->proto = conf->proto;
+					hdlc->proto.id = conf->proto;
 				}
 			}
 #else
 			memcpy(conf, &conf_aux.conf, sizeof(pc300chconf_t));
-			hdlc->proto = conf->proto;
+			hdlc->proto.id = conf->proto;
 #endif
 			return 0;
 		case SIOCGPC300STATUS:
@@ -3153,14 +3152,13 @@ int cpc_open(struct net_device *dev)
 	printk("pc300: cpc_open");
 #endif
 
-	if (hdlc->proto == IF_PROTO_PPP) {
+	if (hdlc->proto.id == IF_PROTO_PPP)
 		d->if_ptr = &hdlc->state.ppp.pppdev;
-	}
 
 	result = hdlc_open(hdlc);
-	if (hdlc->proto == IF_PROTO_PPP) {
+	if (hdlc->proto.id == IF_PROTO_PPP)
 		dev->priv = d;
-	}
+
 	if (result) {
 		return result;
 	}
@@ -3191,9 +3189,9 @@ int cpc_close(struct net_device *dev)
 	CPC_UNLOCK(card, flags);
 
 	hdlc_close(hdlc);
-	if (hdlc->proto == IF_PROTO_PPP) {
+	if (hdlc->proto.id == IF_PROTO_PPP)
 		d->if_ptr = NULL;
-	}
+
 #ifdef CONFIG_PC300_MLPPP
 	if (chan->conf.proto == PC300_PROTO_MLPPP) {
 		cpc_tty_unregister_service(d);

_

      reply	other threads:[~2003-07-28 19:26 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-07-28 19:04 [PATCH] 2.6.0-test2 - HDLC hook update for drivers/net/wan/dscc4 Francois Romieu
2003-07-28 19:22 ` Francois Romieu [this message]

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=20030728212232.C8054@electric-eye.fr.zoreil.com \
    --to=romieu@fr.zoreil.com \
    --cc=henrique@cyclades.com \
    --cc=khc@pm.waw.pl \
    --cc=linux-kernel@vger.kernel.org \
    --cc=torvalds@osdl.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).