linux-spi.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Suzuki K Poulose <suzuki.poulose@arm.com>
To: wsa@the-dreams.de
Cc: linux-kernel@vger.kernel.org, gregkh@linuxfoundation.org,
	rafael@kernel.org, atull@kernel.org, andrew@lunn.ch,
	daniel@ffwll.ch, airlied@linux.ie, davem@davemloft.net,
	devicetree@vger.kernel.org, dri-devel@lists.freedesktop.org,
	f.fainelli@gmail.com, frowand.list@gmail.com,
	hkallweit1@gmail.com, jslaby@suse.com, jonathanh@nvidia.com,
	lee.jones@linaro.org, lgirdwood@gmail.com,
	linux-fpga@vger.kernel.org, linux-i2c@vger.kernel.org,
	linux-spi@vger.kernel.org, maarten.lankhorst@linux.intel.com,
	broonie@kernel.org, mathieu.poirier@linaro.org,
	maxime.ripard@bootlin.com, mdf@kernel.org, peda@axentia.se,
	robh+dt@kernel.org, srinivas.kandagatla@linaro.org,
	thierry.reding@gmail.com, thor.thayer@linux.intel.com,
	ulf.hansson@linaro.org, joe@perches.com
Subject: Re: [PATCH v2 06/28] drivers: Add generic helper to match by of_node
Date: Mon, 17 Jun 2019 10:59:03 +0100	[thread overview]
Message-ID: <d050ae69-52ee-b32d-2bc0-708b408f3bd4@arm.com> (raw)
In-Reply-To: <20190614203144.GB7991@kunai>

Hi

On 14/06/2019 21:31, Wolfram Sang wrote:
>> +
>> +int device_match_of_node(struct device *dev, const void *np)
>> +{
>> +	return dev->of_node == np;
>> +}
>> +EXPORT_SYMBOL_GPL(device_match_of_node);
> 
> Is it an option to 'static inline' this simple function in the header,
> saving the EXPORT?
> 

No. This is supposed to be passed on as a call back function pointer
for the APIs. Having it as a static inline, would simply replicate
the same function through the driver subsystems, which is one of the
issues that series is trying to solve. Also, by having them exported,
we can convert the new specialized device lookup functions,
*_find_device_by_<property> to be static inlines.

Suzuki

  reply	other threads:[~2019-06-17  9:59 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-06-14 17:53 [PATCH v2 00/28] drivers: Consolidate device lookup helpers Suzuki K Poulose
2019-06-14 17:54 ` [PATCH v2 06/28] drivers: Add generic helper to match by of_node Suzuki K Poulose
2019-06-14 20:31   ` Wolfram Sang
2019-06-17  9:59     ` Suzuki K Poulose [this message]
2019-06-17 10:06       ` Wolfram Sang
2019-06-14 17:54 ` [PATCH v2 09/28] drivers: Add generic match helper by ACPI_COMPANION device Suzuki K Poulose
2019-06-17 22:07   ` Rafael J. Wysocki
2019-06-18  8:38     ` Suzuki K Poulose
2019-06-18  8:40       ` Rafael J. Wysocki
2019-06-14 17:54 ` [PATCH v2 17/28] drivers: Introduce bus_find_device_by_of_node() helper Suzuki K Poulose
2019-06-14 20:32   ` Wolfram Sang
2019-07-09 16:19   ` Rob Herring
2019-06-24  3:23 ` [PATCH v2 00/28] drivers: Consolidate device lookup helpers Greg KH

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=d050ae69-52ee-b32d-2bc0-708b408f3bd4@arm.com \
    --to=suzuki.poulose@arm.com \
    --cc=airlied@linux.ie \
    --cc=andrew@lunn.ch \
    --cc=atull@kernel.org \
    --cc=broonie@kernel.org \
    --cc=daniel@ffwll.ch \
    --cc=davem@davemloft.net \
    --cc=devicetree@vger.kernel.org \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=f.fainelli@gmail.com \
    --cc=frowand.list@gmail.com \
    --cc=gregkh@linuxfoundation.org \
    --cc=hkallweit1@gmail.com \
    --cc=joe@perches.com \
    --cc=jonathanh@nvidia.com \
    --cc=jslaby@suse.com \
    --cc=lee.jones@linaro.org \
    --cc=lgirdwood@gmail.com \
    --cc=linux-fpga@vger.kernel.org \
    --cc=linux-i2c@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-spi@vger.kernel.org \
    --cc=maarten.lankhorst@linux.intel.com \
    --cc=mathieu.poirier@linaro.org \
    --cc=maxime.ripard@bootlin.com \
    --cc=mdf@kernel.org \
    --cc=peda@axentia.se \
    --cc=rafael@kernel.org \
    --cc=robh+dt@kernel.org \
    --cc=srinivas.kandagatla@linaro.org \
    --cc=thierry.reding@gmail.com \
    --cc=thor.thayer@linux.intel.com \
    --cc=ulf.hansson@linaro.org \
    --cc=wsa@the-dreams.de \
    /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).