linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 1/2] tsl2x7x_core: remove paragraph about writing to the FSF's mailing address
@ 2017-05-04 20:38 Enric Balletbo i Serra
  2017-05-04 20:38 ` [PATCH 2/2] tsl2x7x_core: use octal permission representation Enric Balletbo i Serra
  2017-05-07 12:51 ` [PATCH 1/2] tsl2x7x_core: remove paragraph about writing to the FSF's mailing address Jonathan Cameron
  0 siblings, 2 replies; 4+ messages in thread
From: Enric Balletbo i Serra @ 2017-05-04 20:38 UTC (permalink / raw)
  To: Jonathan Cameron; +Cc: linux-iio, devel, linux-kernel, Enric Balletbo i Serra

Do not include the paragraph about writing to the Free Software
Foundation's mailing address from the sample GPL notice. The FSF
has changed addresses in the past, and may do so again. Linux
already includes a copy of the GPL.

Signed-off-by: Enric Balletbo i Serra <eballetbo@gmail.com>
---
 drivers/staging/iio/light/tsl2x7x_core.c | 4 ----
 1 file changed, 4 deletions(-)

diff --git a/drivers/staging/iio/light/tsl2x7x_core.c b/drivers/staging/iio/light/tsl2x7x_core.c
index ea15bc1c300c..b35ff63f7f60 100644
--- a/drivers/staging/iio/light/tsl2x7x_core.c
+++ b/drivers/staging/iio/light/tsl2x7x_core.c
@@ -13,10 +13,6 @@
  * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
  * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License for
  * more details.
- *
- * You should have received a copy of the GNU General Public License along
- * with this program; if not, write to the Free Software Foundation, Inc.,
- * 51 Franklin Street, Fifth Floor, Boston, MA        02110-1301, USA.
  */
 
 #include <linux/kernel.h>
-- 
2.11.0

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

* [PATCH 2/2] tsl2x7x_core: use octal permission representation
  2017-05-04 20:38 [PATCH 1/2] tsl2x7x_core: remove paragraph about writing to the FSF's mailing address Enric Balletbo i Serra
@ 2017-05-04 20:38 ` Enric Balletbo i Serra
  2017-05-07 12:55   ` Jonathan Cameron
  2017-05-07 12:51 ` [PATCH 1/2] tsl2x7x_core: remove paragraph about writing to the FSF's mailing address Jonathan Cameron
  1 sibling, 1 reply; 4+ messages in thread
From: Enric Balletbo i Serra @ 2017-05-04 20:38 UTC (permalink / raw)
  To: Jonathan Cameron; +Cc: linux-iio, devel, linux-kernel, Enric Balletbo i Serra

Fix the output from checkpatch.pl like:
  Symbolic permissions 'S_IRUSR' are not preferred.
  Consider using octal permissions '0400'.

Also fix the alignment DEVICE_ATTR variables as should match open
parenthesis.

Signed-off-by: Enric Balletbo i Serra <eballetbo@gmail.com>
---
 drivers/staging/iio/light/tsl2x7x_core.c | 42 +++++++++++++++++---------------
 1 file changed, 22 insertions(+), 20 deletions(-)

diff --git a/drivers/staging/iio/light/tsl2x7x_core.c b/drivers/staging/iio/light/tsl2x7x_core.c
index b35ff63f7f60..41b8f5332737 100644
--- a/drivers/staging/iio/light/tsl2x7x_core.c
+++ b/drivers/staging/iio/light/tsl2x7x_core.c
@@ -1494,35 +1494,37 @@ static int tsl2x7x_write_raw(struct iio_dev *indio_dev,
 	return 0;
 }
 
-static DEVICE_ATTR(power_state, S_IRUGO | S_IWUSR,
-		tsl2x7x_power_state_show, tsl2x7x_power_state_store);
+static DEVICE_ATTR(power_state, 0644, tsl2x7x_power_state_show,
+		   tsl2x7x_power_state_store);
 
-static DEVICE_ATTR(in_proximity0_calibscale_available, S_IRUGO,
-		tsl2x7x_prox_gain_available_show, NULL);
+static DEVICE_ATTR(in_proximity0_calibscale_available, 0444,
+		   tsl2x7x_prox_gain_available_show, NULL);
 
-static DEVICE_ATTR(in_illuminance0_calibscale_available, S_IRUGO,
-		tsl2x7x_gain_available_show, NULL);
+static DEVICE_ATTR(in_illuminance0_calibscale_available, 0444,
+		   tsl2x7x_gain_available_show, NULL);
 
-static DEVICE_ATTR(in_illuminance0_integration_time, S_IRUGO | S_IWUSR,
-		tsl2x7x_als_time_show, tsl2x7x_als_time_store);
+static DEVICE_ATTR(in_illuminance0_integration_time, 0644,
+		   tsl2x7x_als_time_show, tsl2x7x_als_time_store);
 
-static DEVICE_ATTR(in_illuminance0_target_input, S_IRUGO | S_IWUSR,
-		tsl2x7x_als_cal_target_show, tsl2x7x_als_cal_target_store);
+static DEVICE_ATTR(in_illuminance0_target_input, 0644,
+		   tsl2x7x_als_cal_target_show, tsl2x7x_als_cal_target_store);
 
-static DEVICE_ATTR(in_illuminance0_calibrate, S_IWUSR, NULL,
-		tsl2x7x_do_calibrate);
+static DEVICE_ATTR(in_illuminance0_calibrate, 0200, NULL,
+		   tsl2x7x_do_calibrate);
 
-static DEVICE_ATTR(in_proximity0_calibrate, S_IWUSR, NULL,
-		tsl2x7x_do_prox_calibrate);
+static DEVICE_ATTR(in_proximity0_calibrate, 0200, NULL,
+		   tsl2x7x_do_prox_calibrate);
 
-static DEVICE_ATTR(in_illuminance0_lux_table, S_IRUGO | S_IWUSR,
-		tsl2x7x_luxtable_show, tsl2x7x_luxtable_store);
+static DEVICE_ATTR(in_illuminance0_lux_table, 0644, tsl2x7x_luxtable_show,
+		   tsl2x7x_luxtable_store);
 
-static DEVICE_ATTR(in_intensity0_thresh_period, S_IRUGO | S_IWUSR,
-		tsl2x7x_als_persistence_show, tsl2x7x_als_persistence_store);
+static DEVICE_ATTR(in_intensity0_thresh_period, 0644,
+		   tsl2x7x_als_persistence_show,
+		   tsl2x7x_als_persistence_store);
 
-static DEVICE_ATTR(in_proximity0_thresh_period, S_IRUGO | S_IWUSR,
-		tsl2x7x_prox_persistence_show, tsl2x7x_prox_persistence_store);
+static DEVICE_ATTR(in_proximity0_thresh_period, 0644,
+		   tsl2x7x_prox_persistence_show,
+		   tsl2x7x_prox_persistence_store);
 
 /* Use the default register values to identify the Taos device */
 static int tsl2x7x_device_id(unsigned char *id, int target)
-- 
2.11.0

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

* Re: [PATCH 1/2] tsl2x7x_core: remove paragraph about writing to the FSF's mailing address
  2017-05-04 20:38 [PATCH 1/2] tsl2x7x_core: remove paragraph about writing to the FSF's mailing address Enric Balletbo i Serra
  2017-05-04 20:38 ` [PATCH 2/2] tsl2x7x_core: use octal permission representation Enric Balletbo i Serra
