[tip: timers/core] time/timecounter: Mark 1st argument of timecounter_cyc2time() as const

2021-04-16 Thread tip-bot2 for Marc Kleine-Budde
The following commit has been merged into the timers/core branch of tip: Commit-ID: 07ff4aed015c564d03fd518d2fb54e5e6948903c Gitweb: https://git.kernel.org/tip/07ff4aed015c564d03fd518d2fb54e5e6948903c Author:Marc Kleine-Budde AuthorDate:Wed, 03 Mar 2021 11:35:44 +01:00

Re: [PATCH v2 0/2] MCAN: Add support for implementing transceiver as a phy

2021-04-16 Thread Marc Kleine-Budde
this patch hits mainline. Then I'll merge this into linux-can-next. regards, Marc -- Pengutronix e.K. | Marc Kleine-Budde | Embedded Linux | https://www.pengutronix.de | Vertretung West/Dortmund | Phone: +49-231-2826-924 | Amtsgericht Hildeshe

Re: [PATCH v5 0/3] CAN TRANSCEIVER: Add support for CAN transceivers

2021-04-16 Thread Marc Kleine-Budde
df > > Aswath Govindraju (3): > phy: core: Reword the comment specifying the units of max_link_rate to > be Mbps > dt-bindings: phy: Add binding for TI TCAN104x CAN transceivers > phy: phy-can-transceiver: Add support for generic CAN transceiver > driver >

Re: [PATCH v4 3/3] phy: phy-can-transceiver: Add support for generic CAN transceiver driver

2021-04-16 Thread Marc Kleine-Budde
"CAN transceiver PHY" > + select GENERIC_PHY > + help > + This option enables support for CAN transceivers as a PHY. This > + driver provides function for putting the transceivers in various > + functional modes using gpios and sets the a

Re: [PATCH v2 2/2] can: m_can: Add support for transceiver as phy

2021-04-16 Thread Marc Kleine-Budde
t; priv->mram_base = mram_addr; > > @@ -108,6 +120,7 @@ static int m_can_plat_probe(struct platform_device *pdev) > mcan_class->pm_clock_support = 1; > mcan_class->can.clock.freq = clk_get_rate(mcan_class->cclk); > mcan_class->dev = >dev; > + mcan_class->transceiver = transceiver; > > mcan_class->ops = _can_plat_ops; > > Marc -- Pengutronix e.K. | Marc Kleine-Budde | Embedded Linux | https://www.pengutronix.de | Vertretung West/Dortmund | Phone: +49-231-2826-924 | Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917- | signature.asc Description: OpenPGP digital signature

Re: [PATCH][next] can: etas_es58x: Fix missing null check on netdev pointer

2021-04-15 Thread Marc Kleine-Budde
On 15.04.2021 20:42:36, Vincent MAILHOL wrote: > On Thu. 15 Apr 2021 at 18:04, Marc Kleine-Budde wrote: > > On 15.04.2021 09:47:23, Colin King wrote: > > > From: Colin Ian King > > > > > > There is an assignment to *ne

Re: [PATCH][next] can: etas_es58x: Fix a couple of spelling mistakes

2021-04-15 Thread Marc Kleine-Budde
On 15.04.2021 12:30:50, Colin King wrote: > From: Colin Ian King > > There are spelling mistakes in netdev_dbg and netdev_dbg messages, > fix these. > > Signed-off-by: Colin Ian King Applied to linux-can-next/testing. Tnx, Marc -- Pengutronix e.K. |

Re: [PATCH v2 3/6] dt-bindings: phy: Add binding for TI TCAN104x CAN transceivers

2021-04-15 Thread Marc Kleine-Budde
tation/devicetree/bindings/phy folder. Also, > scripts/get_maintainer.pl is giving the names of maintainers after > reading the yaml files too. Nice! Clever script. Marc -- Pengutronix e.K. | Marc Kleine-Budde | Embedded Linux | https://www.pengut

Re: [PATCH][next] can: etas_es58x: Fix missing null check on netdev pointer

2021-04-15 Thread Marc Kleine-Budde
verity: ("Dereference before null check") > Fixes: 8537257874e9 ("can: etas_es58x: add core support for ETAS ES58X CAN > USB interfaces") > Signed-off-by: Colin Ian King Looks good. Applied to linux-can-next/testing. Tnx, Marc -- Pengutronix e.K.

Re: [PATCH][next] can: etas_es58x: Fix potential null pointer dereference on pointer cf

2021-04-15 Thread Marc Kleine-Budde
net-next/master https://git.kernel.org/pub/scm/linux/kernel/git/netdev/net-next.git/commit/?id=e2b1e4b532abdd39bfb7313146153815e370d60c Marc -- Pengutronix e.K. | Marc Kleine-Budde | Embedded Linux | https://www.pengutronix.de | Vertr

Re: [PATCH v2 3/6] dt-bindings: phy: Add binding for TI TCAN104x CAN transceivers

2021-04-15 Thread Marc Kleine-Budde
On 15.04.2021 11:57:20, Aswath Govindraju wrote: > Hi Marc, > > On 14/04/21 9:03 pm, Marc Kleine-Budde wrote: > > On 14.04.2021 19:35:18, Aswath Govindraju wrote: > >> Add binding documentation for TI TCAN104x CAN transceivers. > >> >

Re: [PATCH v2 0/6] CAN TRANSCEIVER: Add support for CAN transceivers

2021-04-14 Thread Marc Kleine-Budde
pport CAN transceivers. > > Patches 5 & 6 add support for implementing the transceiver as a phy of > m_can_platform driver. regards, Marc -- Pengutronix e.K. | Marc Kleine-Budde | Embedded Linux | https://www.pengutronix.de | Vertretun

Re: [PATCH v2 4/6] phy: phy-can-transceiver: Add support for generic CAN transceiver driver

