All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] media: cec: name for RC passthrough device does not need 'RC for'
@ 2018-10-04 22:21 Sean Young
  2018-10-05  7:37 ` Hans Verkuil
  0 siblings, 1 reply; 3+ messages in thread
From: Sean Young @ 2018-10-04 22:21 UTC (permalink / raw)
  To: Hans Verkuil, linux-media

An RC device is does not need to be called 'RC for'. Simply the name
will suffice.

Signed-off-by: Sean Young <sean@mess.org>
---
 drivers/media/cec/cec-core.c | 6 ++----
 include/media/cec.h          | 2 --
 2 files changed, 2 insertions(+), 6 deletions(-)

diff --git a/drivers/media/cec/cec-core.c b/drivers/media/cec/cec-core.c
index 74596f089ec9..e4edc930d4ed 100644
--- a/drivers/media/cec/cec-core.c
+++ b/drivers/media/cec/cec-core.c
@@ -307,12 +307,10 @@ struct cec_adapter *cec_allocate_adapter(const struct cec_adap_ops *ops,
 		return ERR_PTR(-ENOMEM);
 	}
 
-	snprintf(adap->device_name, sizeof(adap->device_name),
-		 "RC for %s", name);
 	snprintf(adap->input_phys, sizeof(adap->input_phys),
-		 "%s/input0", name);
+		 "%s/input0", adap->name);
 
-	adap->rc->device_name = adap->device_name;
+	adap->rc->device_name = adap->name;
 	adap->rc->input_phys = adap->input_phys;
 	adap->rc->input_id.bustype = BUS_CEC;
 	adap->rc->input_id.vendor = 0;
diff --git a/include/media/cec.h b/include/media/cec.h
index 9f382f0c2970..73ed28b076ce 100644
--- a/include/media/cec.h
+++ b/include/media/cec.h
@@ -198,9 +198,7 @@ struct cec_adapter {
 	u16 phys_addrs[15];
 	u32 sequence;
 
-	char device_name[32];
 	char input_phys[32];
-	char input_drv[32];
 };
 
 static inline void *cec_get_drvdata(const struct cec_adapter *adap)
-- 
2.17.1

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

* Re: [PATCH] media: cec: name for RC passthrough device does not need 'RC for'
  2018-10-04 22:21 [PATCH] media: cec: name for RC passthrough device does not need 'RC for' Sean Young
@ 2018-10-05  7:37 ` Hans Verkuil
  2018-10-05  9:36   ` Sean Young
  0 siblings, 1 reply; 3+ messages in thread
From: Hans Verkuil @ 2018-10-05  7:37 UTC (permalink / raw)
  To: Sean Young, linux-media

On 10/05/2018 12:21 AM, Sean Young wrote:
> An RC device is does not need to be called 'RC for'. Simply the name
> will suffice.
> 
> Signed-off-by: Sean Young <sean@mess.org>

Reviewed-by: Hans Verkuil <hans.verkuil@cisco.com>

OK if I take this patch? I have a cec pull request upcoming anyway.

Regards,

	Hans

> ---
>  drivers/media/cec/cec-core.c | 6 ++----
>  include/media/cec.h          | 2 --
>  2 files changed, 2 insertions(+), 6 deletions(-)
> 
> diff --git a/drivers/media/cec/cec-core.c b/drivers/media/cec/cec-core.c
> index 74596f089ec9..e4edc930d4ed 100644
> --- a/drivers/media/cec/cec-core.c
> +++ b/drivers/media/cec/cec-core.c
> @@ -307,12 +307,10 @@ struct cec_adapter *cec_allocate_adapter(const struct cec_adap_ops *ops,
>  		return ERR_PTR(-ENOMEM);
>  	}
>  
> -	snprintf(adap->device_name, sizeof(adap->device_name),
> -		 "RC for %s", name);
>  	snprintf(adap->input_phys, sizeof(adap->input_phys),
> -		 "%s/input0", name);
> +		 "%s/input0", adap->name);
>  
> -	adap->rc->device_name = adap->device_name;
> +	adap->rc->device_name = adap->name;
>  	adap->rc->input_phys = adap->input_phys;
>  	adap->rc->input_id.bustype = BUS_CEC;
>  	adap->rc->input_id.vendor = 0;
> diff --git a/include/media/cec.h b/include/media/cec.h
> index 9f382f0c2970..73ed28b076ce 100644
> --- a/include/media/cec.h
> +++ b/include/media/cec.h
> @@ -198,9 +198,7 @@ struct cec_adapter {
>  	u16 phys_addrs[15];
>  	u32 sequence;
>  
> -	char device_name[32];
>  	char input_phys[32];
> -	char input_drv[32];
>  };
>  
>  static inline void *cec_get_drvdata(const struct cec_adapter *adap)
> 

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

* Re: [PATCH] media: cec: name for RC passthrough device does not need 'RC for'
  2018-10-05  7:37 ` Hans Verkuil
@ 2018-10-05  9:36   ` Sean Young
  0 siblings, 0 replies; 3+ messages in thread
From: Sean Young @ 2018-10-05  9:36 UTC (permalink / raw)
  To: Hans Verkuil; +Cc: linux-media

On Fri, Oct 05, 2018 at 09:37:11AM +0200, Hans Verkuil wrote:
> On 10/05/2018 12:21 AM, Sean Young wrote:
> > An RC device is does not need to be called 'RC for'. Simply the name
> > will suffice.
> > 
> > Signed-off-by: Sean Young <sean@mess.org>
> 
> Reviewed-by: Hans Verkuil <hans.verkuil@cisco.com>
> 
> OK if I take this patch? I have a cec pull request upcoming anyway.

Please do, thank you.

Sean

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

end of thread, other threads:[~2018-10-05 16:34 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-10-04 22:21 [PATCH] media: cec: name for RC passthrough device does not need 'RC for' Sean Young
2018-10-05  7:37 ` Hans Verkuil
2018-10-05  9:36   ` Sean Young

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.