Skip to contentSkip to conversation

Linux kernel 2.6rc1 and USCC>4/ISA

DISCUSSION [email protected] 2 participants 9 messages Jan 3, 2004 – Jan 4, 2004

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

Hi,

I have slackware current (is ready to use kernel 2.6.x) and I have made latest kernel 2.6rc1 to use with BayCom USCC>4/ISA card (with kernel 2.4.23 this card working) after load module AX25 and SCC and run sccinit this application not exit and frozen console and I have not success to use latest kernel with USCC card.

begin:vcard
fn:Waldemar Ogonowski
n:Ogonowski;Waldemar
org;quoted-printable:Geofizyka Torun Sp. z o.o.;O=C5=9Brodek Obliczeniowy adr;dom:;;ul. Chrobrego 50;Torun;;87-100 email;internet:[email protected]
tel;work:+48 56 6593 313
tel;fax:+48 56 6593 311
tel;cell:+48 502 509 059
x-mozilla-html:FALSE
url:http://www.GTservices.pl
version:2.1
end:vcard

#1 lore raw
Quoted 7 lines · On 2004.01.03 12:04:42 +0100 [email protected] wrote:

Hi,

I have slackware current (is ready to use kernel 2.6.x) and I have made latest kernel 2.6rc1 to use with BayCom USCC>4/ISA card (with kernel 2.4.23 this card working) after load module AX25 and SCC and run sccinit this application not exit and frozen console and I have not success to use latest kernel with USCC card.

Not all patches (including one for your scc problem) are in 2.6.0-rc1 yet. I have attached the remaining ones to this message.

Jeroen

net/ax25/af_ax25.c +4 -3
diff -ru linux-2.6.0.rxq.applied/net/ax25/af_ax25.c linux-2.6.0.rxq/net/ax25/af_ax25.c
@@ -247,6 +247,7 @@
 				kfree_skb(copy);
 		}
 	}
+	spin_unlock_bh(&ax25_list_lock);
 }
 
 /*
@@ -1618,16 +1619,16 @@
 	if (msg->msg_namelen != 0) {
 		struct sockaddr_ax25 *sax = (struct sockaddr_ax25 *)msg->msg_name;
 		ax25_digi digi;
-		ax25_address dest;
+		ax25_address src;
 
-		ax25_addr_parse(skb->mac.raw+1, skb->data-skb->mac.raw-1, NULL, &dest, &digi, NULL, NULL);
+		ax25_addr_parse(skb->mac.raw+1, skb->data-skb->mac.raw-1, &src, NULL, &digi, NULL, NULL);
 
 		sax->sax25_family = AF_AX25;
 		/* We set this correctly, even though we may not let the
 		   application know the digi calls further down (because it
 		   did NOT ask to know them).  This could get political... **/
 		sax->sax25_ndigis = digi.ndigi;
