05 Oct, 2012

1 commit


03 Oct, 2012

1 commit

  • The network merge brought in a few users of functions that got
    deprecated by the workqueue cleanups: the 'system_nrt_wq' is now the
    same as the regular system_wq, since all workqueues are now non-
    reentrant.

    Similarly, remove one use of flush_work_sync() - the regular
    flush_work() has become synchronous, and the "_sync()" version is thus
    deprecated as being superfluous.

    Signed-off-by: Linus Torvalds

    Linus Torvalds
     

28 Sep, 2012

1 commit


27 Sep, 2012

5 commits

  • nfc_llcp_socket_release is calling lock_sock/release_sock while holding
    write lock for rwlock. Use bh_lock/unlock_sock instead.

    BUG: sleeping function called from invalid context at net/core/sock.c:2138
    in_atomic(): 1, irqs_disabled(): 0, pid: 56, name: kworker/1:1
    4 locks held by kworker/1:1/56:
    Pid: 56, comm: kworker/1:1 Not tainted 3.5.0-999-nfc+ #7
    Call Trace:
    [] __might_sleep+0x145/0x200
    [] lock_sock_nested+0x36/0xa0
    [] ? _raw_write_lock+0x49/0x50
    [] ? nfc_llcp_socket_release+0x30/0x200 [nfc]
    [] nfc_llcp_socket_release+0x52/0x200 [nfc]
    [] nfc_llcp_mac_is_down+0x20/0x30 [nfc]
    [] nfc_dep_link_down+0xaa/0xf0 [nfc]
    [] nfc_llcp_timeout_work+0x15/0x20 [nfc]
    [] process_one_work+0x197/0x7c0
    [] ? process_one_work+0x136/0x7c0
    [] ? __schedule+0x419/0x9c0
    [] ? nfc_llcp_build_gb+0x1b0/0x1b0 [nfc]
    [] worker_thread+0x190/0x4c0
    [] ? rescuer_thread+0x2a0/0x2a0
    [] kthread+0xae/0xc0
    [] ? trace_hardirqs_on+0xd/0x10
    [] kernel_thread_helper+0x4/0x10
    [] ? retint_restore_args+0x13/0x13
    [] ? flush_kthread_worker+0x150/0x150
    [] ? gs_change+0x13/0x13

    Signed-off-by: Szymon Janc
    Signed-off-by: Samuel Ortiz

    Szymon Janc
     
  • netlink_register_notifier requires notify functions to not sleep.
    nfc_stop_poll locks device mutex and must not be called from notifier.
    Create workqueue that will handle this for all devices.

    BUG: sleeping function called from invalid context at kernel/mutex.c:269
    in_atomic(): 0, irqs_disabled(): 0, pid: 4497, name: neard
    1 lock held by neard/4497:
    Pid: 4497, comm: neard Not tainted 3.5.0-999-nfc+ #5
    Call Trace:
    [] __might_sleep+0x145/0x200
    [] mutex_lock_nested+0x2e/0x50
    [] nfc_stop_poll+0x39/0xb0
    [] nfc_genl_rcv_nl_event+0x77/0xc0
    [] notifier_call_chain+0x5c/0x120
    [] __atomic_notifier_call_chain+0x86/0x140
    [] ? notifier_call_chain+0x120/0x120
    [] ? skb_dequeue+0x67/0x90
    [] atomic_notifier_call_chain+0x16/0x20
    [] netlink_release+0x24a/0x280
    [] sock_release+0x28/0xa0
    [] sock_close+0x17/0x30
    [] __fput+0xcc/0x250
    [] ____fput+0xe/0x10
    [] task_work_run+0x69/0x90
    [] do_notify_resume+0x81/0xd0
    [] int_signal+0x12/0x17

    Signed-off-by: Szymon Janc
    Signed-off-by: Samuel Ortiz

    Szymon Janc
     
  • This is used when CONFIG_NFC_SHDLC is disabled.

    Reported-by: Randy Dunlap
    Signed-off-by: John W. Linville
    Signed-off-by: Samuel Ortiz

    John W. Linville
     
  • This adds support for socket of type SOCK_RAW to LLCP.
    sk_buff are copied and sent to raw sockets with a 2 bytes extra header:
    The first byte header contains the nfc adapter index.
    The second one contains flags:
    - 0x01 - Direction (0=RX, 1=TX)
    - 0x02-0x80 - Reserved
    A raw socket has to be explicitly bound to a nfc adapter. This is achieved
    by specifying the adapter index to be bound to in the dev_idx field of the
    sockaddr_nfc_llcp struct passed to bind().

    Signed-off-by: Thierry Escande
    Signed-off-by: Samuel Ortiz

    Thierry Escande
     
  • If rwlock is dynamically allocated but statically initialized it is
    missing proper lockdep annotation.

    INFO: trying to register non-static key.
    the code is fine but needs lockdep annotation.
    turning off the locking correctness validator.
    Pid: 3352, comm: neard Not tainted 3.5.0-999-nfc+ #2
    Call Trace:
    [] __lock_acquire+0x8f6/0x1bf0
    [] ? printk+0x4d/0x4f
    [] lock_acquire+0x9d/0x220
    [] ? nfc_llcp_sock_from_sn+0x4e/0x160
    [] _raw_read_lock+0x44/0x60
    [] ? nfc_llcp_sock_from_sn+0x4e/0x160
    [] nfc_llcp_sock_from_sn+0x4e/0x160
    [] nfc_llcp_get_sdp_ssap+0xa7/0x1b0
    [] llcp_sock_bind+0x173/0x210
    [] sys_bind+0xe4/0x100
    [] ? trace_hardirqs_on_thunk+0x3a/0x3f
    [] system_call_fastpath+0x16/0x1b

    Signed-off-by: Szymon Janc
    Signed-off-by: Samuel Ortiz

    Szymon Janc
     

25 Sep, 2012

22 commits


11 Sep, 2012

1 commit

  • 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"
    Acked-by: Stephen Hemminger
    Signed-off-by: David S. Miller

    Eric W. Biederman
     

21 Jul, 2012

1 commit


18 Jul, 2012

1 commit


13 Jul, 2012

3 commits


11 Jul, 2012

1 commit

  • Conflicts:
    net/batman-adv/bridge_loop_avoidance.c
    net/batman-adv/bridge_loop_avoidance.h
    net/batman-adv/soft-interface.c
    net/mac80211/mlme.c

    With merge help from Antonio Quartulli (batman-adv) and
    Stephen Rothwell (drivers/net/usb/qmi_wwan.c).

    The net/mac80211/mlme.c conflict seemed easy enough, accounting for a
    conversion to some new tracing macros.

    Signed-off-by: David S. Miller

    David S. Miller
     

10 Jul, 2012

3 commits