On Wed, Jun 14, 2017 at 04:30:37PM +1000, Tobin C. Harding wrote: > Currently we are in the process of replacing the WEXT interface with > the cfg80211 API. WEXT code is currently within a sub directory and > not included in the module build. > > The driver is designed with various layers of abstraction; > > - The main layer contains the net_device_ops callbacks. Also included > in this layer is the rx/tx code. > - The SDIO layer contains code specific to the SDIO hardware. > - The cfg80211 layer contains the implementation of the cfg80211 > configuration API. > - The HIF (Host InterFace) layer provides driver policy and interfaces > between the cfg80211 layer and the FIL. > - The FIL (Firmware Interface Layer) provides mechanism for > interfacing with the firmware. > > The firmware interface is derived from the WEXT driver, if we > write code to interface with the firmware as a separate abstraction > layer then the cfg80211 code and the rest of the driver functionality > can be written cleanly from scratch. > > The separate layers are restricted to calls as indicated by the > following diagram, A --> B indicates layer A calls functions in layer B. > > ----> main (tx/rx) <---> SDIO > | > | | > | | > v v > > cfg80211 <---> HIF > > | > | > v > > FIL > > Implementation status is outlined in README.rst. A todo list is > included in TODO.rst. > > Add initial cfg80211 implementation. > > Signed-off-by: Tobin C. Harding <me@xxxxxxxx> > --- > drivers/staging/ks7010/Kconfig | 2 + > drivers/staging/ks7010/Makefile | 28 +- > drivers/staging/ks7010/README.rst | 91 +++ > drivers/staging/ks7010/TODO.rst | 30 + > drivers/staging/ks7010/cfg80211.c | 981 +++++++++++++++++++++++++++ > drivers/staging/ks7010/cfg80211.h | 40 ++ > drivers/staging/ks7010/common.h | 33 + > drivers/staging/ks7010/eap.h | 73 ++ > drivers/staging/ks7010/fil.c | 1294 ++++++++++++++++++++++++++++++++++++ > drivers/staging/ks7010/fil.h | 559 ++++++++++++++++ > drivers/staging/ks7010/fil_types.h | 851 ++++++++++++++++++++++++ > drivers/staging/ks7010/hif.c | 505 ++++++++++++++ > drivers/staging/ks7010/hif.h | 202 ++++++ > drivers/staging/ks7010/ks7010.h | 309 +++++++++ > drivers/staging/ks7010/main.c | 337 ++++++++++ > drivers/staging/ks7010/rx.c | 130 ++++ > drivers/staging/ks7010/sdio.c | 691 +++++++++++++++++++ > drivers/staging/ks7010/sdio.h | 37 ++ > drivers/staging/ks7010/tx.c | 170 +++++ > 19 files changed, 6362 insertions(+), 1 deletion(-) > create mode 100644 drivers/staging/ks7010/README.rst > create mode 100644 drivers/staging/ks7010/TODO.rst > create mode 100644 drivers/staging/ks7010/cfg80211.c > create mode 100644 drivers/staging/ks7010/cfg80211.h > create mode 100644 drivers/staging/ks7010/common.h > create mode 100644 drivers/staging/ks7010/eap.h > create mode 100644 drivers/staging/ks7010/fil.c > create mode 100644 drivers/staging/ks7010/fil.h > create mode 100644 drivers/staging/ks7010/fil_types.h > create mode 100644 drivers/staging/ks7010/hif.c > create mode 100644 drivers/staging/ks7010/hif.h > create mode 100644 drivers/staging/ks7010/ks7010.h > create mode 100644 drivers/staging/ks7010/main.c > create mode 100644 drivers/staging/ks7010/rx.c > create mode 100644 drivers/staging/ks7010/sdio.c > create mode 100644 drivers/staging/ks7010/sdio.h > create mode 100644 drivers/staging/ks7010/tx.c > > diff --git a/drivers/staging/ks7010/Kconfig b/drivers/staging/ks7010/Kconfig > index 437b928..71f2026 100644 > --- a/drivers/staging/ks7010/Kconfig > +++ b/drivers/staging/ks7010/Kconfig > @@ -1,5 +1,7 @@ > config KS7010 > tristate "KeyStream KS7010 SDIO support" > + depends on CFG80211 > + depends on MMC tabs vs. spaces??? > ---help--- > This is a driver for KeyStream KS7010 based SDIO WIFI cards. It is > found on at least later Spectec SDW-821 (FCC-ID "S2Y-WLAN-11G-K" only, > diff --git a/drivers/staging/ks7010/Makefile b/drivers/staging/ks7010/Makefile > index 9444885..1cd570e 100644 > --- a/drivers/staging/ks7010/Makefile > +++ b/drivers/staging/ks7010/Makefile > @@ -1 +1,27 @@ > -# Makefile intentionally left blank > +#------------------------------------------------------------------------- > +# Driver for KeyStream wireless LAN cards. > +# > +# Copyright (C) 2005-2008 KeyStream Corp. > +# Copyright (C) 2009 Renesas Technology Corp. > +# Copyright (C) 2017 Tobin C. Harding. > +# > +# This program is free software; you can redistribute it and/or modify > +# it under the terms of the GNU General Public License version 2 as > +# published by the Free Software Foundation. > +# > +# This program is distributed in the hope that it will be useful, but > +# WITHOUT ANY WARRANTY; without even the implied warranty of > +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU > +# General Public License for more details. It's a makefile, not a "program", so why is all of this here? > +#------------------------------------------------------------------------- > + > +ccflags-y += -DDEBUG > + > +obj-$(CONFIG_KS7010) += ks7010.o > +ks7010-y += main.o > +ks7010-y += tx.o > +ks7010-y += rx.o > +ks7010-y += sdio.o > +ks7010-y += cfg80211.o > +ks7010-y += fil.o > +ks7010-y += hif.o Wait, is this a whole new driver for this device? Why not just put it in a new directory and just forget about the old one entirely? And testing it would be good to do :) thanks, greg k-h _______________________________________________ devel mailing list devel@xxxxxxxxxxxxxxxxxxxxxx http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel