Re: [PATCH 1/3] staging: most: core.c: move static specifier into MOST_INST_ATTR

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, Jul 27, 2015 at 10:31:08AM +0900, Chaehyun Lim wrote:
> Move static specifier into MOST_INST_ATTR to fix checkpatch error.
> ERROR: Macros with complex values should be enclosed in parentheses
> 
> Signed-off-by: Chaehyun Lim <chaehyun.lim@xxxxxxxxx>
> ---
>  drivers/staging/most/mostcore/core.c | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/drivers/staging/most/mostcore/core.c b/drivers/staging/most/mostcore/core.c
> index f4f9034..192b53d 100644
> --- a/drivers/staging/most/mostcore/core.c
> +++ b/drivers/staging/most/mostcore/core.c
> @@ -572,7 +572,7 @@ static void destroy_most_c_obj(struct most_c_obj *c)
>   *		     ___I N S T A N C E___
>   */
>  #define MOST_INST_ATTR(_name, _mode, _show, _store) \
> -		struct most_inst_attribute most_inst_attr_##_name = \
> +		static struct most_inst_attribute most_inst_attr_##_name = \
>  		__ATTR(_name, _mode, _show, _store)

That's a really odd change, you aren't "fixing" anything here by making
it.  checkpatch is just wrong here.

>  static struct list_head instance_list;
> @@ -696,7 +696,7 @@ static ssize_t show_interface(struct most_inst_obj *instance_obj,
>  }
>  
>  #define create_inst_attribute(value) \
> -	static MOST_INST_ATTR(value, S_IRUGO, show_##value, NULL)
> +	MOST_INST_ATTR(value, S_IRUGO, show_##value, NULL)

See, you didn't really "fix" anything, just moved the word around, not
good.

I can't take this, sorry.

greg k-h
_______________________________________________
devel mailing list
devel@xxxxxxxxxxxxxxxxxxxxxx
http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel



[Index of Archives]     [Linux Driver Backports]     [DMA Engine]     [Linux GPIO]     [Linux SPI]     [Video for Linux]     [Linux USB Devel]     [Linux Coverity]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Yosemite Backpacking]
  Powered by Linux