@ 2017-05-07 12:51 ` Jonathan Cameron
  1 sibling, 0 replies; 4+ messages in thread
From: Jonathan Cameron @ 2017-05-07 12:51 UTC (permalink / raw)
  To: Enric Balletbo i Serra; +Cc: linux-iio, devel, linux-kernel, Brian Masney

On 04/05/17 21:38, Enric Balletbo i Serra wrote:
> Do not include the paragraph about writing to the Free Software
> Foundation's mailing address from the sample GPL notice. The FSF
> has changed addresses in the past, and may do so again. Linux
> already includes a copy of the GPL.
> 
> Signed-off-by: Enric Balletbo i Serra <eballetbo@gmail.com>
Applied to the togreg branch of iio.git and pushed out as testing
for the autobuilders to play with it.

I dealt with the fact this crossed with a file rename patch and
the file is now called tsl2x7x.c

Jonathan
> ---
>  drivers/staging/iio/light/tsl2x7x_core.c | 4 ----
>  1 file changed, 4 deletions(-)
> 
> diff --git a/drivers/staging/iio/light/tsl2x7x_core.c b/drivers/staging/iio/light/tsl2x7x_core.c
> index ea15bc1c300c..b35ff63f7f60 100644
> --- a/drivers/staging/iio/light/tsl2x7x_core.c
> +++ b/drivers/staging/iio/light/tsl2x7x_core.c
> @@ -13,10 +13,6 @@
>   * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
>   * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License for
>   * more details.
> - *
> - * You should have received a copy of the GNU General Public License along
> - * with this program; if not, write to the Free Software Foundation, Inc.,
> - * 51 Franklin Street, Fifth Floor, Boston, MA        02110-1301, USA.
>   */
>  
>  #include <linux/kernel.h>
> 

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

* Re: [PATCH 2/2] tsl2x7x_core: use octal permission representation
  2017-05-04 20:38 ` [PATCH 2/2] tsl2x7x_core: use octal permission representation Enric Balletbo i Serra
