can: m_can: remove redundant check for pm_clock_support
authorFrancesco Dolcini <francesco.dolcini@toradex.com>
Thu, 4 Jan 2024 23:57:23 +0000 (00:57 +0100)
committerMarc Kleine-Budde <mkl@pengutronix.de>
Wed, 14 Feb 2024 10:24:30 +0000 (11:24 +0100)
commite517293fd72d9044902efae59f05203203a60736
treefb60060b414481d7e126570c343181af883993b1
parente1a00373e1305578cd09526aa056940409e6b877
can: m_can: remove redundant check for pm_clock_support

m_can_clk_start() already skip starting the clock when
clock support is disabled, remove the redundant check in
m_can_class_register().

This also solves the imbalance with m_can_clk_stop() that is called
afterward in the same function before the return.

Signed-off-by: Francesco Dolcini <francesco.dolcini@toradex.com>
Reviewed-by: Markus Schneider-Pargmann <msp@baylibre.com>
Link: https://lore.kernel.org/all/20240104235723.46931-1-francesco@dolcini.it
[mkl: rebased to net-next/main]
Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de>
drivers/net/can/m_can/m_can.c