netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* Re: baycom_ser_fdx - fixed under 2.6
       [not found] <alpine.DEB.1.10.0807191042050.21295@tombstone.paradise.gen.nz>
@ 2008-07-22  9:31 ` Pidoux
  2008-07-22 12:08   ` Ralf Baechle
  2008-07-28  3:44   ` Peter Mallett
  0 siblings, 2 replies; 5+ messages in thread
From: Pidoux @ 2008-07-22  9:31 UTC (permalink / raw)
  To: David Robb; +Cc: linux-hams, David Miller, Ralf Baechle, Linux Netdev List

Hi,

This is a trivial but very important bug fix. Thanks David.
It was probably not submitted to the right destination and thus never applied.

This bug may have discouraged more than one radioamateur wishing to experiment baycom style modems under Linux.
Fortunately you have done a very good historical search.

I rebuilt the patch against 2.6.26 kernel (the only source I have here on my laptop at my remote location during vacation).

I Cc: to David Miller and Ralf Baechle DL5RB maintainers of Linux net devices drivers and Linux AX25 drivers, respectively.

73 de Bernard, f6bvp


--- a/drivers/net/hamradio/hdlcdrv.c	2008-07-22 10:40:20.000000000 +0200
+++ b/drivers/net/hamradio/hdlcdrv.c	2008-07-22 10:42:13.000000000 +0200
@@ -88,6 +88,7 @@
  static inline void append_crc_ccitt(unsigned char *buffer, int len)
  {
   	unsigned int crc = crc_ccitt(0xffff, buffer, len) ^ 0xffff;
+	buffer += len;
  	*buffer++ = crc;
  	*buffer++ = crc >> 8;
  }



David Robb wrote :
> So it seems that I might be the only person in the world who's still 
> attempting to use a Baycom bp-1 pocket modem under Linux, but oh well..
> 
> As a number of people noticed back in about 2005 (and some even 
> earlier), the baycom_ser_fdx driver hasn't worked under Linux 2.6 for a 
> few years (possibly ever).
> 
> Various people poked around 
> (http://osdir.com/ml/hams/2005-05/msg00022.html) and determined that 
> there was some kind of packet corruption going on, and that the CRC was 
> mangled.
> 
> Well, after bashing my head against it a few times over the last few 
> months (I guess I was bored), and finally thinking that it mightn't be 
> in the baycom_ser_fdx driver that the problem actually was, I tracked it 
> down to the hdlcdrv code instead...
> 
> Someone called Micah actually figured this out in 2004, and submitted a 
> patch, but it never made it into the kernel (at least in my 2.6.25.7 
> it's still broken):
> 
> http://linux.derkeiler.com/Mailing-Lists/Kernel/2004-11/2929.html
> 
> The CRC's overwriting some of the packet...
> 
> So anyway, applying the patch listed at that URL (1 line! Just one 
> little line!) my BP-1 now works again under 2.6.25.
> 
> Perhaps I'm strange for wanting this working in these days of high speed 
> links, but hey... it seems sad to have broken code and no support where 
> there used to be a functional device.
> 
> Anyway, share and enjoy.
> 
> --David ZL3UDR

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: baycom_ser_fdx - fixed under 2.6
  2008-07-22  9:31 ` baycom_ser_fdx - fixed under 2.6 Pidoux
@ 2008-07-22 12:08   ` Ralf Baechle
  2008-07-28  3:44   ` Peter Mallett
  1 sibling, 0 replies; 5+ messages in thread
From: Ralf Baechle @ 2008-07-22 12:08 UTC (permalink / raw)
  To: Pidoux, Jeff Garzik, stable
  Cc: David Robb, linux-hams, David Miller, Linux Netdev List

On Tue, Jul 22, 2008 at 11:31:34AM +0200, Pidoux wrote:

> This is a trivial but very important bug fix. Thanks David.
> It was probably not submitted to the right destination and thus never applied.
>
> This bug may have discouraged more than one radioamateur wishing to experiment baycom style modems under Linux.
> Fortunately you have done a very good historical search.
>
> I rebuilt the patch against 2.6.26 kernel (the only source I have here on my laptop at my remote location during vacation).
>
> I Cc: to David Miller and Ralf Baechle DL5RB maintainers of Linux net devices drivers and Linux AX25 drivers, respectively.

Correct, the CRC should go at the end of the frame, not corrupt the first
header bytes.  So this one should also go into -stable.

Acked-by: Ralf Baechle <ralf@linux-mips.org>

  Ralf

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: baycom_ser_fdx - fixed under 2.6
  2008-07-22  9:31 ` baycom_ser_fdx - fixed under 2.6 Pidoux
  2008-07-22 12:08   ` Ralf Baechle
@ 2008-07-28  3:44   ` Peter Mallett
  2008-07-28 10:32     ` Matti Aarnio
  1 sibling, 1 reply; 5+ messages in thread
From: Peter Mallett @ 2008-07-28  3:44 UTC (permalink / raw)
  To: Pidoux
  Cc: David Robb, linux-hams, David Miller, Ralf Baechle,
	Linux Netdev List

Pidoux wrote:
> Hi,
>
> This is a trivial but very important bug fix. Thanks David.
> It was probably not submitted to the right destination and thus never 
> applied.
>
> This bug may have discouraged more than one radioamateur wishing to 
> experiment baycom style modems under Linux.
> Fortunately you have done a very good historical search.
>
> I rebuilt the patch against 2.6.26 kernel (the only source I have here 
> on my laptop at my remote location during vacation).
>
> I Cc: to David Miller and Ralf Baechle DL5RB maintainers of Linux net 
> devices drivers and Linux AX25 drivers, respectively.
>
> 73 de Bernard, f6bvp
>
>
> --- a/drivers/net/hamradio/hdlcdrv.c    2008-07-22 10:40:20.000000000 
> +0200
> +++ b/drivers/net/hamradio/hdlcdrv.c    2008-07-22 10:42:13.000000000 
> +0200
> @@ -88,6 +88,7 @@
>  static inline void append_crc_ccitt(unsigned char *buffer, int len)
>  {
>       unsigned int crc = crc_ccitt(0xffff, buffer, len) ^ 0xffff;
> +    buffer += len;
>      *buffer++ = crc;
>      *buffer++ = crc >> 8;
>  }
>
>
>
> David Robb wrote :
>> So it seems that I might be the only person in the world who's still 
>> attempting to use a Baycom bp-1 pocket modem under Linux, but oh well..
>>
>> As a number of people noticed back in about 2005 (and some even 
>> earlier), the baycom_ser_fdx driver hasn't worked under Linux 2.6 for 
>> a few years (possibly ever).
>>
>> Various people poked around 
>> (http://osdir.com/ml/hams/2005-05/msg00022.html) and determined that 
>> there was some kind of packet corruption going on, and that the CRC 
>> was mangled.
>>
>> Well, after bashing my head against it a few times over the last few 
>> months (I guess I was bored), and finally thinking that it mightn't 
>> be in the baycom_ser_fdx driver that the problem actually was, I 
>> tracked it down to the hdlcdrv code instead...
>>
>> Someone called Micah actually figured this out in 2004, and submitted 
>> a patch, but it never made it into the kernel (at least in my 
>> 2.6.25.7 it's still broken):
>>
>> http://linux.derkeiler.com/Mailing-Lists/Kernel/2004-11/2929.html
>>
>> The CRC's overwriting some of the packet...
>>
>> So anyway, applying the patch listed at that URL (1 line! Just one 
>> little line!) my BP-1 now works again under 2.6.25.
>>
>> Perhaps I'm strange for wanting this working in these days of high 
>> speed links, but hey... it seems sad to have broken code and no 
>> support where there used to be a functional device.
>>
>> Anyway, share and enjoy.
>>
>> --David ZL3UDR
> -- 
> To unsubscribe from this list: send the line "unsubscribe linux-hams" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html
>

Hi,

    The Baycom MoDem problem is one I have battled for quite a while here.

How do I apply this patch to my Ubuntu 2.6.20-17-generic kernel.

I have the linux-source-2.6.20-2.6.20 source so which file do I apply 
the patch too ?

Then I need to recompile it ?

Would this bug also affect the SCC Baycom card ?

Regards ..... Peter


^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: baycom_ser_fdx - fixed under 2.6
  2008-07-28  3:44   ` Peter Mallett
@ 2008-07-28 10:32     ` Matti Aarnio
  2008-07-29  0:01       ` Peter Mallett
  0 siblings, 1 reply; 5+ messages in thread
From: Matti Aarnio @ 2008-07-28 10:32 UTC (permalink / raw)
  To: Peter Mallett
  Cc: Pidoux, David Robb, linux-hams, David Miller, Ralf Baechle,
	Linux Netdev List

On Mon, Jul 28, 2008 at 03:44:22PM +1200, Peter Mallett wrote:
> Pidoux wrote:
>> Hi,
....
>> 73 de Bernard, f6bvp
>>
>> --- a/drivers/net/hamradio/hdlcdrv.c    2008-07-22 10:40:20.000000000 +0200
>> +++ b/drivers/net/hamradio/hdlcdrv.c    2008-07-22 10:42:13.000000000 +0200
>> @@ -88,6 +88,7 @@
>>  static inline void append_crc_ccitt(unsigned char *buffer, int len)
>>  {
>>       unsigned int crc = crc_ccitt(0xffff, buffer, len) ^ 0xffff;
>> +    buffer += len;
>>      *buffer++ = crc;
>>      *buffer++ = crc >> 8;
>>  }
....
> Hi,
>
>    The Baycom MoDem problem is one I have battled for quite a while here.
>
> How do I apply this patch to my Ubuntu 2.6.20-17-generic kernel.
>
> I have the linux-source-2.6.20-2.6.20 source so which file do I apply  
> the patch too ?

Officially:

  patch -p1 < patch.text

Easier for you:

 - pick editor that you know how to use (nano, vi, emacs, joe, jove...)
 - edit file  drivers/net/hamradio/hdlcdrv.c
   - locate function  append_crc_ccitt
   - add missing line

> Then I need to recompile it ?

Yes.

Better would be to rebuild your kernel runtime in distribution specific
way -- which I do not know for Ubuntu.


> Would this bug also affect the SCC Baycom card ?

No.  It does HDLC framing in hardware.

> Regards ..... Peter

73 de Matti, OH2MQK

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: baycom_ser_fdx - fixed under 2.6
  2008-07-28 10:32     ` Matti Aarnio
@ 2008-07-29  0:01       ` Peter Mallett
  0 siblings, 0 replies; 5+ messages in thread
From: Peter Mallett @ 2008-07-29  0:01 UTC (permalink / raw)
  To: Matti Aarnio
  Cc: Pidoux, David Robb, linux-hams, David Miller, Ralf Baechle,
	Linux Netdev List

Matti Aarnio wrote:

Hi Matti,

             Thank you for the info, I think I have it sorted out now.

Regards ..... Peter


^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2008-07-29  0:01 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
     [not found] <alpine.DEB.1.10.0807191042050.21295@tombstone.paradise.gen.nz>
2008-07-22  9:31 ` baycom_ser_fdx - fixed under 2.6 Pidoux
2008-07-22 12:08   ` Ralf Baechle
2008-07-28  3:44   ` Peter Mallett
2008-07-28 10:32     ` Matti Aarnio
2008-07-29  0:01       ` Peter Mallett

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).