All of lore.kernel.org
 help / color / mirror / Atom feed
From: Martin Dalecki <dalecki@evision-ventures.com>
To: Linus Torvalds <torvalds@transmeta.com>
Cc: Kernel Mailing List <linux-kernel@vger.kernel.org>
Subject: [PATCH] 2.5.21 kill warnings 19/19
Date: Mon, 10 Jun 2002 13:50:36 +0200	[thread overview]
Message-ID: <3D04928C.4080401@evision-ventures.com> (raw)
In-Reply-To: <Pine.LNX.4.33.0206082235240.4635-100000@penguin.transmeta.com>

[-- Attachment #1: Type: text/plain, Size: 37 bytes --]

and now the final irda offender :-).

[-- Attachment #2: warn-2.5.21-19.diff --]
[-- Type: text/plain, Size: 9245 bytes --]

diff -urN linux-2.5.21/net/irda/wrapper.c linux/net/irda/wrapper.c
--- linux-2.5.21/net/irda/wrapper.c	2002-06-09 07:27:50.000000000 +0200
+++ linux/net/irda/wrapper.c	2002-06-09 20:49:58.000000000 +0200
@@ -1,5 +1,5 @@
 /*********************************************************************
- *                
+ *
  * Filename:      wrapper.c
  * Version:       1.2
  * Description:   IrDA SIR async wrapper layer
@@ -10,17 +10,17 @@
  * Modified by:   Dag Brattli <dagb@cs.uit.no>
  * Modified at:   Fri May 28  3:11 CST 1999
  * Modified by:   Horst von Brand <vonbrand@sleipnir.valparaiso.cl>
- * 
- *     Copyright (c) 1998-2000 Dag Brattli <dagb@cs.uit.no>, 
+ *
+ *     Copyright (c) 1998-2000 Dag Brattli <dagb@cs.uit.no>,
  *     All Rights Reserved.
- *     
- *     This program is free software; you can redistribute it and/or 
- *     modify it under the terms of the GNU General Public License as 
- *     published by the Free Software Foundation; either version 2 of 
+ *
+ *     This program is free software; you can redistribute it and/or
+ *     modify it under the terms of the GNU General Public License as
+ *     published by the Free Software Foundation; either version 2 of
  *     the License, or (at your option) any later version.
  *
  *     Neither Dag Brattli nor University of Tromsø admit liability nor
- *     provide warranty for any of this software. This material is 
+ *     provide warranty for any of this software. This material is
  *     provided "AS-IS" and at no charge.
  *
  ********************************************************************/
@@ -39,22 +39,22 @@
 
 static inline int stuff_byte(__u8 byte, __u8 *buf);
 
-static void state_outside_frame(struct net_device *dev, 
-				struct net_device_stats *stats, 
+static void state_outside_frame(struct net_device *dev,
+				struct net_device_stats *stats,
 				iobuff_t *rx_buff, __u8 byte);
-static void state_begin_frame(struct net_device *dev, 
-			      struct net_device_stats *stats, 
+static void state_begin_frame(struct net_device *dev,
+			      struct net_device_stats *stats,
 			      iobuff_t *rx_buff, __u8 byte);
-static void state_link_escape(struct net_device *dev, 
-			      struct net_device_stats *stats, 
+static void state_link_escape(struct net_device *dev,
+			      struct net_device_stats *stats,
 			      iobuff_t *rx_buff, __u8 byte);
-static void state_inside_frame(struct net_device *dev, 
-			       struct net_device_stats *stats, 
+static void state_inside_frame(struct net_device *dev,
+			       struct net_device_stats *stats,
 			       iobuff_t *rx_buff, __u8 byte);
 
-static void (*state[])(struct net_device *dev, struct net_device_stats *stats, 
-		       iobuff_t *rx_buff, __u8 byte) = 
-{ 
+static void (*state[])(struct net_device *dev, struct net_device_stats *stats,
+		       iobuff_t *rx_buff, __u8 byte) =
+{
 	state_outside_frame,
 	state_begin_frame,
 	state_link_escape,
@@ -64,14 +64,14 @@
 /*
  * Function async_wrap (skb, *tx_buff, buffsize)
  *
- *    Makes a new buffer with wrapping and stuffing, should check that 
+ *    Makes a new buffer with wrapping and stuffing, should check that
  *    we don't get tx buffer overflow.
  */
 int async_wrap_skb(struct sk_buff *skb, __u8 *tx_buff, int buffsize)
 {
 	struct irda_skb_cb *cb = (struct irda_skb_cb *) skb->cb;
 	int xbofs;
- 	int i;
+	int i;
 	int n;
 	union {
 		__u16 value;
@@ -86,11 +86,11 @@
 	 *  Send  XBOF's for required min. turn time and for the negotiated
 	 *  additional XBOFS
 	 */
-	
+
 	if (cb->magic != LAP_MAGIC) {
-		/* 
+		/*
 		 * This will happen for all frames sent from user-space.
-		 * Nothing to worry about, but we set the default number of 
+		 * Nothing to worry about, but we set the default number of
 		 * BOF's
 		 */
 		IRDA_DEBUG(1, __FUNCTION__ "(), wrong magic in skb!\n");
@@ -116,7 +116,7 @@
 	for (i=0; i < skb->len; i++) {
 		/*
 		 *  Check for the possibility of tx buffer overflow. We use
-		 *  bufsize-5 since the maximum number of bytes that can be 
+		 *  bufsize-5 since the maximum number of bytes that can be
 		 *  transmitted after this point is 5.
 		 */
 		ASSERT(n < (buffsize-5), return n;);
@@ -124,7 +124,7 @@
 		n += stuff_byte(skb->data[i], tx_buff+n);
 		fcs.value = irda_fcs(fcs.value, skb->data[i]);
 	}
-	
+
 	/* Insert CRC in little endian format (LSB first) */
 	fcs.value = ~fcs.value;
 #ifdef __LITTLE_ENDIAN
@@ -144,9 +144,9 @@
  *
  *    Byte stuff one single byte and put the result in buffer pointed to by
  *    buf. The buffer must at all times be able to have two bytes inserted.
- * 
+ *
  */
-static inline int stuff_byte(__u8 byte, __u8 *buf) 
+static inline int stuff_byte(__u8 byte, __u8 *buf)
 {
 	switch (byte) {
 	case BOF: /* FALLTHROUGH */
@@ -174,7 +174,7 @@
 inline void async_bump(struct net_device *dev, struct net_device_stats *stats,
 		       __u8 *buf, int len)
 {
-       	struct sk_buff *skb;
+	struct sk_buff *skb;
 
 	skb = dev_alloc_skb(len+1);
 	if (!skb)  {
@@ -184,10 +184,10 @@
 
 	/* Align IP header to 20 bytes */
 	skb_reserve(skb, 1);
-	
+
         /* Copy data without CRC */
-	memcpy(skb_put(skb, len-2), buf, len-2); 
-	
+	memcpy(skb_put(skb, len-2), buf, len-2);
+
 	/* Feed it to IrLAP layer */
 	skb->dev = dev;
 	skb->mac.raw  = skb->data;
@@ -196,7 +196,7 @@
 	netif_rx(skb);
 
 	stats->rx_packets++;
-	stats->rx_bytes += len;	
+	stats->rx_bytes += len;
 }
 
 /*
@@ -205,21 +205,21 @@
  *    Parse and de-stuff frame received from the IrDA-port
  *
  */
-inline void async_unwrap_char(struct net_device *dev, 
-			      struct net_device_stats *stats, 
+inline void async_unwrap_char(struct net_device *dev,
+			      struct net_device_stats *stats,
 			      iobuff_t *rx_buff, __u8 byte)
 {
 	(*state[rx_buff->state])(dev, stats, rx_buff, byte);
 }
-	 
+
 /*
  * Function state_outside_frame (dev, rx_buff, byte)
  *
  *    Not receiving any frame (or just bogus data)
  *
  */
-static void state_outside_frame(struct net_device *dev, 
-				struct net_device_stats *stats, 
+static void state_outside_frame(struct net_device *dev,
+				struct net_device_stats *stats,
 				iobuff_t *rx_buff, __u8 byte)
 {
 	switch (byte) {
@@ -245,8 +245,8 @@
  *    Begin of frame detected
  *
  */
-static void state_begin_frame(struct net_device *dev, 
-			      struct net_device_stats *stats, 
+static void state_begin_frame(struct net_device *dev,
+			      struct net_device_stats *stats,
 			      iobuff_t *rx_buff, __u8 byte)
 {
 	/* Time to initialize receive buffer */
@@ -283,27 +283,27 @@
  *    Found link escape character
  *
  */
-static void state_link_escape(struct net_device *dev, 
-			      struct net_device_stats *stats, 
+static void state_link_escape(struct net_device *dev,
+			      struct net_device_stats *stats,
 			      iobuff_t *rx_buff, __u8 byte)
 {
 	switch (byte) {
 	case BOF: /* New frame? */
-		IRDA_DEBUG(1, __FUNCTION__ 
+		IRDA_DEBUG(1, __FUNCTION__
 			   "(), Discarding incomplete frame\n");
 		rx_buff->state = BEGIN_FRAME;
 		irda_device_set_media_busy(dev, TRUE);
 		break;
 	case CE:
-		WARNING(__FUNCTION__ "(), state not defined\n");
+		WARNING("%s: state not defined\n", __FUNCTION__);
 		break;
 	case EOF: /* Abort frame */
 		rx_buff->state = OUTSIDE_FRAME;
 		break;
 	default:
-		/* 
-		 *  Stuffed char, complement bit 5 of byte 
-		 *  following CE, IrLAP p.114 
+		/*
+		 *  Stuffed char, complement bit 5 of byte
+		 *  following CE, IrLAP p.114
 		 */
 		byte ^= IRDA_TRANS;
 		if (rx_buff->len < rx_buff->truesize)  {
@@ -324,15 +324,15 @@
  *    Handle bytes received within a frame
  *
  */
-static void state_inside_frame(struct net_device *dev, 
+static void state_inside_frame(struct net_device *dev,
 			       struct net_device_stats *stats,
 			       iobuff_t *rx_buff, __u8 byte)
 {
-	int ret = 0; 
+	int ret = 0;
 
 	switch (byte) {
 	case BOF: /* New frame? */
-		IRDA_DEBUG(1, __FUNCTION__ 
+		IRDA_DEBUG(1, __FUNCTION__
 			   "(), Discarding incomplete frame\n");
 		rx_buff->state = BEGIN_FRAME;
 		irda_device_set_media_busy(dev, TRUE);
@@ -343,7 +343,7 @@
 	case EOF: /* End of frame */
 		rx_buff->state = OUTSIDE_FRAME;
 		rx_buff->in_frame = FALSE;
-		
+
 		/* Test FCS and signal success if the frame is good */
 		if (rx_buff->fcs == GOOD_FCS) {
 			/* Deliver frame */
@@ -352,24 +352,22 @@
 			break;
 		} else {
 			/* Wrong CRC, discard frame!  */
-			irda_device_set_media_busy(dev, TRUE); 
+			irda_device_set_media_busy(dev, TRUE);
 
 			IRDA_DEBUG(1, __FUNCTION__ "(), crc error\n");
 			stats->rx_errors++;
 			stats->rx_crc_errors++;
-		}			
+		}
 		break;
 	default: /* Must be the next byte of the frame */
 		if (rx_buff->len < rx_buff->truesize)  {
 			rx_buff->data[rx_buff->len++] = byte;
 			rx_buff->fcs = irda_fcs(rx_buff->fcs, byte);
 		} else {
-			IRDA_DEBUG(1, __FUNCTION__ 
+			IRDA_DEBUG(1, __FUNCTION__
 			      "(), Rx buffer overflow, aborting\n");
 			rx_buff->state = OUTSIDE_FRAME;
 		}
 		break;
 	}
 }
-
-

  parent reply	other threads:[~2002-06-10 12:50 UTC|newest]

Thread overview: 99+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2002-06-09  5:42 Linux 2.5.21 Linus Torvalds
2002-06-09  7:10 ` 2.5.21 -- suspend.h:58: parse error before "__nosavedata" Miles Lane
2002-06-09  8:40   ` Skip Ford
2002-06-09 13:37 ` [PATCH] 2.5.20 IDE 86 Martin Dalecki
2002-06-09 13:39 ` [PATCH] 2.5.20 locks.h Martin Dalecki
2002-06-10 11:19 ` [PATCH] 2.5.21 "I can't get no compilation" Martin Dalecki
2002-06-10 12:32   ` Anton Altaparmakov
2002-06-10 11:54     ` Martin Dalecki
2002-06-10 13:08       ` Anton Altaparmakov
2002-06-10 11:21 ` [PATCH] 2.5.21 kill warnings 1/19 Martin Dalecki
2002-06-10 11:23 ` [PATCH] 2.5.21 kill warnings 2/19 Martin Dalecki
2002-06-10 11:24 ` [PATCH] 2.5.21 kill warnings 3/19 Martin Dalecki
2002-06-10 11:26 ` [PATCH] 2.5.21 kill warnings 4/19 Martin Dalecki
2002-06-10 18:46   ` Maksim (Max) Krasnyanskiy
2002-06-10 18:57     ` Thomas 'Dent' Mirlacher
2002-06-10 19:08       ` Roland Dreier
2002-06-10 19:14         ` Thomas 'Dent' Mirlacher
2002-06-10 19:19       ` Tom Rini
2002-06-10 19:30         ` Andrew Morton
2002-06-10 19:44           ` Tom Rini
2002-06-10 19:51             ` Andrew Morton
2002-06-10 20:03               ` Thunder from the hill
2002-06-10 20:08                 ` Tom Rini
2002-06-10 20:14                   ` Andrew Morton
2002-06-10 21:01                   ` Maksim (Max) Krasnyanskiy
2002-06-10 21:11                     ` Tom Rini
2002-06-10 21:34                       ` Thunder from the hill
2002-06-10 20:10                 ` Thunder from the hill
2002-06-10 20:15                   ` Tom Rini
2002-06-10 20:05               ` Tom Rini
2002-06-10 20:18                 ` Thomas 'Dent' Mirlacher
2002-06-10 19:46           ` Thunder from the hill
2002-06-10 20:00             ` Andrew Morton
2002-06-11  6:12           ` Martin Dalecki
2002-06-10 21:51     ` Neil Booth
2002-06-10 22:42       ` Maksim (Max) Krasnyanskiy
2002-06-11  6:10     ` Martin Dalecki
2002-06-13 12:01     ` Martin Dalecki
2002-06-11  0:40   ` Greg KH
2002-06-11  6:33     ` Martin Dalecki
2002-06-11  6:38       ` Greg KH
2002-06-11  8:26       ` Russell King
2002-06-11  8:34         ` Martin Dalecki
2002-06-11  9:06           ` Russell King
2002-06-11  9:09             ` Martin Dalecki
2002-06-11  9:28               ` Russell King
2002-06-11  9:42                 ` Martin Dalecki
2002-06-11 10:36                   ` Russell King
2002-06-11 11:06   ` Pavel Machek
2002-06-10 11:28 ` [PATCH] 2.5.21 kill warnings 5/19 Martin Dalecki
2002-06-10 22:24   ` William Lee Irwin III
2002-06-10 22:35     ` Russell King
2002-06-11  0:38   ` Greg KH
2002-06-10 11:35 ` [PATCH] 2.5.21 kill warnings 6/19 Martin Dalecki
2002-06-16 11:05   ` Adrian Bunk
2002-06-10 11:37 ` [PATCH] 2.5.21 kill warnings 7/19 Martin Dalecki
2002-06-10 11:38 ` [PATCH] 2.5.21 kill warnings 8/19 Martin Dalecki
2002-06-10 11:39 ` [PATCH] 2.5.21 kill warnings 9/19 Martin Dalecki
2002-06-10 11:40 ` [PATCH] 2.5.21 kill warnings 10/19 Martin Dalecki
2002-06-10 11:42 ` [PATCH] 2.5.21 kill warnings 11/19 Martin Dalecki
2002-06-10 11:43 ` [PATCH] 2.5.21 kill warnings 12/19 Martin Dalecki
2002-06-10 11:44 ` [PATCH] 2.5.21 kill warnings 13/19 Martin Dalecki
2002-06-10 11:45 ` [PATCH] 2.5.21 kill warinigs 14/19 Martin Dalecki
2002-06-10 18:47   ` Ingo Oeser
2002-06-11  8:07     ` Martin Dalecki
2002-06-11 11:59     ` Dave Jones
2002-06-10 11:46 ` [PATCH] 2.5.21 kill warnings 15/19 Martin Dalecki
2002-06-10 11:48 ` [PATCH] 2.5.21 kill warnings 16/19 Martin Dalecki
2002-06-10 11:49 ` [PATCH] 2.5.21 kill warnings 17/19 Martin Dalecki
2002-06-10 11:49 ` [PATCH] 2.5.21 kill warnings 18/19 Martin Dalecki
2002-06-10 11:50 ` Martin Dalecki [this message]
2002-06-10 11:59 ` [REVERT] 2.5.21 s390/block/xpram.c Martin Dalecki
2002-06-11  7:46 ` [PATCH] 2.5.21 IDE 87 Martin Dalecki
2002-06-11 19:02   ` John Weber
2002-06-12  7:00     ` Martin Dalecki
2002-06-13  1:25       ` John Weber
2002-06-12 17:39   ` Brad Heilbrun
2002-06-12 10:50 ` [PATCH] 2.5.21 inline abuse Martin Dalecki
2002-06-13 12:45   ` Richard Zidlicky
2002-06-13  9:51 ` [PATCH] 2.5.21 IDE 88 Martin Dalecki
2002-06-14 11:06 ` [PATCH] 2.5.21 IDE 89 Martin Dalecki
2002-06-14 11:08 ` [PATCH] 2.5.21 IDE 90 Martin Dalecki
2002-06-14 14:02 ` [PATCH] 2.5.21 IDE 91 Martin Dalecki
2002-06-14 15:17   ` Jens Axboe
2002-06-14 15:42     ` John Weber
2002-06-14 15:43     ` Dave Jones
2002-06-14 16:06       ` Bartlomiej Zolnierkiewicz
2002-06-14 16:33         ` Martin Dalecki
2002-06-14 17:56       ` Linus Torvalds
2002-06-14 15:56     ` Benjamin LaHaise
2002-06-14 16:04       ` Dave Jones
2002-06-14 17:23         ` Martin Dalecki
2002-06-14 16:09       ` Bartlomiej Zolnierkiewicz
2002-06-14 16:15     ` Martin Dalecki
2002-06-15  8:15       ` Jens Axboe
2002-06-14 16:43     ` Linus Torvalds
2002-06-14 16:47       ` Martin Dalecki
2002-06-15  8:19       ` Jens Axboe
2002-06-16 18:36 ` [PATCH] 2.5.21 ide 92 Martin Dalecki

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=3D04928C.4080401@evision-ventures.com \
    --to=dalecki@evision-ventures.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=torvalds@transmeta.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.