@ 2017-05-07 12:55   ` Jonathan Cameron
  0 siblings, 0 replies; 4+ messages in thread
From: Jonathan Cameron @ 2017-05-07 12:55 UTC (permalink / raw)
  To: Enric Balletbo i Serra; +Cc: linux-iio, devel, linux-kernel

On 04/05/17 21:38, Enric Balletbo i Serra wrote:
> Fix the output from checkpatch.pl like:
>   Symbolic permissions 'S_IRUSR' are not preferred.
>   Consider using octal permissions '0400'.
> 
> Also fix the alignment DEVICE_ATTR variables as should match open
> parenthesis.
> 
> Signed-off-by: Enric Balletbo i Serra <eballetbo@gmail.com>
I already have a patch in place doing this from a couple of weeks ago
(Paulo Cretaro - April 25th)

Thanks

Jonathan
> ---
>  drivers/staging/iio/light/tsl2x7x_core.c | 42 +++++++++++++++++---------------
>  1 file changed, 22 insertions(+), 20 deletions(-)
> 
> diff --git a/drivers/staging/iio/light/tsl2x7x_core.c b/drivers/staging/iio/light/tsl2x7x_core.c
> index b35ff63f7f60..41b8f5332737 100644
> --- a/drivers/staging/iio/light/tsl2x7x_core.c
> +++ b/drivers/staging/iio/light/tsl2x7x_core.c
> @@ -1494,35 +1494,37 @@ static int tsl2x7x_write_raw(struct iio_dev *indio_dev,
>  	return 0;
>  }
>  
> -static DEVICE_ATTR(power_state, S_IRUGO | S_IWUSR,
> -		tsl2x7x_power_state_show, tsl2x7x_power_state_store);
> +static DEVICE_ATTR(power_state, 0644, tsl2x7x_power_state_show,
> +		   tsl2x7x_power_state_store);
>  
> -static DEVICE_ATTR(in_proximity0_calibscale_available, S_IRUGO,
> -		tsl2x7x_prox_gain_available_show, NULL);
> +static DEVICE_ATTR(in_proximity0_calibscale_available, 0444,
> +		   tsl2x7x_prox_gain_available_show, NULL);
>  
> -static DEVICE_ATTR(in_illuminance0_calibscale_available, S_IRUGO,
> -		tsl2x7x_gain_available_show, NULL);
> +static DEVICE_ATTR(in_illuminance0_calibscale_available, 0444,
> +		   tsl2x7x_gain_available_show, NULL);
>  
> -static DEVICE_ATTR(in_illuminance0_integration_time, S_IRUGO | S_IWUSR,
> -		tsl2x7x_als_time_show, tsl2x7x_als_time_store);
> +static DEVICE_ATTR(in_illuminance0_integration_time, 0644,
> +		   tsl2x7x_als_time_show, tsl2x7x_als_time_store);
>  
> -static DEVICE_ATTR(in_illuminance0_target_input, S_IRUGO | S_IWUSR,
> -		tsl2x7x_als_cal_target_show, tsl2x7x_als_cal_target_store);
> +static DEVICE_ATTR(in_illuminance0_target_input, 0644,
> +		   tsl2x7x_als_cal_target_show, tsl2x7x_als_cal_target_store);
>  
> -static DEVICE_ATTR(in_illuminance0_calibrate, S_IWUSR, NULL,
> -		tsl2x7x_do_calibrate);
> +static DEVICE_ATTR(in_illuminance0_calibrate, 0200, NULL,
> +		   tsl2x7x_do_calibrate);
>  
> -static DEVICE_ATTR(in_proximity0_calibrate, S_IWUSR, NULL,
> -		tsl2x7x_do_prox_calibrate);
> +static DEVICE_ATTR(in_proximity0_calibrate, 0200, NULL,
> +		   tsl2x7x_do_prox_calibrate);
>  
> -static DEVICE_ATTR(in_illuminance0_lux_table, S_IRUGO | S_IWUSR,
> -		tsl2x7x_luxtable_show, tsl2x7x_luxtable_store);
> +static DEVICE_ATTR(in_illuminance0_lux_table, 0644, tsl2x7x_luxtable_show,
> +		   tsl2x7x_luxtable_store);
>  
> -static DEVICE_ATTR(in_intensity0_thresh_period, S_IRUGO | S_IWUSR,
> -		tsl2x7x_als_persistence_show, tsl2x7x_als_persistence_store);
> +static DEVICE_ATTR(in_intensity0_thresh_period, 0644,
> +		   tsl2x7x_als_persistence_show,
> +		   tsl2x7x_als_persistence_store);
>  
> -static DEVICE_ATTR(in_proximity0_thresh_period, S_IRUGO | S_IWUSR,
> -		tsl2x7x_prox_persistence_show, tsl2x7x_prox_persistence_store);
> +static DEVICE_ATTR(in_proximity0_thresh_period, 0644,
> +		   tsl2x7x_prox_persistence_show,
> +		   tsl2x7x_prox_persistence_store);
>  
>  /* Use the default register values to identify the Taos device */
>  static int tsl2x7x_device_id(unsigned char *id, int target)
> 

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

end of thread, other threads:[~2017-05-07 22:21 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-05-04 20:38 [PATCH 1/2] tsl2x7x_core: remove paragraph about writing to the FSF's mailing address Enric Balletbo i Serra
2017-05-04 20:38 ` [PATCH 2/2] tsl2x7x_core: use octal permission representation Enric Balletbo i Serra
2017-05-07 12:55   ` Jonathan Cameron
2017-05-07 12:51 ` [PATCH 1/2] tsl2x7x_core: remove paragraph about writing to the FSF's mailing address Jonathan Cameron

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