Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 28 Aug 2003 22:46:02 +0200
From:      Thomas Moestl <t.moestl@tu-bs.de>
To:        Maxim Mazurok <maxim@km.ua>
Cc:        freebsd-sparc@freebsd.org
Subject:   Re: sio(4) driver
Message-ID:  <20030828204602.GA709@timesink.dyndns.org>
In-Reply-To: <20030828175336.GS8966@km.ua>
References:  <20030801132240.GA77415@km.ua> <20030801170417.GC834@crow.dom2ip.de> <20030822131349.GD21392@km.ua> <20030822145956.GA673@crow.dom2ip.de> <20030822185956.GL21392@km.ua> <20030823180012.GA668@crow.dom2ip.de> <20030828100032.GI8966@km.ua> <20030828104212.GL8966@km.ua> <20030828175336.GS8966@km.ua>

next in thread | previous in thread | raw e-mail | index | archive | help

--yrj/dFKFPuw6o+aM
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline

On Thu, 2003/08/28 at 20:53:36 +0300, Maxim Mazurok wrote:
> On Thu, Aug 28, 2003 at 01:42:12PM +0300, Maxim Mazurok wrote:
> 
> >ops. i wrong.
> >after recompile kernel width 
> >options         OFW_NEWPCI
> >my ethernet cards change numbers. rl0 ->rl3, rl1 -> rl0, rl2 -> rl1, rl3 ->
> >rl2.
> >you swapped scan of two bloks of pci slot.
> >it's good.
> >but i have one small problem :)
> >rl cards in my system see any remote arp's only if i run 'tcpdump -n -i rl1'
> >can you fix this?
> >and one more Q: you planned to commit this pathes (sio(4) and rl(4)) to CURRENT tree?
> >if i cvsup sources width '*default release=cvs tag=.' your latest patch for
> >sio(4) (sio-s64-20030822.diff) applied width errors. :)
> 
> oops. i have new problem :)

Try the attached patch.

	- Thomas

-- 
Thomas Moestl <t.moestl@tu-bs.de>	http://www.tu-bs.de/~y0015675/
              <tmm@FreeBSD.org>		http://people.FreeBSD.org/~tmm/
PGP fingerprint: 1C97 A604 2BD0 E492 51D0  9C0F 1FE6 4F1D 419C 776C

--yrj/dFKFPuw6o+aM
Content-Type: text/plain; charset=us-ascii
Content-Disposition: attachment; filename="ipfw-socklen.diff"

Index: ipfw2.c
===================================================================
RCS file: /vol/ncvs/src/sbin/ipfw/ipfw2.c,v
retrieving revision 1.38
diff -u -r1.38 ipfw2.c
--- ipfw2.c	21 Jul 2003 09:56:05 -0000	1.38
+++ ipfw2.c	21 Jul 2003 23:42:21 -0000
@@ -363,7 +363,7 @@
  * conditionally runs the command.
  */
 static int
-do_cmd(int optname, void *optval, socklen_t optlen)
+do_cmd(int optname, void *optval, uintptr_t optlen)
 {
 	static int s = -1;	/* the socket */
 	int i;
@@ -1556,7 +1556,7 @@
 		nbytes = sizeof(struct ip_fw);
 		if ((data = calloc(1, nbytes)) == NULL)
 			err(EX_OSERR, "calloc");
-		if (do_cmd(IP_FW_GET, data, (socklen_t)&nbytes) < 0)
+		if (do_cmd(IP_FW_GET, data, (uintptr_t)&nbytes) < 0)
 			err(EX_OSERR, "getsockopt(IP_FW_GET)");
 		bcopy(&((struct ip_fw *)data)->next_rule,
 			&set_disable, sizeof(set_disable));
@@ -1701,7 +1701,7 @@
 		nbytes = nalloc;
 		if ((data = realloc(data, nbytes)) == NULL)
 			err(EX_OSERR, "realloc");
-		if (do_cmd(ocmd, data, (socklen_t)&nbytes) < 0)
+		if (do_cmd(ocmd, data, (uintptr_t)&nbytes) < 0)
 			err(EX_OSERR, "getsockopt(IP_%s_GET)",
 				do_pipe ? "DUMMYNET" : "FW");
 	}
@@ -3493,7 +3493,7 @@
 
 	rule->cmd_len = (uint32_t *)dst - (uint32_t *)(rule->cmd);
 	i = (char *)dst - (char *)rule;
-	if (do_cmd(IP_FW_ADD, rule, (socklen_t)&i) == -1)
+	if (do_cmd(IP_FW_ADD, rule, (uintptr_t)&i) == -1)
 		err(EX_UNAVAILABLE, "getsockopt(%s)", "IP_FW_ADD");
 	if (!do_quiet)
 		show_ipfw(rule, 0, 0);

--yrj/dFKFPuw6o+aM--



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20030828204602.GA709>