Since IP175D uses tag-based VLANs, we need an ability to set VLAN tag
of every VLAN.
Signed-off-by: Martin Mares <mj@ucw.cz>
Signed-off-by: Patrick Horn <patrick.horn@gmail.com>
SVN-Revision: 21718
So far, state->remove_tag was sometimes updated incrementally, sometimes
left to correct_vlan_state() to recalculate. Since I want to avoid use of
correct_vlan_state() for IP175D, this patch fixes the only two remaining
places which leave state->remove_tag inconsistent with state->add_tag
and it drops the recalculation.
Signed-off-by: Martin Mares <mj@ucw.cz>
Signed-off-by: Patrick Horn <patrick.horn@gmail.com>
SVN-Revision: 21717
Let VLAN state variables be initialized not only when the enable VLAN bit
is toggled, but also upon reset.
At this point, this should be a no-op, since the driver reads the current
hardware state before doing any modifications anyway, but I plan to keep
some state locally in the subsequent patches.
Signed-off-by: Martin Mares <mj@ucw.cz>
Signed-off-by: Patrick Horn <patrick.horn@gmail.com>
SVN-Revision: 21716
Replace vlan_ports array in struct ip175c_state by an array of structures.
Signed-off-by: Martin Mares <mj@ucw.cz>
Signed-off-by: Patrick Horn <patrick.horn@gmail.com>
SVN-Revision: 21715
This patch introduces seperation between low-level and high-level parts
of the driver. The low-level functions are now called via pointers stored
in struct ip175c_regs.
The only functional changes are:
o correct_vlan_state() is now called as a part of every update_state().
o The order of setting of MODE_REG and resetting switch ports
has changed. (These are independent actions, so it should not matter.)
o ip175c_set_tagged() sets the tags via update_state() instead of writing
directly to the registers.
o The same for ip175c_set_pvid().
The only gaps in this abstraction are operations on ports (get_port_speed
and friends), which access PHY registers directly.
Signed-off-by: Martin Mares <mj@ucw.cz>
Signed-off-by: Patrick Horn <patrick.horn@gmail.com>
SVN-Revision: 21714
The value written to MODE_REG in ip175c_reset() should be obviously MODE_VAL,
not RESET_VAL. Actually, this change is a NOP, because in the only case where
the MODE_REG is used, the two values are identical, but it makes the code
more readable.
Signed-off-by: Martin Mares <mj@ucw.cz>
Signed-off-by: Patrick Horn <patrick.horn@gmail.com>
SVN-Revision: 21713
Upon error, ip175c_set_val() returned 0 instead of -EINVAL.
Signed-off-by: Martin Mares <mj@ucw.cz>
Signed-off-by: Patrick Horn <patrick.horn@gmail.com>
SVN-Revision: 21711
Trying to unify capitalization and formatting of comments. Writing of periods
at the end of comments is however still inconsistent.
Signed-off-by: Martin Mares <mj@ucw.cz>
Signed-off-by: Patrick Horn <patrick.horn@gmail.com>
SVN-Revision: 21710
Call mdiobus_{read,write} instead of duplicating their code.
Introduce ip_phy_write_masked(), which changes a part of a register. Will
be used later in this patch series. Please note that it does not hold any
lock between reading and writing, so it is up to the caller to serialize.
Also add DUMP_MII_IO, which enables logging of all MII accesses.
Signed-off-by: Martin Mares <mj@ucw.cz>
Signed-off-by: Patrick Horn <patrick.horn@gmail.com>
SVN-Revision: 21709
SWITCH_PORT_FLAG_TAGGED is a bit index, not a bit mask.
Signed-off-by: Martin Mares <mj@ucw.cz>
Signed-off-by: Patrick Horn <patrick.horn@gmail.com>
SVN-Revision: 21708
This patch appears to be lost beetween 2.6.32 and 2.6.33.
Thank you Maddes for the patch.
This helps making orion work with kernel 2.6.34.
closes #7377.
SVN-Revision: 21622
Driver had recursive spinlock locking: 1. jz4740_queue() acquires lock 2. done()
is called in chain:
jz4740_queue()->jz4740_ep0_kick()->jz4740_ep0_in()->write_fifo_ep0()->done() and
it tries to acquire same lock. 3. Deadlock.
Signed-off-by:
Yauhen Kharuzhy <jekhor@gmail.com>
SVN-Revision: 21619
This patch appears to be lost beetween 2.6.32 and 2.6.33.
Thank you Maddes for the patch.
This helps making orion work with kernel 2.6.33.
SVN-Revision: 21552
This patch does not apply any more because of changes in target/linux/generic-2.6/patches-2.6.32/089-mtd-samsung-flash.patch
TODO: find out if this patch is still needed.
Fixes build problem decsripted in #7348.
SVN-Revision: 21551
* bump kernel to 2.6.33.4
* make ethernet be configurable as MII/RMII
* on xway we now assign a static amount of cp1 ram (still need to find a
sane value)
* remove bogus board.c
* jiffies were running with a (1 << 2) multiplier
SVN-Revision: 21485
Before this patch CONFIG_SSB_BLOCKIO was set to y in compat-wireless
but the in kernel ssb system had it set to n, this causes an invalid pointer.
b43 now needs CONFIG_SSB_BLOCKIO=y
SVN-Revision: 21449
wget2nand didnt check the exit status after copying the kernel, if the
copying failed for some reason ( for example not enougs space on the
kernel partition) it simply continued extracting the rootfs.
I also changed the filename, which wget2nand trys to download (
.tar.gz instead of .tgz ).
Signed-off-by: Marko Foerster <mrkfoerster@googlemail.com>
SVN-Revision: 21444