From patchwork Wed Feb 26 17:41:17 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Gregory Rose X-Patchwork-Id: 1245234 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=openvswitch.org (client-ip=140.211.166.133; helo=hemlock.osuosl.org; envelope-from=ovs-dev-bounces@openvswitch.org; receiver=) Authentication-Results: ozlabs.org; dmarc=fail (p=none dis=none) header.from=gmail.com Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.a=rsa-sha256 header.s=20161025 header.b=ERQDfVbr; dkim-atps=neutral Received: from hemlock.osuosl.org (smtp2.osuosl.org [140.211.166.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 48SNR60m8vz9sPK for ; Thu, 27 Feb 2020 04:42:09 +1100 (AEDT) Received: from localhost (localhost [127.0.0.1]) by hemlock.osuosl.org (Postfix) with ESMTP id 1C40E87C11; Wed, 26 Feb 2020 17:42:08 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from hemlock.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id jwxjaXlv1P-X; Wed, 26 Feb 2020 17:42:04 +0000 (UTC) Received: from lists.linuxfoundation.org (lf-lists.osuosl.org [140.211.9.56]) by hemlock.osuosl.org (Postfix) with ESMTP id E61AE87CB8; Wed, 26 Feb 2020 17:41:58 +0000 (UTC) Received: from lf-lists.osuosl.org (localhost [127.0.0.1]) by lists.linuxfoundation.org (Postfix) with ESMTP id B7AD9C1DCE; Wed, 26 Feb 2020 17:41:58 +0000 (UTC) X-Original-To: dev@openvswitch.org Delivered-To: ovs-dev@lists.linuxfoundation.org Received: from silver.osuosl.org (smtp3.osuosl.org [140.211.166.136]) by lists.linuxfoundation.org (Postfix) with ESMTP id D17B2C1DCB for ; Wed, 26 Feb 2020 17:41:56 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by silver.osuosl.org (Postfix) with ESMTP id B856D231AB for ; Wed, 26 Feb 2020 17:41:56 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from silver.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id JUnobFBOj4PM for ; Wed, 26 Feb 2020 17:41:54 +0000 (UTC) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.6 Received: from mail-pf1-f196.google.com (mail-pf1-f196.google.com [209.85.210.196]) by silver.osuosl.org (Postfix) with ESMTPS id 1E5FD22EDD for ; Wed, 26 Feb 2020 17:41:40 +0000 (UTC) Received: by mail-pf1-f196.google.com with SMTP id b185so127527pfb.7 for ; Wed, 26 Feb 2020 09:41:40 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=FcDWzeAnrxD+wy6hBB/J3Px3Pg6fmoqz4o8LTtRtGjE=; b=ERQDfVbrXW8YIqUL+V5ruZKOwm5a3paf/8V6SWBhJBdwCholFmbPDFS9iBaLfv279G MBGmTbHCSx582xQAkwK/KkHcQGFIgNeu7MRIxhZkvU0fHyiKufgVYoKnbOIL/PWiTmBV tUnM5y8FRXK1sdfpzpb5eiw/l3xNLXqDjB9m/C5cs9kl/ah+MaJLCR9artlJa1LISweD +MWWi7WILGGzQLa5UAtWYK5Z7jXrkFah+3K8oFOWmDr0IVbgiyNvHJ7qpUSPSG2R9UdB xQUBJNACCJuqV8mZY435Ba9iLfawEo7eghzOvInyghYxV8NbRdr+dMl6/8l4+YKgkekG Xxxg== 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:in-reply-to :references; bh=FcDWzeAnrxD+wy6hBB/J3Px3Pg6fmoqz4o8LTtRtGjE=; b=q3YdKqlTpaeyd7qFiQXdhugy5viBkTFrFIMgZ9lGTQa+arWzuGzNWea2CZWtEUA/ha PSJYAXYSjH9mzFVfTY+goUNgtAgelrbXpLCeF/8NPQprEngxVnsvG4sZVXlW1xcfOtN5 Mt/PEbyMr0DIWQwLpl1n74jevD9PyTOIcLPoHXEZE20lE6vr0XDok4MvRbaUuSRmMVU2 grU/LBzCPhuy1UKOuE63QcsoVGXEJWmKcOUVBWNIDjZ65YgJmUQDUEhYtLyWZbA3Qrsg ytB+z2YePxqBTtQ1JdW61+09qfN/rJzEOJyt6ULJu23o9iwh0TK6CnHNXVUtIJiBU6nr cEVw== X-Gm-Message-State: APjAAAXgpyFi0mrRWsY7z4pUMMiUhIodzI8fbBbwN7jHe/cCKThxrZZm /qyTSc+c9M2Idf67363Gphjt8V/49s0= X-Google-Smtp-Source: APXvYqwWpFfocSvOR1XlISrRFk36BIoJ5LL17x0ne+w2wRe92X5VHfCzXdLMjGDMZvb77yQeeUEYXw== X-Received: by 2002:a63:3f4f:: with SMTP id m76mr4742397pga.353.1582738892205; Wed, 26 Feb 2020 09:41:32 -0800 (PST) Received: from gizo.domain (97-115-113-182.ptld.qwest.net. [97.115.113.182]) by smtp.gmail.com with ESMTPSA id k67sm3463133pga.91.2020.02.26.09.41.31 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Wed, 26 Feb 2020 09:41:31 -0800 (PST) From: Greg Rose To: dev@openvswitch.org Date: Wed, 26 Feb 2020 09:41:17 -0800 Message-Id: <1582738882-15842-7-git-send-email-gvrose8192@gmail.com> X-Mailer: git-send-email 1.8.3.1 In-Reply-To: <1582738882-15842-1-git-send-email-gvrose8192@gmail.com> References: <1582738882-15842-1-git-send-email-gvrose8192@gmail.com> Subject: [ovs-dev] [PATCH V2 06/11] compat: Add FIELD_SIZEOF macro X-BeenThere: ovs-dev@openvswitch.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: ovs-dev-bounces@openvswitch.org Sender: "dev" The FIELD_SIZEOF macro is removed in Linux kernel release 5.5 but is still needed in our out of tree kernel module for compatibility with older kernels. Signed-off-by: Greg Rose --- datapath/linux/compat/include/linux/kernel.h | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/datapath/linux/compat/include/linux/kernel.h b/datapath/linux/compat/include/linux/kernel.h index 2e81abc..8529b1d 100644 --- a/datapath/linux/compat/include/linux/kernel.h +++ b/datapath/linux/compat/include/linux/kernel.h @@ -32,4 +32,8 @@ #define U32_MAX ((u32)~0U) #endif +#ifndef FIELD_SIZEOF +#define FIELD_SIZEOF(t, f) (sizeof(((t*)0)->f)) +#endif + #endif /* linux/kernel.h */