2021-04-14 Thread Marc Kleine-Budde
\ > broadcom/\ I'm not sure how the phy framework handles this, but I assume it's alphabetically sorted, too. Marc -- Pengutronix e.K. | Marc Kleine-Budde | Embedded Linux | https://www.pengutronix.de

Re: [PATCH v2 4/6] phy: phy-can-transceiver: Add support for generic CAN transceiver driver

2021-04-14 Thread Marc Kleine-Budde
/devicetree/bindings/net/can/ > F: Documentation/devicetree/bindings/phy/ti,tcan104x-can.yaml > +F: drivers/phy/phy-can-transceiver.c > F: drivers/net/can/ please keep this alphabetically sorted Marc -- Pengutronix e.K. | Marc Kleine-Budde | Embed

Re: [PATCH v2 3/6] dt-bindings: phy: Add binding for TI TCAN104x CAN transceivers

2021-04-14 Thread Marc Kleine-Budde
i,tcan1043"; > + #phy-cells = <0>; > + max-bitrate = <500>; > + standby-gpios = <_gpio1 16 GPIO_ACTIVE_LOW>; > + enable-gpios = <_gpio1 67 GPIO_ACTIVE_LOW>; AFAICS the enable gpio is active high. Marc -- Pengutronix e.K. | Marc Kleine-Budde | Embedded Linux | https://www.pengutronix.de | Vertretung West/Dortmund | Phone: +49-231-2826-924 | Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917- | signature.asc Description: PGP signature

Re: [PATCH v2 6/6] can: m_can: Add support for transceiver as phy

2021-04-14 Thread Marc Kleine-Budde
ate_max = transceiver->attrs.max_link_rate; > + > priv->base = addr; > priv->mram_base = mram_addr; > > @@ -108,6 +122,7 @@ static int m_can_plat_probe(struct platform_device *pdev) > mcan_class->pm_clock_support = 1; > mcan_class->can.clock.freq = clk_get_rate(mcan_class->cclk); > mcan_class->dev = >dev; > + mcan_class->transceiver = transceiver; > > mcan_class->ops = _can_plat_ops; Marc -- Pengutronix e.K. | Marc Kleine-Budde | Embedded Linux | https://www.pengutronix.de | Vertretung West/Dortmund | Phone: +49-231-2826-924 | Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917- | signature.asc Description: PGP signature

Re: [PATCH 0/4] CAN TRANSCEIVER: Add support for CAN transceivers

2021-04-14 Thread Marc Kleine-Budde
add it CAN NETWORK DRIVERS. regards, Marc -- Pengutronix e.K. | Marc Kleine-Budde | Embedded Linux | https://www.pengutronix.de | Vertretung West/Dortmund | Phone: +49-231-2826-924 | Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-555

Re: [PATCH 2/4] phy: phy-can-transceiver: Add support for generic CAN transceiver driver

2021-04-14 Thread Marc Kleine-Budde
On 14.04.2021 11:54:36, Aswath Govindraju wrote: > Hi Marc, > > On 12/04/21 3:48 pm, Marc Kleine-Budde wrote: > > On 4/9/21 3:40 PM, Aswath Govindraju wrote: > >> The driver adds support for generic CAN transceivers. Currently > >> the modes supported by this dr

Re: [PATCH] can: etas_es58x: fix null pointer dereference when handling error frames

2021-04-13 Thread Marc Kleine-Budde
d. You might either cancel the pull request > and squash this to 8537257874e9 ("can: etas_es58x: add core support > for ETAS ES58X CAN USB interfaces") or send it as a separate patch. > > Please let me know if you need me to do anything. I'll send a follow-up

Re: [PATCH 1/4] dt-bindings: phy: Add binding for TI TCAN104x CAN transceivers

2021-04-13 Thread Marc Kleine-Budde
On 12.04.2021 12:49:56, Rob Herring wrote: > On Mon, Apr 12, 2021 at 12:19:30PM +0200, Marc Kleine-Budde wrote: > > On 4/9/21 3:40 PM, Aswath Govindraju wrote: > > > Add binding documentation for TI TCAN104x CAN transceivers. > > > > > &

Re: [PATCH 4/4] can: m_can_platform: Add support for transceiver as phy

2021-04-12 Thread Marc Kleine-Budde
100; > + if (!bitrate_max) > + dev_warn(>dev, "Invalid value for transceiver max > bitrate. Ignoring bitrate limit\n"); Please move this check to the generic transcevier code. > + priv->cdev.can.bitrate_max = bitrate_max; > +

Re: [PATCH 1/4] dt-bindings: phy: Add binding for TI TCAN104x CAN transceivers

2021-04-12 Thread Marc Kleine-Budde
required: > + - compatible > + - '#phy-cells' > + > +additionalProperties: false > + > +examples: > + - | > +#include > + > +transceiver1: tcan104x-phy { > + compatible = "ti,tcan1043"; > + #phy-cells = <0>; &g

Re: [PATCH 2/4] phy: phy-can-transceiver: Add support for generic CAN transceiver driver

2021-04-12 Thread Marc Kleine-Budde
et(dev, "enable", GPIOD_OUT_LOW); > + if (IS_ERR(enable_gpio)) > + return PTR_ERR(enable_gpio); > + can_transceiver_phy->enable_gpio = enable_gpio; > + } > + > + phy_set_drvdata(can_transceiver_phy->generic_phy, can

Re: [PATCH v15 0/3] Introducing ETAS ES58X CAN USB interfaces

2021-04-12 Thread Marc Kleine-Budde
x_urb_cmd *urb_cmd) I have applied to linux-can-next/testing with the above spell fix. Thanks for the steady work on this and all the other features. regards, Marc -- Pengutronix e.K. | Marc Kleine-Budde | Embedded Linux | https://www.pengutronix.de | Vertre

