linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] spi: <linux/spi/spi.h>: add missing struct kernel-doc entry
@ 2021-06-28  0:40 Randy Dunlap
  2021-06-28  7:05 ` Lukas Wunner
  0 siblings, 1 reply; 3+ messages in thread
From: Randy Dunlap @ 2021-06-28  0:40 UTC (permalink / raw)
  To: linux-kernel
  Cc: Randy Dunlap, William A . Kennington III, Mark Brown, linux-spi

Fix kernel-doc warning in spi.h:

../include/linux/spi/spi.h:673: warning: Function parameter or member 'devm_allocated' not described in 'spi_controller'

Fixes: 794aaf01444d ("spi: Fix use-after-free with devm_spi_alloc_*")
Signed-off-by: Randy Dunlap <rdunlap@infradead.org>
Cc: William A. Kennington III <wak@google.com>
Cc: Mark Brown <broonie@kernel.org>
Cc: linux-spi@vger.kernel.org
---
 include/linux/spi/spi.h |    1 +
 1 file changed, 1 insertion(+)

--- linux-next-20210625.orig/include/linux/spi/spi.h
+++ linux-next-20210625/include/linux/spi/spi.h
@@ -339,6 +339,7 @@ extern struct spi_device *spi_new_ancill
  * @max_speed_hz: Highest supported transfer speed
  * @flags: other constraints relevant to this driver
  * @slave: indicates that this is an SPI slave controller
+ * @devm_allocated: flag indicating this is a non-devres managed controller
  * @max_transfer_size: function that returns the max transfer size for
  *	a &spi_device; may be %NULL, so the default %SIZE_MAX will be used.
  * @max_message_size: function that returns the max message size for

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH] spi: <linux/spi/spi.h>: add missing struct kernel-doc entry
  2021-06-28  0:40 [PATCH] spi: <linux/spi/spi.h>: add missing struct kernel-doc entry Randy Dunlap
@ 2021-06-28  7:05 ` Lukas Wunner
  2021-06-28 16:56   ` Randy Dunlap
  0 siblings, 1 reply; 3+ messages in thread
From: Lukas Wunner @ 2021-06-28  7:05 UTC (permalink / raw)
  To: Randy Dunlap
  Cc: linux-kernel, William A . Kennington III, Mark Brown, linux-spi

On Sun, Jun 27, 2021 at 05:40:23PM -0700, Randy Dunlap wrote:
> --- linux-next-20210625.orig/include/linux/spi/spi.h
> +++ linux-next-20210625/include/linux/spi/spi.h
> @@ -339,6 +339,7 @@ extern struct spi_device *spi_new_ancill
>   * @max_speed_hz: Highest supported transfer speed
>   * @flags: other constraints relevant to this driver
>   * @slave: indicates that this is an SPI slave controller
> + * @devm_allocated: flag indicating this is a non-devres managed controller

Actually the flag indicates that the *allocation* of the controller *is*
devres-managed, so instead of the above I'd suggest something along the
lines of:

 * @devm_allocated: whether allocation of this struct is devres-managed

Thanks,

Lukas

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH] spi: <linux/spi/spi.h>: add missing struct kernel-doc entry
  2021-06-28  7:05 ` Lukas Wunner
@ 2021-06-28 16:56   ` Randy Dunlap
  0 siblings, 0 replies; 3+ messages in thread
From: Randy Dunlap @ 2021-06-28 16:56 UTC (permalink / raw)
  To: Lukas Wunner
  Cc: linux-kernel, William A . Kennington III, Mark Brown, linux-spi

On 6/28/21 12:05 AM, Lukas Wunner wrote:
> On Sun, Jun 27, 2021 at 05:40:23PM -0700, Randy Dunlap wrote:
>> --- linux-next-20210625.orig/include/linux/spi/spi.h
>> +++ linux-next-20210625/include/linux/spi/spi.h
>> @@ -339,6 +339,7 @@ extern struct spi_device *spi_new_ancill
>>   * @max_speed_hz: Highest supported transfer speed
>>   * @flags: other constraints relevant to this driver
>>   * @slave: indicates that this is an SPI slave controller
>> + * @devm_allocated: flag indicating this is a non-devres managed controller
> 
> Actually the flag indicates that the *allocation* of the controller *is*
> devres-managed, so instead of the above I'd suggest something along the
> lines of:
> 
>  * @devm_allocated: whether allocation of this struct is devres-managed
> 
> Thanks,

Hi Lukas,

OK, I'll change it like that.
I had just copied a comment from below in that same file.
I think that I should fix that comment as well.

Thanks.

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2021-06-28 16:57 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-06-28  0:40 [PATCH] spi: <linux/spi/spi.h>: add missing struct kernel-doc entry Randy Dunlap
2021-06-28  7:05 ` Lukas Wunner
2021-06-28 16:56   ` Randy Dunlap

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).