Re: [PATCH 11/12] ptp: Added a clock driver for the IXP46x.

2010-06-15 Thread Richard Cochran
On Tue, Jun 15, 2010 at 12:41:56PM -0600, Grant Likely wrote: > Nitpick. We use all lower case names for structures in Linux. Yes, I know, but in this case an exception makes sense. I prefer to use the exact same register mnemonics as in the hardware documentation, whenever possible. That way, a

Re: [PATCH 10/12] ptp: Added a clock that uses the eTSEC found on the MPC85xx.

2010-06-15 Thread Richard Cochran
On Tue, Jun 15, 2010 at 11:20:41AM -0600, Grant Likely wrote: > > Is this header file used by anything other than gianfar_ptp.c? If > not, then roll the two files together. I anticipate that it might be necessary to share the header's contents with gianfar.c one day. > Use dash ('-') not unders

Re: Request review of device tree documentation

2010-06-15 Thread Mitch Bradley
Mike Rapoport wrote: Mitch Bradley wrote: Mike Rapoport wrote: Mitch Bradley wrote: The second topic is the hypothetical use of OFW as a HAL. That will not happen for several reasons. The opposition to the idea is widespread and deeply held, and there are good arguments to support that opp

Re: [PATCH 04/12] phylib: add a way to make PHY time stamps possible.