Re: [PATCH net-next v1 2/3] net: phy: at803x: AR8085: add loopback support

2021-03-30 Thread Marc Kleine-Budde
p. > + * Documentation says nothing about it, so I take time which seems to > + * work on AR8085. > + */ /* Keep in mind the net multi line comment * style. */ Marc -- Pengutronix e.K. | Marc Kleine-Budde | Embedded Linux | h

Re: [PATCH net-next v1 1/3] net: phy: micrel: KSZ8081: add loopback support

2021-03-30 Thread Marc Kleine-Budde
| Marc Kleine-Budde | Embedded Linux | https://www.pengutronix.de | Vertretung West/Dortmund | Phone: +49-231-2826-924 | Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917- | signature.asc Description: OpenPGP digital signature

Re: [kbuild-all] Re: include/linux/compiler_types.h:315:38: error: call to '__compiletime_assert_536' declared with attribute error: BUILD_BUG_ON failed: offsetof(struct can_frame, len) != offsetof(st

2021-03-29 Thread Marc Kleine-Budde
call cc-option,-mno-thumb-interwork,) | endif regards, Marc -- Pengutronix e.K. | Marc Kleine-Budde | Embedded Linux | https://www.pengutronix.de | Vertretung West/Dortmund | Phone: +49-231-2826-924 | Amtsgericht Hildesheim, HRA 2686 |

Re: drivers/net/can/spi/mcp251xfd/mcp251xfd-core.c:2267:16: warning: taking address of packed member 'hw_tx_obj' of class or structure 'mcp251xfd_tx_obj_load_buf::(anonymous)' may result in an unalign

2021-03-29 Thread Marc Kleine-Budde
. That warning is technically correct, hw_tx_obj is an unaligned pointer in the first warning, but... > vim +2267 drivers/net/can/spi/mcp251xfd/mcp251xfd-core.c > > 55e5b97f003e85 drivers/net/can/spi/mcp25xxfd/mcp25xxfd-core.c Marc > Kleine-Budde 2020-09-18 2215 static void > eb79a267c9b3e6 d

