1
0
mirror of git://projects.qi-hardware.com/openwrt-xburst.git synced 2024-11-15 09:50:16 +02:00
Commit Graph

49 Commits

Author SHA1 Message Date
juhosg
1cfcccb5b0 linux: rtl836x: add a generic reset_switch function
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@31536 3c298f89-4303-0410-b956-a3cf2f4a3e73
2012-04-29 18:29:31 +00:00
juhosg
5df734f0bc linux: rtl836x: rename rtl836*_hw_init to rtl836*_setup
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@31535 3c298f89-4303-0410-b956-a3cf2f4a3e73
2012-04-29 18:29:29 +00:00
juhosg
1dcdbf2d3f linux: rtl836x: add a reset_chip callback to rtl8366_smi_ops
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@31534 3c298f89-4303-0410-b956-a3cf2f4a3e73
2012-04-29 18:29:26 +00:00
juhosg
1f9f293936 generic: rtl8366s: use the generic get_port_link implementation
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@30843 3c298f89-4303-0410-b956-a3cf2f4a3e73
2012-03-07 16:32:38 +00:00
juhosg
e2bae31171 generic: rtl8366: add rtl8366_smi_write_reg_noack helper
After issuing a soft reset on the RT8366{S,RB}
switch, waiting for the last acknowlegement fails
in rtl8366_smi_write_reg. Add a _noack version of
the function and use that for issuing a soft reset.

git-svn-id: svn://svn.openwrt.org/openwrt/trunk@29844 3c298f89-4303-0410-b956-a3cf2f4a3e73
2012-01-21 22:44:09 +00:00
juhosg
d80f2ee46b generic: rtl8366: preparing for RTL8367 support
* make clock delay configurable
* make read,write commands configurable
* use u16 for member and untag fields

git-svn-id: svn://svn.openwrt.org/openwrt/trunk@29677 3c298f89-4303-0410-b956-a3cf2f4a3e73
2012-01-07 19:36:30 +00:00
juhosg
a176de7d8d generic: jumbo frames support for rtl8366s
This patch adds the option to enable jumbo frames on the rtl8366s
switch. This is almost exactly the same as the first patch at
https://dev.openwrt.org/ticket/7977 and it has been requested
in a comment there.

I have tested this and it successfully allows devices on the switch
using jumbo frames to communicate.

Signed-off-by: Ash Hughes <ashley.hughes@blueyonder.co.uk>

git-svn-id: svn://svn.openwrt.org/openwrt/trunk@28267 3c298f89-4303-0410-b956-a3cf2f4a3e73
2011-09-21 11:47:38 +00:00
jogo
6c853478d6 swconfig: Add generic switch identifiers
Also make switches available under a generic name "switch<num>" for device
name agnostic access. The old device name is used as an alias for backward
compatibility.

git-svn-id: svn://svn.openwrt.org/openwrt/trunk@27800 3c298f89-4303-0410-b956-a3cf2f4a3e73
2011-07-27 18:00:18 +00:00
nbd
de95026813 rtl8366: unify rtl8366s and rtl8366rb platform data
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@27754 3c298f89-4303-0410-b956-a3cf2f4a3e73
2011-07-24 14:40:23 +00:00
juhosg
c67c0978c5 generic: rtl8366{s,rb}: remove the PHY driver.
Since the PHY driver is only used for the WAN port and there is virtually
no difference between it and the generic PHY driver, we can sefely remove
it.

Signed-off-by: Jonas Gorski <jonas.gorski+openwrt@gmail.com>

git-svn-id: svn://svn.openwrt.org/openwrt/trunk@26600 3c298f89-4303-0410-b956-a3cf2f4a3e73
2011-04-12 09:29:07 +00:00
juhosg
f1f92beb2e generic: rtl8366s: allow initial register values to be passed via platform_data
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@25120 3c298f89-4303-0410-b956-a3cf2f4a3e73
2011-01-26 20:35:46 +00:00
juhosg
784b0f3ae6 generic: rtl8366: enable vlans before enabling the ports
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@24939 3c298f89-4303-0410-b956-a3cf2f4a3e73
2011-01-08 20:24:29 +00:00
juhosg
5082ee8d98 generic: rtl8366: enable ports only after VLAN configuration is done
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@24938 3c298f89-4303-0410-b956-a3cf2f4a3e73
2011-01-08 20:24:26 +00:00
juhosg
14f9ab7993 generic: rtl8366: add enable_port helper
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@24937 3c298f89-4303-0410-b956-a3cf2f4a3e73
2011-01-08 20:24:22 +00:00
juhosg
cf57ba0b68 generic: rtl8366s: use correct bitmasks in sanity checks
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@24935 3c298f89-4303-0410-b956-a3cf2f4a3e73
2011-01-08 18:04:04 +00:00
juhosg
891f8034ba generic: rtl8366s: add vlan fid support
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@24934 3c298f89-4303-0410-b956-a3cf2f4a3e73
2011-01-08 18:04:00 +00:00
nbd
9c885bdb22 rt8366*: use __devinit instead of __init for the probe function to fix a section mismatch
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@23573 3c298f89-4303-0410-b956-a3cf2f4a3e73
2010-10-21 18:42:05 +00:00
juhosg
8c86c48cec generic: RTL8366S/RB: Fix autonegotiation for the WAN port.
The RTL8366S/RB support connecting a second mac to it and using the 5th
port as an independent phy. Therefore we need to handle autonegotiation
changes for phy 4 like on a single phy device.

