Skip to content

Commit

Permalink
can: ems_pci: Deassert hardware reset
Browse files Browse the repository at this point in the history
The reset line from the Asix chip to the SJA1000 is asserted after boot up
until it is deasserted by a register write

Signed-off-by: Gerhard Uttenthaler <uttenthaler@ems-wuensche.com>
Link: https://lore.kernel.org/all/20230120112616.6071-8-uttenthaler@ems-wuensche.com
Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de>
  • Loading branch information
Gerhard Uttenthaler authored and Marc Kleine-Budde committed Feb 2, 2023
1 parent 8b4339f commit 946c413
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions drivers/net/can/sja1000/ems_pci.c
Original file line number Diff line number Diff line change
Expand Up @@ -326,6 +326,14 @@ static int ems_pci_add_card(struct pci_dev *pdev,
}
}

if (card->version == 3) {
/* ASIX chip asserts local reset to CAN controllers
* after bootup until it is deasserted
*/
writel(readl(card->conf_addr + ASIX_LIEMR) & ~ASIX_LIEMR_LRST,
card->conf_addr + ASIX_LIEMR);
}

ems_pci_card_reset(card);

/* Detect available channels */
Expand Down

0 comments on commit 946c413

Please sign in to comment.