Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
L
loop-detector
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container registry
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Issue analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
This is an archived project. Repository and other project resources are read-only.
Show more breadcrumbs
IOPSYS
loop-detector
Commits
dc941c16
Commit
dc941c16
authored
7 years ago
by
Sukru Senli
Browse files
Options
Downloads
Patches
Plain Diff
add copyright headers
parent
2e8584ae
Branches
Branches containing commit
No related tags found
No related merge requests found
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
Makefile
+1
-4
1 addition, 4 deletions
Makefile
README
+7
-8
7 additions, 8 deletions
README
ethernetThreadPool.c
+20
-5
20 additions, 5 deletions
ethernetThreadPool.c
loop-detector.c
+19
-3
19 additions, 3 deletions
loop-detector.c
mac_ethernet.c
+21
-6
21 additions, 6 deletions
mac_ethernet.c
with
68 additions
and
26 deletions
Makefile
+
1
−
4
View file @
dc941c16
#Makfile responsible to compile loop-detector sources
#Author: Omar Kallel <omar.kallel@pivasoftware.com>
#
#@Company: PivaSoftware, Inteno
#@author: Omar KALLEL
CPPFLAGS
=
$(
CPPOPTIONS
)
-DPATCH_MD
-DPATCH_HOSTAP
-D_GNU_SOURCE
-D__BUSYBOX__
-D_LIBC
CPPFLAGS
=
$(
CPPOPTIONS
)
-DPATCH_MD
-DPATCH_HOSTAP
-D_GNU_SOURCE
-D__BUSYBOX__
-D_LIBC
...
...
This diff is collapsed.
Click to expand it.
README
+
7
−
8
View file @
dc941c16
loop_detection is an openwrt package.
-------------------
It's responsible to detect layer 2 loops in a network and shutdown the equipment corresponding ehternet port.
About loop-detector
-------------------
It's developed by Omar KALLEL from pivasoftware company.
- Developed for OpenWrt systems.
- Responsible to detect layer 2 loops in a switch and shutdown the corresponding ehternet port.
- Developed by Omar KALLEL from Piva Software for Inteno Broadband Technology AB.
- GPLv2
**** Build ****
You should select in the menuconfig->Utilities loop_detection.
loop_detection used some libraries like : libpthread, libpcap, libuci. Those libraries should be selected, compiled and then installed in
the router.
\ No newline at end of file
This diff is collapsed.
Click to expand it.
ethernetThreadPool.c
+
20
−
5
View file @
dc941c16
/*
/*
* ethernetThreadPool.c
source file
contains functions that allows to:
* ethernetThreadPool.c
--
contains functions that allows to:
* -create threads responsible to listen coming frames in each ethernet port and make decision down the port that corresponds to a loop.
* -
create threads responsible to listen coming frames in each ethernet port and make decision down the port that corresponds to a loop.
* -create thread that send periodically loop discovery frame and make decision to up again an ethernet port
* -
create thread that send periodically loop discovery frame and make decision to up again an ethernet port
*
*
* @Company: PivaSoftware, Inteno
* Copyright (C) 2017 Inteno Broadband Technology AB. All rights reserved.
* @author: Omar Kallel
*
* Author: Omar Kallel <omar.kallel@pivasoftware.com>
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License
* version 2 as published by the Free Software Foundation.
*
* This program is distributed in the hope that 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.
*
* 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., 51 Franklin St, Fifth Floor, Boston, MA
* 02110-1301 USA
*/
*/
#include
<stdlib.h>
#include
<stdlib.h>
...
...
This diff is collapsed.
Click to expand it.
loop-detector.c
+
19
−
3
View file @
dc941c16
/*
/*
*
This is
the main file of loop_detection application.
*
loop-detector --
the main file of loop_detection application.
*
*
* @Company: PivaSoftware, Inteno
* Copyright (C) 2017 Inteno Broadband Technology AB. All rights reserved.
* @author: Omar Kallel
*
* Author: Omar Kallel <omar.kallel@pivasoftware.com>
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License
* version 2 as published by the Free Software Foundation.
*
* This program is distributed in the hope that 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.
*
* 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., 51 Franklin St, Fifth Floor, Boston, MA
* 02110-1301 USA
*/
*/
#include
<stdio.h>
#include
<stdio.h>
#include
<uci.h>
#include
<uci.h>
#include
<stdlib.h>
/* for atoi() and exit() */
#include
<stdlib.h>
/* for atoi() and exit() */
...
...
This diff is collapsed.
Click to expand it.
mac_ethernet.c
+
21
−
6
View file @
dc941c16
/*
/*
* mac_ethernet.c
source file
contains functions that allows to:
* mac_ethernet.c
--
contains functions that allows to:
* -interact with ehternet ports (up and down)
* -
interact with ehternet ports (up and down)
* -get the equipment mac address
* -
get the equipment mac address
* -create loop discovery frame that will be sent periodically
* -
create loop discovery frame that will be sent periodically
*
*
* @Company: PivaSoftware, Inteno
* Copyright (C) 2017 Inteno Broadband Technology AB. All rights reserved.
* @author: Omar Kallel
*
* Author: Omar Kallel <omar.kallel@pivasoftware.com>
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License
* version 2 as published by the Free Software Foundation.
*
* This program is distributed in the hope that 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.
*
* 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., 51 Franklin St, Fifth Floor, Boston, MA
* 02110-1301 USA
*/
*/
#include
<stdio.h>
#include
<stdio.h>
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment