aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/staging/rtl8192e/rtllib_crypt_tkip.c (follow)
AgeCommit message (Collapse)AuthorFilesLines
2018-09-28lib80211: Remove VLA usage of skcipherKees Cook1-18/+16
In the quest to remove all stack VLA usage from the kernel[1], this replaces struct crypto_skcipher and SKCIPHER_REQUEST_ON_STACK() usage with struct crypto_sync_skcipher and SYNC_SKCIPHER_REQUEST_ON_STACK(), which uses a fixed stack size. [1] https://lkml.kernel.org/r/CA+55aFzCG-zNmZwX4A2FQpadafLfEzK6CC=qPXydAacU1RqZWA@mail.gmail.com Cc: Johannes Berg <johannes@sipsolutions.net> Cc: linux-wireless@vger.kernel.org Signed-off-by: Kees Cook <keescook@chromium.org> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
2018-07-29staging: rtl8192e: ieee80211: Convert from ahash to shashKees Cook1-28/+28
This is an identical change to the wireless/lib80211 of the same name. In preparing to remove all stack VLA usage from the kernel[1], this removes the discouraged use of AHASH_REQUEST_ON_STACK in favor of the smaller SHASH_DESC_ON_STACK by converting from ahash-wrapped-shash to direct shash. By removing a layer of indirection this both improves performance and reduces stack usage. The stack allocation will be made a fixed size in a later patch to the crypto subsystem. [1] https://lkml.kernel.org/r/CA+55aFzCG-zNmZwX4A2FQpadafLfEzK6CC=qPXydAacU1RqZWA@mail.gmail.com Signed-off-by: Kees Cook <keescook@chromium.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2016-03-17Merge tag 'staging-4.6-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/stagingLinus Torvalds1-2/+1
Pull staging driver updates from Greg KH: "Here is the big staging driver pull request for 4.6-rc1. Lots of little things here, over 1600 patches or so. Notable is all of the good Lustre work happening, those developers have finally woken up and are cleaning up their code greatly. The Outreachy intern application process is also happening, which brought in another 400 or so patches. Full details are in the very long shortlog. All of these have been in linux-next with no reported issues" * tag 'staging-4.6-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/staging: (1673 commits) staging: lustre: fix aligments in lnet selftest staging: lustre: report minimum of two buffers for LNet selftest load test staging: lustre: test for proper errno code in lstcon_rpc_trans_abort staging: lustre: filter remaining extra spacing for lnet selftest staging: lustre: remove extra spacing when setting variable for lnet selftest staging: lustre: remove extra spacing of variable declartions for lnet selftest staging: lustre: fix spacing issues checkpatch reported in lnet selftest staging: lustre: remove returns in void function for lnet selftest staging: lustre: fix bogus lst errors for lnet selftest staging: netlogic: Replacing pr_err with dev_err after the call to devm_kzalloc staging: mt29f_spinand: Replacing pr_info with dev_info after the call to devm_kzalloc staging: android: ion: fix up file mode staging: ion: debugfs invalid gfp mask staging: rts5208: Replace pci_enable_device with pcim_enable_device Staging: ieee80211: Place constant on right side of the test. staging: speakup: Replace del_timer with del_timer_sync staging: lowmemorykiller: fix 2 checks that checkpatch complained staging: mt29f_spinand: Drop void pointer cast staging: rdma: hfi1: file_ops: Replace ALIGN with PAGE_ALIGN staging: rdma: hfi1: driver: Replace IS_ALIGNED with PAGE_ALIGNED ...
2016-03-11staging: rtl8192e: rtllib_crypt_tkip: Remove unnecessary else after returnBhaktipriya Shridhar1-2/+1
This patch fixes the checkpatch warning that else is not generally useful after a break or return. This was done using Coccinelle: @@ expression e2; statement s1; @@ if(e2) { ... return ...; } -else s1 Signed-off-by: Bhaktipriya Shridhar <bhaktipriya96@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2016-01-27staging: rtl8192e: Replace uses of obsolete blkcipher and hashHerbert Xu1-45/+54
The interfaces blkcipher and hash are obsolete. This patch replaces them with skcipher and ahash respectively. Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> Acked-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-06-01staging: rtl8192e: Fix PREFER_PR_LEVEL warningsMateusz Kulikowski1-36/+31
Fix most of remaining PREFER_PR_LEVEL warnings in rtllib. Replace printk() with netdev_* if possible, pr_* in other cases. Signed-off-by: Mateusz Kulikowski <mateusz.kulikowski@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-06-01staging: rtl8192e: Fix PREFER_ETHER_ADDR_COPY warningsMateusz Kulikowski1-9/+10
Replace memcpy() with ether_addr_copy() where possible to make checkpatch.pl happy. Change was target tested (download 1Mb file over WPA2 network) with BUG trap for unaligned addresses in ether_addr_copy() Signed-off-by: Mateusz Kulikowski <mateusz.kulikowski@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-06-01staging: rtl8192e: Make ethernet addresses properly alignedMateusz Kulikowski1-1/+2
Reorder ethernet addresses allocated on stack or in non-packed structures to keep them aligned(2). Use ETH_ALEN as array length in places where it was hardcoded to 6. Alignment verified using pahole where possible and target-tested with BUG_ON() trap in ether_addr_copy. Signed-off-by: Mateusz Kulikowski <mateusz.kulikowski@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-04-03staging: rtl8192e: Comment cleanup (style/format)Mateusz Kulikowski1-5/+10
- Multiline comments use "network subsystem comment style" - Merge short multiline comments - Remove empty comments - Remove function name comment at the end of small (<1 screen) functions - Reformat 802.11 data frame format to use spaces and network format Signed-off-by: Mateusz Kulikowski <mateusz.kulikowski@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-03-20staging: rtl8192e: fix coding style warnings (printk -> netdev_*)Mateusz Kulikowski1-2/+2
Use netdev_*, dev_* or pr_* instead of printk where possible. KERN_DEBUG messages are left intact as pr_dbg has different behaviour. Signed-off-by: Mateusz Kulikowski <mateusz.kulikowski@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-03-20staging: rtl8192e: fix coding style issues (merge broken strings)Mateusz Kulikowski1-31/+31
Fix checkpatch.pl warnings: - 'WARNING: quoted string split across lines' - 'WARNING: break quoted strings at a space character' Signed-off-by: Mateusz Kulikowski <mateusz.kulikowski@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-08-30staging: rtl8192e: fixed coding style issuesMatthew Casey1-0/+5
Fixed missing blank line after declarations issues Signed-off-by: Matthew Casey <mdcasey@chabloom.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-01-09Staging rtl8192e: Fixing checkpatch error in rtllib_crypt_tkip.cAndreas Frembs1-1/+1
In rtllib_crypt_tkip.c we fixed the following checkpatch error: ERROR: space required after that ',' Signed-off-by: Andreas Frembs <andreas.frembs@studium.uni-erlangen.de> Signed-off-by: Matthias Schoepe <matthias.schoepe@studium.uni-erlangen.de> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2013-11-10Staging: rtl8192e: Fix Sparse Warning for Static Declarations in rtllib_crypt_tkip.cRashika Kheria1-2/+2
This patch fixes the following Sparse warnings in rtllib_crypt_tkip.c- drivers/staging/rtl8192e/rtllib_crypt_tkip.c:755:12: warning: symbol 'rtllib_crypto_tkip_init' was not declared. Should it be static? drivers/staging/rtl8192e/rtllib_crypt_tkip.c:761:13: warning: symbol 'rtllib_crypto_tkip_exit' was not declared. Should it be static? Signed-off-by: Rashika Kheria <rashika.kheria@gmail.com> Reviewed-by: Peter P Waskiewicz Jr <peter.p.waskiewicz.jr@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2013-11-10Staging: rtl8192e: Fix Sparse warning of cast to restricted __le16 in rtllib_crypt_tkip.cRashika Kheria1-1/+1
This patch fixes the following Sparse warnings in rtllib_crypt_tkip.c- drivers/staging/rtl8192e/rtllib_crypt_tkip.c:176:16: warning: cast to restricted __le16 Signed-off-by: Rashika Kheria <rashika.kheria@gmail.com> Reviewed-by: Peter P Waskiewicz Jr <peter.p.waskiewicz.jr@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2013-04-29hostap: Don't use create_proc_read_entry()David Howells1-22/+22
Don't use create_proc_read_entry() as that is deprecated, but rather use proc_create_data() and seq_file instead. Signed-off-by: David Howells <dhowells@redhat.com> Acked-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> cc: Jouni Malinen <j@w1.fi> cc: John W. Linville <linville@tuxdriver.com> cc: Johannes Berg <johannes@sipsolutions.net> cc: linux-wireless@vger.kernel.org cc: netdev@vger.kernel.org cc: devel@driverdev.osuosl.org Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
2011-12-22staging/rtl8192e: Register against lib80211Sean MacLennan1-3/+3
Convert rtllib from registering the crypt drivers against rtllib_crypt and instead register the against lib80211. The crypto functions have R- prepended (R-CCMP, R-TKIP, R-WEP) so they will not clash with the lib80211 versions. We cannot use the lib80211 crypt drivers since the rtl8192e has some hardware support that is not handled by the lib80211 crypt drivers. Signed-off-by: Sean MacLennan <seanm@seanm.ca> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2011-12-22staging/rtl8192e: Convert to lib80211_crypt_data and lib80211_crypt_opsSean MacLennan1-11/+8
Convert rtllib_crypt_data to lib80211_crypt_data and rtllib_crypt_ops to lib80211_crypt_ops. This is almost a 1:1 replacement, only extra_prefix_len and extra_postfix_len changed. Signed-off-by: Sean MacLennan <seanm@seanm.ca> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2011-12-13staging: remove version.h includes in rtl8192eDevendra Naga1-1/+0
Signed-off-by: Devendra Naga <devendra.aaru@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2011-11-30rtl8192e: Split the driver upSean MacLennan1-5/+4
This patch splits the current r8192e_pci driver up into six different drivers: rtllib, rtllib_crypt, rtllib_crypt_ccmp, rtllib_crypt_tkip, rtllib_crypt_wep, and r8192e_pci. Now that they are proper modules, the init and exit functions do not need to be called directly. Also, the rtllib_*_null functions are not needed since they will be loaded on demand. Signed-off-by: Sean MacLennan <seanm@seanm.ca> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2011-11-26staging: rtl8192e: Use kzalloc rather than kmalloc v2Thomas Meyer1-2/+1
Use kzalloc rather than kmalloc followed by memset with 0 This considers some simple cases that are common and easy to validate Note in particular that there are no ...s in the rule, so all of the matched code has to be contiguous The semantic patch that makes this change is available in scripts/coccinelle/api/alloc/kzalloc-simple.cocci. Signed-off-by: Thomas Meyer <thomas@m3y3r.de> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2011-08-25staging: rtl8192e: Remove MAC_FMT and MAC_ARG for %pMLarry Finger1-11/+10
Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2011-08-25staging: rtl8192e: Cleanup checkpatch -f warnings and errors - Part XILarry Finger1-60/+64
Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2011-08-24staging: rtl8192e: Convert typedef cb_desc to struct cb_descLarry Finger1-2/+2
Remove typedef from struct. Rename struct. Rename uses. Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
2011-08-23staging: rtl8192e: Remove code dependent of JOHN_DUMPLarry Finger1-11/+0
Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
2011-08-23rtl8192e: Remove WIRELESS_EXT macro checksMike McCormack1-24/+0
Signed-off-by: Mike McCormack <mikem@ring3k.org>
2011-08-23rtl8192e: Remove extra ifdefsMike McCormack1-187/+2
Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net> Signed-off-by: Mike McCormack <mikem@ring3k.org>
2011-08-23From: wlanfae <wlanfae@realtek.com>Larry Finger1-0/+992
[PATCH 1/8] rtl8192e: Import new version of driver from realtek Signed-off-by: wlanfae <wlanfae@realtek.com> Signed-off-by: Mike McCormack <mikem@ring3k.org> Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net> ---