1. 18 11月, 2022 6 次提交
  2. 17 11月, 2022 7 次提交
    • H
      net: use struct_group to copy ip/ipv6 header addresses · 58e0be1e
      Hangbin Liu 提交于
      kernel test robot reported warnings when build bonding module with
      make W=1 O=build_dir ARCH=x86_64 SHELL=/bin/bash drivers/net/bonding/:
      
                       from ../drivers/net/bonding/bond_main.c:35:
      In function ‘fortify_memcpy_chk’,
          inlined from ‘iph_to_flow_copy_v4addrs’ at ../include/net/ip.h:566:2,
          inlined from ‘bond_flow_ip’ at ../drivers/net/bonding/bond_main.c:3984:3:
      ../include/linux/fortify-string.h:413:25: warning: call to ‘__read_overflow2_field’ declared with attribute warning: detected read beyond size of f
      ield (2nd parameter); maybe use struct_group()? [-Wattribute-warning]
        413 |                         __read_overflow2_field(q_size_field, size);
            |                         ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
      In function ‘fortify_memcpy_chk’,
          inlined from ‘iph_to_flow_copy_v6addrs’ at ../include/net/ipv6.h:900:2,
          inlined from ‘bond_flow_ip’ at ../drivers/net/bonding/bond_main.c:3994:3:
      ../include/linux/fortify-string.h:413:25: warning: call to ‘__read_overflow2_field’ declared with attribute warning: detected read beyond size of f
      ield (2nd parameter); maybe use struct_group()? [-Wattribute-warning]
        413 |                         __read_overflow2_field(q_size_field, size);
            |                         ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
      
      This is because we try to copy the whole ip/ip6 address to the flow_key,
      while we only point the to ip/ip6 saddr. Note that since these are UAPI
      headers, __struct_group() is used to avoid the compiler warnings.
      Reported-by: Nkernel test robot <lkp@intel.com>
      Fixes: c3f83241 ("net: Add full IPv6 addresses to flow_keys")
      Signed-off-by: NHangbin Liu <liuhangbin@gmail.com>
      Link: https://lore.kernel.org/r/20221115142400.1204786-1-liuhangbin@gmail.comSigned-off-by: NPaolo Abeni <pabeni@redhat.com>
      58e0be1e
    • A
      net: usb: smsc95xx: fix external PHY reset · 809ff97a
      Alexandru Tachici 提交于
      An external PHY needs settling time after power up or reset.
      In the bind() function an mdio bus is registered. If at this point
      the external PHY is still initialising, no valid PHY ID will be
      read and on phy_find_first() the bind() function will fail.
      
      If an external PHY is present, wait the maximum time specified
      in 802.3 45.2.7.1.1.
      
      Fixes: 05b35e7e ("smsc95xx: add phylib support")
      Signed-off-by: NAlexandru Tachici <alexandru.tachici@analog.com>
      Reviewed-by: NAndrew Lunn <andrew@lunn.ch>
      Link: https://lore.kernel.org/r/20221115114434.9991-2-alexandru.tachici@analog.comSigned-off-by: NPaolo Abeni <pabeni@redhat.com>
      809ff97a
    • E
      net: usb: qmi_wwan: add Telit 0x103a composition · e103ba33
      Enrico Sau 提交于
      Add the following Telit LE910C4-WWX composition:
      
      0x103a: rmnet
      Signed-off-by: NEnrico Sau <enrico.sau@gmail.com>
      Acked-by: NBjørn Mork <bjorn@mork.no>
      Link: https://lore.kernel.org/r/20221115105859.14324-1-enrico.sau@gmail.comSigned-off-by: NPaolo Abeni <pabeni@redhat.com>
      e103ba33
    • W
      netdevsim: Fix memory leak of nsim_dev->fa_cookie · 064bc731
      Wang Yufen 提交于
      kmemleak reports this issue:
      
      unreferenced object 0xffff8881bac872d0 (size 8):
        comm "sh", pid 58603, jiffies 4481524462 (age 68.065s)
        hex dump (first 8 bytes):
          04 00 00 00 de ad be ef                          ........
        backtrace:
          [<00000000c80b8577>] __kmalloc+0x49/0x150
          [<000000005292b8c6>] nsim_dev_trap_fa_cookie_write+0xc1/0x210 [netdevsim]
          [<0000000093d78e77>] full_proxy_write+0xf3/0x180
          [<000000005a662c16>] vfs_write+0x1c5/0xaf0
          [<000000007aabf84a>] ksys_write+0xed/0x1c0
          [<000000005f1d2e47>] do_syscall_64+0x3b/0x90
          [<000000006001c6ec>] entry_SYSCALL_64_after_hwframe+0x63/0xcd
      
      The issue occurs in the following scenarios:
      
      nsim_dev_trap_fa_cookie_write()
        kmalloc() fa_cookie
        nsim_dev->fa_cookie = fa_cookie
      ..
      nsim_drv_remove()
      
      The fa_cookie allocked in nsim_dev_trap_fa_cookie_write() is not freed. To
      fix, add kfree(nsim_dev->fa_cookie) to nsim_drv_remove().
      
      Fixes: d3cbb907 ("netdevsim: add ACL trap reporting cookie as a metadata")
      Signed-off-by: NWang Yufen <wangyufen@huawei.com>
      Cc: Jiri Pirko <jiri@mellanox.com>
      Link: https://lore.kernel.org/r/1668504625-14698-1-git-send-email-wangyufen@huawei.comSigned-off-by: NJakub Kicinski <kuba@kernel.org>
      064bc731
    • L
      Merge tag 'for-linus-6.1-rc6-tag' of git://git.kernel.org/pub/scm/linux/kernel/git/xen/tip · cc675d22
      Linus Torvalds 提交于
      Pull xen fixes from Juergen Gross:
       "Two trivial cleanups, and three simple fixes"
      
      * tag 'for-linus-6.1-rc6-tag' of git://git.kernel.org/pub/scm/linux/kernel/git/xen/tip:
        xen/platform-pci: use define instead of literal number
        xen/platform-pci: add missing free_irq() in error path
        xen-pciback: Allow setting PCI_MSIX_FLAGS_MASKALL too
        xen/pcpu: fix possible memory leak in register_pcpu()
        x86/xen: Use kstrtobool() instead of strtobool()
      cc675d22
    • L
      Merge tag 'pinctrl-v6.1-4' of git://git.kernel.org/pub/scm/linux/kernel/git/linusw/linux-pinctrl · 31c9c4c5
      Linus Torvalds 提交于
      Pull pin control fixes from Linus Walleij:
       "Aere is a hopefully final round of pin control fixes. Nothing special,
        driver fixes and we caught a potential NULL pointer exception.
      
         - Fix a potential NULL dereference in the core!
      
         - Fix all pin mux routes in the Rockchop PX30 driver
      
         - Fix the UFS pins in the Qualcomm SC8280XP driver
      
         - Fix bias disabling in the Mediatek driver
      
         - Fix debounce time settings in the Mediatek driver"
      
      * tag 'pinctrl-v6.1-4' of git://git.kernel.org/pub/scm/linux/kernel/git/linusw/linux-pinctrl:
        pinctrl: mediatek: Export debounce time tables
        pinctrl: mediatek: Fix EINT pins input debounce time configuration
        pinctrl: devicetree: fix null pointer dereferencing in pinctrl_dt_to_map
        pinctrl: mediatek: common-v2: Fix bias-disable for PULL_PU_PD_RSEL_TYPE
        pinctrl: qcom: sc8280xp: Rectify UFS reset pins
        pinctrl: rockchip: list all pins in a possible mux route for PX30
      31c9c4c5
    • L
      Merge tag 'platform-drivers-x86-v6.1-4' of... · 941209ef
      Linus Torvalds 提交于
      Merge tag 'platform-drivers-x86-v6.1-4' of git://git.kernel.org/pub/scm/linux/kernel/git/pdx86/platform-drivers-x86
      
      Pull x86 platform driver fixes from Hans de Goede:
      
       - Surface Pro 9 and Surface Laptop 5 kbd, battery, etc support (this
         is just a few hw-id additions)
      
       - A couple of other hw-id / DMI-quirk additions
      
       - A few small bug fixes + 1 build fix
      
      * tag 'platform-drivers-x86-v6.1-4' of git://git.kernel.org/pub/scm/linux/kernel/git/pdx86/platform-drivers-x86:
        platform/x86: ideapad-laptop: Add module parameters to match DMI quirk tables
        platform/x86: ideapad-laptop: Fix interrupt storm on fn-lock toggle on some Yoga laptops
        platform/x86: hp-wmi: Ignore Smart Experience App event
        platform/surface: aggregator_registry: Add support for Surface Laptop 5
        platform/surface: aggregator_registry: Add support for Surface Pro 9
        platform/surface: aggregator: Do not check for repeated unsequenced packets
        platform/x86: acer-wmi: Enable SW_TABLET_MODE on Switch V 10 (SW5-017)
        platform/x86: asus-wmi: add missing pci_dev_put() in asus_wmi_set_xusb2pr()
        platform/x86/intel: pmc: Don't unconditionally attach Intel PMC when virtualized
        platform/x86: thinkpad_acpi: Enable s2idle quirk for 21A1 machine type
        platform/x86/amd: pmc: Add new ACPI ID AMDI0009
        platform/x86/amd: pmc: Remove more CONFIG_DEBUG_FS checks
      941209ef
  3. 16 11月, 2022 22 次提交
  4. 15 11月, 2022 5 次提交