<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux.git/drivers/staging/media/lirc, branch v4.1</title>
<subtitle>Linux kernel source tree</subtitle>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux.git/'/>
<entry>
<title>Staging: media: remove useless dev_info to avoid null ptr dereference</title>
<updated>2015-03-23T21:42:40+00:00</updated>
<author>
<name>Haneen Mohammed</name>
<email>hamohammed.sa@gmail.com</email>
</author>
<published>2015-03-22T00:02:02+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux.git/commit/?id=be546c6cd0a9ad742f1dc7869acdf2d80971ddb5'/>
<id>be546c6cd0a9ad742f1dc7869acdf2d80971ddb5</id>
<content type='text'>
Context is used in dev_info after it has been freed.
This patch fix that issue by removing the dev_info itself,
for msg doesn't look much necessary.

Signed-off-by: Haneen Mohammed &lt;hamohammed.sa@gmail.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Context is used in dev_info after it has been freed.
This patch fix that issue by removing the dev_info itself,
for msg doesn't look much necessary.

Signed-off-by: Haneen Mohammed &lt;hamohammed.sa@gmail.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>Staging: media: replace pr_* with dev_*</title>
<updated>2015-03-18T10:21:33+00:00</updated>
<author>
<name>Haneen Mohammed</name>
<email>hamohammed.sa@gmail.com</email>
</author>
<published>2015-03-18T10:09:50+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux.git/commit/?id=2c9356d115c91c18a2508a266a482c47fc3659c6'/>
<id>2c9356d115c91c18a2508a266a482c47fc3659c6</id>
<content type='text'>
This patch replace pr_err/pr_info with dev_err/dev_infi, when
appropriate device structure is found.

Issues found using the following Coccinelle script. pr_err/dev_err was
substituted with pr_info/dev_info in the later case.

@r exists@
identifier f, s, i;
position p;
@@
f(...,struct s *i,...) {
&lt;+...
when != i == NULL
pr_err@p(...);
...+&gt;
}
@rr@
identifier r.s, s2, fld;
@@

struct s {
	...
	struct s2 *fld;
	...
};

@rrr@
identifier rr.s2, fld2;
@@

struct s2 {
	...
	struct device fld2;
	...
};
@@
identifier r.i, r.s, rr.fld, rrr.fld2;
position r.p;
@@

-pr_err@p
+dev_err
   (
+ &amp;i-&gt;fld-&gt;fld2,
...)

Signed-off-by: Haneen Mohammed &lt;hamohammed.sa@gmail.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This patch replace pr_err/pr_info with dev_err/dev_infi, when
appropriate device structure is found.

Issues found using the following Coccinelle script. pr_err/dev_err was
substituted with pr_info/dev_info in the later case.

@r exists@
identifier f, s, i;
position p;
@@
f(...,struct s *i,...) {
&lt;+...
when != i == NULL
pr_err@p(...);
...+&gt;
}
@rr@
identifier r.s, s2, fld;
@@

struct s {
	...
	struct s2 *fld;
	...
};

@rrr@
identifier rr.s2, fld2;
@@

struct s2 {
	...
	struct device fld2;
	...
};
@@
identifier r.i, r.s, rr.fld, rrr.fld2;
position r.p;
@@

-pr_err@p
+dev_err
   (
+ &amp;i-&gt;fld-&gt;fld2,
...)

Signed-off-by: Haneen Mohammed &lt;hamohammed.sa@gmail.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>Staging: media: Remove parentheses around right side an assignment</title>
<updated>2015-03-16T15:24:19+00:00</updated>
<author>
<name>Haneen Mohammed</name>
<email>hamohammed.sa@gmail.com</email>
</author>
<published>2015-03-13T17:46:57+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux.git/commit/?id=8126e17f89259dfb6bf8ba6a2303a62702099e37'/>
<id>8126e17f89259dfb6bf8ba6a2303a62702099e37</id>
<content type='text'>
Parentheses are not needed around the right hand side of an assignment.
This patch remove parenthese of such occurenses. Issue was detected and
solved using the following coccinelle script:

