Hi Antoine,
I love your patch! Yet something to improve:
[auto build test ERROR on net-next/master]
url:
https://github.com/0day-ci/linux/commits/Antoine-Tenart/net-mscc-PTP-Hardware-Clock-PHC-support/20190707-075931
config: ia64-allmodconfig (attached as .config)
compiler: ia64-linux-gcc (G
Hello Jakub,
On Mon, Jul 08, 2019 at 12:06:26PM -0700, Jakub Kicinski wrote:
> On Mon, 8 Jul 2019 10:48:09 +0200, Antoine Tenart wrote:
> > > > + /* Commit back the result & save it */
> > > > + memcpy(&ocelot->hwtstamp_config, &cfg, sizeof(cfg));
> > > > + mutex_unlock(&ocelot->
On Mon, 8 Jul 2019 10:48:09 +0200, Antoine Tenart wrote:
> > > + /* Commit back the result & save it */
> > > + memcpy(&ocelot->hwtstamp_config, &cfg, sizeof(cfg));
> > > + mutex_unlock(&ocelot->ptp_lock);
> > > +
> > > + return copy_to_user(ifr->ifr_data, &cfg, sizeof(cfg)) ? -EFAULT : 0;
> > > +}
Hello Jakub,
On Fri, Jul 05, 2019 at 03:10:38PM -0700, Jakub Kicinski wrote:
> On Fri, 5 Jul 2019 21:52:13 +0200, Antoine Tenart wrote:
> > @@ -596,11 +606,50 @@ static int ocelot_port_xmit(struct sk_buff *skb,
> > struct net_device *dev)
> >
> > dev->stats.tx_packets++;
> > dev->stats
Hi Richard,
On Fri, Jul 05, 2019 at 03:02:24PM -0700, Richard Cochran wrote:
> On Fri, Jul 05, 2019 at 09:52:13PM +0200, Antoine Tenart wrote:
> > +static irqreturn_t ocelot_ptp_rdy_irq_handler(int irq, void *arg)
> > +{
> > + struct ocelot *ocelot = arg;
> > +
> > + do {
>
> > + /*
On Fri, 5 Jul 2019 21:52:13 +0200, Antoine Tenart wrote:
> This patch adds support for PTP Hardware Clock (PHC) to the Ocelot
> switch for both PTP 1-step and 2-step modes.
>
> Signed-off-by: Antoine Tenart
> @@ -596,11 +606,50 @@ static int ocelot_port_xmit(struct sk_buff *skb, struct
> net_d
On Fri, Jul 05, 2019 at 09:52:13PM +0200, Antoine Tenart wrote:
> +static irqreturn_t ocelot_ptp_rdy_irq_handler(int irq, void *arg)
> +{
> + struct ocelot *ocelot = arg;
> +
> + do {
> + /* Check if a timestamp can be retrieved */
> + if (!(val & SYS_PTP_STATUS_PTP
This patch adds support for PTP Hardware Clock (PHC) to the Ocelot
switch for both PTP 1-step and 2-step modes.
Signed-off-by: Antoine Tenart
---
drivers/net/ethernet/mscc/ocelot.c | 393 ++-
drivers/net/ethernet/mscc/ocelot.h | 37 +++
drivers/net/ethernet/mscc/