Author: simon
Date: 2009-11-07 10:59:00 +0000 (Sat, 07 Nov 2009)
New Revision: 1462
Modified:
trunk/batman-adv-kernelland/Makefile
trunk/batman-adv-kernelland/Makefile.kbuild
trunk/batman-adv-kernelland/README
trunk/batman-adv-kernelland/aggregation.c
trunk/batman-adv-kernelland/aggregation.h
trunk/batman-adv-kernelland/bitarray.c
trunk/batman-adv-kernelland/bitarray.h
trunk/batman-adv-kernelland/compat.h
trunk/batman-adv-kernelland/device.c
trunk/batman-adv-kernelland/device.h
trunk/batman-adv-kernelland/hard-interface.c
trunk/batman-adv-kernelland/hard-interface.h
trunk/batman-adv-kernelland/hash.c
trunk/batman-adv-kernelland/hash.h
trunk/batman-adv-kernelland/log.c
trunk/batman-adv-kernelland/log.h
trunk/batman-adv-kernelland/main.c
trunk/batman-adv-kernelland/main.h
trunk/batman-adv-kernelland/packet.h
trunk/batman-adv-kernelland/proc.c
trunk/batman-adv-kernelland/proc.h
trunk/batman-adv-kernelland/ring_buffer.c
trunk/batman-adv-kernelland/ring_buffer.h
trunk/batman-adv-kernelland/routing.c
trunk/batman-adv-kernelland/routing.h
trunk/batman-adv-kernelland/send.c
trunk/batman-adv-kernelland/send.h
trunk/batman-adv-kernelland/soft-interface.c
trunk/batman-adv-kernelland/soft-interface.h
trunk/batman-adv-kernelland/translation-table.c
trunk/batman-adv-kernelland/translation-table.h
trunk/batman-adv-kernelland/types.h
trunk/batman-adv-kernelland/vis.c
trunk/batman-adv-kernelland/vis.h
Log:
update README and adjust year numbers in copyright notice
Modified: trunk/batman-adv-kernelland/Makefile
===================================================================
--- trunk/batman-adv-kernelland/Makefile 2009-11-04 23:12:40 UTC (rev 1461)
+++ trunk/batman-adv-kernelland/Makefile 2009-11-07 10:59:00 UTC (rev 1462)
@@ -1,6 +1,8 @@
#
-# Copyright (C) 2007-2008 B.A.T.M.A.N. contributors:
+# Copyright (C) 2007-2009 B.A.T.M.A.N. contributors:
+#
# Marek Lindner, Simon Wunderlich
+#
# This program is free software; you can redistribute it and/or
# modify it under the terms of version 2 of the GNU General Public
# License as published by the Free Software Foundation.
Modified: trunk/batman-adv-kernelland/Makefile.kbuild
===================================================================
--- trunk/batman-adv-kernelland/Makefile.kbuild 2009-11-04 23:12:40 UTC (rev 1461)
+++ trunk/batman-adv-kernelland/Makefile.kbuild 2009-11-07 10:59:00 UTC (rev 1462)
@@ -1,6 +1,8 @@
#
-# Copyright (C) 2007-2008 B.A.T.M.A.N. contributors:
+# Copyright (C) 2007-2009 B.A.T.M.A.N. contributors:
+#
# Marek Lindner, Simon Wunderlich
+#
# This program is free software; you can redistribute it and/or
# modify it under the terms of version 2 of the GNU General Public
# License as published by the Free Software Foundation.
Modified: trunk/batman-adv-kernelland/README
===================================================================
--- trunk/batman-adv-kernelland/README 2009-11-04 23:12:40 UTC (rev 1461)
+++ trunk/batman-adv-kernelland/README 2009-11-07 10:59:00 UTC (rev 1462)
@@ -1,11 +1,20 @@
-[state: 17-11-2008]
+[state: 07-11-2009]
BATMAN-ADV
----------
-The kernel implementation of batman-advanced. It does not depend on any network
-driver, and can be used on wifi as well as ethernet, vpn, etc ... (anything
-with ethernet-style layer 2).
+Batman-advanced is a new approach to wireless networking which does no longer
+operate on the IP basis. Unlike B.A.T.M.A.N, which exchanges information
+using UDP packets and sets routing tables, batman-advanced operates on ISO/OSI
+Layer 2 only and uses and routes (or better: bridges) Ethernet Frames. It
+emulates a virtual network switch of all nodes participating. Therefore all
+nodes appear to be link local, thus all higher operating protocols won't be
+affected by any changes within the network. You can run almost any protocol
+above B.A.T.M.A.N. Advanced, prominent examples are: IPv4, IPv6, DHCP, IPX.
+
+This is batman-advanced implemented as Linux kernel driver. It does not depend
+on any network (other) driver, and can be used on wifi as well as ethernet,
+vpn, etc ... (anything with ethernet-style layer 2).
It compiles against and should work with Linux 2.6.20 - 2.6.31. Supporting older
versions is not planned, but it's probably easy to backport it. If you work on a
backport, feel free to contact us. :-)
@@ -53,18 +62,54 @@
# echo "server" > /proc/net/batman-adv/vis
+Each node is either configured as "server" or as "client" (default:
+"client"). Clients send their topology data to the server next to them,
+and server synchronize with other servers. If there is no server
+configured (default) within the mesh, no topology information will be
+transmitted. With these "synchronizing servers", there can be 1 or
+more vis servers sharing the same (or at least very similar) data.
+
When configured as server, you can get a topology snapshot of your mesh:
# cat /proc/net/batman-adv/vis
-This output can be processed with graphviz-tools like dot.
+This output format is a graphviz formatted text file which can be
+processed with graphviz-tools like dot.
The labels are similar/compatible to the ETX metric, 1.0 means perfect
connection (100%), 2.0 means 50%, 3.0 means 33% and so on.
+Alternatively, a JSON output format is available. The format can be set
+using by writing either "dot_draw" or "json" into the vis_format file.
+"dot_draw" is selected by default.
+
+echo "json" > /proc/net/batman-adv/vis_format
+
+In very mobile scenarios, you might want to adjust the originator
+interval to a lower value. This will make the mesh more responsive to
+topology changes, but will also increase the overhead. Please make sure
+that all nodes in your mesh use the same interval. The default value
+is 1000 ms (1 second).
+
+# echo 1000 > /proc/net/batman-adv/orig_interval
+
To deactivate batman, do:
# echo "" > /proc/net/batman-adv/interfaces
+BATCTL
+------
+
+B.A.T.M.A.N. advanced operates on layer 2 and thus all hosts partici-
+pating in the virtual switch are completely transparent for all proto-
+cols above layer 2. Therefore the common diagnosis tools do not work as
+expected. To overcome these problems batctl was created. At the moment
+the batctl contains ping, traceroute, tcpdump and interfaces to the
+kernel module settings.
+
+For more information, please see the manpage (man batctl).
+
+batctl is available on http://www.open-mesh.net/
+
CONTACT
-------
Modified: trunk/batman-adv-kernelland/aggregation.c
===================================================================
--- trunk/batman-adv-kernelland/aggregation.c 2009-11-04 23:12:40 UTC (rev 1461)
+++ trunk/batman-adv-kernelland/aggregation.c 2009-11-07 10:59:00 UTC (rev 1462)
@@ -1,6 +1,8 @@
/*
* Copyright (C) 2007-2009 B.A.T.M.A.N. contributors:
+ *
* Marek Lindner, Simon Wunderlich
+ *
* This program is free software; you can redistribute it and/or
* modify it under the terms of version 2 of the GNU General Public
* License as published by the Free Software Foundation.
Modified: trunk/batman-adv-kernelland/aggregation.h
===================================================================
--- trunk/batman-adv-kernelland/aggregation.h 2009-11-04 23:12:40 UTC (rev 1461)
+++ trunk/batman-adv-kernelland/aggregation.h 2009-11-07 10:59:00 UTC (rev 1462)
@@ -1,6 +1,8 @@
/*
* Copyright (C) 2007-2009 B.A.T.M.A.N. contributors:
+ *
* Marek Lindner, Simon Wunderlich
+ *
* This program is free software; you can redistribute it and/or
* modify it under the terms of version 2 of the GNU General Public
* License as published by the Free Software Foundation.
Modified: trunk/batman-adv-kernelland/bitarray.c
===================================================================
--- trunk/batman-adv-kernelland/bitarray.c 2009-11-04 23:12:40 UTC (rev 1461)
+++ trunk/batman-adv-kernelland/bitarray.c 2009-11-07 10:59:00 UTC (rev 1462)
@@ -1,6 +1,8 @@
/*
- * Copyright (C) 2006-2008 B.A.T.M.A.N. contributors:
+ * Copyright (C) 2006-2009 B.A.T.M.A.N. contributors:
+ *
* Simon Wunderlich, Marek Lindner
+ *
* This program is free software; you can redistribute it and/or
* modify it under the terms of version 2 of the GNU General Public
* License as published by the Free Software Foundation.
Modified: trunk/batman-adv-kernelland/bitarray.h
===================================================================
--- trunk/batman-adv-kernelland/bitarray.h 2009-11-04 23:12:40 UTC (rev 1461)
+++ trunk/batman-adv-kernelland/bitarray.h 2009-11-07 10:59:00 UTC (rev 1462)
@@ -1,6 +1,8 @@
/*
- * Copyright (C) 2006-2008 B.A.T.M.A.N. contributors:
+ * Copyright (C) 2006-2009 B.A.T.M.A.N. contributors:
+ *
* Simon Wunderlich, Marek Lindner
+ *
* This program is free software; you can redistribute it and/or
* modify it under the terms of version 2 of the GNU General Public
* License as published by the Free Software Foundation.
Modified: trunk/batman-adv-kernelland/compat.h
===================================================================
--- trunk/batman-adv-kernelland/compat.h 2009-11-04 23:12:40 UTC (rev 1461)
+++ trunk/batman-adv-kernelland/compat.h 2009-11-07 10:59:00 UTC (rev 1462)
@@ -1,6 +1,8 @@
/*
- * Copyright (C) 2007-2008 B.A.T.M.A.N. contributors:
+ * Copyright (C) 2007-2009 B.A.T.M.A.N. contributors:
+ *
* Marek Lindner, Simon Wunderlich
+ *
* This program is free software; you can redistribute it and/or
* modify it under the terms of version 2 of the GNU General Public
* License as published by the Free Software Foundation.
Modified: trunk/batman-adv-kernelland/device.c
===================================================================
--- trunk/batman-adv-kernelland/device.c 2009-11-04 23:12:40 UTC (rev 1461)
+++ trunk/batman-adv-kernelland/device.c 2009-11-07 10:59:00 UTC (rev 1462)
@@ -1,6 +1,8 @@
/*
- * Copyright (C) 2007-2008 B.A.T.M.A.N. contributors:
+ * Copyright (C) 2007-2009 B.A.T.M.A.N. contributors:
+ *
* Marek Lindner
+ *
* This program is free software; you can redistribute it and/or
* modify it under the terms of version 2 of the GNU General Public
* License as published by the Free Software Foundation.
Modified: trunk/batman-adv-kernelland/device.h
===================================================================
--- trunk/batman-adv-kernelland/device.h 2009-11-04 23:12:40 UTC (rev 1461)
+++ trunk/batman-adv-kernelland/device.h 2009-11-07 10:59:00 UTC (rev 1462)
@@ -1,6 +1,8 @@
/*
- * Copyright (C) 2007-2008 B.A.T.M.A.N. contributors:
+ * Copyright (C) 2007-2009 B.A.T.M.A.N. contributors:
+ *
* Marek Lindner
+ *
* This program is free software; you can redistribute it and/or
* modify it under the terms of version 2 of the GNU General Public
* License as published by the Free Software Foundation.
Modified: trunk/batman-adv-kernelland/hard-interface.c
===================================================================
--- trunk/batman-adv-kernelland/hard-interface.c 2009-11-04 23:12:40 UTC (rev 1461)
+++ trunk/batman-adv-kernelland/hard-interface.c 2009-11-07 10:59:00 UTC (rev 1462)
@@ -1,6 +1,8 @@
/*
- * Copyright (C) 2007-2008 B.A.T.M.A.N. contributors:
+ * Copyright (C) 2007-2009 B.A.T.M.A.N. contributors:
+ *
* Marek Lindner, Simon Wunderlich
+ *
* This program is free software; you can redistribute it and/or
* modify it under the terms of version 2 of the GNU General Public
* License as published by the Free Software Foundation.
Modified: trunk/batman-adv-kernelland/hard-interface.h
===================================================================
--- trunk/batman-adv-kernelland/hard-interface.h 2009-11-04 23:12:40 UTC (rev 1461)
+++ trunk/batman-adv-kernelland/hard-interface.h 2009-11-07 10:59:00 UTC (rev 1462)
@@ -1,6 +1,8 @@
/*
- * Copyright (C) 2007-2008 B.A.T.M.A.N. contributors:
+ * Copyright (C) 2007-2009 B.A.T.M.A.N. contributors:
+ *
* Marek Lindner, Simon Wunderlich
+ *
* This program is free software; you can redistribute it and/or
* modify it under the terms of version 2 of the GNU General Public
* License as published by the Free Software Foundation.
Modified: trunk/batman-adv-kernelland/hash.c
===================================================================
--- trunk/batman-adv-kernelland/hash.c 2009-11-04 23:12:40 UTC (rev 1461)
+++ trunk/batman-adv-kernelland/hash.c 2009-11-07 10:59:00 UTC (rev 1462)
@@ -1,6 +1,8 @@
/*
- * Copyright (C) 2006-2008 B.A.T.M.A.N. contributors:
+ * Copyright (C) 2006-2009 B.A.T.M.A.N. contributors:
+ *
* Simon Wunderlich, Marek Lindner
+ *
* This program is free software; you can redistribute it and/or
* modify it under the terms of version 2 of the GNU General Public
* License as published by the Free Software Foundation.
Modified: trunk/batman-adv-kernelland/hash.h
===================================================================
--- trunk/batman-adv-kernelland/hash.h 2009-11-04 23:12:40 UTC (rev 1461)
+++ trunk/batman-adv-kernelland/hash.h 2009-11-07 10:59:00 UTC (rev 1462)
@@ -1,6 +1,8 @@
/*
- * Copyright (C) 2006-2008 B.A.T.M.A.N. contributors:
+ * Copyright (C) 2006-2009 B.A.T.M.A.N. contributors:
+ *
* Simon Wunderlich, Marek Lindner
+ *
* This program is free software; you can redistribute it and/or
* modify it under the terms of version 2 of the GNU General Public
* License as published by the Free Software Foundation.
Modified: trunk/batman-adv-kernelland/log.c
===================================================================
--- trunk/batman-adv-kernelland/log.c 2009-11-04 23:12:40 UTC (rev 1461)
+++ trunk/batman-adv-kernelland/log.c 2009-11-07 10:59:00 UTC (rev 1462)
@@ -1,6 +1,8 @@
/*
- * Copyright (C) 2007-2008 B.A.T.M.A.N. contributors:
+ * Copyright (C) 2007-2009 B.A.T.M.A.N. contributors:
+ *
* Marek Lindner, Simon Wunderlich
+ *
* This program is free software; you can redistribute it and/or
* modify it under the terms of version 2 of the GNU General Public
* License as published by the Free Software Foundation.
Modified: trunk/batman-adv-kernelland/log.h
===================================================================
--- trunk/batman-adv-kernelland/log.h 2009-11-04 23:12:40 UTC (rev 1461)
+++ trunk/batman-adv-kernelland/log.h 2009-11-07 10:59:00 UTC (rev 1462)
@@ -1,6 +1,8 @@
/*
- * Copyright (C) 2007-2008 B.A.T.M.A.N. contributors:
+ * Copyright (C) 2007-2009 B.A.T.M.A.N. contributors:
+ *
* Marek Lindner, Simon Wunderlich
+ *
* This program is free software; you can redistribute it and/or
* modify it under the terms of version 2 of the GNU General Public
* License as published by the Free Software Foundation.
Modified: trunk/batman-adv-kernelland/main.c
===================================================================
--- trunk/batman-adv-kernelland/main.c 2009-11-04 23:12:40 UTC (rev 1461)
+++ trunk/batman-adv-kernelland/main.c 2009-11-07 10:59:00 UTC (rev 1462)
@@ -1,6 +1,8 @@
/*
- * Copyright (C) 2007-2008 B.A.T.M.A.N. contributors:
+ * Copyright (C) 2007-2009 B.A.T.M.A.N. contributors:
+ *
* Marek Lindner, Simon Wunderlich
+ *
* This program is free software; you can redistribute it and/or
* modify it under the terms of version 2 of the GNU General Public
* License as published by the Free Software Foundation.
Modified: trunk/batman-adv-kernelland/main.h
===================================================================
--- trunk/batman-adv-kernelland/main.h 2009-11-04 23:12:40 UTC (rev 1461)
+++ trunk/batman-adv-kernelland/main.h 2009-11-07 10:59:00 UTC (rev 1462)
@@ -1,6 +1,8 @@
/*
- * Copyright (C) 2007-2008 B.A.T.M.A.N. contributors:
+ * Copyright (C) 2007-2009 B.A.T.M.A.N. contributors:
+ *
* Marek Lindner, Simon Wunderlich
+ *
* This program is free software; you can redistribute it and/or
* modify it under the terms of version 2 of the GNU General Public
* License as published by the Free Software Foundation.
Modified: trunk/batman-adv-kernelland/packet.h
===================================================================
--- trunk/batman-adv-kernelland/packet.h 2009-11-04 23:12:40 UTC (rev 1461)
+++ trunk/batman-adv-kernelland/packet.h 2009-11-07 10:59:00 UTC (rev 1462)
@@ -1,6 +1,8 @@
/*
* Copyright (C) 2007-2009 B.A.T.M.A.N. contributors:
+ *
* Marek Lindner, Simon Wunderlich
+ *
* This program is free software; you can redistribute it and/or
* modify it under the terms of version 2 of the GNU General Public
* License as published by the Free Software Foundation.
Modified: trunk/batman-adv-kernelland/proc.c
===================================================================
--- trunk/batman-adv-kernelland/proc.c 2009-11-04 23:12:40 UTC (rev 1461)
+++ trunk/batman-adv-kernelland/proc.c 2009-11-07 10:59:00 UTC (rev 1462)
@@ -1,6 +1,8 @@
/*
- * Copyright (C) 2007-2008 B.A.T.M.A.N. contributors:
+ * Copyright (C) 2007-2009 B.A.T.M.A.N. contributors:
+ *
* Marek Lindner, Simon Wunderlich
+ *
* This program is free software; you can redistribute it and/or
* modify it under the terms of version 2 of the GNU General Public
* License as published by the Free Software Foundation.
Modified: trunk/batman-adv-kernelland/proc.h
===================================================================
--- trunk/batman-adv-kernelland/proc.h 2009-11-04 23:12:40 UTC (rev 1461)
+++ trunk/batman-adv-kernelland/proc.h 2009-11-07 10:59:00 UTC (rev 1462)
@@ -1,6 +1,8 @@
/*
- * Copyright (C) 2007-2008 B.A.T.M.A.N. contributors:
+ * Copyright (C) 2007-2009 B.A.T.M.A.N. contributors:
+ *
* Marek Lindner, Simon Wunderlich
+ *
* This program is free software; you can redistribute it and/or
* modify it under the terms of version 2 of the GNU General Public
* License as published by the Free Software Foundation.
Modified: trunk/batman-adv-kernelland/ring_buffer.c
===================================================================
--- trunk/batman-adv-kernelland/ring_buffer.c 2009-11-04 23:12:40 UTC (rev 1461)
+++ trunk/batman-adv-kernelland/ring_buffer.c 2009-11-07 10:59:00 UTC (rev 1462)
@@ -1,6 +1,8 @@
/*
- * Copyright (C) 2007-2008 B.A.T.M.A.N. contributors:
+ * Copyright (C) 2007-2009 B.A.T.M.A.N. contributors:
+ *
* Marek Lindner
+ *
* This program is free software; you can redistribute it and/or
* modify it under the terms of version 2 of the GNU General Public
* License as published by the Free Software Foundation.
Modified: trunk/batman-adv-kernelland/ring_buffer.h
===================================================================
--- trunk/batman-adv-kernelland/ring_buffer.h 2009-11-04 23:12:40 UTC (rev 1461)
+++ trunk/batman-adv-kernelland/ring_buffer.h 2009-11-07 10:59:00 UTC (rev 1462)
@@ -1,6 +1,8 @@
/*
- * Copyright (C) 2007-2008 B.A.T.M.A.N. contributors:
+ * Copyright (C) 2007-2009 B.A.T.M.A.N. contributors:
+ *
* Marek Lindner
+ *
* This program is free software; you can redistribute it and/or
* modify it under the terms of version 2 of the GNU General Public
* License as published by the Free Software Foundation.
Modified: trunk/batman-adv-kernelland/routing.c
===================================================================
--- trunk/batman-adv-kernelland/routing.c 2009-11-04 23:12:40 UTC (rev 1461)
+++ trunk/batman-adv-kernelland/routing.c 2009-11-07 10:59:00 UTC (rev 1462)
@@ -1,6 +1,8 @@
/*
- * Copyright (C) 2007-2008 B.A.T.M.A.N. contributors:
+ * Copyright (C) 2007-2009 B.A.T.M.A.N. contributors:
+ *
* Marek Lindner, Simon Wunderlich
+ *
* This program is free software; you can redistribute it and/or
* modify it under the terms of version 2 of the GNU General Public
* License as published by the Free Software Foundation.
Modified: trunk/batman-adv-kernelland/routing.h
===================================================================
--- trunk/batman-adv-kernelland/routing.h 2009-11-04 23:12:40 UTC (rev 1461)
+++ trunk/batman-adv-kernelland/routing.h 2009-11-07 10:59:00 UTC (rev 1462)
@@ -1,6 +1,8 @@
/*
- * Copyright (C) 2007-2008 B.A.T.M.A.N. contributors:
+ * Copyright (C) 2007-2009 B.A.T.M.A.N. contributors:
+ *
* Marek Lindner, Simon Wunderlich
+ *
* This program is free software; you can redistribute it and/or
* modify it under the terms of version 2 of the GNU General Public
* License as published by the Free Software Foundation.
Modified: trunk/batman-adv-kernelland/send.c
===================================================================
--- trunk/batman-adv-kernelland/send.c 2009-11-04 23:12:40 UTC (rev 1461)
+++ trunk/batman-adv-kernelland/send.c 2009-11-07 10:59:00 UTC (rev 1462)
@@ -1,6 +1,8 @@
/*
* Copyright (C) 2007-2009 B.A.T.M.A.N. contributors:
+ *
* Marek Lindner, Simon Wunderlich
+ *
* This program is free software; you can redistribute it and/or
* modify it under the terms of version 2 of the GNU General Public
* License as published by the Free Software Foundation.
Modified: trunk/batman-adv-kernelland/send.h
===================================================================
--- trunk/batman-adv-kernelland/send.h 2009-11-04 23:12:40 UTC (rev 1461)
+++ trunk/batman-adv-kernelland/send.h 2009-11-07 10:59:00 UTC (rev 1462)
@@ -1,6 +1,8 @@
/*
* Copyright (C) 2007-2009 B.A.T.M.A.N. contributors:
+ *
* Marek Lindner, Simon Wunderlich
+ *
* This program is free software; you can redistribute it and/or
* modify it under the terms of version 2 of the GNU General Public
* License as published by the Free Software Foundation.
Modified: trunk/batman-adv-kernelland/soft-interface.c
===================================================================
--- trunk/batman-adv-kernelland/soft-interface.c 2009-11-04 23:12:40 UTC (rev 1461)
+++ trunk/batman-adv-kernelland/soft-interface.c 2009-11-07 10:59:00 UTC (rev 1462)
@@ -1,6 +1,8 @@
/*
- * Copyright (C) 2007-2008 B.A.T.M.A.N. contributors:
+ * Copyright (C) 2007-2009 B.A.T.M.A.N. contributors:
+ *
* Marek Lindner, Simon Wunderlich
+ *
* This program is free software; you can redistribute it and/or
* modify it under the terms of version 2 of the GNU General Public
* License as published by the Free Software Foundation.
Modified: trunk/batman-adv-kernelland/soft-interface.h
===================================================================
--- trunk/batman-adv-kernelland/soft-interface.h 2009-11-04 23:12:40 UTC (rev 1461)
+++ trunk/batman-adv-kernelland/soft-interface.h 2009-11-07 10:59:00 UTC (rev 1462)
@@ -1,6 +1,8 @@
/*
- * Copyright (C) 2007-2008 B.A.T.M.A.N. contributors:
+ * Copyright (C) 2007-2009 B.A.T.M.A.N. contributors:
+ *
* Marek Lindner
+ *
* This program is free software; you can redistribute it and/or
* modify it under the terms of version 2 of the GNU General Public
* License as published by the Free Software Foundation.
Modified: trunk/batman-adv-kernelland/translation-table.c
===================================================================
--- trunk/batman-adv-kernelland/translation-table.c 2009-11-04 23:12:40 UTC (rev 1461)
+++ trunk/batman-adv-kernelland/translation-table.c 2009-11-07 10:59:00 UTC (rev 1462)
@@ -1,6 +1,8 @@
/*
- * Copyright (C) 2007-2008 B.A.T.M.A.N. contributors:
+ * Copyright (C) 2007-2009 B.A.T.M.A.N. contributors:
+ *
* Marek Lindner, Simon Wunderlich
+ *
* This program is free software; you can redistribute it and/or
* modify it under the terms of version 2 of the GNU General Public
* License as published by the Free Software Foundation.
Modified: trunk/batman-adv-kernelland/translation-table.h
===================================================================
--- trunk/batman-adv-kernelland/translation-table.h 2009-11-04 23:12:40 UTC (rev 1461)
+++ trunk/batman-adv-kernelland/translation-table.h 2009-11-07 10:59:00 UTC (rev 1462)
@@ -1,6 +1,8 @@
/*
- * Copyright (C) 2007-2008 B.A.T.M.A.N. contributors:
+ * Copyright (C) 2007-2009 B.A.T.M.A.N. contributors:
+ *
* Marek Lindner, Simon Wunderlich
+ *
* This program is free software; you can redistribute it and/or
* modify it under the terms of version 2 of the GNU General Public
* License as published by the Free Software Foundation.
Modified: trunk/batman-adv-kernelland/types.h
===================================================================
--- trunk/batman-adv-kernelland/types.h 2009-11-04 23:12:40 UTC (rev 1461)
+++ trunk/batman-adv-kernelland/types.h 2009-11-07 10:59:00 UTC (rev 1462)
@@ -1,6 +1,8 @@
/*
- * Copyright (C) 2007-2008 B.A.T.M.A.N. contributors:
+ * Copyright (C) 2007-2009 B.A.T.M.A.N. contributors:
+ *
* Marek Lindner, Simon Wunderlich
+ *
* This program is free software; you can redistribute it and/or
* modify it under the terms of version 2 of the GNU General Public
* License as published by the Free Software Foundation.
Modified: trunk/batman-adv-kernelland/vis.c
===================================================================
--- trunk/batman-adv-kernelland/vis.c 2009-11-04 23:12:40 UTC (rev 1461)
+++ trunk/batman-adv-kernelland/vis.c 2009-11-07 10:59:00 UTC (rev 1462)
@@ -1,6 +1,8 @@
/*
- * Copyright (C) 2008 B.A.T.M.A.N. contributors:
+ * Copyright (C) 2008-2009 B.A.T.M.A.N. contributors:
+ *
* Simon Wunderlich
+ *
* This program is free software; you can redistribute it and/or
* modify it under the terms of version 2 of the GNU General Public
* License as published by the Free Software Foundation.
Modified: trunk/batman-adv-kernelland/vis.h
===================================================================
--- trunk/batman-adv-kernelland/vis.h 2009-11-04 23:12:40 UTC (rev 1461)
+++ trunk/batman-adv-kernelland/vis.h 2009-11-07 10:59:00 UTC (rev 1462)
@@ -1,6 +1,8 @@
/*
- * Copyright (C) 2008 B.A.T.M.A.N. contributors:
+ * Copyright (C) 2008-2009 B.A.T.M.A.N. contributors:
+ *
* Simon Wunderlich, Marek Lindner
+ *
* This program is free software; you can redistribute it and/or
* modify it under the terms of version 2 of the GNU General Public
* License as published by the Free Software Foundation.
Author: simon
Date: 2009-11-07 14:04:18 +0000 (Sat, 07 Nov 2009)
New Revision: 1471
Modified:
trunk/batman-adv-kernelland/device.c
Log:
unlock in bat_device_add_packet() before returning (thanks Sven)
Modified: trunk/batman-adv-kernelland/device.c
===================================================================
--- trunk/batman-adv-kernelland/device.c 2009-11-07 13:50:40 UTC (rev 1470)
+++ trunk/batman-adv-kernelland/device.c 2009-11-07 14:04:18 UTC (rev 1471)
@@ -306,6 +306,7 @@
/* while waiting for the lock the device_client could have been
* deleted */
if (!device_client_hash[icmp_packet->uid]) {
+ spin_unlock(&device_client->lock);
kfree(device_packet);
return;
}
Author: simon
Date: 2009-11-07 13:29:35 +0000 (Sat, 07 Nov 2009)
New Revision: 1468
Modified:
trunk/batman-adv-kernelland/hard-interface.c
Log:
fix memory leak when there is a problem adding an interface
Modified: trunk/batman-adv-kernelland/hard-interface.c
===================================================================
--- trunk/batman-adv-kernelland/hard-interface.c 2009-11-07 13:21:17 UTC (rev 1467)
+++ trunk/batman-adv-kernelland/hard-interface.c 2009-11-07 13:29:35 UTC (rev 1468)
@@ -400,6 +400,8 @@
return 1;
out:
+ if (batman_if->packet_buff)
+ kfree(batman_if->packet_buff);
kfree(batman_if);
kfree(dev);
return -1;
Author: simon
Date: 2009-11-07 13:21:17 +0000 (Sat, 07 Nov 2009)
New Revision: 1467
Modified:
trunk/batman-adv-kernelland/bitarray.h
Log:
remove obsolete functions from bitarray.h (thanks Sven)
Modified: trunk/batman-adv-kernelland/bitarray.h
===================================================================
--- trunk/batman-adv-kernelland/bitarray.h 2009-11-07 12:50:34 UTC (rev 1466)
+++ trunk/batman-adv-kernelland/bitarray.h 2009-11-07 13:21:17 UTC (rev 1467)
@@ -24,9 +24,6 @@
#define TYPE_OF_WORD unsigned long
#define WORD_BIT_SIZE (sizeof(TYPE_OF_WORD) * 8)
-/* clear the bits, ready for use */
-void bit_init(TYPE_OF_WORD *seq_bits);
-
/* returns true if the corresponding bit in the given seq_bits indicates true
* and curr_seqno is within range of last_seqno */
uint8_t get_bit_status(TYPE_OF_WORD *seq_bits, uint16_t last_seqno,
@@ -46,6 +43,3 @@
/* count the hamming weight, how many good packets did we receive? */
int bit_packet_count(TYPE_OF_WORD *seq_bits);
-
-/* print the packet array, for debugging purposes */
-char *bit_print(TYPE_OF_WORD *seq_bits);
Author: marek
Date: 2009-11-04 23:12:34 +0000 (Wed, 04 Nov 2009)
New Revision: 1460
Modified:
trunk/batman-adv-kernelland/routing.c
Log:
[batman-adv] avoid temporary routing loops
Modified: trunk/batman-adv-kernelland/routing.c
===================================================================
--- trunk/batman-adv-kernelland/routing.c 2009-10-26 20:48:30 UTC (rev 1459)
+++ trunk/batman-adv-kernelland/routing.c 2009-11-04 23:12:34 UTC (rev 1460)
@@ -344,18 +344,28 @@
tmp_hna_buff_len = (hna_buff_len > batman_packet->num_hna * ETH_ALEN ? batman_packet->num_hna * ETH_ALEN : hna_buff_len);
- /**
- * if we got have a better tq value via this neighbour or
- * same tq value but the link is more symetric change the next hop
- * router
- */
- if ((orig_node->router != neigh_node) && ((!orig_node->router) ||
- (neigh_node->tq_avg > orig_node->router->tq_avg) ||
- ((neigh_node->tq_avg == orig_node->router->tq_avg) &&
- (neigh_node->orig_node->bcast_own_sum[if_incoming->if_num] > orig_node->router->orig_node->bcast_own_sum[if_incoming->if_num]))))
- update_routes(orig_node, neigh_node, hna_buff, tmp_hna_buff_len);
- else
- update_routes(orig_node, orig_node->router, hna_buff, tmp_hna_buff_len);
+ /* if this neighbor already is our next hop there is nothing to change */
+ if (orig_node->router == neigh_node)
+ goto update_hna;
+
+ /* if this neighbor does not offer a better TQ we won't consider it */
+ if ((orig_node->router) &&
+ (orig_node->router->tq_avg > neigh_node->tq_avg))
+ goto update_hna;
+
+ /* if the TQ is the same and the link not more symetric we won't consider it either */
+ if ((orig_node->router) &&
+ ((neigh_node->tq_avg == orig_node->router->tq_avg) &&
+ (orig_node->router->orig_node->bcast_own_sum[if_incoming->if_num] >
+ neigh_node->orig_node->bcast_own_sum[if_incoming->if_num])))
+ goto update_hna;
+
+ update_routes(orig_node, neigh_node, hna_buff, tmp_hna_buff_len);
+ return;
+
+update_hna:
+ update_routes(orig_node, orig_node->router, hna_buff, tmp_hna_buff_len);
+ return;
}
static char count_real_packets(struct ethhdr *ethhdr, struct batman_packet *batman_packet, struct batman_if *if_incoming)
@@ -402,7 +412,7 @@
/* Silently drop when the batman packet is actually not a correct packet.
*
- * This might happen if a packet is padded (e.g. Ethernet has a
+ * This might happen if a packet is padded (e.g. Ethernet has a
* minimum frame length of 64 byte) and the aggregation interprets
* it as an additional length.
*
@@ -491,6 +501,15 @@
if (orig_node == NULL)
return;
+ /* avoid temporary routing loops */
+ if ((orig_node->router) && (orig_node->router->orig_node->router) &&
+ (compare_orig(orig_node->router->addr, batman_packet->prev_sender)) &&
+ !(compare_orig(batman_packet->orig, batman_packet->prev_sender)) &&
+ (compare_orig(orig_node->router->addr, orig_node->router->orig_node->router->addr))) {
+ debug_log(LOG_TYPE_BATMAN, "Drop packet: ignoring all rebroadcast packets that may make me loop (sender: %s) \n", neigh_str);
+ return;
+ }
+
/* if sender is a direct neighbor the sender mac equals originator mac */
orig_neigh_node = (is_single_hop_neigh ? orig_node : get_orig_node(ethhdr->h_source));
if (orig_neigh_node == NULL)