Re: [kbuild-all] Re: include/linux/compiler_types.h:315:38: error: call to '__compiletime_assert_536' declared with attribute error: BUILD_BUG_ON failed: offsetof(struct can_frame, len) != offsetof(st

2021-03-24 Thread Marc Kleine-Budde
ot the compiler, but the ABI. > To make clear in the comments what we are suppressing here any why. Feel free to post an updated patch description. Marc -- Pengutronix e.K. | Marc Kleine-Budde | Embedded Linux | https://www.pengutronix.de | Vertre

Re: [kbuild-all] Re: include/linux/compiler_types.h:315:38: error: call to '__compiletime_assert_536' declared with attribute error: BUILD_BUG_ON failed: offsetof(struct can_frame, len) != offsetof(st

2021-03-23 Thread Marc Kleine-Budde
option it is, stay tuned. Marc -- Pengutronix e.K. | Marc Kleine-Budde | Embedded Linux | https://www.pengutronix.de | Vertretung West/Dortmund | Phone: +49-231-2826-924 | Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-20691

Re: [kbuild-all] Re: include/linux/compiler_types.h:315:38: error: call to '__compiletime_assert_536' declared with attribute error: BUILD_BUG_ON failed: offsetof(struct can_frame, len) != offsetof(st

2021-03-23 Thread Marc Kleine-Budde
on 10.2.1 20210110 (Debian 10.2.1-6) regards, Marc -- Pengutronix e.K. | Marc Kleine-Budde | Embedded Linux | https://www.pengutronix.de | Vertretung West/Dortmund | Phone: +49-231-2826-924 | Amtsgericht Hildesheim, HRA 2686 | Fax: +49-51

Re: [PATCH] net: can: Remove duplicate include of regmap.h

2021-03-23 Thread Marc Kleine-Budde
On 23.03.2021 10:10:25, Wan Jiabing wrote: > linux/regmap.h has been included at line 13, so remove the > duplicate one at line 14. applied to linux-can-next/testing. Thanks, Marc -- Pengutronix e.K. | Marc Kleine-Budde | Embedded Linux |

Re: linux-next: manual merge of the net tree with Linus' tree

2021-03-20 Thread Marc Kleine-Budde
a pull request to David and Jakub. https://lore.kernel.org/r/20210320192649.341832-1-...@pengutronix.de regards, Marc -- Pengutronix e.K. | Marc Kleine-Budde | Embedded Linux | https://www.pengutronix.de | Vertretung West/Dortmund | Phone: +49-231-2826-924 | Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917- | signature.asc Description: OpenPGP digital signature

Re: [PATCH] MAINTAINERS: Update MCAN MMIO device driver maintainer

2021-03-19 Thread Marc Kleine-Budde
On 18.03.2021 16:56:34, Pankaj Sharma wrote: > Update Chandrasekar Ramakrishnan as maintainer for mcan mmio device driver as > I > will be moving to a different role. Applied to can-next/testing. regards, Marc -- Pengutronix e.K. | Marc Kleine-Budde | Embed

Re: [PATCH] dt-bindings: Drop type references on common properties

2021-03-17 Thread Marc Kleine-Budde
Saenz Julienne > Cc: Maxime Ripard > Cc: Linus Walleij > Cc: Bartosz Golaszewski > Cc: Bjorn Andersson > Cc: Krzysztof Kozlowski > Cc: Marc Kleine-Budde > Cc: "David S. Miller" > Cc: Jakub Kicinski > Cc: Srinivas Kandagatla > Cc: Ohad Ben-Cohen >

Re: [RFC v2] net: sched: implement TCQ_F_CAN_BYPASS for lockless qdisc

2021-03-15 Thread Marc Kleine-Budde
ses about 10% with this > patch. > > Signed-off-by: Yunsheng Lin I gave it a short test on a single core imx. No problem here. Marc -- Pengutronix e.K. | Marc Kleine-Budde | Embedded Linux | https://www.pengutronix.de | Vertretung West/Dortmun

Re: [PATCH RFC] net: sched: implement TCQ_F_CAN_BYPASS for lockless qdisc

2021-03-14 Thread Marc Kleine-Budde
vious attempt to > add qdisc bypass to pfifo_fast by Paolo Abeni: > https://lore.kernel.org/netdev/661cc33a-5f65-2769-cc1a-65791cb4b...@pengutronix.de/ > It was reverted because TX reordering was observed with SocketCAN > (although, presumably it should also be seen with Ethernet a

Re: [PATCH] leds: trigger: fix potential deadlock with libata

2021-03-08 Thread Marc Kleine-Budde
On 08.03.2021 15:56:53, Marc Kleine-Budde wrote: > > > meanwhile this patch hit v5.10.x stable and caused a performance > > > degradation on our use case: > > > > > > It's an embedded ARM system, 4x Cortex A53, with an SPI attached CAN > > > contr

Re: [PATCH] leds: trigger: fix potential deadlock with libata

2021-03-08 Thread Marc Kleine-Budde
On 07.03.2021 10:02:32, Boqun Feng wrote: > On Sat, Mar 06, 2021 at 09:39:54PM +0100, Marc Kleine-Budde wrote: > > Hello *, > > > > On 02.11.2020 11:41:52, Andrea Righi wrote: > > > We have the followin

list_add corruption in __percpu_counter_init

2021-03-08 Thread Marc Kleine-Budde
z with ECC RAM and runs now stable on v4.19. Is this a know (or even fixed problem?) Any ideas how to debug this? I'll ask my admins to compile latest v5.10 and give it a try. As this is one of our production machines testing is a bit limited. regards, Marc -- Pengutronix e.K.

Re: [PATCH] leds: trigger: fix potential deadlock with libata

2021-03-06 Thread Marc Kleine-Budde
is 240µs. Reverting this patch, restores the old performance. What is the best way to solve this dilemma? Identify the critical path in our use case? Is there a way we can get around the irqsave in led_trigger_event()? regards, Marc -- Pengutronix e.K. | Marc Kleine-Budde

Re: [PATCH v4 5/6] can: c_can: prepare to up the message objects number

2021-03-04 Thread Marc Kleine-Budde
- Pengutronix e.K. | Marc Kleine-Budde | Embedded Linux | https://www.pengutronix.de | Vertretung West/Dortmund | Phone: +49-231-2826-924 | Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917- | signature.asc Description: PGP signature

Re: [PATCH v4 0/6] can: c_can: add support to 64 message objects

2021-03-04 Thread Marc Kleine-Budde
gt; of tests performed just on x86 and arm architectures. Applied to linux-can-next/testing. I've added some cleanup patches to the series. I'll send it around soon, please test. regards, Marc -- Pengutronix e.K. | Marc Kleine-Budde | Embedded Linux

[PATCH] time: timecounter_cyc2time(): mark 1st argument (struct timecounter) as const

2021-03-03 Thread Marc Kleine-Budde
As the timecounter is not modified in this function, mark it as const. Signed-off-by: Marc Kleine-Budde --- include/linux/timecounter.h | 2 +- kernel/time/timecounter.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/include/linux/timecounter.h b/include/linux

Re: [PATCH v3 5/6] can: c_can: prepare to up the message objects number

2021-03-03 Thread Marc Kleine-Budde
On 03.03.2021 11:31:10, Dario Binacchi wrote: > I think these features need to be developed in a later series. > I would stay with the extension to 64 messages equally divided > between reception and transmission. Fine with me. Marc -- Pengutronix e.K. | Marc Kle

Re: [PATCH v3 5/6] can: c_can: prepare to up the message objects number

2021-03-03 Thread Marc Kleine-Budde
xir.bootlin.com/linux/v5.11/source/drivers/net/can/flexcan.c#L904 This should to IMHO into patch 6. Adding the ethtool support and making the rings configurable would be a separate patch. regards, Marc -- Pengutronix e.K. | Marc Kleine-Budde | Embedded Linux

Re: [PATCH v3 5/6] can: c_can: prepare to up the message objects number

2021-03-02 Thread Marc Kleine-Budde
On 3/2/21 11:50 AM, Dario Binacchi wrote: > Hi Marc, > >> Il 01/03/2021 20:45 Marc Kleine-Budde ha scritto: >> >> >> On 01.03.2021 18:21:42, Dario Binacchi wrote: >>>>> @@ -730,7 +728,7 @@ static void c_can_do_tx(struct net_device *dev) >>&g

Re: [PATCH v2] can: c_can: move runtime PM enable/disable to c_can_platform

2021-03-02 Thread Marc Kleine-Budde
pm_enable/disable code to > c_can_platform. > > Signed-off-by: Tong Zhang Applied to linux-can/testing. Thanks, Marc -- Pengutronix e.K. | Marc Kleine-Budde | Embedded Linux | https://www.pengutronix.de | Vertretung West/Dortmund | Phone: +49

Re: [PATCH v3 5/6] can: c_can: prepare to up the message objects number

2021-03-01 Thread Marc Kleine-Budde
riv->msg_obj_tx_num - 1))) > > > > Do we need 1UL here, too? > > Do you agree if I use the BIT macro ? No, please use GENMASK(priv->msg_obj_tx_num, 0) here. regrads, Marc -- Pengutronix e.K. | Marc Kleine-Budde | Embedded Linux | https://www.pengutronix.de | Vertretung West/Dortmund | Phone: +49-231-2826-924 | Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917- | signature.asc Description: PGP signature

