From: Richard Cochran <richardcochran@gmail.com>
To: "Ben Dooks (Codethink)" <ben.dooks@codethink.co.uk>
Cc: linux-kernel@lists.codethink.co.uk, netdev@vger.kernel.org,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH] ptp_pch: include ethernet driver for external functions
Date: Fri, 18 Oct 2019 04:41:16 -0700 [thread overview]
Message-ID: <20191018114116.GA1348@localhost> (raw)
In-Reply-To: <20191018105128.4382-1-ben.dooks@codethink.co.uk>
On Fri, Oct 18, 2019 at 11:51:28AM +0100, Ben Dooks (Codethink) wrote:
> The driver uses a number of functions from the ethernet driver
> so include the header to remove the following warnings from
> sparse about undeclared functions:
>
> drivers/ptp/ptp_pch.c:182:5: warning: symbol 'pch_ch_control_read' was not declared. Should it be static?
That one is never used and should be removed.
> drivers/ptp/ptp_pch.c:193:6: warning: symbol 'pch_ch_control_write' was not declared. Should it be static?
> drivers/ptp/ptp_pch.c:201:5: warning: symbol 'pch_ch_event_read' was not declared. Should it be static?
> drivers/ptp/ptp_pch.c:212:6: warning: symbol 'pch_ch_event_write' was not declared. Should it be static?
> drivers/ptp/ptp_pch.c:220:5: warning: symbol 'pch_src_uuid_lo_read' was not declared. Should it be static?
> drivers/ptp/ptp_pch.c:231:5: warning: symbol 'pch_src_uuid_hi_read' was not declared. Should it be static?
> drivers/ptp/ptp_pch.c:242:5: warning: symbol 'pch_rx_snap_read' was not declared. Should it be static?
> drivers/ptp/ptp_pch.c:259:5: warning: symbol 'pch_tx_snap_read' was not declared. Should it be static?
> drivers/ptp/ptp_pch.c:300:5: warning: symbol 'pch_set_station_address' was not declared. Should it be static?
> +#include <../net/ethernet/oki-semi/pch_gbe/pch_gbe.h>
Instead of that long relative path, just move ptp_pch.c out of
drivers/ptp and into drivers/net/ethernet/oki-semi/pch_gbe.
Then move the shared declarations out of pch_gbe.h and into a new
header file, included by both users with:
#include "ptp_pch.h"
Thanks,
Richard
prev parent reply other threads:[~2019-10-18 11:41 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-10-18 10:51 [PATCH] ptp_pch: include ethernet driver for external functions Ben Dooks (Codethink)
2019-10-18 10:56 ` Ben Dooks
2019-10-18 11:41 ` Richard Cochran [this message]
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=20191018114116.GA1348@localhost \
--to=richardcochran@gmail.com \
--cc=ben.dooks@codethink.co.uk \
--cc=linux-kernel@lists.codethink.co.uk \
--cc=linux-kernel@vger.kernel.org \
--cc=netdev@vger.kernel.org \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.