* [PATCH] staging: nvec: Remove unnecessary cast on void pointer
@ 2017-03-02 20:15 ` simran singhal
0 siblings, 0 replies; 5+ messages in thread
From: simran singhal @ 2017-03-02 20:15 UTC (permalink / raw)
To: marvin24
Cc: devel, gregkh, linux-kernel, outreachy-kernel, linux-tegra, ac100
The following Coccinelle script was used to detect this:
@r@
expression x;
void* e;
type T;
identifier f;
@@
(
*((T *)e)
|
((T *)x)[...]
|
((T*)x)->f
|
- (T*)
e
)
Signed-off-by: simran singhal <singhalsimran0@gmail.com>
---
drivers/staging/nvec/nvec_kbd.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/staging/nvec/nvec_kbd.c b/drivers/staging/nvec/nvec_kbd.c
index e881e6b..a01f486 100644
--- a/drivers/staging/nvec/nvec_kbd.c
+++ b/drivers/staging/nvec/nvec_kbd.c
@@ -58,7 +58,7 @@ static int nvec_keys_notifier(struct notifier_block *nb,
unsigned long event_type, void *data)
{
int code, state;
- unsigned char *msg = (unsigned char *)data;
+ unsigned char *msg = data;
if (event_type == NVEC_KB_EVT) {
int _size = (msg[0] & (3 << 5)) >> 5;
--
2.7.4
^ permalink raw reply related [flat|nested] 5+ messages in thread
* [PATCH] staging: nvec: Remove unnecessary cast on void pointer
@ 2017-03-02 20:15 ` simran singhal
0 siblings, 0 replies; 5+ messages in thread
From: simran singhal @ 2017-03-02 20:15 UTC (permalink / raw)
To: marvin24
Cc: gregkh, ac100, linux-tegra, devel, linux-kernel, outreachy-kernel
The following Coccinelle script was used to detect this:
@r@
expression x;
void* e;
type T;
identifier f;
@@
(
*((T *)e)
|
((T *)x)[...]
|
((T*)x)->f
|
- (T*)
e
)
Signed-off-by: simran singhal <singhalsimran0@gmail.com>
---
drivers/staging/nvec/nvec_kbd.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/staging/nvec/nvec_kbd.c b/drivers/staging/nvec/nvec_kbd.c
index e881e6b..a01f486 100644
--- a/drivers/staging/nvec/nvec_kbd.c
+++ b/drivers/staging/nvec/nvec_kbd.c
@@ -58,7 +58,7 @@ static int nvec_keys_notifier(struct notifier_block *nb,
unsigned long event_type, void *data)
{
int code, state;
- unsigned char *msg = (unsigned char *)data;
+ unsigned char *msg = data;
if (event_type == NVEC_KB_EVT) {
int _size = (msg[0] & (3 << 5)) >> 5;
--
2.7.4
^ permalink raw reply related [flat|nested] 5+ messages in thread
* Re: [PATCH] staging: nvec: Remove unnecessary cast on void pointer
2017-03-02 20:15 ` simran singhal
(?)
@ 2017-03-02 21:21 ` SIMRAN SINGHAL
-1 siblings, 0 replies; 5+ messages in thread
From: SIMRAN SINGHAL @ 2017-03-02 21:21 UTC (permalink / raw)
To: outreachy-kernel
Cc: marvin24, gregkh, ac100, linux-tegra, devel, linux-kernel
[-- Attachment #1.1: Type: text/plain, Size: 1144 bytes --]
Please ignore this patch.
I have send this again as a part of patch series.
On Friday, March 3, 2017 at 1:45:17 AM UTC+5:30, SIMRAN SINGHAL wrote:
>
> The following Coccinelle script was used to detect this:
>
> @r@
> expression x;
> void* e;
> type T;
> identifier f;
> @@
> (
> *((T *)e)
> |
> ((T *)x)[...]
> |
> ((T*)x)->f
> |
> - (T*)
> e
> )
>
> Signed-off-by: simran singhal <singhalsimran0@gmail.com>
> ---
> drivers/staging/nvec/nvec_kbd.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/staging/nvec/nvec_kbd.c
> b/drivers/staging/nvec/nvec_kbd.c
> index e881e6b..a01f486 100644
> --- a/drivers/staging/nvec/nvec_kbd.c
> +++ b/drivers/staging/nvec/nvec_kbd.c
> @@ -58,7 +58,7 @@ static int nvec_keys_notifier(struct notifier_block *nb,
> unsigned long event_type, void *data)
> {
> int code, state;
> - unsigned char *msg = (unsigned char *)data;
> + unsigned char *msg = data;
>
> if (event_type == NVEC_KB_EVT) {
> int _size = (msg[0] & (3 << 5)) >> 5;
> --
> 2.7.4
>
>
[-- Attachment #1.2: Type: text/html, Size: 1760 bytes --]
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH] staging: nvec: Remove unnecessary cast on void pointer
2017-03-02 20:15 ` simran singhal
@ 2017-03-08 12:49 ` Thierry Reding
-1 siblings, 0 replies; 5+ messages in thread
From: Thierry Reding @ 2017-03-08 12:49 UTC (permalink / raw)
To: simran singhal
Cc: devel, gregkh, linux-kernel, outreachy-kernel, linux-tegra, ac100
[-- Attachment #1.1: Type: text/plain, Size: 504 bytes --]
On Fri, Mar 03, 2017 at 01:45:11AM +0530, simran singhal wrote:
> The following Coccinelle script was used to detect this:
>
> @r@
> expression x;
> void* e;
> type T;
> identifier f;
> @@
> (
> *((T *)e)
> |
> ((T *)x)[...]
> |
> ((T*)x)->f
> |
> - (T*)
> e
> )
>
> Signed-off-by: simran singhal <singhalsimran0@gmail.com>
> ---
> drivers/staging/nvec/nvec_kbd.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
Acked-by: Thierry Reding <treding@nvidia.com>
[-- Attachment #1.2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]
[-- Attachment #2: Type: text/plain, Size: 169 bytes --]
_______________________________________________
devel mailing list
devel@linuxdriverproject.org
http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH] staging: nvec: Remove unnecessary cast on void pointer
@ 2017-03-08 12:49 ` Thierry Reding
0 siblings, 0 replies; 5+ messages in thread
From: Thierry Reding @ 2017-03-08 12:49 UTC (permalink / raw)
To: simran singhal
Cc: marvin24, gregkh, ac100, linux-tegra, devel, linux-kernel,
outreachy-kernel
[-- Attachment #1: Type: text/plain, Size: 504 bytes --]
On Fri, Mar 03, 2017 at 01:45:11AM +0530, simran singhal wrote:
> The following Coccinelle script was used to detect this:
>
> @r@
> expression x;
> void* e;
> type T;
> identifier f;
> @@
> (
> *((T *)e)
> |
> ((T *)x)[...]
> |
> ((T*)x)->f
> |
> - (T*)
> e
> )
>
> Signed-off-by: simran singhal <singhalsimran0@gmail.com>
> ---
> drivers/staging/nvec/nvec_kbd.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
Acked-by: Thierry Reding <treding@nvidia.com>
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2017-03-08 12:54 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-03-02 20:15 [PATCH] staging: nvec: Remove unnecessary cast on void pointer simran singhal
2017-03-02 20:15 ` simran singhal
2017-03-02 21:21 ` SIMRAN SINGHAL
2017-03-08 12:49 ` Thierry Reding
2017-03-08 12:49 ` Thierry Reding
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.