From owner-freebsd-current@FreeBSD.ORG Wed Mar 7 15:38:47 2012 Return-Path: Delivered-To: freebsd-current@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 0C0AF106566C; Wed, 7 Mar 2012 15:38:47 +0000 (UTC) (envelope-from iwasaki@jp.FreeBSD.org) Received: from locore.org (ns01.locore.org [218.45.21.227]) by mx1.freebsd.org (Postfix) with ESMTP id 926078FC0C; Wed, 7 Mar 2012 15:38:45 +0000 (UTC) Received: from localhost (celeron.v4.locore.org [192.168.0.10]) by locore.org (8.14.5/8.14.5/iwasaki) with ESMTP/inet id q27Fcigv022293; Thu, 8 Mar 2012 00:38:44 +0900 (JST) (envelope-from iwasaki@jp.FreeBSD.org) Date: Thu, 08 Mar 2012 00:38:44 +0900 (JST) Message-Id: <20120308.003844.08316346.iwasaki@jp.FreeBSD.org> To: bschmidt@freebsd.org From: Mitsuru IWASAKI In-Reply-To: <201203062005.15276.bschmidt@freebsd.org> References: <201203052314.22050.bschmidt@freebsd.org> <20120307.023046.27956263.iwasaki@jp.FreeBSD.org> <201203062005.15276.bschmidt@freebsd.org> X-Mailer: Mew version 3.3 on Emacs 20.7 / Mule 4.0 (HANANOEN) Mime-Version: 1.0 Content-Type: Text/Plain; charset=us-ascii Content-Transfer-Encoding: 7bit Cc: adrian@freebsd.org, freebsd-current@freebsd.org, freebsd-wireless@freebsd.org Subject: Re: patches for if_iwi and wlan for WEP mode X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 07 Mar 2012 15:38:47 -0000 > > In RELENG_7, data frame is transmitted by iwi_tx_start() like this. > > > > ether_output > > ether_output_frame > > IFQ_HANDOFF/IFQ_HANDOFF_ADJ > > if_start > > iwi_start > > iwi_tx_start > > > > After 8.0-RELEASE, device specific if_transmit() is called via net80211 layer. > > > > ether_output > > ether_output_frame > > if_transmit > > IFQ_HANDOFF/IFQ_HANDOFF_ADJ > > if_start > > ieee80211_start > > parent->if_transmit(ie. iwi_transmit()) > > > > There was not if_transmit method in iwi(4), so I add it. > > On if_qflush(), CURRENT kernel complains that `transmit and qflush > > must both either be set or both be NULL' from if.c. > > I wrote iwi_qflush(), but actually never tested it... > > Hmm, it still is the case for >= 8 afaik, there is a default > if_transmit() which is used for all wireless drivers which seems to > work pretty well. That's why I'm wondering, iwi(4) would be the first > driver to have it's own if_transmit() function. I'm not aware of any > technical reason for adding one, or did I miss something? If not I'd > rather not have one added, for sake of consistency. By your this comment, I noticed that my understanding on iwi_start() call stack > 8.0 was wrong a bit, correct one is like this; ether_output ether_output_frame if_transmit IFQ_HANDOFF/IFQ_HANDOFF_ADJ if_start ieee80211_start parent->if_transmit(ie. if_transmit()) IFQ_HANDOFF/IFQ_HANDOFF_ADJ if_start iwi_start iwi_start_locked iwi_tx_start So iwi_transmit and iwi_qflush would not be necessary. Today's version of patches at: http://people.freebsd.org/~iwasaki/iwi/iwi-20120307.diff This would be the final version I hope. Thanks!