mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Marc Kleine-Budde <mkl@pengutronix.de>
To: Wei Fang <wei.fang@nxp.com>
Cc: Shenwei Wang <shenwei.wang@nxp.com>,
	 Clark Wang <xiaoning.wang@nxp.com>,
	"David S. Miller" <davem@davemloft.net>,
	 Eric Dumazet <edumazet@google.com>,
	Jakub Kicinski <kuba@kernel.org>,
	 Paolo Abeni <pabeni@redhat.com>,
	Richard Cochran <richardcochran@gmail.com>,
	 "imx@lists.linux.dev" <imx@lists.linux.dev>,
	"netdev@vger.kernel.org" <netdev@vger.kernel.org>,
	 "linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	"kernel@pengutronix.de" <kernel@pengutronix.de>
Subject: Re: RE: [PATCH net-next 07/13] net: fec: fec_probe(): update quirk: bring IRQs in correct order
Date: Thu, 17 Oct 2024 08:16:12 +0200	[thread overview]
Message-ID: <20241017-affable-impartial-rhino-a422ec-mkl@pengutronix.de> (raw)
In-Reply-To: <PAXPR04MB85103D3E433F3FBE5DDFA15C88472@PAXPR04MB8510.eurprd04.prod.outlook.com>

[-- Attachment #1: Type: text/plain, Size: 2878 bytes --]

On 17.10.2024 03:09:15, Wei Fang wrote:
> > -----Original Message-----
> > From: Marc Kleine-Budde <mkl@pengutronix.de>
> > Sent: 2024年10月17日 5:52
> > To: Wei Fang <wei.fang@nxp.com>; Shenwei Wang <shenwei.wang@nxp.com>;
> > Clark Wang <xiaoning.wang@nxp.com>; David S. Miller
> > <davem@davemloft.net>; Eric Dumazet <edumazet@google.com>; Jakub
> > Kicinski <kuba@kernel.org>; Paolo Abeni <pabeni@redhat.com>; Richard
> > Cochran <richardcochran@gmail.com>
> > Cc: imx@lists.linux.dev; netdev@vger.kernel.org; linux-kernel@vger.kernel.org;
> > kernel@pengutronix.de; Marc Kleine-Budde <mkl@pengutronix.de>
> > Subject: [PATCH net-next 07/13] net: fec: fec_probe(): update quirk: bring IRQs
> > in correct order
> > 
> > With i.MX8MQ and compatible SoCs, the order of the IRQs in the device
> > tree is not optimal. The driver expects the first three IRQs to match
> > their corresponding queue, while the last (fourth) IRQ is used for the
> > PPS:
> > 
> > - 1st IRQ: "int0": queue0 + other IRQs
> > - 2nd IRQ: "int1": queue1
> > - 3rd IRQ: "int2": queue2
> > - 4th IRQ: "pps": pps
> > 
> > However, the i.MX8MQ and compatible SoCs do not use the
> > "interrupt-names" property and specify the IRQs in the wrong order:
> > 
> > - 1st IRQ: queue1
> > - 2nd IRQ: queue2
> > - 3rd IRQ: queue0 + other IRQs
> > - 4th IRQ: pps
> > 
> > First rename the quirk from FEC_QUIRK_WAKEUP_FROM_INT2 to
> > FEC_QUIRK_INT2_IS_MAIN_IRQ, to better reflect it's functionality.
> > 
> > If the FEC_QUIRK_INT2_IS_MAIN_IRQ quirk is active, put the IRQs back
> > in the correct order, this is done in fec_probe().
> > 
> 
> I think FEC_QUIRK_INT2_IS_MAIN_IRQ or FEC_QUIRK_WAKEUP_FROM_INT2
> is *NO* needed anymore. Actually, INT2 is also the main IRQ for i.MX8QM and
> its compatible SoCs, but i.MX8QM uses a different solution. I don't know why
> there are two different ways of doing it, as I don't know the history. But you can
> refer to the solution of i.MX8QM, which I think is more suitable.
> 
> See arch/arm64/boot/dts/freescale/imx8-ss-conn.dtsi, the IRQ 258 is
> placed first.

Yes, that is IMHO the correct description of the IP core, but the
i.MX8M/N/Q DTS have the wrong order of IRQs. And for compatibility
reasons (fixed DTS with old driver) it's IMHO not possible to change the
DTS.

> fec1: ethernet@5b040000 {
> 		reg = <0x5b040000 0x10000>;
> 		interrupts = <GIC_SPI 258 IRQ_TYPE_LEVEL_HIGH>,
> 			     <GIC_SPI 256 IRQ_TYPE_LEVEL_HIGH>,
> 			     <GIC_SPI 257 IRQ_TYPE_LEVEL_HIGH>,
> 			     <GIC_SPI 259 IRQ_TYPE_LEVEL_HIGH>;

regards,
Marc

-- 
Pengutronix e.K.                 | Marc Kleine-Budde          |
Embedded Linux                   | https://www.pengutronix.de |
Vertretung Nürnberg              | Phone: +49-5121-206917-129 |
Amtsgericht Hildesheim, HRA 2686 | Fax:   +49-5121-206917-9   |

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 488 bytes --]

  reply	other threads:[~2024-10-17  6:16 UTC|newest]

Thread overview: 60+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-10-16 21:51 [PATCH net-next 00/13] net: fec: cleanups, update quirk, update IRQ naming Marc Kleine-Budde
2024-10-16 21:51 ` [PATCH net-next 01/13] net: fec: fix typos found by codespell Marc Kleine-Budde
2024-10-17  1:31   ` Wei Fang
2024-10-17  1:52   ` Frank Li
2024-11-15 14:40   ` Csókás Bence
2024-10-16 21:51 ` [PATCH net-next 02/13] net: fec: struct fec_enet_private: remove obsolete comment Marc Kleine-Budde
2024-10-17  1:37   ` Wei Fang
2024-10-17  1:55   ` Frank Li
2024-10-17  6:53     ` Marc Kleine-Budde
2024-10-16 21:51 ` [PATCH net-next 03/13] net: fec: add missing header files Marc Kleine-Budde
2024-10-17  1:40   ` Wei Fang
2024-10-17  1:56   ` Frank Li
2024-10-17  6:53     ` Marc Kleine-Budde
2024-10-16 21:51 ` [PATCH net-next 04/13] net: fec: rename struct fec_devinfo fec_imx6x_info -> fec_imx6sx_info Marc Kleine-Budde
2024-10-17  1:44   ` Wei Fang
2024-10-17  1:59   ` Frank Li
2024-10-17  6:54     ` Marc Kleine-Budde
2024-10-16 21:51 ` [PATCH net-next 05/13] net: fec: fec_restart(): introduce a define for FEC_ECR_SPEED Marc Kleine-Budde
2024-10-17  1:47   ` Wei Fang
2024-10-17  2:05   ` Frank Li
2024-10-17  6:56     ` Marc Kleine-Budde
2024-10-16 21:51 ` [PATCH net-next 06/13] net: fec: fec_restart(): make use of FEC_ECR_RESET Marc Kleine-Budde
2024-10-17  1:49   ` Wei Fang
2024-10-17  2:07   ` Frank Li
2024-10-17  6:56     ` Marc Kleine-Budde
2024-10-16 21:51 ` [PATCH net-next 07/13] net: fec: fec_probe(): update quirk: bring IRQs in correct order Marc Kleine-Budde
2024-10-17  2:15   ` Frank Li
2024-10-17  6:13     ` Marc Kleine-Budde
2024-10-17  3:09   ` Wei Fang
2024-10-17  6:16     ` Marc Kleine-Budde [this message]
2024-10-17  7:43       ` Wei Fang
2024-10-17 10:21         ` Marc Kleine-Budde
2024-10-17 14:03           ` Frank Li
2024-10-17 14:21             ` Marc Kleine-Budde
2024-10-17 15:30               ` Frank Li
2024-10-18  9:16                 ` Marc Kleine-Budde
2024-10-18 15:26                   ` Frank Li
2024-10-16 21:51 ` [PATCH net-next 08/13] net: fec: fec_probe(): let IRQ name reflect its function Marc Kleine-Budde
2024-10-17  2:24   ` Frank Li
2024-10-17  3:12   ` Wei Fang
2024-10-16 21:51 ` [PATCH net-next 09/13] net: fec: fec_enet_rx_queue(): use same signature as fec_enet_tx_queue() Marc Kleine-Budde
2024-10-17  2:32   ` Frank Li
2024-10-17  7:02     ` Marc Kleine-Budde
2024-10-16 21:51 ` [PATCH net-next 10/13] net: fec: fec_enet_rx_queue(): replace open coded cast by skb_vlan_eth_hdr() Marc Kleine-Budde
2024-10-17  2:44   ` Frank Li
2024-10-17  7:04     ` Marc Kleine-Budde
2024-10-17  3:15   ` Wei Fang
2024-10-16 21:51 ` [PATCH net-next 11/13] net: fec: fec_enet_rx_queue(): reduce scope of data Marc Kleine-Budde
2024-10-17  2:49   ` Frank Li
2024-10-17  3:19   ` Wei Fang
2024-10-16 21:52 ` [PATCH net-next 12/13] net: fec: fec_enet_rx_queue(): move_call to _vlan_hwaccel_put_tag() Marc Kleine-Budde
2024-10-17  3:05   ` Frank Li
2024-10-17  7:05     ` Marc Kleine-Budde
2024-10-17  3:29   ` Wei Fang
2024-10-16 21:52 ` [PATCH net-next 13/13] net: fec: fec_enet_rx_queue(): factor out VLAN handling into separate function fec_enet_rx_vlan() Marc Kleine-Budde
2024-10-17  3:07   ` Frank Li
2024-10-17  3:33   ` Wei Fang
2024-10-17  7:09     ` Marc Kleine-Budde
2024-10-17  7:48       ` Wei Fang
2024-10-18  7:21         ` Marc Kleine-Budde

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20241017-affable-impartial-rhino-a422ec-mkl@pengutronix.de \
    --to=mkl@pengutronix.de \
    --cc=davem@davemloft.net \
    --cc=edumazet@google.com \
    --cc=imx@lists.linux.dev \
    --cc=kernel@pengutronix.de \
    --cc=kuba@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=netdev@vger.kernel.org \
    --cc=pabeni@redhat.com \
    --cc=richardcochran@gmail.com \
    --cc=shenwei.wang@nxp.com \
    --cc=wei.fang@nxp.com \
    --cc=xiaoning.wang@nxp.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®