Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751786AbcDQLun (ORCPT ); Sun, 17 Apr 2016 07:50:43 -0400 Received: from mx1.redhat.com ([209.132.183.28]:50964 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751316AbcDQLum (ORCPT ); Sun, 17 Apr 2016 07:50:42 -0400 Date: Sun, 17 Apr 2016 13:50:37 +0200 From: Jiri Olsa To: Wang Nan Cc: acme@kernel.org, linux-kernel@vger.kernel.org, pi3orama@163.com, Adrian Hunter , He Kuang , Jiri Olsa , Masami Hiramatsu , Namhyung Kim , Zefan Li , Arnaldo Carvalho de Melo Subject: Re: [PATCH v3 1/6] perf tools: Derive trigger class from auxtrace_snapshot Message-ID: <20160417115037.GA31336@krava.brq.redhat.com> References: <1460744420-175165-1-git-send-email-wangnan0@huawei.com> <1460744420-175165-2-git-send-email-wangnan0@huawei.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1460744420-175165-2-git-send-email-wangnan0@huawei.com> User-Agent: Mutt/1.5.24 (2015-08-30) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 770 Lines: 19 On Fri, Apr 15, 2016 at 06:20:15PM +0000, Wang Nan wrote: > Create a new class named 'trigger' to model the state of a trigger and > implement auxtrace_snapshot with it. > > auxtrace_record__snapshot_started and auxtrace_snapshot_err are absorbed. > > 'trigger' defines 4 state transitioning functions ('on', 'released', > 'toggle' and 'colddown') and 2 state query function ('is_released') and > ('is_toggled'). The state 'ON' and 'OFF' take higher priority than > 'RELEASED' and 'TOGGLED'. A trigger must be 'on' before 'enable' and > 'disable' take effect. A trigger can be colddown after being triggered. what's the COLDDOWN state for? could you please document all the transitions of this state machine in the change log and the trigger.h file? thanks, jirka