History log of /drivers/staging/gdm72xx/netlink_k.c
Revision Date Author Comments
2e98f76c8fe3247e2118b948799e0ea491f35b9e 26-Sep-2014 Gulsah Kose <gulsah.1004@gmail.com> drivers: staging: gdm72xx: Removed unnecessary braces.

This patch fixes "braces {} are not necessary for single statement
blocks" checkpatch.pl warning in netlink_k.c

Signed-off-by: Gulsah Kose <gulsah.1004@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
93f509a88107b2ee551ae63e710f22378815eb76 26-Sep-2014 Gulsah Kose <gulsah.1004@gmail.com> drivers: staging: gdm72xx: Removed unnecessary else expression.

This patch fixes "else is not generally useful after a break or return"
checkpatch.pl warning in netlink_k.c

Signed-off-by: Gulsah Kose <gulsah.1004@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
a3709f7a143d9522ede046d23ed46b7f4fe67102 23-May-2014 Davide Gianforte <davide@gengisdave.org> staging: gdm72xx: code cleanup

Checkpatch.pl cleanup

Thanks again to Greg KH and Dan Carpenter for the patience :)

Signed-off-by: Davide Gianforte <davide@gengisdave.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
39c511f8cb90be18f12575e5bdaf566a5e9a56b5 09-May-2014 Michalis Pappas <mpappas@fastmail.fm> staging: gdm72xx: Whitespace fixes to conform to coding standards

Fixes the following checkpatch.pl issues:

WARNING: unnecessary whitespace before a quoted newline
CHECK: Alignment should match open parenthesis
CHECK: No space is necessary after a cast

Also some additional, whitespace related, readability issues.

Signed-off-by: Michalis Pappas <mpappas@fastmail.fm>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
71fd11e1a0b585934b1b7af8114971979b0142c8 09-May-2014 Michalis Pappas <mpappas@fastmail.fm> staging: gdm72xx: Fix braces to conform with coding style

Fixes the following checkpatch.pl issue:

CHECK: braces {} should be used on all arms of this statement

Signed-off-by: Michalis Pappas <mpappas@fastmail.fm>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
b96dc464994cb6d839c3b307b20061b440dc3edb 27-Mar-2013 Hong zhi guo <honkiko@gmail.com> gdm72xx: replace obsolete NLMSG_* with type safe nlmsg_*

Signed-off-by: Hong Zhiguo <honkiko@gmail.com>
Acked-by: Thomas Graf <tgraf@suug.ch>
Signed-off-by: David S. Miller <davem@davemloft.net>
a6000538e402ef2479a16ff789059c78a152be9d 19-Feb-2013 Peter Huewe <peterhuewe@gmx.de> staging/gdm72xx: Include corresponding header file (fix sparse warning)

sdio_boot.c and netlink_k.c both have a corresponding header file with
their function prototypes but fail to include them, which leads to the
following sparse warnings:
sdio_boot.c:135:5: warning: symbol 'sdio_boot' was not declared. Should it be static?
netlink_k.c:89:13: warning: symbol 'netlink_init' was not declared. Should it be static?
netlink_k.c:109:6: warning: symbol 'netlink_exit' was not declared. Should it be static?
netlink_k.c:114:5: warning: symbol 'netlink_send' was not declared. Should it be static?

-> Add the include files and silence the warning

Signed-off-by: Peter Huewe <peterhuewe@gmx.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
cade0fe46fde08642674838a0d17389bd1b7ba4b 29-Oct-2012 YAMANE Toshiaki <yamanetoshi@gmail.com> staging/gdm72xx: Use netdev_ or pr_ printks in netlink_k.c

