Skip to contentSkip to conversation

Staging: fsl-mc: include: mc: Kernel type 'int' preferred over 's16'

PATCH In review Shiva Kerdel 2 participants 2 messages Nov 15, 2016 Staging

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 Staging: fsl-mc: include: mc: Kernel type 'int' preferred over 's16'

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.

---
 drivers/staging/fsl-mc/include/mc-bus.h | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
drivers/staging/fsl-mc/include/mc-bus.h +2 -2
index c7cad87..42700de 100644
@@ -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;
Signature · 1 line
2.10.2
maintainer
#1 lore raw
Quoted 11 lines · 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.

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