@rule1@
identifier x, y, z;
expression E1, E2;
@@

(
x = (y == z);
|
x = (E1 == E2);
|
 x =
-(
...
-)
 ;
)

Signed-off-by: Haneen Mohammed &lt;hamohammed.sa@gmail.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Parentheses are not needed around the right hand side of an assignment.
This patch remove parenthese of such occurenses. Issue was detected and
solved using the following coccinelle script:

@rule1@
identifier x, y, z;
expression E1, E2;
@@

(
x = (y == z);
|
x = (E1 == E2);
|
 x =
-(
...
-)
 ;
)

Signed-off-by: Haneen Mohammed &lt;hamohammed.sa@gmail.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>staging: media: lirc: remove pointer to pointer cast on function arguments</title>
<updated>2015-03-15T17:41:11+00:00</updated>
<author>
<name>Aya Mahfouz</name>
<email>mahfouz.saif.elyazal@gmail.com</email>
</author>
<published>2015-03-10T16:57:25+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux.git/commit/?id=805184c451cdb225ffbdf83ba010160d74b3a471'/>
<id>805184c451cdb225ffbdf83ba010160d74b3a471</id>
<content type='text'>
Removes pointer to pointer cast on function arguments. Issue
detected and resolved using the following coccinelle script:

@@
expression e;
type t;
identifier f;
@@

f(...,
-(t *)
e
,...)

Signed-off-by: Aya Mahfouz &lt;mahfouz.saif.elyazal@gmail.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Removes pointer to pointer cast on function arguments. Issue
detected and resolved using the following coccinelle script:

@@
expression e;
type t;
identifier f;
@@

f(...,
-(t *)
e
,...)

Signed-off-by: Aya Mahfouz &lt;mahfouz.saif.elyazal@gmail.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>staging: media: lirc: fix multiple issues with function arguments</title>
<updated>2015-03-15T17:41:11+00:00</updated>
<author>
<name>Aya Mahfouz</name>
<email>mahfouz.saif.elyazal@gmail.com</email>
</author>
<published>2015-03-10T16:56:37+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux.git/commit/?id=028b242d1b91e95869a084c43ce3497203f84e5c'/>
<id>028b242d1b91e95869a084c43ce3497203f84e5c</id>
<content type='text'>
Handles the following issues:

Removing extra parentheses around function arguments,
Removing unnecessary pointer to pointer casts.

Issues detected and resolved using the following coccinelle
script:

@@
expression e;
type t;
identifier f;
@@

f(...,
-(t *)
e
,...)

@@
expression e;
identifier f;
@@

f(...,
&amp;
-(
e
-)
,...)

@@
expression e;
identifier f;
@@

f(...,
-(
e
-)
,...)

Signed-off-by: Aya Mahfouz &lt;mahfouz.saif.elyazal@gmail.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Handles the following issues:

Removing extra parentheses around function arguments,
Removing unnecessary pointer to pointer casts.

Issues detected and resolved using the following coccinelle
script:

@@
expression e;
type t;
identifier f;
@@

f(...,
-(t *)
e
,...)

@@
expression e;
identifier f;
@@

f(...,
&amp;
-(
e
-)
,...)

@@
expression e;
identifier f;
@@

f(...,
-(
e
-)
,...)

Signed-off-by: Aya Mahfouz &lt;mahfouz.saif.elyazal@gmail.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>staging: media: lirc: remove unnecessary cast on function argument</title>
<updated>2015-03-15T17:41:11+00:00</updated>
<author>
<name>Aya Mahfouz</name>
<email>mahfouz.saif.elyazal@gmail.com</email>
</author>
<published>2015-03-10T16:55:27+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux.git/commit/?id=505942151da6310df05213413d4ebd10bd5fd450'/>
<id>505942151da6310df05213413d4ebd10bd5fd450</id>
<content type='text'>
Removes pointer to pointer cast on a function argument. Issue
detected and resolved using the following coccinelle script:

