1. 12 3月, 2016 1 次提交
  2. 11 3月, 2016 34 次提交
  3. 10 3月, 2016 5 次提交
    • R
      can: rcar_can: Add r8a7795 support · e481ab23
      Ramesh Shanmugasundaram 提交于
      Added r8a7795 SoC support.
      Signed-off-by: NRamesh Shanmugasundaram <ramesh.shanmugasundaram@bp.renesas.com>
      Acked-by: NRob Herring <robh@kernel.org>
      Signed-off-by: NMarc Kleine-Budde <mkl@pengutronix.de>
      e481ab23
    • M
      can: ifi: Add obscure bit swap for EFF frame IDs · 6cc64266
      Marek Vasut 提交于
      In case of CAN2.0 EFF frame, the controller handles frame IDs in a
      rather bizzare way. The ID is split into an extended part, IDX[28:11]
      and standard part, ID[10:0]. In the TX path, the core first sends the
      top 11 bits of the IDX, followed by ID and finally the rest of IDX.
      In the RX path, the core stores the ID the LSbit part of IDX field,
      followed by the LSbit parts of real IDX. The MSbit parts of IDX are
      stored in ID field of the register.
      
      This patch implements the necessary bit shuffling to mitigate this
      obscure behavior. In case two of these controllers are connected
      together, the RX and TX bit swapping nullifies itself and the issue
      does not manifest. The issue only manifests when talking to another
      different CAN controller.
      Signed-off-by: NMarek Vasut <marex@denx.de>
      Cc: Marc Kleine-Budde <mkl@pengutronix.de>
      Cc: Mark Rutland <mark.rutland@arm.com>
      Cc: Oliver Hartkopp <socketcan@hartkopp.net>
      Cc: Wolfgang Grandegger <wg@grandegger.com>
      Reviewed-by: NOliver Hartkopp <socketcan@hartkopp.net>
      Signed-off-by: NMarc Kleine-Budde <mkl@pengutronix.de>
      6cc64266
    • M
      can: ifi: Fix RX and TX ID mask · 22365435
      Marek Vasut 提交于
      The RX and TX ID mask for CAN2.0 is 11 bits wide. This patch fixes
      the incorrect mask, which caused the CAN IDs to miss the MSBit both
      on receive and transmit.
      Signed-off-by: NMarek Vasut <marex@denx.de>
      Cc: Marc Kleine-Budde <mkl@pengutronix.de>
      Cc: Mark Rutland <mark.rutland@arm.com>
      Cc: Oliver Hartkopp <socketcan@hartkopp.net>
      Cc: Wolfgang Grandegger <wg@grandegger.com>
      Reviewed-by: NOliver Hartkopp <socketcan@hartkopp.net>
      Signed-off-by: NMarc Kleine-Budde <mkl@pengutronix.de>
      22365435
    • M
      can: ifi: Fix TX DLC configuration · f1deaee0
      Marek Vasut 提交于
      The TX DLC, the transmission length information, was not written
      into the transmit configuration register. When using the CAN core
      with different CAN controller, the receiving CAN controller will
      receive only the ID part of the CAN frame, but no data at all.
      
      This patch adds the TX DLC into the register to fix this issue.
      Signed-off-by: NMarek Vasut <marex@denx.de>
      Cc: Marc Kleine-Budde <mkl@pengutronix.de>
      Cc: Mark Rutland <mark.rutland@arm.com>
      Cc: Oliver Hartkopp <socketcan@hartkopp.net>
      Cc: Wolfgang Grandegger <wg@grandegger.com>
      Reviewed-by: NOliver Hartkopp <socketcan@hartkopp.net>
      Signed-off-by: NMarc Kleine-Budde <mkl@pengutronix.de>
      f1deaee0
    • M
      can: ifi: Fix clock generator configuration · 99312c37
      Marek Vasut 提交于
      The clock generation does not match reality when using the CAN IP
      core outside of the FPGA design. This patch fixes the computation
      of values which are programmed into the clock generator registers.
      
      First, there are some off-by-one errors which manifest themselves
      only when communicating with different controller, so those are
      fixed.
      
      Second, the bits in the clock generator registers have different
      meaning depending on whether the core is in ISO CANFD mode or any
      of the other modes (BOSCH CANFD or CAN2.0). Detect the ISO CANFD
      mode and fix handling of this special case of clock configuration.
      
      Finally, the CAN clock speed is in CANCLOCK register, not SYSCLOCK
      register, so fix this as well.
      Signed-off-by: NMarek Vasut <marex@denx.de>
      Cc: Marc Kleine-Budde <mkl@pengutronix.de>
      Cc: Mark Rutland <mark.rutland@arm.com>
      Cc: Oliver Hartkopp <socketcan@hartkopp.net>
      Cc: Wolfgang Grandegger <wg@grandegger.com>
      Reviewed-by: NOliver Hartkopp <socketcan@hartkopp.net>
      Signed-off-by: NMarc Kleine-Budde <mkl@pengutronix.de>
      99312c37