From patchwork Mon Oct 12 21:19:15 2009 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Hauke Mehrtens X-Patchwork-Id: 53214 Received: from vger.kernel.org (vger.kernel.org [209.132.176.167]) by demeter.kernel.org (8.14.2/8.14.2) with ESMTP id n9CLU8Ja025169 for ; Mon, 12 Oct 2009 21:30:09 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1758307AbZJLVUp (ORCPT ); Mon, 12 Oct 2009 17:20:45 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1758279AbZJLVUp (ORCPT ); Mon, 12 Oct 2009 17:20:45 -0400 Received: from server19320154104.serverpool.info ([193.201.54.104]:47121 "EHLO hauke-m.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1758299AbZJLVUn (ORCPT ); Mon, 12 Oct 2009 17:20:43 -0400 Received: from localhost (localhost [127.0.0.1]) by hauke-m.de (Postfix) with ESMTP id B0E8A820F; Mon, 12 Oct 2009 23:19:37 +0200 (CEST) Received: from hauke-m.de ([127.0.0.1]) by localhost (hauke-m.de [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id hMM4uWIo5S7c; Mon, 12 Oct 2009 23:19:33 +0200 (CEST) Received: from localhost.localdomain (dyndsl-085-016-164-212.ewe-ip-backbone.de [85.16.164.212]) by hauke-m.de (Postfix) with ESMTPSA id 8C7358210; Mon, 12 Oct 2009 23:19:22 +0200 (CEST) From: Hauke Mehrtens To: lrodriguez@atheros.com Cc: linux-wireless@vger.kernel.org, Hauke Mehrtens Subject: [PATCH 6/9] [compat-2.6] Fix build with kernel < 2.6.27 Date: Mon, 12 Oct 2009 23:19:15 +0200 Message-Id: <1255382358-20760-8-git-send-email-hauke@hauke-m.de> X-Mailer: git-send-email 1.6.2.1 In-Reply-To: <1255382358-20760-1-git-send-email-hauke@hauke-m.de> References: <1255382358-20760-1-git-send-email-hauke@hauke-m.de> Sender: linux-wireless-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org diff --git a/compat/compat-2.6.27.h b/compat/compat-2.6.27.h index 2543482..8cc6c22 100644 --- a/compat/compat-2.6.27.h +++ b/compat/compat-2.6.27.h @@ -163,6 +163,26 @@ static inline void list_splice_tail_init(struct list_head *list, extern unsigned int mmc_align_data_size(struct mmc_card *, unsigned int); extern unsigned int sdio_align_size(struct sdio_func *func, unsigned int sz); +/** Include iw_handler.h before we redefine some methods **/ +#include + +#define iwe_stream_add_value(info, event, value, ends, iwe, event_len) iwe_stream_add_value(event, value, ends, iwe, event_len) +#define iwe_stream_add_point(info, stream, ends, iwe, extra) iwe_stream_add_point(stream, ends, iwe, extra) +#define iwe_stream_add_event(info, stream, ends, iwe, event_len) iwe_stream_add_event(stream, ends, iwe, event_len) + +/* Flags available in struct iw_request_info */ +#define IW_REQUEST_FLAG_COMPAT 0x0001 /* Compat ioctl call */ + +static inline int iwe_stream_lcp_len(struct iw_request_info *info) +{ +#ifdef CONFIG_COMPAT + if (info->flags & IW_REQUEST_FLAG_COMPAT) + return IW_EV_COMPAT_LCP_LEN; +#endif + return IW_EV_LCP_LEN; +} +/** source: include/net/iw_handler.h **/ + #endif /* (LINUX_VERSION_CODE < KERNEL_VERSION(2,6,27)) */ #endif /* LINUX_26_27_COMPAT_H */