Re: [PATCH 2/3] Always check marker consitency

Mathieu Desnoyers <[email protected]>
Newsgroups gmane.linux.kernel.tracing
Message-ID <20070514201444.GB25984@Krystal>
Applied.

* Jan Kiszka ([email protected]) wrote:
> Test for consistent marker format strings even if the caller of
> _marker_set_probe_range doesn't pass one.
> 
> Signed-off-by: Jan Kiszka <[email protected]>
> 
> ---
>  kernel/module.c |   22 +++++++++++++---------
>  1 file changed, 13 insertions(+), 9 deletions(-)
> 
> Index: linux-2.6.21.1/kernel/module.c
> ===================================================================
> --- linux-2.6.21.1.orig/kernel/module.c
> +++ linux-2.6.21.1/kernel/module.c
> @@ -342,15 +342,19 @@ static int _marker_set_probe_range(int f
>  		if (strcmp(name, iter->mdata->name) != 0)
>  			continue;
> 
> -		if (format && strcmp(format, iter->mdata->format) != 0) {
> -			printk(KERN_NOTICE
> -				"Format mismatch for probe %s "
> -				"(%s), marker (%s)\n",
> -				name,
> -				format,
> -				iter->mdata->format);
> -			continue;
> -		}
> +		if (format) {
> +			if (strcmp(format, iter->mdata->format) != 0) {
> +				printk(KERN_NOTICE
> +					"Format mismatch for probe %s "
> +					"(%s), marker (%s)\n",
> +					name,
> +					format,
> +					iter->mdata->format);
> +				continue;
> +			}
> +		} else
> +			format = iter->mdata->format;
> +
>  		if (flags & MF_LOCKDEP
>  			&& !(iter->mdata->flags & MF_LOCKDEP)) {
>  			printk(KERN_NOTICE
> 



> _______________________________________________
> Ltt-dev mailing list
> [email protected]
> http://listserv.shafik.org/mailman/listinfo/ltt-dev


-- 
Mathieu Desnoyers
Computer Engineering Ph.D. Student, Ecole Polytechnique de Montreal
OpenPGP key fingerprint: 8CD5 52C3 8E3C 4140 715F  BA06 3F25 A8FE 3BAE 9A68

_______________________________________________
Ltt-dev mailing list
[email protected]
http://listserv.shafik.org/mailman/listinfo/ltt-dev
signature.asc (application/pgp-signature, 189 B)
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.6 (GNU/Linux)

iD8DBQFGSMM0PyWo/juummgRAkM6AJ4/3iwAqXqjjion+2ZhBt/kAJZXswCggpw+
H8adU+dBLDvJZ5na5JVrxH0=
=fpjA
-----END PGP SIGNATURE-----
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.