@@
expression e;
type t;
identifier f;
@@

f(...,
-(t *)
e
,...)

Signed-off-by: Aya Mahfouz &lt;mahfouz.saif.elyazal@gmail.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Removes pointer to pointer cast on a function argument. Issue
detected and resolved using the following coccinelle script:

@@
expression e;
type t;
identifier f;
@@

f(...,
-(t *)
e
,...)

Signed-off-by: Aya Mahfouz &lt;mahfouz.saif.elyazal@gmail.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>staging: media: lirc: lirc_imon.c: remove extra parentheses around function arguments</title>
<updated>2015-03-15T17:41:11+00:00</updated>
<author>
<name>Aya Mahfouz</name>
<email>mahfouz.saif.elyazal@gmail.com</email>
</author>
<published>2015-03-10T16:54:51+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux.git/commit/?id=bb3a4dc3af68b92ad5d5cc0020268daae554db93'/>
<id>bb3a4dc3af68b92ad5d5cc0020268daae554db93</id>
<content type='text'>
Removes extra parentheses around function arguments. Issue
detected and resolved using the following coccinelle script:

@@
expression e;
identifier f;
@@

f(...,
&amp;
-(
e
-)
,...)

Signed-off-by: Aya Mahfouz &lt;mahfouz.saif.elyazal@gmail.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Removes extra parentheses around function arguments. Issue
detected and resolved using the following coccinelle script:

@@
expression e;
identifier f;
@@

f(...,
&amp;
-(
e
-)
,...)

Signed-off-by: Aya Mahfouz &lt;mahfouz.saif.elyazal@gmail.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>Staging: media: clean dev_err logging</title>
<updated>2015-03-06T23:55:36+00:00</updated>
<author>
<name>Haneen Mohammed</name>
<email>hamohammed.sa@gmail.com</email>
</author>
<published>2015-03-06T19:00:10+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux.git/commit/?id=8c6ccbeb510fe48ed8808067cd7cbf92f7e8ebac'/>
<id>8c6ccbeb510fe48ed8808067cd7cbf92f7e8ebac</id>
<content type='text'>
This patch removes  __func__ from dev_err. dev_err includes information about:
(devcice, driver, specific instance of device, etc) in the log printout.
This was done using Coccinelle, with the following semantic patch:

@a@
expression E, R;
expression  msg;
@@

dev_err(E, msg, __func__, R);

@script:python b@
e &lt;&lt; a.msg;
y;
@@

if(e.find("%s: ") == True):
	m = e.replace("%s: ", "", 1);
	coccinelle.y = m;
elif(e.find("%s ") == True):
	m = e.replace("%s ", "", 1);
	coccinelle.y = m;
elif(e.find("%s:") == True):
	m = e.replace("%s:", "", 1);
	coccinelle.y = m;
else:
	m = e.replace("%s", "",1);
	coccinelle.y = m;

@c@
expression a.E, a.msg, a.R;
identifier  b.y;
@@

- dev_err(E, msg, __func__, R);
+ dev_err(E, y, R);

Signed-off-by: Haneen Mohammed &lt;hamohammed.sa@gmail.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This patch removes  __func__ from dev_err. dev_err includes information about:
(devcice, driver, specific instance of device, etc) in the log printout.
This was done using Coccinelle, with the following semantic patch:

@a@
expression E, R;
expression  msg;
@@

dev_err(E, msg, __func__, R);

@script:python b@
e &lt;&lt; a.msg;
y;
@@

if(e.find("%s: ") == True):
	m = e.replace("%s: ", "", 1);
	coccinelle.y = m;
elif(e.find("%s ") == True):
	m = e.replace("%s ", "", 1);
	coccinelle.y = m;
elif(e.find("%s:") == True):
	m = e.replace("%s:", "", 1);
	coccinelle.y = m;
else:
	m = e.replace("%s", "",1);
	coccinelle.y = m;

@c@
expression a.E, a.msg, a.R;
identifier  b.y;
@@

- dev_err(E, msg, __func__, R);
+ dev_err(E, y, R);

Signed-off-by: Haneen Mohammed &lt;hamohammed.sa@gmail.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>Staging: media: Replace dev_err with pr_err to avoid null pointer derefrence</title>
<updated>2015-03-06T23:54:41+00:00</updated>
<author>
<name>Haneen Mohammed</name>
<email>hamohammed.sa@gmail.com</email>
</author>
<published>2015-03-06T17:01:07+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux.git/commit/?id=14f63eeecfa3ca092f1c83755303161e53a9c641'/>
<id>14f63eeecfa3ca092f1c83755303161e53a9c641</id>
<content type='text'>
This patch replace dev_err with pr_err, for pointer is derefrenced after comparing it to NULL.
This was found using the following coccinelle script:

@disable is_null@
identifier f;
expression E;
identifier fld;
statement S;
@@

+ if(E == NULL) S
	f(...,E-&gt;fld,...);
-if(E == NULL) S;

@@
identifier f;
expression E;
identifier fld;
statement S;
@@

+ if(!E) S
	f(...,E-&gt;fld,...);
-if(!E) S;

Signed-off-by: Haneen Mohammed &lt;hamohammed.sa@gmail.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This patch replace dev_err with pr_err, for pointer is derefrenced after comparing it to NULL.
This was found using the following coccinelle script:

@disable is_null@
identifier f;
expression E;
identifier fld;
statement S;
@@

+ if(E == NULL) S
	f(...,E-&gt;fld,...);
-if(E == NULL) S;

@@
identifier f;
expression E;
identifier fld;
statement S;
@@

+ if(!E) S
	f(...,E-&gt;fld,...);
-if(!E) S;

Signed-off-by: Haneen Mohammed &lt;hamohammed.sa@gmail.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>staging: media: lirc: remove extra parentheses around right bit shift operation</title>
<updated>2015-03-06T23:22:42+00:00</updated>
<author>
<name>Aya Mahfouz</name>
<email>mahfouz.saif.elyazal@gmail.com</email>
</author>
<published>2015-03-04T05:31:19+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux.git/commit/?id=6182930bdb207789c3c92051c2c4a03f5da8f6ee'/>
<id>6182930bdb207789c3c92051c2c4a03f5da8f6ee</id>
<content type='text'>
Removes extra parentheses around bitwise right shift operation.
The case handled here is when the resultant value is assigned to
a variable. The issue was detected and resolved using the following
coccinelle script:

@@
expression e, e1;
constant c;
@@

e =
-(e1
+e1
&gt;&gt;
-c);
+c;

@@
identifier i;
constant c;
type t;
expression e;
@@

t i =
-(e
+e
&gt;&gt;
-c);
+c;

@@
expression e, e1;
identifier f;
constant c;
@@

e1 = f(...,
-(e
+e
&gt;&gt;
-c)
+c
,...);

Signed-off-by: Aya Mahfouz &lt;mahfouz.saif.elyazal@gmail.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Removes extra parentheses around bitwise right shift operation.
The case handled here is when the resultant value is assigned to
a variable. The issue was detected and resolved using the following
coccinelle script:

@@
expression e, e1;
constant c;
@@

e =
-(e1
+e1
&gt;&gt;
-c);
+c;

@@
identifier i;
constant c;
type t;
expression e;
@@

t i =
-(e
+e
&gt;&gt;
-c);
+c;

@@
expression e, e1;
identifier f;
constant c;
@@

e1 = f(...,
-(e
+e
&gt;&gt;
-c)
+c
,...);

Signed-off-by: Aya Mahfouz &lt;mahfouz.saif.elyazal@gmail.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</pre>
</div>
</content>
</entry>
</feed>
