From patchwork Tue Nov 25 14:46:57 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jouni Malinen X-Patchwork-Id: 414727 Return-Path: X-Original-To: patchwork-incoming@ozlabs.org Delivered-To: patchwork-incoming@ozlabs.org Received: from maxx.maxx.shmoo.com (maxx.shmoo.com [205.134.188.171]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 136341401DD for ; Wed, 26 Nov 2014 01:47:21 +1100 (AEDT) Received: from localhost (localhost [127.0.0.1]) by maxx.maxx.shmoo.com (Postfix) with ESMTP id E973317C053; Tue, 25 Nov 2014 09:47:19 -0500 (EST) X-Virus-Scanned: amavisd-new at maxx.shmoo.com Received: from maxx.maxx.shmoo.com ([127.0.0.1]) by localhost (maxx.shmoo.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id ZHxbjjUE+W5f; Tue, 25 Nov 2014 09:47:19 -0500 (EST) Received: from maxx.shmoo.com (localhost [127.0.0.1]) by maxx.maxx.shmoo.com (Postfix) with ESMTP id C372017C077; Tue, 25 Nov 2014 09:47:10 -0500 (EST) X-Original-To: mailman-post+hostap@maxx.shmoo.com Delivered-To: mailman-post+hostap@maxx.shmoo.com Received: from localhost (localhost [127.0.0.1]) by maxx.maxx.shmoo.com (Postfix) with ESMTP id 8FF9417C077 for ; Tue, 25 Nov 2014 09:47:09 -0500 (EST) X-Virus-Scanned: amavisd-new at maxx.shmoo.com Received: from maxx.maxx.shmoo.com ([127.0.0.1]) by localhost (maxx.shmoo.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id gnN7aKgA1yCP for ; Tue, 25 Nov 2014 09:47:02 -0500 (EST) Received: from li674-96.members.linode.com (mail.w1.fi [212.71.239.96]) by maxx.maxx.shmoo.com (Postfix) with ESMTP id 942B017C053 for ; Tue, 25 Nov 2014 09:47:02 -0500 (EST) Received: from jm (188-67-125-155.bb.dnainternet.fi [188.67.125.155]) by li674-96.members.linode.com (Postfix) with ESMTPSA id 8C1C91119F for ; Tue, 25 Nov 2014 14:46:58 +0000 (UTC) Received: by jm (sSMTP sendmail emulation); Tue, 25 Nov 2014 16:46:57 +0200 Date: Tue, 25 Nov 2014 16:46:57 +0200 From: Jouni Malinen To: hostap@lists.shmoo.com Subject: Re: Regression in hostap build using HS20 and proxyarp Message-ID: <20141125144657.GA9409@w1.fi> Mail-Followup-To: hostap@lists.shmoo.com References: MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.21 (2010-09-15) X-BeenThere: hostap@lists.shmoo.com X-Mailman-Version: 2.1.11 Precedence: list List-Id: HostAP Project List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: hostap-bounces@lists.shmoo.com Errors-To: hostap-bounces@lists.shmoo.com On Tue, Nov 25, 2014 at 02:32:31PM +0000, Peer, Ilan wrote: > I tried building hwsim with the default example configuration files using the latest master, but this failed the hostapd compilation with the below error. > > I tried resolving this by moving includes, changing include order etc. without much success. Apparently this is a known issue (for example see http://www.redhat.com/archives/libvir-list/2013-January/msg01084.html) Yeah, linux/*.h include in user space is often an issue.. Does this work for you? I guess I could also make IPv6 ProxyARP things conditional on CONFIG_IPV6=y to make it easier to work around this on systems that do not have suitable IPv6 header files. diff --git a/src/ap/ndisc_snoop.c b/src/ap/ndisc_snoop.c index b6faeed..d397981 100644 --- a/src/ap/ndisc_snoop.c +++ b/src/ap/ndisc_snoop.c @@ -7,8 +7,8 @@ */ #include "utils/includes.h" -#include -#include +#include "netinet/ip6.h" +#include "netinet/icmp6.h" #include "utils/common.h" #include "l2_packet/l2_packet.h" @@ -24,8 +24,8 @@ struct ip6addr { }; struct icmpv6_ndmsg { - struct ipv6hdr ipv6h; - struct icmp6hdr icmp6h; + struct ip6_hdr ipv6h; + struct icmp6_hdr icmp6h; struct in6_addr target_addr; u8 opt_type; u8 len; @@ -98,7 +98,7 @@ static void handle_ndisc(void *ctx, const u8 *src_addr, const u8 *buf, if (msg->opt_type != SOURCE_LL_ADDR) return; - saddr = &msg->ipv6h.saddr; + saddr = &msg->ipv6h.ip6_src; if (!(saddr->s6_addr32[0] == 0 && saddr->s6_addr32[1] == 0 && saddr->s6_addr32[2] == 0 && saddr->s6_addr32[3] == 0)) { if (len < ETH_HLEN + sizeof(*msg) + ETH_ALEN)