-		sax->sax25_call   = dest;
+		sax->sax25_call   = src;
 
 		if (sax->sax25_ndigis != 0) {
 			int ct;
drivers/net/hamradio/mkiss.c +10 -10
@@ -167,17 +167,17 @@
 	/* If no channels are available, allocate one */
 	if (axp == NULL && (ax25_ctrls[i] = kmalloc(sizeof(ax25_ctrl_t), GFP_KERNEL)) != NULL) {
 		axp = ax25_ctrls[i];
-		memset(axp, 0, sizeof(ax25_ctrl_t));
-
-		/* Initialize channel control data */
-		set_bit(AXF_INUSE, &axp->ctrl.flags);
-		sprintf(axp->dev.name, "ax%d", i++);
-		axp->ctrl.tty      = NULL;
-		axp->dev.base_addr = i;
-		axp->dev.priv      = (void *)&axp->ctrl;
-		axp->dev.next      = NULL;
-		axp->dev.init      = ax25_init;
 	}
+	memset(axp, 0, sizeof(ax25_ctrl_t));
+
+	/* Initialize channel control data */
+	set_bit(AXF_INUSE, &axp->ctrl.flags);
+	sprintf(axp->dev.name, "ax%d", i++);
+	axp->ctrl.tty      = NULL;
+	axp->dev.base_addr = i;
+	axp->dev.priv      = (void *)&axp->ctrl;
+	axp->dev.next      = NULL;
+	axp->dev.init      = ax25_init;
 
 	if (axp != NULL) {
 		/*
drivers/net/hamradio/scc.c +5 -1
@@ -163,6 +163,7 @@
 #include <linux/delay.h>
 #include <linux/skbuff.h>
 #include <linux/netdevice.h>
+#include <linux/rtnetlink.h>
 #include <linux/if_ether.h>
 #include <linux/if_arp.h>
 #include <linux/socket.h>
@@ -1526,7 +1527,7 @@
 	scc->dev = dev;
 	spin_lock_init(&scc->lock);
 
-	err = register_netdev(dev);
+	err = register_netdevice(dev);
 	if (err) {
 		printk(KERN_ERR "%s: can't register network device (%d)\n", 
 		       name, err);
@@ -2119,10 +2120,13 @@
 	
 	sprintf(devname,"%s0", SCC_DriverName);
 	
+	rtnl_lock();
 	if (scc_net_alloc(devname, SCC_Info)) {
+		rtnl_unlock();
 		printk(KERN_ERR "z8530drv: cannot initialize module\n");
 		return -EIO;
 	}
+	rtnl_unlock();
 
 	proc_net_fops_create("z8530drv", 0, &scc_net_seq_fops);
 
#2 lore raw

Ops, I have tried not 2.6rc1 but 2.6.1-rc1 edition 31 december 2003.

Waldek

#3 lore raw
Quoted 1 line · On 2004.01.03 18:11:36 +0100 [email protected] wrote:

Ops, I have tried not 2.6rc1 but 2.6.1-rc1 edition 31 december 2003.

My fault to... I also ment 2.6.1-rc1....

You can still apply the patches I sent.

Jeroen

#4 lore raw

Hi,

Thank you for patches and I have recompiled kernel 2.6.1-rc1 with this patches and now USCC card working ! But in log I saw some worning after init USCC:

AX.25: Z8530 SCC driver version 3.0.dl1bke
mkiss: AX.25 Multikiss, Hans Albas PE1AYX
scc0: data port = 0x300 control port = 0x304 -- found
scc1: data port = 0x301 control port = 0x305 -- found
scc2: data port = 0x302 control port = 0x306 -- found
scc3: data port = 0x303 control port = 0x307 -- found Init Z8530 driver: 4 channels, IRQ 7 Uninitialised timer!
This is just a warning. Your computer is OK function=0x00000000, data=0x0

Call Trace:
 [<c0120b91>] check_timer_failed+0x51/0x60
 [<c0120ef7>] del_timer+0x17/0x90
 [<c8828ef8>] init_channel+0x18/0x7e0 [scc]
 [<c01091a8>] common_interrupt+0x18/0x20
 [<c882b516>] scc_net_open+0x36/0x50 [scc]
 [<c02626a3>] dev_open+0xb3/0xe0
 [<c0263b87>] dev_change_flags+0x57/0x130
 [<c029ac86>] devinet_ioctl+0x296/0x610
 [<c029cec4>] inet_ioctl+0xa4/0xe0
 [<c025b821>] sock_ioctl+0xf1/0x2b0
 [<c015b7cc>] sys_ioctl+0xec/0x260
 [<c0108f87>] syscall_call+0x7/0xb

Uninitialised timer!
This is just a warning. Your computer is OK function=0x00000000, data=0x0

Call Trace:
 [<c0120b91>] check_timer_failed+0x51/0x60
 [<c0120ef7>] del_timer+0x17/0x90
 [<c8828f04>] init_channel+0x24/0x7e0 [scc]
 [<c01091a8>] common_interrupt+0x18/0x20
 [<c882b516>] scc_net_open+0x36/0x50 [scc]
 [<c02626a3>] dev_open+0xb3/0xe0
 [<c0263b87>] dev_change_flags+0x57/0x130
 [<c029ac86>] devinet_ioctl+0x296/0x610
 [<c029cec4>] inet_ioctl+0xa4/0xe0
 [<c025b821>] sock_ioctl+0xf1/0x2b0
 [<c015b7cc>] sys_ioctl+0xec/0x260
 [<c0108f87>] syscall_call+0x7/0xb

Uninitialised timer!
This is just a warning. Your computer is OK function=0x00000000, data=0x0

Call Trace:
 [<c0120b91>] check_timer_failed+0x51/0x60
 [<c0120ef7>] del_timer+0x17/0x90
 [<c8828ef8>] init_channel+0x18/0x7e0 [scc]
 [<c02b567e>] masq_inet_event+0x1e/0x30
 [<c02b5690>] device_cmp+0x0/0x100
 [<c882b516>] scc_net_open+0x36/0x50 [scc]
 [<c02626a3>] dev_open+0xb3/0xe0
 [<c0263b87>] dev_change_flags+0x57/0x130
 [<c029ac86>] devinet_ioctl+0x296/0x610
 [<c029cec4>] inet_ioctl+0xa4/0xe0
 [<c025b821>] sock_ioctl+0xf1/0x2b0
 [<c015b7cc>] sys_ioctl+0xec/0x260
 [<c0108f87>] syscall_call+0x7/0xb

Uninitialised timer!
This is just a warning. Your computer is OK function=0x00000000, data=0x0

Call Trace:
 [<c0120b91>] check_timer_failed+0x51/0x60
 [<c0120ef7>] del_timer+0x17/0x90
 [<c8828f04>] init_channel+0x24/0x7e0 [scc]
 [<c02b567e>] masq_inet_event+0x1e/0x30
 [<c02b5690>] device_cmp+0x0/0x100
 [<c882b516>] scc_net_open+0x36/0x50 [scc]
 [<c02626a3>] dev_open+0xb3/0xe0
 [<c0263b87>] dev_change_flags+0x57/0x130
 [<c029ac86>] devinet_ioctl+0x296/0x610
 [<c029cec4>] inet_ioctl+0xa4/0xe0
 [<c025b821>] sock_ioctl+0xf1/0x2b0
 [<c015b7cc>] sys_ioctl+0xec/0x260
 [<c0108f87>] syscall_call+0x7/0xb
#5 lore raw
Quoted 6 lines · On 2004.01.03 21:33:33 +0100 [email protected] wrote:

Hi,

Thank you for patches and I have recompiled kernel 2.6.1-rc1 with this patches and now USCC card working ! But in log I saw some worning after init USCC:

Quoted 8 lines

AX.25: Z8530 SCC driver version 3.0.dl1bke
mkiss: AX.25 Multikiss, Hans Albas PE1AYX
scc0: data port = 0x300 control port = 0x304 -- found
scc1: data port = 0x301 control port = 0x305 -- found
scc2: data port = 0x302 control port = 0x306 -- found
scc3: data port = 0x303 control port = 0x307 -- found Init Z8530 driver: 4 channels, IRQ 7 Uninitialised timer!

Can you try the attached patch? It should fix the warnings.

Jeroen

drivers/net/hamradio/scc.c +2 -0
@@ -1525,5 +1526,7 @@
 	dev->priv = scc;
 	scc->dev = dev;
 	spin_lock_init(&scc->lock);
+	init_timer(&scc->tx_t);
+	init_timer(&scc->tx_wdog);
 
#6 lore raw

Re: Linux kernel 2.6.1-rc1 and USCC>4/ISA

Yes, I have applied these patches because without them I can't init USCC card. After recompile new kernel 2.6.1.-rc1 with patches I can init USCC card but in log I have some warnings about timer.

Waldek

#8 lore raw
In reply to Jeroen Vreeken

Hi Jeroen,

I did not notice attached new patch, sorry.

Now I have applied last your patch scc-linux-2.6.0.rxq2.diff I have not wornings in log about timers.

Thank you for very good support.

Waldek

#7 lore raw

Re: Linux kernel 2.6.1-rc1 and USCC>4/ISA

In reply to [email protected]
Quoted 4 lines · On 2004.01.04 17:43:13 +0100 [email protected] wrote:

Yes, I have applied these patches because without them I can't init USCC card. After recompile new kernel 2.6.1.-rc1 with patches I can init USCC card but in log I have some warnings about timer.

That's what the second patch is for :)
It should talk the warnings away.

Jeroen