linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH][RESPIN] Staging: fsl-mc: include: mc: Kernel type 'int' preferred over 's16'
@ 2016-11-15  8:30 Shiva Kerdel
  2016-11-15 10:02 ` Greg KH
  0 siblings, 1 reply; 2+ messages in thread
From: Shiva Kerdel @ 2016-11-15  8:30 UTC (permalink / raw)
  To: stuart.yoder
  Cc: gregkh, German.Rivera, treding, itai.katz, linux-kernel, devel,
	Shiva Kerdel

After following a discussion about the used integer types Dan Carpenter
pointed out that 'int' types should be used over the current change to
's16'. The reason for this is to have an upper bound instead of overflowing
the 's16' so we could still remove devices.

Signed-off-by: Shiva Kerdel <shiva@exdev.nl>
Suggested-by: Stuart Yoder <stuart.yoder@nxp.com>
Suggested-by: Dan Carpenter <dan.carpenter@oracle.com>
---
 drivers/staging/fsl-mc/include/mc-bus.h | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/staging/fsl-mc/include/mc-bus.h b/drivers/staging/fsl-mc/include/mc-bus.h
index c7cad87..42700de 100644
--- a/drivers/staging/fsl-mc/include/mc-bus.h
+++ b/drivers/staging/fsl-mc/include/mc-bus.h
@@ -42,8 +42,8 @@ struct msi_domain_info;
  */
 struct fsl_mc_resource_pool {
 	enum fsl_mc_pool_type type;
-	s16 max_count;
-	s16 free_count;
+	int max_count;
+	int free_count;
 	struct mutex mutex;	/* serializes access to free_list */
 	struct list_head free_list;
 	struct fsl_mc_bus *mc_bus;
-- 
2.10.2

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

* Re: [PATCH][RESPIN] Staging: fsl-mc: include: mc: Kernel type 'int' preferred over 's16'
  2016-11-15  8:30 [PATCH][RESPIN] Staging: fsl-mc: include: mc: Kernel type 'int' preferred over 's16' Shiva Kerdel
@ 2016-11-15 10:02 ` Greg KH
  0 siblings, 0 replies; 2+ messages in thread
From: Greg KH @ 2016-11-15 10:02 UTC (permalink / raw)
  To: Shiva Kerdel
  Cc: stuart.yoder, German.Rivera, treding, itai.katz, linux-kernel,
	devel

On Tue, Nov 15, 2016 at 09:30:03AM +0100, Shiva Kerdel wrote:
> After following a discussion about the used integer types Dan Carpenter
> pointed out that 'int' types should be used over the current change to
> 's16'. The reason for this is to have an upper bound instead of overflowing
> the 's16' so we could still remove devices.
> 
> Signed-off-by: Shiva Kerdel <shiva@exdev.nl>
> Suggested-by: Stuart Yoder <stuart.yoder@nxp.com>
> Suggested-by: Dan Carpenter <dan.carpenter@oracle.com>
> ---
>  drivers/staging/fsl-mc/include/mc-bus.h | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)

In the future, don't do [RESPIN] as that means nothing to me, and is
just noise...

thanks,

greg k-h

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

end of thread, other threads:[~2016-11-15 10:02 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-11-15  8:30 [PATCH][RESPIN] Staging: fsl-mc: include: mc: Kernel type 'int' preferred over 's16' Shiva Kerdel
2016-11-15 10:02 ` Greg KH

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