Messages in this thread | | | Date | Wed, 31 Aug 2022 03:45:30 +0300 | From | Dmitry Rokosov <> | Subject | Re: [PATCH v1] regmap: introduce value tracing for regmap bulk operations |
| |
Hello Andy,
Sorry for late response. I didn't have the ability to reach my laptop during last week.
[...]
> > > + if (val) > > + memcpy(__get_dynamic_array(buf), val, val_len); > > I'm probably missing something, but what this condition prevents from?
In general, this condition prevents memcpy from being executed when tracepoint is called with a null pointed buffer.
[...]
> > + TP_printk("%s reg=%x val=%s", __get_str(name), > > + (unsigned int)__entry->reg, > > Why do you need casting? >
To be honest, I've made it based on the already existing regmap tracepoints style. All of them make a cast to unsigned int type when printout reg number.
-- Thank you, Dmitry
| |