1. 14 Feb, 2020 21 commits
    • Takashi Iwai's avatar
      ALSA: dummy: Fix PCM format loop in proc output · 8af95780
      Takashi Iwai authored
      commit 2acf25f1 upstream.
      
      The loop termination for iterating over all formats should contain
      SNDRV_PCM_FORMAT_LAST, not less than it.
      
      Fixes: 9b151fec ("ALSA: dummy - Add debug proc file")
      Cc: <stable@vger.kernel.org>
      Link: https://lore.kernel.org/r/20200201080530.22390-3-tiwai@suse.deSigned-off-by: default avatarTakashi Iwai <tiwai@suse.de>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      8af95780
    • Bryan O'Donoghue's avatar
      usb: gadget: f_ecm: Use atomic_t to track in-flight request · 5feb24e3
      Bryan O'Donoghue authored
      commit d710562e upstream.
      
      Currently ecm->notify_req is used to flag when a request is in-flight.
      ecm->notify_req is set to NULL and when a request completes it is
      subsequently reset.
      
      This is fundamentally buggy in that the unbind logic of the ECM driver will
      unconditionally free ecm->notify_req leading to a NULL pointer dereference.
      
      Fixes: da741b8c ("usb ethernet gadget: split CDC Ethernet function")
      Cc: stable <stable@vger.kernel.org>
      Signed-off-by: default avatarBryan O'Donoghue <bryan.odonoghue@linaro.org>
      Signed-off-by: default avatarFelipe Balbi <balbi@kernel.org>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      5feb24e3
    • Bryan O'Donoghue's avatar
      usb: gadget: f_ncm: Use atomic_t to track in-flight request · a5299a17
      Bryan O'Donoghue authored
      commit 5b24c28c upstream.
      
      Currently ncm->notify_req is used to flag when a request is in-flight.
      ncm->notify_req is set to NULL and when a request completes it is
      subsequently reset.
      
      This is fundamentally buggy in that the unbind logic of the NCM driver will
      unconditionally free ncm->notify_req leading to a NULL pointer dereference.
      
      Fixes: 40d133d7 ("usb: gadget: f_ncm: convert to new function interface with backward compatibility")
      Cc: stable <stable@vger.kernel.org>
      Signed-off-by: default avatarBryan O'Donoghue <bryan.odonoghue@linaro.org>
      Signed-off-by: default avatarFelipe Balbi <balbi@kernel.org>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      a5299a17
    • Roger Quadros's avatar
      usb: gadget: legacy: set max_speed to super-speed · cea1c152
      Roger Quadros authored
      commit 463f67ae upstream.
      
      These interfaces do support super-speed so let's not
      limit maximum speed to high-speed.
      
      Cc: <stable@vger.kernel.org>
      Signed-off-by: default avatarRoger Quadros <rogerq@ti.com>
      Signed-off-by: default avatarFelipe Balbi <balbi@kernel.org>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      cea1c152
    • Navid Emamdoost's avatar
      brcmfmac: Fix memory leak in brcmf_usbdev_qinit · 0f42ac5d
      Navid Emamdoost authored
      commit 4282dc05 upstream.
      
      In the implementation of brcmf_usbdev_qinit() the allocated memory for
      reqs is leaking if usb_alloc_urb() fails. Release reqs in the error
      handling path.
      
      Fixes: 71bb244b ("brcm80211: fmac: add USB support for bcm43235/6/8 chipsets")
      Signed-off-by: default avatarNavid Emamdoost <navid.emamdoost@gmail.com>
      Signed-off-by: default avatarKalle Valo <kvalo@codeaurora.org>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      0f42ac5d
    • Oliver Neukum's avatar
      mfd: dln2: More sanity checking for endpoints · 2b8aa1bd
      Oliver Neukum authored
      commit 2b8bd606 upstream.
      
      It is not enough to check for the number of endpoints.
      The types must also be correct.
      
      Reported-and-tested-by: syzbot+48a2851be24583b864dc@syzkaller.appspotmail.com
      Signed-off-by: default avatarOliver Neukum <oneukum@suse.com>
      Reviewed-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      Signed-off-by: default avatarLee Jones <lee.jones@linaro.org>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      2b8aa1bd
    • Will Deacon's avatar
      media: uvcvideo: Avoid cyclic entity chains due to malformed USB descriptors · f8734375
      Will Deacon authored
      commit 68035c80 upstream.
      
      Way back in 2017, fuzzing the 4.14-rc2 USB stack with syzkaller kicked
      up the following WARNING from the UVC chain scanning code:
      
        | list_add double add: new=ffff880069084010, prev=ffff880069084010,
        | next=ffff880067d22298.
        | ------------[ cut here ]------------
        | WARNING: CPU: 1 PID: 1846 at lib/list_debug.c:31 __list_add_valid+0xbd/0xf0
        | Modules linked in:
        | CPU: 1 PID: 1846 Comm: kworker/1:2 Not tainted
        | 4.14.0-rc2-42613-g1488251d1a98 #238
        | Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS Bochs 01/01/2011
        | Workqueue: usb_hub_wq hub_event
        | task: ffff88006b01ca40 task.stack: ffff880064358000
        | RIP: 0010:__list_add_valid+0xbd/0xf0 lib/list_debug.c:29
        | RSP: 0018:ffff88006435ddd0 EFLAGS: 00010286
        | RAX: 0000000000000058 RBX: ffff880067d22298 RCX: 0000000000000000
        | RDX: 0000000000000058 RSI: ffffffff85a58800 RDI: ffffed000c86bbac
        | RBP: ffff88006435dde8 R08: 1ffff1000c86ba52 R09: 0000000000000000
        | R10: 0000000000000002 R11: 0000000000000000 R12: ffff880069084010
        | R13: ffff880067d22298 R14: ffff880069084010 R15: ffff880067d222a0
        | FS:  0000000000000000(0000) GS:ffff88006c900000(0000) knlGS:0000000000000000
        | CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
        | CR2: 0000000020004ff2 CR3: 000000006b447000 CR4: 00000000000006e0
        | Call Trace:
        |  __list_add ./include/linux/list.h:59
        |  list_add_tail+0x8c/0x1b0 ./include/linux/list.h:92
        |  uvc_scan_chain_forward.isra.8+0x373/0x416
        | drivers/media/usb/uvc/uvc_driver.c:1471
        |  uvc_scan_chain drivers/media/usb/uvc/uvc_driver.c:1585
        |  uvc_scan_device drivers/media/usb/uvc/uvc_driver.c:1769
        |  uvc_probe+0x77f2/0x8f00 drivers/media/usb/uvc/uvc_driver.c:2104
      
      Looking into the output from usbmon, the interesting part is the
      following data packet:
      
        ffff880069c63e00 30710169 C Ci:1:002:0 0 143 = 09028f00 01030080
        00090403 00000e01 00000924 03000103 7c003328 010204db
      
      If we drop the lead configuration and interface descriptors, we're left
      with an output terminal descriptor describing a generic display:
      
        /* Output terminal descriptor */
        buf[0]	09
        buf[1]	24
        buf[2]	03	/* UVC_VC_OUTPUT_TERMINAL */
        buf[3]	00	/* ID */
        buf[4]	01	/* type == 0x0301 (UVC_OTT_DISPLAY) */
        buf[5]	03
        buf[6]	7c
        buf[7]	00	/* source ID refers to self! */
        buf[8]	33
      
      The problem with this descriptor is that it is self-referential: the
      source ID of 0 matches itself! This causes the 'struct uvc_entity'
      representing the display to be added to its chain list twice during
      'uvc_scan_chain()': once via 'uvc_scan_chain_entity()' when it is
      processed directly from the 'dev->entities' list and then again
      immediately afterwards when trying to follow the source ID in
      'uvc_scan_chain_forward()'
      
      Add a check before adding an entity to a chain list to ensure that the
      entity is not already part of a chain.
      
      Link: https://lore.kernel.org/linux-media/CAAeHK+z+Si69jUR+N-SjN9q4O+o5KFiNManqEa-PjUta7EOb7A@mail.gmail.com/
      
      Cc: <stable@vger.kernel.org>
      Fixes: c0efd232 ("V4L/DVB (8145a): USB Video Class driver")
      Reported-by: default avatarAndrey Konovalov <andreyknvl@google.com>
      Signed-off-by: default avatarWill Deacon <will@kernel.org>
      Signed-off-by: default avatarLaurent Pinchart <laurent.pinchart@ideasonboard.com>
      Signed-off-by: default avatarMauro Carvalho Chehab <mchehab+huawei@kernel.org>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      f8734375
    • Eric Dumazet's avatar
      tcp: clear tp->segs_{in|out} in tcp_disconnect() · 1f6f96b9
      Eric Dumazet authored
      [ Upstream commit 784f8344 ]
      
      tp->segs_in and tp->segs_out need to be cleared in tcp_disconnect().
      
      tcp_disconnect() is rarely used, but it is worth fixing it.
      
      Fixes: 2efd055c ("tcp: add tcpi_segs_in and tcpi_segs_out to tcp_info")
      Signed-off-by: default avatarEric Dumazet <edumazet@google.com>
      Cc: Marcelo Ricardo Leitner <mleitner@redhat.com>
      Cc: Yuchung Cheng <ycheng@google.com>
      Cc: Neal Cardwell <ncardwell@google.com>
      Acked-by: default avatarNeal Cardwell <ncardwell@google.com>
      Signed-off-by: default avatarJakub Kicinski <kuba@kernel.org>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      1f6f96b9
    • Eric Dumazet's avatar
      tcp: clear tp->data_segs{in|out} in tcp_disconnect() · 5022fce1
      Eric Dumazet authored
      [ Upstream commit db7ffee6 ]
      
      tp->data_segs_in and tp->data_segs_out need to be cleared
      in tcp_disconnect().
      
      tcp_disconnect() is rarely used, but it is worth fixing it.
      
      Fixes: a44d6eac ("tcp: Add RFC4898 tcpEStatsPerfDataSegsOut/In")
      Signed-off-by: default avatarEric Dumazet <edumazet@google.com>
      Cc: Martin KaFai Lau <kafai@fb.com>
      Cc: Yuchung Cheng <ycheng@google.com>
      Cc: Neal Cardwell <ncardwell@google.com>
      Acked-by: default avatarNeal Cardwell <ncardwell@google.com>
      Signed-off-by: default avatarJakub Kicinski <kuba@kernel.org>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      5022fce1
    • Eric Dumazet's avatar
      tcp: clear tp->delivered in tcp_disconnect() · f5b61093
      Eric Dumazet authored
      [ Upstream commit 2fbdd562 ]
      
      tp->delivered needs to be cleared in tcp_disconnect().
      
      tcp_disconnect() is rarely used, but it is worth fixing it.
      
      Fixes: ddf1af6f ("tcp: new delivery accounting")
      Signed-off-by: default avatarEric Dumazet <edumazet@google.com>
      Cc: Yuchung Cheng <ycheng@google.com>
      Cc: Neal Cardwell <ncardwell@google.com>
      Acked-by: default avatarYuchung Cheng <ycheng@google.com>
      Acked-by: default avatarNeal Cardwell <ncardwell@google.com>
      Acked-by: default avatarSoheil Hassas Yeganeh <soheil@google.com>
      Signed-off-by: default avatarJakub Kicinski <kuba@kernel.org>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      f5b61093
    • Eric Dumazet's avatar
      tcp: clear tp->total_retrans in tcp_disconnect() · b1e355a7
      Eric Dumazet authored
      [ Upstream commit c13c48c0 ]
      
      total_retrans needs to be cleared in tcp_disconnect().
      
      tcp_disconnect() is rarely used, but it is worth fixing it.
      
      Fixes: 1da177e4 ("Linux-2.6.12-rc2")
      Signed-off-by: default avatarEric Dumazet <edumazet@google.com>
      Cc: SeongJae Park <sjpark@amazon.de>
      Signed-off-by: default avatarJakub Kicinski <kuba@kernel.org>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      b1e355a7
    • David Howells's avatar
      rxrpc: Fix NULL pointer deref due to call->conn being cleared on disconnect · ae9cd076
      David Howells authored
      [ Upstream commit 5273a191 ]
      
      When a call is disconnected, the connection pointer from the call is
      cleared to make sure it isn't used again and to prevent further attempted
      transmission for the call.  Unfortunately, there might be a daemon trying
      to use it at the same time to transmit a packet.
      
      Fix this by keeping call->conn set, but setting a flag on the call to
      indicate disconnection instead.
      
      Remove also the bits in the transmission functions where the conn pointer is
      checked and a ref taken under spinlock as this is now redundant.
      
      Fixes: 8d94aa38 ("rxrpc: Calls shouldn't hold socket refs")
      Signed-off-by: default avatarDavid Howells <dhowells@redhat.com>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      ae9cd076
    • David Howells's avatar
      rxrpc: Fix insufficient receive notification generation · 362f28fc
      David Howells authored
      [ Upstream commit f71dbf2f ]
      
      In rxrpc_input_data(), rxrpc_notify_socket() is called if the base sequence
      number of the packet is immediately following the hard-ack point at the end
      of the function.  However, this isn't sufficient, since the recvmsg side
      may have been advancing the window and then overrun the position in which
      we're adding - at which point rx_hard_ack >= seq0 and no notification is
      generated.
      
      Fix this by always generating a notification at the end of the input
      function.
      
      Without this, a long call may stall, possibly indefinitely.
      
      Fixes: 248f219c ("rxrpc: Rewrite the data and ack handling code")
      Signed-off-by: default avatarDavid Howells <dhowells@redhat.com>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      362f28fc
    • Cong Wang's avatar
      net_sched: fix an OOB access in cls_tcindex · b974ac51
      Cong Wang authored
      [ Upstream commit 599be01e ]
      
      As Eric noticed, tcindex_alloc_perfect_hash() uses cp->hash
      to compute the size of memory allocation, but cp->hash is
      set again after the allocation, this caused an out-of-bound
      access.
      
      So we have to move all cp->hash initialization and computation
      before the memory allocation. Move cp->mask and cp->shift together
      as cp->hash may need them for computation too.
      
      Reported-and-tested-by: syzbot+35d4dea36c387813ed31@syzkaller.appspotmail.com
      Fixes: 331b7292 ("net: sched: RCU cls_tcindex")
      Cc: Eric Dumazet <eric.dumazet@gmail.com>
      Cc: John Fastabend <john.fastabend@gmail.com>
      Cc: Jamal Hadi Salim <jhs@mojatatu.com>
      Cc: Jiri Pirko <jiri@resnulli.us>
      Cc: Jakub Kicinski <kuba@kernel.org>
      Signed-off-by: default avatarCong Wang <xiyou.wangcong@gmail.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      b974ac51
    • Eric Dumazet's avatar
      net: hsr: fix possible NULL deref in hsr_handle_frame() · a29ce73f
      Eric Dumazet authored
      [ Upstream commit 2b5b8251 ]
      
      hsr_port_get_rcu() can return NULL, so we need to be careful.
      
      general protection fault, probably for non-canonical address 0xdffffc0000000006: 0000 [#1] PREEMPT SMP KASAN
      KASAN: null-ptr-deref in range [0x0000000000000030-0x0000000000000037]
      CPU: 1 PID: 10249 Comm: syz-executor.5 Not tainted 5.5.0-syzkaller #0
      Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011
      RIP: 0010:__read_once_size include/linux/compiler.h:199 [inline]
      RIP: 0010:hsr_addr_is_self+0x86/0x330 net/hsr/hsr_framereg.c:44
      Code: 04 00 f3 f3 f3 65 48 8b 04 25 28 00 00 00 48 89 45 d0 31 c0 e8 6b ff 94 f9 4c 89 f2 48 b8 00 00 00 00 00 fc ff df 48 c1 ea 03 <80> 3c 02 00 0f 85 75 02 00 00 48 8b 43 30 49 39 c6 49 89 47 c0 0f
      RSP: 0018:ffffc90000da8a90 EFLAGS: 00010206
      RAX: dffffc0000000000 RBX: 0000000000000000 RCX: ffffffff87e0cc33
      RDX: 0000000000000006 RSI: ffffffff87e035d5 RDI: 0000000000000000
      RBP: ffffc90000da8b20 R08: ffff88808e7de040 R09: ffffed1015d2707c
      R10: ffffed1015d2707b R11: ffff8880ae9383db R12: ffff8880a689bc5e
      R13: 1ffff920001b5153 R14: 0000000000000030 R15: ffffc90000da8af8
      FS:  00007fd7a42be700(0000) GS:ffff8880ae900000(0000) knlGS:0000000000000000
      CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
      CR2: 0000001b32338000 CR3: 00000000a928c000 CR4: 00000000001406e0
      DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
      DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
      Call Trace:
       <IRQ>
       hsr_handle_frame+0x1c5/0x630 net/hsr/hsr_slave.c:31
       __netif_receive_skb_core+0xfbc/0x30b0 net/core/dev.c:5099
       __netif_receive_skb_one_core+0xa8/0x1a0 net/core/dev.c:5196
       __netif_receive_skb+0x2c/0x1d0 net/core/dev.c:5312
       process_backlog+0x206/0x750 net/core/dev.c:6144
       napi_poll net/core/dev.c:6582 [inline]
       net_rx_action+0x508/0x1120 net/core/dev.c:6650
       __do_softirq+0x262/0x98c kernel/softirq.c:292
       do_softirq_own_stack+0x2a/0x40 arch/x86/entry/entry_64.S:1082
       </IRQ>
      
      Fixes: c5a75911 ("net/hsr: Use list_head (and rcu) instead of array for slave devices.")
      Signed-off-by: default avatarEric Dumazet <edumazet@google.com>
      Reported-by: default avatarsyzbot <syzkaller@googlegroups.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      a29ce73f
    • Taehee Yoo's avatar
      gtp: use __GFP_NOWARN to avoid memalloc warning · 16c0f943
      Taehee Yoo authored
      [ Upstream commit bd5cd35b ]
      
      gtp hashtable size is received by user-space.
      So, this hashtable size could be too large. If so, kmalloc will internally
      print a warning message.
      This warning message is actually not necessary for the gtp module.
      So, this patch adds __GFP_NOWARN to avoid this message.
      
      Splat looks like:
      [ 2171.200049][ T1860] WARNING: CPU: 1 PID: 1860 at mm/page_alloc.c:4713 __alloc_pages_nodemask+0x2f3/0x740
      [ 2171.238885][ T1860] Modules linked in: gtp veth openvswitch nsh nf_conncount nf_nat nf_conntrack nf_defrag_ipv]
      [ 2171.262680][ T1860] CPU: 1 PID: 1860 Comm: gtp-link Not tainted 5.5.0+ #321
      [ 2171.263567][ T1860] Hardware name: innotek GmbH VirtualBox/VirtualBox, BIOS VirtualBox 12/01/2006
      [ 2171.264681][ T1860] RIP: 0010:__alloc_pages_nodemask+0x2f3/0x740
      [ 2171.265332][ T1860] Code: 64 fe ff ff 65 48 8b 04 25 c0 0f 02 00 48 05 f0 12 00 00 41 be 01 00 00 00 49 89 47 0
      [ 2171.267301][ T1860] RSP: 0018:ffff8880b51af1f0 EFLAGS: 00010246
      [ 2171.268320][ T1860] RAX: ffffed1016a35e43 RBX: 0000000000000000 RCX: 0000000000000000
      [ 2171.269517][ T1860] RDX: 0000000000000000 RSI: 000000000000000b RDI: 0000000000000000
      [ 2171.270305][ T1860] RBP: 0000000000040cc0 R08: ffffed1018893109 R09: dffffc0000000000
      [ 2171.275973][ T1860] R10: 0000000000000001 R11: ffffed1018893108 R12: 1ffff11016a35e43
      [ 2171.291039][ T1860] R13: 000000000000000b R14: 000000000000000b R15: 00000000000f4240
      [ 2171.292328][ T1860] FS:  00007f53cbc83740(0000) GS:ffff8880da000000(0000) knlGS:0000000000000000
      [ 2171.293409][ T1860] CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
      [ 2171.294586][ T1860] CR2: 000055f540014508 CR3: 00000000b49f2004 CR4: 00000000000606e0
      [ 2171.295424][ T1860] Call Trace:
      [ 2171.295756][ T1860]  ? mark_held_locks+0xa5/0xe0
      [ 2171.296659][ T1860]  ? __alloc_pages_slowpath+0x21b0/0x21b0
      [ 2171.298283][ T1860]  ? gtp_encap_enable_socket+0x13e/0x400 [gtp]
      [ 2171.298962][ T1860]  ? alloc_pages_current+0xc1/0x1a0
      [ 2171.299475][ T1860]  kmalloc_order+0x22/0x80
      [ 2171.299936][ T1860]  kmalloc_order_trace+0x1d/0x140
      [ 2171.300437][ T1860]  __kmalloc+0x302/0x3a0
      [ 2171.300896][ T1860]  gtp_newlink+0x293/0xba0 [gtp]
      [ ... ]
      
      Fixes: 459aa660 ("gtp: add initial driver for datapath of GPRS Tunneling Protocol (GTP-U)")
      Signed-off-by: default avatarTaehee Yoo <ap420073@gmail.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      16c0f943
    • Eric Dumazet's avatar
      cls_rsvp: fix rsvp_policy · d157f114
      Eric Dumazet authored
      [ Upstream commit cb3c0e6b ]
      
      NLA_BINARY can be confusing, since .len value represents
      the max size of the blob.
      
      cls_rsvp really wants user space to provide long enough data
      for TCA_RSVP_DST and TCA_RSVP_SRC attributes.
      
      BUG: KMSAN: uninit-value in rsvp_get net/sched/cls_rsvp.h:258 [inline]
      BUG: KMSAN: uninit-value in gen_handle net/sched/cls_rsvp.h:402 [inline]
      BUG: KMSAN: uninit-value in rsvp_change+0x1ae9/0x4220 net/sched/cls_rsvp.h:572
      CPU: 1 PID: 13228 Comm: syz-executor.1 Not tainted 5.5.0-rc5-syzkaller #0
      Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011
      Call Trace:
       __dump_stack lib/dump_stack.c:77 [inline]
       dump_stack+0x1c9/0x220 lib/dump_stack.c:118
       kmsan_report+0xf7/0x1e0 mm/kmsan/kmsan_report.c:118
       __msan_warning+0x58/0xa0 mm/kmsan/kmsan_instr.c:215
       rsvp_get net/sched/cls_rsvp.h:258 [inline]
       gen_handle net/sched/cls_rsvp.h:402 [inline]
       rsvp_change+0x1ae9/0x4220 net/sched/cls_rsvp.h:572
       tc_new_tfilter+0x31fe/0x5010 net/sched/cls_api.c:2104
       rtnetlink_rcv_msg+0xcb7/0x1570 net/core/rtnetlink.c:5415
       netlink_rcv_skb+0x451/0x650 net/netlink/af_netlink.c:2477
       rtnetlink_rcv+0x50/0x60 net/core/rtnetlink.c:5442
       netlink_unicast_kernel net/netlink/af_netlink.c:1302 [inline]
       netlink_unicast+0xf9e/0x1100 net/netlink/af_netlink.c:1328
       netlink_sendmsg+0x1248/0x14d0 net/netlink/af_netlink.c:1917
       sock_sendmsg_nosec net/socket.c:639 [inline]
       sock_sendmsg net/socket.c:659 [inline]
       ____sys_sendmsg+0x12b6/0x1350 net/socket.c:2330
       ___sys_sendmsg net/socket.c:2384 [inline]
       __sys_sendmsg+0x451/0x5f0 net/socket.c:2417
       __do_sys_sendmsg net/socket.c:2426 [inline]
       __se_sys_sendmsg+0x97/0xb0 net/socket.c:2424
       __x64_sys_sendmsg+0x4a/0x70 net/socket.c:2424
       do_syscall_64+0xb8/0x160 arch/x86/entry/common.c:296
       entry_SYSCALL_64_after_hwframe+0x44/0xa9
      RIP: 0033:0x45b349
      Code: ad b6 fb ff c3 66 2e 0f 1f 84 00 00 00 00 00 66 90 48 89 f8 48 89 f7 48 89 d6 48 89 ca 4d 89 c2 4d 89 c8 4c 8b 4c 24 08 0f 05 <48> 3d 01 f0 ff ff 0f 83 7b b6 fb ff c3 66 2e 0f 1f 84 00 00 00 00
      RSP: 002b:00007f269d43dc78 EFLAGS: 00000246 ORIG_RAX: 000000000000002e
      RAX: ffffffffffffffda RBX: 00007f269d43e6d4 RCX: 000000000045b349
      RDX: 0000000000000000 RSI: 00000000200001c0 RDI: 0000000000000003
      RBP: 000000000075bfc8 R08: 0000000000000000 R09: 0000000000000000
      R10: 0000000000000000 R11: 0000000000000246 R12: 00000000ffffffff
      R13: 00000000000009c2 R14: 00000000004cb338 R15: 000000000075bfd4
      
      Uninit was created at:
       kmsan_save_stack_with_flags mm/kmsan/kmsan.c:144 [inline]
       kmsan_internal_poison_shadow+0x66/0xd0 mm/kmsan/kmsan.c:127
       kmsan_slab_alloc+0x8a/0xe0 mm/kmsan/kmsan_hooks.c:82
       slab_alloc_node mm/slub.c:2774 [inline]
       __kmalloc_node_track_caller+0xb40/0x1200 mm/slub.c:4382
       __kmalloc_reserve net/core/skbuff.c:141 [inline]
       __alloc_skb+0x2fd/0xac0 net/core/skbuff.c:209
       alloc_skb include/linux/skbuff.h:1049 [inline]
       netlink_alloc_large_skb net/netlink/af_netlink.c:1174 [inline]
       netlink_sendmsg+0x7d3/0x14d0 net/netlink/af_netlink.c:1892
       sock_sendmsg_nosec net/socket.c:639 [inline]
       sock_sendmsg net/socket.c:659 [inline]
       ____sys_sendmsg+0x12b6/0x1350 net/socket.c:2330
       ___sys_sendmsg net/socket.c:2384 [inline]
       __sys_sendmsg+0x451/0x5f0 net/socket.c:2417
       __do_sys_sendmsg net/socket.c:2426 [inline]
       __se_sys_sendmsg+0x97/0xb0 net/socket.c:2424
       __x64_sys_sendmsg+0x4a/0x70 net/socket.c:2424
       do_syscall_64+0xb8/0x160 arch/x86/entry/common.c:296
       entry_SYSCALL_64_after_hwframe+0x44/0xa9
      
      Fixes: 6fa8c014 ("[NET_SCHED]: Use nla_policy for attribute validation in classifiers")
      Signed-off-by: default avatarEric Dumazet <edumazet@google.com>
      Reported-by: default avatarsyzbot <syzkaller@googlegroups.com>
      Acked-by: default avatarCong Wang <xiyou.wangcong@gmail.com>
      Signed-off-by: default avatarJakub Kicinski <kuba@kernel.org>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      d157f114
    • Nobuhiro Iwamatsu's avatar
      ASoC: qcom: Fix of-node refcount unbalance to link->codec_of_node · e080b6ea
      Nobuhiro Iwamatsu authored
      [ This is a fix specific to 4.4.y and 4.9.y stable trees;
        4.14.y and older are not affected ]
      
      The of-node refcount fixes were made in commit 8d166720 ("ASoC: qcom:
      Fix of-node refcount unbalance in apq8016_sbc_parse_of()"), but not enough
      in 4.4.y and 4.9.y. The modification of link->codec_of_node is missing.
      This fixes of-node refcount unbalance to link->codec_of_node.
      
      Fixes: 8d166720 ("ASoC: qcom: Fix of-node refcount unbalance in apq8016_sbc_parse_of()")
      Cc: Patrick Lai <plai@codeaurora.org>
      Cc: Banajit Goswami <bgoswami@codeaurora.org>
      Cc: Takashi Iwai <tiwai@suse.de>
      Cc: Mark Brown <broonie@kernel.org>
      Cc: Sasha Levin <sashal@kernel.org>
      Signed-off-by: default avatarNobuhiro Iwamatsu <nobuhiro1.iwamatsu@toshiba.co.jp>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      e080b6ea
    • Arnd Bergmann's avatar
      sparc32: fix struct ipc64_perm type definition · 7c756a4a
      Arnd Bergmann authored
      [ Upstream commit 34ca70ef ]
      
      As discussed in the strace issue tracker, it appears that the sparc32
      sysvipc support has been broken for the past 11 years. It was however
      working in compat mode, which is how it must have escaped most of the
      regular testing.
      
      The problem is that a cleanup patch inadvertently changed the uid/gid
      fields in struct ipc64_perm from 32-bit types to 16-bit types in uapi
      headers.
      
      Both glibc and uclibc-ng still use the original types, so they should
      work fine with compat mode, but not natively.  Change the definitions
      to use __kernel_uid32_t and __kernel_gid32_t again.
      
      Fixes: 83c86984 ("sparc: unify ipcbuf.h")
      Link: https://github.com/strace/strace/issues/116
      Cc: <stable@vger.kernel.org> # v2.6.29
      Cc: Sam Ravnborg <sam@ravnborg.org>
      Cc: "Dmitry V . Levin" <ldv@altlinux.org>
      Cc: Rich Felker <dalias@libc.org>
      Cc: libc-alpha@sourceware.org
      Signed-off-by: default avatarArnd Bergmann <arnd@arndb.de>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      Signed-off-by: default avatarSasha Levin <sashal@kernel.org>
      7c756a4a
    • Pawan Gupta's avatar
      x86/cpu: Update cached HLE state on write to TSX_CTRL_CPUID_CLEAR · 09cc3fd9
      Pawan Gupta authored
      [ Upstream commit 5efc6fa9 ]
      
      /proc/cpuinfo currently reports Hardware Lock Elision (HLE) feature to
      be present on boot cpu even if it was disabled during the bootup. This
      is because cpuinfo_x86->x86_capability HLE bit is not updated after TSX
      state is changed via the new MSR IA32_TSX_CTRL.
      
      Update the cached HLE bit also since it is expected to change after an
      update to CPUID_CLEAR bit in MSR IA32_TSX_CTRL.
      
      Fixes: 95c5824f ("x86/cpu: Add a "tsx=" cmdline option with TSX disabled by default")
      Signed-off-by: default avatarPawan Gupta <pawan.kumar.gupta@linux.intel.com>
      Signed-off-by: default avatarThomas Gleixner <tglx@linutronix.de>
      Tested-by: default avatarNeelima Krishnan <neelima.krishnan@intel.com>
      Reviewed-by: default avatarDave Hansen <dave.hansen@linux.intel.com>
      Reviewed-by: default avatarJosh Poimboeuf <jpoimboe@redhat.com>
      Cc: stable@vger.kernel.org
      Link: https://lore.kernel.org/r/2529b99546294c893dfa1c89e2b3e46da3369a59.1578685425.git.pawan.kumar.gupta@linux.intel.comSigned-off-by: default avatarSasha Levin <sashal@kernel.org>
      09cc3fd9
    • Johan Hovold's avatar
      media: iguanair: fix endpoint sanity check · ab42c566
      Johan Hovold authored
      [ Upstream commit 1b257870 ]
      
      Make sure to use the current alternate setting, which need not be the
      first one by index, when verifying the endpoint descriptors and
      initialising the URBs.
      
      Failing to do so could cause the driver to misbehave or trigger a WARN()
      in usb_submit_urb() that kernels with panic_on_warn set would choke on.
      
      Fixes: 26ff6313 ("[media] Add support for the IguanaWorks USB IR Transceiver")
      Fixes: ab1cbdf1 ("media: iguanair: add sanity checks")
      Cc: stable <stable@vger.kernel.org>     # 3.6
      Cc: Oliver Neukum <oneukum@suse.com>
      Signed-off-by: default avatarJohan Hovold <johan@kernel.org>
      Signed-off-by: default avatarSean Young <sean@mess.org>
      Signed-off-by: default avatarMauro Carvalho Chehab <mchehab+huawei@kernel.org>
      Signed-off-by: default avatarSasha Levin <sashal@kernel.org>
      ab42c566
  2. 05 Feb, 2020 19 commits