linux/drivers/net/wan
Krzysztof Halasa 5dbc46506a IXP42x HSS support for setting internal clock rate
HSS usually uses external clocks, so it's not a big deal. Internal clock
is used for direct DTE-DTE connections and when the DCE doesn't provide
it's own clock.

This also depends on the oscillator frequency. Intel seems to have
calculated the clock register settings for 33.33 MHz (66.66 MHz timer
base). Their settings seem quite suboptimal both in terms of average
frequency (60 ppm is unacceptable for G.703 applications, their primary
intended usage(?)) and jitter.

Many (most?) platforms use a 33.333 MHz oscillator, a 10 ppm difference
from Intel's base.

Instead of creating static tables, I've created a procedure to program
the HSS clock register. The register consists of 3 parts (A, B, C).
The average frequency (= bit rate) is:
66.66x MHz / (A  + (B + 1) / (C + 1))
The procedure aims at the closest average frequency, possibly at the
cost of increased jitter. Nobody would be able to directly drive an
unbufferred transmitter with a HSS anyway, and the frequency error is
what it really counts.

I've verified the above with an oscilloscope on IXP425. It seems IXP46x
and possibly IXP43x use a bit different clock generation algorithm - it
looks like the avg frequency is:
(on IXP465) 66.66x MHz / (A  + B / (C + 1)).
Also they use much greater precomputed A and B - on IXP425 it would
simply result in more jitter, but I don't know how does it work on
IXP46x (perhaps 3 least significant bits aren't used?).

Anyway it looks that they were aiming for exactly +60 ppm or -60 ppm,
while <1 ppm is typically possible (with a synchronized clock, of
course).

The attached patch makes it possible to set almost any bit rate
(my IXP425 533 MHz quits at > 22 Mb/s if a single port is used, and the
minimum is ca. 65 Kb/s).

This is independent of MVIP (multi-E1/T1 on one HSS) mode.

Signed-off-by: Krzysztof Hałasa <khc@pm.waw.pl>
Signed-off-by: David S. Miller <davem@davemloft.net>
2009-09-07 01:56:49 -07:00
..
lmc wan: convert drivers to netdev_tx_t 2009-09-01 01:13:28 -07:00
.gitignore
c101.c
cosa.c wan: convert drivers to netdev_tx_t 2009-09-01 01:13:28 -07:00
cosa.h
cycx_drv.c
cycx_main.c
cycx_x25.c wan: convert drivers to netdev_tx_t 2009-09-01 01:13:28 -07:00
dlci.c wan: dlci/sdla transmit return dehacking 2009-09-07 01:56:33 -07:00
dscc4.c WAN: dscc4: Fix warning pointing out a bug. 2009-09-03 21:34:39 -07:00
farsync.c wan: convert drivers to netdev_tx_t 2009-09-01 01:13:28 -07:00
farsync.h
hd64570.c wan: convert drivers to netdev_tx_t 2009-09-01 01:13:28 -07:00
hd64570.h
hd64572.c wan: convert drivers to netdev_tx_t 2009-09-01 01:13:28 -07:00
hd64572.h
hdlc_cisco.c
hdlc_fr.c wan: convert drivers to netdev_tx_t 2009-09-01 01:13:28 -07:00
hdlc_ppp.c
hdlc_raw_eth.c wan: convert drivers to netdev_tx_t 2009-09-01 01:13:28 -07:00
hdlc_raw.c
hdlc_x25.c wan: convert drivers to netdev_tx_t 2009-09-01 01:13:28 -07:00
hdlc.c wan: convert drivers to netdev_tx_t 2009-09-01 01:13:28 -07:00
hostess_sv11.c wan: convert drivers to netdev_tx_t 2009-09-01 01:13:28 -07:00
ixp4xx_hss.c IXP42x HSS support for setting internal clock rate 2009-09-07 01:56:49 -07:00
Kconfig
lapbether.c wan: convert drivers to netdev_tx_t 2009-09-01 01:13:28 -07:00
Makefile
n2.c
pc300_drv.c
pc300_tty.c
pc300-falc-lh.h
pc300.h
pc300too.c
pci200syn.c WAN: remove deprecated PCI_DEVICE_ID from PCI200SYN driver. 2009-09-07 01:56:45 -07:00
sbni.c wan: convert drivers to netdev_tx_t 2009-09-01 01:13:28 -07:00
sbni.h
sdla.c wan: dlci/sdla transmit return dehacking 2009-09-07 01:56:33 -07:00
sealevel.c wan: convert drivers to netdev_tx_t 2009-09-01 01:13:28 -07:00
wanxl.c wan: convert drivers to netdev_tx_t 2009-09-01 01:13:28 -07:00
wanxl.h
wanxlfw.inc_shipped
wanxlfw.S
x25_asy.c wan: convert drivers to netdev_tx_t 2009-09-01 01:13:28 -07:00
x25_asy.h
z85230.c wan: convert drivers to netdev_tx_t 2009-09-01 01:13:28 -07:00
z85230.h wan: convert drivers to netdev_tx_t 2009-09-01 01:13:28 -07:00