openbmc.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
From: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
To: Iwona Winiarska <iwona.winiarska@intel.com>
Cc: linux-aspeed@lists.ozlabs.org, linux-doc@vger.kernel.org,
	Dave Hansen <dave.hansen@intel.com>,
	Zev Weiss <zweiss@equinix.com>,
	Jae Hyun Yoo <jae.hyun.yoo@linux.intel.com>,
	Jonathan Corbet <corbet@lwn.net>,
	openbmc@lists.ozlabs.org,
	Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>,
	Guenter Roeck <linux@roeck-us.net>,
	devicetree@vger.kernel.org, Jean Delvare <jdelvare@suse.com>,
	Arnd Bergmann <arnd@arndb.de>, Rob Herring <robh+dt@kernel.org>,
	Borislav Petkov <bp@alien8.de>,
	Dan Williams <dan.j.williams@intel.com>,
	Andy Shevchenko <andriy.shevchenko@linux.intel.com>,
	linux-arm-kernel@lists.infradead.org,
	linux-hwmon@vger.kernel.org, Tony Luck <tony.luck@intel.com>,
	Andrew Jeffery <andrew@aj.id.au>,
	Randy Dunlap <rdunlap@infradead.org>,
	linux-kernel@vger.kernel.org, Olof Johansson <olof@lixom.net>
Subject: Re: [PATCH v3 06/13] peci: Add device detection
Date: Mon, 15 Nov 2021 19:49:57 +0100	[thread overview]
Message-ID: <YZKr1Rqfx6Cmw+Ok@kroah.com> (raw)
In-Reply-To: <20211115182552.3830849-7-iwona.winiarska@intel.com>

On Mon, Nov 15, 2021 at 07:25:45PM +0100, Iwona Winiarska wrote:
> +void peci_device_destroy(struct peci_device *device)
> +{
> +	bool killed;
> +
> +	device_lock(&device->dev);
> +	killed = kill_device(&device->dev);

Eeek, why call this?

> +	device_unlock(&device->dev);
> +
> +	if (!killed)
> +		return;

What happened if something changed after you unlocked it?

Why is kill_device() required at all?  That's a very rare function to
call, and one that only one "bus" calls today because it is very
special (i.e. crazy and broken...)

thanks,

greg k-h

  reply	other threads:[~2021-11-15 19:11 UTC|newest]

Thread overview: 24+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-11-15 18:25 [PATCH v3 00/13] Introduce PECI subsystem Iwona Winiarska
2021-11-15 18:25 ` [PATCH v3 01/13] dt-bindings: Add generic bindings for PECI Iwona Winiarska
2021-11-15 18:25 ` [PATCH v3 02/13] dt-bindings: Add bindings for peci-aspeed Iwona Winiarska
2021-11-15 18:25 ` [PATCH v3 03/13] ARM: dts: aspeed: Add PECI controller nodes Iwona Winiarska
2021-11-15 18:25 ` [PATCH v3 04/13] peci: Add core infrastructure Iwona Winiarska
2021-11-15 18:25 ` [PATCH v3 05/13] peci: Add peci-aspeed controller driver Iwona Winiarska
2021-11-15 18:25 ` [PATCH v3 06/13] peci: Add device detection Iwona Winiarska
2021-11-15 18:49   ` Greg Kroah-Hartman [this message]
2021-11-15 22:35     ` Winiarska, Iwona
2021-11-16  6:26       ` gregkh
2021-11-17 23:19         ` Winiarska, Iwona
2021-11-15 18:25 ` [PATCH v3 07/13] peci: Add sysfs interface for PECI bus Iwona Winiarska
2021-11-15 18:25 ` [PATCH v3 08/13] peci: Add support for PECI device drivers Iwona Winiarska
2021-11-15 18:25 ` [PATCH v3 09/13] peci: Add peci-cpu driver Iwona Winiarska
2021-11-15 18:25 ` [PATCH v3 10/13] hwmon: peci: Add cputemp driver Iwona Winiarska
2021-11-16  0:52   ` Guenter Roeck
2021-11-17 22:20     ` Winiarska, Iwona
2021-11-15 18:25 ` [PATCH v3 11/13] hwmon: peci: Add dimmtemp driver Iwona Winiarska
2021-11-15 18:25 ` [PATCH v3 12/13] docs: hwmon: Document PECI drivers Iwona Winiarska
2021-11-15 18:25 ` [PATCH v3 13/13] docs: Add PECI documentation Iwona Winiarska
2021-11-17  3:56 ` [PATCH v3 00/13] Introduce PECI subsystem Zev Weiss
2021-11-17 23:25   ` Winiarska, Iwona
2021-11-18 12:19 ` Tomer Maimon
2021-11-18 21:51   ` Winiarska, Iwona

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=YZKr1Rqfx6Cmw+Ok@kroah.com \
    --to=gregkh@linuxfoundation.org \
    --cc=andrew@aj.id.au \
    --cc=andriy.shevchenko@linux.intel.com \
    --cc=arnd@arndb.de \
    --cc=bp@alien8.de \
    --cc=corbet@lwn.net \
    --cc=dan.j.williams@intel.com \
    --cc=dave.hansen@intel.com \
    --cc=devicetree@vger.kernel.org \
    --cc=iwona.winiarska@intel.com \
    --cc=jae.hyun.yoo@linux.intel.com \
    --cc=jdelvare@suse.com \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-aspeed@lists.ozlabs.org \
    --cc=linux-doc@vger.kernel.org \
    --cc=linux-hwmon@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux@roeck-us.net \
    --cc=olof@lixom.net \
    --cc=openbmc@lists.ozlabs.org \
    --cc=pierre-louis.bossart@linux.intel.com \
    --cc=rdunlap@infradead.org \
    --cc=robh+dt@kernel.org \
    --cc=tony.luck@intel.com \
    --cc=zweiss@equinix.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).