From owner-freebsd-wireless@FreeBSD.ORG Tue Jun 7 22:01:53 2011 Return-Path: Delivered-To: freebsd-wireless@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id EE782106564A; Tue, 7 Jun 2011 22:01:53 +0000 (UTC) (envelope-from sendtomatt@gmail.com) Received: from mail-px0-f172.google.com (mail-px0-f172.google.com [209.85.212.172]) by mx1.freebsd.org (Postfix) with ESMTP id B73A98FC0A; Tue, 7 Jun 2011 22:01:53 +0000 (UTC) Received: by pxi6 with SMTP id 6so3597262pxi.17 for ; Tue, 07 Jun 2011 15:01:53 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:message-id:date:from:user-agent:mime-version:to :cc:subject:references:in-reply-to:content-type :content-transfer-encoding; bh=t1fIEyPsVdb4DHbqBtF7in4DnaKGkgBDaMNfSdyCink=; b=ZSzVUoX7VemPJFqO9mhNofWxtrtgCtbQ9P0fIdk4G9WwkpB0kq7RE3cbcU+36aI6T7 ApaOPC36zh/6jgI4paDsL0l5Kdwuq0aN+SEa//J4CN/AF9PvHjYY4w4D3w48drkJlaIS YQusCwwc6B4UHuvz0CGznj/Hm87DjoKRUU3lw= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=message-id:date:from:user-agent:mime-version:to:cc:subject :references:in-reply-to:content-type:content-transfer-encoding; b=LLwm5hyJW509+PNWyB/udnAsH/qs4pFL9pJTEa/8GB9Z2WIv3fMb8GNWzhW4iTXWKx sdQfudJAQWnV/AqLcI+CtiYEZH56vYD7sLDC13uQilWfsRT8EjMsEAW9gKrIXRWIfkzJ 8htat6yLUIBNyNjbHP4xUW92yMMYWT3ngtvqc= Received: by 10.142.201.7 with SMTP id y7mr189396wff.82.1307484113206; Tue, 07 Jun 2011 15:01:53 -0700 (PDT) Received: from sidhe.local ([75.101.87.90]) by mx.google.com with ESMTPS id k9sm589546pbc.86.2011.06.07.15.01.50 (version=SSLv3 cipher=OTHER); Tue, 07 Jun 2011 15:01:51 -0700 (PDT) Message-ID: <4DEE9FCA.7030302@gmail.com> Date: Tue, 07 Jun 2011 15:01:46 -0700 From: Matt User-Agent: Mozilla/5.0 (X11; U; FreeBSD amd64; en-US; rv:1.9.2.17) Gecko/20110502 Thunderbird/3.1.10 MIME-Version: 1.0 To: bschmidt@freebsd.org References: <4DD365A2.3090106@gmail.com> <20110606022257.39093142.ray@ddteam.net> <4DED769A.6040405@gmail.com> <201106070811.56236.bschmidt@freebsd.org> In-Reply-To: <201106070811.56236.bschmidt@freebsd.org> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: freebsd-wireless@freebsd.org Subject: Re: Ralink RT3090/RT2860 X-BeenThere: freebsd-wireless@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Discussions of 802.11 stack, tools device driver development." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 07 Jun 2011 22:01:54 -0000 On 06/06/11 23:11, Bernhard Schmidt wrote: > On Tuesday, June 07, 2011 02:53:46 Matt wrote: >> On 06/05/11 16:22, Aleksandr Rybalko wrote: >>> Hi folks, >>> >>> On Sun, 05 Jun 2011 15:24:52 -0700 >>> Matt wrote: >>> >>>> On 05/18/11 00:36, Adrian Chadd wrote: >>>>> On 18 May 2011 15:02, Sergey V. Dyatko >>>>> wrote: >>>>> >>>>>> As far I know Alexandr is too busy now (ported fbsd into one of >>>>>> d-link device). Hi have plans port ral code from openbsd. IIRC it >>>>>> was discussed not so long ago, in current@ >>>>> This thread reads to me like "hi, would someone like to pick up >>>>> Alex's work, liase with Alex/Bernhard, and bring the code up to >>>>> scratch so we can commit it to FreeBSD". >>>>> >>>>> Matt, how's your C? :) >>>>> >>>>> >>>>> Adrian >>>>> >>>> I've successfully got Alexandr's code worked into the Ral driver. >>>> This mainly involved some changes to if_ral_pci.c, renaming some >>>> softc stuff and pulling PCI code out of rt2860_attach. >>> Must say, that code not mine, wrote by Alexander Egorenkov (based on >>> OpenBSD one) + OpenBSD part for 3090 (but seems w/o LEDs :) ) and plus >>> my part for wireless embedded into SoC like RT3052F. >>> >>>> It's stable so far, WPA2 works fine as does Host AP etc (haven't >>>> tried with encryption). I haven't tested AHdemo, I assume monitor >>>> mode works. >>>> >>>> I want to eventually go through and place some chip specific fixes >>>> for 3090 etc., and possibly compare functions between different >>>> sources and make sure we're doing it right. >>>> >>>> Some questions: >>>> 1) If I kldunload if_ral while associated and flood pinging, I get >>>> "no route" for a while and then a page fault (only bug I've found so >>>> far). I assume this is something dumb I've done during detach? >>>> >>>> 2) My LED does not work. I have this in a Thinkpad WWAN slot, which >>>> are known to have issues with LED on some chips. A broadcom 4321 did >>>> activate the led in this slot. Can anyone confirm if they had a >>>> working LED using Alexandr's RT2860 stand alone driver? Or does work >>>> on LED code need to occur? >>>> >>>> Cheers, I'll remove my ugly printfs and post a patch or tarball later >>>> today. >>> Anyway, we (Adrian, Bernhard, PseudoCylon and me) discuss what there is >>> preferred to port current version of OpenBSD `ral` driver, and keep it >>> sync in future. But only one problem here, we all don't have time >>> right now for that :) >>> >>>> Matt >>> I hope someone found a time for it :) >>> >>> WBW >> Well, in anycase here is the patch I made for Ral. If no one wants to >> work on trying to port OpenBSD ral, I can try, but I am still learning >> very much! >> >> http://pastebin.com/GeAGVjtR >> >> Please add manually rt2860.c to Makefile @ /usr/src/sys/modules/ral/Makefile >> >> Note about patch, it's still alpha quality in that it has a known bug >> (do not kldunload while interface is running!) and it is largely >> untested. Changes include softc, pci code& all functions put in >> monolithic file (to help compare against OpenBSD ral, mainly). They are >> in the wrong order for now, however. Ultimate plan was to compare >> side-by-side with OpenBSD ral to assist porting. >> >> There is still an "ecosystem" of includes per rt2860 original, didn't >> get around to combining them. > Doesn't look bad at first glance, thx! At least the if_ral_pci.c > part looks like I'd have done it. ;) > > Do you have some unified diff also? I'd take a closer look then, > maybe we can get that into the tree. > I'll make unified diffs tonight...that's diff -u oldfile newfile >> bigpatch.patch, right? I'll keep hacking some changes into it...it sounds like LEDs never worked on x86/amd64 non-embedded platforms? It complains about extension channels some as well, so I may see what that's about. Thanks all! Matt In the Hat