From: Frank Li <Frank.li@nxp.com>
To: Wei Fang <wei.fang@nxp.com>
Cc: Shenwei Wang <shenwei.wang@nxp.com>,
Clark Wang <xiaoning.wang@nxp.com>,
"andrew+netdev@lunn.ch" <andrew+netdev@lunn.ch>,
"davem@davemloft.net" <davem@davemloft.net>,
"edumazet@google.com" <edumazet@google.com>,
"kuba@kernel.org" <kuba@kernel.org>,
"pabeni@redhat.com" <pabeni@redhat.com>,
"eric@nelint.com" <eric@nelint.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>
Subject: Re: [PATCH net-next 2/5] net: fec: simplify the conditional preprocessor directives
Date: Thu, 13 Nov 2025 11:27:05 -0500 [thread overview]
Message-ID: <aRYG2YqpeOr3U3XS@lizhi-Precision-Tower-5810> (raw)
In-Reply-To: <AS8PR04MB8497494755B820A2D33ED39488CCA@AS8PR04MB8497.eurprd04.prod.outlook.com>
On Wed, Nov 12, 2025 at 01:53:15AM +0000, Wei Fang wrote:
> > > - if (!of_machine_is_compatible("fsl,imx6ul")) {
> > > - reg_list = fec_enet_register_offset;
> > > - reg_cnt = ARRAY_SIZE(fec_enet_register_offset);
> > > - } else {
> > > +
> > > +#if !defined(CONFIG_M5272) || defined(CONFIG_COMPILE_TEST)
> > > + if (of_machine_is_compatible("fsl,imx6ul")) {
> >
> > There are stub of_machine_is_compatible(), so needn't #ifdef here.
> >
>
> fec_enet_register_offset_6ul is not defined when CONFIG_M5272 is
> enabled, so we still need it here.
Is it possible to remove ifdef for fec_enet_register_offset_6ul?
Frank
>
> > > reg_list = fec_enet_register_offset_6ul;
> > > reg_cnt = ARRAY_SIZE(fec_enet_register_offset_6ul);
> > > }
> > > -#else
> > > - /* coldfire */
> > > - static u32 *reg_list = fec_enet_register_offset;
> > > - static const u32 reg_cnt = ARRAY_SIZE(fec_enet_register_offset);
> > > #endif
> > > ret = pm_runtime_resume_and_get(dev);
> > > if (ret < 0)
> > > --
> > > 2.34.1
> > >
next prev parent reply other threads:[~2025-11-13 16:27 UTC|newest]
Thread overview: 23+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-11-11 10:00 [PATCH net-next 0/5] net: fec: do some cleanup for the driver Wei Fang
2025-11-11 10:00 ` [PATCH net-next 1/5] net: fec: remove useless conditional preprocessor directives Wei Fang
2025-11-11 22:15 ` Frank Li
2025-11-12 20:13 ` Andrew Lunn
2025-11-13 1:35 ` Wei Fang
2025-11-11 10:00 ` [PATCH net-next 2/5] net: fec: simplify the " Wei Fang
2025-11-11 22:24 ` Frank Li
2025-11-12 1:53 ` Wei Fang
2025-11-13 16:27 ` Frank Li [this message]
2025-11-14 2:20 ` Wei Fang
2025-11-18 3:04 ` Wei Fang
2025-11-11 10:00 ` [PATCH net-next 3/5] net: fec: remove struct fec_enet_priv_txrx_info Wei Fang
2025-11-11 22:30 ` Frank Li
2025-11-12 1:56 ` Wei Fang
2025-11-11 10:00 ` [PATCH net-next 4/5] net: fec: remove rx_align from fec_enet_private Wei Fang
2025-11-11 22:34 ` Frank Li
2025-11-12 2:00 ` Wei Fang
2025-11-12 20:25 ` Andrew Lunn
2025-11-13 1:40 ` Wei Fang
2025-11-13 13:10 ` Andrew Lunn
2025-11-14 2:17 ` Wei Fang
2025-11-11 10:00 ` [PATCH net-next 5/5] net: fec: remove duplicate macros of the BD status Wei Fang
2025-11-11 22:39 ` Frank Li
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=aRYG2YqpeOr3U3XS@lizhi-Precision-Tower-5810 \
--to=frank.li@nxp.com \
--cc=andrew+netdev@lunn.ch \
--cc=davem@davemloft.net \
--cc=edumazet@google.com \
--cc=eric@nelint.com \
--cc=imx@lists.linux.dev \
--cc=kuba@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=netdev@vger.kernel.org \
--cc=pabeni@redhat.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