This fixes #7980, verified on a WNDR3700.

Signed-off-by: Jonas Gorski <jonas.gorski+openwrt@gmail.com>

git-svn-id: svn://svn.openwrt.org/openwrt/trunk@23127 3c298f89-4303-0410-b956-a3cf2f4a3e73
2010-09-27 14:42:05 +00:00
juhosg
0c4c78bf4c generic: rtl8366: allow use of VIDs 16-4095 if vlan4k is enabled
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@22704 3c298f89-4303-0410-b956-a3cf2f4a3e73
2010-08-18 16:00:39 +00:00
juhosg
356b45cef3 generic: rtl8366: add generic code to enable VLANs
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@22703 3c298f89-4303-0410-b956-a3cf2f4a3e73
2010-08-18 16:00:37 +00:00
juhosg
3b7b50fb89 generic: rtl8366: add enable_vlan{,4k} to smi_ops
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@22702 3c298f89-4303-0410-b956-a3cf2f4a3e73
2010-08-18 16:00:34 +00:00
juhosg
fbab069d3f generic: fix LED control on the RTL8366 switches
* patch from #7713

git-svn-id: svn://svn.openwrt.org/openwrt/trunk@22656 3c298f89-4303-0410-b956-a3cf2f4a3e73
2010-08-15 06:47:42 +00:00
nbd
1fc3901363 rtl8366: re-enable learning by default, disabling it broke switching functionality.
add a configuration option for dynamically enabling/disabling this feature.
based on patch from #7637

git-svn-id: svn://svn.openwrt.org/openwrt/trunk@22545 3c298f89-4303-0410-b956-a3cf2f4a3e73
2010-08-08 20:15:10 +00:00
nbd
f093fbf8a3 swconfig: cleanup of kernel drivers and interface
- add some comments to a few data structures
- add a switch_dev_ops data structure for attributes and callback to replace the stupid template memcpy
- get rid of the switch_dev.priv pointer - using container_of() is better

git-svn-id: svn://svn.openwrt.org/openwrt/trunk@22476 3c298f89-4303-0410-b956-a3cf2f4a3e73
2010-08-04 00:43:40 +00:00
juhosg
8007d48891 generic: rtl8366: add common rtl8366_sw_{get,set}_vlan_ports functions
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@22204 3c298f89-4303-0410-b956-a3cf2f4a3e73
2010-07-15 13:05:50 +00:00
juhosg
dac77d22af generic: rtl8366: add common rtl8366_sw_get_vlan_info
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@22203 3c298f89-4303-0410-b956-a3cf2f4a3e73
2010-07-15 13:05:47 +00:00
juhosg
4bcb729a13 generic: rtl8366: use smi->num_ports and smi->ops->get_vlan_4k
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@22202 3c298f89-4303-0410-b956-a3cf2f4a3e73
2010-07-15 13:05:43 +00:00
juhosg
fc85856afd generic: rtl8366: add is_vlan_valid function to smi_ops
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@22201 3c298f89-4303-0410-b956-a3cf2f4a3e73
2010-07-15 13:05:39 +00:00
juhosg
5476411f3d generic: rtl8366: add common rtl8366_sw_get_port_mib function
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@22200 3c298f89-4303-0410-b956-a3cf2f4a3e73
2010-07-15 13:05:36 +00:00
juhosg
a072aff468 generic: rtl8366: generealize rtl8366{s,rb}_sw_get_port_mib functions
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@22199 3c298f89-4303-0410-b956-a3cf2f4a3e73
2010-07-15 13:05:32 +00:00
juhosg
6938bc08df generic: rtl8366: add common rtl8366_sw_{get,set}_port_pvid functions
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@22197 3c298f89-4303-0410-b956-a3cf2f4a3e73
2010-07-15 13:05:25 +00:00
juhosg
e920aacf90 generic: rtl8366: add setup to rtl8366_smi_ops struct
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@22196 3c298f89-4303-0410-b956-a3cf2f4a3e73
2010-07-15 13:05:21 +00:00
juhosg
ec7835703b generic: rtl8366: introduce rtl8366_smi_alloc
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@22195 3c298f89-4303-0410-b956-a3cf2f4a3e73
2010-07-15 13:05:16 +00:00
juhosg
a8fb744861 generic: rtl8366: get rid of private rtl8366{s,rb} structs
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@22194 3c298f89-4303-0410-b956-a3cf2f4a3e73
2010-07-15 13:05:10 +00:00
juhosg
e2d43315df generic: rtl8366: move switch device to the rtl8366_smi struct
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@22193 3c298f89-4303-0410-b956-a3cf2f4a3e73
2010-07-15 13:05:06 +00:00
juhosg
320e8ef881 generic: rtl8366: get rid of private vlan_{mc,4k} structs
The usage of bitfields causes problems in Little-Endian mode. Remove
them and manipulate the bits directly in the appropriate functions. This
change also reduces the size of the binary a bit.


