From patchwork Tue Jun 17 17:55:16 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Taras Kondratiuk X-Patchwork-Id: 32099 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-oa0-f71.google.com (mail-oa0-f71.google.com [209.85.219.71]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id 04A6620C81 for ; Tue, 17 Jun 2014 17:56:46 +0000 (UTC) Received: by mail-oa0-f71.google.com with SMTP id n16sf43592897oag.6 for ; Tue, 17 Jun 2014 10:56:46 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:delivered-to:from:to:date:message-id:in-reply-to :references:subject:precedence:list-id:list-unsubscribe:list-archive :list-post:list-help:list-subscribe:mime-version:errors-to:sender :x-original-sender:x-original-authentication-results:mailing-list :content-type:content-transfer-encoding; bh=cfoF2mA84m4kBEuRn9xixPVrlz5CsS3p5msr5WhFNYs=; b=JOlTBxRJfHRy6YHLEElg6g1g96nv9Rq9OHRX9jkVnDOzVXBizfXlSbAGQDMH5qz4Y7 XbhIFpuXlMVWg/nvBfz4TC7BSShniyIBzu3cZ6IM+SKi+5fRavvSrnVWrHqnlALBWnLA UlK7kjqdL7TmUA911OvuN0YZkABMFlg5/x7DxEcITah/J9SYXQ8b0tztIlq0g+tN6Q/L zWoWNpqH/+rKBDRqj+a6kYpA9oe7EpvwMUu9ynOp+SG3viYEDBxfgla0OHkiuLQ2Vhqn WBkTQWZb9P7SbtqtNpiVoqqG93tYpUqCOLQrJBH+u/6hpZumbMSWrIanSL6RNjGg81nN Jh0Q== X-Gm-Message-State: ALoCoQlV6HYPA9b7OQWQE6+7+UTc+QEwllu+KqZ1Y/fEw5pY9ceMwxaVdXCPkFafUsVdg9MJHZm/ X-Received: by 10.50.73.35 with SMTP id i3mr546614igv.2.1403027806548; Tue, 17 Jun 2014 10:56:46 -0700 (PDT) X-BeenThere: patchwork-forward@linaro.org Received: by 10.140.96.6 with SMTP id j6ls1026092qge.89.gmail; Tue, 17 Jun 2014 10:56:46 -0700 (PDT) X-Received: by 10.52.52.168 with SMTP id u8mr19248090vdo.25.1403027806331; Tue, 17 Jun 2014 10:56:46 -0700 (PDT) Received: from mail-ve0-f170.google.com (mail-ve0-f170.google.com [209.85.128.170]) by mx.google.com with ESMTPS id mb10si5773334vcb.59.2014.06.17.10.56.46 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Tue, 17 Jun 2014 10:56:46 -0700 (PDT) Received-SPF: pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.128.170 as permitted sender) client-ip=209.85.128.170; Received: by mail-ve0-f170.google.com with SMTP id i13so4399492veh.15 for ; Tue, 17 Jun 2014 10:56:46 -0700 (PDT) X-Received: by 10.220.69.72 with SMTP id y8mr23109264vci.21.1403027806239; Tue, 17 Jun 2014 10:56:46 -0700 (PDT) X-Forwarded-To: patchwork-forward@linaro.org X-Forwarded-For: patch@linaro.org patchwork-forward@linaro.org Delivered-To: patch@linaro.org Received: by 10.221.54.6 with SMTP id vs6csp227596vcb; Tue, 17 Jun 2014 10:56:45 -0700 (PDT) X-Received: by 10.224.167.70 with SMTP id p6mr37976980qay.48.1403027805801; Tue, 17 Jun 2014 10:56:45 -0700 (PDT) Received: from ip-10-141-164-156.ec2.internal (lists.linaro.org. [54.225.227.206]) by mx.google.com with ESMTPS id k12si1848718qav.129.2014.06.17.10.56.45 for (version=TLSv1 cipher=RC4-SHA bits=128/128); Tue, 17 Jun 2014 10:56:45 -0700 (PDT) Received-SPF: none (google.com: lng-odp-bounces@lists.linaro.org does not designate permitted sender hosts) client-ip=54.225.227.206; Received: from localhost ([127.0.0.1] helo=ip-10-141-164-156.ec2.internal) by ip-10-141-164-156.ec2.internal with esmtp (Exim 4.76) (envelope-from ) id 1Wwxb3-0004vt-SV; Tue, 17 Jun 2014 17:55:01 +0000 Received: from mail-lb0-f172.google.com ([209.85.217.172]) by ip-10-141-164-156.ec2.internal with esmtp (Exim 4.76) (envelope-from ) id 1Wwxa8-0004ne-Ir for lng-odp@lists.linaro.org; Tue, 17 Jun 2014 17:54:04 +0000 Received: by mail-lb0-f172.google.com with SMTP id c11so4292364lbj.3 for ; Tue, 17 Jun 2014 10:55:41 -0700 (PDT) X-Received: by 10.112.131.8 with SMTP id oi8mr1962818lbb.87.1403027741530; Tue, 17 Jun 2014 10:55:41 -0700 (PDT) Received: from localhost.localdomain (176-241-155-136-dynamic.retail.datagroup.ua. [176.241.155.136]) by mx.google.com with ESMTPSA id d3sm11646351lbw.2.2014.06.17.10.55.40 for (version=TLSv1.1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Tue, 17 Jun 2014 10:55:41 -0700 (PDT) From: Taras Kondratiuk To: lng-odp@lists.linaro.org Date: Tue, 17 Jun 2014 20:55:16 +0300 Message-Id: <1403027720-9738-15-git-send-email-taras.kondratiuk@linaro.org> X-Mailer: git-send-email 1.7.9.5 In-Reply-To: <1403027720-9738-1-git-send-email-taras.kondratiuk@linaro.org> References: <1403027720-9738-1-git-send-email-taras.kondratiuk@linaro.org> X-Topics: patch Subject: [lng-odp] [PATCH v2 14/18] Split out platform-specific part of odp_spinlock.h X-BeenThere: lng-odp@lists.linaro.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: 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-bounces@lists.linaro.org X-Removed-Original-Auth: Dkim didn't pass. X-Original-Sender: taras.kondratiuk@linaro.org X-Original-Authentication-Results: mx.google.com; spf=pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.128.170 as permitted sender) smtp.mail=patch+caf_=patchwork-forward=linaro.org@linaro.org Mailing-list: list patchwork-forward@linaro.org; contact patchwork-forward+owners@linaro.org X-Google-Group-Id: 836684582541 Signed-off-by: Taras Kondratiuk --- include/odp_spinlock.h | 6 ++--- platform/linux-generic/include/plat/odp_spinlock.h | 27 ++++++++++++++++++++ 2 files changed, 29 insertions(+), 4 deletions(-) create mode 100644 platform/linux-generic/include/plat/odp_spinlock.h diff --git a/include/odp_spinlock.h b/include/odp_spinlock.h index 52b7a71..e155ca3 100644 --- a/include/odp_spinlock.h +++ b/include/odp_spinlock.h @@ -20,14 +20,12 @@ extern "C" { #include - +#include /** * ODP spinlock */ -typedef struct odp_spinlock_t { - volatile int lock; /**< @private Lock */ -} odp_spinlock_t; +typedef plat_odp_spinlock_t odp_spinlock_t; /** diff --git a/platform/linux-generic/include/plat/odp_spinlock.h b/platform/linux-generic/include/plat/odp_spinlock.h new file mode 100644 index 0000000..f980a3d --- /dev/null +++ b/platform/linux-generic/include/plat/odp_spinlock.h @@ -0,0 +1,27 @@ +/* Copyright (c) 2013, Linaro Limited + * All rights reserved. + * + * SPDX-License-Identifier: BSD-3-Clause + */ + + +/** + * @file + * + * ODP spinlock + */ + +#ifndef ODP_SPINLOCK_H_ +#error This file should be included only into corresponding top level header +#else + +#include + +/** + * ODP spinlock + */ +typedef struct odp_spinlock_t { + volatile int lock; /**< @private Lock */ +} plat_odp_spinlock_t; + +#endif