From patchwork Fri Apr 26 09:59:08 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Simon Dawson X-Patchwork-Id: 239791 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from fraxinus.osuosl.org (fraxinus.osuosl.org [140.211.166.137]) by ozlabs.org (Postfix) with ESMTP id 8F7A82C00F4 for ; Fri, 26 Apr 2013 19:59:27 +1000 (EST) Received: from localhost (localhost [127.0.0.1]) by fraxinus.osuosl.org (Postfix) with ESMTP id 7B3BF10BAD3; Fri, 26 Apr 2013 09:59:06 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from fraxinus.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id PAKAQi3+YgI9; Fri, 26 Apr 2013 09:59:01 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by fraxinus.osuosl.org (Postfix) with ESMTP id 1F7C61026DD; Fri, 26 Apr 2013 09:59:01 +0000 (UTC) X-Original-To: buildroot@lists.busybox.net Delivered-To: buildroot@osuosl.org Received: from whitealder.osuosl.org (whitealder.osuosl.org [140.211.166.138]) by ash.osuosl.org (Postfix) with ESMTP id 71CBD8F753 for ; Fri, 26 Apr 2013 09:59:25 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by whitealder.osuosl.org (Postfix) with ESMTP id 81A8E84D90 for ; Fri, 26 Apr 2013 09:59:17 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from whitealder.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id etHuQSkJN93j for ; Fri, 26 Apr 2013 09:59:14 +0000 (UTC) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.6 Received: from mail-wg0-f52.google.com (mail-wg0-f52.google.com [74.125.82.52]) by whitealder.osuosl.org (Postfix) with ESMTPS id 2FA3384F73 for ; Fri, 26 Apr 2013 09:59:13 +0000 (UTC) Received: by mail-wg0-f52.google.com with SMTP id k13so2017405wgh.19 for ; Fri, 26 Apr 2013 02:59:12 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=x-received:from:to:subject:date:message-id:x-mailer; bh=wPDv2RHrlXB+2wRzxHIOvufuCbmMYpImBM0u0tKfdSg=; b=AjprMx6cMk49/rzl9i4Q+Qu0t3OKtk128kvdBAT+nhrdUrl6mes+o49+pfJ+MYgKqd OWsEglxNYWZre1IcrPTyC14JW7brmR/0moCuHX2Q7ecx7LNlOrjA1ZIE8ITat0LBOXWv vC7HbRMcI7rwn/2a85fC/8JNymJsxrmAwt3MlbZwFZWhcbx7xBnk8gIvxqJt5iKlrMzr Wpgjxeuc/o5U+39av6r/XhcG5qEEtNRvtTh6V68y/QCtOnSHkKFfa9KkFgoXHEtEiBbh AJvV2uuhAwRpLDC7ZaNDbEuLr/hLpYipIEqdGZLDCCxmG80Isjdh3U9vPBXH1KH7bSLP urpQ== X-Received: by 10.180.187.206 with SMTP id fu14mr2890590wic.11.1366970352598; Fri, 26 Apr 2013 02:59:12 -0700 (PDT) Received: from localhost.localdomain (host86-134-29-90.range86-134.btcentralplus.com. [86.134.29.90]) by mx.google.com with ESMTPSA id t7sm2403715wij.2.2013.04.26.02.59.11 for (version=TLSv1.1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Fri, 26 Apr 2013 02:59:11 -0700 (PDT) From: spdawson@gmail.com To: buildroot@busybox.net Date: Fri, 26 Apr 2013 10:59:08 +0100 Message-Id: <1366970348-16429-1-git-send-email-spdawson@gmail.com> X-Mailer: git-send-email 1.7.10.4 Subject: [Buildroot] [PATCH] neard: bump version to 0.11 X-BeenThere: buildroot@busybox.net X-Mailman-Version: 2.1.14 Precedence: list List-Id: Discussion and development of buildroot List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: buildroot-bounces@busybox.net Sender: buildroot-bounces@busybox.net From: Simon Dawson Signed-off-by: Simon Dawson --- .../neard/neard-fix-missing-linux-nfc-header.patch | 428 -------------------- package/neard/neard.mk | 2 +- 2 files changed, 1 insertion(+), 429 deletions(-) delete mode 100644 package/neard/neard-fix-missing-linux-nfc-header.patch diff --git a/package/neard/neard-fix-missing-linux-nfc-header.patch b/package/neard/neard-fix-missing-linux-nfc-header.patch deleted file mode 100644 index 377269e..0000000 --- a/package/neard/neard-fix-missing-linux-nfc-header.patch +++ /dev/null @@ -1,428 +0,0 @@ -Add a private copy of - -The addition of the header in the kernel sources is -moderately recent, and therefore, a number of toolchains don't have -this header. - -As a workaround until all reasonable toolchains get this header -included, add a configure check in neard to test whether this header -is available or not, and if not, use our own private copy of it. - -Since symbols from the v3.7 kernel header are used, but linux/nfc.h -already exists since the v3.1 kernel, check for one of the most -recently added symbols: NFC_LLCP_RAW_HEADER_SIZE. - -Signed-off-by: Thomas Petazzoni -Signed-off-by: Arnout Vandecappelle (Essensium/Mind) - -Index: b/configure.ac -=================================================================== ---- a/configure.ac -+++ b/configure.ac -@@ -88,6 +88,12 @@ - AC_SUBST(NETLINK_CFLAGS) - AC_SUBST(NETLINK_LIBS) - -+AC_TRY_COMPILE([ -+#include -+#include -+ ], [int err[NFC_LLCP_RAW_HEADER_SIZE-2];], -+ [AC_DEFINE(HAVE_LINUX_NFC_H, 1, [Defines if linux/nfc.h header is available])], []) -+ - AC_ARG_ENABLE(test, AC_HELP_STRING([--enable-test], - [enable test/example scripts]), - [enable_test=${enableval}]) -Index: b/src/near.h -=================================================================== ---- a/src/near.h -+++ b/src/near.h -@@ -23,7 +23,11 @@ - #include - - #include -+#ifdef HAVE_LINUX_NFC_H - #include -+#else -+#include "linux-nfc.h" -+#endif - - #include - -Index: b/src/linux-nfc.h -=================================================================== ---- /dev/null -+++ b/src/linux-nfc.h -@@ -0,0 +1,197 @@ -+/* -+ * Copyright (C) 2011 Instituto Nokia de Tecnologia -+ * -+ * Authors: -+ * Lauro Ramos Venancio -+ * Aloisio Almeida Jr -+ * -+ * This program is free software; you can redistribute it and/or modify -+ * it under the terms of the GNU General Public License as published by -+ * the Free Software Foundation; either version 2 of the License, or -+ * (at your option) any later version. -+ * -+ * This program is distributed in the hope that it will be useful, -+ * but WITHOUT ANY WARRANTY; without even the implied warranty of -+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -+ * GNU General Public License for more details. -+ * -+ * You should have received a copy of the GNU General Public License -+ * along with this program; if not, write to the -+ * Free Software Foundation, Inc., -+ * 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. -+ */ -+ -+#ifndef __LINUX_NFC_H -+#define __LINUX_NFC_H -+ -+#include -+#include -+ -+#define NFC_GENL_NAME "nfc" -+#define NFC_GENL_VERSION 1 -+ -+#define NFC_GENL_MCAST_EVENT_NAME "events" -+ -+/** -+ * enum nfc_commands - supported nfc commands -+ * -+ * @NFC_CMD_UNSPEC: unspecified command -+ * -+ * @NFC_CMD_GET_DEVICE: request information about a device (requires -+ * %NFC_ATTR_DEVICE_INDEX) or dump request to get a list of all nfc devices -+ * @NFC_CMD_DEV_UP: turn on the nfc device -+ * (requires %NFC_ATTR_DEVICE_INDEX) -+ * @NFC_CMD_DEV_DOWN: turn off the nfc device -+ * (requires %NFC_ATTR_DEVICE_INDEX) -+ * @NFC_CMD_START_POLL: start polling for targets using the given protocols -+ * (requires %NFC_ATTR_DEVICE_INDEX and %NFC_ATTR_PROTOCOLS) -+ * @NFC_CMD_STOP_POLL: stop polling for targets (requires -+ * %NFC_ATTR_DEVICE_INDEX) -+ * @NFC_CMD_GET_TARGET: dump all targets found by the previous poll (requires -+ * %NFC_ATTR_DEVICE_INDEX) -+ * @NFC_EVENT_TARGETS_FOUND: event emitted when a new target is found -+ * (it sends %NFC_ATTR_DEVICE_INDEX) -+ * @NFC_EVENT_DEVICE_ADDED: event emitted when a new device is registred -+ * (it sends %NFC_ATTR_DEVICE_NAME, %NFC_ATTR_DEVICE_INDEX and -+ * %NFC_ATTR_PROTOCOLS) -+ * @NFC_EVENT_DEVICE_REMOVED: event emitted when a device is removed -+ * (it sends %NFC_ATTR_DEVICE_INDEX) -+ * @NFC_EVENT_TM_ACTIVATED: event emitted when the adapter is activated in -+ * target mode. -+ * @NFC_EVENT_DEVICE_DEACTIVATED: event emitted when the adapter is deactivated -+ * from target mode. -+ */ -+enum nfc_commands { -+ NFC_CMD_UNSPEC, -+ NFC_CMD_GET_DEVICE, -+ NFC_CMD_DEV_UP, -+ NFC_CMD_DEV_DOWN, -+ NFC_CMD_DEP_LINK_UP, -+ NFC_CMD_DEP_LINK_DOWN, -+ NFC_CMD_START_POLL, -+ NFC_CMD_STOP_POLL, -+ NFC_CMD_GET_TARGET, -+ NFC_EVENT_TARGETS_FOUND, -+ NFC_EVENT_DEVICE_ADDED, -+ NFC_EVENT_DEVICE_REMOVED, -+ NFC_EVENT_TARGET_LOST, -+ NFC_EVENT_TM_ACTIVATED, -+ NFC_EVENT_TM_DEACTIVATED, -+/* private: internal use only */ -+ __NFC_CMD_AFTER_LAST -+}; -+#define NFC_CMD_MAX (__NFC_CMD_AFTER_LAST - 1) -+ -+/** -+ * enum nfc_attrs - supported nfc attributes -+ * -+ * @NFC_ATTR_UNSPEC: unspecified attribute -+ * -+ * @NFC_ATTR_DEVICE_INDEX: index of nfc device -+ * @NFC_ATTR_DEVICE_NAME: device name, max 8 chars -+ * @NFC_ATTR_PROTOCOLS: nfc protocols - bitwise or-ed combination from -+ * NFC_PROTO_*_MASK constants -+ * @NFC_ATTR_TARGET_INDEX: index of the nfc target -+ * @NFC_ATTR_TARGET_SENS_RES: NFC-A targets extra information such as NFCID -+ * @NFC_ATTR_TARGET_SEL_RES: NFC-A targets extra information (useful if the -+ * target is not NFC-Forum compliant) -+ * @NFC_ATTR_TARGET_NFCID1: NFC-A targets identifier, max 10 bytes -+ * @NFC_ATTR_TARGET_SENSB_RES: NFC-B targets extra information, max 12 bytes -+ * @NFC_ATTR_TARGET_SENSF_RES: NFC-F targets extra information, max 18 bytes -+ * @NFC_ATTR_COMM_MODE: Passive or active mode -+ * @NFC_ATTR_RF_MODE: Initiator or target -+ * @NFC_ATTR_IM_PROTOCOLS: Initiator mode protocols to poll for -+ * @NFC_ATTR_TM_PROTOCOLS: Target mode protocols to listen for -+ */ -+enum nfc_attrs { -+ NFC_ATTR_UNSPEC, -+ NFC_ATTR_DEVICE_INDEX, -+ NFC_ATTR_DEVICE_NAME, -+ NFC_ATTR_PROTOCOLS, -+ NFC_ATTR_TARGET_INDEX, -+ NFC_ATTR_TARGET_SENS_RES, -+ NFC_ATTR_TARGET_SEL_RES, -+ NFC_ATTR_TARGET_NFCID1, -+ NFC_ATTR_TARGET_SENSB_RES, -+ NFC_ATTR_TARGET_SENSF_RES, -+ NFC_ATTR_COMM_MODE, -+ NFC_ATTR_RF_MODE, -+ NFC_ATTR_DEVICE_POWERED, -+ NFC_ATTR_IM_PROTOCOLS, -+ NFC_ATTR_TM_PROTOCOLS, -+/* private: internal use only */ -+ __NFC_ATTR_AFTER_LAST -+}; -+#define NFC_ATTR_MAX (__NFC_ATTR_AFTER_LAST - 1) -+ -+#define NFC_DEVICE_NAME_MAXSIZE 8 -+#define NFC_NFCID1_MAXSIZE 10 -+#define NFC_SENSB_RES_MAXSIZE 12 -+#define NFC_SENSF_RES_MAXSIZE 18 -+#define NFC_GB_MAXSIZE 48 -+ -+/* NFC protocols */ -+#define NFC_PROTO_JEWEL 1 -+#define NFC_PROTO_MIFARE 2 -+#define NFC_PROTO_FELICA 3 -+#define NFC_PROTO_ISO14443 4 -+#define NFC_PROTO_NFC_DEP 5 -+#define NFC_PROTO_ISO14443_B 6 -+ -+#define NFC_PROTO_MAX 7 -+ -+/* NFC communication modes */ -+#define NFC_COMM_ACTIVE 0 -+#define NFC_COMM_PASSIVE 1 -+ -+/* NFC RF modes */ -+#define NFC_RF_INITIATOR 0 -+#define NFC_RF_TARGET 1 -+#define NFC_RF_NONE 2 -+ -+/* NFC protocols masks used in bitsets */ -+#define NFC_PROTO_JEWEL_MASK (1 << NFC_PROTO_JEWEL) -+#define NFC_PROTO_MIFARE_MASK (1 << NFC_PROTO_MIFARE) -+#define NFC_PROTO_FELICA_MASK (1 << NFC_PROTO_FELICA) -+#define NFC_PROTO_ISO14443_MASK (1 << NFC_PROTO_ISO14443) -+#define NFC_PROTO_NFC_DEP_MASK (1 << NFC_PROTO_NFC_DEP) -+#define NFC_PROTO_ISO14443_B_MASK (1 << NFC_PROTO_ISO14443_B) -+ -+struct sockaddr_nfc { -+ sa_family_t sa_family; -+ __u32 dev_idx; -+ __u32 target_idx; -+ __u32 nfc_protocol; -+}; -+ -+#define NFC_LLCP_MAX_SERVICE_NAME 63 -+struct sockaddr_nfc_llcp { -+ sa_family_t sa_family; -+ __u32 dev_idx; -+ __u32 target_idx; -+ __u32 nfc_protocol; -+ __u8 dsap; /* Destination SAP, if known */ -+ __u8 ssap; /* Source SAP to be bound to */ -+ char service_name[NFC_LLCP_MAX_SERVICE_NAME]; /* Service name URI */; -+ size_t service_name_len; -+}; -+ -+/* NFC socket protocols */ -+#define NFC_SOCKPROTO_RAW 0 -+#define NFC_SOCKPROTO_LLCP 1 -+#define NFC_SOCKPROTO_MAX 2 -+ -+#define NFC_HEADER_SIZE 1 -+ -+/** -+ * Pseudo-header info for raw socket packets -+ * First byte is the adapter index -+ * Second byte contains flags -+ * - 0x01 - Direction (0=RX, 1=TX) -+ * - 0x02-0x80 - Reserved -+ **/ -+#define NFC_LLCP_RAW_HEADER_SIZE 2 -+#define NFC_LLCP_DIRECTION_RX 0x00 -+#define NFC_LLCP_DIRECTION_TX 0x01 -+ -+#endif /*__LINUX_NFC_H */ -Index: b/plugins/mifare.c -=================================================================== ---- a/plugins/mifare.c -+++ b/plugins/mifare.c -@@ -29,7 +29,11 @@ - #include - - #include -+#ifdef HAVE_LINUX_NFC_H - #include -+#else -+#include "../src/linux-nfc.h" -+#endif - - #include - #include -Index: b/plugins/p2p.c -=================================================================== ---- a/plugins/p2p.c -+++ b/plugins/p2p.c -@@ -30,7 +30,11 @@ - #include - - #include -+#ifdef HAVE_LINUX_NFC_H - #include -+#else -+#include "../src/linux-nfc.h" -+#endif - - #include - #include -Index: b/plugins/handover.c -=================================================================== ---- a/plugins/handover.c -+++ b/plugins/handover.c -@@ -29,7 +29,11 @@ - #include - - #include -+#ifdef HAVE_LINUX_NFC_H - #include -+#else -+#include "../src/linux-nfc.h" -+#endif - - #include - #include -Index: b/plugins/nfctype1.c -=================================================================== ---- a/plugins/nfctype1.c -+++ b/plugins/nfctype1.c -@@ -29,7 +29,11 @@ - #include - - #include -+#ifdef HAVE_LINUX_NFC_H - #include -+#else -+#include "../src/linux-nfc.h" -+#endif - - #include - #include -Index: b/plugins/nfctype2.c -=================================================================== ---- a/plugins/nfctype2.c -+++ b/plugins/nfctype2.c -@@ -29,7 +29,11 @@ - #include - - #include -+#ifdef HAVE_LINUX_NFC_H - #include -+#else -+#include "../src/linux-nfc.h" -+#endif - - #include - #include -Index: b/plugins/nfctype3.c -=================================================================== ---- a/plugins/nfctype3.c -+++ b/plugins/nfctype3.c -@@ -29,7 +29,11 @@ - #include - - #include -+#ifdef HAVE_LINUX_NFC_H - #include -+#else -+#include "../src/linux-nfc.h" -+#endif - - #include - #include -Index: b/plugins/nfctype4.c -=================================================================== ---- a/plugins/nfctype4.c -+++ b/plugins/nfctype4.c -@@ -30,7 +30,11 @@ - #include - - #include -+#ifdef HAVE_LINUX_NFC_H - #include -+#else -+#include "../src/linux-nfc.h" -+#endif - - #include - #include -Index: b/plugins/npp.c -=================================================================== ---- a/plugins/npp.c -+++ b/plugins/npp.c -@@ -29,7 +29,11 @@ - #include - - #include -+#ifdef HAVE_LINUX_NFC_H - #include -+#else -+#include "../src/linux-nfc.h" -+#endif - - #include - #include -Index: b/plugins/snep.c -=================================================================== ---- a/plugins/snep.c -+++ b/plugins/snep.c -@@ -29,7 +29,11 @@ - #include - - #include -+#ifdef HAVE_LINUX_NFC_H - #include -+#else -+#include "../src/linux-nfc.h" -+#endif - - #include - #include -Index: b/plugins/snep-core.c -=================================================================== ---- a/plugins/snep-core.c -+++ b/plugins/snep-core.c -@@ -29,7 +29,11 @@ - #include - - #include -+#ifdef HAVE_LINUX_NFC_H - #include -+#else -+#include "../src/linux-nfc.h" -+#endif - - #include - #include -Index: b/plugins/snep-validation.c -=================================================================== ---- a/plugins/snep-validation.c -+++ b/plugins/snep-validation.c -@@ -29,7 +29,11 @@ - #include - - #include -+#ifdef HAVE_LINUX_NFC_H - #include -+#else -+#include "../src/linux-nfc.h" -+#endif - - #include - #include diff --git a/package/neard/neard.mk b/package/neard/neard.mk index c3466e6..056875c 100644 --- a/package/neard/neard.mk +++ b/package/neard/neard.mk @@ -4,7 +4,7 @@ # ############################################################# -NEARD_VERSION = 0.9 +NEARD_VERSION = 0.11 NEARD_SITE = $(BR2_KERNEL_MIRROR)/linux/network/nfc NEARD_LICENSE = GPLv2 NEARD_LICENSE_FILES = COPYING