From owner-freebsd-wireless@freebsd.org Sat Sep 2 03:45:23 2017 Return-Path: Delivered-To: freebsd-wireless@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 1CCCAE1CC9B for ; Sat, 2 Sep 2017 03:45:23 +0000 (UTC) (envelope-from khanzf@gmail.com) Received: from mail-pf0-x22f.google.com (mail-pf0-x22f.google.com [IPv6:2607:f8b0:400e:c00::22f]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id E7BF271D55 for ; Sat, 2 Sep 2017 03:45:22 +0000 (UTC) (envelope-from khanzf@gmail.com) Received: by mail-pf0-x22f.google.com with SMTP id g13so5213689pfm.2 for ; Fri, 01 Sep 2017 20:45:22 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc; bh=riyYTWL5Ah8GdN5VMrnlejzQLHp/LYIDQaGl8jKghG8=; b=HW1ijUPL4yhh3UgFMT+NsEQKdtBHZd+c8jRFpE128Y51nK40wOMcpA6zz0/l4OGSFt 7kcDekMWh9Ipl2rVOGQVJQNcufoHulP4/385XSt2HcyRVM9OFVN6wqqFcvJDCQ3SZmpD ihljoR6B/Gl0uvJKTL8Lkmw8CoFC/htZ5AvvZOVgTm74OseS5oUBu6hlDco29FG2dFFc Q2onr/TGWKkxYQGra7lJxXdghaU2CG2nJH5r+gQb5o9DEyCMOvXX2Nw13VThTg4AU1Ji A6SW4xV/7NSp7Op7lId86PU+M+WDtzEwqPW/n0kP68ko+N7eaN1rL07ZE9eawWzti0lp 7P+Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc; bh=riyYTWL5Ah8GdN5VMrnlejzQLHp/LYIDQaGl8jKghG8=; b=iM41KpoQQrUIBkkFXlVwKTjj49UeeKYhXxCjKKmuRA3MQSa+1P8xdbVwh4XM4pLLsQ IEBe+ryVTyUcLe40ppSf1d/e1n/UfVvtN4NN9+IS0hm1e8K/XvkKKGMSPYbD/Snb3JXV IZV9MCHjvrt9nTdt0j+qf7K+pMjLe/tUeTcVZ/D2mLDrI/F3KX2cNISXDrJO57divL5K fpjyWHE5qpAkFhfDTarnWhnYamFTTaB/NWxMmr8hVOyf8pdh+J5pH94huxHYLbzRxsXx aroYXCqSkGeHVI2OyFNmWYuvK82nE8E9SycZUnqcfea+aL2zlUg0NrCTbgNc4iLjbNHk 5tkQ== X-Gm-Message-State: AHPjjUi/5bQXEBoUYn0QmJBfu/UN0L2KuqZmdZjiOXX1ef093lnIEY5d lq9vx3KfgtrG5KxQ7J5vJWwc95aWkXT74Uo= X-Google-Smtp-Source: ADKCNb5MThVUbraVP9C9jtfxBY+b2hBrGyfkLAKFiiPjoyKRvwrsayNVqdxIM6PozrHjUyK/V2SWJ01DM1kQOdLellA= X-Received: by 10.99.0.74 with SMTP id 71mr4846628pga.304.1504323922231; Fri, 01 Sep 2017 20:45:22 -0700 (PDT) MIME-Version: 1.0 Received: by 10.100.183.208 with HTTP; Fri, 1 Sep 2017 20:45:01 -0700 (PDT) In-Reply-To: <68.D0.25924.050D9A95@dnvrco-omsmta02> References: <68.D0.25924.050D9A95@dnvrco-omsmta02> From: Farhan Khan Date: Fri, 1 Sep 2017 23:45:01 -0400 Message-ID: Subject: Re: Adding wifi source code To: Thomas Mueller Cc: freebsd-wireless@freebsd.org Content-Type: text/plain; charset="UTF-8" X-Content-Filtered-By: Mailman/MimeDel 2.1.23 X-BeenThere: freebsd-wireless@freebsd.org X-Mailman-Version: 2.1.23 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: Sat, 02 Sep 2017 03:45:23 -0000 Thomas, I was planning on also porting over the Atheros AR9271 driver from NetBSD (athn(4) /usr/src/sys/dev/usb/if_athn_usb.c), but not until I finish the current device I am working on. It might not be for a while though. There is likely a lot of shared code with ath(4) on FreeBSD (/usr/src/sys/dev/athn). NetBSD seems to separate all code between USB and PCI, whereas FreeBSD combines drivers. Let me know if I can help out, as I already own this device and would be willing to test out code or troubleshoot with you. I am currently working on another driver from Linux to FreeBSD. The core concepts are the same, but a lot of code is in different order. FreeBSD drivers have an attach function that assign function pointers to the softc struct. The Linux equivalent is in DRIVERNAME_ops. In my case, this: http://src.illumos.org/source/xref/linux-master/drivers/net/wireless/realtek/rtlwifi/rtl8188ee/sw.c#224 . Hope this helps. But yes, would love to work on AR9271! -- Farhan Khan PGP Fingerprint: 782F 342B 5B08 0D2F F4E8 82C3 FFA1 CAE1 6536 51CA On Fri, Sep 1, 2017 at 5:25 PM, Thomas Mueller wrote: > from Tecno Linux: > > > Hello, I have the source code of my wireless driver i extract it from the > > linux kernel how can i compile that source code or i have another option > my > > wireless driver is a realtek rtl8723be wifi > > I have similar question, but the source code is from NetBSD and the > wireless chip is Atheros AR9271. > > I also have similar question regarding Ethernet Realtek 8111E re driver, > works in NetBSD but not FreeBSD (11.1-STABLE and HEAD) on computer in > question. > > Is there online handbook/documentation on writing device drivers or > porting from Linux or NetBSD? > > Tom > > _______________________________________________ > freebsd-wireless@freebsd.org mailing list > https://lists.freebsd.org/mailman/listinfo/freebsd-wireless > To unsubscribe, send any mail to "freebsd-wireless-unsubscribe@freebsd.org > " >