From patchwork Mon Aug 14 21:01:35 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: John Stultz X-Patchwork-Id: 110061 Delivered-To: patches@linaro.org Received: by 10.140.95.78 with SMTP id h72csp4843377qge; Mon, 14 Aug 2017 14:01:42 -0700 (PDT) X-Received: by 10.99.51.142 with SMTP id z136mr25096382pgz.275.1502744502252; Mon, 14 Aug 2017 14:01:42 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1502744502; cv=none; d=google.com; s=arc-20160816; b=brtwMFK6H/ip6NdS8ke1yKi3RBMCS4uIzKP2p/kfre0MrCFZjawNNpi49gvyvqPzMg KacgI5WfJI1KXpTc0lvhoB9eNJm/MOgAu/BR3Y4ZMy2mQNWrpxIQYemQec1TRIhlWXN/ JX15eI0upinkcwAtAWYJFOYXT55OJGjbDe81sHmSrnHICx6YNAbSrSgc4Y7zV4OH7RFc 6J/dTiBtJMuKg3hY2WqDe4gKJSKytwPNIB2HLLzxNg4AlBsL8Hc/nAdfAqunToAeOe2a 6Z+YDPWx+QuulSgqaLXoX1qYGW5P4Gi19zc/TZAIKzmaufMk3ayzkItxoybEDSYRSa// 5MxQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=message-id:date:subject:cc:to:from:dkim-signature :arc-authentication-results; bh=++chrhhd59F7YXl4xEo4Wa3MnSaycL70WQUIEbldInM=; b=hQ85zJPVUI2DuW4ywM6pAuDmCRgFrQITofl+jkRSOA+Dmk8nlbQY79/8aC8pVi98n/ 315ql7NIODOWPeA7/lW7JxMOF/H4qGXZ11Si6qCzZGwSGbUH6bp5yBnfP5UjYpVsxvkL vwqTezDcuOGYzEoJfutEfXK7ouzx2ZUL/E+ycZYFOssxlE8k58CWIzEWOzPyTDglFYqG ffNeF4MnSr0/dVSWH0yp3xLFKkzEAj4ybZ1coi7Y52rGPvXURO2Fdmi3FJutvXuOjbk2 g7tPLYv6oyXuTM/4XfuMWVNT1ZcFqNlA8yDN79v/GGljHSR775wtAauypkwx8ZA7xZuy ox6Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=d0x/vwJC; spf=pass (google.com: domain of john.stultz@linaro.org designates 2607:f8b0:400e:c05::233 as permitted sender) smtp.mailfrom=john.stultz@linaro.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from mail-pg0-x233.google.com (mail-pg0-x233.google.com. [2607:f8b0:400e:c05::233]) by mx.google.com with ESMTPS id f87si4639042pfe.137.2017.08.14.14.01.42 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 14 Aug 2017 14:01:42 -0700 (PDT) Received-SPF: pass (google.com: domain of john.stultz@linaro.org designates 2607:f8b0:400e:c05::233 as permitted sender) client-ip=2607:f8b0:400e:c05::233; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=d0x/vwJC; spf=pass (google.com: domain of john.stultz@linaro.org designates 2607:f8b0:400e:c05::233 as permitted sender) smtp.mailfrom=john.stultz@linaro.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: by mail-pg0-x233.google.com with SMTP id i12so3619075pgr.3 for ; Mon, 14 Aug 2017 14:01:42 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id; bh=++chrhhd59F7YXl4xEo4Wa3MnSaycL70WQUIEbldInM=; b=d0x/vwJCN4no0S+FpQWT/5HQLPlXGIeNksCGlxvbtkSXjVtln+5dF8b5HIjCJKOVZJ KniS1XU+OtkwkofuuUxYBWAfndANA+H3sRtCX5g8+VJ/u9WqDd2LRYIieN8zyOdGP1/c iH997IkRnWI2i7OH2G8ffX23OyTnBJrq5vBAA= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id; bh=++chrhhd59F7YXl4xEo4Wa3MnSaycL70WQUIEbldInM=; b=WJWzKrYqMLQzeTWe+kjAe2tgDmfZAJH8Bup1p+hFkM1aeBdJIn/Ct3V21toaRDcELh gU2bTBt+mLDyHTzfyzhDMRKcuiPD1VSRGFnR0aovOWROAwtk6k9xOsqN/8bryKTbpQet WE9ehiAyt0VBeZPJX4CHxGmWD9gpGBvUqeOpCF77wKvzvlHwvUQGHHjLgfybhy0LsDeP wq7/YkqmX9gu5t2nuIElxEuWML3pvN62sk3ptfPyZ7SYn1peEEY6EpUTgHtNSXoY7ZMe Ktjc8FhJvJJxUXyRl09eBg2QKsik7A1sQgTh3/MAOmzNftfT+XgZIgx431QQw41JnAz0 NRTQ== X-Gm-Message-State: AHYfb5gXaV2HMpMCMVD9gWRhr0DJe7ETI4H6amT1LtUdaVrKOJYISgEl VyJwVwktf0KEEBZhzj0= X-Received: by 10.84.210.78 with SMTP id z72mr28998071plh.465.1502744501471; Mon, 14 Aug 2017 14:01:41 -0700 (PDT) Return-Path: Received: from localhost.localdomain ([2601:1c2:1002:83f0:4e72:b9ff:fe99:466a]) by smtp.gmail.com with ESMTPSA id b184sm14263491pfb.53.2017.08.14.14.01.39 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Mon, 14 Aug 2017 14:01:40 -0700 (PDT) From: John Stultz To: lkml Cc: John Stultz , Shuah Khan , Thomas Gleixner , Stephen Boyd , Miroslav Lichvar , linux-kselftest@vger.kernel.org Subject: [RFC][PATCH 1/2] kselftests: timers: freq-step: Define ADJ_SETOFFSET if device has older kernel headers Date: Mon, 14 Aug 2017 14:01:35 -0700 Message-Id: <1502744496-17863-1-git-send-email-john.stultz@linaro.org> X-Mailer: git-send-email 2.7.4 On some systems, the kernel headers haven't been updated to include ADJ_SETOFFSET, so define it in the test if needed. Cc: Shuah Khan Cc: Thomas Gleixner Cc: Stephen Boyd Cc: Miroslav Lichvar Cc: linux-kselftest@vger.kernel.org Signed-off-by: John Stultz --- tools/testing/selftests/timers/freq-step.c | 4 ++++ 1 file changed, 4 insertions(+) -- 2.7.4 diff --git a/tools/testing/selftests/timers/freq-step.c b/tools/testing/selftests/timers/freq-step.c index 22312eb..f0d1323 100644 --- a/tools/testing/selftests/timers/freq-step.c +++ b/tools/testing/selftests/timers/freq-step.c @@ -33,6 +33,10 @@ #define MAX_FREQ_ERROR 10e-6 #define MAX_STDDEV 1000e-9 +#ifndef ADJ_SETOFFSET + #define ADJ_SETOFFSET 0x0100 +#endif + struct sample { double offset; double time;