fixed below checkpatch warnings.
- WARNING: Prefer netdev_err(netdev, ... then dev_err(dev, ... then pr_err(... to printk(KERN_ERR ...

and add pr_fmt.

Signed-off-by: YAMANE Toshiaki <yamanetoshi@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
15e473046cb6e5d18a4d0057e61d76315230382b 07-Sep-2012 Eric W. Biederman <ebiederm@xmission.com> netlink: Rename pid to portid to avoid confusion

It is a frequent mistake to confuse the netlink port identifier with a
process identifier. Try to reduce this confusion by renaming fields
that hold port identifiers portid instead of pid.

I have carefully avoided changing the structures exported to
userspace to avoid changing the userspace API.

I have successfully built an allyesconfig kernel with this change.

Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com>
Acked-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
9f00d9776bc5beb92e8bfc884a7e96ddc5589e2e 08-Sep-2012 Pablo Neira Ayuso <pablo@netfilter.org> netlink: hide struct module parameter in netlink_kernel_create

This patch defines netlink_kernel_create as a wrapper function of
__netlink_kernel_create to hide the struct module *me parameter
(which seems to be THIS_MODULE in all existing netlink subsystems).

Suggested by David S. Miller.

Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
a31f2d17b331db970259e875b7223d3aba7e3821 29-Jun-2012 Pablo Neira Ayuso <pablo@netfilter.org> netlink: add netlink_kernel_cfg parameter to netlink_kernel_create

This patch adds the following structure:

struct netlink_kernel_cfg {
unsigned int groups;
void (*input)(struct sk_buff *skb);
struct mutex *cb_mutex;
};

That can be passed to netlink_kernel_create to set optional configurations
for netlink kernel sockets.

I've populated this structure by looking for NULL and zero parameters at the
existing code. The remaining parameters that always need to be set are still
left in the original interface.

That includes optional parameters for the netlink socket creation. This allows
easy extensibility of this interface in the future.

This patch also adapts all callers to use this new interface.

Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
a8edf8a690817ebfe68aa14c4bc482f62699077f 27-Jun-2012 David S. Miller <davem@davemloft.net> gdm72xx: Move away from NLMSG_PUT().

And use nlmsg_data() while we're here too.

Signed-off-by: David S. Miller <davem@davemloft.net>
2da049bd5f9b0dbd688519fdb6688a4895fe8395 27-Jun-2012 Javier Martinez Canillas <javier@dowhile0.org> staging: gdm72xx: fix an skb memory leak

The NLMSG_PUT() macro contains a hidden goto that jumps to the
nlmsg_failure label. Since the sk_buff was allocated before the macro,
jumping to the nlmsg_failure label leaks the memory allocated for it.

Calling kfree() before returning would fix it, but is better to avoid
using this error prone macro and use nlmsg_put() instead.

Also, use nlmsg_data() instead of NLMSG_DATA() to check type.

Signed-off-by: Javier Martinez Canillas <javier@dowhile0.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9f77186dd13125bef301f9136b6075f5530f3d85 14-Jun-2012 Ben Chan <benchan@chromium.org> staging: gdm72xx: Release netlink socket properly

This patch modifies the gdm72xx driver to properly release a netlink
socket using netlink_kernel_release. It fixes the following kernel
crash, which occurs after repeatedly suspending and resuming a system.

kernel BUG at /home/benchan/trunk/src/third_party/kernel/files/mm/slub.c:3471!
invalid opcode: 0000 [#1] SMP
CPU 2
Modules linked in: asix usbnet snd_hda_codec_hdmi
snd_hda_codec_cirrus i2c_dev uinput snd_hda_intel snd_hda_codec
snd_hwdep snd_pcm snd_timer bluetooth snd_page_alloc fuse aesni_intel
cryptd isl29018(C) aes_x86_64 industrialio(C) memconsole nm10_gpio
rtc_cmos nf_conntrack_ipv6 nf_defrag_ipv6 r8169 ath9k mac80211
ip6table_filter ath9k_common ath9k_hw ath cfg80211 xt_mark ip6_tables
uvcvideo videobuf2_core videodev videobuf2_vmalloc videobuf2_memops
gdmwm(C) joydev

Pid: 3125, comm: kworker/u:30 Tainted: G WC 3.4.0 #1
RIP: 0010:[<ffffffff810cda19>] [<ffffffff810cda19>] kfree+0x67/0xca
RSP: 0018:ffff880134977d60 EFLAGS: 00010246
RAX: 4000000000000400 RBX: ffffffff818832a0 RCX: 0000000000000000
RDX: 4000000000000000 RSI: 0000000000000000 RDI: ffffffff818832a0
RBP: ffff880134977d80 R08: 00000000ffffffff R09: ffffea00000620c0
R10: ffffffff8111b729 R11: ffff880149fb3840 R12: ffffffff81a08840
R13: ffffffff813f5bc3 R14: ffffffff8138ed84 R15: 0000000000000000
FS: 0000000000000000(0000) GS:ffff88014fb00000(0000) knlGS:0000000000000000
CS: 0010 DS: 0000 ES: 0000 CR0: 000000008005003b
CR2: 00007f7cad963110 CR3: 000000000180b000 CR4: 00000000000407e0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000ffff0ff0 DR7: 0000000000000400
Process kworker/u:30 (pid: 3125, threadinfo ffff880134976000, task ffff8801330647e0)
Stack:
0000000000000002 ffffffff818832a0 ffffffff81a08840 ffff880134977df0
ffff880134977da0 ffffffff813f5bc3 ffff880134977df0 ffffffff81883250
ffff880134977dd0 ffffffff8138e64c 0000000180150010 ffffffff81883250
Call Trace:
[<ffffffff813f5bc3>] ipv4_sysctl_exit_net+0x23/0x27
[<ffffffff8138e64c>] ops_exit_list+0x27/0x50
[<ffffffff8138ee72>] cleanup_net+0xee/0x17c
[<ffffffff81040c64>] process_one_work+0x199/0x2b8
[<ffffffff810416e4>] worker_thread+0x13c/0x222
[<ffffffff810415a8>] ? manage_workers.isra.26+0x171/0x171
[<ffffffff8104506d>] kthread+0x8b/0x93
[<ffffffff8145b414>] kernel_thread_helper+0x4/0x10
[<ffffffff81044fe2>] ? __init_kthread_worker+0x39/0x39
[<ffffffff8145b410>] ? gs_change+0xb/0xb
Code: 83 c4 10 49 83 3c 24 00 eb e4 48 83 fb 10 76 76 48 89 df e8 17
e1 ff ff 49 89 c1 48 8b 00 a8 80 75 15 49 f7 01 00 c0 00 00 75 02
<0f> 0b 4c 89 cf e8 b8 b4 fd ff eb 4f 4c 8b 55 08 49 8b 79 30 48
RIP [<ffffffff810cda19>] kfree+0x67/0xca
RSP <ffff880134977d60>

Signed-off-by: Ben Chan <benchan@chromium.org>
Cc: Sage Ahn <syahn@gctsemi.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
02fd3b3670fb99017b17757d33a0a17e2405920c 27-May-2012 Devendra Naga <devendra.aaru@gmail.com> staging/gdm72xx: Remove version.h includes

Signed-off-by: Devendra Naga <devendra.aaru@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
247e9cffdce024fec5f55f76a8592f2fa8b3aa7b 15-May-2012 Sage Ahn <syahn@gctsemi.com> staging: gdm72xx: Add GCT GDM72xx WiMAX driver.

This patch provides the kernel driver for the GDM72xx WiMAX chips
developed by GCT Semiconductor, Inc., which enables mobile WiMAX
connection on the Linux host.

Signed-off-by: Sage Ahn <syahn@gctsemi.com>
Cc: Ben Chan <benchan@chromium.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>