Re: Routes not deleted after link down

2005-06-19 Thread Michal Vanco
On Sunday 19 June 2005 10:29, Gleb Smirnoff wrote:
 On Sat, Jun 18, 2005 at 10:14:32PM +0200, Jose M Rodriguez wrote:
 J Second, you may need a route daemon for this.  ospf is a well known
 J canditate where convergence in case of lost link is a must.

 While an OSPF daemon may stop advertising the affected route to its
 neighbors, the kernel will still have the route installed and thus
 the box won't be able to contact other hosts on the connected net,
 while they are reachable via alternate pass.

Routing protocol should be responsible for removing affected routes from FIB. 
For example quagga should remove all routes learned via particular ospf 
neighbour when that neighbour is not reachable anymore due to link goes down. 
But in case when no daemons are used (`static' and `connected' are also 
`routing protocols'), kernel should be responsible for doing that.

 I've checked that Cisco routers remove route from FIB when interface
 link goes down. I haven't checked Junipers yet.

Junipers do the same. It is the only feasible behaviour for router.


 From my viewpoint, removing route (or marking it unusable) is a correct
 behavior for router. Not sure it is correct for desktop.


Sure.

 My vote is that we should implement this functionality and make it
 switchable via sysctl. I'd leave the default as is.


Agree.


pgp8nMK3Ubf8W.pgp
Description: PGP signature


Routes not deleted after link down

2005-06-18 Thread Michal Vanco
Hi,

i discovered that routes are not deleted from routing table after
link on interface goes down. For example:

 netstat -rnf inet | grep bge0
default10.1.14.1  UGS 0   135968   bge0
10.1/17link#1 UC  00   bge0

 route -n monitor

got message of size 96 on Sat Jun 18 15:10:38 2005
RTM_IFINFO: iface status change: len 96, if# 1, link: down,
+flags:UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST

 netstat -rnf inet | grep bge0
default10.1.14.1  UGS 0   136011   bge0
10.1/17link#1 UC  00   bge0

Should't all routes via bge0 be deleted after link on bge0 goes down?

thanks
michal


___
freebsd-stable@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-stable
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: Routes not deleted after link down

2005-06-18 Thread Michal Vanco
On Saturday 18 June 2005 20:48, Chuck Swiger wrote:
 Michal Vanco wrote:
  i discovered that routes are not deleted from routing table after
  link on interface goes down. For example:

 [ ... ]

  Should't all routes via bge0 be deleted after link on bge0 goes down?

 Maybe.  If the system was not going to be reconnected to that network
 anytime soon, it would be a good idea.  On the other hand, if the link down
 was due to a transient failure of a wireless connection, which will be back
 up in a second or two, it's much better not to drop the route and kill any
 open connections.

hmm ... this approach is may be appropriate for deskop instalation. what about 
internet router? shouldn't fast convergence be better in this case? imagine 
two links connected to the same router with different metrics. if first of 
them goes down, the second never gets used in this case.

michal
___
freebsd-stable@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-stable
To unsubscribe, send any mail to [EMAIL PROTECTED]


MS USB Wireless Mouse

2005-06-13 Thread Michal Vanco

Hi,

my problem with %subj% continues. Recently I have forced ums to detect 
it as mouse but there are still some weird things.


ums0: Microsoft Microsoft USB Wireless Mouse, rev 2.00/0.17, addr 2, 
iclass 3/1
ums_attach: bLength=7 bDescriptorType=5 bEndpointAddress=1-in 
bmAttributes=3 wMaxPacketSize=8 bInterval=10

ums0: 5 buttons and Z dir.
ums_attach: sc=0xc1bcb800
ums_attach: X   48/8
ums_attach: Y   56/8
ums_attach: Z   64/8
ums_attach: B1  40/1
ums_attach: B2  41/1
ums_attach: B3  42/1
ums_attach: B4  43/1
ums_attach: B5  44/1
ums_attach: size=11, id=19

... seems like reported locations X,Y,Z and buttons are wrong.

any clues?
thanx
michal

___
freebsd-stable@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-stable
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: MS USB Wireless Mouse

2005-06-13 Thread Michal Vanco

Michal Vanco wrote:


... seems like reported locations X,Y,Z and buttons are wrong.


well ... this works. but i'm not sure for other mices

diff -Nrua usb/ums.c /sys/dev/usb/ums.c
--- usb/ums.c   Sun Jan 30 02:00:10 2005
+++ /sys/dev/usb/ums.c  Mon Jun 13 16:24:50 2005
@@ -76,6 +76,7 @@
#include machine/mouse.h
#endif

+
#ifdef USB_DEBUG
#define DPRINTF(x) if (umsdebug) logprintf x
#define DPRINTFN(n,x)  if (umsdebug(n)) logprintf x
@@ -287,6 +288,9 @@
   if (hid_locate(desc, size, HID_USAGE2(HUP_GENERIC_DESKTOP, 
HUG_TWHEEL),

   hid_input, sc-sc_loc_t, flags)) {
   sc-sc_loc_t.pos = sc-sc_loc_t.pos + 8;
+   sc-sc_loc_x.pos = sc-sc_loc_x.pos - 40;
+   sc-sc_loc_y.pos = sc-sc_loc_y.pos - 40;
+   sc-sc_loc_z.pos = sc-sc_loc_z.pos - 40;
   sc-flags |= UMS_T;
   }

@@ -307,9 +311,12 @@
  sc-nbuttons, sc-flags  UMS_Z?  and Z dir : ,
  sc-flags  UMS_T? and a TILT dir: );

-   for (i = 1; i = sc-nbuttons; i++)
+   for (i = 1; i = sc-nbuttons; i++) {
   hid_locate(desc, size, HID_USAGE2(HUP_BUTTON, i),
   hid_input, sc-sc_loc_btn[i-1], 0);
+   if (sc-flags  UMS_T)
+ sc-sc_loc_btn[i - 1].pos -= 40;
+   }

   sc-sc_isize = hid_report_size(desc, size, hid_input, sc-sc_iid);
   sc-sc_ibuf = malloc(sc-sc_isize, M_USB, M_NOWAIT);
@@ -458,8 +465,9 @@
*/
   if (sc-flags  UMS_T) {
   if (sc-sc_iid) {
-   if (*ibuf++ == 0x02)
-   return;
+ ibuf++;
+ if (*(ibuf - 1) == 0x02 || *(ibuf - 1) == 0x14)
+ return;
   }
   } else {
   if (sc-sc_iid) {

___
freebsd-stable@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-stable
To unsubscribe, send any mail to [EMAIL PROTECTED]


Microsoft USB Wireless Mouse not working

2005-06-10 Thread Michal Vanco
Hi,

I'm running 5.4-STABLE and I'm not able to get my MS USB Wireless mouse
working.
After plugging the mouse I see this in my dmesg:
uhid0: Microsoft Microsoft USB Wireless Mouse, rev 2.00/0.17, addr 2,
iclass 3/1

But there is no ums device. I have device ums in kernel.

Is there any patch available to get this working?

thanks in advance
michal

___
freebsd-stable@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-stable
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: Microsoft USB Wireless Mouse not working

2005-06-10 Thread Michal Vanco
Ronald Klop wrote:

 On Fri, 10 Jun 2005 15:38:42 +0200, Michal Vanco [EMAIL PROTECTED] wrote:

 Hi,

 I'm running 5.4-STABLE and I'm not able to get my MS USB Wireless mouse
 working.
 After plugging the mouse I see this in my dmesg:
 uhid0: Microsoft Microsoft USB Wireless Mouse, rev 2.00/0.17, addr 2,
 iclass 3/1

 But there is no ums device. I have device ums in kernel.

 Is there any patch available to get this working?


 Do you also have 'uhid' in your kernel or loaded as a module? Maybe it
 attaches before ums. If yes, try removing it from your kernel and boot
 again. This is just a thought, so maybe it doesn't work.

hmm ... but for other USB mices (wired) it works normaly. doesn't ums
depend on uhid?

michal


___
freebsd-stable@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-stable
To unsubscribe, send any mail to [EMAIL PROTECTED]