From patchwork Tue May 10 01:55:35 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bill Fischofer X-Patchwork-Id: 67390 Delivered-To: patch@linaro.org Received: by 10.140.92.199 with SMTP id b65csp1880708qge; Mon, 9 May 2016 18:55:47 -0700 (PDT) X-Received: by 10.55.166.131 with SMTP id p125mr676460qke.161.1462845346977; Mon, 09 May 2016 18:55:46 -0700 (PDT) Return-Path: Received: from lists.linaro.org (lists.linaro.org. [54.225.227.206]) by mx.google.com with ESMTP id 81si20659427qhg.9.2016.05.09.18.55.46; Mon, 09 May 2016 18:55:46 -0700 (PDT) Received-SPF: pass (google.com: domain of lng-odp-bounces@lists.linaro.org designates 54.225.227.206 as permitted sender) client-ip=54.225.227.206; Authentication-Results: mx.google.com; spf=pass (google.com: domain of lng-odp-bounces@lists.linaro.org designates 54.225.227.206 as permitted sender) smtp.mailfrom=lng-odp-bounces@lists.linaro.org; dmarc=pass (p=NONE dis=NONE) header.from=linaro.org Received: by lists.linaro.org (Postfix, from userid 109) id 65FD8615F5; Tue, 10 May 2016 01:55:46 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on ip-10-142-244-252 X-Spam-Level: X-Spam-Status: No, score=-2.6 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_LOW, RCVD_IN_MSPIKE_H2, URIBL_BLOCKED autolearn=disabled version=3.4.0 Received: from [127.0.0.1] (localhost [127.0.0.1]) by lists.linaro.org (Postfix) with ESMTP id EE0DF6155F; Tue, 10 May 2016 01:55:42 +0000 (UTC) X-Original-To: lng-odp@lists.linaro.org Delivered-To: lng-odp@lists.linaro.org Received: by lists.linaro.org (Postfix, from userid 109) id 7032261562; Tue, 10 May 2016 01:55:41 +0000 (UTC) Received: from mail-ob0-f176.google.com (mail-ob0-f176.google.com [209.85.214.176]) by lists.linaro.org (Postfix) with ESMTPS id 51F586155E for ; Tue, 10 May 2016 01:55:40 +0000 (UTC) Received: by mail-ob0-f176.google.com with SMTP id aq1so86892182obc.3 for ; Mon, 09 May 2016 18:55:40 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id; bh=iZKXL625MkPLoZeuGRC4uHvfogvVxTLp47+LCEEvuwA=; b=WBGXTUnQrh73lSR0A0VX/TK6AoW8yFsE7FeM/gVSZuJTyd0XXpOLdcmZe5985fwCYS tAak+7khN9idl6IRTgRM44h5nv8GHZWY5nPy9QscqmfRcAk7yzClrkXCJqmOsGON0+ae QpuSLwO8Xuet5y9Rauc5CKAXc4a6jKk6y8gMCFFBZtO5Jrnta+Gbl1HiWyyQSEORW8Jk HHYDRw+Sei2Zx7aUJ+Y0pfmpUP85ROF57mROeJnh6Oj54jbsq/ierkIwiuPoweqXSwVJ +S5RIRALweCdkUl0pY5tsr8K2wYhEozRwLr2/bd6/c8pzKf4dG8apLBGv2Lh+VBuaWQC Iz7w== X-Gm-Message-State: AOPr4FWEYX1Vi1dUU/In/J7oR5nrECw6QJ+TQe/aSnz4Q3ZTtqU3hRs4GMA3mB0VrrksbQN/Ojk= X-Received: by 10.182.135.129 with SMTP id ps1mr13482133obb.59.1462845339812; Mon, 09 May 2016 18:55:39 -0700 (PDT) Received: from localhost.localdomain (cpe-66-68-129-43.austin.res.rr.com. [66.68.129.43]) by smtp.gmail.com with ESMTPSA id sl9sm5634693oeb.10.2016.05.09.18.55.39 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Mon, 09 May 2016 18:55:39 -0700 (PDT) From: Bill Fischofer To: lng-odp@lists.linaro.org Date: Mon, 9 May 2016 20:55:35 -0500 Message-Id: <1462845335-5513-1-git-send-email-bill.fischofer@linaro.org> X-Mailer: git-send-email 2.7.4 X-Topics: timers patch Subject: [lng-odp] [PATCH] linux-generic: timer: change assert to account for padding X-BeenThere: lng-odp@lists.linaro.org X-Mailman-Version: 2.1.16 Precedence: list List-Id: "The OpenDataPlane \(ODP\) List" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: lng-odp-bounces@lists.linaro.org Sender: "lng-odp" The tick_buf_t struct may be larger than 16 bytes when a lock char is needed so correct the ODP_STATIC_ASSERT to reflect this. This addresses bug https://bugs.linaro.org/show_bug.cgi?id=2211 when compiling with clang. Signed-off-by: Bill Fischofer Reviewed-by: Balasubramanian Manoharan --- platform/linux-generic/odp_timer.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/platform/linux-generic/odp_timer.c b/platform/linux-generic/odp_timer.c index f4fb1f6..89ec5f5 100644 --- a/platform/linux-generic/odp_timer.c +++ b/platform/linux-generic/odp_timer.c @@ -107,7 +107,7 @@ ODP_ALIGNED(16) /* 16-byte atomic operations need properly aligned addresses */ #endif ; -ODP_STATIC_ASSERT(sizeof(tick_buf_t) == 16, "sizeof(tick_buf_t) == 16"); +ODP_STATIC_ASSERT(sizeof(tick_buf_t) >= 16, "sizeof(tick_buf_t) >= 16"); typedef struct odp_timer_s { void *user_ptr;