2010-06-15 Thread Richard Cochran
On Tue, Jun 15, 2010 at 06:08:20PM +0200, Richard Cochran wrote: > +static inline void skb_tx_timetamp(struct phy_device *phy, struct sk_buff > *skb) > +{ > + union skb_shared_tx *shtx = skb_tx(skb); > + > + if (shtx->hardware && phy && phy->drv->txtstamp) > + phy->drv->txtsta

Re: [PATCH 05/12] phylib: Allow reading and writing a mii bus from atomic context.

2010-06-15 Thread Richard Cochran
> That's right, and I fully agree with that change. To me, going back > to allowing spin locks is a regression because it adds a new source of > scheduling latency. I think that the change was not about reducing scheduling latency. Rather, the idea was simply to allow mdio bus drivers that sleep.

Re: Request review of device tree documentation

2010-06-15 Thread Mitch Bradley
Mike Rapoport wrote: Mitch Bradley wrote: The second topic is the hypothetical use of OFW as a HAL. That will not happen for several reasons. The opposition to the idea is widespread and deeply held, and there are good arguments to support that opposition. Furthermore, the economic conditi

Re: [PATCH 04/12] phylib: add a way to make PHY time stamps possible.

2010-06-15 Thread Richard Cochran
On Tue, Jun 15, 2010 at 10:33:51AM -0600, Grant Likely wrote: > > +config NETWORK_PHY_TIMESTAMPING > Some overhead? At a brief glance of the series it looks like it could > add a lot of overhead, but I'm not fully clear on what the full > process is. Can you describe how the hardware timestamping

Re: [PATCH 5/5] of/address: restrict 'no-ranges' kludge to powerpc

2010-06-15 Thread Benjamin Herrenschmidt
On Tue, 2010-06-15 at 18:23 +0200, Segher Boessenkool wrote: > >> Certain Apple machines don't use the ranges property correctly, > >> but the > >> workaround should not be applied on other architectures. This patch > >> disables the workaround for non-powerpc architectures. > > > > I'm half tem

Re: Request review of device tree documentation

2010-06-15 Thread Stephan Gatzka
Hi Grant, Well, that was easy. I just added the Cite.php extension to the site. tags are now available. g. Thanks, that really helps. Regards, Stephan smime.p7s Description: S/MIME Cryptographic Signature ___ devicetree-discuss mailing lis

Re: [PATCH 08/12] ptp: Added a brand new class driver for ptp clocks.

2010-06-15 Thread Grant Likely
On Tue, Jun 15, 2010 at 10:09 AM, Richard Cochran wrote: > This patch adds an infrastructure for hardware clocks that implement > IEEE 1588, the Precision Time Protocol (PTP). A class driver offers a > registration method to particular hardware clock drivers. Each clock is > exposed to user space

Re: [PATCH 08/12] ptp: Added a brand new class driver for ptp clocks.

2010-06-15 Thread Grant Likely
On Tue, Jun 15, 2010 at 10:09 AM, Richard Cochran wrote: > This patch adds an infrastructure for hardware clocks that implement > IEEE 1588, the Precision Time Protocol (PTP). A class driver offers a > registration method to particular hardware clock drivers. Each clock is > exposed to user space

Re: [PATCH 12/12] ptp: Added a clock driver for the National Semiconductor PHYTER.

2010-06-15 Thread Grant Likely
On Tue, Jun 15, 2010 at 10:10 AM, Richard Cochran wrote: > This patch adds support for the PTP clock found on the DP83640. Only the > basic clock operations have been implemented. > > Signed-off-by: Richard Cochran > --- >  drivers/net/phy/Kconfig   |   11 +++ >  drivers/net/phy/dp83640.c |  158

Re: [PATCH 11/12] ptp: Added a clock driver for the IXP46x.

2010-06-15 Thread Grant Likely
On Tue, Jun 15, 2010 at 10:10 AM, Richard Cochran wrote: > This patch adds a driver for the hardware time stamping unit found on the > IXP465. Only the basic clock operations are implemented. > > Signed-off-by: Richard Cochran Hi Richard, Comments below... > --- >  arch/arm/mach-ixp4xx/include

Re: [PATCH 05/12] phylib: Allow reading and writing a mii bus from atomic context.

2010-06-15 Thread Grant Likely
On Tue, Jun 15, 2010 at 11:08 AM, Richard Cochran wrote: > On Tue, Jun 15, 2010 at 10:43:08AM -0600, Grant Likely wrote: >> On Tue, Jun 15, 2010 at 10:08 AM, Richard Cochran >> wrote: >> > In order to support hardware time stamping from a PHY, it is necessary to >> > read from the PHY while runni

Re: [PATCH 10/12] ptp: Added a clock that uses the eTSEC found on the MPC85xx.

2010-06-15 Thread Grant Likely
On Tue, Jun 15, 2010 at 10:10 AM, Richard Cochran wrote: > The eTSEC includes a PTP clock with quite a few features. This patch adds > support for the basic clock adjustment functions, plus two external time > stamps and one alarm. > > Signed-off-by: Richard Cochran Hi Richard, comments below..

Re: [PATCH 05/12] phylib: Allow reading and writing a mii bus from atomic context.

2010-06-15 Thread Richard Cochran
On Tue, Jun 15, 2010 at 10:43:08AM -0600, Grant Likely wrote: > On Tue, Jun 15, 2010 at 10:08 AM, Richard Cochran > wrote: > > In order to support hardware time stamping from a PHY, it is necessary to > > read from the PHY while running in_interrupt(). This patch allows a mii > > bus to operate in

Re: [PATCH 03/12] phylib: add a driver method for the SIOCSHWTSTAMP ioctl.

2010-06-15 Thread Grant Likely
On Tue, Jun 15, 2010 at 10:49 AM, Grant Likely wrote: > On Tue, Jun 15, 2010 at 10:34 AM, Richard Cochran > wrote: >> On Tue, Jun 15, 2010 at 10:27:59AM -0600, Grant Likely wrote: >>> On Tue, Jun 15, 2010 at 10:08 AM, Richard Cochran >>> wrote: >>> > This patch adds a phy driver method for confi

Re: [PATCH 03/12] phylib: add a driver method for the SIOCSHWTSTAMP ioctl.

2010-06-15 Thread Grant Likely
On Tue, Jun 15, 2010 at 10:34 AM, Richard Cochran wrote: > On Tue, Jun 15, 2010 at 10:27:59AM -0600, Grant Likely wrote: >> On Tue, Jun 15, 2010 at 10:08 AM, Richard Cochran >> wrote: >> > This patch adds a phy driver method for configuring hardware time stamping. >> > Drivers may optionally impl

Re: [PATCH 05/12] phylib: Allow reading and writing a mii bus from atomic context.

2010-06-15 Thread Grant Likely
On Tue, Jun 15, 2010 at 10:08 AM, Richard Cochran wrote: > In order to support hardware time stamping from a PHY, it is necessary to > read from the PHY while running in_interrupt(). This patch allows a mii > bus to operate in an atomic context. An mii_bus driver may declare itself > capable for t

Re: [PATCH 04/12] phylib: add a way to make PHY time stamps possible.

2010-06-15 Thread Grant Likely
On Tue, Jun 15, 2010 at 10:08 AM, Richard Cochran wrote: > This patch adds a new networking option to allow hardware time stamps > from PHY devices. Using PHY time stamps will still require adding two > inline function calls to each MAC driver. The CONFIG option makes these > calls safe to add, si

Re: [PATCH 03/12] phylib: add a driver method for the SIOCSHWTSTAMP ioctl.

2010-06-15 Thread Richard Cochran
On Tue, Jun 15, 2010 at 10:27:59AM -0600, Grant Likely wrote: > On Tue, Jun 15, 2010 at 10:08 AM, Richard Cochran > wrote: > > This patch adds a phy driver method for configuring hardware time stamping. > > Drivers may optionally implement this function. > > > > Signed-off-by: Richard Cochran >

Re: [PATCH 03/12] phylib: add a driver method for the SIOCSHWTSTAMP ioctl.

2010-06-15 Thread Grant Likely
On Tue, Jun 15, 2010 at 10:08 AM, Richard Cochran wrote: > This patch adds a phy driver method for configuring hardware time stamping. > Drivers may optionally implement this function. > > Signed-off-by: Richard Cochran Adding an ioctl to the userspace ABI. Make sure you cc: linux-kernel on the

Re: [PATCH 02/12] phylib: do not filter phy_mii_ioctl()

2010-06-15 Thread Grant Likely
On Tue, Jun 15, 2010 at 10:07 AM, Richard Cochran wrote: > Two maverick drivers filter the ioctl commands passed to phy_mii_ioctl(). > This is unnecessary since phylib will check the command in any case. > > Signed-off-by: Richard Cochran At a glance, looks okay to me. > --- >  drivers/net/cpma

Re: [PATCH 5/5] of/address: restrict 'no-ranges' kludge to powerpc

2010-06-15 Thread Segher Boessenkool
Certain Apple machines don't use the ranges property correctly, but the workaround should not be applied on other architectures. This patch disables the workaround for non-powerpc architectures. I'm half tempted to add it to the quirk list (which should really be made generic) so I can disabl

[PATCH 12/12] ptp: Added a clock driver for the National Semiconductor PHYTER.

2010-06-15 Thread Richard Cochran
This patch adds support for the PTP clock found on the DP83640. Only the basic clock operations have been implemented. Signed-off-by: Richard Cochran --- drivers/net/phy/Kconfig | 11 +++ drivers/net/phy/dp83640.c | 158 - 2 files changed, 168 ins

[PATCH 11/12] ptp: Added a clock driver for the IXP46x.

2010-06-15 Thread Richard Cochran
This patch adds a driver for the hardware time stamping unit found on the IXP465. Only the basic clock operations are implemented. Signed-off-by: Richard Cochran --- arch/arm/mach-ixp4xx/include/mach/ixp46x_ts.h | 67 +++ drivers/net/arm/ixp4xx_eth.c | 194 +++

[PATCH 10/12] ptp: Added a clock that uses the eTSEC found on the MPC85xx.

2010-06-15 Thread Richard Cochran
The eTSEC includes a PTP clock with quite a few features. This patch adds support for the basic clock adjustment functions, plus two external time stamps and one alarm. Signed-off-by: Richard Cochran --- Documentation/powerpc/dts-bindings/fsl/tsec.txt | 54 +++ arch/powerpc/boot/dts/mpc8313erd

[PATCH 09/12] ptp: Added a clock that uses the Linux system time.

2010-06-15 Thread Richard Cochran
This PTP clock simply uses the NTP time adjustment system calls. The driver can be used in systems that lack a special hardware PTP clock. Signed-off-by: Richard Cochran --- drivers/ptp/Kconfig | 12 drivers/ptp/Makefile|1 + drivers/ptp/ptp_linux.c | 136

[PATCH 08/12] ptp: Added a brand new class driver for ptp clocks.

2010-06-15 Thread Richard Cochran
This patch adds an infrastructure for hardware clocks that implement IEEE 1588, the Precision Time Protocol (PTP). A class driver offers a registration method to particular hardware clock drivers. Each clock is exposed to user space as a character device with ioctls that allow tuning of the PTP clo

[PATCH 07/12] phylib: support the National Semiconductor DP83640 PHY.

2010-06-15 Thread Richard Cochran
This patch adds a driver for the DP83640. This device is one of a new generation of PHYs able to time stamp PTP packets. Signed-off-by: Richard Cochran --- drivers/net/phy/Kconfig |5 + drivers/net/phy/Makefile |1 + drivers/net/phy/dp83640.c | 439 +++

[PATCH 06/12] ptp: add a BPF to help drivers detect PTP packets.

2010-06-15 Thread Richard Cochran
Certain kinds of hardware time stamping units in both MACs and PHYs have the limitation that they can only time stamp PTP packets. Drivers for such hardware are left with the task of correctly matching skbs to time stamps. This patch adds a BPF that drivers can use to classify PTP packets when need

[PATCH 05/12] phylib: Allow reading and writing a mii bus from atomic context.

2010-06-15 Thread Richard Cochran
In order to support hardware time stamping from a PHY, it is necessary to read from the PHY while running in_interrupt(). This patch allows a mii bus to operate in an atomic context. An mii_bus driver may declare itself capable for this mode. Drivers which do not do this will remain with the defaul

[PATCH 04/12] phylib: add a way to make PHY time stamps possible.

2010-06-15 Thread Richard Cochran
This patch adds a new networking option to allow hardware time stamps from PHY devices. Using PHY time stamps will still require adding two inline function calls to each MAC driver. The CONFIG option makes these calls safe to add, since the calls become NOOPs when the option is disabled. Signed-of

[PATCH 03/12] phylib: add a driver method for the SIOCSHWTSTAMP ioctl.

2010-06-15 Thread Richard Cochran
This patch adds a phy driver method for configuring hardware time stamping. Drivers may optionally implement this function. Signed-off-by: Richard Cochran --- drivers/net/phy/phy.c |5 + include/linux/phy.h |3 +++ 2 files changed, 8 insertions(+), 0 deletions(-) diff --git a/driv

[PATCH 02/12] phylib: do not filter phy_mii_ioctl()

2010-06-15 Thread Richard Cochran
Two maverick drivers filter the ioctl commands passed to phy_mii_ioctl(). This is unnecessary since phylib will check the command in any case. Signed-off-by: Richard Cochran --- drivers/net/cpmac.c |5 + drivers/net/stmmac/stmmac_main.c | 22 -- 2 files

[PATCH 01/12] phylib: preserve ifreq parameter when calling generic phy_mii_ioctl()

2010-06-15 Thread Richard Cochran
The phy_mii_ioctl() function unnecessarily throws away the original ifreq. We need access to the ifreq in order to support PHYs that can perform hardware time stamping. Signed-off-by: Richard Cochran --- drivers/net/arm/ixp4xx_eth.c |3 ++- drivers/net/au1000_eth.c |

[PATCH v4 00/12] ptp: IEEE 1588 clock support

2010-06-15 Thread Richard Cochran
Now and again there has been talk on the netdev list of adding PTP support into Linux. One part of the picture is already in place, the SO_TIMESTAMPING API for hardware time stamping. This patch set offers the missing second part needed for complete IEEE 1588 support. The only feature still to be

Re: Re:Re: PCIe bus seems work while 'dma' can't under linux

2010-06-15 Thread Benjamin Herrenschmidt
On Tue, 2010-06-15 at 15:05 +0800, jxnuxdy wrote: > Thanks Benjamin, the regions don't display as what we expect, that's why we > suspect if there any configuration probelms in CPU host bridge, but we > changed the uboot/linux a lot, seems take no effect on that problems. > > We use CPU MPC8544,