Thread (25 messages) 25 messages, 3 authors, 2017-03-18

Re: [PATCH v2 2/2] can: spi: hi311x: Add Holt HI-311x CAN driver

From: Wolfgang Grandegger <hidden>
Date: 2017-03-15 07:20:46
Also in: linux-can, lkml, netdev

Hello Akshay,

Am 15.03.2017 um 05:44 schrieb Akshay Bhat:
Hi Wolfgang,

On Tue, Mar 14, 2017 at 2:08 PM, Wolfgang Grandegger [off-list ref] wrote:
...snip....
quoted
quoted
/////disconnect cable
  can0  20000088   [8]  00 00 00 19 00 00 28 00   ERRORFRAME
        protocol-violation{{}{acknowledge-slot}}
        bus-error
        error-counter-tx-rx{{40}{0}}
  can0  20000088   [8]  00 00 00 19 00 00 58 00   ERRORFRAME
        protocol-violation{{}{acknowledge-slot}}
        bus-error
        error-counter-tx-rx{{88}{0}}
  can0  20000088   [8]  00 00 00 19 00 00 80 00   ERRORFRAME
        protocol-violation{{}{acknowledge-slot}}
        bus-error
        error-counter-tx-rx{{128}{0}}

TX error warning is missing.
This support was missing in the driver, added in V4 patch.
quoted
quoted
  can0  2000008C   [8]  00 20 00 19 00 00 80 00   ERRORFRAME
        controller-problem{tx-error-passive}
        protocol-violation{{}{acknowledge-slot}}
        bus-error
        error-counter-tx-rx{{128}{0}}

Here "tx-error-passiv" is packed with a bus error. What I'm looking for are
state change messages similar to:

   can0  20000204  [8] 00 08 00 00 00 00 60 00   ERRORFRAME
        controller-problem{tx-error-warning}
        state-change{tx-error-warning}
        error-counter-tx-rx{{96}{0}}
   can0  20000204  [8] 00 30 00 00 00 00 80 00   ERRORFRAME
        controller-problem{tx-error-passive}
        state-change{tx-error-passive}
        error-counter-tx-rx{{128}{0}

They should always come, even with "berr-reporting off".
HI-3110 has only 1 bus error interrupt. There is no dedicated state
change interrupts like other controllers.
To double check: Could you please read INTF, ERR and STATF at the 
beginning of the ISR and print it out (using dev_dbg and fiends). Then 
run a test with no cable connected and bus error reporting off.

Wolfgang.
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help