git-svn-id: svn://svn.openwrt.org/openwrt/trunk@22192 3c298f89-4303-0410-b956-a3cf2f4a3e73
2010-07-15 13:05:02 +00:00
juhosg
c26785337f generic: rtl8366: use SWITCH_TYPE_NOVAL for reset_mib attributes
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@22191 3c298f89-4303-0410-b956-a3cf2f4a3e73
2010-07-15 13:04:57 +00:00
juhosg
e11397b6d4 generic: rtl8366: enable VLAN ingress filtering
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@22044 3c298f89-4303-0410-b956-a3cf2f4a3e73
2010-07-02 09:55:57 +00:00
juhosg
302f3c09e8 generic: rtl8366: minor cleanup
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@21985 3c298f89-4303-0410-b956-a3cf2f4a3e73
2010-06-28 17:24:05 +00:00
juhosg
d357a4cc6a generic: rtl8366: add common read_debugfs_mibs function
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@21984 3c298f89-4303-0410-b956-a3cf2f4a3e73
2010-06-28 17:24:02 +00:00
juhosg
aaf0b375e0 generic: rtl8366: standardize read_debugfs_mibs functions
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@21983 3c298f89-4303-0410-b956-a3cf2f4a3e73
2010-06-28 17:23:59 +00:00
juhosg
41d026022e generic: rtl8366: use common rtl8366_mib_counter structure
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@21982 3c298f89-4303-0410-b956-a3cf2f4a3e73
2010-06-28 17:23:56 +00:00
juhosg
18ab2efaa8 generic: rtl8366: move common debugfs code to rtl8366_smi.c
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@21981 3c298f89-4303-0410-b956-a3cf2f4a3e73
2010-06-28 17:23:52 +00:00
juhosg
d59f0a0930 generic: rtl8366: move buf to struct rtl8366_smi
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@21980 3c298f89-4303-0410-b956-a3cf2f4a3e73
2010-06-28 17:23:48 +00:00
juhosg
30a7cdf55e generic: rtl8366: move common VLAN handling functions to rtl8366_smi.c
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@21979 3c298f89-4303-0410-b956-a3cf2f4a3e73
2010-06-28 17:23:45 +00:00
juhosg
7a3a11aca6 generic: rtl8366: add cpu_port, num_ports and num_vlan_mc to struct rtl8366_smi
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@21978 3c298f89-4303-0410-b956-a3cf2f4a3e73
2010-06-28 17:23:41 +00:00
juhosg
a81c90dc76 generic: rtl8366: add VLAN handling functions to rtl8366_smi_ops
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@21977 3c298f89-4303-0410-b956-a3cf2f4a3e73
2010-06-28 17:23:37 +00:00
juhosg
e05b25a242 generic: rtl8366: use RTL8366{S,RB} prefixes for all defines
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@21976 3c298f89-4303-0410-b956-a3cf2f4a3e73
2010-06-28 17:23:33 +00:00
nbd
c5552ad039 rename target/linux/generic-2.6 to generic
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@21952 3c298f89-4303-0410-b956-a3cf2f4a3e73
2010-06-26 20:42:58 +00:00