[PATCH 4/7] ARM: oprofile: Move non-ARM code into separate init/exit

Paul Mundt lethal at linux-sh.org
Wed Oct 6 09:41:31 EDT 2010


On Wed, Oct 06, 2010 at 03:33:09PM +0200, Robert Richter wrote:
> On 04.10.10 16:44:22, Matt Fleming wrote:
> > @@ -388,7 +387,14 @@ out:
> >  	return ret;
> >  }
> >  
> > -void __exit oprofile_arch_exit(void)
> > +int __init oprofile_arch_init(struct oprofile_operations *ops)
> > +{
> 
> We should do here a:
> 
> 	memset(ops, 0, sizeof(*ops));
> 
> Otherwise it looks good.
> 
What kind of crap interface is oprofile peddling, seriously?

You expect every single architecture to clear this structure that gets
passed in from the oprofile code without having any idea if there are
defaults assigned or not, instead of just having the oprofile code clear
it out before passing it along?



More information about the linux-arm-kernel mailing list