From: "Arnd Bergmann" <arnd@kernel.org>
To: "Richard Cochran" <richardcochran@gmail.com>,
"Tianfei Zhang" <tianfei.zhang@intel.com>
Cc: Netdev <netdev@vger.kernel.org>,
linux-fpga@vger.kernel.org,
"Ilpo Järvinen" <ilpo.jarvinen@linux.intel.com>,
"Andy Shevchenko" <andriy.shevchenko@linux.intel.com>,
vinicius.gomes@intel.com, pierre-louis.bossart@linux.intel.com,
marpagan@redhat.com, russell.h.weight@intel.com,
matthew.gerlach@linux.intel.com,
"Nicolas Pitre" <nico@fluxnic.net>,
"Raghavendra Khadatare" <raghavendrax.anand.khadatare@intel.com>
Subject: Re: [PATCH v3] ptp: add ToD device driver for Intel FPGA cards
Date: Tue, 28 Mar 2023 16:48:45 +0200 [thread overview]
Message-ID: <acd9a75d-4363-4e64-97e7-7b53cbcc9b3b@app.fastmail.com> (raw)
In-Reply-To: <ZCL8veyS5xNUMCCt@hoboy.vegasvil.org>
On Tue, Mar 28, 2023, at 16:42, Richard Cochran wrote:
> On Tue, Mar 28, 2023 at 10:24:55AM -0400, Tianfei Zhang wrote:
>
>> v3:
>> - add PTP_1588_CLOCK dependency for PTP_DFL_TOD in Kconfig file.
>> - don't need handle NULL case for ptp_clock_register() after adding
>> PTP_1588_CLOCK dependency.
>
> Sorry, but this isn't how it is done...
>
>> +config PTP_DFL_TOD
>> + tristate "FPGA DFL ToD Driver"
>> + depends on FPGA_DFL
>> + depends on PTP_1588_CLOCK
>
> Try these commands:
>
> git grep "depends on PTP_1588_CLOCK_OPTIONAL"
> git grep "depends on PTP_1588_CLOCK_OPTIONAL" | grep -v OPTIONAL
>
> Driver must depend on PTP_1588_CLOCK_OPTIONAL and then handle the NULL
> case correctly.
I think this one is one of the (few) cases where the 'depends on
PTP_1588_CLOCK' is correct and 'depends on PTP_1588_CLOCK_OPTIONAL'
would be wrong:
Using PTP_1588_CLOCK_OPTIONAL as a dependency for PTP_DFL_TOD would
allow enabling the driver even when PTP_1588_CLOCK is completely
disabled, which would cleanly build but not do anything useful
because the driver only handles PTP and not also networking.
Arnd
next prev parent reply other threads:[~2023-03-28 14:51 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-03-28 14:24 [PATCH v3] ptp: add ToD device driver for Intel FPGA cards Tianfei Zhang
2023-03-28 14:42 ` Richard Cochran
2023-03-28 14:48 ` Arnd Bergmann [this message]
2023-03-28 23:45 ` Richard Cochran
2023-03-29 2:34 ` Richard Cochran
2023-03-29 10:57 ` Ilpo Järvinen
2023-03-29 13:54 ` Zhang, Tianfei
2023-03-30 4:40 ` patchwork-bot+netdevbpf
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=acd9a75d-4363-4e64-97e7-7b53cbcc9b3b@app.fastmail.com \
--to=arnd@kernel.org \
--cc=andriy.shevchenko@linux.intel.com \
--cc=ilpo.jarvinen@linux.intel.com \
--cc=linux-fpga@vger.kernel.org \
--cc=marpagan@redhat.com \
--cc=matthew.gerlach@linux.intel.com \
--cc=netdev@vger.kernel.org \
--cc=nico@fluxnic.net \
--cc=pierre-louis.bossart@linux.intel.com \
--cc=raghavendrax.anand.khadatare@intel.com \
--cc=richardcochran@gmail.com \
--cc=russell.h.weight@intel.com \
--cc=tianfei.zhang@intel.com \
--cc=vinicius.gomes@intel.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;
as well as URLs for NNTP newsgroup(s).