History log of /linux-master/drivers/staging/wlan-ng/p80211hdr.h
Revision Date Author Comments
# 5d88ce50 17-May-2023 Bagas Sanjaya <bagasdotme@gmail.com>

drivers: staging: wlan-ng: Remove GPL/MPL boilerplate

Remove the license boilerplate as there is already SPDX license
identifier added in b24413180f5600 ("License cleanup: add SPDX GPL-2.0
license identifier to files with no license") which fulfills the same
intention as the boilerplate.

Cc: Dan Carpenter <error27@gmail.com>
Cc: Kate Stewart <kstewart@linuxfoundation.org>
Cc: Philippe Ombredanne <pombredanne@nexb.com>
Cc: Thomas Gleixner <tglx@linutronix.de>
Reviewed-by: Simon Horman <simon.horman@corigine.com>
Signed-off-by: Bagas Sanjaya <bagasdotme@gmail.com>
Link: https://lore.kernel.org/r/20230517090418.1093091-4-bagasdotme@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>


# 8ffd91d9 28-Aug-2021 Aldas Taraškevičius <aldas60@gmail.com>

staging: wlan-ng: Remove filenames from files

Fix checkpatch warnings about having filenames in the files.

Signed-off-by: Aldas Taraškevičius <aldas60@gmail.com>
Link: https://lore.kernel.org/r/20210828195324.68-1-aldas60@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>


# 65bbdabe 27-Aug-2021 Aakash Hemadri <aakashhemadri123@gmail.com>

staging: wlan-ng: fix invalid assignment warning

p80211_hdr->frame_control is u16, change to __le16
to satisfy sparse warning:

wlan-ng/prism2sta.c:253:43: warning: invalid assignment: |=
wlan-ng/prism2sta.c:253:43: left side has type unsigned short
wlan-ng/prism2sta.c:253:43: right side has type restricted __le16

Fixes: 6277fbfdd29c ("staging: wlan-ng: Remove pointless a3/a4 union")
Reviewed-by: Kees Cook <keescook@chromium.org>
Signed-off-by: Aakash Hemadri <aakashhemadri123@gmail.com>
Link: https://lore.kernel.org/r/20210828042949.2276341-1-aakashhemadri123@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>


# 86a0727b 19-Aug-2021 Kees Cook <keescook@chromium.org>

staging: wlan-ng: Avoid duplicate header in tx/rx frames

Instead of open-coding the same header details in the tx/rx frames,
directly include the actual struct. Rename associated variables to the
more verbose of the two versions. This also has the benefit of being
able to replace a field-spanning memcpy() with a direct assignment,
helping clear the way for coming FORTIFY_SOURCE improvements.

"diffoscope" reports no object code differences after this change,
excepting the selection of different registers when switching from
memcpy() to direct assignment:

--- drivers/staging/wlan-ng/prism2usb.o.before
+++ drivers/staging/wlan-ng/prism2usb.o.after
├── objdump --line-numbers --disassemble --demangle --reloc --no-show-raw-insn --section=.text {}
│ @@ -4887,24 +4887,24 @@
│ sub %rdi,%rcx
│ add $0x3c,%ecx
│ shr $0x3,%ecx
│ rep stos %rax,%es:(%rdi)
│ mov $0x8,%eax
│ movl $0x123,0x23e(%rbx)
│ mov %ax,0x244(%rbx)
│ - mov (%rdx),%rcx
│ - mov %rcx,0x246(%rbx)
│ - mov 0x8(%rdx),%rcx
│ - mov %rcx,0x24e(%rbx)
│ - mov 0x10(%rdx),%rcx
│ - mov %rcx,0x256(%rbx)
│ - mov 0x18(%rdx),%ecx
│ - mov %ecx,0x25e(%rbx)
│ - movzwl 0x1c(%rdx),%edx
│ - mov %dx,0x262(%rbx)
│ + mov (%rdx),%rax
│ + mov %rax,0x246(%rbx)
│ + mov 0x8(%rdx),%rax
│ + mov %rax,0x24e(%rbx)
│ + mov 0x10(%rdx),%rax
│ + mov %rax,0x256(%rbx)
│ + mov 0x18(%rdx),%eax
│ + mov %eax,0x25e(%rbx)
│ + movzwl 0x1c(%rdx),%eax
│ + mov %ax,0x262(%rbx)
│ cmpq $0x0,0x0(%rbp)
│ movzwl 0x70(%rsi),%eax
│ je 477a <hfa384x_drvr_txframe+0xba>
│ add $0x8,%eax
│ mov $0x44,%r12d
│ mov %ax,0x264(%rbx)
│ mov 0x70(%r13),%edx

Cc: Romain Perier <romain.perier@gmail.com>
Cc: Allen Pais <apais@linux.microsoft.com>
Cc: Ivan Safonov <insafonov@gmail.com>
Cc: Arnd Bergmann <arnd@arndb.de>
Cc: linux-staging@lists.linux.dev
Signed-off-by: Kees Cook <keescook@chromium.org>
Link: https://lore.kernel.org/r/20210819174537.3499227-3-keescook@chromium.org
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>


# 6277fbfd 19-Aug-2021 Kees Cook <keescook@chromium.org>

staging: wlan-ng: Remove pointless a3/a4 union

There is no need for the a3/a4 union. The two structs are identical
except for the addition of a4. Excepting one place, the structs are
only ever used in the union, and the union is always allocated at full
size. The one instance of the a3-specific struct can be replaced with
the full version, as no sizing information is used. Replace the union
with the a4 version of the struct. "diffoscope" reports there are no
object code differences after this change.

Cc: Allen Pais <apais@linux.microsoft.com>
Cc: Romain Perier <romain.perier@gmail.com>
Cc: Chen Lin <chen.lin5@zte.com.cn>
Cc: Ivan Safonov <insafonov@gmail.com>
Cc: Arnd Bergmann <arnd@arndb.de>
Cc: linux-staging@lists.linux.dev
Signed-off-by: Kees Cook <keescook@chromium.org>
Link: https://lore.kernel.org/r/20210819174537.3499227-2-keescook@chromium.org
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>


# 9e5ffffb 22-Jun-2018 Tim Collier <osdevtc@gmail.com>

staging: wlan-ng: replace WLAN_CTL_FRAMELEN with inline function in p80211hdr.h

checkpatch reports a "CHECK" diagnostic for WLAN_CTL_FRAMELEN as the
macro reuses its argument, leading to possible side-effects. Avoid
this by replacing the macro with an equivalent function, named
wlan_ctl_framelen (as recommended in the coding style). All references
to the macro also updated accordingly.

Signed-off-by: Tim Collier <osdevtc@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>


# 3fb28ae7 04-May-2018 Tim Collier <osdevtc@gmail.com>

staging: wlan-ng: fix SPDX comment style in headers

Several of the wlan-ng header files had C++-style SPDX comments. Fixed
checkpatch warnings by replacing with C-style comments, as per the
kernel docs.

Signed-off-by: Tim Collier <osdevtc@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>


# f7056d33 07-Nov-2017 Greg Kroah-Hartman <gregkh@linuxfoundation.org>

staging: wlan-ng: add SPDX identifiers to all wlan-ng driver files

It's good to have SPDX identifiers in all files to make it easier to
audit the kernel tree for correct licenses.

Update the wlan-ng driver files with the correct SPDX license identifier
based on the license text in the file itself. The SPDX identifier is a
legally binding shorthand, which can be used instead of the full boiler
plate text.

This work is based on a script and data from Thomas Gleixner, Philippe
Ombredanne, and Kate Stewart.

Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: Kate Stewart <kstewart@linuxfoundation.org>
Cc: Philippe Ombredanne <pombredanne@nexb.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>


# 408fec3f 10-Nov-2016 Sergio Paracuellos <sergio.paracuellos@gmail.com>

staging: wlan-ng: use GENMASK macro in different defines of p80211hdr.h

This patch replace actual mask stuff using BIT macros with
or operators to make use of GENMASK macro which simplifies
code clearity and readibility.

It applies for defines included in p80211hdr.h header file.

Signed-off-by: Sergio Paracuellos <sergio.paracuellos@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>


# 9546780b 07-Nov-2016 Sergio Paracuellos <sergio.paracuellos@gmail.com>

staging: wlan-ng: fix line style issue in macro WLAN_GET_FC_FSTYPE

This patch fix the following checkpatch.pl script warning:
WARNING: line over 80 characters

It also add spaces between or operators inside the macro to
comply with the standard kernel coding style.

Signed-off-by: Sergio Paracuellos <sergio.paracuellos@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>


# ed2e0f83 09-Oct-2016 Sergio Paracuellos <sergio.paracuellos@gmail.com>

staging: wlan-ng: fix block comments style in p80211hdr.h

This patch fixes the following checkpatch.pl warning in p80211hdr.h:
Block comments should align the * on each line

Signed-off-by: Sergio Paracuellos <sergio.paracuellos@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>


# f474f5e5 25-Oct-2014 Ebru Akagunduz <ebru.akagunduz@gmail.com>

staging: wlan-ng: Fix incorrect type in assignments

fc variable type was u16 and it has an assignment
from cpu_to_le16() so its type changed as __le16.
This bug found by sparse.

Signed-off-by: Ebru Akagunduz <ebru.akagunduz@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>


# 7d3864d1 03-Feb-2011 Bas van den Berg <b.van.den.berg.nl@gmail.com>

Staging: wlan-ng: fixed packed checkpatch warnings

Signed-off-by: Bas van den Berg <b.van.den.berg.nl@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>


# 93df38e5 30-Jul-2010 Edgardo Hames <ehames@gmail.com>

Staging: wlan-ng: fix style issues for p80211hdr.h

Removed typedef and other style issues.

Signed-off-by: Edgardo Hames <ehames@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>


# c4004175 21-Jun-2009 Moritz Muehlenhoff <jmm@debian.org>

Staging: wlan-ng: Remove more superflous comments

Signed-off-by: Moritz Muehlenhoff <jmm@debian.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>


# 75f49e07 25-May-2009 Mithlesh Thukral <mithlesh@linsyssoft.com>

Staging: wlan-ng: Lindent cleanups

Lindent script cleanups in wlan-ng driver in the staging tree.
This is a item in the TODO list.

Signed-off-by: Mithlesh Thukral <mithlesh@linsyssoft.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>


# 465e7417 09-Feb-2009 Moritz Muehlenhoff <jmm@debian.org>

Staging: wlan-ng: Remove the now empty wlan_compat.h

Signed-off-by: Moritz Muehlenhoff <jmm@debian.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>


# d6c82d97 07-Feb-2009 Moritz Muehlenhoff <jmm@debian.org>

Staging: wlan-ng: p80211hdr.h: Coding style cleanups

Signed-off-by: Moritz Muehlenhoff <jmm@debian.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>


# 69467fb5 25-Jan-2009 Moritz Muehlenhoff <jmm@debian.org>

Staging: wlan-ng: Remove dead/unused code from p80211hdr.h

Signed-off-by: Moritz Muehlenhoff <jmm@debian.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>


# 7f6e0e44 25-Jan-2009 Moritz Muehlenhoff <jmm@debian.org>

Staging: wlan-ng: Replace BITx with the generic BIT(x)

Signed-off-by: Moritz Muehlenhoff <jmm@debian.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>


# 3bd937af 21-Jan-2009 Moritz Muehlenhoff <jmm@debian.org>

Staging: wlan-ng: Remove stray comments in header files

The header files contain a few comments, which describe the
function of the header element. Remove them where not needed.

Signed-off-by: Moritz Muehlenhoff <jmm@debian.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>


# 28b17a4b 21-Jan-2009 Moritz Muehlenhoff <jmm@debian.org>

Staging: wlan-ng: Remove use of WLAN_ADDR_LEN

Replace the driver local WLAN_ADDR_LEN constant through the kernel-wide ETH_ALEN definiton.

Signed-off-by: Moritz Muehlenhoff <jmm@debian.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>


# 9cba46dc 21-Jan-2009 Moritz Muehlenhoff <jmm@debian.org>

Staging: wlan-ng: Remove use of __WLAN_ATTRIB_PACK__

Replace all ocurrances of the __WLAN_ATTRIB_PACK__ from wlan_compat.h
by __attribute__((packed)) and remove it afterwards.

Signed-off-by: Moritz Muehlenhoff <jmm@debian.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>


# aaad4303 29-Oct-2008 Solomon Peachy <pizza@shaftnet.org>

Staging: wlan-ng: Use standard kernel integer (u32/s32/etc) types.

wlan-ng needed to interact with userspace, and support very old kernels,
so it used to define its own types for integers to ensure consistency.

It's all rather irrelevant now.

Signed-off-by: Solomon Peachy <pizza@shaftnet.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>


# 00b3ed16 02-Oct-2008 Greg Kroah-Hartman <gregkh@suse.de>

Staging: add wlan-ng prism2 usb driver

This adds the wlan-ng prism2 USB driver to the drivers/staging tree.

The code was originally written by the linux-wlan-ng team, patched by
some Novell engineers to properly work on newer kernels, and then hacked
into place in order to get it to build properly in a single subdirectory
within the kernel tree by me.

It supports a wide range of older USB prism2 devices, and contains a
80211 stack to support this single driver.

Cc: Christian Zoz <zoz@suse.de>
Cc: Andreas Gruenbacher <agruen@suse.de>
Cc: linux-wireless <linux-wireless@vger.kernel.org>
Cc: John Linville <linville@tuxdriver.com>
Cc: Helmut Schaa <helmut.schaa@googlemail.com>
Cc: linux-wlan-ng <solomon@linux-wlan.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>