1. 15 3月, 2015 8 次提交
  2. 13 3月, 2015 3 次提交
  3. 07 3月, 2015 2 次提交
  4. 03 3月, 2015 1 次提交
  5. 02 3月, 2015 2 次提交
  6. 28 2月, 2015 1 次提交
    • J
      Bluetooth: make hci_test_bit's addr const · 9391976a
      Jiri Slaby 提交于
      gcc5 warns about passing a const array to hci_test_bit which takes a
      non-const pointer:
      net/bluetooth/hci_sock.c: In function ‘hci_sock_sendmsg’:
      net/bluetooth/hci_sock.c:955:8: warning: passing argument 2 of ‘hci_test_bit’ discards ‘const’ qualifier from pointer target type [-Wdiscarded-array-qualifiers]
              &hci_sec_filter.ocf_mask[ogf])) &&
              ^
      net/bluetooth/hci_sock.c:49:19: note: expected ‘void *’ but argument is of type ‘const __u32 (*)[4] {aka const unsigned int (*)[4]}’
       static inline int hci_test_bit(int nr, void *addr)
                         ^
      
      So make 'addr' 'const void *'.
      Signed-off-by: NJiri Slaby <jslaby@suse.cz>
      Signed-off-by: NMarcel Holtmann <marcel@holtmann.org>
      Cc: Gustavo Padovan <gustavo@padovan.org>
      Cc: Johan Hedberg <johan.hedberg@gmail.com>
      9391976a
  7. 21 2月, 2015 2 次提交
  8. 12 1月, 2015 4 次提交
  9. 24 11月, 2014 1 次提交
  10. 06 11月, 2014 1 次提交
    • D
      net: Add and use skb_copy_datagram_msg() helper. · 51f3d02b
      David S. Miller 提交于
      This encapsulates all of the skb_copy_datagram_iovec() callers
      with call argument signature "skb, offset, msghdr->msg_iov, length".
      
      When we move to iov_iters in the networking, the iov_iter object will
      sit in the msghdr.
      
      Having a helper like this means there will be less places to touch
      during that transformation.
      
      Based upon descriptions and patch from Al Viro.
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      51f3d02b
  11. 29 10月, 2014 1 次提交
  12. 11 7月, 2014 3 次提交
  13. 09 7月, 2014 1 次提交
  14. 06 7月, 2014 1 次提交
    • M
      Bluetooth: Run controller setup after external configuration · d603b76b
      Marcel Holtmann 提交于
      When the external configuration triggers the switch to a configured
      controller, it means the setup needs to be run. Controllers that start
      out unconfigured have only run limited set of HCI commands. This is
      not enough for complete operation and thus run the setup procedure
      before announcing the new controller index.
      
      This introduces HCI_CONFIG flag as companion to HCI_SETUP flag. The
      HCI_SETUP flag is only used once for the initial setup procedure. And
      during that procedure hdev->setup driver callback is called. With the
      new HCI_CONFIG the switch from unconfigured to configured state is
      triggering the same setup procedure just without hdev->setup. This
      is required since bringing a controller back to unconfigured state
      from configured state is possible.
      Signed-off-by: NMarcel Holtmann <marcel@holtmann.org>
      Signed-off-by: NJohan Hedberg <johan.hedberg@intel.com>
      d603b76b
  15. 03 7月, 2014 3 次提交
    • M
      Bluetooth: Add support for Unconfigured Index Added events · 0602a8ad
      Marcel Holtmann 提交于
      When a controller is in unconfigured state it is currently hidden
      from the management interface. This change now announces the new
      controller with an Unconfigured Index Added event and allows clients
      to easily detect the controller.
      Signed-off-by: NMarcel Holtmann <marcel@holtmann.org>
      Signed-off-by: NJohan Hedberg <johan.hedberg@intel.com>
      0602a8ad
    • M
      Bluetooth: Introduce unconfigured controller state · 4a964404
      Marcel Holtmann 提交于
      With the new unconfigured controller state it is possible to provide a
      fully functional HCI transport, but disable the higher level operations
      that would normally happen. This way userspace can try to configure the
      controller before releases the unconfigured state.
      
      The internal state is represented by HCI_UNCONFIGURED. This replaces the
      HCI_QUIRK_RAW_DEVICE quirk as internal state representation. This is now
      a real state and drivers can use the quirk to actually trigger this
      state. In the future this will allow a more fine grained switching from
      unconfigured state to configured state for controller inititialization.
      Signed-off-by: NMarcel Holtmann <marcel@holtmann.org>
      Signed-off-by: NJohan Hedberg <johan.hedberg@intel.com>
      4a964404
    • M
      Bluetooth: Restrict access for raw-only controllers · fee746b0
      Marcel Holtmann 提交于
      Bluetooth controllers that are marked for raw-only usage can only be
      used with user channel access. Any other operation should be rejected.
      
      This simplifies the whole raw-only support since it now depends on
      the fact that the controller is marked with HCI_QUIRK_RAW_DEVICE and
      runtime raw access is restricted to user channel operation.
      
      The kernel internal processing of HCI commands and events is designed
      around the case that either the kernel has full control over the device
      or that the device is driven from userspace. This now makes a clear
      distinction between these two possible operation modes.
      Signed-off-by: NMarcel Holtmann <marcel@holtmann.org>
      Signed-off-by: NJohan Hedberg <johan.hedberg@intel.com>
      fee746b0
  16. 12 6月, 2014 1 次提交
    • O
      net: add __pskb_copy_fclone and pskb_copy_for_clone · bad93e9d
      Octavian Purdila 提交于
      There are several instances where a pskb_copy or __pskb_copy is
      immediately followed by an skb_clone.
      
      Add a couple of new functions to allow the copy skb to be allocated
      from the fclone cache and thus speed up subsequent skb_clone calls.
      
      Cc: Alexander Smirnov <alex.bluesman.smirnov@gmail.com>
      Cc: Dmitry Eremin-Solenikov <dbaryshkov@gmail.com>
      Cc: Marek Lindner <mareklindner@neomailbox.ch>
      Cc: Simon Wunderlich <sw@simonwunderlich.de>
      Cc: Antonio Quartulli <antonio@meshcoding.com>
      Cc: Marcel Holtmann <marcel@holtmann.org>
      Cc: Gustavo Padovan <gustavo@padovan.org>
      Cc: Johan Hedberg <johan.hedberg@gmail.com>
      Cc: Arvid Brodin <arvid.brodin@alten.se>
      Cc: Patrick McHardy <kaber@trash.net>
      Cc: Pablo Neira Ayuso <pablo@netfilter.org>
      Cc: Jozsef Kadlecsik <kadlec@blackhole.kfki.hu>
      Cc: Lauro Ramos Venancio <lauro.venancio@openbossa.org>
      Cc: Aloisio Almeida Jr <aloisio.almeida@openbossa.org>
      Cc: Samuel Ortiz <sameo@linux.intel.com>
      Cc: Jon Maloy <jon.maloy@ericsson.com>
      Cc: Allan Stephens <allan.stephens@windriver.com>
      Cc: Andrew Hendry <andrew.hendry@gmail.com>
      Cc: Eric Dumazet <edumazet@google.com>
      Reviewed-by: NChristoph Paasch <christoph.paasch@uclouvain.be>
      Signed-off-by: NOctavian Purdila <octavian.purdila@intel.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      bad93e9d
  17. 24 4月, 2014 1 次提交
  18. 13 3月, 2014 1 次提交
  19. 18 2月, 2014 1 次提交
  20. 17 12月, 2013 1 次提交
  21. 21 11月, 2013 1 次提交
    • H
      net: rework recvmsg handler msg_name and msg_namelen logic · f3d33426
      Hannes Frederic Sowa 提交于
      This patch now always passes msg->msg_namelen as 0. recvmsg handlers must
      set msg_namelen to the proper size <= sizeof(struct sockaddr_storage)
      to return msg_name to the user.
      
      This prevents numerous uninitialized memory leaks we had in the
      recvmsg handlers and makes it harder for new code to accidentally leak
      uninitialized memory.
      
      Optimize for the case recvfrom is called with NULL as address. We don't
      need to copy the address at all, so set it to NULL before invoking the
      recvmsg handler. We can do so, because all the recvmsg handlers must
      cope with the case a plain read() is called on them. read() also sets
      msg_name to NULL.
      
      Also document these changes in include/linux/net.h as suggested by David
      Miller.
      
      Changes since RFC:
      
      Set msg->msg_name = NULL if user specified a NULL in msg_name but had a
      non-null msg_namelen in verify_iovec/verify_compat_iovec. This doesn't
      affect sendto as it would bail out earlier while trying to copy-in the
      address. It also more naturally reflects the logic by the callers of
      verify_iovec.
      
      With this change in place I could remove "
      if (!uaddr || msg_sys->msg_namelen == 0)
      	msg->msg_name = NULL
      ".
      
      This change does not alter the user visible error logic as we ignore
      msg_namelen as long as msg_name is NULL.
      
      Also remove two unnecessary curly brackets in ___sys_recvmsg and change
      comments to netdev style.
      
      Cc: David Miller <davem@davemloft.net>
      Suggested-by: NEric Dumazet <eric.dumazet@gmail.com>
      Signed-off-by: NHannes Frederic Sowa <hannes@stressinduktion.org>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      f3d33426