[PATCH v9 3/3] binder: add transaction latency tracer

Greg Kroah-Hartman gregkh at linuxfoundation.org
Wed Sep 16 13:38:45 EDT 2020


On Tue, Sep 08, 2020 at 10:06:48PM +0800, Frankie Chang wrote:
> +#if IS_ENABLED(CONFIG_BINDER_TRANSACTION_LATENCY_TRACKING)
> +#include <linux/rtc.h>
> +#include <linux/time.h>
> +#endif
> +
>  struct binder_context {
>  	struct binder_node *binder_context_mgr_node;
>  	struct mutex context_mgr_node_lock;
> @@ -524,6 +529,14 @@ struct binder_transaction {
>  	 * during thread teardown
>  	 */
>  	spinlock_t lock;
> +	/**
> +	 * @ts and @real_ts are used to record the time
> +	 * that the binder transaction startup
> +	 */
> +#if IS_ENABLED(CONFIG_BINDER_TRANSACTION_LATENCY_TRACKING)
> +	struct timespec64 ts;
> +	struct timespec64 real_ts;

Why isn't this ktime_t?  Is timespec64 really something to be using
still?

thanks,

greg k-h



More information about the Linux-mediatek mailing list