On Thu, Apr 03, 2014 at 04:46:53PM -0700, Tony Luck wrote: > > +static int extlog_trace_show(struct seq_file *m, void *v) > > +{ > > + atomic_inc(&trace_on); > > + return 0; > > +} > > + > > +static int trace_open(struct inode *inode, struct file *file) > > +{ > > + return single_open(file, extlog_trace_show, NULL); > > +} > > Shouldn't this atomic_inc() be inside the trace_open() function > ... not the extlog_trace_show()? > Gee. It's my fault. I thought extlog_trace_show is only called by *open* but after I look through related codes, I find it is called be *read*, too. I will fix it in next version.
Attachment:
signature.asc
Description: Digital signature