Re: [PATCH] can: c_can: move runtime PM enable/disable to c_can_platform

2021-03-01 Thread Marc Kleine-Budde
gs |= IFF_ECHO; /* we support local echo */ > dev->netdev_ops = _can_netdev_ops; > > err = register_candev(dev); > - if (err) > - c_can_pm_runtime_disable(priv); > - else > - devm_can_led_init(dev); > - > + if (!err) > + devm_can_led_init

Re: [PATCH v3 5/6] can: c_can: prepare to up the message objects number

2021-03-01 Thread Marc Kleine-Budde
On 01.03.2021 14:08:45, Marc Kleine-Budde wrote: > On 01.03.2021 12:38:05, Marc Kleine-Budde wrote: > > On 28.02.2021 11:38:54, Dario Binacchi wrote: > > [...] > > > > > @@ -730,7 +728,7 @@ static void c_can_do_tx(struct net_device *dev) > > > while ((

Re: [PATCH v3 5/6] can: c_can: prepare to up the message objects number

2021-03-01 Thread Marc Kleine-Budde
On 01.03.2021 18:24:31, Dario Binacchi wrote: > Hi Marc, > > > Il 01/03/2021 14:08 Marc Kleine-Budde ha scritto: > > > > > > On 01.03.2021 12:38:05, Marc Kleine-Budde wrote: > > > On 28.02.2021 11:38:54, Dario Binacchi wrote: > > > [...

Re: [PATCH] can: c_can_pci: fix use-after-free

2021-03-01 Thread Marc Kleine-Budde
an/c_can_pci.c > +++ b/drivers/net/can/c_can/c_can_pci.c > @@ -239,12 +239,13 @@ static void c_can_pci_remove(struct pci_dev *pdev) > { > struct net_device *dev = pci_get_drvdata(pdev); > struct c_can_priv *priv = netdev_priv(dev); > - > + void __iomem *addr =

Re: [PATCH v3 5/6] can: c_can: prepare to up the message objects number

2021-03-01 Thread Marc Kleine-Budde
On 01.03.2021 12:38:05, Marc Kleine-Budde wrote: > On 28.02.2021 11:38:54, Dario Binacchi wrote: > [...] > > > @@ -730,7 +728,7 @@ static void c_can_do_tx(struct net_device *dev) > > while ((idx = ffs(pend))) { > > idx--; > > pend &a

Re: [PATCH v2 5/6] can: c_can: prepare to up the message objects number

2021-03-01 Thread Marc Kleine-Budde
is another option. > > > > Do you know if any of the hardware managed by Linux use a D_CAN controller > with 128 message objects? Even the am437x only uses 64 message objects. Ok let's stay with 64 as max for now. regards, Marc -- Pengutronix e.K. | Marc Kleine-B

Re: [PATCH v3 5/6] can: c_can: prepare to up the message objects number

2021-03-01 Thread Marc Kleine-Budde
gt; /* Clear the bits in the tx_active mask */ > atomic_sub(clr, >tx_active); > > - if (clr & (1 << (C_CAN_MSG_OBJ_TX_NUM - 1))) > + if (clr & (1 << (priv->msg_obj_tx_num - 1))) Do we need 1UL here, too? Marc -- Pengutronix e.K.

Re: [PATCH v2 3/6] can: c_can: fix control interface used by c_can_do_tx

2021-03-01 Thread Marc Kleine-Budde
lysis is correct, please update the patch and add a comment to clarify why IF_RX is used instead of changing it to IF_TX. regards, Marc -- Pengutronix e.K. | Marc Kleine-Budde | Embedded Linux | https://www.pengutronix.de | Vertretung West/Dortmund

Re: [PATCH v2 5/6] can: c_can: prepare to up the message objects number

2021-02-26 Thread Marc Kleine-Budde
g_obj_rx_first = 1; > + priv->msg_obj_rx_last = > + priv->msg_obj_rx_first + priv->msg_obj_rx_num - 1; > + priv->msg_obj_rx_mask = ((u64)1 << priv->msg_obj_rx_num) - 1; Here you're casting the 1 to 64bit, but msg_obj_rx_mask is only u32. Use "1UL", i

Re: [PATCH v2 3/6] can: c_can: fix control interface used by c_can_do_tx

2021-02-26 Thread Marc Kleine-Budde
n_inval_tx_object(dev, IF_TX, obj); > can_get_echo_skb(dev, idx, NULL); > bytes += priv->dlc[idx]; > pkts++; > -- > 2.17.1 > > -- Pengutronix e.K. | Marc Kleine-Budde | Embedded Linux |

Re: [PATCH v2 6/6] can: c_can: add support to 64 message objects

2021-02-26 Thread Marc Kleine-Budde
can_pci.c > @@ -31,6 +31,8 @@ enum c_can_pci_reg_align { > struct c_can_pci_data { > /* Specify if is C_CAN or D_CAN */ > enum c_can_dev_id type; > + /* Number of message objects */ > + int msg_obj_num; unsigned int Marc -- Pengutronix e.K. |

Re: [PATCH v2 5/6] can: c_can: prepare to up the message objects number

2021-02-26 Thread Marc Kleine-Budde
SG_OBJ_TX_FIRST (C_CAN_MSG_OBJ_RX_LAST + 1) > - > -#define RECEIVE_OBJECT_BITS 0x > > enum reg { > C_CAN_CTRL_REG = 0, > @@ -193,6 +182,14 @@ struct c_can_priv { > struct napi_struct napi; > struct net_device *dev; > struct device *device; > + int msg_obj_num; > + int msg_obj_rx_num; > + int msg_obj_tx_num; > + int msg_obj_rx_first; > + int msg_obj_rx_last; > + int msg_obj_tx_first; > + int msg_obj_tx_last; I think these should/could be unsigned int. > + u32 msg_obj_rx_mask; Is this variable big enough after you've extended the driver to use 64 mailboxes? If you want to support 128 message objects converting the driver to the linux bitmap API is another option. Marc -- Pengutronix e.K. | Marc Kleine-Budde | Embedded Linux | https://www.pengutronix.de | Vertretung West/Dortmund | Phone: +49-231-2826-924 | Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917- | signature.asc Description: PGP signature

Re: [PATCH 5/6] can: c_can: prepare to up the message objects number

2021-02-25 Thread Marc Kleine-Budde
^ >1 error generated. For now you can use 16, which means no change. I've added Alexander and Federico to Cc, they added the intel pch and st micro support, maybe they can help and add the correct size. regards, Marc -- Pengutronix e.K. | Marc Kleine-Budde

Re: [PATCH 5/6] can: c_can: prepare to up the message objects number

2021-02-24 Thread Marc Kleine-Budde
v(dev); > + return NULL; > + } > + > + netif_napi_add(dev, >napi, c_can_poll, priv->msg_obj_rx_num); Marc -- Pengutronix e.K. | Marc Kleine-Budde | Embedded Linux | https://www.pengutronix.de | Vertretung West/Dortmund | Phone: +49-231-2826-924 | Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917- | signature.asc Description: PGP signature

Re: [PATCH net v3 1/1] can: can_skb_set_owner(): fix ref counting if socket was closed before setting skb ownership

2021-02-24 Thread Marc Kleine-Budde
by user space, the refcount may already be 0 (and the socket will be freed after the last TX skb has been freed). So only increase socket refcount if the refcount is > 0. regards Marc P.S.: Have you had time to look at my ISOTOP RFC patch? -- Pengutronix e.K. | Marc Kleine-Budde | Embedded Linux | https://www.pengutronix.de | Vertretung West/Dortmund | Phone: +49-231-2826-924 | Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917- | signature.asc Description: PGP signature

Re: [PATCH net v1 3/3] [RFC] mac80211: ieee80211_store_ack_skb(): make use of skb_clone_sk_optional()

2021-02-22 Thread Marc Kleine-Budde
X status time, which is supposed to put > it into the socket's error queue, but if the socket is closed ... no > point in that. We haven't looked at the callers of ieee80211_store_ack_skb(). Marc -- Pengutronix e.K. | Marc Kleine-Budde | Embedded Linux

Re: [PATCH] can: ucan: fix alignment constraints

2021-02-09 Thread Marc Kleine-Budde
On 09.02.2021 10:34:42, David Laight wrote: > From: Marc Kleine-Budde > > Sent: 08 February 2021 13:16 > > > > On 04.02.2021 17:26:13, Arnd Bergmann wrote: > > > From: Arnd Bergmann > > > > > > struct ucan_message_in contains member with 4-byte a

Re: [PATCH] can: ucan: fix alignment constraints

2021-02-08 Thread Marc Kleine-Budde
n_message_in' is less than 4 [-Wpacked-not-aligned] > > Mark the outer structure to have the same alignment as the inner > one. > > Signed-off-by: Arnd Bergmann Applied to linux-can-next/testing. Thanks, Marc -- Pengutronix e.K. | Marc Kleine-Budde | Embe

Re: [PATCH] dt-bindings: can: rcar_canfd: Group tuples in pin control properties

2021-02-08 Thread Marc Kleine-Budde
On 04.02.2021 13:59:37, Geert Uytterhoeven wrote: > To improve human readability and enable automatic validation, the tuples > in "pinctrl-*" properties should be grouped using angle brackets. > > Signed-off-by: Geert Uytterhoeven Acked-by: Marc Kleine-Budde regards, Mar

Re: [PATCH 2/2] can: m_can: m_can_class_allocate_dev(): remove impossible error return judgment

2021-02-05 Thread Marc Kleine-Budde
On 05.02.2021 16:46:16, Xulin Sun wrote: > On 2021/2/5 下午4:19, Marc Kleine-Budde wrote: > > On 05.02.2021 15:25:59, Xulin Sun wrote: > > > If the previous can_net device has been successfully allocated, its > > > private data structure is impossible to be empty, remove

Re: [PATCH 2/2] can: m_can: m_can_class_allocate_dev(): remove impossible error return judgment

2021-02-05 Thread Marc Kleine-Budde
our analysis is correct, the netdev_priv() will never fail. But how will this trigger a mem leak on alloc_candev()? I've removed that statement. I'll add it back, if I've missed something. > Signed-off-by: Xulin Sun Applied to linux-can-next/testing. Thanks, Marc -- Pengutronix e.K.

Re: [PATCH 1/2] can: m_can: m_can_plat_probe(): free can_net device in case probe fails

2021-02-05 Thread Marc Kleine-Budde
t v5.10.x. If you're on a kernel that's still supported, and you're using the latest stable of that kernel, and it doesn't have that patch applied, ask on linux-stable to pick up that patch. Marc -- Pengutronix e.K. | Marc Kleine-Budde | Embedded Linux

Re: [PATCH] can: xilinx_can: Simplify code by using dev_err_probe()

2021-02-04 Thread Marc Kleine-Budde
gt; Signed-off-by: Michal Simek Applied to linux-can-next/testing. Thanks, Marc -- Pengutronix e.K. | Marc Kleine-Budde | Embedded Linux | https://www.pengutronix.de | Vertretung West/Dortmund | Phone: +49-231-2826-924 | Amtsgericht Hildesh

Re: [PATCH v4 0/2] add support for GPIO based counter

2021-01-26 Thread Marc Kleine-Budde
This is only true for >= v2.6.3 :D https://lwn.net/Articles/71732/ Feeling old, Marc -- Pengutronix e.K. | Marc Kleine-Budde | Embedded Linux | https://www.pengutronix.de | Vertretung West/Dortmund | Phone: +49-231-2826-924 | Amtsgericht Hilde

Re: [PATCH v4 0/2] add support for GPIO based counter

2021-01-26 Thread Marc Kleine-Budde
IIRC a long time ago it was 24 bit only Marc -- Pengutronix e.K. | Marc Kleine-Budde | Embedded Linux | https://www.pengutronix.de | Vertretung West/Dortmund | Phone: +49-231-2826-924 | Amtsgericht Hildesheim, HRA 2686 | Fax:

Re: [PATCH] can: mcba_usb: remove h from printk format specifier

2021-01-26 Thread Marc Kleine-Budde
teger promotion is already done and %hx and %hhx is useless > so do not encourage the use of %hh[xudi] or %h[xudi]. > > Signed-off-by: Tom Rix Added to linux-can-next/testing. Thanks, Marc -- Pengutronix e.K. | Marc Kleine-Budde | Embedded Linux |

Re: [PATCH v3] iio: adc: stm32-adc: enable timestamping for non-DMA usage

2021-01-25 Thread Marc Kleine-Budde
n completion; > - u16 buffer[STM32_ADC_MAX_SQ]; > + u16 buffer[STM32_ADC_MAX_SQ + 8] __aligned(8); ^^ ^ How does that fit together? Marc -- Pengutronix e.K. | Marc Kleine-Budde | Embedded Linux | h

Re: [RFC PATCH net 1/2] net: introduce CAN specific pointer in the struct net_device

2021-01-22 Thread Marc Kleine-Budde
ich are limited by all being > ARPHDR_ETHER can start using ml_priv as well? > > > +#if IS_ENABLED(CONFIG_CAN) > > + struct can_ml_priv *can; > > +#endif > > Perhaps put it next to all the _ptr fields? Makes sense. Oleksij will resping the series. regards

Re: [PATCH v4] can: mcp251xfd: replace sizeof(u32) with val_bytes in regmap

2021-01-22 Thread Marc Kleine-Budde
Applied to linux-can-next/testing. Thanks, Marc -- Pengutronix e.K. | Marc Kleine-Budde | Embedded Linux | https://www.pengutronix.de | Vertretung West/Dortmund | Phone: +49-231-2826-924 | Amtsgericht Hildesheim, HRA 2686 | Fax:

Re: [PATCH v1] can: mcp251xfd: use regmap_bulk_write for compatibility

2021-01-22 Thread Marc Kleine-Budde
On 1/22/21 8:59 AM, Su wrote: > > 在 2021/1/22 下午3:26, Marc Kleine-Budde 写道: >> On 1/22/21 4:02 AM, Su Yanjun wrote: >>> Recently i use mcp2518fd on 4.x kernel which multiple write is not >>> backported, regmap_raw_write will cause old kernel crash because the >

Re: [PATCH v1 2/2] isa: Make the remove callback for isa drivers return void

2021-01-21 Thread Marc Kleine-Budde
tionally anyhow. > > Signed-off-by: Uwe Kleine-König > --- > drivers/net/can/sja1000/tscan1.c | 4 +--- For the can driver: Acked-by: Marc Kleine-Budde Marc -- Pengutronix e.K. | Marc Kleine-Budde | Embedded Linux | https://www.p

Re: [PATCH v3] can: mcp251xfd: replace sizeof(u32) with val_bytes in regmap

2021-01-21 Thread Marc Kleine-Budde
d_irq(int irq, void *dev_id) > err = regmap_bulk_read(priv->map_reg, MCP251XFD_REG_INT, > >regs_status, > sizeof(priv->regs_status) / > -sizeof(u32)); > +

Re: [PATCH v1] can: mcp251xfd: use regmap_bulk_write for compatibility

2021-01-21 Thread Marc Kleine-Budde
Pengutronix e.K. | Marc Kleine-Budde | Embedded Linux | https://www.pengutronix.de | Vertretung West/Dortmund | Phone: +49-231-2826-924 | Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917- | signature.asc Description: Ope

Re: [PATCH v1] can: mcp251xfd: Add some sysfs debug interfaces for registers r/w

2021-01-21 Thread Marc Kleine-Budde
, Marc -- Pengutronix e.K. | Marc Kleine-Budde | Embedded Linux | https://www.pengutronix.de | Vertretung West/Dortmund | Phone: +49-231-2826-924 | Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917- | signature.asc Description: O

Re: [PATCH v2] can: mcp251xfd: replace sizeof(u32) with val_bytes in regmap

2021-01-21 Thread Marc Kleine-Budde
980 +16 > > Total: Before=20832, After=20936, chg +0.50% Marc -- Pengutronix e.K. | Marc Kleine-Budde | Embedded Linux | https://www.pengutronix.de | Vertretung West/Dortmund | Phone: +49-231-2826-924 | Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917- | signature.asc Description: PGP signature

Re: [PATCH v2] can: mcp251xfd: replace sizeof(u32) with val_bytes in regmap

2021-01-21 Thread Marc Kleine-Budde
>regs_status, > sizeof(priv->regs_status) / > -sizeof(u32)); > +val_bytes); > if (err) > goto out_fail; >

Re: [PATCH v1] can: mcp251xfd: replace sizeof(u32) with val_bytes in regmap

2021-01-21 Thread Marc Kleine-Budde
[-Werror=return-type] 188 | } | ^ cc1: some warnings being treated as errors Marc -- Pengutronix e.K. | Marc Kleine-Budde | Embedded Linux | https://www.pengutronix.de | Vertretung West/Dortmund | Phone: +49-231-2826-924 | Amtsger

Re: [PATCH] can: mcp251xfd: mcp251xfd_handle_ivmif(): fix wrong NULL pointer check

2021-01-18 Thread Marc Kleine-Budde
m. While in: | ca4c6ebeeb50 can: mcp251xfd: mcp251xfd_handle_rxif_one(): | fix wrong NULL pointer check a real problem has been fixed. Marc -- Pengutronix e.K. | Marc Kleine-Budde | Embedded Linux | https://www.pengutronix.de | Vertretung West

Re: [PATCH 1/2] can: c_can: support 64 message objects for D_CAN

2021-01-13 Thread Marc Kleine-Budde
Or perhaps I can find > some time to do that myself, if that's OK with you. Take the patches as is and improve them. Marc -- Pengutronix e.K. | Marc Kleine-Budde | Embedded Linux | https://www.pengutronix.de | Vertretung West/Dortmund

Re: [PATCH] can: mcp251xfd: fix wrong check in mcp251xfd_handle_rxif_one

2021-01-12 Thread Marc Kleine-Budde
ip MCP25xxFD SPI > CAN") > Signed-off-by: Qinglang Miao applied to linux-can/testing Tnx, Marc -- Pengutronix e.K. | Marc Kleine-Budde | Embedded Linux | https://www.pengutronix.de | Vertretung West/Dortmund | Phone: +49-231-2826-924

Re: [PATCH v3 1/1] can: dev: add software tx timestamps

2021-01-12 Thread Marc Kleine-Budde
| Marc Kleine-Budde | Embedded Linux | https://www.pengutronix.de | Vertretung West/Dortmund | Phone: +49-231-2826-924 | Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917- | signature.asc Description: OpenPGP digital signature

Re: [PATCH v3 1/1] can: dev: add software tx timestamps

2021-01-11 Thread Marc Kleine-Budde
Applied to linux-can-next/testing (ontop of my dev infrastructure cleanup). regards, Marc -- Pengutronix e.K. | Marc Kleine-Budde | Embedded Linux | https://www.pengutronix.de | Vertretung West/Dortmund | Phone: +49-231-2826-924 | Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917- | signature.asc Description: OpenPGP digital signature

Re: [PATCH for can-next] MAINTAINERS: adjust entry to tcan4x5x file split

2021-01-08 Thread Marc Kleine-Budde
> Signed-off-by: Lukas Bulwahn > --- > applies cleanly on next-20210107, not for current master > > Marc, please pick this for your -next tree on top of the tcan4x5x cleanup. Makes perfect sense. Applied to linux-can-next. Thanks, Marc -- Pengutronix e.K. |

Re: [PATCH] MAINTAINERS: Update MCAN MMIO device driver maintainer

2021-01-04 Thread Marc Kleine-Budde
On 1/4/21 1:31 PM, Sriram Dash wrote: > Update Pankaj Sharma as maintainer for mcan mmio device driver as I > will be moving to a different role. > > Signed-off-by: Sriram Dash > --- Applied to linux-can/testing. Tnx, Marc -- Pengutronix e.K. | Ma

Re: [PATCH v2] can: rcar: Update help description for CAN_RCAR config

2021-01-04 Thread Marc Kleine-Budde
On 1/4/21 10:03 AM, Lad Prabhakar wrote: > The rcar_can driver also supports RZ/G SoC's, update the description to > reflect this. > > Signed-off-by: Lad Prabhakar applied to linux-can/testing Thanks, Marc -- Pengutronix e.K. | Marc Kleine-Budde | Em

Re: net/can/isotp.c:1240:13: sparse: sparse: incorrect type in initializer (different address spaces)

2021-01-04 Thread Marc Kleine-Budde
233struct sock *sk = sock->sk; > 1234struct isotp_sock *so = isotp_sk(sk); > 1235int len; > 1236void *val; > 1237 > 1238if (level != SOL_CAN_ISOTP) > 1239return -EI

Re: [PATCH] can: rcar: Update help description for CAN_RCAR config

2021-01-04 Thread Marc Kleine-Budde
nds good. Better make the description more generic instead of updating it each time a new SoC comes along. regards, Marc -- Pengutronix e.K. | Marc Kleine-Budde | Embedded Linux | https://www.pengutronix.de | Vertretung West/Dortmund | Phone: +49-231-2826-

Re: [PATCH 3/7] can: kvaser_pciefd: select CONFIG_CRC32

2021-01-04 Thread Marc Kleine-Budde
`crc32_be' > > Fixes: 26ad340e582d ("can: kvaser_pciefd: Add driver for Kvaser PCIEcan > devices") > Signed-off-by: Arnd Bergmann Acked-by: Marc Kleine-Budde regrards, Marc -- Pengutronix e.K. | Marc Kleine-Budde | Embedded Linux | ht

Re: [PATCH V5 0/5] can: flexcan: add stop mode support for i.MX8QM

2020-12-22 Thread Marc Kleine-Budde
ion for i.MX8QM The patch "firmware: imx: always export SCU symbols" is not yet in net-next/master, so the flexcan patch will not compile where the SCU is switched off. Marc -- Pengutronix e.K. | Marc Kleine-Budde | Embedded Linux | h

Re: [PATCH net v1] net: dsa: qca: ar9331: fix sleeping function called from invalid context bug

2020-12-04 Thread Marc Kleine-Budde
dev_err(priv->dev, "could not unmask IRQ\n"); > + dev_err(priv->dev, "could not mask IRQ\n"); Technically this could be a mask or unmask operation. What about changing the error message to: "faild to change IRQ mask"? Marc -- Pengutronix e.K.

Re: [PATCH v2 2/2] net: dsa: qca: ar9331: export stats64

2020-12-02 Thread Marc Kleine-Budde
tats64(). > > The mutex lock should prevent a race in the read modify write operations > for in the stats->* Makes sense! Marc -- Pengutronix e.K. | Marc Kleine-Budde | Embedded Linux | https://www.pengutronix.de | Vertretung West/Dortmun

  1   2   3   4   5   6   7   8   9   10   >