linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] staging: mt7621-pinctrl: Replaces "unsigned" with "unsigned int", fixes mixed indentation, and puts spaces after commas.
@ 2018-06-30 17:17 Peter Vernia
  2018-06-30 19:32 ` Dan Carpenter
  0 siblings, 1 reply; 3+ messages in thread
From: Peter Vernia @ 2018-06-30 17:17 UTC (permalink / raw)
  Cc: Peter Vernia, Greg Kroah-Hartman, Kees Cook,
	Christian Lütke-Stetzkamp, John Crispin, devel,
	linux-kernel

Signed-off-by: Peter Vernia <peter.vernia@gmail.com>
---
 drivers/staging/mt7621-pinctrl/pinctrl-rt2880.c | 35 +++++++++++++------------
 1 file changed, 18 insertions(+), 17 deletions(-)

diff --git a/drivers/staging/mt7621-pinctrl/pinctrl-rt2880.c b/drivers/staging/mt7621-pinctrl/pinctrl-rt2880.c
index 0c3e498..6894510 100644
--- a/drivers/staging/mt7621-pinctrl/pinctrl-rt2880.c
+++ b/drivers/staging/mt7621-pinctrl/pinctrl-rt2880.c
@@ -54,7 +54,7 @@ static int rt2880_get_group_count(struct pinctrl_dev *pctrldev)
 }
 
 static const char *rt2880_get_group_name(struct pinctrl_dev *pctrldev,
-					 unsigned group)
+					 unsigned int group)
 {
 	struct rt2880_priv *p = pinctrl_dev_get_drvdata(pctrldev);
 
@@ -65,9 +65,9 @@ static const char *rt2880_get_group_name(struct pinctrl_dev *pctrldev,
 }
 
 static int rt2880_get_group_pins(struct pinctrl_dev *pctrldev,
-				 unsigned group,
-				 const unsigned **pins,
-				 unsigned *num_pins)
+				 unsigned int group,
+				 const unsigned int **pins,
+				 unsigned int *num_pins)
 {
 	struct rt2880_priv *p = pinctrl_dev_get_drvdata(pctrldev);
 
@@ -81,7 +81,8 @@ static int rt2880_get_group_pins(struct pinctrl_dev *pctrldev,
 }
 
 static void rt2880_pinctrl_dt_free_map(struct pinctrl_dev *pctrldev,
-				    struct pinctrl_map *map, unsigned num_maps)
+				    struct pinctrl_map *map,
+				    unsigned int num_maps)
 {
 	int i;
 
@@ -94,7 +95,7 @@ static void rt2880_pinctrl_dt_free_map(struct pinctrl_dev *pctrldev,
 
 static void rt2880_pinctrl_pin_dbg_show(struct pinctrl_dev *pctrldev,
 					struct seq_file *s,
-					unsigned offset)
+					unsigned int offset)
 {
 	seq_printf(s, "ralink pio");
 }
@@ -103,7 +104,7 @@ static void rt2880_pinctrl_dt_subnode_to_map(struct pinctrl_dev *pctrldev,
 				struct device_node *np,
 				struct pinctrl_map **map)
 {
-        const char *function;
+	const char *function;
 	int func = of_property_read_string(np, "ralink,function", &function);
 	int grps = of_property_count_strings(np, "ralink,group");
 	int i;
@@ -112,7 +113,7 @@ static void rt2880_pinctrl_dt_subnode_to_map(struct pinctrl_dev *pctrldev,
 		return;
 
 	for (i = 0; i < grps; i++) {
-	        const char *group;
+		const char *group;
 
 		of_property_read_string_index(np, "ralink,group", i, &group);
 
@@ -127,7 +128,7 @@ static void rt2880_pinctrl_dt_subnode_to_map(struct pinctrl_dev *pctrldev,
 static int rt2880_pinctrl_dt_node_to_map(struct pinctrl_dev *pctrldev,
 				struct device_node *np_config,
 				struct pinctrl_map **map,
-				unsigned *num_maps)
+				unsigned int *num_maps)
 {
 	int max_maps = 0;
 	struct pinctrl_map *tmp;
@@ -173,7 +174,7 @@ static int rt2880_pmx_func_count(struct pinctrl_dev *pctrldev)
 }
 
 static const char *rt2880_pmx_func_name(struct pinctrl_dev *pctrldev,
-					 unsigned func)
+					 unsigned int func)
 {
 	struct rt2880_priv *p = pinctrl_dev_get_drvdata(pctrldev);
 
@@ -181,7 +182,7 @@ static const char *rt2880_pmx_func_name(struct pinctrl_dev *pctrldev,
 }
 
 static int rt2880_pmx_group_get_groups(struct pinctrl_dev *pctrldev,
-				unsigned func,
+				unsigned int func,
 				const char * const **groups,
 				unsigned * const num_groups)
 {
@@ -198,11 +199,11 @@ static int rt2880_pmx_group_get_groups(struct pinctrl_dev *pctrldev,
 }
 
 static int rt2880_pmx_group_enable(struct pinctrl_dev *pctrldev,
-				unsigned func,
-				unsigned group)
+				unsigned int func,
+				unsigned int group)
 {
 	struct rt2880_priv *p = pinctrl_dev_get_drvdata(pctrldev);
-        u32 mode = 0;
+	u32 mode = 0;
 	u32 reg = SYSC_REG_GPIO_MODE;
 	int i;
 	int shift;
@@ -243,7 +244,7 @@ static int rt2880_pmx_group_enable(struct pinctrl_dev *pctrldev,
 
 static int rt2880_pmx_group_gpio_request_enable(struct pinctrl_dev *pctrldev,
 				struct pinctrl_gpio_range *range,
-				unsigned pin)
+				unsigned int pin)
 {
 	struct rt2880_priv *p = pinctrl_dev_get_drvdata(pctrldev);
 
@@ -355,13 +356,13 @@ static int rt2880_pinmux_pins(struct rt2880_priv *p)
 	}
 
 	/* the buffer that tells us which pins are gpio */
-	p->gpio = devm_kcalloc(p->dev,p->max_pins, sizeof(uint8_t),
+	p->gpio = devm_kcalloc(p->dev, p->max_pins, sizeof(uint8_t),
 			       GFP_KERNEL);
 	/* the pads needed to tell pinctrl about our pins */
 	p->pads = devm_kcalloc(p->dev,
 		p->max_pins, sizeof(struct pinctrl_pin_desc),
 		GFP_KERNEL);
-	if (!p->pads || !p->gpio ) {
+	if (!p->pads || !p->gpio) {
 		dev_err(p->dev, "Failed to allocate gpio data\n");
 		return -ENOMEM;
 	}
-- 
2.7.4


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

* Re: [PATCH] staging: mt7621-pinctrl: Replaces "unsigned" with "unsigned int", fixes mixed indentation, and puts spaces after commas.
  2018-06-30 17:17 [PATCH] staging: mt7621-pinctrl: Replaces "unsigned" with "unsigned int", fixes mixed indentation, and puts spaces after commas Peter Vernia
@ 2018-06-30 19:32 ` Dan Carpenter
  2018-07-03  5:08   ` Peter Vernia
  0 siblings, 1 reply; 3+ messages in thread
From: Dan Carpenter @ 2018-06-30 19:32 UTC (permalink / raw)
  To: Peter Vernia
  Cc: devel, Kees Cook, Greg Kroah-Hartman, linux-kernel,
	Christian Lütke-Stetzkamp, John Crispin

On Sat, Jun 30, 2018 at 01:17:29PM -0400, Peter Vernia wrote:
> Signed-off-by: Peter Vernia <peter.vernia@gmail.com>

The subject is over 72 characters or whatever the limit is and there
isn't a commit message.

regards,
dan carpenter


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

* Re: [PATCH] staging: mt7621-pinctrl: Replaces "unsigned" with "unsigned int", fixes mixed indentation, and puts spaces after commas.
  2018-06-30 19:32 ` Dan Carpenter
@ 2018-07-03  5:08   ` Peter Vernia
  0 siblings, 0 replies; 3+ messages in thread
From: Peter Vernia @ 2018-07-03  5:08 UTC (permalink / raw)
  To: Dan Carpenter
  Cc: devel, Kees Cook, Greg Kroah-Hartman, linux-kernel,
	Christian Lütke-Stetzkamp, John Crispin

 
> The subject is over 72 characters or whatever the limit is and there
> isn't a commit message.

Dan, thanks for your help, I realize where I went wrong now. I will re-submit
the patch fresh to fix the message subject.

--Peter 

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

end of thread, other threads:[~2018-07-03  5:08 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-06-30 17:17 [PATCH] staging: mt7621-pinctrl: Replaces "unsigned" with "unsigned int", fixes mixed indentation, and puts spaces after commas Peter Vernia
2018-06-30 19:32 ` Dan Carpenter
2018-07-03  5:08   ` Peter Vernia

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