Commit 038ccad1 authored by Maciej Lipinski's avatar Maciej Lipinski Committed by Alessandro Rubini

[rtud-ext] Added file to control RTU extended features - hardware-assited fast…

[rtud-ext] Added file to control RTU extended features - hardware-assited fast forwarding, mirroring, etc.
parent a4e7a965
PROGRAM = wrsw_rtud
SRCFILES = mac.c rtu_drv.c rtu_hash.c rtu_fd.c rtud.c \
SRCFILES = mac.c rtu_drv.c rtu_ext_drv.c rtu_hash.c rtu_fd.c rtud.c \
rtud_exports.c utils.c
OBJFILES = $(patsubst %.c,%.o,$(SRCFILES))
......
This diff is collapsed.
/*
* White Rabbit RTU (Routing Table Unit)
* Copyright (C) 2014, CERN.
*
* Version: wrsw_rtud v1.1
*
* Authors: Maciej Lipinski (maciej.lipinski@cern.ch)
*
* Description: RTU extension driver module in user space.
*
* Fixes:
*
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version
* 2 of the License, or (at your option) any later version.
*
* 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, see <http://www.gnu.org/licenses/>.
*/
#ifndef __WHITERABBIT_RTU_EXT_DRV_H
#define __WHITERABBIT_RTU_EXT_DRV_H
#include "rtu.h"
int rtux_init(void);
void rtux_add_ff_mac_single(int mac_id, int valid, uint8_t mac[ETH_ALEN]);
void rtux_add_ff_mac_range(int mac_id, int valid, uint8_t mac_lower[ETH_ALEN],
uint8_t mac_upper[ETH_ALEN]);
void rtux_set_port_mirror(uint32_t mirror_src_mask, uint32_t mirror_dst_mask, int rx, int tx);
void rtux_set_hp_prio_mask(uint8_t hp_prio_mask);
uint8_t rtux_get_hp_prio_mask();
int rtux_get_cpu_port();
void rtux_set_feature_ctrl(int mr, int mac_ptp, int mac_ll, int mac_single, int mac_range,
int mac_br, int at_fm);
void rtux_set_fw_to_CPU(int hp, int unrec);
void rtux_disp_ctrl(void);
#endif /*__WHITERABBIT_RTU_DRV_H*/
......@@ -47,6 +47,7 @@
#include "mac.h"
#include "rtu_fd.h"
#include "rtu_drv.h"
#include "rtu_ext_drv.h"
#include "rtu_hash.h"
#include "utils.h"
......@@ -272,6 +273,9 @@ static int rtu_daemon_init(uint16_t poly, unsigned long aging_time)
// init RTU HW
TRACE(TRACE_INFO, "init rtu hardware.");
err = rtu_init();
if(err)
return err;
err = rtux_init();
if(err)
return err;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment