Another mkiss patch (was: Re: AX-25 software that works on Fedora Core 4?)

2005-08-24 Thread Ralf Baechle
On Tue, Aug 23, 2005 at 09:17:02PM +0200, Jacques Chion wrote:

   If i do the command ifconfig, i have the interface sm0 with the HWaddr 
   LINUX-1 instead of my callsign F6CWO.
   this can be corrected with the command ifconfig sm0 hw ax25 F6CWO up
   and all is working fine. I don't see from where is coming this LINUX-1.
  
  LINUX-1 is the driver's builtin default MAC address.
  
 
 I will search what is wrong on my box. Sure it's something stupid :)

I did setup soundmodem myself last night and was able to reproduce the
fault.  The problem is being caused by soundmodem passng slightly different
arguments to the failing ioctl than kissattach and the drivers strict
sanity checks did reject that.  I changed that and it's working now.

Latest version attached below.  This I hope is going to be the final
version of this patch.

73 de DL5RB op Ralf

--
Loc. JN47BS / CQ 14 / ITU 28 / DOK A21

Signed-off-by: Ralf Baechle DL5RB [EMAIL PROTECTED]


 drivers/net/hamradio/Kconfig |2 
 drivers/net/hamradio/mkiss.c | 1087 ---
 2 files changed, 525 insertions(+), 564 deletions(-)

Index: linux-cvs/drivers/net/hamradio/mkiss.c
===
--- linux-cvs.orig/drivers/net/hamradio/mkiss.c
+++ linux-cvs/drivers/net/hamradio/mkiss.c
@@ -1,30 +1,19 @@
 /*
- * MKISS Driver
+ *  This program is free software; you can distribute it and/or modify it
+ *  under the terms of the GNU General Public License (Version 2) as
+ *  published by the Free Software Foundation.
  *
- * This module:
- * This module 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.
+ *  This program is distributed in the hope it will be useful, but WITHOUT
+ *  ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ *  FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ *  for more details.
  *
- * This module implements the AX.25 protocol for kernel-based
- * devices like TTYs. It interfaces between a raw TTY, and the
- * kernel's AX.25 protocol layers, just like slip.c.
- * AX.25 needs to be separated from slip.c while slip.c is no
- * longer a static kernel device since it is a module.
- * This method clears the way to implement other kiss protocols
- * like mkiss smack g8bpq . so far only mkiss is implemented.
+ *  You should have received a copy of the GNU General Public License along
+ *  with this program; if not, write to the Free Software Foundation, Inc.,
+ *  59 Temple Place - Suite 330, Boston MA 02111-1307, USA.
  *
- * Hans Alblas [EMAIL PROTECTED]
- *
- * History
- * Jonathan (G4KLX)Fixed to match Linux networking changes - 
2.1.15.
- * Matthias (DG2FEF)   Added support for FlexNet CRC (on special 
request)
- *  Fixed bug in ax25_close(): dev_lock_wait() was
- *  called twice, causing a deadlock.
- * Jeroen (PE1RXQ) Removed old MKISS_MAGIC stuff and calls to
- * MOD_*_USE_COUNT
- * Remove cli() and fix rtnl lock usage.
+ * Copyright (C) Hans Alblas PE1AYX [EMAIL PROTECTED]
+ * Copyright (C) 2004, 05 Ralf Baechle DL5RB [EMAIL PROTECTED]
  */
 
 #include linux/config.h
@@ -49,174 +38,296 @@
 
 #include net/ax25.h
 
-#include mkiss.h
-
 #ifdef CONFIG_INET
 #include linux/ip.h
 #include linux/tcp.h
 #endif
 
-static char banner[] __initdata = KERN_INFO mkiss: AX.25 Multikiss, Hans 
Albas PE1AYX\n;
-
-typedef struct ax25_ctrl {
-   struct ax_disp ctrl;/*  */
-   struct net_device  dev; /* the device   */
-} ax25_ctrl_t;
-
-static ax25_ctrl_t **ax25_ctrls;
+#define AX_MTU 236
 
-int ax25_maxdev = AX25_MAXDEV; /* Can be overridden with insmod! */
+/* SLIP/KISS protocol characters. */
+#define END 0300   /* indicates end of frame   */
+#define ESC 0333   /* indicates byte stuffing  */
+#define ESC_END 0334   /* ESC ESC_END means END 'data' */
+#define ESC_ESC 0335   /* ESC ESC_ESC means ESC 'data' */
+
+struct mkiss {
+   struct tty_struct   *tty;   /* ptr to TTY structure */
+   struct net_device   *dev;   /* easy for intr handling   */
+
+   /* These are pointers to the malloc()ed frame buffers. */
+   spinlock_t  buflock;/* lock for rbuf and xbuf */
+   unsigned char   *rbuff; /* receiver buffer  */
+   int rcount; /* received chars counter   */
+   unsigned char   *xbuff; /* 

Re: AX-25 software that works on Fedora Core 4?

2005-08-22 Thread Scott Weis
Thanks Ralf, I can now use the ax25 kernel stuff again, SIOCSIFHADDR issue 
seems to be fixed...


Thanks  73 de
Scott KB2EAR
- Original Message - 
From: Ralf Baechle DL5RB [EMAIL PROTECTED]

To: Jacques Chion [EMAIL PROTECTED]
Cc: Scott Weis [EMAIL PROTECTED]; linux-hams@vger.kernel.org
Sent: Monday, August 22, 2005 9:28 AM
Subject: Re: AX-25 software that works on Fedora Core 4?



On Sun, Aug 21, 2005 at 12:05:57PM +0200, Jacques Chion wrote:

-the patch you have sent by mail refuse to apply after line 885, but i 
finished by hand, and no problem to compile.
-soundmodem, that i use, is complaining about SIOCSIFHADDR, but it seems 
to work properly.


So, thank you and again, great job !


So here's the next version to test, it should fix the SIOCSIFHADDR issue.
Again the patch is against 2.6.13-rc6.

73 de DL5RB op Ralf

--
Loc. JN47BS / CQ 14 / ITU 28 / DOK A21

Signed-off-by: Ralf Baechle DL5RB [EMAIL PROTECTED]


drivers/net/hamradio/Kconfig |2
drivers/net/hamradio/mkiss.c | 1092 
---

2 files changed, 530 insertions(+), 564 deletions(-)

Index: linux-cvs/drivers/net/hamradio/mkiss.c
===
--- linux-cvs.orig/drivers/net/hamradio/mkiss.c
+++ linux-cvs/drivers/net/hamradio/mkiss.c
@@ -1,30 +1,19 @@
/*
- * MKISS Driver
+ *  This program is free software; you can distribute it and/or modify it
+ *  under the terms of the GNU General Public License (Version 2) as
+ *  published by the Free Software Foundation.
 *
- * This module:
- * This module 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.
+ *  This program is distributed in the hope it will be useful, but 
WITHOUT

+ *  ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ *  FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ *  for more details.
 *
- * This module implements the AX.25 protocol for kernel-based
- * devices like TTYs. It interfaces between a raw TTY, and the
- * kernel's AX.25 protocol layers, just like slip.c.
- * AX.25 needs to be separated from slip.c while slip.c is no
- * longer a static kernel device since it is a module.
- * This method clears the way to implement other kiss protocols
- * like mkiss smack g8bpq . so far only mkiss is implemented.
+ *  You should have received a copy of the GNU General Public License 
along
+ *  with this program; if not, write to the Free Software Foundation, 
Inc.,

+ *  59 Temple Place - Suite 330, Boston MA 02111-1307, USA.
 *
- * Hans Alblas [EMAIL PROTECTED]
- *
- * History
- * Jonathan (G4KLX) Fixed to match Linux networking changes - 2.1.15.
- * Matthias (DG2FEF)   Added support for FlexNet CRC (on special 
request)
- *  Fixed bug in ax25_close(): 
dev_lock_wait() was

- *  called twice, causing a deadlock.
- * Jeroen (PE1RXQ) Removed old MKISS_MAGIC stuff and calls to
- * MOD_*_USE_COUNT
- * Remove cli() and fix rtnl lock usage.
+ * Copyright (C) Hans Alblas PE1AYX [EMAIL PROTECTED]
+ * Copyright (C) 2004, 05 Ralf Baechle DL5RB [EMAIL PROTECTED]
 */

#include linux/config.h
@@ -49,174 +38,302 @@

#include net/ax25.h

-#include mkiss.h
-
#ifdef CONFIG_INET
#include linux/ip.h
#include linux/tcp.h
#endif

-static char banner[] __initdata = KERN_INFO mkiss: AX.25 Multikiss, Hans 
Albas PE1AYX\n;

-
-typedef struct ax25_ctrl {
- struct ax_disp ctrl; /* */
- struct net_device  dev; /* the device */
-} ax25_ctrl_t;
-
-static ax25_ctrl_t **ax25_ctrls;
+#define AX_MTU 236

-int ax25_maxdev = AX25_MAXDEV; /* Can be overridden with insmod! */
+/* SLIP/KISS protocol characters. */
+#define END 0300 /* indicates end of frame */
+#define ESC 0333 /* indicates byte stuffing */
+#define ESC_END 0334 /* ESC ESC_END means END 'data' */
+#define ESC_ESC 0335 /* ESC ESC_ESC means ESC 'data' */
+
+struct mkiss {
+ struct tty_struct *tty; /* ptr to TTY structure */
+ struct net_device *dev; /* easy for intr handling */
+
+ /* These are pointers to the malloc()ed frame buffers. */
+ spinlock_t buflock;/* lock for rbuf and xbuf */
+ unsigned char *rbuff; /* receiver buffer */
+ int rcount; /* received chars counter   */
+ unsigned char *xbuff; /* transmitter buffer */
+ unsigned char *xhead; /* pointer to next byte to XMIT */
+ int xleft; /* bytes left in XMIT queue */
+
+ struct net_device_stats stats;
+
+ /* Detailed SLIP statistics. */
+ int mtu; /* Our mtu (to spot changes!)   */
+ int buffsize; /* Max buffers sizes*/
+
+ unsigned long flags; /* Flag values/ mode etc */
+ /* long req'd: used by set_bit --RR */
+#define AXF_INUSE 0 /* Channel in use   */
+#define AXF_ESCAPE 1   /* ESC received */
+#define

Re: AX-25 software that works on Fedora Core 4?

2005-08-22 Thread Ralf Baechle DL5RB
On Sun, Aug 21, 2005 at 12:05:57PM +0200, Jacques Chion wrote:

 -the patch you have sent by mail refuse to apply after line 885, but i 
 finished by hand, and no problem to compile.
 -soundmodem, that i use, is complaining about SIOCSIFHADDR, but it seems to 
 work properly.
 
 So, thank you and again, great job !

So here's the next version to test, it should fix the SIOCSIFHADDR issue.
Again the patch is against 2.6.13-rc6.

73 de DL5RB op Ralf

--
Loc. JN47BS / CQ 14 / ITU 28 / DOK A21

Signed-off-by: Ralf Baechle DL5RB [EMAIL PROTECTED]


 drivers/net/hamradio/Kconfig |2 
 drivers/net/hamradio/mkiss.c | 1092 ---
 2 files changed, 530 insertions(+), 564 deletions(-)

Index: linux-cvs/drivers/net/hamradio/mkiss.c
===
--- linux-cvs.orig/drivers/net/hamradio/mkiss.c
+++ linux-cvs/drivers/net/hamradio/mkiss.c
@@ -1,30 +1,19 @@
 /*
- * MKISS Driver
+ *  This program is free software; you can distribute it and/or modify it
+ *  under the terms of the GNU General Public License (Version 2) as
+ *  published by the Free Software Foundation.
  *
- * This module:
- * This module 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.
+ *  This program is distributed in the hope it will be useful, but WITHOUT
+ *  ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ *  FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ *  for more details.
  *
- * This module implements the AX.25 protocol for kernel-based
- * devices like TTYs. It interfaces between a raw TTY, and the
- * kernel's AX.25 protocol layers, just like slip.c.
- * AX.25 needs to be separated from slip.c while slip.c is no
- * longer a static kernel device since it is a module.
- * This method clears the way to implement other kiss protocols
- * like mkiss smack g8bpq . so far only mkiss is implemented.
+ *  You should have received a copy of the GNU General Public License along
+ *  with this program; if not, write to the Free Software Foundation, Inc.,
+ *  59 Temple Place - Suite 330, Boston MA 02111-1307, USA.
  *
- * Hans Alblas [EMAIL PROTECTED]
- *
- * History
- * Jonathan (G4KLX)Fixed to match Linux networking changes - 
2.1.15.
- * Matthias (DG2FEF)   Added support for FlexNet CRC (on special 
request)
- *  Fixed bug in ax25_close(): dev_lock_wait() was
- *  called twice, causing a deadlock.
- * Jeroen (PE1RXQ) Removed old MKISS_MAGIC stuff and calls to
- * MOD_*_USE_COUNT
- * Remove cli() and fix rtnl lock usage.
+ * Copyright (C) Hans Alblas PE1AYX [EMAIL PROTECTED]
+ * Copyright (C) 2004, 05 Ralf Baechle DL5RB [EMAIL PROTECTED]
  */
 
 #include linux/config.h
@@ -49,174 +38,302 @@
 
 #include net/ax25.h
 
-#include mkiss.h
-
 #ifdef CONFIG_INET
 #include linux/ip.h
 #include linux/tcp.h
 #endif
 
-static char banner[] __initdata = KERN_INFO mkiss: AX.25 Multikiss, Hans 
Albas PE1AYX\n;
-
-typedef struct ax25_ctrl {
-   struct ax_disp ctrl;/*  */
-   struct net_device  dev; /* the device   */
-} ax25_ctrl_t;
-
-static ax25_ctrl_t **ax25_ctrls;
+#define AX_MTU 236
 
-int ax25_maxdev = AX25_MAXDEV; /* Can be overridden with insmod! */
+/* SLIP/KISS protocol characters. */
+#define END 0300   /* indicates end of frame   */
+#define ESC 0333   /* indicates byte stuffing  */
+#define ESC_END 0334   /* ESC ESC_END means END 'data' */
+#define ESC_ESC 0335   /* ESC ESC_ESC means ESC 'data' */
+
+struct mkiss {
+   struct tty_struct   *tty;   /* ptr to TTY structure */
+   struct net_device   *dev;   /* easy for intr handling   */
+
+   /* These are pointers to the malloc()ed frame buffers. */
+   spinlock_t  buflock;/* lock for rbuf and xbuf */
+   unsigned char   *rbuff; /* receiver buffer  */
+   int rcount; /* received chars counter   */
+   unsigned char   *xbuff; /* transmitter buffer   */
+   unsigned char   *xhead; /* pointer to next byte to XMIT */
+   int xleft;  /* bytes left in XMIT queue */
+
+   struct net_device_stats stats;
+
+   /* Detailed SLIP statistics. */
+   int mtu;/* Our mtu (to spot changes!)   */
+   int buffsize;   /* Max buffers sizes*/

Re: AX-25 software that works on Fedora Core 4?

2005-08-22 Thread Ralf Baechle DL5RB
On Sat, Aug 20, 2005 at 08:30:37PM -, [EMAIL PROTECTED] wrote:

 What version is it actually intended for? The above are the latest Suse
 9.2 and 9.3 respactively. I hope the above tells you something.

2.6.13-rc6.  Always the latest.

73 de DL5RB op Ralf

--
Loc. JN47BS / CQ 14 / ITU 28 / DOK A21
-
To unsubscribe from this list: send the line unsubscribe linux-hams in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: AX-25 software that works on Fedora Core 4?

2005-08-21 Thread Douglas Cole
On Saturday 20 August 2005 13:30, [EMAIL PROTECTED] wrote:
 Hi Ralf

 I would really like to get mkiss working on a SMP machine, so I tried you
 mkis patch on two different kernel versions (2.6.8 and 2.6.11.4), both
 with the same result:

 host# patch --dry-run -p1 mkiss.patch
 patching file drivers/net/hamradio/mkiss.c
 Hunk #6 FAILED at 397.
 Hunk #7 succeeded at 416 (offset 2 lines).
 Hunk #8 FAILED at 438.
 Hunk #9 FAILED at 450.
 Hunk #10 succeeded at 475 (offset 2 lines).
 Hunk #11 FAILED at 527.
 Hunk #12 succeeded at 564 with fuzz 2 (offset 2 lines).
 Hunk #13 FAILED at 577.
 Hunk #14 FAILED at 679.
 Hunk #15 FAILED at 887.
 7 out of 15 hunks FAILED -- saving rejects to file
 drivers/net/hamradio/mkiss.c.rej
 patching file drivers/net/hamradio/Kconfig

 (I am a suspicious type so I always start with --dry-run)

 What version is it actually intended for? The above are the latest Suse
 9.2 and 9.3 respactively. I hope the above tells you something.

Hi Bent, I noticed you are using SuSE 9.3, and am wondering if you installed 
the AX25 stuff from packages not included with SuSE, since at least in the 
disc's that I have (downloaded from OpenSuSE.org) there are no Amateur radio 
packages to speak of. This I found rather discouraging since up to that point 
SuSE has been a very amateur radio friendly distro'. 

And I am wondering if the 'for pay' version has the packages still (since 
version 7 and up to version 9.2 I have paid for SuSE pro and up to that point 
has had great selection of 'Ham' software) and its just that the downloaded 
version has them missing...

I also noticed that version 10 seems to be ignoring amateur radio as well, and 
was wondering if anyone on the list knows why SuSE dropped the Ham Radio 
package group?

With that, I know that I could just download most the stuff from their 
respective websites, but its nice to have it on the distro' that i am using, 
that was one of the reasons that I liked SuSE so much...

tia for any input you can give :)


Douglas Cole   N7BFS
AMSAT#26182 , K2 # 544
http://www.users.qwest.net/~cdoug3
Registered Linux user # 188922
-
To unsubscribe from this list: send the line unsubscribe linux-hams in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html


ham radio RPMs for SUSE [was: Re: AX-25 software that works on Fedora Core 4?]

2005-08-21 Thread Robert Steinhäußer
Hello all,

Douglas Cole wrote:
 I also noticed that version 10 seems to be ignoring amateur radio as well,
 and was wondering if anyone on the list knows why SuSE dropped the Ham
 Radio package group?

Joerg Reuter, DL1BKE [EMAIL PROTECTED] gave some information about the ham 
radio packages in the SUSE LINUX distribution on the (German) suse-ham 
mailing list. You can find his original message in the archives or ask me; I 
can send you a copy. Here is a rough translation from German.

You can find RPMs for SUSE 9.3 here:

ftp://ftp.suse.com/pub/projects/ham/9.3-i386

(or a SUSE mirror of your choice). You can add this directory as an 
installation source (command line: yast install_source) and then install 
using YaST.  

Joerg can only update these packages in his spare time. He has no time for 
testing and calls them highly inofficial.

The main reason for no longer including ham radio programs in the distribution 
is that many of these programs aren't under active development and it is 
getting more and more difficult to let them work under a new distribution. 
Package maintanance is simply costing too much effort, and many programs only 
compile on the PC architecture and thus require even more effort from Joerg 
as packager and from the autobuild team. Additionally, the potential costs 
for quick and effective handling of security problems are quite high.

Joerg also sees an advantage for himself by continuing these packages on his 
own: During the last weeks of a new release's beta phase he only has to check 
once that these packages compile -- and no longer (in extreme cases) weekly, 
every time somebody checks in a new compiler, GLIBC, QT oder KDE update.

73, Robert DL1NC/N9KBK


pgpOM3dwmilEh.pgp
Description: PGP signature


Re: AX-25 software that works on Fedora Core 4?

2005-08-20 Thread oz6bl
Hi Scott

Scott Weis wrote:
 I have been working for weeks to try and get AX-25 working with the
mkiss
 module.  Best I can figure is that there is no working AX25 for SMP
kernels
I believe that the root problem lies in the SMP part. There has been some
discussion on this list of the mkiss kernel module not being threadsafe
(or whatever the proper term is) and thus not being loaded in SMP-enabled
kernels. To the best of my knowledge this has not been solved yet in spite
of Ralf DL5RB's attempts.

Best 73 de Bent/OZ6BL






-
To unsubscribe from this list: send the line unsubscribe linux-hams in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: AX-25 software that works on Fedora Core 4?

2005-08-20 Thread Ralf Baechle DL5RB
On Fri, Aug 19, 2005 at 02:55:42PM -0400, Scott Weis wrote:

 
 I have been working for weeks to try and get AX-25 working with the mkiss 
 module.  Best I can figure is that there is no working AX25 for SMP kernels 
 and core 4.  The ax25-utils package has not kept up with the updates made 
 in the kernel. This is all I can manage to get when I try to start an 
 interface..

All it takes is the minor tweak of recompiling - at least for the rpms
that I'm maintaining for my own use.

 + /sbin/modprobe mkiss
 + sleep 5
 + /usr/local/sbin/mkiss -s 9600 /dev/ttyS0 /dev/ptya1 /dev/ptya2
 + /usr/local/sbin/kissattach /dev/ttya1 ax0 172.16.198.1
 kissattach: SIOCSIFHWADDR: Invalid argument
 unregister_netdevice: device ax%d/ddc80400 never was registered
   

This sounds like you're using my previous broken mkiss patch?  I'm making
an attempt to rewrite mkiss but unfortunately without mkiss setup for
testing, so a very silly bug happened; find a version with that bug
fixed below.  All I can test it is to the point that kissattach succeeds,
however.

  Ralf

PS: Before anybody is scared, it did work that way for 6pack :-)

Signed-off-by: Ralf Baechle DL5RB [EMAIL PROTECTED]

 drivers/net/hamradio/mkiss.c | 1088 ---
 1 files changed, 525 insertions(+), 563 deletions(-)

Index: linux-cvs/drivers/net/hamradio/mkiss.c
===
--- linux-cvs.orig/drivers/net/hamradio/mkiss.c
+++ linux-cvs/drivers/net/hamradio/mkiss.c
@@ -1,30 +1,19 @@
 /*
- * MKISS Driver
+ *  This program is free software; you can distribute it and/or modify it
+ *  under the terms of the GNU General Public License (Version 2) as
+ *  published by the Free Software Foundation.
  *
- * This module:
- * This module 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.
+ *  This program is distributed in the hope it will be useful, but WITHOUT
+ *  ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ *  FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
+ *  for more details.
  *
- * This module implements the AX.25 protocol for kernel-based
- * devices like TTYs. It interfaces between a raw TTY, and the
- * kernel's AX.25 protocol layers, just like slip.c.
- * AX.25 needs to be separated from slip.c while slip.c is no
- * longer a static kernel device since it is a module.
- * This method clears the way to implement other kiss protocols
- * like mkiss smack g8bpq . so far only mkiss is implemented.
+ *  You should have received a copy of the GNU General Public License along
+ *  with this program; if not, write to the Free Software Foundation, Inc.,
+ *  59 Temple Place - Suite 330, Boston MA 02111-1307, USA.
  *
- * Hans Alblas [EMAIL PROTECTED]
- *
- * History
- * Jonathan (G4KLX)Fixed to match Linux networking changes - 
2.1.15.
- * Matthias (DG2FEF)   Added support for FlexNet CRC (on special 
request)
- *  Fixed bug in ax25_close(): dev_lock_wait() was
- *  called twice, causing a deadlock.
- * Jeroen (PE1RXQ) Removed old MKISS_MAGIC stuff and calls to
- * MOD_*_USE_COUNT
- * Remove cli() and fix rtnl lock usage.
+ * Copyright (C) Hans Alblas PE1AYX [EMAIL PROTECTED]
+ * Copyright (C) 2004, 05 Ralf Baechle DL5RB [EMAIL PROTECTED]
  */
 
 #include linux/config.h
@@ -49,174 +38,302 @@
 
 #include net/ax25.h
 
-#include mkiss.h
-
 #ifdef CONFIG_INET
 #include linux/ip.h
 #include linux/tcp.h
 #endif
 
-static char banner[] __initdata = KERN_INFO mkiss: AX.25 Multikiss, Hans 
Albas PE1AYX\n;
-
-typedef struct ax25_ctrl {
-   struct ax_disp ctrl;/*  */
-   struct net_device  dev; /* the device   */
-} ax25_ctrl_t;
-
-static ax25_ctrl_t **ax25_ctrls;
+#define AX_MTU 236 
 
-int ax25_maxdev = AX25_MAXDEV; /* Can be overridden with insmod! */
+/* SLIP/KISS protocol characters. */
+#define END 0300   /* indicates end of frame   */
+#define ESC 0333   /* indicates byte stuffing  */
+#define ESC_END 0334   /* ESC ESC_END means END 'data' */
+#define ESC_ESC 0335   /* ESC ESC_ESC means ESC 'data' */
+
+struct mkiss {
+   struct tty_struct   *tty;   /* ptr to TTY structure */
+   struct net_device   *dev;   /* easy for intr handling   */
+
+   /* These are pointers to the malloc()ed frame buffers. */
+   spinlock_t  buflock;/* 

Re: AX-25 software that works on Fedora Core 4?

2005-08-20 Thread oz6bl
Hi Ralf

I would really like to get mkiss working on a SMP machine, so I tried you
mkis patch on two different kernel versions (2.6.8 and 2.6.11.4), both
with the same result:

host# patch --dry-run -p1 mkiss.patch
patching file drivers/net/hamradio/mkiss.c
Hunk #6 FAILED at 397.
Hunk #7 succeeded at 416 (offset 2 lines).
Hunk #8 FAILED at 438.
Hunk #9 FAILED at 450.
Hunk #10 succeeded at 475 (offset 2 lines).
Hunk #11 FAILED at 527.
Hunk #12 succeeded at 564 with fuzz 2 (offset 2 lines).
Hunk #13 FAILED at 577.
Hunk #14 FAILED at 679.
Hunk #15 FAILED at 887.
7 out of 15 hunks FAILED -- saving rejects to file
drivers/net/hamradio/mkiss.c.rej
patching file drivers/net/hamradio/Kconfig

(I am a suspicious type so I always start with --dry-run)

What version is it actually intended for? The above are the latest Suse
9.2 and 9.3 respactively. I hope the above tells you something.

Best 73 de Bent/OZ6BL

-
To unsubscribe from this list: send the line unsubscribe linux-hams in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: AX-25 software that works on Fedora Core 4?

2005-08-19 Thread Geoff L. Kennedy
On Fri, 19 Aug 2005, Scott Weis wrote:

 I have been working for weeks to try and get AX-25 working with the mkiss 
 module.  Best I can figure is that there is no working AX25 for SMP kernels 
 and core 4.  The ax25-utils package has not kept up with the updates made in 
 the kernel. This is all I can manage to get when I try to start an 
 interface..
 
 + /usr/local/sbin/mkiss -s 9600 /dev/ttyS0 /dev/ptya1 /dev/ptya2
 + /usr/local/sbin/kissattach /dev/ttya1 ax0 172.16.198.1
 kissattach: SIOCSIFHWADDR: Invalid argument
 unregister_netdevice: device ax%d/ddc80400 never was registered
 + ifconfig ax0 netmask 255.255.255.0 broadcast 172.16.198.255
 SIOCSIFNETMASK: No such device
:
:
 ax1: unknown interface: No such device

   Fedora typically uses udev to set up device nodes at startup,
perhaps this is the problem ?

   Just a thought, I'm no expert on udev...  ;-(


-- 

Geoff L. KennedyNorth Delta, British Columbia, Canada
[EMAIL PROTECTED]   Lat: +49.176  Long: -122.895

Amateur Radio Call: VE7WXS

Weather Satellite Imagery: http://wxsat.gelaken.ca
Personal Webpage : http://ve7wxs.gelaken.ca



-
To unsubscribe from this list: send the line unsubscribe linux-hams in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html