Received: by 2002:a25:e7d8:0:0:0:0:0 with SMTP id e207csp1866342ybh; Fri, 13 Mar 2020 08:45:35 -0700 (PDT) X-Google-Smtp-Source: ADFU+vs1ISebMSPVBXXSiv9CW1Z+qbzQ9/uvljkn1suhAY9KjZXCafls7Y2xpPPBNj2J7257XLvP X-Received: by 2002:a9d:6b17:: with SMTP id g23mr9361318otp.263.1584114334878; Fri, 13 Mar 2020 08:45:34 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1584114334; cv=none; d=google.com; s=arc-20160816; b=qrYZhRWBcj+gqnJtJyf4LCg+J7Tj2cQ0+2rqt9rD+tzBCkMnenCmy0YmmfQJC3cvVA ZvnKLvG25w8Vj2yWbqdy/evTtIFS3yjRuNb8bwmzBaNeOg91+F2QUwYn8jMAsxEp1fSL Y1afWopNPEXWek/Igp/WElopSXdm06Jw0BiB1ev+EPt2Iqdt4IA4gerdBmcdajiW7dyU orPZDT3sp9y+OCTIEfnee/lF2HOrF6VXDAbBTnYnxNCPfVOB8zniW1hHat/jAtpCvTzw LUV32B3Mcd+/GBBkttgVrpR2QjqjvIe/pJFVt7sEhr0OXfTZqauWI5hO1rmenlHb8Za/ vE5w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from; bh=ztkJpZm7hZA0dvmRlmvHTYn1wMIl8igO6kJRtrJdG+0=; b=PMVj0OLTe7xZMk4MnLCEbN/+fR7jGwDcnh5eiFB0xfAq10oGGcLLGeVKUkqBJJk4Cu DIvTz8lByfFjG9lhRW4vc0OMtSRRYCCphyvWzQ8lZM54nPr49V5rtYtm4nE7gSaxtOna MG2zxdcmlWOBlAUxtCtWNnkut+PWShQ6SM1ZDpasUBKTELBOnFxzZo1+mKBIJxLBDfW9 16cKfzAeTHPeuUUNohTusJheHQT6oJFVXgxuGDQQHWagYssHKCbU+QhIa1rt8VGjgV/B abwXFTsmK8u/qPNAz1JTdbhgH8BwpNzHbppmCXA/AWMLtOgPT3wpl9sXDOT/vGt+kXf/ D0kw== 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id d16si4741657otp.135.2020.03.13.08.45.22; Fri, 13 Mar 2020 08:45:34 -0700 (PDT) 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727236AbgCMPom (ORCPT + 99 others); Fri, 13 Mar 2020 11:44:42 -0400 Received: from foss.arm.com ([217.140.110.172]:58610 "EHLO foss.arm.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727224AbgCMPol (ORCPT ); Fri, 13 Mar 2020 11:44:41 -0400 Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id C1CEF1045; Fri, 13 Mar 2020 08:44:40 -0700 (PDT) Received: from e119884-lin.cambridge.arm.com (e119884-lin.cambridge.arm.com [10.1.196.72]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id CABC63F67D; Fri, 13 Mar 2020 08:44:37 -0700 (PDT) From: Vincenzo Frascino To: linux-arch@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, linux-mips@vger.kernel.org, clang-built-linux@googlegroups.com, x86@kernel.org Cc: Vincenzo Frascino , Catalin Marinas , Will Deacon , Arnd Bergmann , Russell King , Paul Burton , Thomas Gleixner , Andy Lutomirski , Ingo Molnar , Borislav Petkov , Stephen Boyd , Mark Salyzyn , Kees Cook , Peter Collingbourne , Dmitry Safonov <0x7f454c46@gmail.com>, Andrei Vagin , Nick Desaulniers , Marc Zyngier , Mark Rutland Subject: [PATCH v3 11/26] linux/time32.h: Extract common header for vDSO Date: Fri, 13 Mar 2020 15:43:30 +0000 Message-Id: <20200313154345.56760-12-vincenzo.frascino@arm.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20200313154345.56760-1-vincenzo.frascino@arm.com> References: <20200313154345.56760-1-vincenzo.frascino@arm.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org The vDSO library should only include the necessary headers required for a userspace library (UAPI and a minimal set of kernel headers). To make this possible it is necessary to isolate from the kernel headers the common parts that are strictly necessary to build the library. Split time32.h into linux and common headers to make the latter suitable for inclusion in the vDSO library. Signed-off-by: Vincenzo Frascino --- include/linux/time32.h | 14 ++------------ include/vdso/time32.h | 17 +++++++++++++++++ 2 files changed, 19 insertions(+), 12 deletions(-) create mode 100644 include/vdso/time32.h diff --git a/include/linux/time32.h b/include/linux/time32.h index cad4c3186002..0933f28214c0 100644 --- a/include/linux/time32.h +++ b/include/linux/time32.h @@ -12,19 +12,9 @@ #include #include -#define TIME_T_MAX (__kernel_old_time_t)((1UL << ((sizeof(__kernel_old_time_t) << 3) - 1)) - 1) - -typedef s32 old_time32_t; - -struct old_timespec32 { - old_time32_t tv_sec; - s32 tv_nsec; -}; +#include -struct old_timeval32 { - old_time32_t tv_sec; - s32 tv_usec; -}; +#define TIME_T_MAX (__kernel_old_time_t)((1UL << ((sizeof(__kernel_old_time_t) << 3) - 1)) - 1) struct old_itimerspec32 { struct old_timespec32 it_interval; diff --git a/include/vdso/time32.h b/include/vdso/time32.h new file mode 100644 index 000000000000..fdf56f932f67 --- /dev/null +++ b/include/vdso/time32.h @@ -0,0 +1,17 @@ +/* SPDX-License-Identifier: GPL-2.0 */ +#ifndef __VDSO_TIME32_H +#define __VDSO_TIME32_H + +typedef s32 old_time32_t; + +struct old_timespec32 { + old_time32_t tv_sec; + s32 tv_nsec; +}; + +struct old_timeval32 { + old_time32_t tv_sec; + s32 tv_usec; +}; + +#endif /* __VDSO_TIME32_H */ -- 2.25.1