Re: [patch 02/12] can: c_can: Fix hardware raminit function

2014-03-19 Thread Thomas Gleixner
On Wed, 19 Mar 2014, Oliver Hartkopp wrote: > On 18.03.2014 23:15, Thomas Gleixner wrote: > > On Tue, 18 Mar 2014, Marc Kleine-Budde wrote: > >> On 03/18/2014 06:19 PM, Thomas Gleixner wrote: > >>> +static void c_can_hw_raminit_wait(const struct c_can_priv *priv, u32 > >>> mask, > >>> +

Re: [patch 02/12] can: c_can: Fix hardware raminit function

2014-03-18 Thread Oliver Hartkopp
On 18.03.2014 23:15, Thomas Gleixner wrote: > On Tue, 18 Mar 2014, Marc Kleine-Budde wrote: >> On 03/18/2014 06:19 PM, Thomas Gleixner wrote: >>> +static void c_can_hw_raminit_wait(const struct c_can_priv *priv, u32 mask, >>> + u32 val) >>> +{ >>> + /* We look only at

Re: [patch 02/12] can: c_can: Fix hardware raminit function

2014-03-18 Thread Thomas Gleixner
On Tue, 18 Mar 2014, Marc Kleine-Budde wrote: > On 03/18/2014 06:19 PM, Thomas Gleixner wrote: > > +static void c_can_hw_raminit_wait(const struct c_can_priv *priv, u32 mask, > > + u32 val) > > +{ > > + /* We look only at the bits of our instance. */ > > + val &= mas

Re: [patch 02/12] can: c_can: Fix hardware raminit function

2014-03-18 Thread Marc Kleine-Budde
On 03/18/2014 06:19 PM, Thomas Gleixner wrote: > The function is broken in several ways: > > - The function does not wait for the init to complete. > That can take quite some microseconds. > > - No protection against being called for two chips at the same > time. SMP is such a

[patch 02/12] can: c_can: Fix hardware raminit function

2014-03-18 Thread Thomas Gleixner
The function is broken in several ways: - The function does not wait for the init to complete. That can take quite some microseconds. - No protection against being called for two chips at the same time. SMP is such a new thing, right? Clear the start and the init done bit unc