Received: by 10.223.185.116 with SMTP id b49csp1222553wrg; Fri, 23 Feb 2018 14:14:36 -0800 (PST) X-Google-Smtp-Source: AH8x226ggQRfLE9VfntxXV50Cft3PaXhx+8S9fgZMerXbDzld7Io9iCW0exbAcUOAXNYoP/kBPzW X-Received: by 2002:a17:902:501:: with SMTP id 1-v6mr3015463plf.283.1519424076715; Fri, 23 Feb 2018 14:14:36 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1519424076; cv=none; d=google.com; s=arc-20160816; b=iubJ0i32chc/4F4yOjDsw0FLPQhAFtR5VznW3F8CYLBOZXmAuJ/zO8D82Bq1h7DXhB byh0EaA6dPZx4g6MFnnMDDxOmGZAh2NDxT7+JCWvh6wPTs6oe1RqQNYshf0K2Ua82KgW wdQbYF8ftjLu1cj0ILEpl0hR6fGAt62Kx4KYomzrn0YSMumLlq91m7TBPsVbOKCZkTWm wJ9RarbRXeG4xAVmZNJEgialIYzZuuyKk6ZwbAnPJJhkodg6ZO1mET1QeJEXCFKgM8kI zTiKtUaphlMcFjZmpingQO15w4NWaVqICB4OTK+dVN5dtV5OxYpU3aN5JdyBP1i4ZY0P 3a0g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:references :in-reply-to:message-id:date:subject:cc:to:from :arc-authentication-results; bh=al4g3149AHIIuRXsWxx0VBWYn6t6hzjnGgXa5pN58VI=; b=YVn4QZWUx7srKcB4T2wa7G1TyDz8ElWPo96N3l9ObQUQOqJEUH28qtd4gUfz9nsK19 lvH6QFjqbe2MFEetmlBnhibSe5TLC19jdSaQzsaz1ZQ/C3r4dwFRlJzKu1MAETr9XAxU Zvdr2PGXmFWRI8BWUnLfHVnXeqygdE4kL2l35092QcT2zSHreXAoCCOKRkBxlnr5msdC qvJnYrnYgdy0unWZU7PQYCGPHaajMml1ZrjGZbxI4HQYTMtJihyC4PpHbJT1nQqKuphj FzVtMS/qG6JMZI5O/8nlwxCkG+mPKBonxeAVzuAsT5M7Wj28x+DeR7ZOzcBQfZ81Phdi k3+A== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=samsung.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id u3si2027568pgr.447.2018.02.23.14.14.22; Fri, 23 Feb 2018 14:14:36 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=samsung.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752178AbeBWWMO (ORCPT + 99 others); Fri, 23 Feb 2018 17:12:14 -0500 Received: from osg.samsung.com ([64.30.133.232]:46417 "EHLO osg.samsung.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751955AbeBWWMK (ORCPT ); Fri, 23 Feb 2018 17:12:10 -0500 Received: from localhost (localhost [127.0.0.1]) by osg.samsung.com (Postfix) with ESMTP id 460B420A9B; Fri, 23 Feb 2018 14:12:10 -0800 (PST) X-Virus-Scanned: Debian amavisd-new at dev.s-opensource.com X-Amavis-Alert: BAD HEADER SECTION, Duplicate header field: "References" Received: from osg.samsung.com ([127.0.0.1]) by localhost (localhost [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 8WFqzn70ke3Z; Fri, 23 Feb 2018 14:12:09 -0800 (PST) Received: from localhost.localdomain (c-24-9-64-241.hsd1.co.comcast.net [24.9.64.241]) by osg.samsung.com (Postfix) with ESMTPSA id E784A20A77; Fri, 23 Feb 2018 14:12:04 -0800 (PST) From: Shuah Khan To: shuah@kernel.org, dvhart@infradead.org, tbird20d@gmail.com Cc: Shuah Khan , tglx@linutronix.de, mingo@redhat.com, peterz@infradead.org, linux-kernel@vger.kernel.org, linux-kselftest@vger.kernel.org Subject: [PATCH 4/5] selftests: size call ksft_print_header() to print TAP header Date: Fri, 23 Feb 2018 15:11:39 -0700 Message-Id: <181e4860e7f2b2dc8e4074e76d00cc99662c1fa1.1519423341.git.shuahkh@osg.samsung.com> X-Mailer: git-send-email 2.14.1 In-Reply-To: References: In-Reply-To: References: Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Call ksft_print_header() to print TAP header. This change helps prevent nested TAP headers when the test is run from run_tests and from script generated by emit_tests as in both of these cases KSFT_TAP_LEVEL will be set and ksft_print_header() will suppress the nested TAP header from size test. Signed-off-by: Shuah Khan --- tools/testing/selftests/size/get_size.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/tools/testing/selftests/size/get_size.c b/tools/testing/selftests/size/get_size.c index d4b59ab979a0..1280b09266f0 100644 --- a/tools/testing/selftests/size/get_size.c +++ b/tools/testing/selftests/size/get_size.c @@ -23,6 +23,8 @@ #include #include +#include +#include "../kselftest.h" #define STDOUT_FILENO 1 @@ -77,7 +79,7 @@ void _start(void) unsigned long used; static const char *test_name = " get runtime memory use\n"; - print("TAP version 13\n"); + ksft_print_header(); print("# Testing system size.\n"); ccode = sysinfo(&info); -- 2.14.1