1. 13 11月, 2010 16 次提交
  2. 12 11月, 2010 2 次提交
    • S
      netfilter: ipv6: fix overlap check for fragments · 22e091e5
      Shan Wei 提交于
      The type of FRAG6_CB(prev)->offset is int, skb->len is *unsigned* int,
      and offset is int.
      
      Without this patch, type conversion occurred to this expression, when
      (FRAG6_CB(prev)->offset + prev->len) is less than offset.
      Signed-off-by: NShan Wei <shanwei@cn.fujitsu.com>
      Signed-off-by: NPatrick McHardy <kaber@trash.net>
      22e091e5
    • E
      netfilter: NF_HOOK_COND has wrong conditional · ac5aa2e3
      Eric Paris 提交于
      The NF_HOOK_COND returns 0 when it shouldn't due to what I believe to be an
      error in the code as the order of operations is not what was intended.  C will
      evalutate == before =.  Which means ret is getting set to the bool result,
      rather than the return value of the function call.  The code says
      
      if (ret = function() == 1)
      when it meant to say:
      if ((ret = function()) == 1)
      
      Normally the compiler would warn, but it doesn't notice it because its
      a actually complex conditional and so the wrong code is wrapped in an explict
      set of () [exactly what the compiler wants you to do if this was intentional].
      Fixing this means that errors when netfilter denies a packet get propagated
      back up the stack rather than lost.
      
      Problem introduced by commit 2249065f (netfilter: get rid of the grossness
      in netfilter.h).
      Signed-off-by: NEric Paris <eparis@redhat.com>
      Cc: stable@kernel.org
      Signed-off-by: NPatrick McHardy <kaber@trash.net>
      ac5aa2e3
  3. 11 11月, 2010 6 次提交
  4. 10 11月, 2010 6 次提交
  5. 09 11月, 2010 10 次提交
    • E
      Bluetooth: Add MacBookAir3,1(2) support · 3e3ede7d
      Edgar (gimli) Hucek 提交于
      Adding the new MacBookAir3,1(2) to btusb.
      
      Output without the patch and btusb loaded :
      
      T:  Bus=03 Lev=02 Prnt=03 Port=02 Cnt=01 Dev#=  6 Spd=12  MxCh= 0
      D:  Ver= 2.00 Cls=ff(vend.) Sub=01 Prot=01 MxPS=64 #Cfgs=  1
      P:  Vendor=05ac ProdID=821b Rev= 0.34
      S:  Manufacturer=Apple Inc.
      S:  Product=Bluetooth USB Host Controller
      C:* #Ifs= 4 Cfg#= 1 Atr=e0 MxPwr=  0mA
      I:* If#= 0 Alt= 0 #EPs= 3 Cls=ff(vend.) Sub=01 Prot=01 Driver=(none)
      E:  Ad=81(I) Atr=03(Int.) MxPS=  16 Ivl=1ms
      E:  Ad=82(I) Atr=02(Bulk) MxPS=  64 Ivl=0ms
      E:  Ad=02(O) Atr=02(Bulk) MxPS=  64 Ivl=0ms
      I:* If#= 1 Alt= 0 #EPs= 2 Cls=e0(wlcon) Sub=01 Prot=01 Driver=(none)
      E:  Ad=83(I) Atr=01(Isoc) MxPS=   0 Ivl=1ms
      E:  Ad=03(O) Atr=01(Isoc) MxPS=   0 Ivl=1ms
      I:  If#= 1 Alt= 1 #EPs= 2 Cls=e0(wlcon) Sub=01 Prot=01 Driver=(none)
      E:  Ad=83(I) Atr=01(Isoc) MxPS=   9 Ivl=1ms
      E:  Ad=03(O) Atr=01(Isoc) MxPS=   9 Ivl=1ms
      I:  If#= 1 Alt= 2 #EPs= 2 Cls=e0(wlcon) Sub=01 Prot=01 Driver=(none)
      E:  Ad=83(I) Atr=01(Isoc) MxPS=  17 Ivl=1ms
      E:  Ad=03(O) Atr=01(Isoc) MxPS=  17 Ivl=1ms
      I:  If#= 1 Alt= 3 #EPs= 2 Cls=e0(wlcon) Sub=01 Prot=01 Driver=(none)
      E:  Ad=83(I) Atr=01(Isoc) MxPS=  32 Ivl=1ms
      E:  Ad=03(O) Atr=01(Isoc) MxPS=  32 Ivl=1ms
      I:  If#= 1 Alt= 4 #EPs= 2 Cls=e0(wlcon) Sub=01 Prot=01 Driver=(none)
      E:  Ad=83(I) Atr=01(Isoc) MxPS=  64 Ivl=1ms
      E:  Ad=03(O) Atr=01(Isoc) MxPS=  64 Ivl=1ms
      I:  If#= 1 Alt= 5 #EPs= 2 Cls=e0(wlcon) Sub=01 Prot=01 Driver=(none)
      E:  Ad=83(I) Atr=01(Isoc) MxPS=  64 Ivl=1ms
      E:  Ad=03(O) Atr=01(Isoc) MxPS=  64 Ivl=1ms
      I:* If#= 2 Alt= 0 #EPs= 2 Cls=ff(vend.) Sub=ff Prot=ff Driver=(none)
      E:  Ad=84(I) Atr=02(Bulk) MxPS=  32 Ivl=0ms
      E:  Ad=04(O) Atr=02(Bulk) MxPS=  32 Ivl=0ms
      I:* If#= 3 Alt= 0 #EPs= 0 Cls=fe(app. ) Sub=01 Prot=01 Driver=(none)
      
      Output with the patch and btusb loaded :
      
      T:  Bus=03 Lev=02 Prnt=03 Port=02 Cnt=01 Dev#=  6 Spd=12  MxCh= 0
      D:  Ver= 2.00 Cls=ff(vend.) Sub=01 Prot=01 MxPS=64 #Cfgs=  1
      P:  Vendor=05ac ProdID=821b Rev= 0.34
      S:  Manufacturer=Apple Inc.
      S:  Product=Bluetooth USB Host Controller
      C:* #Ifs= 4 Cfg#= 1 Atr=e0 MxPwr=  0mA
      I:* If#= 0 Alt= 0 #EPs= 3 Cls=ff(vend.) Sub=01 Prot=01 Driver=btusb
      E:  Ad=81(I) Atr=03(Int.) MxPS=  16 Ivl=1ms
      E:  Ad=82(I) Atr=02(Bulk) MxPS=  64 Ivl=0ms
      E:  Ad=02(O) Atr=02(Bulk) MxPS=  64 Ivl=0ms
      I:* If#= 1 Alt= 0 #EPs= 2 Cls=e0(wlcon) Sub=01 Prot=01 Driver=btusb
      E:  Ad=83(I) Atr=01(Isoc) MxPS=   0 Ivl=1ms
      E:  Ad=03(O) Atr=01(Isoc) MxPS=   0 Ivl=1ms
      I:  If#= 1 Alt= 1 #EPs= 2 Cls=e0(wlcon) Sub=01 Prot=01 Driver=btusb
      E:  Ad=83(I) Atr=01(Isoc) MxPS=   9 Ivl=1ms
      E:  Ad=03(O) Atr=01(Isoc) MxPS=   9 Ivl=1ms
      I:  If#= 1 Alt= 2 #EPs= 2 Cls=e0(wlcon) Sub=01 Prot=01 Driver=btusb
      E:  Ad=83(I) Atr=01(Isoc) MxPS=  17 Ivl=1ms
      E:  Ad=03(O) Atr=01(Isoc) MxPS=  17 Ivl=1ms
      I:  If#= 1 Alt= 3 #EPs= 2 Cls=e0(wlcon) Sub=01 Prot=01 Driver=btusb
      E:  Ad=83(I) Atr=01(Isoc) MxPS=  32 Ivl=1ms
      E:  Ad=03(O) Atr=01(Isoc) MxPS=  32 Ivl=1ms
      I:  If#= 1 Alt= 4 #EPs= 2 Cls=e0(wlcon) Sub=01 Prot=01 Driver=btusb
      E:  Ad=83(I) Atr=01(Isoc) MxPS=  64 Ivl=1ms
      E:  Ad=03(O) Atr=01(Isoc) MxPS=  64 Ivl=1ms
      I:  If#= 1 Alt= 5 #EPs= 2 Cls=e0(wlcon) Sub=01 Prot=01 Driver=btusb
      E:  Ad=83(I) Atr=01(Isoc) MxPS=  64 Ivl=1ms
      E:  Ad=03(O) Atr=01(Isoc) MxPS=  64 Ivl=1ms
      I:* If#= 2 Alt= 0 #EPs= 2 Cls=ff(vend.) Sub=ff Prot=ff Driver=(none)
      E:  Ad=84(I) Atr=02(Bulk) MxPS=  32 Ivl=0ms
      E:  Ad=04(O) Atr=02(Bulk) MxPS=  32 Ivl=0ms
      I:* If#= 3 Alt= 0 #EPs= 0 Cls=fe(app. ) Sub=01 Prot=01 Driver=(none)
      Signed-off-by: NEdgar (gimli) Hucek <gimli@dark-green.com>
      Acked-by: NMarcel Holtmann <marcel@holtmann.org>
      Signed-off-by: NGustavo F. Padovan <padovan@profusion.mobi>
      3e3ede7d
    • L
      Bluetooth: fix not setting security level when creating a rfcomm session · 63ce0900
      Luiz Augusto von Dentz 提交于
      This cause 'No Bonding' to be used if userspace has not yet been paired
      with remote device since the l2cap socket used to create the rfcomm
      session does not have any security level set.
      Signed-off-by: NLuiz Augusto von Dentz <luiz.dentz-von@nokia.com>
      Acked-by: NVille Tervo <ville.tervo@nokia.com>
      Acked-by: NMarcel Holtmann <marcel@holtmann.org>
      Signed-off-by: NGustavo F. Padovan <padovan@profusion.mobi>
      63ce0900
    • G
      Bluetooth: fix endianness conversion in L2CAP · 4f8b691c
      Gustavo F. Padovan 提交于
      Last commit added a wrong endianness conversion. Fixing that.
      Reported-by: NHarvey Harrison <harvey.harrison@gmail.com>
      Signed-off-by: NGustavo F. Padovan <padovan@profusion.mobi>
      4f8b691c
    • S
      Bluetooth: fix unaligned access to l2cap conf data · bfaaeb3e
      steven miao 提交于
      In function l2cap_get_conf_opt() and l2cap_add_conf_opt() the address of
      opt->val sometimes is not at the edge of 2-bytes/4-bytes, so 2-bytes/4 bytes
      access will cause data misalignment exeception.  Use get_unaligned_le16/32
      and put_unaligned_le16/32 function to avoid data misalignment execption.
      Signed-off-by: Nsteven miao <realmz6@gmail.com>
      Signed-off-by: NMike Frysinger <vapier@gentoo.org>
      Acked-by: NMarcel Holtmann <marcel@holtmann.org>
      Signed-off-by: NGustavo F. Padovan <padovan@profusion.mobi>
      bfaaeb3e
    • M
      Bluetooth: Enable USB autosuspend by default on btusb · 556ea928
      Matthew Garrett 提交于
      We've done this for a while in Fedora without any obvious problems other
      than some interaction with input devices. Those should be fixed now, so
      let's try this in mainline.
      Signed-off-by: NMatthew Garrett <mjg@redhat.com>
      Acked-by: NMarcel Holtmann <marcel@holtmann.org>
      Signed-off-by: NGustavo F. Padovan <padovan@profusion.mobi>
      556ea928
    • J
      Bluetooth: Fix non-SSP auth request for HIGH security level sockets · bdb7524a
      Johan Hedberg 提交于
      When initiating dedicated bonding a L2CAP raw socket with HIGH security
      level is used. The kernel is supposed to trigger the authentication
      request in this case but this doesn't happen currently for non-SSP
      (pre-2.1) devices. The reason is that the authentication request happens
      in the remote extended features callback which never gets called for
      non-SSP devices. This patch fixes the issue by requesting also
      authentiation in the (normal) remote features callback in the case of
      non-SSP devices.
      
      This rule is applied only for HIGH security level which might at first
      seem unintuitive since on the server socket side MEDIUM is already
      enough for authentication. However, for the clients we really want to
      prefer the server side to decide the authentication requrement in most
      cases, and since most client sockets use MEDIUM it's better to be
      avoided on the kernel side for these sockets. The important socket to
      request it for is the dedicated bonding one and that socket uses HIGH
      security level.
      
      The patch is based on the initial investigation and patch proposal from
      Andrei Emeltchenko <endrei.emeltchenko@nokia.com>.
      Signed-off-by: NJohan Hedberg <johan.hedberg@nokia.com>
      Acked-by: NMarcel Holtmann <marcel@holtmann.org>
      Signed-off-by: NGustavo F. Padovan <padovan@profusion.mobi>
      bdb7524a
    • R
      Bluetooth: fix hidp kconfig dependency warning · 96c99b47
      Randy Dunlap 提交于
      Fix kconfig dependency warning to satisfy dependencies:
      
      warning: (BT_HIDP && NET && BT && BT_L2CAP && INPUT || USB_HID && HID_SUPPORT && USB && INPUT) selects HID which has unmet direct dependencies (HID_SUPPORT && INPUT)
      Signed-off-by: NRandy Dunlap <randy.dunlap@oracle.com>
      Acked-by: NMarcel Holtmann <marcel@holtmann.org>
      Signed-off-by: NGustavo F. Padovan <padovan@profusion.mobi>
      96c99b47
    • R
      ath9k_hw: Fix memory leak on ath9k_hw_rf_alloc_ext_banks failure · 48a7c3df
      Rajkumar Manoharan 提交于
      The allocated externel radio banks have to be freed in
      case of ath9k_hw_rf_alloc_ext_banks failure.
      
      Cc: stable@kernel.org
      Signed-off-by: NRajkumar Manoharan <rmanoharan@atheros.com>
      Signed-off-by: NJohn W. Linville <linville@tuxdriver.com>
      48a7c3df
    • R
      ath9k_htc: Fix probe failure if CONFIG_USB_DEBUG enabled · 490b3f4e
      Rajkumar Manoharan 提交于
      Since the endpoint descriptors (EP3 & EP4) were changed from Interrupt
      to Bulk type by firmware, the urb submission done on Bulk pipes.
      And the recent commit "check the endpoint type against the pipe type"
      added aditional error checking against pipe types under CONFIG_USB_DEBUG.
      
      So bmAttribute has to be updated for both EP3 & EP4 before submitting
      urbs on that pipe. This patch resolves the following failure.
      
      [ 2215.710936] usb 1-1: usb_probe_device
      [ 2215.710945] usb 1-1: configuration #1 chosen from 1 choice
      [ 2215.711152] usb 1-1: adding 1-1:1.0 (config #1, interface 0)
      [ 2215.711252] ath9k_hif_usb 1-1:1.0: usb_probe_interface
      [ 2215.711255] ath9k_hif_usb 1-1:1.0: usb_probe_interface - got id
      [ 2215.712780] usb 1-1: BOGUS urb xfer, pipe 3 != type 1
      [ 2215.713782] usb 1-1: ath9k_htc: Unable to allocate URBs
      [ 2215.713801] ath9k_hif_usb: probe of 1-1:1.0 failed with error -22
      Reported-by: NMing Lei <tom.leiming@gmail.com>
      Signed-off-by: NRajkumar Manoharan <rmanoharan@atheros.com>
      Signed-off-by: NJohn W. Linville <linville@tuxdriver.com>
      490b3f4e
    • H
      ath9k_htc: Add support for device ID 3346 · ac618d70
      Haitao Zhang 提交于
      This patch adds support for USB dongle with device ID 3346 from IMC Networks.
      Signed-off-by: NHaitao Zhang <minipanda@linuxrobot.org>
      Signed-off-by: NJohn W. Linville <linville@tuxdriver.com>
      ac618d70