1. 29 Jan, 2021 21 commits
    • Linus Torvalds's avatar
      Merge tag 'for-5.11-rc5-tag' of git://git.kernel.org/pub/scm/linux/kernel/git/kdave/linux · c05d51c7
      Linus Torvalds authored
      Pull btrfs fixes from David Sterba:
       "A few more fixes for a late rc:
      
         - fix lockdep complaint on 32bit arches and also remove an unsafe
           memory use due to device vs filesystem lifetime
      
         - two fixes for free space tree:
      
            * race during log replay and cache rebuild, now more likely to
              happen due to changes in this dev cycle
      
            * possible free space tree corruption with online conversion
              during initial tree population"
      
      * tag 'for-5.11-rc5-tag' of git://git.kernel.org/pub/scm/linux/kernel/git/kdave/linux:
        btrfs: fix log replay failure due to race with space cache rebuild
        btrfs: fix lockdep warning due to seqcount_mutex on 32bit arch
        btrfs: fix possible free space tree corruption with online conversion
      c05d51c7
    • Linus Torvalds's avatar
      Merge tag 'block-5.11-2021-01-29' of git://git.kernel.dk/linux-block · 2ba1c4d1
      Linus Torvalds authored
      Pull block fixes from Jens Axboe:
       "All over the place fixes for this release:
      
         - blk-cgroup iteration teardown resched fix (Baolin)
      
         - NVMe pull request from Christoph:
              - add another Write Zeroes quirk (Chaitanya Kulkarni)
              - handle a no path available corner case (Daniel Wagner)
              - use the proper RCU aware list_add helper (Chao Leng)
      
         - bcache regression fix (Coly)
      
         - bdev->bd_size_lock IRQ fix. This will be fixed in drivers for 5.12,
           but for now, we'll make it IRQ safe (Damien)
      
         - null_blk zoned init fix (Damien)
      
         - add_partition() error handling fix (Dinghao)
      
         - s390 dasd kobject fix (Jan)
      
         - nbd fix for freezing queue while adding connections (Josef)
      
         - tag queueing regression fix (Ming)
      
         - revert of a patch that inadvertently meant that we regressed write
           performance on raid (Maxim)"
      
      * tag 'block-5.11-2021-01-29' of git://git.kernel.dk/linux-block:
        null_blk: cleanup zoned mode initialization
        nvme-core: use list_add_tail_rcu instead of list_add_tail for nvme_init_ns_head
        nvme-multipath: Early exit if no path is available
        nvme-pci: add the DISABLE_WRITE_ZEROES quirk for a SPCC device
        bcache: only check feature sets when sb->version >= BCACHE_SB_VERSION_CDEV_WITH_FEATURES
        block: fix bd_size_lock use
        blk-cgroup: Use cond_resched() when destroy blkgs
        Revert "block: simplify set_init_blocksize" to regain lost performance
        nbd: freeze the queue while we're adding connections
        s390/dasd: Fix inconsistent kobject removal
        block: Fix an error handling in add_partition
        blk-mq: test QUEUE_FLAG_HCTX_ACTIVE for sbitmap_shared in hctx_may_queue
      2ba1c4d1
    • Linus Torvalds's avatar
      Merge tag 'io_uring-5.11-2021-01-29' of git://git.kernel.dk/linux-block · c0ec4ffc
      Linus Torvalds authored
      Pull io_uring fixes from Jens Axboe:
       "We got the cancelation story sorted now, so for all intents and
        purposes, this should be it for 5.11 outside of any potential little
        fixes that may come in. This contains:
      
         - task_work task state fixes (Hao, Pavel)
      
         - Cancelation fixes (me, Pavel)
      
         - Fix for an inflight req patch in this release (Pavel)
      
         - Fix for a lock deadlock issue (Pavel)"
      
      * tag 'io_uring-5.11-2021-01-29' of git://git.kernel.dk/linux-block:
        io_uring: reinforce cancel on flush during exit
        io_uring: fix sqo ownership false positive warning
        io_uring: fix list corruption for splice file_get
        io_uring: fix flush cqring overflow list while TASK_INTERRUPTIBLE
        io_uring: fix wqe->lock/completion_lock deadlock
        io_uring: fix cancellation taking mutex while TASK_UNINTERRUPTIBLE
        io_uring: fix __io_uring_files_cancel() with TASK_UNINTERRUPTIBLE
        io_uring: only call io_cqring_ev_posted() if events were posted
        io_uring: if we see flush on exit, cancel related tasks
      c0ec4ffc
    • Linus Torvalds's avatar
      Merge tag 'iommu-fixes-v5.11-rc5' of git://git.kernel.org/pub/scm/linux/kernel/git/joro/iommu · 8ef24c20
      Linus Torvalds authored
      Pull iommu fixes from Joerg Roedel:
      
       - AMD IOMMU fix to make sure features are detected before they are
         queried.
      
       - Intel IOMMU address alignment check fix for an IOLTB flushing
         command.
      
       - Performance fix for Intel IOMMU to make sure the code does not do
         full IOTLB flushes all the time. Those flushes are very expensive
         on emulated IOMMUs.
      
      * tag 'iommu-fixes-v5.11-rc5' of git://git.kernel.org/pub/scm/linux/kernel/git/joro/iommu:
        iommu/vt-d: Do not use flush-queue when caching-mode is on
        iommu/vt-d: Correctly check addr alignment in qi_flush_dev_iotlb_pasid()
        iommu/amd: Use IVHD EFR for early initialization of IOMMU features
      8ef24c20
    • Linus Torvalds's avatar
      Merge tag 'pm-5.11-rc6' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm · 32b0c410
      Linus Torvalds authored
      Pull power management fixes from Rafael Wysocki:
       "These fix a deadlock in the 'kexec jump' code and address a possible
        hibernation image creation issue.
      
        Specifics:
      
         - Fix a deadlock caused by attempting to acquire the same mutex twice
           in a row in the "kexec jump" code (Baoquan He)
      
         - Modify the hibernation image saving code to flush the unwritten
           data to the swap storage later so as to avoid failing to write the
           image signature which is possible in some cases (Laurent Badel)"
      
      * tag 'pm-5.11-rc6' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm:
        PM: hibernate: flush swap writer after marking
        kernel: kexec: remove the lock operation of system_transition_mutex
      32b0c410
    • Linus Torvalds's avatar
      Merge tag 'acpi-5.11-rc6' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm · 016decc0
      Linus Torvalds authored
      Pull ACPI fixes from Rafael Wysocki:
       "These fix the handling of notifications in the ACPI thermal driver and
        address a device enumeration issue leading to the presence of multiple
        'MODALIAS=' entries in one uevent file in sysfs in some cases.
      
        Specifics:
      
         - Modify the ACPI thermal driver to avoid evaluating _TMP directly in
           its Notify () handler callback and running too many thermal checks
           for one thermal zone at the same time so as to address a work item
           accumulation issue observed on some systems that fail to shut down
           as a result of it (Rafael Wysocki)
      
         - Modify the ACPI uevent file creation code to avoid putting multiple
           'MODALIAS=' entries in one uevent file in sysfs which breaks
           systemd-udevd (Kai-Heng Feng)"
      
      * tag 'acpi-5.11-rc6' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm:
        ACPI: thermal: Do not call acpi_thermal_check() directly
        ACPI: sysfs: Prefer "compatible" modalias
      016decc0
    • Linus Torvalds's avatar
      Merge tag 'drm-fixes-2021-01-29' of git://anongit.freedesktop.org/drm/drm · 6305d15e
      Linus Torvalds authored
      Pull drm fixes from Dave Airlie:
       "Weekly fixes for graphics, nothing too major, nouveau has a few
        regression fixes for various fallout from header changes previously,
        vc4 has two fixes, two amdgpu, and a smattering of i915 fixes.
      
        All seems on course for a quieter rc7, fingers crossed.
      
        nouveau:
         - fix svm init conditions
         - fix nv50 modesetting regression
         - fix cursor plane modifiers
         - fix > 64x64 cursor regression
      
        vc4:
         - Fix LBM size calculation
         - Fix high resolutions for hvs5
      
        i915:
         - Fix ICL MG PHY vswing
         - Fix subplatform handling
         - Fix selftest memleak
         - Clear CACHE_MODE prior to clearing residuals
         - Always flush the active worker before returning from the wait
         - Always try to reserve GGTT address 0x0
      
        amdgpu:
         - Fix a fan control regression on some boards
         - Fix clang warning"
      
      * tag 'drm-fixes-2021-01-29' of git://anongit.freedesktop.org/drm/drm:
        drm/nouveau/kms/gk104-gp1xx: Fix > 64x64 cursors
        drm/nouveau/kms/nv50-: Report max cursor size to userspace
        drivers/nouveau/kms/nv50-: Reject format modifiers for cursor planes
        drm/nouveau/svm: fail NOUVEAU_SVM_INIT ioctl on unsupported devices
        drm/nouveau/dispnv50: Restore pushing of all data.
        amdgpu: fix clang build warning
        Revert "drm/amdgpu/swsmu: drop set_fan_speed_percent (v2)"
        drm/i915/gt: Always try to reserve GGTT address 0x0
        drm/i915: Always flush the active worker before returning from the wait
        drm/i915/selftest: Fix potential memory leak
        drm/i915: Check for all subplatform bits
        drm/i915: Fix ICL MG PHY vswing handling
        drm/i915/gt: Clear CACHE_MODE prior to clearing residuals
        drm/vc4: Correct POS1_SCL for hvs5
        drm/vc4: Correct lbm size and calculation
        drm/nouveau/nvif: fix method count when pushing an array
      6305d15e
    • Linus Torvalds's avatar
      tty: avoid using vfs_iocb_iter_write() for redirected console writes · a9cbbb80
      Linus Torvalds authored
      It turns out that the vfs_iocb_iter_{read,write}() functions are
      entirely broken, and don't actually use the passed-in file pointer for
      IO - only for the preparatory work (permission checking and for the
      write_iter function lookup).
      
      That worked fine for overlayfs, which always builds the new iocb with
      the same file pointer that it passes in, but in the general case it ends
      up doing nonsensical things (and could cause an iterator call that
      doesn't even match the passed-in file pointer).
      
      This subtly broke the tty conversion to write_iter in commit
      9bb48c82 ("tty: implement write_iter"), because the console
      redirection didn't actually end up redirecting anything, since the
      passed-in file pointer was basically ignored, and the actual write was
      done with the original non-redirected console tty after all.
      
      The main visible effect of this is that the console messages were no
      longer logged to /var/log/boot.log during graphical boot.
      
      Fix the issue by simply not using the vfs write "helper" function at
      all, and just redirecting the write entirely internally to the tty
      layer.  Do the target writability permission checks when actually
      registering the target tty with TIOCCONS instead of at write time.
      
      Fixes: 9bb48c82 ("tty: implement write_iter")
      Reported-and-tested-by: default avatarHans de Goede <hdegoede@redhat.com>
      Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
      Cc: stable@kernel.org
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      a9cbbb80
    • Rafael J. Wysocki's avatar
      Merge branch 'acpi-sysfs' · b584b7e9
      Rafael J. Wysocki authored
      * acpi-sysfs:
        ACPI: sysfs: Prefer "compatible" modalias
      b584b7e9
    • Damien Le Moal's avatar
      null_blk: cleanup zoned mode initialization · cd92cdb9
      Damien Le Moal authored
      To avoid potential compilation problems, replaced the badly written
      MB_TO_SECTS() macro (missing parenthesis around the argument use) with
      the inline function mb_to_sects(). And while at it, simplify the
      calculation of the total number of zones of the device using the
      round_up() macro.
      Signed-off-by: default avatarDamien Le Moal <damien.lemoal@wdc.com>
      Signed-off-by: default avatarJens Axboe <axboe@kernel.dk>
      cd92cdb9
    • Linus Torvalds's avatar
      Merge tag 'ecryptfs-5.11-rc6-setxattr-fix' of... · bec4c296
      Linus Torvalds authored
      Merge tag 'ecryptfs-5.11-rc6-setxattr-fix' of git://git.kernel.org/pub/scm/linux/kernel/git/tyhicks/ecryptfs
      
      Pull ecryptfs fix from Tyler Hicks:
       "Fix a regression that resulted in two rounds of UID translations when
        setting v3 namespaced file capabilities in some configurations"
      
      * tag 'ecryptfs-5.11-rc6-setxattr-fix' of git://git.kernel.org/pub/scm/linux/kernel/git/tyhicks/ecryptfs:
        ecryptfs: fix uid translation for setxattr on security.capability
      bec4c296
    • Dave Airlie's avatar
      Merge tag 'amd-drm-fixes-5.11-2021-01-28' of... · e0ecafed
      Dave Airlie authored
      Merge tag 'amd-drm-fixes-5.11-2021-01-28' of https://gitlab.freedesktop.org/agd5f/linux into drm-fixes
      
      amd-drm-fixes-5.11-2021-01-28:
      
      amdgpu:
      - Fix a fan control regression on some boards
      - Fix clang warning
      Signed-off-by: default avatarDave Airlie <airlied@redhat.com>
      From: Alex Deucher <alexdeucher@gmail.com>
      Link: https://patchwork.freedesktop.org/patch/msgid/20210128191558.3821-1-alexander.deucher@amd.com
      e0ecafed
    • Dave Airlie's avatar
      Merge tag 'drm-intel-fixes-2021-01-28' of... · 9a1054c3
      Dave Airlie authored
      Merge tag 'drm-intel-fixes-2021-01-28' of git://anongit.freedesktop.org/drm/drm-intel into drm-fixes
      
      drm/i915 fixes for v5.11-rc6:
      - Fix ICL MG PHY vswing
      - Fix subplatform handling
      - Fix selftest memleak
      - Clear CACHE_MODE prior to clearing residuals
      - Always flush the active worker before returning from the wait
      - Always try to reserve GGTT address 0x0
      Signed-off-by: default avatarDave Airlie <airlied@redhat.com>
      From: Jani Nikula <jani.nikula@intel.com>
      Link: https://patchwork.freedesktop.org/patch/msgid/87y2gdi3mp.fsf@intel.com
      9a1054c3
    • Dave Airlie's avatar
      Merge tag 'drm-misc-fixes-2021-01-27' of git://anongit.freedesktop.org/drm/drm-misc into drm-fixes · fb62b7b9
      Dave Airlie authored
      Short summary of fixes pull (less than what git shortlog provides):
      
       * drm/vc4: Fix LBM size calculation; Fix high resolutions for hvs5
      Signed-off-by: default avatarDave Airlie <airlied@redhat.com>
      
      From: Thomas Zimmermann <tzimmermann@suse.de>
      Link: https://patchwork.freedesktop.org/patch/msgid/YBEco1Vxeny8U/ca@linux-uq9g
      fb62b7b9
    • Dave Airlie's avatar
      Merge branch '04.01-ampere-lite' of git://github.com/skeggsb/linux into drm-fixes · 87bff758
      Dave Airlie authored
      Mostly a regression fixes here, a couple of which could lead to
      display hanging, and have been affecting a number of users.
      Signed-off-by: default avatarDave Airlie <airlied@redhat.com>
      From: Ben Skeggs <skeggsb@gmail.com>
      Link: https://patchwork.freedesktop.org/patch/msgid/CACAvsv4Y0ZiAevSvgphLAOaZjFi75ECXqUD9ShBvRxZ6S-pb9Q@mail.gmail.com
      87bff758
    • Lyude Paul's avatar
      drm/nouveau/kms/gk104-gp1xx: Fix > 64x64 cursors · ba839b75
      Lyude Paul authored
      While we do handle the additional cursor sizes introduced in NVE4, it looks
      like we accidentally broke this when converting over to use Nvidia's
      display headers. Since we now use NVVAL in dispnv50/head907d.c in order to
      format the value for the cursor layout and NVD9 only had one byte reserved
      vs. the 2 bytes reserved in later generations, we end up accidentally
      stripping the second bit in the cursor layout format parameter - causing us
      to set the wrong cursor size.
      
      This fixes that by adding our own curs_set hook for 917d which uses the
      NV917D headers.
      
      Cc: Martin Peres <martin.peres@free.fr>
      Cc: Jeremy Cline <jcline@redhat.com>
      Cc: Simon Ser <contact@emersion.fr>
      Cc: <stable@vger.kernel.org> # v5.9+
      Signed-off-by: default avatarLyude Paul <lyude@redhat.com>
      Fixes: ed0b86a9 ("drm/nouveau/kms/nv50-: use NVIDIA's headers for core head_curs_set()")
      Signed-off-by: default avatarBen Skeggs <bskeggs@redhat.com>
      ba839b75
    • Lyude Paul's avatar
      drm/nouveau/kms/nv50-: Report max cursor size to userspace · d3b2f0f7
      Lyude Paul authored
      Cc: Martin Peres <martin.peres@free.fr>
      Cc: Jeremy Cline <jcline@redhat.com>
      Cc: Simon Ser <contact@emersion.fr>
      Signed-off-by: default avatarLyude Paul <lyude@redhat.com>
      Tested-by: default avatarSimon Ser <contact@emersion.fr>
      Signed-off-by: default avatarBen Skeggs <bskeggs@redhat.com>
      d3b2f0f7
    • Lyude Paul's avatar
      drivers/nouveau/kms/nv50-: Reject format modifiers for cursor planes · 7c6d6598
      Lyude Paul authored
      Nvidia hardware doesn't actually support using tiling formats with the
      cursor plane, only linear is allowed. In the future, we should write a
      testcase for this.
      
      Fixes: c586f30b ("drm/nouveau/kms: Add format mod prop to base/ovly/nvdisp")
      Cc: James Jones <jajones@nvidia.com>
      Cc: Martin Peres <martin.peres@free.fr>
      Cc: Jeremy Cline <jcline@redhat.com>
      Cc: Simon Ser <contact@emersion.fr>
      Cc: <stable@vger.kernel.org> # v5.8+
      Signed-off-by: default avatarLyude Paul <lyude@redhat.com>
      Reviewed-by: default avatarSimon Ser <contact@emersion.fr>
      Reviewed-by: default avatarJames Jones <jajones@nvidia.com>
      Signed-off-by: default avatarBen Skeggs <bskeggs@redhat.com>
      7c6d6598
    • Karol Herbst's avatar
      drm/nouveau/svm: fail NOUVEAU_SVM_INIT ioctl on unsupported devices · dcd602cc
      Karol Herbst authored
      Fixes a crash when trying to create a channel on e.g. Turing GPUs when
      NOUVEAU_SVM_INIT was called before.
      
      Fixes: eeaf06ac ("drm/nouveau/svm: initial support for shared virtual memory")
      Signed-off-by: default avatarKarol Herbst <kherbst@redhat.com>
      Signed-off-by: default avatarBen Skeggs <bskeggs@redhat.com>
      dcd602cc
    • Bastian Beranek's avatar
      drm/nouveau/dispnv50: Restore pushing of all data. · fd55b61e
      Bastian Beranek authored
      Commit f844eb48 introduced a regression for
      NV50, which lead to visual artifacts, tearing and eventual crashes.
      
      In the changes of f844eb48 only the first line
      was correctly translated to the new NVIDIA header macros:
      
      -		PUSH_NVSQ(push, NV827C, 0x0110, 0,
      -					0x0114, 0);
      +		PUSH_MTHD(push, NV827C, SET_PROCESSING,
      +			  NVDEF(NV827C, SET_PROCESSING, USE_GAIN_OFS, DISABLE));
      
      The lower part ("0x0114, 0") was probably omitted by accident.
      
      This patch restores the push of the missing data and fixes the regression.
      Signed-off-by: default avatarBastian Beranek <bastian.beischer@rwth-aachen.de>
      Fixes: f844eb48 ("drm/nouveau/kms/nv50-: use NVIDIA's headers for wndw image_set()")
      Link: https://gitlab.freedesktop.org/drm/nouveau/-/issues/14Signed-off-by: default avatarBen Skeggs <bskeggs@redhat.com>
      fd55b61e
    • Pavel Begunkov's avatar
      io_uring: reinforce cancel on flush during exit · 3a7efd1a
      Pavel Begunkov authored
      What 84965ff8 ("io_uring: if we see flush on exit, cancel related tasks")
      really wants is to cancel all relevant REQ_F_INFLIGHT requests reliably.
      That can be achieved by io_uring_cancel_files(), but we'll miss it
      calling io_uring_cancel_task_requests(files=NULL) from io_uring_flush(),
      because it will go through __io_uring_cancel_task_requests().
      
      Just always call io_uring_cancel_files() during cancel, it's good enough
      for now.
      
      Cc: stable@vger.kernel.org # 5.9+
      Signed-off-by: default avatarPavel Begunkov <asml.silence@gmail.com>
      Signed-off-by: default avatarJens Axboe <axboe@kernel.dk>
      3a7efd1a
  2. 28 Jan, 2021 19 commits
    • Linus Torvalds's avatar
      Merge tag 'net-5.11-rc6' of git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net · 909b447d
      Linus Torvalds authored
      Pull networking fixes from Jakub Kicinski:
       "Networking fixes including fixes from can, xfrm, wireless,
        wireless-drivers and netfilter trees. Nothing scary, Intel
        WiFi-related fixes seemed most notable to the users.
      
        Current release - regressions:
      
         - dsa: microchip: ksz8795: fix KSZ8794 port map again to program the
           CPU port correctly
      
        Current release - new code bugs:
      
         - iwlwifi: pcie: reschedule in long-running memory reads
      
        Previous releases - regressions:
      
         - iwlwifi: dbg: don't try to overwrite read-only FW data
      
         - iwlwifi: provide gso_type to GSO packets
      
         - octeontx2: make sure the buffer is 128 byte aligned
      
         - tcp: make TCP_USER_TIMEOUT accurate for zero window probes
      
         - xfrm: fix wraparound in xfrm_policy_addr_delta()
      
         - xfrm: fix oops in xfrm_replay_advance_bmp due to a race between
           CPUs in presence of packet reorder
      
         - tcp: fix TLP timer not set when CA_STATE changes from DISORDER to
           OPEN
      
         - wext: fix NULL-ptr-dereference with cfg80211's lack of commit()
      
        Previous releases - always broken:
      
         - igc: fix link speed advertising
      
         - stmmac: configure EHL PSE0 GbE and PSE1 GbE to 32 bits DMA
           addressing
      
         - team: protect features update by RCU to avoid deadlock
      
         - xfrm: fix disable_xfrm sysctl when used on xfrm interfaces
           themselves
      
         - fec: fix temporary RMII clock reset on link up
      
         - can: dev: prevent potential information leak in can_fill_info()
      
        Misc:
      
         - mrp: fix bad packing of MRP test packet structures
      
         - uapi: fix big endian definition of ipv6_rpl_sr_hdr
      
         - add David Ahern to IPv4/IPv6 maintainers"
      
      * tag 'net-5.11-rc6' of git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net: (86 commits)
        rxrpc: Fix memory leak in rxrpc_lookup_local
        mlxsw: spectrum_span: Do not overwrite policer configuration
        selftests: forwarding: Specify interface when invoking mausezahn
        stmmac: intel: Configure EHL PSE0 GbE and PSE1 GbE to 32 bits DMA addressing
        net: usb: cdc_ether: added support for Thales Cinterion PLSx3 modem family.
        ibmvnic: Ensure that CRQ entry read are correctly ordered
        MAINTAINERS: add missing header for bonding
        net: decnet: fix netdev refcount leaking on error path
        net: switchdev: don't set port_obj_info->handled true when -EOPNOTSUPP
        can: dev: prevent potential information leak in can_fill_info()
        net: fec: Fix temporary RMII clock reset on link up
        net: lapb: Add locking to the lapb module
        team: protect features update by RCU to avoid deadlock
        MAINTAINERS: add David Ahern to IPv4/IPv6 maintainers
        net/mlx5: CT: Fix incorrect removal of tuple_nat_node from nat rhashtable
        net/mlx5e: Revert parameters on errors when changing MTU and LRO state without reset
        net/mlx5e: Revert parameters on errors when changing trust state without reset
        net/mlx5e: Correctly handle changing the number of queues when the interface is down
        net/mlx5e: Fix CT rule + encap slow path offload and deletion
        net/mlx5e: Disable hw-tc-offload when MLX5_CLS_ACT config is disabled
        ...
      909b447d
    • Takeshi Misawa's avatar
      rxrpc: Fix memory leak in rxrpc_lookup_local · b8323f72
      Takeshi Misawa authored
      Commit 9ebeddef ("rxrpc: rxrpc_peer needs to hold a ref on the rxrpc_local record")
      Then release ref in __rxrpc_put_peer and rxrpc_put_peer_locked.
      
      	struct rxrpc_peer *rxrpc_alloc_peer(struct rxrpc_local *local, gfp_t gfp)
      	-               peer->local = local;
      	+               peer->local = rxrpc_get_local(local);
      
      rxrpc_discard_prealloc also need ref release in discarding.
      
      syzbot report:
      BUG: memory leak
      unreferenced object 0xffff8881080ddc00 (size 256):
        comm "syz-executor339", pid 8462, jiffies 4294942238 (age 12.350s)
        hex dump (first 32 bytes):
          00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  ................
          00 00 00 00 0a 00 00 00 00 c0 00 08 81 88 ff ff  ................
        backtrace:
          [<000000002b6e495f>] kmalloc include/linux/slab.h:552 [inline]
          [<000000002b6e495f>] kzalloc include/linux/slab.h:682 [inline]
          [<000000002b6e495f>] rxrpc_alloc_local net/rxrpc/local_object.c:79 [inline]
          [<000000002b6e495f>] rxrpc_lookup_local+0x1c1/0x760 net/rxrpc/local_object.c:244
          [<000000006b43a77b>] rxrpc_bind+0x174/0x240 net/rxrpc/af_rxrpc.c:149
          [<00000000fd447a55>] afs_open_socket+0xdb/0x200 fs/afs/rxrpc.c:64
          [<000000007fd8867c>] afs_net_init+0x2b4/0x340 fs/afs/main.c:126
          [<0000000063d80ec1>] ops_init+0x4e/0x190 net/core/net_namespace.c:152
          [<00000000073c5efa>] setup_net+0xde/0x2d0 net/core/net_namespace.c:342
          [<00000000a6744d5b>] copy_net_ns+0x19f/0x3e0 net/core/net_namespace.c:483
          [<0000000017d3aec3>] create_new_namespaces+0x199/0x4f0 kernel/nsproxy.c:110
          [<00000000186271ef>] unshare_nsproxy_namespaces+0x9b/0x120 kernel/nsproxy.c:226
          [<000000002de7bac4>] ksys_unshare+0x2fe/0x5c0 kernel/fork.c:2957
          [<00000000349b12ba>] __do_sys_unshare kernel/fork.c:3025 [inline]
          [<00000000349b12ba>] __se_sys_unshare kernel/fork.c:3023 [inline]
          [<00000000349b12ba>] __x64_sys_unshare+0x12/0x20 kernel/fork.c:3023
          [<000000006d178ef7>] do_syscall_64+0x2d/0x70 arch/x86/entry/common.c:46
          [<00000000637076d4>] entry_SYSCALL_64_after_hwframe+0x44/0xa9
      
      Fixes: 9ebeddef ("rxrpc: rxrpc_peer needs to hold a ref on the rxrpc_local record")
      Signed-off-by: default avatarTakeshi Misawa <jeliantsurux@gmail.com>
      Reported-and-tested-by: syzbot+305326672fed51b205f7@syzkaller.appspotmail.com
      Signed-off-by: default avatarDavid Howells <dhowells@redhat.com>
      Link: https://lore.kernel.org/r/161183091692.3506637.3206605651502458810.stgit@warthog.procyon.org.ukSigned-off-by: default avatarJakub Kicinski <kuba@kernel.org>
      b8323f72
    • Jakub Kicinski's avatar
      Merge branch 'mlxsw-various-fixes' · 924b171c
      Jakub Kicinski authored
      Ido Schimmel says:
      
      ====================
      mlxsw: Various fixes
      
      Patch #1 fixes wrong invocation of mausezahn in a couple of selftests.
      The tests started failing after Fedora updated their libnet package from
      version 1.1.6 to 1.2.1. With the fix the tests pass regardless of libnet
      version.
      
      Patch #2 fixes an issue in the mirroring to CPU code that results in
      policer configuration being overwritten.
      ====================
      
      Link: https://lore.kernel.org/r/20210128144820.3280295-1-idosch@idosch.orgSigned-off-by: default avatarJakub Kicinski <kuba@kernel.org>
      924b171c
    • Ido Schimmel's avatar
      mlxsw: spectrum_span: Do not overwrite policer configuration · b6f6881a
      Ido Schimmel authored
      The purpose of the delayed work in the SPAN module is to potentially
      update the destination port and various encapsulation parameters of SPAN
      agents that point to a VLAN device or a GRE tap. The destination port
      can change following the insertion of a new route, for example.
      
      SPAN agents that point to a physical port or the CPU port are static and
      never change throughout the lifetime of the SPAN agent. Therefore, skip
      over them in the delayed work.
      
      This fixes an issue where the delayed work overwrites the policer
      that was set on a SPAN agent pointing to the CPU. Modifying the delayed
      work to inherit the original policer configuration is error-prone, as
      the same will be needed for any new parameter.
      
      Fixes: 4039504e ("mlxsw: spectrum_span: Allow setting policer on a SPAN agent")
      Reviewed-by: default avatarPetr Machata <petrm@nvidia.com>
      Signed-off-by: default avatarIdo Schimmel <idosch@nvidia.com>
      Signed-off-by: default avatarJakub Kicinski <kuba@kernel.org>
      b6f6881a
    • Danielle Ratson's avatar
      selftests: forwarding: Specify interface when invoking mausezahn · 11df27f7
      Danielle Ratson authored
      Specify the interface through which packets should be transmitted so
      that the test will pass regardless of the libnet version against which
      mausezahn is linked.
      
      Fixes: cab14d10 ("selftests: Add version of router_multipath.sh using nexthop objects")
      Fixes: 3d578d87 ("selftests: forwarding: Test IPv4 weighted nexthops")
      Signed-off-by: default avatarDanielle Ratson <danieller@nvidia.com>
      Signed-off-by: default avatarIdo Schimmel <idosch@nvidia.com>
      Signed-off-by: default avatarJakub Kicinski <kuba@kernel.org>
      11df27f7
    • Voon Weifeng's avatar
      stmmac: intel: Configure EHL PSE0 GbE and PSE1 GbE to 32 bits DMA addressing · 7cfc4486
      Voon Weifeng authored
      Fix an issue where dump stack is printed and Reset Adapter occurs when
      PSE0 GbE or/and PSE1 GbE is/are enabled. EHL PSE0 GbE and PSE1 GbE use
      32 bits DMA addressing whereas EHL PCH GbE uses 64 bits DMA addressing.
      
      [   25.535095] ------------[ cut here ]------------
      [   25.540276] NETDEV WATCHDOG: enp0s29f2 (intel-eth-pci): transmit queue 2 timed out
      [   25.548749] WARNING: CPU: 2 PID: 0 at net/sched/sch_generic.c:443 dev_watchdog+0x259/0x260
      [   25.558004] Modules linked in: 8021q bnep bluetooth ecryptfs snd_hda_codec_hdmi intel_gpy marvell intel_ishtp_loader intel_ishtp_hid iTCO_wdt mei_hdcp iTCO_vendor_support x86_pkg_temp_thermal kvm_intel dwmac_intel stmmac kvm igb pcs_xpcs irqbypass phylink snd_hda_intel intel_rapl_msr pcspkr dca snd_hda_codec i915 i2c_i801 i2c_smbus libphy intel_ish_ipc snd_hda_core mei_me intel_ishtp mei spi_dw_pci 8250_lpss spi_dw thermal dw_dmac_core parport_pc tpm_crb tpm_tis parport tpm_tis_core tpm intel_pmc_core sch_fq_codel uhid fuse configfs snd_sof_pci snd_sof_intel_byt snd_sof_intel_ipc snd_sof_intel_hda_common snd_sof_xtensa_dsp snd_sof snd_soc_acpi_intel_match snd_soc_acpi snd_intel_dspcfg ledtrig_audio snd_soc_core snd_compress ac97_bus snd_pcm snd_timer snd soundcore
      [   25.633795] CPU: 2 PID: 0 Comm: swapper/2 Tainted: G     U            5.11.0-rc4-intel-lts-MISMAIL5+ #5
      [   25.644306] Hardware name: Intel Corporation Elkhart Lake Embedded Platform/ElkhartLake LPDDR4x T4 RVP1, BIOS EHLSFWI1.R00.2434.A00.2010231402 10/23/2020
      [   25.659674] RIP: 0010:dev_watchdog+0x259/0x260
      [   25.664650] Code: e8 3b 6b 60 ff eb 98 4c 89 ef c6 05 ec e7 bf 00 01 e8 fb e5 fa ff 89 d9 4c 89 ee 48 c7 c7 78 31 d2 9e 48 89 c2 e8 79 1b 18 00 <0f> 0b e9 77 ff ff ff 0f 1f 44 00 00 48 c7 47 08 00 00 00 00 48 c7
      [   25.685647] RSP: 0018:ffffb7ca80160eb8 EFLAGS: 00010286
      [   25.691498] RAX: 0000000000000000 RBX: 0000000000000002 RCX: 0000000000000103
      [   25.699483] RDX: 0000000080000103 RSI: 00000000000000f6 RDI: 00000000ffffffff
      [   25.707465] RBP: ffff985709ce0440 R08: 0000000000000000 R09: c0000000ffffefff
      [   25.715455] R10: ffffb7ca80160cf0 R11: ffffb7ca80160ce8 R12: ffff985709ce039c
      [   25.723438] R13: ffff985709ce0000 R14: 0000000000000008 R15: ffff9857068af940
      [   25.731425] FS:  0000000000000000(0000) GS:ffff985864300000(0000) knlGS:0000000000000000
      [   25.740481] CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
      [   25.746913] CR2: 00005567f8bb76b8 CR3: 00000001f8e0a000 CR4: 0000000000350ee0
      [   25.754900] Call Trace:
      [   25.757631]  <IRQ>
      [   25.759891]  ? qdisc_put_unlocked+0x30/0x30
      [   25.764565]  ? qdisc_put_unlocked+0x30/0x30
      [   25.769245]  call_timer_fn+0x2e/0x140
      [   25.773346]  run_timer_softirq+0x1f3/0x430
      [   25.777932]  ? __hrtimer_run_queues+0x12c/0x2c0
      [   25.783005]  ? ktime_get+0x3e/0xa0
      [   25.786812]  __do_softirq+0xa6/0x2ef
      [   25.790816]  asm_call_irq_on_stack+0xf/0x20
      [   25.795501]  </IRQ>
      [   25.797852]  do_softirq_own_stack+0x5d/0x80
      [   25.802538]  irq_exit_rcu+0x94/0xb0
      [   25.806475]  sysvec_apic_timer_interrupt+0x42/0xc0
      [   25.811836]  asm_sysvec_apic_timer_interrupt+0x12/0x20
      [   25.817586] RIP: 0010:cpuidle_enter_state+0xd9/0x370
      [   25.823142] Code: 85 c0 0f 8f 0a 02 00 00 31 ff e8 22 d5 7e ff 45 84 ff 74 12 9c 58 f6 c4 02 0f 85 47 02 00 00 31 ff e8 7b a0 84 ff fb 45 85 f6 <0f> 88 ab 00 00 00 49 63 ce 48 2b 2c 24 48 89 c8 48 6b d1 68 48 c1
      [   25.844140] RSP: 0018:ffffb7ca800f7e80 EFLAGS: 00000206
      [   25.849996] RAX: ffff985864300000 RBX: 0000000000000003 RCX: 000000000000001f
      [   25.857975] RDX: 00000005f2028ea8 RSI: ffffffff9ec5907f RDI: ffffffff9ec62a5d
      [   25.865961] RBP: 00000005f2028ea8 R08: 0000000000000000 R09: 0000000000029d00
      [   25.873947] R10: 000000137b0e0508 R11: ffff9858643294e4 R12: ffff9858643336d0
      [   25.881935] R13: ffffffff9ef74b00 R14: 0000000000000003 R15: 0000000000000000
      [   25.889918]  cpuidle_enter+0x29/0x40
      [   25.893922]  do_idle+0x24a/0x290
      [   25.897536]  cpu_startup_entry+0x19/0x20
      [   25.901930]  start_secondary+0x128/0x160
      [   25.906326]  secondary_startup_64_no_verify+0xb0/0xbb
      [   25.911983] ---[ end trace b4c0c8195d0ba61f ]---
      [   25.917193] intel-eth-pci 0000:00:1d.2 enp0s29f2: Reset adapter.
      
      Fixes: 67c08ac4 ("net: stmmac: add EHL PSE0 & PSE1 1Gbps PCI info and PCI ID")
      Signed-off-by: default avatarVoon Weifeng <weifeng.voon@intel.com>
      Co-developed-by: default avatarMohammad Athari Bin Ismail <mohammad.athari.ismail@intel.com>
      Signed-off-by: default avatarMohammad Athari Bin Ismail <mohammad.athari.ismail@intel.com>
      Link: https://lore.kernel.org/r/20210126100844.30326-1-mohammad.athari.ismail@intel.comSigned-off-by: default avatarJakub Kicinski <kuba@kernel.org>
      7cfc4486
    • Giacinto Cifelli's avatar
      net: usb: cdc_ether: added support for Thales Cinterion PLSx3 modem family. · dad3a72f
      Giacinto Cifelli authored
      lsusb -v for this device:
      
      Bus 003 Device 007: ID 1e2d:0069
      Device Descriptor:
        bLength                18
        bDescriptorType         1
        bcdUSB               2.00
        bDeviceClass          239 Miscellaneous Device
        bDeviceSubClass         2 ?
        bDeviceProtocol         1 Interface Association
        bMaxPacketSize0        64
        idVendor           0x1e2d
        idProduct          0x0069
        bcdDevice            0.00
        iManufacturer           4 Cinterion Wireless Modules
        iProduct                3 PLSx3
        iSerial                 5 fa3c1419
        bNumConfigurations      1
        Configuration Descriptor:
          bLength                 9
          bDescriptorType         2
          wTotalLength          352
          bNumInterfaces         10
          bConfigurationValue     1
          iConfiguration          2 Cinterion Configuration
          bmAttributes         0xe0
            Self Powered
            Remote Wakeup
          MaxPower              500mA
          Interface Association:
            bLength                 8
            bDescriptorType        11
            bFirstInterface         0
            bInterfaceCount         2
            bFunctionClass          2 Communications
            bFunctionSubClass       2 Abstract (modem)
            bFunctionProtocol       1 AT-commands (v.25ter)
            iFunction               0
          Interface Descriptor:
            bLength                 9
            bDescriptorType         4
            bInterfaceNumber        0
            bAlternateSetting       0
            bNumEndpoints           1
            bInterfaceClass         2 Communications
            bInterfaceSubClass      2 Abstract (modem)
            bInterfaceProtocol      1 AT-commands (v.25ter)
            iInterface              0
            CDC Header:
              bcdCDC               1.10
            CDC ACM:
              bmCapabilities       0x02
                line coding and serial state
            CDC Call Management:
              bmCapabilities       0x03
                call management
                use DataInterface
              bDataInterface          1
            CDC Union:
              bMasterInterface        0
              bSlaveInterface         1
            Endpoint Descriptor:
              bLength                 7
              bDescriptorType         5
              bEndpointAddress     0x81  EP 1 IN
              bmAttributes            3
                Transfer Type            Interrupt
                Synch Type               None
                Usage Type               Data
              wMaxPacketSize     0x0040  1x 64 bytes
              bInterval               5
          Interface Descriptor:
            bLength                 9
            bDescriptorType         4
            bInterfaceNumber        1
            bAlternateSetting       0
            bNumEndpoints           2
            bInterfaceClass        10 CDC Data
            bInterfaceSubClass      0 Unused
            bInterfaceProtocol      0
            iInterface              0
            Endpoint Descriptor:
              bLength                 7
              bDescriptorType         5
              bEndpointAddress     0x82  EP 2 IN
              bmAttributes            2
                Transfer Type            Bulk
                Synch Type               None
                Usage Type               Data
              wMaxPacketSize     0x0200  1x 512 bytes
              bInterval               0
            Endpoint Descriptor:
              bLength                 7
              bDescriptorType         5
              bEndpointAddress     0x01  EP 1 OUT
              bmAttributes            2
                Transfer Type            Bulk
                Synch Type               None
                Usage Type               Data
              wMaxPacketSize     0x0200  1x 512 bytes
              bInterval               0
          Interface Association:
            bLength                 8
            bDescriptorType        11
            bFirstInterface         2
            bInterfaceCount         2
            bFunctionClass          2 Communications
            bFunctionSubClass       2 Abstract (modem)
            bFunctionProtocol       1 AT-commands (v.25ter)
            iFunction               0
          Interface Descriptor:
            bLength                 9
            bDescriptorType         4
            bInterfaceNumber        2
            bAlternateSetting       0
            bNumEndpoints           1
            bInterfaceClass         2 Communications
            bInterfaceSubClass      2 Abstract (modem)
            bInterfaceProtocol      1 AT-commands (v.25ter)
            iInterface              0
            CDC Header:
              bcdCDC               1.10
            CDC ACM:
              bmCapabilities       0x02
                line coding and serial state
            CDC Call Management:
              bmCapabilities       0x03
                call management
                use DataInterface
              bDataInterface          3
            CDC Union:
              bMasterInterface        2
              bSlaveInterface         3
            Endpoint Descriptor:
              bLength                 7
              bDescriptorType         5
              bEndpointAddress     0x83  EP 3 IN
              bmAttributes            3
                Transfer Type            Interrupt
                Synch Type               None
                Usage Type               Data
              wMaxPacketSize     0x0040  1x 64 bytes
              bInterval               5
          Interface Descriptor:
            bLength                 9
            bDescriptorType         4
            bInterfaceNumber        3
            bAlternateSetting       0
            bNumEndpoints           2
            bInterfaceClass        10 CDC Data
            bInterfaceSubClass      0 Unused
            bInterfaceProtocol      0
            iInterface              0
            Endpoint Descriptor:
              bLength                 7
              bDescriptorType         5
              bEndpointAddress     0x84  EP 4 IN
              bmAttributes            2
                Transfer Type            Bulk
                Synch Type               None
                Usage Type               Data
              wMaxPacketSize     0x0200  1x 512 bytes
              bInterval               0
            Endpoint Descriptor:
              bLength                 7
              bDescriptorType         5
              bEndpointAddress     0x02  EP 2 OUT
              bmAttributes            2
                Transfer Type            Bulk
                Synch Type               None
                Usage Type               Data
              wMaxPacketSize     0x0200  1x 512 bytes
              bInterval               0
          Interface Association:
            bLength                 8
            bDescriptorType        11
            bFirstInterface         4
            bInterfaceCount         2
            bFunctionClass          2 Communications
            bFunctionSubClass       2 Abstract (modem)
            bFunctionProtocol       1 AT-commands (v.25ter)
            iFunction               0
          Interface Descriptor:
            bLength                 9
            bDescriptorType         4
            bInterfaceNumber        4
            bAlternateSetting       0
            bNumEndpoints           1
            bInterfaceClass         2 Communications
            bInterfaceSubClass      2 Abstract (modem)
            bInterfaceProtocol      1 AT-commands (v.25ter)
            iInterface              0
            CDC Header:
              bcdCDC               1.10
            CDC ACM:
              bmCapabilities       0x02
                line coding and serial state
            CDC Call Management:
              bmCapabilities       0x03
                call management
                use DataInterface
              bDataInterface          5
            CDC Union:
              bMasterInterface        4
              bSlaveInterface         5
            Endpoint Descriptor:
              bLength                 7
              bDescriptorType         5
              bEndpointAddress     0x85  EP 5 IN
              bmAttributes            3
                Transfer Type            Interrupt
                Synch Type               None
                Usage Type               Data
              wMaxPacketSize     0x0040  1x 64 bytes
              bInterval               5
          Interface Descriptor:
            bLength                 9
            bDescriptorType         4
            bInterfaceNumber        5
            bAlternateSetting       0
            bNumEndpoints           2
            bInterfaceClass        10 CDC Data
            bInterfaceSubClass      0 Unused
            bInterfaceProtocol      0
            iInterface              0
            Endpoint Descriptor:
              bLength                 7
              bDescriptorType         5
              bEndpointAddress     0x86  EP 6 IN
              bmAttributes            2
                Transfer Type            Bulk
                Synch Type               None
                Usage Type               Data
              wMaxPacketSize     0x0200  1x 512 bytes
              bInterval               0
            Endpoint Descriptor:
              bLength                 7
              bDescriptorType         5
              bEndpointAddress     0x03  EP 3 OUT
              bmAttributes            2
                Transfer Type            Bulk
                Synch Type               None
                Usage Type               Data
              wMaxPacketSize     0x0200  1x 512 bytes
              bInterval               0
          Interface Association:
            bLength                 8
            bDescriptorType        11
            bFirstInterface         6
            bInterfaceCount         2
            bFunctionClass          2 Communications
            bFunctionSubClass       2 Abstract (modem)
            bFunctionProtocol       1 AT-commands (v.25ter)
            iFunction               0
          Interface Descriptor:
            bLength                 9
            bDescriptorType         4
            bInterfaceNumber        6
            bAlternateSetting       0
            bNumEndpoints           1
            bInterfaceClass         2 Communications
            bInterfaceSubClass      2 Abstract (modem)
            bInterfaceProtocol      1 AT-commands (v.25ter)
            iInterface              0
            CDC Header:
              bcdCDC               1.10
            CDC ACM:
              bmCapabilities       0x02
                line coding and serial state
            CDC Call Management:
              bmCapabilities       0x03
                call management
                use DataInterface
              bDataInterface          7
            CDC Union:
              bMasterInterface        6
              bSlaveInterface         7
            Endpoint Descriptor:
              bLength                 7
              bDescriptorType         5
              bEndpointAddress     0x87  EP 7 IN
              bmAttributes            3
                Transfer Type            Interrupt
                Synch Type               None
                Usage Type               Data
              wMaxPacketSize     0x0040  1x 64 bytes
              bInterval               5
          Interface Descriptor:
            bLength                 9
            bDescriptorType         4
            bInterfaceNumber        7
            bAlternateSetting       0
            bNumEndpoints           2
            bInterfaceClass        10 CDC Data
            bInterfaceSubClass      0 Unused
            bInterfaceProtocol      0
            iInterface              0
            Endpoint Descriptor:
              bLength                 7
              bDescriptorType         5
              bEndpointAddress     0x88  EP 8 IN
              bmAttributes            2
                Transfer Type            Bulk
                Synch Type               None
                Usage Type               Data
              wMaxPacketSize     0x0200  1x 512 bytes
              bInterval               0
            Endpoint Descriptor:
              bLength                 7
              bDescriptorType         5
              bEndpointAddress     0x04  EP 4 OUT
              bmAttributes            2
                Transfer Type            Bulk
                Synch Type               None
                Usage Type               Data
              wMaxPacketSize     0x0200  1x 512 bytes
              bInterval               0
          Interface Association:
            bLength                 8
            bDescriptorType        11
            bFirstInterface         8
            bInterfaceCount         2
            bFunctionClass          2 Communications
            bFunctionSubClass       0
            bFunctionProtocol       0
            iFunction               0
          Interface Descriptor:
            bLength                 9
            bDescriptorType         4
            bInterfaceNumber        8
            bAlternateSetting       0
            bNumEndpoints           1
            bInterfaceClass         2 Communications
            bInterfaceSubClass      6 Ethernet Networking
            bInterfaceProtocol      0
            iInterface              0
            CDC Header:
              bcdCDC               1.10
            CDC Ethernet:
              iMacAddress                      1 00A0C6C14190
              bmEthernetStatistics    0x00000000
              wMaxSegmentSize              16384
              wNumberMCFilters            0x0001
              bNumberPowerFilters              0
            CDC Union:
              bMasterInterface        8
              bSlaveInterface         9
            Endpoint Descriptor:
              bLength                 7
              bDescriptorType         5
              bEndpointAddress     0x89  EP 9 IN
              bmAttributes            3
                Transfer Type            Interrupt
                Synch Type               None
                Usage Type               Data
              wMaxPacketSize     0x0040  1x 64 bytes
              bInterval               5
          Interface Descriptor:
            bLength                 9
            bDescriptorType         4
            bInterfaceNumber        9
            bAlternateSetting       0
            bNumEndpoints           0
            bInterfaceClass        10 CDC Data
            bInterfaceSubClass      0 Unused
            bInterfaceProtocol      0
            iInterface              0
          Interface Descriptor:
            bLength                 9
            bDescriptorType         4
            bInterfaceNumber        9
            bAlternateSetting       1
            bNumEndpoints           2
            bInterfaceClass        10 CDC Data
            bInterfaceSubClass      0 Unused
            bInterfaceProtocol      0
            iInterface              0
            Endpoint Descriptor:
              bLength                 7
              bDescriptorType         5
              bEndpointAddress     0x8a  EP 10 IN
              bmAttributes            2
                Transfer Type            Bulk
                Synch Type               None
                Usage Type               Data
              wMaxPacketSize     0x0200  1x 512 bytes
              bInterval               0
            Endpoint Descriptor:
              bLength                 7
              bDescriptorType         5
              bEndpointAddress     0x05  EP 5 OUT
              bmAttributes            2
                Transfer Type            Bulk
                Synch Type               None
                Usage Type               Data
              wMaxPacketSize     0x0200  1x 512 bytes
              bInterval               0
      Device Qualifier (for other device speed):
        bLength                10
        bDescriptorType         6
        bcdUSB               2.00
        bDeviceClass          239 Miscellaneous Device
        bDeviceSubClass         2 ?
        bDeviceProtocol         1 Interface Association
        bMaxPacketSize0        64
        bNumConfigurations      1
      Device Status:     0x0000
        (Bus Powered)
      Signed-off-by: default avatarGiacinto Cifelli <gciofono@gmail.com>
      Link: https://lore.kernel.org/r/20210126044245.8455-1-gciofono@gmail.comSigned-off-by: default avatarJakub Kicinski <kuba@kernel.org>
      dad3a72f
    • Linus Torvalds's avatar
      Merge tag 'locking-urgent-2021-01-28' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip · c64396cc
      Linus Torvalds authored
      Pull locking fixes from Thomas Gleixner:
       "A set of PI futex fixes:
      
         - Address a longstanding issue where the user space part of the PI
           futex is not writeable. The kernel returns with inconsistent state
           which can in the worst case result in a UAF of a tasks kernel
           stack.
      
           The solution is to establish consistent kernel state which makes
           future operations on the futex fail because user space and kernel
           space state are inconsistent. Not a problem as PI futexes
           fundamentaly require a functional RW mapping and if user space
           pulls the rug under it, then it can keep the pieces it asked for.
      
         - Address an issue where the return value is incorrect in case that
           the futex was acquired after a timeout/signal made the waiter drop
           out of the rtmutex wait.
      
           In one of the corner cases the kernel returned an error code
           despite having successfully acquired the futex"
      
      * tag 'locking-urgent-2021-01-28' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip:
        futex: Handle faults correctly for PI futexes
        futex: Simplify fixup_pi_state_owner()
        futex: Use pi_state_update_owner() in put_pi_state()
        rtmutex: Remove unused argument from rt_mutex_proxy_unlock()
        futex: Provide and use pi_state_update_owner()
        futex: Replace pointless printk in fixup_owner()
        futex: Ensure the correct return value from futex_lock_pi()
      c64396cc
    • Jens Axboe's avatar
      Merge tag 'nvme-5.11-2021-01-28' of git://git.infradead.org/nvme into block-5.11 · e2579c76
      Jens Axboe authored
      Pull NVMe fixes from Christoph:
      
      "nvme fixes for 5.11:
      
       - add another Write Zeroes quirk (Chaitanya Kulkarni)
       - handle a no path available corner case (Daniel Wagner)
       - use the proper RCU aware list_add helper (Chao Leng)"
      
      * tag 'nvme-5.11-2021-01-28' of git://git.infradead.org/nvme:
        nvme-core: use list_add_tail_rcu instead of list_add_tail for nvme_init_ns_head
        nvme-multipath: Early exit if no path is available
        nvme-pci: add the DISABLE_WRITE_ZEROES quirk for a SPCC device
      e2579c76
    • Pavel Begunkov's avatar
      io_uring: fix sqo ownership false positive warning · 70b2c60d
      Pavel Begunkov authored
      WARNING: CPU: 0 PID: 21359 at fs/io_uring.c:9042
          io_uring_cancel_task_requests+0xe55/0x10c0 fs/io_uring.c:9042
      Call Trace:
       io_uring_flush+0x47b/0x6e0 fs/io_uring.c:9227
       filp_close+0xb4/0x170 fs/open.c:1295
       close_files fs/file.c:403 [inline]
       put_files_struct fs/file.c:418 [inline]
       put_files_struct+0x1cc/0x350 fs/file.c:415
       exit_files+0x7e/0xa0 fs/file.c:435
       do_exit+0xc22/0x2ae0 kernel/exit.c:820
       do_group_exit+0x125/0x310 kernel/exit.c:922
       get_signal+0x427/0x20f0 kernel/signal.c:2773
       arch_do_signal_or_restart+0x2a8/0x1eb0 arch/x86/kernel/signal.c:811
       handle_signal_work kernel/entry/common.c:147 [inline]
       exit_to_user_mode_loop kernel/entry/common.c:171 [inline]
       exit_to_user_mode_prepare+0x148/0x250 kernel/entry/common.c:201
       __syscall_exit_to_user_mode_work kernel/entry/common.c:291 [inline]
       syscall_exit_to_user_mode+0x19/0x50 kernel/entry/common.c:302
       entry_SYSCALL_64_after_hwframe+0x44/0xa9
      
      Now io_uring_cancel_task_requests() can be called not through file
      notes but directly, remove a WARN_ONCE() there that give us false
      positives. That check is not very important and we catch it in other
      places.
      
      Fixes: 84965ff8 ("io_uring: if we see flush on exit, cancel related tasks")
      Cc: stable@vger.kernel.org # 5.9+
      Reported-by: syzbot+3e3d9bd0c6ce9efbc3ef@syzkaller.appspotmail.com
      Signed-off-by: default avatarPavel Begunkov <asml.silence@gmail.com>
      Signed-off-by: default avatarJens Axboe <axboe@kernel.dk>
      70b2c60d
    • Pavel Begunkov's avatar
      io_uring: fix list corruption for splice file_get · f609cbb8
      Pavel Begunkov authored
      kernel BUG at lib/list_debug.c:29!
      Call Trace:
       __list_add include/linux/list.h:67 [inline]
       list_add include/linux/list.h:86 [inline]
       io_file_get+0x8cc/0xdb0 fs/io_uring.c:6466
       __io_splice_prep+0x1bc/0x530 fs/io_uring.c:3866
       io_splice_prep fs/io_uring.c:3920 [inline]
       io_req_prep+0x3546/0x4e80 fs/io_uring.c:6081
       io_queue_sqe+0x609/0x10d0 fs/io_uring.c:6628
       io_submit_sqe fs/io_uring.c:6705 [inline]
       io_submit_sqes+0x1495/0x2720 fs/io_uring.c:6953
       __do_sys_io_uring_enter+0x107d/0x1f30 fs/io_uring.c:9353
       do_syscall_64+0x2d/0x70 arch/x86/entry/common.c:46
       entry_SYSCALL_64_after_hwframe+0x44/0xa9
      
      io_file_get() may be called from splice, and so REQ_F_INFLIGHT may
      already be set.
      
      Fixes: 02a13674 ("io_uring: account io_uring internal files as REQ_F_INFLIGHT")
      Cc: stable@vger.kernel.org # 5.9+
      Reported-by: syzbot+6879187cf57845801267@syzkaller.appspotmail.com
      Signed-off-by: default avatarPavel Begunkov <asml.silence@gmail.com>
      Signed-off-by: default avatarJens Axboe <axboe@kernel.dk>
      f609cbb8
    • Arnd Bergmann's avatar
      amdgpu: fix clang build warning · 00190bc0
      Arnd Bergmann authored
      clang warns about the -mhard-float command line arguments
      on architectures that do not support this:
      
      clang: error: argument unused during compilation: '-mhard-float' [-Werror,-Wunused-command-line-argument]
      
      Move this into the gcc-specific arguments.
      
      Fixes: e77165bf ("drm/amd/display: Add DCN3 blocks to Makefile")
      Signed-off-by: default avatarArnd Bergmann <arnd@arndb.de>
      Signed-off-by: default avatarAlex Deucher <alexander.deucher@amd.com>
      00190bc0
    • Alex Deucher's avatar
      Revert "drm/amdgpu/swsmu: drop set_fan_speed_percent (v2)" · a119f87b
      Alex Deucher authored
      On some boards the rpm interface apparently does not work at all
      leading to the fan not spinning or spinning at strange speeds.
      Revert this for now to fix 5.10, 5.11.  The follow on patch
      fixes this properly for 5.12.
      
      This reverts commit 8d6e65ad.
      
      Bug: https://gitlab.freedesktop.org/drm/amd/-/issues/1408Signed-off-by: default avatarAlex Deucher <alexander.deucher@amd.com>
      Cc: stable@vger.kernel.org
      a119f87b
    • Chao Leng's avatar
      nvme-core: use list_add_tail_rcu instead of list_add_tail for nvme_init_ns_head · 772ea326
      Chao Leng authored
      The "list" of nvme_ns_head is used as rcu list, now in nvme_init_ns_head
      list_add_tail is used to add ns->siblings to the rcu list. It is not safe.
      Should use list_add_tail_rcu instead of list_add_tail.
      Signed-off-by: default avatarChao Leng <lengchao@huawei.com>
      Signed-off-by: default avatarChristoph Hellwig <hch@lst.de>
      772ea326
    • Daniel Wagner's avatar
      nvme-multipath: Early exit if no path is available · d1bcf006
      Daniel Wagner authored
      nvme_round_robin_path() should test if the return ns pointer is valid.
      nvme_next_ns() will return a NULL pointer if there is no path left.
      
      Fixes: 75c10e73 ("nvme-multipath: round-robin I/O policy")
      Signed-off-by: default avatarDaniel Wagner <dwagner@suse.de>
      Reviewed-by: default avatarHannes Reinecke <hare@suse.de>
      Signed-off-by: default avatarChristoph Hellwig <hch@lst.de>
      d1bcf006
    • Chaitanya Kulkarni's avatar
      nvme-pci: add the DISABLE_WRITE_ZEROES quirk for a SPCC device · 89919929
      Chaitanya Kulkarni authored
      This adds a quirk for SPCC 256GB NVMe 1.3 drive which fixes timeouts and
      I/O errors due to the fact that the controller does not properly
      handle the Write Zeroes command:
      
      [ 2745.659527] CPU: 2 PID: 0 Comm: swapper/2 Tainted: G            E 5.10.6-BET #1
      [ 2745.659528] Hardware name: System manufacturer System Product Name/PRIME X570-P, BIOS 3001 12/04/2020
      [ 2776.138874] nvme nvme1: I/O 414 QID 3 timeout, aborting
      [ 2776.138886] nvme nvme1: I/O 415 QID 3 timeout, aborting
      [ 2776.138891] nvme nvme1: I/O 416 QID 3 timeout, aborting
      [ 2776.138895] nvme nvme1: I/O 417 QID 3 timeout, aborting
      [ 2776.138912] nvme nvme1: Abort status: 0x0
      [ 2776.138921] nvme nvme1: I/O 428 QID 3 timeout, aborting
      [ 2776.138922] nvme nvme1: Abort status: 0x0
      [ 2776.138925] nvme nvme1: Abort status: 0x0
      [ 2776.138974] nvme nvme1: Abort status: 0x0
      [ 2776.138977] nvme nvme1: Abort status: 0x0
      [ 2806.346792] nvme nvme1: I/O 414 QID 3 timeout, reset controller
      [ 2806.363566] nvme nvme1: 15/0/0 default/read/poll queues
      [ 2836.554298] nvme nvme1: I/O 415 QID 3 timeout, disable controller
      [ 2836.672064] blk_update_request: I/O error, dev nvme1n1, sector 16350 op 0x9:(WRITE_ZEROES) flags 0x0 phys_seg 0 prio class 0
      [ 2836.672072] blk_update_request: I/O error, dev nvme1n1, sector 16093 op 0x9:(WRITE_ZEROES) flags 0x0 phys_seg 0 prio class 0
      [ 2836.672074] blk_update_request: I/O error, dev nvme1n1, sector 15836 op 0x9:(WRITE_ZEROES) flags 0x0 phys_seg 0 prio class 0
      [ 2836.672076] blk_update_request: I/O error, dev nvme1n1, sector 15579 op 0x9:(WRITE_ZEROES) flags 0x0 phys_seg 0 prio class 0
      [ 2836.672078] blk_update_request: I/O error, dev nvme1n1, sector 15322 op 0x9:(WRITE_ZEROES) flags 0x0 phys_seg 0 prio class 0
      [ 2836.672080] blk_update_request: I/O error, dev nvme1n1, sector 15065 op 0x9:(WRITE_ZEROES) flags 0x0 phys_seg 0 prio class 0
      [ 2836.672082] blk_update_request: I/O error, dev nvme1n1, sector 14808 op 0x9:(WRITE_ZEROES) flags 0x0 phys_seg 0 prio class 0
      [ 2836.672083] blk_update_request: I/O error, dev nvme1n1, sector 14551 op 0x9:(WRITE_ZEROES) flags 0x0 phys_seg 0 prio class 0
      [ 2836.672085] blk_update_request: I/O error, dev nvme1n1, sector 14294 op 0x9:(WRITE_ZEROES) flags 0x0 phys_seg 0 prio class 0
      [ 2836.672087] blk_update_request: I/O error, dev nvme1n1, sector 14037 op 0x9:(WRITE_ZEROES) flags 0x0 phys_seg 0 prio class 0
      [ 2836.672121] nvme nvme1: failed to mark controller live state
      [ 2836.672123] nvme nvme1: Removing after probe failure status: -19
      [ 2836.689016] Aborting journal on device dm-0-8.
      [ 2836.689024] Buffer I/O error on dev dm-0, logical block 25198592, lost sync page write
      [ 2836.689027] JBD2: Error -5 detected when updating journal superblock for dm-0-8.
      Reported-by: default avatarBradley Chapman <chapman6235@comcast.net>
      Signed-off-by: default avatarChaitanya Kulkarni <chaitanya.kulkarni@wdc.com>
      Tested-by: default avatarBradley Chapman <chapman6235@comcast.net>
      Reviewed-by: default avatarKeith Busch <kbusch@kernel.org>
      Signed-off-by: default avatarChristoph Hellwig <hch@lst.de>
      89919929
    • Linus Torvalds's avatar
      Merge tag 'for-linus-5.11-rc6-tag' of git://git.kernel.org/pub/scm/linux/kernel/git/xen/tip · e5ff2cb9
      Linus Torvalds authored
      Pull xen fixes from Juergen Gross:
      
       - A fix for a regression introduced in 5.11 resulting in Xen dom0
         having problems to correctly initialize Xenstore.
      
       - A fix for avoiding WARN splats when booting as Xen dom0 with
         CONFIG_AMD_MEM_ENCRYPT enabled due to a missing trap handler for the
         #VC exception (even if the handler should never be called).
      
       - A fix for the Xen bklfront driver adapting to the correct but
         unexpected behavior of new qemu.
      
      * tag 'for-linus-5.11-rc6-tag' of git://git.kernel.org/pub/scm/linux/kernel/git/xen/tip:
        x86/xen: avoid warning in Xen pv guest with CONFIG_AMD_MEM_ENCRYPT enabled
        xen: Fix XenStore initialisation for XS_LOCAL
        xen-blkfront: allow discard-* nodes to be optional
      e5ff2cb9
    • Linus Torvalds's avatar
      Merge tag 'asm-generic-fixes-v5.11' of... · 228345bf
      Linus Torvalds authored
      Merge tag 'asm-generic-fixes-v5.11' of git://git.kernel.org/pub/scm/linux/kernel/git/arnd/asm-generic
      
      Pull ia64 fixes from Arnd Bergmann:
       "asm-generic/ia64 fixes, and mark as orphaned
      
        Commit 2b49ddce ("ia64: convert to legacy_timer_tick") from my
        timer series I merged through the asm-generic tree caused a regression
        on all ia64 machines, as bisected by Adrian Glaubitz.
      
        Tony Luck is no longer really working on ia64, so instead of merging
        the fix through his tree, we ended up deciding that I'd merge the fix
        myself along a patch to mark the architecture as Orphaned and a
        compile time warning fix I made while working on the regression"
      
      [ HPE no longer accepts orders for new Itanium hardware, and Intel
        stopped accepting orders a year ago. While intel is still officially
        shipping chips until July 29, 2021, it's unlikely that any such orders
        actually exist.
      
        It's dead, Jim.
                           - Linus ]
      
      * tag 'asm-generic-fixes-v5.11' of git://git.kernel.org/pub/scm/linux/kernel/git/arnd/asm-generic:
        ia64: Mark architecture as orphaned
        ia64: fix xchg() warning
        ia64: fix timer cleanup regression
      228345bf
    • Linus Torvalds's avatar
      Merge tag 'arm-soc-fixes-v5.11-2' of git://git.kernel.org/pub/scm/linux/kernel/git/soc/soc · 7485e08e
      Linus Torvalds authored
      Pull ARM SoC fixes from Arnd Bergmann:
       "These are the current arm-soc bug fixes for linux-5.11. I already
        merged a larger set that just came in during the past three days but
        has not had much exposure in linux-next, but this is the subset I
        merged last week.
      
        Most of these are for the NXP i.MX platform (descriptions from their
        pull request):
      
         - Fix pcf2127 reset for imx7d-flex-concentrator board.
         - Fix i.MX6 suspend with Thumb-2 kernel.
         - Fix ethernet-phy address issue on imx6qdl-sr-som board.
         - Fix GPIO3 `gpio-ranges` on i.MX8MP.
         - Select SOC_BUS for IMX_SCU driver to fix build issue.
         - Fix backlight pwm on imx6qdl-kontron-samx6i which is lost from
           #pwm-cells conversion.
         - Fix duplicated bus node name for i.MX8MN SoC.
         - Fix reset register offset on LS1028A SoC.
         - Rename MMC node aliases for imx6q-tbs2910 to keep the MMC device
           index consistent with previous kernel version.
         - Selecting ARM_GIC_V3 on non-CP15 processors to fix one build
           failure with i.MX8M SoC driver.
         - Fix typos with status property on imx6qdl-kontron-samx6i board.
         - Fix duplicated regulator-name on imx6qdl-gw52xx board.
      
        Aside from i.MX, the bugfixes are all over the place:
      
         - Coccinelle found a refcount imbalance on integrator
         - defconfig fix for TI K3
         - A boot regression fix for ST ux500
         - A code preemption fix for the optee driver
         - USB DMA regression on Broadcom Stingray
         - A bogus boot time warning fix for at91 code"
      
      * tag 'arm-soc-fixes-v5.11-2' of git://git.kernel.org/pub/scm/linux/kernel/git/soc/soc:
        MAINTAINERS: Include bcm2835 subsequents into search
        arm64: dts: broadcom: Fix USB DMA address translation for Stingray
        drivers: soc: atmel: add null entry at the end of at91_soc_allowed_list[]
        drivers: soc: atmel: Avoid calling at91_soc_init on non AT91 SoCs
        tee: optee: replace might_sleep with cond_resched
        firmware: imx: select SOC_BUS to fix firmware build
        arm64: dts: imx8mp: Correct the gpio ranges of gpio3
        ARM: dts: imx6qdl-sr-som: fix some cubox-i platforms
        ARM: imx: build suspend-imx6.S with arm instruction set
        ARM: dts: imx7d-flex-concentrator: fix pcf2127 reset
        ARM: dts: ux500: Reserve memory carveouts
        arm64: defconfig: Drop unused K3 SoC specific options
        bus: arm-integrator-lm: Add of_node_put() before return statement
        ARM: dts: imx6qdl-gw52xx: fix duplicate regulator naming
        ARM: dts: imx6qdl-kontron-samx6i: fix i2c_lcd/cam default status
        ARM: imx: fix imx8m dependencies
        ARM: dts: tbs2910: rename MMC node aliases
        arm64: dts: ls1028a: fix the offset of the reset register
        arm64: dts: imx8mn: Fix duplicate node name
        ARM: dts: imx6qdl-kontron-samx6i: fix pwms for lcd-backlight
      7485e08e